Bläddra i källkod

system获取所有车辆信息

qiangxuan 2 månader sedan
förälder
incheckning
1f03f6d748

+ 1 - 0
zgztBus/jeecg-boot-base-core/src/main/java/org/jeecg/config/shiro/ShiroConfig.java

@@ -159,6 +159,7 @@ public class ShiroConfig {
         filterChainDefinitionMap.put("/storageBill/editNoToken", "anon");
         filterChainDefinitionMap.put("/storageBill/editSynData", "anon");
         filterChainDefinitionMap.put("/storageBill/editLicensePlate", "anon");
+        filterChainDefinitionMap.put("/sys/dict/getAllLicensePlate", "anon");
         // update-begin--author:liusq Date:20230522 for:[issues/4829]访问不存在的url时会提示Token失效,请重新登录呢
         //错误路径排除
         filterChainDefinitionMap.put("/error", "anon");

+ 21 - 0
zgztBus/jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/system/controller/SysDictController.java

@@ -6,6 +6,7 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
 import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import io.swagger.annotations.ApiOperation;
 import lombok.extern.slf4j.Slf4j;
 import org.apache.shiro.SecurityUtils;
 import org.apache.shiro.authz.annotation.RequiresPermissions;
@@ -183,6 +184,26 @@ public class SysDictController {
 		}
 		return result;
 	}
+	@ApiOperation(value="B端监控看板获取所有系统车辆信息", notes="B端监控看板获取所有系统车辆信息")
+	@RequestMapping(value = "/getAllLicensePlate", method = RequestMethod.GET)
+	public Result<List<DictModel>> getDictItemsLicensePlate() {
+		Result<List<DictModel>> result = new Result<List<DictModel>>();
+		try {
+			List<DictModel> ls = sysDictService.getDictItems("lg_car");
+			if (ls == null) {
+				result.error500("字典Code格式不正确!");
+				return result;
+			}
+			result.setSuccess(true);
+			result.setResult(ls);
+			log.debug(result.toString());
+		} catch (Exception e) {
+			log.error(e.getMessage(), e);
+			result.error500("操作失败");
+			return result;
+		}
+		return result;
+	}
 
 	/**
 	 * 【接口签名验证】