From f5c1732bf6bfd05af3fa53286e9c85f34d77c677 Mon Sep 17 00:00:00 2001
From: Administrator <admin>
Date: Mon, 30 Aug 2021 16:06:45 +0800
Subject: [PATCH] 未持证去除
---
src/main/java/org/springblade/modules/system/service/impl/UserServiceImpl.java | 43 +++++++++++++++++++++++++++++++++++++++++--
1 files changed, 41 insertions(+), 2 deletions(-)
diff --git a/src/main/java/org/springblade/modules/system/service/impl/UserServiceImpl.java b/src/main/java/org/springblade/modules/system/service/impl/UserServiceImpl.java
index 7fef4e8..e258e59 100644
--- a/src/main/java/org/springblade/modules/system/service/impl/UserServiceImpl.java
+++ b/src/main/java/org/springblade/modules/system/service/impl/UserServiceImpl.java
@@ -41,6 +41,9 @@
import org.springblade.core.tool.support.Kv;
import org.springblade.core.tool.utils.*;
import org.springblade.modules.auth.enums.UserEnum;
+import org.springblade.modules.information.entity.Information;
+import org.springblade.modules.information.service.IInformationService;
+import org.springblade.modules.jurisdiction.entity.Jurisdiction;
import org.springblade.modules.system.entity.*;
import org.springblade.modules.system.excel.UserExcel;
import org.springblade.modules.system.mapper.UserMapper;
@@ -72,6 +75,7 @@
private final IUserOauthService userOauthService;
private final IRoleService roleService;
private final BladeTenantProperties tenantProperties;
+ private final IInformationService iInformationService;
@Override
@Transactional(rollbackFor = Exception.class)
@@ -347,7 +351,8 @@
//设置账号
user.setAccount(user.getCardid());
//获取默认密码配置
- user.setPassword(ParamCache.getValue(DEFAULT_PARAM_PASSWORD));
+ user.setPassword(user.getCardid().substring(user.getCardid().length()-6));
+// user.setPassword(ParamCache.getValue(DEFAULT_PARAM_PASSWORD));
//新增
this.submit(user);
});
@@ -591,7 +596,8 @@
//设置账号
user.setAccount(user.getCardid());
//获取默认密码配置
- user.setPassword(ParamCache.getValue(DEFAULT_PARAM_PASSWORD));
+ user.setPassword(user.getCardid().substring(user.getCardid().length()-6));
+// user.setPassword(ParamCache.getValue(DEFAULT_PARAM_PASSWORD));
//新增
this.submit(user);
});
@@ -618,4 +624,37 @@
public UserVO getUserDetails(User user) {
return baseMapper.getUserDetails(user);
}
+
+ /**
+ *
+ * @param type 1:派遣 2:保安向
+ * @param deptid
+ * @param jurisdiction
+ * @return
+ */
+ @Override
+ public List<Map<String, Object>> seleL(String type,String deptid, String jurisdiction) {
+ List<Map<String, Object>> list = new ArrayList<>();
+ //派遣
+ if (Integer.parseInt(type)==1){
+ list = baseMapper.getDispaterInfo(deptid, jurisdiction);
+ }
+ //工作汇报
+ //保安向保安
+ if (Integer.parseInt(type)==2){
+ list = baseMapper.getWorkReportInfo(type,deptid, jurisdiction);
+ }
+ //保安向民警
+ if (Integer.parseInt(type)==3){
+ Information information = new Information();
+ information.setDepartmentid(deptid);
+ Information one = iInformationService.getOne(Condition.getQueryWrapper(information));
+ list = baseMapper.getWorkReportInfo(type,null, one.getJurisdiction());
+ }
+ //民警对民警
+ if (Integer.parseInt(type)==4){
+ list = baseMapper.getWorkReportInfo(type,deptid, jurisdiction);
+ }
+ return list;
+ }
}
--
Gitblit v1.9.3