diff --git a/src/main/java/com/subsidy/controller/AdministerCompanyMappingController.java b/src/main/java/com/subsidy/controller/AdministerCompanyMappingController.java
new file mode 100644
index 0000000..2068e77
--- /dev/null
+++ b/src/main/java/com/subsidy/controller/AdministerCompanyMappingController.java
@@ -0,0 +1,29 @@
+package com.subsidy.controller;
+
+
+import com.subsidy.common.ResponseData;
+import com.subsidy.common.ResponseVO;
+import com.subsidy.service.AdministerCompanyMappingService;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestMapping;
+
+import org.springframework.web.bind.annotation.RestController;
+import io.swagger.annotations.Api;
+
+/**
+ *
+ * 管理员-公司映射表 前端控制器
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-05
+ */
+@RestController
+@Api(tags = "管理员-公司映射表")
+@RequestMapping("/administerCompanyMapping")
+public class AdministerCompanyMappingController {
+
+}
diff --git a/src/main/java/com/subsidy/controller/AdministerController.java b/src/main/java/com/subsidy/controller/AdministerController.java
index 7257d7f..80452ae 100644
--- a/src/main/java/com/subsidy/controller/AdministerController.java
+++ b/src/main/java/com/subsidy/controller/AdministerController.java
@@ -4,7 +4,9 @@ package com.subsidy.controller;
import com.subsidy.common.ResponseData;
import com.subsidy.common.ResponseVO;
import com.subsidy.common.interceptor.LoginRequired;
+import com.subsidy.common.interceptor.TimeRequired;
import com.subsidy.dto.administer.*;
+import com.subsidy.dto.member.QingxuetangLoginDTO;
import com.subsidy.model.*;
import com.subsidy.service.AdministerService;
import com.subsidy.vo.member.DownloadFailMembersDTO;
@@ -15,6 +17,7 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;
+import javax.servlet.http.HttpServletRequest;
import java.util.List;
/**
@@ -33,18 +36,19 @@ public class AdministerController {
@Autowired
private AdministerService administerService;
-// @GetMapping("getIp")
-// public String getIp()throws Exception{
-// InetAddress addr = InetAddress.getLocalHost();
-// return addr.getHostAddress();
-// }
-
@PostMapping("/login")
- @ApiOperation("登录接口 accountName password")
+ @ApiOperation("登录接口(非中心端登录入口) accountName password")
public ResponseVO login(@RequestBody AdministerDO administerDO) {
return ResponseData.generateCreatedResponse(0, administerService.login(administerDO));
}
+ @PostMapping("appLogin")
+ @ApiOperation("应用端 手机号accountName timestamp sign")
+ @TimeRequired
+ public ResponseVO kunchiLogin(@RequestBody AppLoginDTO appLoginDTO, HttpServletRequest request){
+ return ResponseData.generateCreatedResponse(0,administerService.appLogin(appLoginDTO,request));
+ }
+
@PostMapping("/getPermissions")
@ApiOperation("权限查询")
@LoginRequired
@@ -53,31 +57,31 @@ public class AdministerController {
}
@PostMapping("/administers")
- @ApiOperation("查询所有运营者 { userName pageNum pageSize }")
+ @ApiOperation("客户账户管理 { userName companyName pageNum pageSize }")
// @LoginRequired
public ResponseVO operators(@RequestBody OperatorsDTO operatorsDTO) {
return ResponseData.generateCreatedResponse(0, administerService.operators(operatorsDTO));
}
@PostMapping("addAdminister")
- @ApiOperation("添加运营者 id userName 名称 accountName 账号 ")
+ @ApiOperation("添加客户账户 userName 名称 accountName 账户 password 密码 telephone 联系方式 role:0:应用 1:客户 2:中心 3:企业唯一账号 remark 备注 companyIds[] serviceIds[]")
@LoginRequired
- public ResponseVO addAdminister(@RequestBody AdministerDO administerDO) {
- return ResponseData.generateCreatedResponse(0, administerService.addAdminister(administerDO));
+ public ResponseVO addAdminister(@RequestBody AddAdministerDTO addAdministerDTO) {
+ return ResponseData.generateCreatedResponse(0, administerService.addAdminister(addAdministerDTO));
}
@PostMapping("deleteAdminister")
- @ApiOperation("添加运营者 id ")
+ @ApiOperation("客户账户管理 删除 id ")
@LoginRequired
public ResponseVO deleteAdminister(@RequestBody AdministerDO administerDO) {
return ResponseData.generateCreatedResponse(0, administerService.deleteAdminister(administerDO));
}
@PostMapping("updateAdminister")
- @ApiOperation("编辑运营者 id userName 名称 accountName 账号 password")
+ @ApiOperation("编辑客户账户 id userName 名称 accountName 账号 password remark telephone companyIds[] serviceIds[]")
@LoginRequired
- public ResponseVO updateAdminister(@RequestBody AdministerDO administerDO) {
- return ResponseData.generateCreatedResponse(0, administerService.updateAdminister(administerDO));
+ public ResponseVO updateAdminister(@RequestBody AddAdministerDTO addAdministerDTO) {
+ return ResponseData.generateCreatedResponse(0, administerService.updateAdminister(addAdministerDTO));
}
@PostMapping("classSummary")
diff --git a/src/main/java/com/subsidy/controller/CompanyMemberMappingController.java b/src/main/java/com/subsidy/controller/CompanyMemberMappingController.java
index a8ad305..f20f16a 100644
--- a/src/main/java/com/subsidy/controller/CompanyMemberMappingController.java
+++ b/src/main/java/com/subsidy/controller/CompanyMemberMappingController.java
@@ -3,7 +3,9 @@ package com.subsidy.controller;
import com.subsidy.common.ResponseData;
import com.subsidy.common.ResponseVO;
+import com.subsidy.dto.company.AttendMembersDTO;
import com.subsidy.dto.member.CancerMemberDTO;
+import com.subsidy.dto.member.DepartMembersDTO;
import com.subsidy.dto.member.InviteMemberDTO;
import com.subsidy.mapper.CompanyMemberMappingMapper;
import com.subsidy.model.CompanyMemberMappingDO;
@@ -35,7 +37,7 @@ public class CompanyMemberMappingController {
private CompanyMemberMappingService companyMemberMappingService;
@PostMapping("noCompanyMembers")
- @ApiOperation(" userName idCard")
+ @ApiOperation("没有公司的人 userName idCard")
public ResponseVO noCompanyMembers(@RequestBody MemberDO memberDO){
return ResponseData.generateCreatedResponse(0,companyMemberMappingService.noCompanyMembers(memberDO));
}
@@ -52,4 +54,29 @@ public class CompanyMemberMappingController {
return ResponseData.generateCreatedResponse(0,companyMemberMappingService.cancerMember(cancerMemberDTO));
}
+ @PostMapping("departMembers")
+ @ApiOperation("某公司的离职记录 pageSize pageNum companyId userName 姓名/手机号/身份证号")
+ public ResponseVO departMembers(@RequestBody DepartMembersDTO departMembersDTO){
+ return ResponseData.generateCreatedResponse(0,companyMemberMappingService.departMembers(departMembersDTO));
+ }
+
+ @PostMapping("exportDepartMembers")
+ @ApiOperation("导出离职人员记录 companyId userName 姓名/手机号/身份证号 ")
+ public void exportDepartMembers(@RequestBody DepartMembersDTO departMembersDTO){
+ companyMemberMappingService.exportDepartMembers(departMembersDTO);
+ }
+
+ @PostMapping("attendMembers")
+ @ApiOperation("查看某个企业已经参加过该培训的学生 companyId departmentId userName pageSize pageNum")
+ public ResponseVO attendMembers(@RequestBody AttendMembersDTO attendMembersDTO){
+ return ResponseData.generateCreatedResponse(0,companyMemberMappingService.attendMembers(attendMembersDTO));
+ }
+
+ @PostMapping("memberAttendInfo")
+ @ApiOperation("某个学员在该企业参加培训的详情 memberId 学员id companyId 公司id")
+ public ResponseVO memberAttendInfo(@RequestBody CompanyMemberMappingDO companyMemberMappingDO){
+ return ResponseData.generateCreatedResponse(0,companyMemberMappingService.memberAttendInfo(companyMemberMappingDO));
+ }
+
+
}
diff --git a/src/main/java/com/subsidy/controller/MemberController.java b/src/main/java/com/subsidy/controller/MemberController.java
index e62f0cb..83e2a7d 100644
--- a/src/main/java/com/subsidy/controller/MemberController.java
+++ b/src/main/java/com/subsidy/controller/MemberController.java
@@ -44,6 +44,14 @@ public class MemberController {
return ResponseData.generateCreatedResponse(0,memberService.getAll(getAllDTO));
}
+ @PostMapping("exportAllMembers")
+ @ApiOperation("导出企业成员 departmentId userName status ")
+ public void exportAllMembers(@RequestBody GetAllDTO getAllDTO){
+ memberService.exportAllMembers(getAllDTO);
+ }
+
+
+
@PostMapping("deleteMember")
@ApiOperation("删除成员 id ")
@LoginRequired
diff --git a/src/main/java/com/subsidy/controller/OssController.java b/src/main/java/com/subsidy/controller/OssController.java
index f37729b..d3841e0 100644
--- a/src/main/java/com/subsidy/controller/OssController.java
+++ b/src/main/java/com/subsidy/controller/OssController.java
@@ -47,41 +47,6 @@ public class OssController {
return ResponseData.generateCreatedResponse(0, getSecretVO);
}
-// @PostMapping("uploadFile")
-// @ApiOperation("上传文件 file")
-// public ResponseVO uploadFile(@RequestParam("file") MultipartFile file) {
-// // 创建OSSClient实例。
-// OSS ossClient = new OSSClientBuilder().build("http://oss-cn-shanghai.aliyuncs.com", keyId, secret);
-// UploadFileVO uploadFileVO = new UploadFileVO();
-// try {
-//
-// if (env.equals("test")) {
-// env = "ykhl-bigger-test";
-// }
-// if (env.equals("prod")) {
-// env = "ykhl-bigger";
-// }
-//
-//
-// // 创建PutObjectRequest对象。
-// PutObjectRequest putObjectRequest = new PutObjectRequest(env, System.currentTimeMillis() + "_" + file.getOriginalFilename(), file.getInputStream());
-// // 设置该属性可以返回response。如果不设置,则返回的response为空。
-// putObjectRequest.setProcess("true");
-// // 创建PutObject请求。
-// PutObjectResult result = ossClient.putObject(putObjectRequest);
-// // 如果上传成功,则返回200。
-//// System.out.println(result.getResponse().getUri());
-// uploadFileVO.setUrl(result.getResponse().getUri());
-// } catch (Exception oe) {
-// oe.printStackTrace();
-// } finally {
-// if (ossClient != null) {
-// ossClient.shutdown();
-// }
-// }
-// return ResponseData.generateCreatedResponse(0, uploadFileVO);
-// }
-
@PostMapping("uploadFile")
@ApiOperation("分片上传")
public ResponseVO fenpian(@RequestParam("file") MultipartFile file) {
diff --git a/src/main/java/com/subsidy/controller/ProductDictController.java b/src/main/java/com/subsidy/controller/ProductDictController.java
new file mode 100644
index 0000000..b441443
--- /dev/null
+++ b/src/main/java/com/subsidy/controller/ProductDictController.java
@@ -0,0 +1,58 @@
+package com.subsidy.controller;
+
+
+import com.subsidy.common.ResponseData;
+import com.subsidy.common.ResponseVO;
+import com.subsidy.dto.product.AllProductsDTO;
+import com.subsidy.model.ProductDictDO;
+import com.subsidy.service.ProductDictService;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+
+/**
+ *
+ * 产品管理字典表 前端控制器
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-08
+ */
+@RestController
+@Api(tags = "产品管理字典表")
+@RequestMapping("/productDict")
+public class ProductDictController {
+
+ @Autowired
+ private ProductDictService productDictService;
+
+ @PostMapping("allProducts")
+ @ApiOperation("查看所有产品 productName pageSize pageNum")
+ public ResponseVO allProducts(@RequestBody AllProductsDTO allProductsDTO){
+ return ResponseData.generateCreatedResponse(0,productDictService.allProducts(allProductsDTO));
+ }
+
+ @PostMapping("addProduct")
+ @ApiOperation("添加产品 productName productLogo productDesc contactInfo groundingStatus highlightTag ")
+ public ResponseVO addProduct(@RequestBody ProductDictDO productDictDO){
+ return ResponseData.generateCreatedResponse(0,productDictService.addProduct(productDictDO));
+ }
+
+ @PostMapping("deleteProduct")
+ @ApiOperation("删除产品 id")
+ public ResponseVO deleteProduct(@RequestBody ProductDictDO productDictDO){
+ return ResponseData.generateCreatedResponse(0,productDictService.deleteProduct(productDictDO));
+ }
+
+ @PostMapping("updateProduct")
+ @ApiOperation("编辑产品 id productName productLogo productDesc contactInfo groundingStatus highlightTag ")
+ public ResponseVO updateProduct(@RequestBody ProductDictDO productDictDO){
+ return ResponseData.generateCreatedResponse(0,productDictService.updateProduct(productDictDO));
+ }
+
+
+}
diff --git a/src/main/java/com/subsidy/controller/ServiceAdministerMappingController.java b/src/main/java/com/subsidy/controller/ServiceAdministerMappingController.java
new file mode 100644
index 0000000..0635ea8
--- /dev/null
+++ b/src/main/java/com/subsidy/controller/ServiceAdministerMappingController.java
@@ -0,0 +1,40 @@
+package com.subsidy.controller;
+
+
+import com.subsidy.common.ResponseData;
+import com.subsidy.common.ResponseVO;
+import com.subsidy.model.ServiceAdministerMappingDO;
+import com.subsidy.service.ServiceAdministerMappingService;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestMapping;
+
+import org.springframework.web.bind.annotation.RestController;
+import io.swagger.annotations.Api;
+
+/**
+ *
+ * 应用账户-服务映射表 前端控制器
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-08
+ */
+@RestController
+@Api(tags = "应用账户-服务映射表")
+@RequestMapping("/serviceAdministerMapping")
+public class ServiceAdministerMappingController {
+
+ @Autowired
+ private ServiceAdministerMappingService serviceAdministerMappingService;
+
+ @PostMapping("administerServices")
+ @ApiOperation("查看某个人所有的服务 administerId 账户id")
+ public ResponseVO administerServices(@RequestBody ServiceAdministerMappingDO serviceAdministerMappingDO){
+ return ResponseData.generateCreatedResponse(0,serviceAdministerMappingService.administerServices(serviceAdministerMappingDO));
+ }
+
+
+}
diff --git a/src/main/java/com/subsidy/controller/ServiceCompanyFilesController.java b/src/main/java/com/subsidy/controller/ServiceCompanyFilesController.java
new file mode 100644
index 0000000..43f8c02
--- /dev/null
+++ b/src/main/java/com/subsidy/controller/ServiceCompanyFilesController.java
@@ -0,0 +1,51 @@
+package com.subsidy.controller;
+
+
+import com.subsidy.common.ResponseData;
+import com.subsidy.common.ResponseVO;
+import com.subsidy.model.ServiceCompanyFilesDO;
+import com.subsidy.service.ServiceCompanyFilesService;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestMapping;
+
+import org.springframework.web.bind.annotation.RestController;
+import io.swagger.annotations.Api;
+
+/**
+ *
+ * 前端控制器
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-05
+ */
+@RestController
+@Api(tags = "协议管理材料表")
+@RequestMapping("/serviceCompanyFiles")
+public class ServiceCompanyFilesController {
+
+ @Autowired
+ private ServiceCompanyFilesService serviceCompanyFilesService;
+
+ @PostMapping("companyFiles")
+ @ApiOperation("查看业务合同/业务材料 serviceCompanyId fileType 0:业务合同 1:业务材料 ")
+ public ResponseVO companyFiles(@RequestBody ServiceCompanyFilesDO serviceCompanyFilesDO){
+ return ResponseData.generateCreatedResponse(0,serviceCompanyFilesService.companyFiles(serviceCompanyFilesDO));
+ }
+
+ @PostMapping("deleteFile")
+ @ApiOperation("删除协议/材料 id companyFiles返回的id")
+ public ResponseVO deleteFile(@RequestBody ServiceCompanyFilesDO serviceCompanyFilesDO){
+ return ResponseData.generateCreatedResponse(0,serviceCompanyFilesService.deleteFile(serviceCompanyFilesDO));
+ }
+
+ @PostMapping("uploadFile")
+ @ApiOperation("上传新文件 serviceCompanyId fileType 0:业务合同 1:业务材料 fileName fileAddress ")
+ public ResponseVO uploadFile(@RequestBody ServiceCompanyFilesDO serviceCompanyFilesDO){
+ return ResponseData.generateCreatedResponse(0,serviceCompanyFilesService.uploadFile(serviceCompanyFilesDO));
+ }
+
+}
diff --git a/src/main/java/com/subsidy/controller/ServiceCompanyMappingController.java b/src/main/java/com/subsidy/controller/ServiceCompanyMappingController.java
new file mode 100644
index 0000000..3cf4ae9
--- /dev/null
+++ b/src/main/java/com/subsidy/controller/ServiceCompanyMappingController.java
@@ -0,0 +1,61 @@
+package com.subsidy.controller;
+
+
+import com.subsidy.common.ResponseData;
+import com.subsidy.common.ResponseVO;
+import com.subsidy.dto.service.CancelAuthDTO;
+import com.subsidy.dto.service.GetServiceCompaniesDTO;
+import com.subsidy.service.ServiceCompanyMappingService;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestMapping;
+
+import org.springframework.web.bind.annotation.RestController;
+import io.swagger.annotations.Api;
+
+/**
+ *
+ * 业务公司 映射表 前端控制器
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-05
+ */
+@RestController
+@Api(tags = "业务公司 映射表")
+@RequestMapping("/serviceCompanyMapping")
+public class ServiceCompanyMappingController {
+
+ @Autowired
+ private ServiceCompanyMappingService serviceCompanyMappingService;
+
+ @PostMapping("getServiceCompanies")
+ @ApiOperation("获取某个业务下的公司(筛选可查全部的) serviceId 业务id pageSize authStatus pageNum companyName")
+ public ResponseVO getServiceCompanies(@RequestBody GetServiceCompaniesDTO getServiceCompaniesDTO){
+ return ResponseData.generateCreatedResponse(0,serviceCompanyMappingService.getServiceCompanies(getServiceCompaniesDTO));
+ }
+
+ @PostMapping("cancelAuth")
+ @ApiOperation("取消授权 serviceId companyIds[]")
+ public ResponseVO cancelAuth(@RequestBody CancelAuthDTO cancelAuthDTO){
+ return ResponseData.generateCreatedResponse(0,serviceCompanyMappingService.cancelAuth(cancelAuthDTO));
+ }
+
+
+ @PostMapping("addAuth")
+ @ApiOperation("添加授权 serviceId companyIds[]")
+ public ResponseVO addAuth(@RequestBody CancelAuthDTO cancelAuthDTO){
+ return ResponseData.generateCreatedResponse(0,serviceCompanyMappingService.addAuth(cancelAuthDTO));
+ }
+
+ @PostMapping("serviceCompanies")
+ @ApiOperation("获取某个业务管理下的所有公司 companyName serviceId")
+ public ResponseVO serviceCompanies(@RequestBody GetServiceCompaniesDTO getServiceCompaniesDTO){
+ return ResponseData.generateCreatedResponse(0,serviceCompanyMappingService.serviceCompanies(getServiceCompaniesDTO));
+ }
+
+
+
+}
diff --git a/src/main/java/com/subsidy/controller/ServiceDictController.java b/src/main/java/com/subsidy/controller/ServiceDictController.java
new file mode 100644
index 0000000..4bd6797
--- /dev/null
+++ b/src/main/java/com/subsidy/controller/ServiceDictController.java
@@ -0,0 +1,39 @@
+package com.subsidy.controller;
+
+
+import com.subsidy.common.ResponseData;
+import com.subsidy.common.ResponseVO;
+import com.subsidy.service.ServiceDictService;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.RequestMapping;
+
+import org.springframework.web.bind.annotation.RestController;
+import io.swagger.annotations.Api;
+
+import javax.servlet.http.HttpServletRequest;
+
+/**
+ *
+ * 业务管理字典表 前端控制器
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-05
+ */
+@RestController
+@Api(tags = "业务管理字典表")
+@RequestMapping("/serviceDict")
+public class ServiceDictController {
+
+ @Autowired
+ private ServiceDictService serviceDictService;
+
+ @PostMapping("getAllServices")
+ @ApiOperation("获取所有的服务")
+ public ResponseVO getAllServices(){
+ return ResponseData.generateCreatedResponse(0,serviceDictService.getAllServices());
+ }
+
+}
diff --git a/src/main/java/com/subsidy/dto/administer/AddAdministerDTO.java b/src/main/java/com/subsidy/dto/administer/AddAdministerDTO.java
new file mode 100644
index 0000000..0ac08eb
--- /dev/null
+++ b/src/main/java/com/subsidy/dto/administer/AddAdministerDTO.java
@@ -0,0 +1,52 @@
+package com.subsidy.dto.administer;
+
+import lombok.Data;
+
+import java.util.List;
+
+@Data
+public class AddAdministerDTO {
+
+
+ private Long id;
+
+ /**
+ * 账号
+ */
+ private String accountName;
+
+ /**
+ * 手机号/企业账号
+ */
+ private String telephone;
+
+ /**
+ * 密码
+ */
+ private String password;
+
+ /**
+ * 成员名称
+ */
+ private String userName;
+
+ /**
+ * 备注
+ */
+ private String remark;
+
+ /**
+ * 角色
+ */
+ private Integer role;
+ /**
+ * 企业
+ */
+ private List companyIds;
+
+ /**
+ * 服务
+ */
+ private List serviceIds;
+
+}
diff --git a/src/main/java/com/subsidy/dto/administer/AppLoginDTO.java b/src/main/java/com/subsidy/dto/administer/AppLoginDTO.java
new file mode 100644
index 0000000..fb80633
--- /dev/null
+++ b/src/main/java/com/subsidy/dto/administer/AppLoginDTO.java
@@ -0,0 +1,28 @@
+package com.subsidy.dto.administer;
+
+import lombok.Data;
+
+@Data
+public class AppLoginDTO {
+
+ private String appId;
+
+ private String authCorpId;
+
+ private String authCorpName;
+
+ private String openId;
+
+ private String accountName;
+
+ private Long id;
+
+ private String mobile;
+
+ private String nickname;
+
+ private Long timestamp;
+
+ private String sign;
+
+}
diff --git a/src/main/java/com/subsidy/dto/administer/OperatorsDTO.java b/src/main/java/com/subsidy/dto/administer/OperatorsDTO.java
index 567085b..62976fa 100644
--- a/src/main/java/com/subsidy/dto/administer/OperatorsDTO.java
+++ b/src/main/java/com/subsidy/dto/administer/OperatorsDTO.java
@@ -21,4 +21,7 @@ public class OperatorsDTO {
private String superviseName;
+ private Long userId;
+
+
}
diff --git a/src/main/java/com/subsidy/dto/company/AttendMembersDTO.java b/src/main/java/com/subsidy/dto/company/AttendMembersDTO.java
new file mode 100644
index 0000000..da68f84
--- /dev/null
+++ b/src/main/java/com/subsidy/dto/company/AttendMembersDTO.java
@@ -0,0 +1,18 @@
+package com.subsidy.dto.company;
+
+import lombok.Data;
+
+@Data
+public class AttendMembersDTO {
+
+ private Long companyId;
+
+ private Long departmentId;
+
+ private String userName;
+
+ private Integer pageSize;
+
+ private Integer pageNum;
+
+}
diff --git a/src/main/java/com/subsidy/dto/member/DepartMembersDTO.java b/src/main/java/com/subsidy/dto/member/DepartMembersDTO.java
new file mode 100644
index 0000000..fadfdd3
--- /dev/null
+++ b/src/main/java/com/subsidy/dto/member/DepartMembersDTO.java
@@ -0,0 +1,16 @@
+package com.subsidy.dto.member;
+
+import lombok.Data;
+
+@Data
+public class DepartMembersDTO {
+
+ private Integer pageSize;
+
+ private Integer pageNum;
+
+ private String userName;
+
+ private Long companyId;
+
+}
diff --git a/src/main/java/com/subsidy/dto/product/AllProductsDTO.java b/src/main/java/com/subsidy/dto/product/AllProductsDTO.java
new file mode 100644
index 0000000..5c97b51
--- /dev/null
+++ b/src/main/java/com/subsidy/dto/product/AllProductsDTO.java
@@ -0,0 +1,14 @@
+package com.subsidy.dto.product;
+
+import lombok.Data;
+
+@Data
+public class AllProductsDTO {
+
+ private Integer pageSize;
+
+ private Integer pageNum;
+
+ private String productName;
+
+}
diff --git a/src/main/java/com/subsidy/dto/service/CancelAuthDTO.java b/src/main/java/com/subsidy/dto/service/CancelAuthDTO.java
new file mode 100644
index 0000000..4c8eb4b
--- /dev/null
+++ b/src/main/java/com/subsidy/dto/service/CancelAuthDTO.java
@@ -0,0 +1,13 @@
+package com.subsidy.dto.service;
+
+import lombok.Data;
+
+import java.util.List;
+
+@Data
+public class CancelAuthDTO {
+
+ private List companyIds;
+
+ private Long serviceId;
+}
diff --git a/src/main/java/com/subsidy/dto/service/GetServiceCompaniesDTO.java b/src/main/java/com/subsidy/dto/service/GetServiceCompaniesDTO.java
new file mode 100644
index 0000000..388ccc3
--- /dev/null
+++ b/src/main/java/com/subsidy/dto/service/GetServiceCompaniesDTO.java
@@ -0,0 +1,18 @@
+package com.subsidy.dto.service;
+
+import lombok.Data;
+
+@Data
+public class GetServiceCompaniesDTO {
+
+ private Integer pageSize;
+
+ private Integer pageNum;
+
+ private String companyName;
+
+ private String authStatus;
+
+ private Long serviceId;
+
+}
diff --git a/src/main/java/com/subsidy/mapper/AdministerCompanyMappingMapper.java b/src/main/java/com/subsidy/mapper/AdministerCompanyMappingMapper.java
new file mode 100644
index 0000000..6f4af25
--- /dev/null
+++ b/src/main/java/com/subsidy/mapper/AdministerCompanyMappingMapper.java
@@ -0,0 +1,18 @@
+package com.subsidy.mapper;
+
+import com.subsidy.model.AdministerCompanyMappingDO;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import org.springframework.stereotype.Repository;
+
+/**
+ *
+ * 管理员-公司映射表 Mapper 接口
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-05
+ */
+ @Repository
+public interface AdministerCompanyMappingMapper extends BaseMapper {
+
+}
diff --git a/src/main/java/com/subsidy/mapper/AdministerMapper.java b/src/main/java/com/subsidy/mapper/AdministerMapper.java
index 29caedc..047a156 100644
--- a/src/main/java/com/subsidy/mapper/AdministerMapper.java
+++ b/src/main/java/com/subsidy/mapper/AdministerMapper.java
@@ -5,8 +5,10 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
import com.subsidy.dto.administer.SelfExportVO;
import com.subsidy.model.AdministerDO;
import com.subsidy.model.ClassDictDO;
+import com.subsidy.model.CompanyDictDO;
import com.subsidy.vo.administer.*;
import com.subsidy.vo.classdict.ClassDetailVO;
+import com.subsidy.vo.company.GetAllCompanyVO;
import com.subsidy.vo.member.ClassSignVO;
import com.subsidy.vo.sign.AnswerRecordVO;
import org.springframework.stereotype.Repository;
@@ -59,11 +61,25 @@ public interface AdministerMapper extends BaseMapper {
/**
* 管理员账号管理
*/
- IPage operators(IPage page, String userName);
+ IPage operators(IPage page, String userName,String companyName);
/**
* 自助导出
*/
List selfExport(ClassDictDO classDictDO);
+ /**
+ * 查看某客户账号管理哪些公司
+ */
+ List administerCompanys(Long administerId);
+
+ /**
+ * 查看某客户账号管理哪些公司 返回id
+ */
+ List administerCompanyIds(Long administerId);
+
+ /**
+ * 查看某客户有哪些服务 返回id
+ */
+ List administerServiceIds(Long administerId);
}
diff --git a/src/main/java/com/subsidy/mapper/CompanyDictMapper.java b/src/main/java/com/subsidy/mapper/CompanyDictMapper.java
index e02dd31..dee2ef2 100644
--- a/src/main/java/com/subsidy/mapper/CompanyDictMapper.java
+++ b/src/main/java/com/subsidy/mapper/CompanyDictMapper.java
@@ -22,12 +22,18 @@ import java.util.List;
@Repository
public interface CompanyDictMapper extends BaseMapper {
+
+ /**
+ * 查询全部企业
+ */
+ IPage allOperators(IPage page,String companyName, Long fieldId, String superviseName);
+
/**
* 企业管理--查找所有主账号 、运营者
*
* @return
*/
- IPage operators(IPage page, String companyName, Long fieldId, Long id, Integer role, String superviseName);
+ IPage operators(IPage page, Long userId,String companyName, Long fieldId, String superviseName);
/**
* 查找所有的公司名称
diff --git a/src/main/java/com/subsidy/mapper/CompanyMemberMappingMapper.java b/src/main/java/com/subsidy/mapper/CompanyMemberMappingMapper.java
index 05de4c2..e49d274 100644
--- a/src/main/java/com/subsidy/mapper/CompanyMemberMappingMapper.java
+++ b/src/main/java/com/subsidy/mapper/CompanyMemberMappingMapper.java
@@ -1,9 +1,14 @@
package com.subsidy.mapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
import com.subsidy.model.CompanyDictDO;
import com.subsidy.model.CompanyMemberMappingDO;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.subsidy.model.MemberDO;
+import com.subsidy.vo.member.AttendMembersVO;
+import com.subsidy.vo.member.DepartMembersVO;
+import com.subsidy.vo.member.MemberAttendInfoVO;
+import com.subsidy.vo.member.MemberCompanyVO;
import org.springframework.stereotype.Repository;
import java.util.List;
@@ -43,4 +48,25 @@ public interface CompanyMemberMappingMapper extends BaseMapper companyAccountMembers(Long companyId,String accountName);
+
+ /**
+ * 查询某个人带过公司的记录
+ */
+ List memberCompanys(Long memberId);
+
+ /**
+ * 查看某个公司的离职记录
+ */
+ IPage departMembers(IPage iPage,Long companyId,String userName);
+
+ /**
+ * 某公司参加过培训的学生名单
+ */
+ IPage attendMembers(IPage iPage, Long companyId, Long departmentId, String userName);
+
+ /**
+ * 某个学员参加过某个公司的所有培训
+ */
+ List memberAttendInfo(Long memberId, Long companyId);
+
}
diff --git a/src/main/java/com/subsidy/mapper/ProductDictMapper.java b/src/main/java/com/subsidy/mapper/ProductDictMapper.java
new file mode 100644
index 0000000..28ebf67
--- /dev/null
+++ b/src/main/java/com/subsidy/mapper/ProductDictMapper.java
@@ -0,0 +1,22 @@
+package com.subsidy.mapper;
+
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.subsidy.dto.product.AllProductsDTO;
+import com.subsidy.model.ProductDictDO;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import org.springframework.stereotype.Repository;
+
+/**
+ *
+ * 产品管理字典表 Mapper 接口
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-08
+ */
+@Repository
+public interface ProductDictMapper extends BaseMapper {
+
+ IPage allProducts(IPage iPage,String productName);
+
+}
diff --git a/src/main/java/com/subsidy/mapper/ServiceAdministerMappingMapper.java b/src/main/java/com/subsidy/mapper/ServiceAdministerMappingMapper.java
new file mode 100644
index 0000000..eef23eb
--- /dev/null
+++ b/src/main/java/com/subsidy/mapper/ServiceAdministerMappingMapper.java
@@ -0,0 +1,26 @@
+package com.subsidy.mapper;
+
+import com.subsidy.model.ServiceAdministerMappingDO;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.subsidy.model.ServiceDictDO;
+import org.springframework.stereotype.Repository;
+
+import java.util.List;
+
+/**
+ *
+ * 应用账户-服务映射表 Mapper 接口
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-08
+ */
+@Repository
+public interface ServiceAdministerMappingMapper extends BaseMapper {
+
+ /**
+ * 查看某个账户能管理的应用
+ */
+ List administerService(Long administerId);
+
+}
diff --git a/src/main/java/com/subsidy/mapper/ServiceCompanyFilesMapper.java b/src/main/java/com/subsidy/mapper/ServiceCompanyFilesMapper.java
new file mode 100644
index 0000000..7d3f7b5
--- /dev/null
+++ b/src/main/java/com/subsidy/mapper/ServiceCompanyFilesMapper.java
@@ -0,0 +1,22 @@
+package com.subsidy.mapper;
+
+import com.subsidy.model.ServiceCompanyFilesDO;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import org.springframework.stereotype.Repository;
+
+import java.util.List;
+
+/**
+ *
+ * Mapper 接口
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-05
+ */
+ @Repository
+public interface ServiceCompanyFilesMapper extends BaseMapper {
+
+ List companyFiles(Long serviceCompanyId, String fileName);
+
+}
diff --git a/src/main/java/com/subsidy/mapper/ServiceCompanyMappingMapper.java b/src/main/java/com/subsidy/mapper/ServiceCompanyMappingMapper.java
new file mode 100644
index 0000000..fcb4386
--- /dev/null
+++ b/src/main/java/com/subsidy/mapper/ServiceCompanyMappingMapper.java
@@ -0,0 +1,27 @@
+package com.subsidy.mapper;
+
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.subsidy.model.CompanyDictDO;
+import com.subsidy.model.ServiceCompanyMappingDO;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.subsidy.vo.service.GetServiceCompaniesVO;
+import com.subsidy.vo.service.ServiceCompaniesVO;
+import org.springframework.stereotype.Repository;
+
+import java.util.List;
+
+/**
+ *
+ * 业务公司 映射表 Mapper 接口
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-05
+ */
+@Repository
+public interface ServiceCompanyMappingMapper extends BaseMapper {
+
+ IPage getServiceCompanies(IPage iPage, Long serviceId, String companyName, String authStatus);
+
+ List serviceCompanies(Long serviceId, String companyName);
+}
diff --git a/src/main/java/com/subsidy/mapper/ServiceDictMapper.java b/src/main/java/com/subsidy/mapper/ServiceDictMapper.java
new file mode 100644
index 0000000..bbad35c
--- /dev/null
+++ b/src/main/java/com/subsidy/mapper/ServiceDictMapper.java
@@ -0,0 +1,18 @@
+package com.subsidy.mapper;
+
+import com.subsidy.model.ServiceDictDO;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import org.springframework.stereotype.Repository;
+
+/**
+ *
+ * 业务管理字典表 Mapper 接口
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-05
+ */
+ @Repository
+public interface ServiceDictMapper extends BaseMapper {
+
+}
diff --git a/src/main/java/com/subsidy/model/AdministerCompanyMappingDO.java b/src/main/java/com/subsidy/model/AdministerCompanyMappingDO.java
new file mode 100644
index 0000000..6cd1404
--- /dev/null
+++ b/src/main/java/com/subsidy/model/AdministerCompanyMappingDO.java
@@ -0,0 +1,33 @@
+package com.subsidy.model;
+
+import com.subsidy.util.BaseModel;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+/**
+ *
+ * 管理员-公司映射表
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-05
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+@TableName("administer_company_mapping")
+public class AdministerCompanyMappingDO extends BaseModel {
+
+ private static final long serialVersionUID = 1L;
+
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ private Long administerId;
+
+ private Long companyId;
+
+
+}
diff --git a/src/main/java/com/subsidy/model/AdministerDO.java b/src/main/java/com/subsidy/model/AdministerDO.java
index d76b33c..5dbb91a 100644
--- a/src/main/java/com/subsidy/model/AdministerDO.java
+++ b/src/main/java/com/subsidy/model/AdministerDO.java
@@ -63,15 +63,14 @@ public class AdministerDO extends BaseModel {
*/
private String status;
- ///**
- // * 0:运营者账号 1:企业账号
- // */
- //private String accountType;
-
/**
* role 0:平台运营者 1:超级管理员 2:普通成员
*/
private Integer role;
+ /**
+ * 备注
+ */
+ private String remark;
}
diff --git a/src/main/java/com/subsidy/model/CompanyDictDO.java b/src/main/java/com/subsidy/model/CompanyDictDO.java
index 3c4d157..9643b32 100644
--- a/src/main/java/com/subsidy/model/CompanyDictDO.java
+++ b/src/main/java/com/subsidy/model/CompanyDictDO.java
@@ -41,16 +41,6 @@ public class CompanyDictDO extends BaseModel {
private String companyCode;
/**
- * 账号
- */
- private String accountName;
-
- /**
- * 密码
- */
- private String password;
-
- /**
* 简称
*/
private String shortName;
diff --git a/src/main/java/com/subsidy/model/CompanyMemberMappingDO.java b/src/main/java/com/subsidy/model/CompanyMemberMappingDO.java
index 1845099..0164f38 100644
--- a/src/main/java/com/subsidy/model/CompanyMemberMappingDO.java
+++ b/src/main/java/com/subsidy/model/CompanyMemberMappingDO.java
@@ -40,5 +40,14 @@ public class CompanyMemberMappingDO extends BaseModel {
*/
private Integer memberStatus;
+ /**
+ * 工号
+ */
+ private String workNo;
+
+ /**
+ * 入职时间
+ */
+ private String inductionDate;
}
diff --git a/src/main/java/com/subsidy/model/MemberDO.java b/src/main/java/com/subsidy/model/MemberDO.java
index b05e5e0..d8d8c7c 100644
--- a/src/main/java/com/subsidy/model/MemberDO.java
+++ b/src/main/java/com/subsidy/model/MemberDO.java
@@ -60,17 +60,6 @@ public class MemberDO extends BaseModel {
private String password;
/**
- * 工号
- */
- private String workNo;
-
- /**
- * 入职时间
- */
- @JsonFormat
- private String inductionDate;
-
- /**
* 邮箱
*/
private String email;
diff --git a/src/main/java/com/subsidy/model/ProductDictDO.java b/src/main/java/com/subsidy/model/ProductDictDO.java
new file mode 100644
index 0000000..792edf5
--- /dev/null
+++ b/src/main/java/com/subsidy/model/ProductDictDO.java
@@ -0,0 +1,59 @@
+package com.subsidy.model;
+
+import com.subsidy.util.BaseModel;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+/**
+ *
+ * 产品管理字典表
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-08
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+@TableName("product_dict")
+public class ProductDictDO extends BaseModel {
+
+ private static final long serialVersionUID = 1L;
+
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ /**
+ * 产品名称
+ */
+ private String productName;
+
+ /**
+ * 产品图标
+ */
+ private String productLogo;
+
+ /**
+ * 产品描述
+ */
+ private String productDesc;
+
+ /**
+ * 联系方式
+ */
+ private String contactInfo;
+
+ /**
+ * 上下架状态
+ */
+ private String groundingStatus;
+
+ /**
+ * 高亮标签
+ */
+ private String highlightTag;
+
+
+}
diff --git a/src/main/java/com/subsidy/model/RankDictDO.java b/src/main/java/com/subsidy/model/RankDictDO.java
index 0bcb376..fe97fc0 100644
--- a/src/main/java/com/subsidy/model/RankDictDO.java
+++ b/src/main/java/com/subsidy/model/RankDictDO.java
@@ -30,7 +30,7 @@ public class RankDictDO extends BaseModel {
/**
* 职级
*/
- private String rank;
+ private String rankLevel;
}
diff --git a/src/main/java/com/subsidy/model/ServiceAdministerMappingDO.java b/src/main/java/com/subsidy/model/ServiceAdministerMappingDO.java
new file mode 100644
index 0000000..06d1bba
--- /dev/null
+++ b/src/main/java/com/subsidy/model/ServiceAdministerMappingDO.java
@@ -0,0 +1,33 @@
+package com.subsidy.model;
+
+import com.subsidy.util.BaseModel;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+/**
+ *
+ * 应用账户-服务映射表
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-08
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+@TableName("service_administer_mapping")
+public class ServiceAdministerMappingDO extends BaseModel {
+
+ private static final long serialVersionUID = 1L;
+
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ private Long administerId;
+
+ private Long serviceId;
+
+
+}
diff --git a/src/main/java/com/subsidy/model/ServiceCompanyFilesDO.java b/src/main/java/com/subsidy/model/ServiceCompanyFilesDO.java
new file mode 100644
index 0000000..39f1114
--- /dev/null
+++ b/src/main/java/com/subsidy/model/ServiceCompanyFilesDO.java
@@ -0,0 +1,40 @@
+package com.subsidy.model;
+
+import com.subsidy.util.BaseModel;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+/**
+ *
+ *
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-05
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+@TableName("service_company_files")
+public class ServiceCompanyFilesDO extends BaseModel {
+
+ private static final long serialVersionUID = 1L;
+
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ private Long serviceCompanyId;
+
+ /**
+ * 0:业务合同 1:业务材料
+ */
+ private String fileType;
+
+ private String fileName;
+
+ private String fileAddress;
+
+
+}
diff --git a/src/main/java/com/subsidy/model/ServiceCompanyMappingDO.java b/src/main/java/com/subsidy/model/ServiceCompanyMappingDO.java
new file mode 100644
index 0000000..33f2712
--- /dev/null
+++ b/src/main/java/com/subsidy/model/ServiceCompanyMappingDO.java
@@ -0,0 +1,38 @@
+package com.subsidy.model;
+
+import com.subsidy.util.BaseModel;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+/**
+ *
+ * 业务公司 映射表
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-05
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+@TableName("service_company_mapping")
+public class ServiceCompanyMappingDO extends BaseModel {
+
+ private static final long serialVersionUID = 1L;
+
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ /**
+ * 公司id
+ */
+ private Long companyId;
+
+ /**
+ * 业务id
+ */
+ private Long serviceId;
+
+}
diff --git a/src/main/java/com/subsidy/model/ServiceDictDO.java b/src/main/java/com/subsidy/model/ServiceDictDO.java
new file mode 100644
index 0000000..7f1d5ac
--- /dev/null
+++ b/src/main/java/com/subsidy/model/ServiceDictDO.java
@@ -0,0 +1,34 @@
+package com.subsidy.model;
+
+import com.subsidy.util.BaseModel;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+/**
+ *
+ * 业务管理字典表
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-05
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+@TableName("service_dict")
+public class ServiceDictDO extends BaseModel {
+
+ private static final long serialVersionUID = 1L;
+
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ /**
+ * 业务名称
+ */
+ private String serviceName;
+
+
+}
diff --git a/src/main/java/com/subsidy/service/AdministerCompanyMappingService.java b/src/main/java/com/subsidy/service/AdministerCompanyMappingService.java
new file mode 100644
index 0000000..f16880e
--- /dev/null
+++ b/src/main/java/com/subsidy/service/AdministerCompanyMappingService.java
@@ -0,0 +1,18 @@
+package com.subsidy.service;
+
+import com.subsidy.model.AdministerCompanyMappingDO;
+import com.baomidou.mybatisplus.extension.service.IService;
+
+import java.util.List;
+
+/**
+ *
+ * 管理员-公司映射表 服务类
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-05
+ */
+public interface AdministerCompanyMappingService extends IService {
+
+}
diff --git a/src/main/java/com/subsidy/service/AdministerService.java b/src/main/java/com/subsidy/service/AdministerService.java
index e304ca6..b08ccee 100644
--- a/src/main/java/com/subsidy/service/AdministerService.java
+++ b/src/main/java/com/subsidy/service/AdministerService.java
@@ -14,6 +14,7 @@ import com.subsidy.vo.member.ImportMemberVO;
import com.subsidy.vo.sign.AnswerRecordVO;
import org.springframework.web.multipart.MultipartFile;
+import javax.servlet.http.HttpServletRequest;
import java.util.List;
/**
@@ -28,15 +29,17 @@ public interface AdministerService extends IService {
LoginVO login(AdministerDO administerDO);
+ LoginVO appLogin(AppLoginDTO appLoginDTO, HttpServletRequest request);
+
AdministerPermissionVO getPermissions();
- IPage operators(OperatorsDTO operatorsDTO);
+ IPage operators(OperatorsDTO operatorsDTO);
- String addAdminister(AdministerDO administerDO);
+ String addAdminister(AddAdministerDTO addAdministerDTO);
String deleteAdminister(AdministerDO administerDO);
- String updateAdminister(AdministerDO administerDO);
+ String updateAdminister(AddAdministerDTO addAdministerDTO);
ClassSummaryVO classSummary(ClassDetailDTO classDetailDTO);
diff --git a/src/main/java/com/subsidy/service/CompanyMemberMappingService.java b/src/main/java/com/subsidy/service/CompanyMemberMappingService.java
index 1ec89e4..87d590d 100644
--- a/src/main/java/com/subsidy/service/CompanyMemberMappingService.java
+++ b/src/main/java/com/subsidy/service/CompanyMemberMappingService.java
@@ -1,10 +1,16 @@
package com.subsidy.service;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.subsidy.dto.company.AttendMembersDTO;
import com.subsidy.dto.member.CancerMemberDTO;
+import com.subsidy.dto.member.DepartMembersDTO;
import com.subsidy.dto.member.InviteMemberDTO;
import com.subsidy.model.CompanyMemberMappingDO;
import com.baomidou.mybatisplus.extension.service.IService;
import com.subsidy.model.MemberDO;
+import com.subsidy.vo.member.AttendMembersVO;
+import com.subsidy.vo.member.DepartMembersVO;
+import com.subsidy.vo.member.MemberAttendInfoVO;
import java.util.List;
@@ -23,4 +29,13 @@ public interface CompanyMemberMappingService extends IService departMembers(DepartMembersDTO departMembersDTO);
+
+ void exportDepartMembers(DepartMembersDTO departMembersDTO);
+
+ IPage attendMembers(AttendMembersDTO attendMembersDTO);
+
+ List memberAttendInfo(CompanyMemberMappingDO companyMemberMappingDO);
+
}
diff --git a/src/main/java/com/subsidy/service/MemberService.java b/src/main/java/com/subsidy/service/MemberService.java
index af73fbf..86df841 100644
--- a/src/main/java/com/subsidy/service/MemberService.java
+++ b/src/main/java/com/subsidy/service/MemberService.java
@@ -29,6 +29,8 @@ public interface MemberService extends IService {
IPage getAll(GetAllDTO getAllDTO);
+ void exportAllMembers(GetAllDTO getAllDTO);
+
String deleteMember(MemberDO memberDO);
String addMember(AddMemberDTO addMemberDTO);
diff --git a/src/main/java/com/subsidy/service/ProductDictService.java b/src/main/java/com/subsidy/service/ProductDictService.java
new file mode 100644
index 0000000..973c8b5
--- /dev/null
+++ b/src/main/java/com/subsidy/service/ProductDictService.java
@@ -0,0 +1,26 @@
+package com.subsidy.service;
+
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.extension.service.IService;
+import com.subsidy.dto.product.AllProductsDTO;
+import com.subsidy.model.ProductDictDO;
+
+/**
+ *
+ * 产品管理字典表 服务类
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-08
+ */
+public interface ProductDictService extends IService {
+
+ IPage allProducts(AllProductsDTO allProductsDTO);
+
+ String addProduct(ProductDictDO productDictDO);
+
+ String deleteProduct(ProductDictDO productDictDO);
+
+ String updateProduct(ProductDictDO productDictDO);
+
+}
diff --git a/src/main/java/com/subsidy/service/ServiceAdministerMappingService.java b/src/main/java/com/subsidy/service/ServiceAdministerMappingService.java
new file mode 100644
index 0000000..99b47fc
--- /dev/null
+++ b/src/main/java/com/subsidy/service/ServiceAdministerMappingService.java
@@ -0,0 +1,21 @@
+package com.subsidy.service;
+
+import com.subsidy.model.ServiceAdministerMappingDO;
+import com.baomidou.mybatisplus.extension.service.IService;
+import com.subsidy.model.ServiceDictDO;
+
+import java.util.List;
+
+/**
+ *
+ * 应用账户-服务映射表 服务类
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-08
+ */
+public interface ServiceAdministerMappingService extends IService {
+
+ List administerServices(ServiceAdministerMappingDO serviceAdministerMappingDO);
+
+}
diff --git a/src/main/java/com/subsidy/service/ServiceCompanyFilesService.java b/src/main/java/com/subsidy/service/ServiceCompanyFilesService.java
new file mode 100644
index 0000000..1d7f4a6
--- /dev/null
+++ b/src/main/java/com/subsidy/service/ServiceCompanyFilesService.java
@@ -0,0 +1,24 @@
+package com.subsidy.service;
+
+import com.subsidy.model.ServiceCompanyFilesDO;
+import com.baomidou.mybatisplus.extension.service.IService;
+
+import java.util.List;
+
+/**
+ *
+ * 服务类
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-05
+ */
+public interface ServiceCompanyFilesService extends IService {
+
+ List companyFiles(ServiceCompanyFilesDO serviceCompanyFilesDO);
+
+ String deleteFile(ServiceCompanyFilesDO serviceCompanyFilesDO);
+
+ String uploadFile(ServiceCompanyFilesDO serviceCompanyFilesDO);
+
+}
diff --git a/src/main/java/com/subsidy/service/ServiceCompanyMappingService.java b/src/main/java/com/subsidy/service/ServiceCompanyMappingService.java
new file mode 100644
index 0000000..3166542
--- /dev/null
+++ b/src/main/java/com/subsidy/service/ServiceCompanyMappingService.java
@@ -0,0 +1,32 @@
+package com.subsidy.service;
+
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.subsidy.dto.service.CancelAuthDTO;
+import com.subsidy.dto.service.GetServiceCompaniesDTO;
+import com.subsidy.model.CompanyDictDO;
+import com.subsidy.model.ServiceCompanyMappingDO;
+import com.baomidou.mybatisplus.extension.service.IService;
+import com.subsidy.vo.service.GetServiceCompaniesVO;
+import com.subsidy.vo.service.ServiceCompaniesVO;
+
+import java.util.List;
+
+/**
+ *
+ * 业务公司 映射表 服务类
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-05
+ */
+public interface ServiceCompanyMappingService extends IService {
+
+ IPage getServiceCompanies(GetServiceCompaniesDTO getServiceCompaniesDTO);
+
+ String cancelAuth(CancelAuthDTO cancelAuthDTO);
+
+ String addAuth(CancelAuthDTO cancelAuthDTO);
+
+ List serviceCompanies(GetServiceCompaniesDTO getServiceCompaniesDTO);
+
+}
diff --git a/src/main/java/com/subsidy/service/ServiceDictService.java b/src/main/java/com/subsidy/service/ServiceDictService.java
new file mode 100644
index 0000000..04f3b91
--- /dev/null
+++ b/src/main/java/com/subsidy/service/ServiceDictService.java
@@ -0,0 +1,21 @@
+package com.subsidy.service;
+
+import com.subsidy.model.ServiceDictDO;
+import com.baomidou.mybatisplus.extension.service.IService;
+
+import java.util.List;
+
+/**
+ *
+ * 业务管理字典表 服务类
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-05
+ */
+public interface ServiceDictService extends IService {
+
+ List getAllServices();
+
+
+}
diff --git a/src/main/java/com/subsidy/service/impl/AdministerCompanyMappingServiceImpl.java b/src/main/java/com/subsidy/service/impl/AdministerCompanyMappingServiceImpl.java
new file mode 100644
index 0000000..fab85ed
--- /dev/null
+++ b/src/main/java/com/subsidy/service/impl/AdministerCompanyMappingServiceImpl.java
@@ -0,0 +1,25 @@
+package com.subsidy.service.impl;
+
+import com.subsidy.mapper.AdministerMapper;
+import com.subsidy.model.AdministerCompanyMappingDO;
+import com.subsidy.mapper.AdministerCompanyMappingMapper;
+import com.subsidy.service.AdministerCompanyMappingService;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import com.subsidy.vo.company.GetAllCompanyVO;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+/**
+ *
+ * 管理员-公司映射表 服务实现类
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-05
+ */
+@Service
+public class AdministerCompanyMappingServiceImpl extends ServiceImpl implements AdministerCompanyMappingService {
+
+}
diff --git a/src/main/java/com/subsidy/service/impl/AdministerServiceImpl.java b/src/main/java/com/subsidy/service/impl/AdministerServiceImpl.java
index 33ee251..f0686ef 100644
--- a/src/main/java/com/subsidy/service/impl/AdministerServiceImpl.java
+++ b/src/main/java/com/subsidy/service/impl/AdministerServiceImpl.java
@@ -14,6 +14,7 @@ import com.subsidy.util.*;
import com.subsidy.util.excel.ExcelUtil;
import com.subsidy.vo.administer.*;
import com.subsidy.vo.classdict.ClassDetailVO;
+import com.subsidy.vo.company.GetAllCompanyVO;
import com.subsidy.vo.done.GetMaxScoreVO;
import com.subsidy.vo.done.TestScoreInfoVO;
import com.subsidy.vo.image.GetMemberCheckDetailVO;
@@ -43,11 +44,13 @@ import org.apache.poi.xssf.usermodel.XSSFWorkbook;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
import org.springframework.web.context.request.RequestContextHolder;
import org.springframework.web.context.request.ServletRequestAttributes;
import org.springframework.web.multipart.MultipartFile;
import javax.servlet.ServletOutputStream;
+import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.*;
import java.net.URLEncoder;
@@ -104,14 +107,11 @@ public class AdministerServiceImpl extends ServiceImpl()
.lambda()
- .eq(AdministerDO::getAccountName, administerDO.getAccountName()));
- //redisUtil.set(RedisPrefixConstant.SUBSIDY_ADMINISTER_PREFIX + administerDO.getAccountName(), administerDO1);
- //}
+ .eq(AdministerDO::getAccountName, administerDO.getAccountName())
+ .ne(AdministerDO::getRole, 2));
if (null == administerDO1) {
throw new HttpException(10012);
@@ -171,7 +165,7 @@ public class AdministerServiceImpl extends ServiceImpl()
+ .lambda()
+ .eq(AdministerDO::getAccountName, appLoginDTO.getAccountName()));
+
+ if (administerDO == null) {
+ throw new HttpException(10010);
+ }
+
+ /**
+ * 时间戳有没有过期
+ */
+ if (appLoginDTO.getTimestamp() - System.currentTimeMillis() >= 5 * 60 * 1000 || System.currentTimeMillis() - appLoginDTO.getTimestamp() >= 5 * 60 * 1000) {
+ throw new HttpException(14002);
+ }
+
+ //鉴权逻辑 对不对
+ String preAuthen = "appId=qxywz5nnWMI7ABCS"
+ +"&id="+administerDO.getId()
+ + "&accountName=" + administerDO.getAccountName()
+ + "&appSecret=626737T1-65K0-5xC2-0Y0V-2Aq9QUAJ";
+
+ String result = SecretUtils.getMD5String(preAuthen);
+ if (!appLoginDTO.getSign().equals(result)) {
+ throw new HttpException(14001);
+ }
+
+ String token = JwtUtil.generateToken(administerDO.getId(), ConstantUtils.ADMINISTER_TERMINATE);
+ loginVO.setToken(token);
+ return loginVO;
+ }
+
public AdministerPermissionVO getPermissions() {
AdministerPermissionVO administerPermissionVO = new AdministerPermissionVO();
@@ -250,78 +283,185 @@ public class AdministerServiceImpl extends ServiceImpl()
- .lambda()
- .eq(RoleAdministerMappingDO::getAdministerId, administerDO.getId()));
- administerPermissionVO.setRole(roleAdministerMappingDO.getRoleId());
+// //查询角色
+// RoleAdministerMappingDO roleAdministerMappingDO = roleAdministerMappingMapper.selectOne(new QueryWrapper()
+// .lambda()
+// .eq(RoleAdministerMappingDO::getAdministerId, administerDO.getId()));
+// administerPermissionVO.setRole(roleAdministerMappingDO.getRoleId());
+
+// CompanyDictDO companyDictDO = companyDictMapper.selectById(administerDO.getCompanyId());
+// administerPermissionVO.setCompanyName(companyDictDO.getCompanyName());
+// administerPermissionVO.setShortName(companyDictDO.getShortName());
- CompanyDictDO companyDictDO = companyDictMapper.selectById(administerDO.getCompanyId());
- administerPermissionVO.setCompanyName(companyDictDO.getCompanyName());
- administerPermissionVO.setShortName(companyDictDO.getShortName());
+ administerPermissionVO.setRole(administerDO.getRole());
+ /**
+ * 所在公司
+ */
+ List getAllCompanyVOS = this.baseMapper.administerCompanys(administerDO.getId());
+ administerPermissionVO.setGetAllCompanyVOS(getAllCompanyVOS);
return administerPermissionVO;
}
- public IPage operators(OperatorsDTO operatorsDTO) {
+ public IPage operators(OperatorsDTO operatorsDTO) {
Page pager = new Page(operatorsDTO.getPageNum(), operatorsDTO.getPageSize());
- IPage operatorsVOIPage = this.baseMapper.operators(pager, operatorsDTO.getUserName());
+ IPage administerVOIPage = this.baseMapper.operators(pager, operatorsDTO.getUserName(), operatorsDTO.getCompanyName());
- List operatorsVOS = operatorsVOIPage.getRecords();
- for (OperatorsVO operatorsVO : operatorsVOS) {
- operatorsVO.setField(fieldDictMapper.queryCompanyFields(operatorsVO.getCompanyId()));
+ List administerVOS = administerVOIPage.getRecords();
+ for (AdministerVO administerVO : administerVOS) {
+ if (1 == administerVO.getRole() || 3 == administerVO.getRole()) {
+ //所有公司
+ administerVO.setGetAllCompanyVOS(this.baseMapper.administerCompanys(administerVO.getId()));
+ }
+ if (0 == administerVO.getRole()) {
+ //所有服务
+ administerVO.setServiceDictDOS(serviceAdministerMappingMapper.administerService(administerVO.getId()));
+ }
}
- return operatorsVOIPage;
+ return administerVOIPage;
}
- public String addAdminister(AdministerDO administerDO) {
+ public String addAdminister(AddAdministerDTO addAdministerDTO) {
int count = this.baseMapper.selectCount(new QueryWrapper()
.lambda()
- .eq(AdministerDO::getAccountName, administerDO.getAccountName()));
+ .eq(AdministerDO::getAccountName, addAdministerDTO.getAccountName()));
- if (count > 0) {
+ int count1 = this.baseMapper.selectCount(new QueryWrapper()
+ .lambda()
+ .eq(AdministerDO::getTelephone, addAdministerDTO.getTelephone()));
+
+ if (count + count1 > 0) {
throw new HttpException(20002);
}
- //administerDO.setRole(0);
- administerDO.setPassword("admin123");
- administerDO.setStatus("1");
+ AdministerDO administerDO = new AdministerDO();
+ BeanUtils.copyProperties(addAdministerDTO, administerDO);
this.baseMapper.insert(administerDO);
- RoleAdministerMappingDO roleAdministerMappingDO = new RoleAdministerMappingDO();
- roleAdministerMappingDO.setAdministerId(administerDO.getId());
- roleAdministerMappingDO.setRoleId(1L);
- roleAdministerMappingMapper.insert(roleAdministerMappingDO);
+ if (null != addAdministerDTO.getCompanyIds()) {
+ List companyIds = addAdministerDTO.getCompanyIds();
+ for (Long companyId : companyIds) {
+ AdministerCompanyMappingDO administerCompanyMappingDO = new AdministerCompanyMappingDO();
+ administerCompanyMappingDO.setAdministerId(administerDO.getId());
+ administerCompanyMappingDO.setCompanyId(companyId);
+ administerCompanyMappingMapper.insert(administerCompanyMappingDO);
+ }
+ }
+
+ if (null != addAdministerDTO.getServiceIds()) {
+ List serviceIds = addAdministerDTO.getServiceIds();
+ for (Long service : serviceIds) {
+ ServiceAdministerMappingDO serviceAdministerMappingDO = new ServiceAdministerMappingDO();
+ serviceAdministerMappingDO.setAdministerId(administerDO.getId());
+ serviceAdministerMappingDO.setServiceId(service);
+ serviceAdministerMappingMapper.insert(serviceAdministerMappingDO);
+ }
+ }
return ConstantUtils.ADD_SUCCESS;
}
+ @Transactional(rollbackFor = Exception.class)
public String deleteAdminister(AdministerDO administerDO) {
this.baseMapper.deleteById(administerDO.getId());
- roleAdministerMappingMapper.delete(new QueryWrapper()
+ administerCompanyMappingMapper.delete(new QueryWrapper()
.lambda()
- .eq(RoleAdministerMappingDO::getAdministerId, administerDO.getId()));
+ .eq(AdministerCompanyMappingDO::getAdministerId, administerDO.getId()));
+
+ serviceAdministerMappingMapper.delete(new QueryWrapper()
+ .lambda()
+ .eq(ServiceAdministerMappingDO::getAdministerId, administerDO.getId()));
+
return ConstantUtils.DELETE_SUCCESS;
}
- public String updateAdminister(AdministerDO administerDO) {
+ public String updateAdminister(AddAdministerDTO addAdministerDTO) {
int count = this.baseMapper.selectCount(new QueryWrapper()
.lambda()
- .eq(AdministerDO::getAccountName, administerDO.getAccountName())
- .ne(AdministerDO::getId, administerDO.getId()));
+ .eq(AdministerDO::getAccountName, addAdministerDTO.getAccountName())
+ .ne(AdministerDO::getId, addAdministerDTO.getId()));
+
+ int count1 = this.baseMapper.selectCount(new QueryWrapper()
+ .lambda()
+ .eq(AdministerDO::getTelephone, addAdministerDTO.getTelephone())
+ .ne(AdministerDO::getId, addAdministerDTO.getId()));
- if (count > 0) {
+ if (count + count1 > 0) {
throw new HttpException(20002);
}
+ AdministerDO administerDO = this.baseMapper.selectById(addAdministerDTO.getId());
+ BeanUtils.copyProperties(addAdministerDTO, administerDO);
this.baseMapper.updateById(administerDO);
- AdministerDO administerDO1 = this.baseMapper.selectById(administerDO.getId());
- //更新redis里该老师的数据
- //redisUtil.set(RedisPrefixConstant.SUBSIDY_ADMINISTER_PREFIX + administerDO1.getAccountName(), administerDO1);
+
+ if (null != addAdministerDTO.getCompanyIds()) {
+
+ //
+ List oldIds = this.baseMapper.administerCompanyIds(addAdministerDTO.getId());
+ List newIds = addAdministerDTO.getCompanyIds();
+
+ List newCompanyIds2 = new ArrayList<>();
+ for (Long lg : newIds) {
+ newCompanyIds2.add(lg);
+ }
+
+ newIds.removeAll(oldIds); //
+ if (newIds.size() > 0) {
+ for (Long lg : newIds) {
+ AdministerCompanyMappingDO administerCompanyMappingDO = new AdministerCompanyMappingDO();
+ administerCompanyMappingDO.setAdministerId(addAdministerDTO.getId());
+ administerCompanyMappingDO.setCompanyId(lg);
+ administerCompanyMappingMapper.insert(administerCompanyMappingDO);
+ }
+ }
+
+ oldIds.removeAll(newCompanyIds2);
+ if (oldIds.size() > 0) {
+ for (Long lg : oldIds) {
+ administerCompanyMappingMapper.delete(new QueryWrapper()
+ .lambda()
+ .eq(AdministerCompanyMappingDO::getAdministerId, addAdministerDTO.getId())
+ .eq(AdministerCompanyMappingDO::getCompanyId, lg));
+ }
+ }
+ }
+
+ if (null != addAdministerDTO.getServiceIds()) {
+
+ //
+ List oldIds = this.baseMapper.administerServiceIds(addAdministerDTO.getId());
+ List newIds = addAdministerDTO.getServiceIds();
+
+ List newServices2 = new ArrayList<>();
+ for (Long lg : newIds) {
+ newServices2.add(lg);
+ }
+
+ newIds.removeAll(oldIds); //
+ if (newIds.size() > 0) {
+ for (Long lg : newIds) {
+ ServiceAdministerMappingDO serviceAdministerMappingDO = new ServiceAdministerMappingDO();
+ serviceAdministerMappingDO.setAdministerId(addAdministerDTO.getId());
+ serviceAdministerMappingDO.setServiceId(lg);
+ serviceAdministerMappingMapper.insert(serviceAdministerMappingDO);
+ }
+ }
+
+ oldIds.removeAll(newServices2);
+ if (oldIds.size() > 0) {
+ for (Long lg : oldIds) {
+ serviceAdministerMappingMapper.delete(new QueryWrapper()
+ .lambda()
+ .eq(ServiceAdministerMappingDO::getAdministerId, addAdministerDTO.getId())
+ .eq(ServiceAdministerMappingDO::getServiceId, lg));
+ }
+ }
+ }
+
return ConstantUtils.SET_SUCCESS;
}
@@ -1344,7 +1484,7 @@ public class AdministerServiceImpl extends ServiceImpl memberDOS = companyMemberMappingMapper.companyAccountMembers(companyId,accountName);
+ List memberDOS = companyMemberMappingMapper.companyAccountMembers(companyId, accountName);
if (memberDOS.size() > 0) {
String usernames = userName(accountName, 0, companyId);
@@ -1436,10 +1571,12 @@ public class AdministerServiceImpl extends ServiceImpl operators(OperatorsDTO operatorsDTO) {
Page pager = new Page(operatorsDTO.getPageNum(), operatorsDTO.getPageSize());
+ AdministerDO administerDO = administerMapper.selectById(operatorsDTO.getUserId());
- AdministerDO administerDO = administerMapper.selectById(operatorsDTO.getId());
-
- //判断该用户的角色
- Integer count = roleAdministerMappingMapper.selectCount(new QueryWrapper()
- .lambda()
- .eq(RoleAdministerMappingDO::getAdministerId, operatorsDTO.getId())
- .eq(RoleAdministerMappingDO::getRoleId, 1));
-
- if (count > 0) {
- administerDO.setCompanyId(null);
+ IPage page = null;
+ if (0 == administerDO.getRole()) {
+ page = this.baseMapper.allOperators(pager, operatorsDTO.getCompanyName(), operatorsDTO.getFieldId(), operatorsDTO.getSuperviseName());
+ } else if (1 == administerDO.getRole() || 3 == administerDO.getRole()) {
+ page = this.baseMapper.operators(pager, operatorsDTO.getUserId(), operatorsDTO.getCompanyName(), operatorsDTO.getFieldId(), operatorsDTO.getSuperviseName());
}
- IPage page = this.baseMapper.operators(pager, operatorsDTO.getCompanyName(), operatorsDTO.getFieldId(), administerDO.getCompanyId(), 2, operatorsDTO.getSuperviseName());
+
List operatorsVOS = page.getRecords();
for (OperatorsVO operatorsVO : operatorsVOS) {
+
//查看公司所在行业
List fieldDictDOS = fieldDictMapper.queryCompanyFields(operatorsVO.getCompanyId());
operatorsVO.setField(fieldDictDOS);
@@ -178,6 +179,11 @@ public class CompanyDictServiceImpl extends ServiceImpl getCompanyMembers(GetCompanyMembersDTO getCompanyMembersDTO) {
Page pager = new Page(getCompanyMembersDTO.getPageNum(), getCompanyMembersDTO.getPageSize());
- return this.baseMapper.getCompanyMembers(pager, getCompanyMembersDTO.getCompanyId(), getCompanyMembersDTO.getUserName(),getCompanyMembersDTO.getMemberStatus());
+
+ IPage companyMembersVOIPage = this.baseMapper.getCompanyMembers(pager, getCompanyMembersDTO.getCompanyId(), getCompanyMembersDTO.getUserName(), getCompanyMembersDTO.getMemberStatus());
+
+ List records = companyMembersVOIPage.getRecords();
+ for (GetCompanyMembersVO gcmv : records) {
+
+ //历史带过的企业
+ List memberCompanyVOS = companyMemberMappingMapper.memberCompanys(gcmv.getId());
+ gcmv.setMemberCompanyVOS(memberCompanyVOS);
+
+ }
+ return companyMembersVOIPage;
}
public void exportCompanyMembers(GetCompanyMembersDTO getCompanyMembersDTO) {
Page pager = new Page(1, -1);
- List getCompanyMembersVOS = this.baseMapper.getCompanyMembers(pager, getCompanyMembersDTO.getCompanyId(), getCompanyMembersDTO.getUserName(),getCompanyMembersDTO.getMemberStatus()).getRecords();
+ List getCompanyMembersVOS = this.baseMapper.getCompanyMembers(pager, getCompanyMembersDTO.getCompanyId(), getCompanyMembersDTO.getUserName(), getCompanyMembersDTO.getMemberStatus()).getRecords();
ExcelUtil.writeExcel(getCompanyMembersVOS, GetCompanyMembersVO.class);
}
diff --git a/src/main/java/com/subsidy/service/impl/CompanyMemberMappingServiceImpl.java b/src/main/java/com/subsidy/service/impl/CompanyMemberMappingServiceImpl.java
index 253da05..fc587a5 100644
--- a/src/main/java/com/subsidy/service/impl/CompanyMemberMappingServiceImpl.java
+++ b/src/main/java/com/subsidy/service/impl/CompanyMemberMappingServiceImpl.java
@@ -1,8 +1,12 @@
package com.subsidy.service.impl;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.subsidy.common.exception.HttpException;
+import com.subsidy.dto.company.AttendMembersDTO;
import com.subsidy.dto.member.CancerMemberDTO;
+import com.subsidy.dto.member.DepartMembersDTO;
import com.subsidy.dto.member.InviteMemberDTO;
import com.subsidy.mapper.MemberDepartmentMappingMapper;
import com.subsidy.mapper.MemberMapper;
@@ -13,10 +17,13 @@ import com.subsidy.model.MemberDepartmentMappingDO;
import com.subsidy.service.CompanyMemberMappingService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.subsidy.util.ConstantUtils;
+import com.subsidy.util.excel.ExcelUtil;
+import com.subsidy.vo.member.AttendMembersVO;
+import com.subsidy.vo.member.DepartMembersVO;
+import com.subsidy.vo.member.MemberAttendInfoVO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
-import java.util.ArrayList;
import java.util.List;
/**
@@ -56,7 +63,7 @@ public class CompanyMemberMappingServiceImpl extends ServiceImpl 0 ) {
+ if (count > 0) {
throw new HttpException(10028);
}
@@ -94,4 +101,25 @@ public class CompanyMemberMappingServiceImpl extends ServiceImpl departMembers(DepartMembersDTO departMembersDTO) {
+ Page pager = new Page(departMembersDTO.getPageNum(), departMembersDTO.getPageSize());
+ return this.baseMapper.departMembers(pager, departMembersDTO.getCompanyId(), departMembersDTO.getUserName());
+ }
+
+ public void exportDepartMembers(DepartMembersDTO departMembersDTO) {
+ Page pager = new Page(1, -1);
+ IPage departMembersVOIPage = this.baseMapper.departMembers(pager, departMembersDTO.getCompanyId(), departMembersDTO.getUserName());
+ List departMembersVOS = departMembersVOIPage.getRecords();
+ ExcelUtil.writeExcel(departMembersVOS, DepartMembersVO.class);
+ }
+
+ public IPage attendMembers(AttendMembersDTO attendMembersDTO) {
+ Page pager = new Page(attendMembersDTO.getPageNum(), attendMembersDTO.getPageSize());
+ return this.baseMapper.attendMembers(pager, attendMembersDTO.getCompanyId(), attendMembersDTO.getDepartmentId(), attendMembersDTO.getUserName());
+ }
+
+ public List memberAttendInfo(CompanyMemberMappingDO companyMemberMappingDO) {
+ return this.baseMapper.memberAttendInfo(companyMemberMappingDO.getMemberId(),companyMemberMappingDO.getCompanyId());
+ }
+
}
diff --git a/src/main/java/com/subsidy/service/impl/LiveDictServiceImpl.java b/src/main/java/com/subsidy/service/impl/LiveDictServiceImpl.java
index 9a0a4e5..b4f021b 100644
--- a/src/main/java/com/subsidy/service/impl/LiveDictServiceImpl.java
+++ b/src/main/java/com/subsidy/service/impl/LiveDictServiceImpl.java
@@ -7,7 +7,6 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.subsidy.common.configure.PolyvConfig;
import com.subsidy.dto.live.AddLiveDTO;
import com.subsidy.dto.live.AllLivesDTO;
-import com.subsidy.jobs.CourseNotificationJob;
import com.subsidy.jobs.LiveDictJob;
import com.subsidy.mapper.LiveClassesMapper;
import com.subsidy.mapper.LiveStudyHistoryMapper;
@@ -15,12 +14,10 @@ import com.subsidy.model.LiveClassesDO;
import com.subsidy.model.LiveDictDO;
import com.subsidy.mapper.LiveDictMapper;
import com.subsidy.model.LiveStudyHistoryDO;
-import com.subsidy.model.MemberDO;
import com.subsidy.service.LiveDictService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.subsidy.util.*;
import com.subsidy.vo.live.*;
-import net.polyv.common.v1.constant.Constant;
import net.polyv.live.v1.util.LiveSignUtil;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
diff --git a/src/main/java/com/subsidy/service/impl/LiveStudyHistoryServiceImpl.java b/src/main/java/com/subsidy/service/impl/LiveStudyHistoryServiceImpl.java
index 21d62bd..9042277 100644
--- a/src/main/java/com/subsidy/service/impl/LiveStudyHistoryServiceImpl.java
+++ b/src/main/java/com/subsidy/service/impl/LiveStudyHistoryServiceImpl.java
@@ -1,15 +1,11 @@
package com.subsidy.service.impl;
-import com.subsidy.common.configure.PolyvConfig;
import com.subsidy.dto.live.LiveSignDTO;
import com.subsidy.model.LiveStudyHistoryDO;
import com.subsidy.mapper.LiveStudyHistoryMapper;
-import com.subsidy.model.MemberDO;
import com.subsidy.service.LiveStudyHistoryService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
-import com.subsidy.util.ConstantUtils;
import com.subsidy.util.PolyvUtils;
-import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
/**
diff --git a/src/main/java/com/subsidy/service/impl/MemberServiceImpl.java b/src/main/java/com/subsidy/service/impl/MemberServiceImpl.java
index 70f03b0..2b7e66d 100644
--- a/src/main/java/com/subsidy/service/impl/MemberServiceImpl.java
+++ b/src/main/java/com/subsidy/service/impl/MemberServiceImpl.java
@@ -14,6 +14,7 @@ import com.subsidy.mapper.*;
import com.subsidy.model.*;
import com.subsidy.service.MemberService;
import com.subsidy.util.*;
+import com.subsidy.util.excel.ExcelUtil;
import com.subsidy.vo.administer.UserRoleVO;
import com.subsidy.vo.live.MemberLivesVO;
import com.subsidy.vo.live.PolyvInfoVO;
@@ -154,6 +155,23 @@ public class MemberServiceImpl extends ServiceImpl imple
return iPage;
}
+ public void exportAllMembers(GetAllDTO getAllDTO) {
+
+ Page pager = new Page(1, -1);
+
+ DepartmentDictDO departmentDictDO = departmentDictMapper.selectById(getAllDTO.getDepartmentId());
+
+ IPage iPage = null;
+
+ if (null != departmentDictDO.getParentId()) {
+ iPage = this.baseMapper.getMembers(pager, getAllDTO.getDepartmentId(), getAllDTO.getUserName(), getAllDTO.getStatus(), getAllDTO.getStartDate(), getAllDTO.getEndDate());
+ } else {
+ iPage = this.baseMapper.getCompanyMember(pager, departmentDictDO.getCompanyId(), getAllDTO.getUserName(), getAllDTO.getStatus(), getAllDTO.getStartDate(), getAllDTO.getEndDate());
+ }
+ List getAllVOS = iPage.getRecords();
+ ExcelUtil.writeExcel(getAllVOS, GetAllVO.class);
+ }
+
@Transactional(rollbackFor = Exception.class)
public String deleteMember(MemberDO memberDO) {
@@ -185,7 +203,7 @@ public class MemberServiceImpl extends ServiceImpl imple
throw new HttpException(20002);
}
- List memberDOS = companyMemberMappingMapper.companyAccountMembers(addMemberDTO.getCompanyId(),addMemberDTO.getAccountName());
+ List memberDOS = companyMemberMappingMapper.companyAccountMembers(addMemberDTO.getCompanyId(), addMemberDTO.getAccountName());
if (memberDOS.size() > 0) {
throw new HttpException(20002);
@@ -348,8 +366,8 @@ public class MemberServiceImpl extends ServiceImpl imple
public MemberVO passwordLogin(PasswordLoginDTO passwordLoginDTO, HttpServletRequest request) {
- List memberDOS = companyMemberMappingMapper.companyAccountMembers(passwordLoginDTO.getCompanyId(),passwordLoginDTO.getAccountName());
- if (memberDOS.size() == 0 ) {
+ List memberDOS = companyMemberMappingMapper.companyAccountMembers(passwordLoginDTO.getCompanyId(), passwordLoginDTO.getAccountName());
+ if (memberDOS.size() == 0) {
throw new HttpException(10017);
}
diff --git a/src/main/java/com/subsidy/service/impl/ProductDictServiceImpl.java b/src/main/java/com/subsidy/service/impl/ProductDictServiceImpl.java
new file mode 100644
index 0000000..3981bb8
--- /dev/null
+++ b/src/main/java/com/subsidy/service/impl/ProductDictServiceImpl.java
@@ -0,0 +1,53 @@
+package com.subsidy.service.impl;
+
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.subsidy.common.exception.HttpException;
+import com.subsidy.dto.product.AllProductsDTO;
+import com.subsidy.model.ProductDictDO;
+import com.subsidy.mapper.ProductDictMapper;
+import com.subsidy.service.ProductDictService;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import com.subsidy.util.ConstantUtils;
+import org.springframework.stereotype.Service;
+
+/**
+ *
+ * 产品管理字典表 服务实现类
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-08
+ */
+@Service
+public class ProductDictServiceImpl extends ServiceImpl implements ProductDictService {
+
+ public IPage allProducts(AllProductsDTO allProductsDTO) {
+ Page pager = new Page(allProductsDTO.getPageNum(), allProductsDTO.getPageSize());
+ return this.baseMapper.allProducts(pager, allProductsDTO.getProductName());
+ }
+
+ public String addProduct(ProductDictDO productDictDO) {
+ int count = this.baseMapper.selectCount(new QueryWrapper()
+ .lambda()
+ .eq(ProductDictDO::getProductName, productDictDO.getProductName()));
+
+ if (count > 0) {
+ throw new HttpException(30002);
+ }
+ this.baseMapper.insert(productDictDO);
+ return ConstantUtils.ADD_SUCCESS;
+ }
+
+ public String deleteProduct(ProductDictDO productDictDO) {
+ this.baseMapper.deleteById(productDictDO.getId());
+ return ConstantUtils.DELETE_SUCCESS;
+ }
+
+ public String updateProduct(ProductDictDO productDictDO) {
+ this.baseMapper.updateById(productDictDO);
+ return ConstantUtils.SUCCESS_UPDATE;
+ }
+
+}
diff --git a/src/main/java/com/subsidy/service/impl/RankDictServiceImpl.java b/src/main/java/com/subsidy/service/impl/RankDictServiceImpl.java
index e06df23..7e5137a 100644
--- a/src/main/java/com/subsidy/service/impl/RankDictServiceImpl.java
+++ b/src/main/java/com/subsidy/service/impl/RankDictServiceImpl.java
@@ -28,7 +28,7 @@ public class RankDictServiceImpl extends ServiceImpl
int count = this.baseMapper.selectCount(new QueryWrapper()
.lambda()
.eq(RankDictDO::getCompanyId, rankDictDO.getCompanyId())
- .eq(RankDictDO::getRank, rankDictDO.getRank()));
+ .eq(RankDictDO::getRankLevel, rankDictDO.getRankLevel()));
if (count > 0) {
throw new HttpException(12001);
}
@@ -46,7 +46,7 @@ public class RankDictServiceImpl extends ServiceImpl
int count = this.baseMapper.selectCount(new QueryWrapper()
.lambda()
.eq(RankDictDO::getCompanyId, rankDictDO.getCompanyId())
- .eq(RankDictDO::getRank, rankDictDO.getRank())
+ .eq(RankDictDO::getRankLevel, rankDictDO.getRankLevel())
.ne(RankDictDO::getId, rankDictDO.getId()));
if (count > 0) {
throw new HttpException(12001);
diff --git a/src/main/java/com/subsidy/service/impl/RenSheJuServiceImpl.java b/src/main/java/com/subsidy/service/impl/RenSheJuServiceImpl.java
index 3b55b2e..89c9b2a 100644
--- a/src/main/java/com/subsidy/service/impl/RenSheJuServiceImpl.java
+++ b/src/main/java/com/subsidy/service/impl/RenSheJuServiceImpl.java
@@ -57,26 +57,24 @@ public class RenSheJuServiceImpl implements RenSheJuService {
//查找前一天产生数据的班级
-// //看视频
-// List vodClassIds = renSheJuMapper.vodClassIds("0");
-//
-// //考试
-// List examClassIds = renSheJuMapper.examClassIds("0");
-//
-// //答疑
-// List answerClassIds = renSheJuMapper.answerClassIds("0");
-//
-// //人脸识别
-// List imageClassIds = renSheJuMapper.imageClassIds("0");
+ //看视频
+ List vodClassIds = renSheJuMapper.vodClassIds("0");
- Set classIds = new HashSet<>();
+ //考试
+ List examClassIds = renSheJuMapper.examClassIds("0");
-// vodClassIds.stream().forEach(x -> classIds.add(x));
-// examClassIds.stream().forEach(x -> classIds.add(x));
-// answerClassIds.stream().forEach(x -> classIds.add(x));
-// imageClassIds.stream().forEach(x -> classIds.add(x));
+ //答疑
+ List answerClassIds = renSheJuMapper.answerClassIds("0");
- classIds.add(473L);
+ //人脸识别
+ List imageClassIds = renSheJuMapper.imageClassIds("0");
+
+ Set classIds = new HashSet<>();
+
+ vodClassIds.stream().forEach(x -> classIds.add(x));
+ examClassIds.stream().forEach(x -> classIds.add(x));
+ answerClassIds.stream().forEach(x -> classIds.add(x));
+ imageClassIds.stream().forEach(x -> classIds.add(x));
try {
if (classIds.size() > 0) {
@@ -161,13 +159,10 @@ public class RenSheJuServiceImpl implements RenSheJuService {
List classHourBasics = new ArrayList<>();
// 产生视频学习数据的班级
-// List vodClassIds = renSheJuMapper.vodClassIds("0");
+ List vodClassIds = renSheJuMapper.vodClassIds("0");
List result = new ArrayList<>();
- List vodClassIds = new ArrayList<>();
- vodClassIds.add(473L);
-
try {
for (Long classId : vodClassIds) {
//产生数据的班级
@@ -284,9 +279,6 @@ public class RenSheJuServiceImpl implements RenSheJuService {
//找出前一天产生考试数据的班级
List classIds = renSheJuMapper.dailyExamBasic("0");
-// List classIds = new ArrayList<>();
-// classIds.add(439L);
-
try {
if (classIds.size() > 0) {
for (Long classId : classIds) {
diff --git a/src/main/java/com/subsidy/service/impl/ServiceAdministerMappingServiceImpl.java b/src/main/java/com/subsidy/service/impl/ServiceAdministerMappingServiceImpl.java
new file mode 100644
index 0000000..64f9d6c
--- /dev/null
+++ b/src/main/java/com/subsidy/service/impl/ServiceAdministerMappingServiceImpl.java
@@ -0,0 +1,27 @@
+package com.subsidy.service.impl;
+
+import com.subsidy.model.ServiceAdministerMappingDO;
+import com.subsidy.mapper.ServiceAdministerMappingMapper;
+import com.subsidy.model.ServiceDictDO;
+import com.subsidy.service.ServiceAdministerMappingService;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+/**
+ *
+ * 应用账户-服务映射表 服务实现类
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-08
+ */
+@Service
+public class ServiceAdministerMappingServiceImpl extends ServiceImpl implements ServiceAdministerMappingService {
+
+ public List administerServices(ServiceAdministerMappingDO serviceAdministerMappingDO) {
+ return this.baseMapper.administerService(serviceAdministerMappingDO.getAdministerId());
+ }
+
+}
diff --git a/src/main/java/com/subsidy/service/impl/ServiceCompanyFilesServiceImpl.java b/src/main/java/com/subsidy/service/impl/ServiceCompanyFilesServiceImpl.java
new file mode 100644
index 0000000..d45ef56
--- /dev/null
+++ b/src/main/java/com/subsidy/service/impl/ServiceCompanyFilesServiceImpl.java
@@ -0,0 +1,38 @@
+package com.subsidy.service.impl;
+
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.subsidy.model.ServiceCompanyFilesDO;
+import com.subsidy.mapper.ServiceCompanyFilesMapper;
+import com.subsidy.service.ServiceCompanyFilesService;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import com.subsidy.util.ConstantUtils;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+/**
+ *
+ * 服务实现类
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-05
+ */
+@Service
+public class ServiceCompanyFilesServiceImpl extends ServiceImpl implements ServiceCompanyFilesService {
+
+ public List companyFiles(ServiceCompanyFilesDO serviceCompanyFilesDO) {
+ return this.baseMapper.companyFiles(serviceCompanyFilesDO.getServiceCompanyId(), serviceCompanyFilesDO.getFileName());
+ }
+
+ public String deleteFile(ServiceCompanyFilesDO serviceCompanyFilesDO) {
+ this.baseMapper.deleteById(serviceCompanyFilesDO.getId());
+ return ConstantUtils.DELETE_SUCCESS;
+ }
+
+ public String uploadFile(ServiceCompanyFilesDO serviceCompanyFilesDO) {
+ this.baseMapper.insert(serviceCompanyFilesDO);
+ return ConstantUtils.ADD_SUCCESS;
+ }
+
+}
diff --git a/src/main/java/com/subsidy/service/impl/ServiceCompanyMappingServiceImpl.java b/src/main/java/com/subsidy/service/impl/ServiceCompanyMappingServiceImpl.java
new file mode 100644
index 0000000..72bdefb
--- /dev/null
+++ b/src/main/java/com/subsidy/service/impl/ServiceCompanyMappingServiceImpl.java
@@ -0,0 +1,65 @@
+package com.subsidy.service.impl;
+
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.subsidy.dto.service.CancelAuthDTO;
+import com.subsidy.dto.service.GetServiceCompaniesDTO;
+import com.subsidy.model.CompanyDictDO;
+import com.subsidy.model.ServiceCompanyMappingDO;
+import com.subsidy.mapper.ServiceCompanyMappingMapper;
+import com.subsidy.service.ServiceCompanyMappingService;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import com.subsidy.util.ConstantUtils;
+import com.subsidy.vo.service.GetServiceCompaniesVO;
+import com.subsidy.vo.service.ServiceCompaniesVO;
+import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
+
+import java.util.List;
+
+/**
+ *
+ * 业务公司 映射表 服务实现类
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-05
+ */
+@Service
+public class ServiceCompanyMappingServiceImpl extends ServiceImpl implements ServiceCompanyMappingService {
+
+ public IPage getServiceCompanies(GetServiceCompaniesDTO getServiceCompaniesDTO) {
+ Page pager = new Page(getServiceCompaniesDTO.getPageNum(), getServiceCompaniesDTO.getPageSize());
+ return this.baseMapper.getServiceCompanies(pager, getServiceCompaniesDTO.getServiceId(), getServiceCompaniesDTO.getCompanyName(), getServiceCompaniesDTO.getAuthStatus());
+ }
+
+ @Transactional(rollbackFor = Exception.class)
+ public String cancelAuth(CancelAuthDTO cancelAuthDTO) {
+ List companyIds = cancelAuthDTO.getCompanyIds();
+ for (Long companyId : companyIds) {
+ this.baseMapper.delete(new QueryWrapper()
+ .lambda()
+ .eq(ServiceCompanyMappingDO::getCompanyId, companyId)
+ .eq(ServiceCompanyMappingDO::getServiceId, cancelAuthDTO.getServiceId()));
+ }
+ return ConstantUtils.DELETE_SUCCESS;
+ }
+
+ @Transactional(rollbackFor = Exception.class)
+ public String addAuth(CancelAuthDTO cancelAuthDTO) {
+ List companyIds = cancelAuthDTO.getCompanyIds();
+ for (Long companyId : companyIds) {
+ ServiceCompanyMappingDO serviceCompanyMappingDO = new ServiceCompanyMappingDO();
+ serviceCompanyMappingDO.setCompanyId(companyId);
+ serviceCompanyMappingDO.setServiceId(cancelAuthDTO.getServiceId());
+ this.baseMapper.insert(serviceCompanyMappingDO);
+ }
+ return ConstantUtils.ADD_SUCCESS;
+ }
+
+ public List serviceCompanies(GetServiceCompaniesDTO getServiceCompaniesDTO) {
+ return this.baseMapper.serviceCompanies(getServiceCompaniesDTO.getServiceId(),getServiceCompaniesDTO.getCompanyName());
+ }
+
+}
diff --git a/src/main/java/com/subsidy/service/impl/ServiceDictServiceImpl.java b/src/main/java/com/subsidy/service/impl/ServiceDictServiceImpl.java
new file mode 100644
index 0000000..22f6fb9
--- /dev/null
+++ b/src/main/java/com/subsidy/service/impl/ServiceDictServiceImpl.java
@@ -0,0 +1,26 @@
+package com.subsidy.service.impl;
+
+import com.subsidy.model.ServiceDictDO;
+import com.subsidy.mapper.ServiceDictMapper;
+import com.subsidy.service.ServiceDictService;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+/**
+ *
+ * 业务管理字典表 服务实现类
+ *
+ *
+ * @author Tuyp
+ * @since 2024-01-05
+ */
+@Service
+public class ServiceDictServiceImpl extends ServiceImpl implements ServiceDictService {
+
+ public List getAllServices(){
+ return this.baseMapper.selectList(null);
+ }
+
+}
diff --git a/src/main/java/com/subsidy/vo/administer/AdministerPermissionVO.java b/src/main/java/com/subsidy/vo/administer/AdministerPermissionVO.java
index 9c50ed2..bb42438 100644
--- a/src/main/java/com/subsidy/vo/administer/AdministerPermissionVO.java
+++ b/src/main/java/com/subsidy/vo/administer/AdministerPermissionVO.java
@@ -1,5 +1,6 @@
package com.subsidy.vo.administer;
+import com.subsidy.vo.company.GetAllCompanyVO;
import lombok.Data;
import java.util.List;
@@ -11,7 +12,7 @@ public class AdministerPermissionVO {
private String userName;
- private Long role;
+ private Integer role;
private String img;
@@ -22,4 +23,6 @@ public class AdministerPermissionVO {
private String shortName;
private List permissions;
+
+ private List getAllCompanyVOS;
}
diff --git a/src/main/java/com/subsidy/vo/administer/AdministerVO.java b/src/main/java/com/subsidy/vo/administer/AdministerVO.java
new file mode 100644
index 0000000..cddf585
--- /dev/null
+++ b/src/main/java/com/subsidy/vo/administer/AdministerVO.java
@@ -0,0 +1,28 @@
+package com.subsidy.vo.administer;
+
+import com.subsidy.model.ServiceDictDO;
+import com.subsidy.vo.company.GetAllCompanyVO;
+import lombok.Data;
+
+import java.util.List;
+
+@Data
+public class AdministerVO {
+
+ private Long id;
+
+ private String userName;
+
+ private String password;
+
+ private String telephone;
+
+ private String remark;
+
+ private Integer role;
+
+ private List getAllCompanyVOS;
+
+ private List serviceDictDOS;
+
+}
diff --git a/src/main/java/com/subsidy/vo/company/GetCompanyMembersVO.java b/src/main/java/com/subsidy/vo/company/GetCompanyMembersVO.java
index 0f062d8..f45058c 100644
--- a/src/main/java/com/subsidy/vo/company/GetCompanyMembersVO.java
+++ b/src/main/java/com/subsidy/vo/company/GetCompanyMembersVO.java
@@ -1,8 +1,11 @@
package com.subsidy.vo.company;
import com.subsidy.util.excel.ExcelColumn;
+import com.subsidy.vo.member.MemberCompanyVO;
import lombok.Data;
+import java.util.List;
+
@Data
public class GetCompanyMembersVO {
@@ -38,5 +41,6 @@ public class GetCompanyMembersVO {
private String memberStatus;
+ private List memberCompanyVOS;
}
diff --git a/src/main/java/com/subsidy/vo/member/AttendMembersVO.java b/src/main/java/com/subsidy/vo/member/AttendMembersVO.java
new file mode 100644
index 0000000..46f953b
--- /dev/null
+++ b/src/main/java/com/subsidy/vo/member/AttendMembersVO.java
@@ -0,0 +1,25 @@
+package com.subsidy.vo.member;
+
+import lombok.Data;
+
+@Data
+public class AttendMembersVO {
+
+ private Long id;
+
+ private String userName;
+
+ private String accountNameEn;
+
+ private String accountName;
+
+ private String gender;
+
+ private String telephone;
+
+ private String idCard;
+
+ private String email;
+
+
+}
diff --git a/src/main/java/com/subsidy/vo/member/DepartMembersVO.java b/src/main/java/com/subsidy/vo/member/DepartMembersVO.java
new file mode 100644
index 0000000..c227858
--- /dev/null
+++ b/src/main/java/com/subsidy/vo/member/DepartMembersVO.java
@@ -0,0 +1,32 @@
+package com.subsidy.vo.member;
+
+import com.subsidy.util.excel.ExcelColumn;
+import lombok.Data;
+
+@Data
+public class DepartMembersVO {
+
+ @ExcelColumn(value = "姓名", col = 1)
+ private String userName;
+
+ @ExcelColumn(value = "手机号", col = 2)
+ private String telephone;
+
+ @ExcelColumn(value = "身份证号", col = 3)
+ private String idCard;
+
+ @ExcelColumn(value = "性别", col = 4)
+ private String gender;
+
+ @ExcelColumn(value = "邮件", col = 5)
+ private String email;
+
+ @ExcelColumn(value = "QQ号", col = 6)
+ private String qqNo;
+
+ @ExcelColumn(value = "微信号", col = 7)
+ private String wechat;
+
+ @ExcelColumn(value = "离职时间", col = 8)
+ private String createDate;
+}
diff --git a/src/main/java/com/subsidy/vo/member/GetAllVO.java b/src/main/java/com/subsidy/vo/member/GetAllVO.java
index 712e9b1..87c8d11 100644
--- a/src/main/java/com/subsidy/vo/member/GetAllVO.java
+++ b/src/main/java/com/subsidy/vo/member/GetAllVO.java
@@ -6,6 +6,7 @@ import com.fasterxml.jackson.annotation.JsonFormat;
import com.subsidy.model.DepartmentDictDO;
import com.subsidy.model.JobDictDO;
import com.subsidy.model.MemberDO;
+import com.subsidy.util.excel.ExcelColumn;
import lombok.Data;
import java.util.Date;
@@ -16,18 +17,25 @@ public class GetAllVO {
private Long id;
+ @ExcelColumn(value = "账号", col = 5)
private String accountName;
+ @ExcelColumn(value = "英文名", col = 2)
private String accountNameEn;
+ @ExcelColumn(value = "姓名", col = 1)
private String userName;
+ @ExcelColumn(value = "手机号", col = 6)
private String telephone;
+ @ExcelColumn(value = "性别", col = 4)
private String gender;
+ @ExcelColumn(value = "身份证号码", col = 7)
private String idCard;
+ @ExcelColumn(value = "账号状态", col = 3)
private String status;
private String email;
diff --git a/src/main/java/com/subsidy/vo/member/MemberAttendInfoVO.java b/src/main/java/com/subsidy/vo/member/MemberAttendInfoVO.java
new file mode 100644
index 0000000..89dedff
--- /dev/null
+++ b/src/main/java/com/subsidy/vo/member/MemberAttendInfoVO.java
@@ -0,0 +1,14 @@
+package com.subsidy.vo.member;
+
+import lombok.Data;
+
+@Data
+public class MemberAttendInfoVO {
+
+ private Long id;
+
+ private String className;
+
+ private String createDate;
+
+}
diff --git a/src/main/java/com/subsidy/vo/member/MemberCompanyVO.java b/src/main/java/com/subsidy/vo/member/MemberCompanyVO.java
new file mode 100644
index 0000000..6623173
--- /dev/null
+++ b/src/main/java/com/subsidy/vo/member/MemberCompanyVO.java
@@ -0,0 +1,14 @@
+package com.subsidy.vo.member;
+
+import lombok.Data;
+
+@Data
+public class MemberCompanyVO {
+
+ private Long companyId;
+
+ private String companyName;
+
+ private String createDate;
+
+}
diff --git a/src/main/java/com/subsidy/vo/service/GetServiceCompaniesVO.java b/src/main/java/com/subsidy/vo/service/GetServiceCompaniesVO.java
new file mode 100644
index 0000000..7e3e031
--- /dev/null
+++ b/src/main/java/com/subsidy/vo/service/GetServiceCompaniesVO.java
@@ -0,0 +1,20 @@
+package com.subsidy.vo.service;
+
+import lombok.Data;
+
+@Data
+public class GetServiceCompaniesVO {
+
+ private Long id;
+
+ private String companyName;
+
+ private String shortName;
+
+ private String areaName;
+
+ private String superviseName;
+
+ private String authStatus;
+
+}
diff --git a/src/main/java/com/subsidy/vo/service/ServiceCompaniesVO.java b/src/main/java/com/subsidy/vo/service/ServiceCompaniesVO.java
new file mode 100644
index 0000000..98d09cb
--- /dev/null
+++ b/src/main/java/com/subsidy/vo/service/ServiceCompaniesVO.java
@@ -0,0 +1,12 @@
+package com.subsidy.vo.service;
+
+import lombok.Data;
+
+@Data
+public class ServiceCompaniesVO {
+
+ private Long id;
+
+ private String companyName;
+
+}
diff --git a/src/main/resources/code.properties b/src/main/resources/code.properties
index 5830f37..9ce8341 100644
--- a/src/main/resources/code.properties
+++ b/src/main/resources/code.properties
@@ -76,4 +76,6 @@ meishu.code-message[18001]=已超过当日验证次数上线
meishu.code-message[19001]=验证失败
-meishu.code-message[20003]=提交时间过短,请稍后尝试
\ No newline at end of file
+meishu.code-message[20003]=提交时间过短,请稍后尝试
+
+meishu.code-message[30002]=该产品已存在
\ No newline at end of file
diff --git a/src/main/resources/mapper/AdministerCompanyMappingMapper.xml b/src/main/resources/mapper/AdministerCompanyMappingMapper.xml
new file mode 100644
index 0000000..a1aeb8b
--- /dev/null
+++ b/src/main/resources/mapper/AdministerCompanyMappingMapper.xml
@@ -0,0 +1,23 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ create_date,
+ update_date,
+ delete_date,
+ id, administer_id, company_id
+
+
+
diff --git a/src/main/resources/mapper/AdministerMapper.xml b/src/main/resources/mapper/AdministerMapper.xml
index 71611c7..8af8de4 100644
--- a/src/main/resources/mapper/AdministerMapper.xml
+++ b/src/main/resources/mapper/AdministerMapper.xml
@@ -221,18 +221,27 @@
order by t6.account_name ASC
-
+
+ SELECT
+ t2.id,
+ t2.company_name
+ FROM
+ administer_company_mapping t
+ LEFT JOIN company_dict t2 ON t.company_id = t2.id
+ WHERE
+ t.delete_date IS NULL
+ AND t2.delete_date IS NULL
+ AND t.administer_id = #{administerId}
+
+
+
+ SELECT
+ t2.id
+ FROM
+ administer_company_mapping t
+ LEFT JOIN company_dict t2 ON t.company_id = t2.id
+ WHERE
+ t.delete_date IS NULL
+ AND t2.delete_date IS NULL
+ AND t.administer_id = #{administerId}
+
+
+
+ SELECT
+ t2.id
+ FROM
+ service_administer_mapping t
+ LEFT JOIN service_dict t2 ON t.service_id = t2.id
+ WHERE
+ t.delete_date IS NULL
+ AND t2.delete_date IS NULL
+ AND t.administer_id = #{administerId}
+
+
diff --git a/src/main/resources/mapper/CompanyDictMapper.xml b/src/main/resources/mapper/CompanyDictMapper.xml
index 1115f22..dff5629 100644
--- a/src/main/resources/mapper/CompanyDictMapper.xml
+++ b/src/main/resources/mapper/CompanyDictMapper.xml
@@ -2,70 +2,79 @@
-
-
-
-
-
-
-
-
-
-
- create_date,
- update_date,
- delete_date,
- id, company_name
-
+
+ SELECT
+ distinct
+ t2.id as companyId,
+ t2.banner,
+ t2.short_name,
+ t2.company_name,
+ t2.logo,
+ t2.address,
+ t2.supervise_name,
+ t2.company_code,
+ t2.area_name
+ FROM
+ company_dict t2
+ left join company_field_mapping t3 on t2.id = t3.company_id
+ left join service_company_mapping t4 on t2.id = t4.company_id
+ WHERE
+ t2.delete_date is null
+ and t3.delete_date is null
+ and service_id = 1
+ and t4.delete_date is null
+
+ and t2.company_name like concat('%',#{companyName} ,'%')
+
+
+ and t3.field_id = #{fieldId}
+
+
+ and t2.supervise_name =#{superviseName}
+
+
SELECT
- distinct t.id,
- t2.id as companyId,
- t.telephone,
- t.user_name,
- t2.banner,
- t2.short_name,
- t.account_name,
- t.img,
- t2.company_name,
- t2.logo,
- t2.address,
- t2.supervise_name,
- t2.company_code,
- t2.area_name
+ distinct
+ t2.id as companyId,
+ t2.banner,
+ t2.short_name,
+ t2.company_name,
+ t2.logo,
+ t2.address,
+ t2.supervise_name,
+ t2.company_code,
+ t2.area_name
FROM
- administer t
- left join role_administer_mapping t4 on t.id = t4.administer_id
- left join company_dict t2 on t.company_id = t2.id
- left join company_field_mapping t3 on t2.id = t3.company_id
+ company_dict t2
+ left join administer_company_mapping t4 on t2.id = t4.company_id
+ left join company_field_mapping t3 on t2.id = t3.company_id
+ left join service_company_mapping t5 on t2.id = t5.company_id
WHERE
- t.delete_date IS NULL
- and t2.delete_date is null
- and t3.delete_date is null
-
- and t4.role_id in (1,3)
-
-
- and t4.role_id = 2
-
-
- and t2.id = #{id}
-
-
- and t2.company_name like concat('%',#{companyName} ,'%')
-
-
- and t3.field_id = #{fieldId}
-
-
- and t2.supervise_name =#{superviseName}
-
-
+ t2.delete_date is null
+ and t3.delete_date is null
+ and t4.delete_date is null
+ and t5.service_id = 1
+ and t5.delete_date is null
+
+ and t2.company_name like concat('%',#{companyName} ,'%')
+
+
+ and t3.field_id = #{fieldId}
+
+
+ and t2.supervise_name =#{superviseName}
+
+
+ and t4.administer_id =#{userId}
+
+
+
-
+
SELECT
t.id,
t.company_name
diff --git a/src/main/resources/mapper/CompanyMemberMappingMapper.xml b/src/main/resources/mapper/CompanyMemberMappingMapper.xml
index d756723..351e7be 100644
--- a/src/main/resources/mapper/CompanyMemberMappingMapper.xml
+++ b/src/main/resources/mapper/CompanyMemberMappingMapper.xml
@@ -76,4 +76,93 @@
AND t.member_status = 1
+
+ SELECT
+ t.company_id,
+ t2.company_name,
+ t.create_date
+ FROM
+ company_member_mapping t
+ LEFT JOIN company_dict t2 ON t.company_id = t2.id
+ WHERE
+ t.delete_date IS NULL
+ AND t2.delete_date IS NULL
+ AND t.member_id =#{memberId}
+ order by t.create_date desc,t.id desc
+
+
+
+ SELECT
+ t2.user_name,
+ t2.telephone,
+ t2.id_card,
+ t2.gender,
+ t2.email,
+ t2.qq_no,
+ t2.wechat,
+ t.create_date
+ FROM
+ company_member_mapping t
+ LEFT JOIN member t2 ON t.member_id = t2.id
+ WHERE
+ t.delete_date IS NULL
+ AND t2.delete_date IS NULL
+ AND t.company_id = #{companyId}
+
+ and ( t2.user_name like concat('%',#{userName} ,'%')
+ or t2.id_card like concat('%',#{userName} ,'%')
+ or t2.telephone like concat('%',#{userName} ,'%'))
+
+ and t.member_status = 0
+ order by t.id desc
+
+
+
+ SELECT DISTINCT
+ t1.id,
+ t1.user_name,
+ t1.account_name_en,
+ t1.account_name,
+ t1.gender,
+ t1.telephone,
+ t1.id_card,
+ t1.email
+ FROM
+ member t1
+ LEFT JOIN company_member_mapping t3 ON t1.id = t3.member_id
+ LEFT JOIN class_member_mapping t2 ON t1.id = t2.member_id
+ LEFT JOIN member_department_mapping t4 ON t1.id = t4.member_id
+ WHERE
+ t1.delete_date IS NULL
+ AND t2.delete_date IS NULL
+ AND t3.delete_date IS NULL
+ AND t4.delete_date IS NULL
+ AND t3.member_status = 1
+ AND t2.id IS NOT NULL
+ AND t3.company_id = #{companyId}
+ AND t4.member_status = 1
+ AND t4.department_id = #{departmentId}
+
+ and ( t1.user_name like concat('%',#{userName} ,'%')
+ or t1.id_card like concat('%',#{userName} ,'%')
+ or t1.telephone like concat('%',#{userName} ,'%'))
+
+
+
+
+ SELECT
+ t2.id,
+ t2.class_name,
+ t.create_date
+ FROM
+ class_member_mapping t
+ LEFT JOIN class_dict t2 ON t.class_id = t2.id
+ WHERE
+ t.delete_date IS NULL
+ AND t2.delete_date IS NULL
+ AND t.member_id = #{memberId}
+ AND t2.company_id = #{companyId}
+ order by t.create_date desc
+
+
diff --git a/src/main/resources/mapper/ProductDictMapper.xml b/src/main/resources/mapper/ProductDictMapper.xml
new file mode 100644
index 0000000..19d5f5b
--- /dev/null
+++ b/src/main/resources/mapper/ProductDictMapper.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+ SELECT
+ *
+ FROM
+ product_dict t
+ WHERE
+ t.delete_date IS NULL
+ AND t.product_name like concat('%',#{productName} ,'%')
+
+
+
diff --git a/src/main/resources/mapper/ServiceAdministerMappingMapper.xml b/src/main/resources/mapper/ServiceAdministerMappingMapper.xml
new file mode 100644
index 0000000..5eeef76
--- /dev/null
+++ b/src/main/resources/mapper/ServiceAdministerMappingMapper.xml
@@ -0,0 +1,17 @@
+
+
+
+
+
+ SELECT
+ t2.*
+ FROM
+ service_administer_mapping t
+ LEFT JOIN service_dict t2 ON t.service_id = t2.id
+ WHERE
+ t.delete_date IS NULL
+ AND t2.delete_date IS NULL
+ AND t.administer_id = #{administerId}
+
+
+
diff --git a/src/main/resources/mapper/ServiceCompanyFilesMapper.xml b/src/main/resources/mapper/ServiceCompanyFilesMapper.xml
new file mode 100644
index 0000000..fab6952
--- /dev/null
+++ b/src/main/resources/mapper/ServiceCompanyFilesMapper.xml
@@ -0,0 +1,18 @@
+
+
+
+
+
+ SELECT
+ *
+ FROM
+ service_company_files t
+ WHERE
+ t.delete_date IS NULL
+ AND t.service_company_id = #{serviceCompanyId}
+
+ AND t.file_name like concat('%',#{fileName} ,'%')
+
+
+
+
diff --git a/src/main/resources/mapper/ServiceCompanyMappingMapper.xml b/src/main/resources/mapper/ServiceCompanyMappingMapper.xml
new file mode 100644
index 0000000..5ff735a
--- /dev/null
+++ b/src/main/resources/mapper/ServiceCompanyMappingMapper.xml
@@ -0,0 +1,47 @@
+
+
+
+
+
+ SELECT
+ t2.id,
+ t2.company_name,
+ t2.short_name,
+ t2.area_name,
+ t2.supervise_name ,
+ IF(t.id=null,'授权','未授权') as authStatus
+ FROM
+ company_dict t2
+ LEFT JOIN service_company_mapping t ON t.company_id = t2.id
+ WHERE
+ t.delete_date IS NULL
+ AND t2.delete_date IS NULL
+ AND t.service_id = #{serviceId}
+
+ AND t2.company_name like concat('%',#{companyName} ,'%')
+
+
+ and t.id is not null
+
+
+ and t.id is null
+
+
+
+
+ SELECT
+ t2.id,
+ t2.company_name
+ FROM
+ service_company_mapping t
+ LEFT JOIN company_dict t2 ON t.company_id = t2.id
+ WHERE
+ t.delete_date IS NULL
+ AND t2.delete_date IS NULL
+ AND t.service_id = #{serviceId}
+
+ AND t2.company_name like concat('%',#{companyName} ,'%')
+
+
+
+
diff --git a/src/main/resources/mapper/ServiceDictMapper.xml b/src/main/resources/mapper/ServiceDictMapper.xml
new file mode 100644
index 0000000..b9d59dc
--- /dev/null
+++ b/src/main/resources/mapper/ServiceDictMapper.xml
@@ -0,0 +1,7 @@
+
+
+
+
+
+
+