diff --git a/src/main/java/com/zcloud/controller/bus/ClassMessageController.java b/src/main/java/com/zcloud/controller/bus/ClassMessageController.java new file mode 100644 index 00000000..d65f9341 --- /dev/null +++ b/src/main/java/com/zcloud/controller/bus/ClassMessageController.java @@ -0,0 +1,74 @@ +package com.zcloud.controller.bus; + +import com.alibaba.fastjson.JSONObject; +import com.zcloud.controller.base.BaseController; +import com.zcloud.entity.Page; +import com.zcloud.entity.PageData; +import com.zcloud.service.bus.ClassInfoService; +import com.zcloud.util.HttpClientService; +import com.zcloud.util.Tools; +import com.zcloud.util.Warden; +import org.apache.commons.lang3.StringUtils; +import org.apache.shiro.authz.annotation.RequiresPermissions; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.beans.factory.annotation.Value; +import org.springframework.stereotype.Controller; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RequestParam; +import org.springframework.web.bind.annotation.ResponseBody; +import org.springframework.web.multipart.MultipartFile; + +import javax.servlet.http.HttpServletResponse; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.stream.Collectors; + +/** + * 说明:开课信息 + * 作者:luoxiaobao + * 时间:2023-09-27 + * 官网:www.zcloudchina.com + */ +@Controller +@RequestMapping("/classMessage") +public class ClassMessageController extends BaseController { + + @Value("${preventionxgf.api.url}") + private String xgfUrl; + + private static int index = -1; + + + @Autowired + private ClassInfoService classInfoService; + + + @RequestMapping(value = "/getUserinfoList") + @ResponseBody + public Object getUserinfoList() throws Exception { + Map map = new HashMap<>(); + PageData condition = new PageData(); + PageData request = this.getPageData(); + condition.put("CLASS_MESSAGE_ID", request.getString("CLASS_MESSAGE_ID")); + condition.put("CLASS_INFO_ID", request.getString("CLASS_INFO_ID")); + condition.put("CER_TYPE", "7498057c4c1f4a11b9a960e66ea04a7a"); + List list = classInfoService.findinfoByCondition(condition); + map.put("list", list); + map.put("result", "success"); + return map; + } + + @RequestMapping(value = "/getClassinfo") + @ResponseBody + public Object getClassinfo() throws Exception { + Map map = new HashMap<>(); + PageData condition = new PageData(); + PageData request = this.getPageData(); + condition.put("TRAINUSERS_ID", request.getString("TRAINUSERS_ID")); + PageData entity = classInfoService.getClassinfo(condition); + map.put("pd", entity); + map.put("result", "success"); + return map; + } +} diff --git a/src/main/java/com/zcloud/mapper/dsno2/bus/ClassInfoMapper.java b/src/main/java/com/zcloud/mapper/dsno2/bus/ClassInfoMapper.java new file mode 100644 index 00000000..3cbca053 --- /dev/null +++ b/src/main/java/com/zcloud/mapper/dsno2/bus/ClassInfoMapper.java @@ -0,0 +1,34 @@ +package com.zcloud.mapper.dsno2.bus; + +import com.zcloud.entity.Page; +import com.zcloud.entity.PageData; + +import java.util.List; + +/** + * 说明:班级学员表 + * 作者:luoxiaobao + * 时间:2023-09-27 + * 官网:www.zcloudchina.com + */ +public interface ClassInfoMapper { + + + /**通过id获取数据 + * @param pd + * @throws Exception + */ + + PageData getClassinfo(PageData pd); + + /**批量删除 + * @param ArrayDATA_IDS + * @throws Exception + */ + + + List findinfoByCondition(PageData pd); + + +} + diff --git a/src/main/java/com/zcloud/service/bus/ClassInfoService.java b/src/main/java/com/zcloud/service/bus/ClassInfoService.java new file mode 100644 index 00000000..0ee34beb --- /dev/null +++ b/src/main/java/com/zcloud/service/bus/ClassInfoService.java @@ -0,0 +1,27 @@ +package com.zcloud.service.bus; + +import com.zcloud.entity.Page; +import com.zcloud.entity.PageData; + +import java.util.List; + +/** + * 说明:班级学员表 + * 作者:luoxiaobao + * 时间:2023-09-27 + * 官网:www.zcloudchina.com + */ +public interface ClassInfoService { + + + + public PageData getClassinfo(PageData pd)throws Exception; + + + List findinfoByCondition(PageData condition) throws Exception; + + + + +} + diff --git a/src/main/java/com/zcloud/service/bus/impl/ClassInfoServiceImpl.java b/src/main/java/com/zcloud/service/bus/impl/ClassInfoServiceImpl.java new file mode 100644 index 00000000..91b8e35c --- /dev/null +++ b/src/main/java/com/zcloud/service/bus/impl/ClassInfoServiceImpl.java @@ -0,0 +1,43 @@ +package com.zcloud.service.bus.impl; + +import com.zcloud.entity.Page; +import com.zcloud.entity.PageData; +import com.zcloud.mapper.dsno2.bus.ClassInfoMapper; +import com.zcloud.service.bus.ClassInfoService; +import com.zcloud.util.Warden; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; +import org.springframework.transaction.annotation.Transactional; + +import java.util.List; + +/** + * 说明:班级学员表 + * 作者:luoxiaobao + * 时间:2023-09-27 + * 官网:www.zcloudchina.com + */ +@Service +@Transactional //开启事物 +public class ClassInfoServiceImpl implements ClassInfoService { + + @Autowired + private ClassInfoMapper classInfoMapper; + + + + + public PageData getClassinfo(PageData pd)throws Exception{ + return classInfoMapper.getClassinfo(pd); + } + + + @Override + public List findinfoByCondition(PageData condition) throws Exception { + return classInfoMapper.findinfoByCondition(condition); + } + + + +} + diff --git a/src/main/java/com/zcloud/util/HiddenExcelImgToSessionView.java b/src/main/java/com/zcloud/util/HiddenExcelImgToSessionView.java index 52306ff6..15b510fd 100644 --- a/src/main/java/com/zcloud/util/HiddenExcelImgToSessionView.java +++ b/src/main/java/com/zcloud/util/HiddenExcelImgToSessionView.java @@ -34,9 +34,7 @@ import net.coobird.thumbnailator.Thumbnails; @Component public class HiddenExcelImgToSessionView extends AbstractXlsView{ - @Value("${http.file.url}") - private String fileUrl; - + private String fileUrl = "http://192.168.192.201:8991/file/"; @Override protected void buildExcelDocument(Map model, Workbook workbook, HttpServletRequest request, diff --git a/src/main/java/com/zcloud/util/HiddenExcelImgView.java b/src/main/java/com/zcloud/util/HiddenExcelImgView.java index a447a4bf..8b788f4b 100644 --- a/src/main/java/com/zcloud/util/HiddenExcelImgView.java +++ b/src/main/java/com/zcloud/util/HiddenExcelImgView.java @@ -38,8 +38,8 @@ import com.zcloud.entity.PageData; */ public class HiddenExcelImgView extends AbstractXlsView{ - @Value("${http.file.url}") - private String fileUrl; + + private String fileUrl = "http://192.168.192.201:8991/file/"; @Override protected void buildExcelDocument(Map model, diff --git a/src/main/resources/application-dev.properties b/src/main/resources/application-dev.properties index a4dd85c3..1db9c3fa 100644 --- a/src/main/resources/application-dev.properties +++ b/src/main/resources/application-dev.properties @@ -75,7 +75,7 @@ rocketmq.consumer.group2=edu-admin-edit rocketmq.consumer.group1=edu-admin-add #rocketmq.name-server=10.0.140.141:9876 #rocketmq.name-server=192.168.0.70:9876 -rocketmq.name-server=192.168.0.31:9876 +rocketmq.name-server=172.24.151.16:9876 rocketmq.producer.group=libmiddle rocketmq.producer.send-message-timeout=3000 rocketmq.producer.compress-message-body-threshold=4096 @@ -90,6 +90,8 @@ mq.topic.eightWork=eightWork mq.group.info=scheduled_tasks mq.group.eightWork=scheduled_tasks_eightWork +http.file.url=https://qgqy.qhdsafety.com/file/ + #数据同步topic mq.gwj.data.topic=czks_qy_docking @@ -98,3 +100,6 @@ mq.gwj.file.topic=czks_qy_dockingPicture baseimgpath=https://qgqy.qhdsafety.com/file/ cfd.prevention.api.url=http://192.168.0.31:7021/qa-regulatory-cfd + +corp.default.pic-path=https://qgqy.qhdsafety.com/ +corp.default.back-end-path=https://qgqy.qhdsafety.com/file/ diff --git a/src/main/resources/application-local.properties b/src/main/resources/application-local.properties index 483396e2..023e9b32 100644 --- a/src/main/resources/application-local.properties +++ b/src/main/resources/application-local.properties @@ -91,6 +91,7 @@ mq.group.eightWork=scheduled_tasks_eightWork corp.default.pic-path=https://qgqy.qhdsafety.com/ + corp.default.back-end-path=https://qgqy.qhdsafety.com/file/ http.file.url=https://qgqy.qhdsafety.com/file/ diff --git a/src/main/resources/application-master.properties b/src/main/resources/application-master.properties index 4ebd818f..bc29f57c 100644 --- a/src/main/resources/application-master.properties +++ b/src/main/resources/application-master.properties @@ -85,12 +85,14 @@ mq.group.info=scheduled_tasks mq.group.eightWork=scheduled_tasks_eightWork -corp.default.pic-path=https://qgqy.qhdsafety.com/file/ +corp.default.pic-path=http://192.168.192.201:8991/file/ corp.default.back-end-path=https://skqhdg.porthebei.com:9004/file/ #数据同步topic mq.gwj.data.topic=czks_docking mq.gwj.file.topic=czks_dockingPicture #港务局文件服务器前缀 -baseimgpath=https://qgqy.qhdsafety.com/file/ +baseimgpath=http://192.168.192.201:8991/file/ cfd.prevention.api.url=http://192.168.0.31:7021/qa-regulatory-cfd + +http.file.url=http://192.168.192.201:8991/file/ diff --git a/src/main/resources/application.properties b/src/main/resources/application.properties index 25c549c5..dd259ac5 100644 --- a/src/main/resources/application.properties +++ b/src/main/resources/application.properties @@ -4,9 +4,9 @@ server.port=8091 #?? #spring.profiles.active=local #����31ʱʹ�� -spring.profiles.active=dev +#spring.profiles.active=dev #?? -#spring.profiles.active=master +spring.profiles.active=master diff --git a/src/main/resources/mybatis/dsno2/bus/ClassInfoMapper.xml b/src/main/resources/mybatis/dsno2/bus/ClassInfoMapper.xml new file mode 100644 index 00000000..8a25c2a4 --- /dev/null +++ b/src/main/resources/mybatis/dsno2/bus/ClassInfoMapper.xml @@ -0,0 +1,143 @@ + + + + + + + BUS_CLASS_INFO + + + + + SYS_DICTIONARIES + + + + + f.CREATE_TIME, + f.CREATOR, + f.OPERATE_TIME, + f.OPERATOR, + f.ISDELETE, + f.CORPINFO_ID, + f.USER_ID, + f.STATUS, + f.CLASS_MESSAGE_ID, + f.CLASS_INFO_ID, + f.USERNAME, + f.NAME, + f.SEX, + f.CARD_ID, + f.RELEVANT_UNIT_NAME, + f.DEPARTMENT_NAME, + f.PHOTO, + f.PHONE, + f.PERSON_WORK_TYPE, + f.CERTIFICATE, + f.CLASS_NO, + f.TRAINUSERS_ID + + + + + CREATE_TIME, + CREATOR, + OPERATE_TIME, + OPERATOR, + ISDELETE, + CORPINFO_ID, + USER_ID, + STATUS, + CLASS_MESSAGE_ID, + CLASS_INFO_ID, + USERNAME, + NAME, + SEX, + CARD_ID, + RELEVANT_UNIT_NAME, + DEPARTMENT_NAME, + PHOTO, + PHONE, + PERSON_WORK_TYPE, + CERTIFICATE, + CLASS_NO, + TRAINUSERS_ID + + + + + #{CREATE_TIME}, + #{CREATOR}, + #{OPERATE_TIME}, + #{OPERATOR}, + #{ISDELETE}, + #{CORPINFO_ID}, + #{USER_ID}, + #{STATUS}, + #{CLASS_MESSAGE_ID}, + #{CLASS_INFO_ID}, + #{USERNAME}, + #{NAME}, + #{SEX}, + #{CARD_ID}, + #{RELEVANT_UNIT_NAME}, + #{DEPARTMENT_NAME}, + #{PHOTO}, + #{PHONE}, + #{PERSON_WORK_TYPE}, + #{CERTIFICATE}, + #{CLASS_NO}, + #{TRAINUSERS_ID} + + + + + + + + + + +