Commit 731df811 authored by 赵啸非's avatar 赵啸非

一件事统一办

parent e97e352e
......@@ -27,17 +27,14 @@
</el-dialog>
<el-card class="box-card">
<div slot="header" class="clearfix">
<span class="el-icon-document">基础信息</span>
<span class="el-icon-document">办理信息</span>
<el-button style="float: right" type="primary" @click="goBack"
>返回</el-button
>
</div>
<el-col :span="16" :offset="6" v-if="variableOpen">
<!--申请流程初始化表单模块-->
<div>
<!-- <parser :key="new Date().getTime()" :form-conf="variablesData" /> -->
</div>
<el-descriptions
style="margin-bottom: 20px; font-size: 14px"
......@@ -466,7 +463,7 @@ export default {
this.getBusinessDetail(this.$route.query.businessKey);
this.getBusinessFiles(this.$route.query.businessKey);
//this.getBusinessFiles(this.$route.query.businessKey);
this.taskForm.deployId = this.$route.query && this.$route.query.deployId;
this.taskForm.taskId = this.$route.query && this.$route.query.taskId;
......@@ -574,7 +571,7 @@ export default {
},
getBusinessDetail(id) {
//获取业务详细
//获取业务信息
this.$post("/yth/onething/view", {
id: [id],
}).then((res) => {
......@@ -584,17 +581,17 @@ export default {
});
},
getBusinessFiles(id) {
//获取业务详细
this.$post("/datum/file/list", {
"query.tid": id,
}).then((res) => {
console.log("business", res);
this.datumFileList = res.data.result;
// getBusinessFiles(id) {
// //获取业务详细
// this.$post("/datum/file/list", {
// "query.tid": id,
// }).then((res) => {
// console.log("business", res);
// this.datumFileList = res.data.result;
this.dict = Object.assign({}, this.dict, res.data.dict);
});
},
// this.dict = Object.assign({}, this.dict, res.data.dict);
// });
// },
/** xml 文件 */
getModelDetail(deployId) {
......
package com.mortals.xhx.busiz;
import com.mortals.framework.util.DateUtils;
import com.mortals.xhx.busiz.baseinfo.BaseInfoDetail;
import com.mortals.xhx.busiz.oneProblemlist.OneProblemInfo;
import com.mortals.xhx.busiz.oneProblemlist.OptionDetailInfo;
import com.mortals.xhx.busiz.uploadfile.UploadDatumReq;
import com.mortals.xhx.busiz.uploadfile.SubmitDatumReq;
import com.mortals.xhx.busiz.wechat.WechatBaseReq;
import com.mortals.xhx.module.member.model.MemberEntity;
import com.mortals.xhx.module.yth.model.YthOnethingEntity;
......@@ -38,7 +34,6 @@ public interface BaseMapper {
@Mapping(source = "b_img", target = "BImg")
MemberEntity weChat2Entity(WechatBaseReq req);
@Mapping(source = "open_id", target = "openId")
YthOnethingEntity uploadDatumReq2OneThingEntity(UploadDatumReq req);
YthOnethingEntity uploadDatumReq2OneThingEntity(SubmitDatumReq req);
}
......@@ -12,6 +12,6 @@ public class BaseReq {
/**
* 微信开放id
*/
private String open_id;
private String openId;
}
###列表查询
###主题包列表
POST {{baseUrl}}/m/zwfw/proced/thing/oneTopiclist
Content-Type: application/x-www-form-urlencoded
type=1
###主题包列表
POST {{baseUrl}}/m/zwfw/proced/thing/one_list
Content-Type: application/x-www-form-urlencoded
page=1&limit=10&keywords=打广告
###问答数据
POST {{baseUrl}}/m/zwfw/proced/thing/oneProblem
Content-Type: application/x-www-form-urlencoded
id= 1
id=1
###事项详细数据
POST {{baseUrl}}/m/zwfw/proced/thing/oneBasicsInfo
Content-Type: application/x-www-form-urlencoded
id= 1
id=1
###根据openid 查询用户
POST {{baseUrl}}/m/zwfw/proced/thing/is_phone
POST {{baseUrl}}/m/zwfw/proced/thing/searchMember
Content-Type: application/x-www-form-urlencoded
open_id= dafdadfasfdaf
openId=abc
###问答基础数据
POST {{baseUrl}}/m/zwfw/proced/thing/condition
POST {{baseUrl}}/m/zwfw/proced/thing/ansResults
Content-Type: application/x-www-form-urlencoded
option_id= 59&key= (1&2&3)
optionIds[0]=17&optionIds[1]=20
###微信用户校验创建更新
POST {{baseUrl}}/m/zwfw/wechatinter/base/checkCard
Content-Type: application/x-www-form-urlencoded
sitenum= 123&openid= aldadfijakdjkdknnciemdmdiadkkdmakd&idcard= 510106197907211830&tel= 028-83182408&name= 张三&file= 123&z_img= 123&b_img= 123&siteid= 12
sitenum=123&openid=aldadfijakdjkdknnciemdmdiadkkdmakd&idcard= 510106197907211830&tel= 028-83182408&name= 张三&file= 123&z_img= 123&b_img= 123&siteid= 12
###测试文件上传
POST {{baseUrl}}/m/zwfw/proced/thing/upload_file
POST {{baseUrl}}/m/zwfw/proced/thing/uploadFile
Content-Type: multipart/form-data; boundary=WebAppBoundary
--WebAppBoundary
......@@ -55,17 +48,21 @@ Content-Type: multipart/form-data
< ./test.xlsx
--WebAppBoundary--
###删除文件
POST {{baseUrl}}/m/zwfw/proced/thing/delFile
Content-Type: application/x-www-form-urlencoded
filePath=/uploads/oneys/625703530623135744.xlsx
###发起审批
POST {{baseUrl}}/m/zwfw/proced/thing/upload_datum
###一件事一次办材料提交
POST {{baseUrl}}/m/zwfw/proced/thing/submitDatum
Content-Type: application/x-www-form-urlencoded
is_agent=0&open_id=aldadfijakdjkdknnciemdmdiadkkdmakd&manner=0&matterid=1&region_id=1&option_content=v1ia4x&phone=15719864910&name=正豪.丁&siteid=501&file_arr[0].datumid=3&file_arr[0].file=/upload/download/12312.jpg&idcard=510106198907211830
classifyTopicId=1&siteId=1&openId=abc&isAgent=0&idcard=361620199707288337&matterReqList[0].attachmentList[0].filepath=/uploads/oneys/625710918952546304.xlsx&name=张三&matterReqList[0].matterid=1&phone=15978345833&matterReqList[0].attachmentList[0].fileName=test.xlsx&manner=0&matterReqList[0].attachmentList[0].datumId=1
###查询我的办理
POST {{baseUrl}}/m/zwfw/proced/thing/my_handle
POST {{baseUrl}}/m/zwfw/proced/thing/myHandle
Content-Type: application/x-www-form-urlencoded
open_id= aldadfijakdjkdknnciemdmdiadkkdmakd
\ No newline at end of file
openId=abc
\ No newline at end of file
......@@ -5,6 +5,7 @@ import lombok.Data;
import java.util.Date;
/**
* 受理条件
* @author: zxfei
* @date: 2021/9/6 13:59
* @description:
......@@ -12,27 +13,20 @@ import java.util.Date;
@Data
public class AcceptInfo {
private Long id;
/**
* 模板标题
* 事项id
*/
private String title;
private Long matterId;
/**
* 申请条件
* 受理条件
*/
private String content;
private String title;
/**
* 基础表one_basics id
* 受理条件
*/
private Long basics_id;
private String content;
/**
* 创建时间
*/
private Long create_time;
}
......@@ -6,21 +6,22 @@ import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import java.io.Serializable;
import java.util.List;
/**
* 问答问题
* 问答问题答案
*
* @author: zxfei
* @date: 2021/9/6 9:26
*/
@Data
@ApiModel(value = "QuestionReq", description = "回答问题请求参数")
public class QuestionReq extends BaseReq implements Serializable {
public class AnswerReq extends BaseReq implements Serializable {
/**
* 问答最后最后选项ID
* 问答最后答案选项ID(多问题线)
*/
@ApiModelProperty(value = "问答最后最后选项ID")
private Long option_id;
@ApiModelProperty(value = "问答最后最后选项ids")
private List<Long> optionIds;
/**
* 问题路线id?
......
package com.mortals.xhx.busiz.question;
import lombok.Data;
/**
* 材料附件下载详细
* @author: zxfei
* @date: 2021/9/6 14:06
* @description:
**/
@Data
public class DatumDownloadInfo {
/**
* 材料id
*/
private Long datumid;
/**
* 附件名称
*/
private String fileName;
/**
* 附件下载地址
*/
private String fileUrl;
/**
* 附件类型 1 示例样表 2空白表格 默认1
*/
private Integer filetype;
}
......@@ -2,13 +2,20 @@ package com.mortals.xhx.busiz.question;
import lombok.Data;
import java.util.Date;
import java.util.List;
/**
* 材料详细
* @author: zxfei
* @date: 2021/9/6 14:06
* @description:
**/
@Data
public class DatumInfo {
/**
* 材料id
*/
private Long id;
/**
* 材料名
......@@ -16,44 +23,35 @@ public class DatumInfo {
private String materialName;
/**
* 基础表one_basics id
*/
private Long basics_id;
/**
* 事项表yth_matter id 表示从一体化获取的材料
* 事项Id
*/
private Long matterid;
private Long matterId;
/**
* 材料表yth_datum id 表示从一体化获取的材料
*/
private Long datum_id;
/**
* 材料形式
*/
private Integer materialProperty;
private String materialProperty;
/**
* 是否必交,0 否 1 是 默认0
*/
private Integer isMust;
private String isMust;
/**
* 材料类型
*/
private Integer materialType;
private String materialType;
/**
* 电子材料格式
*/
private Integer electronicgs;
private String electronicgs;
/**
* 材料来源渠道
*/
private Integer materialSource;
private String materialSource;
/**
* 纸质材料份数
......@@ -63,32 +61,28 @@ public class DatumInfo {
/**
* 纸质材料规格
*/
private Integer paperGg;
private String paperGg;
/**
* 减免模式
*/
private Integer jianmMs;
private String jianmMs;
/**
* 盖章方式
*/
private Integer sealWay;
private String sealWay;
/**
* 是否减免
*/
private Integer isjianm;
private String isjianm;
/**
* 材料是否容缺
*/
private Integer isLack;
private String isLack;
/**
* 材料地址
*/
private String yb_url;
/**
* 来源渠道说明
......@@ -115,11 +109,13 @@ public class DatumInfo {
*/
private String summary;
/**
* 0正常 1删除
* 材料创建时间
*/
private Integer valid;
private Date createTime;
private Long create_time;
private List<DatumDownloadInfo> attachList;
}
......@@ -8,30 +8,32 @@ import lombok.Data;
* @description:
**/
@Data
public class FlowLimitinfo {
private Long id;
public class FlowLimitInfo {
/**
* 模板标题
* 事项matter id
*/
private String title;
private Long matterId;
/**
* 办理流程
*/
private String content;
private String flowName;
/**
* 办理时长
*/
private String flowTime;
/**
* 基础表one_basics id
* 转外时限
*/
private Long basics_id;
private String flowTurnOut;
/**
* 创建时间
* 办理流程说明
*/
private Long create_time;
private String flowDesc;
}
package com.mortals.xhx.busiz.question;
import lombok.Data;
/**
* 事项
*
* @author: zxfei
* @date: 2021/9/6 14:05
* @description:
**/
@Data
public class MatterInfo {
/**
* 事项id
*/
private Long id;
/**
* 事项名称
*/
private String matterName;
}
package com.mortals.xhx.busiz.question;
import lombok.Data;
/**
* 常见问题
*
* @author: zxfei
* @date: 2021/9/6 14:05
* @description:
**/
@Data
public class QAndAInfo {
/**
* 事项id
*/
private Long matterId;
/**
* 问题
*/
private String question;
/**
* 回答
*/
private String answer;
}
......@@ -5,6 +5,7 @@ import lombok.Data;
import java.util.List;
/**
* 问题结果
* @author: zxfei
* @date: 2021/9/6 13:58
* @description:
......@@ -12,14 +13,30 @@ import java.util.List;
@Data
public class QuestionInfo {
private BasicsInfo basicsInfo;
private List<AcceptInfo> accept;
private List<FlowLimitinfo> flowlimit;
private List<DatumInfo> datum;
/**
* 事项列表列表
*/
private List<MatterInfo> matterInfoList;
/**
* 受理条件列表
*/
private List<AcceptInfo> acceptInfoList;
/**
* 办理流程列表
*/
private List<FlowLimitInfo> flowLimitInfoList;
/**
* 事项材料列表
*/
private List<DatumInfo> datumInfoList;
/**
* 常见问题列表
*/
private List<QAndAInfo> qAndAInfoList;
}
......@@ -21,7 +21,7 @@ public class DeleteFileReq extends BaseReq implements Serializable {
* 文件路径
*/
@ApiModelProperty(value = "文件路径")
private String file_path;
private String filePath;
}
package com.mortals.xhx.busiz.uploadfile;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import java.io.Serializable;
import java.util.List;
/**
* 办理事项提交
*
* @author: zxfei
* @date: 2021/9/6 9:26
*/
@Data
@ApiModel(value = "MatterReq", description = "事项提交参数")
public class MatterReq implements Serializable {
/**
* 事项ID
*/
@ApiModelProperty(value = "事项ID")
private Long matterid;
/**
* 申请材料列表
*
*/
@ApiModelProperty(value = "申请材料附件列表")
private List<UploadFileInfo> attachmentList;
}
......@@ -9,32 +9,29 @@ import java.io.Serializable;
import java.util.List;
/**
* 文件资料上传
* 办理材料提交
*
* @author: zxfei
* @date: 2021/9/6 9:26
*/
@Data
@ApiModel(value = "UploadDatumReq", description = "请求参数")
public class UploadDatumReq extends BaseReq implements Serializable {
@ApiModel(value = "SubmitDatumReq", description = "请求参数")
public class SubmitDatumReq extends BaseReq implements Serializable {
/**
* 事项ID
*/
@ApiModelProperty(value = "事项ID")
private Long matterid;
/**
* siteid
* 申请主题包id
*/
@ApiModelProperty(value = "村数据下的站点id")
private Long siteid;
@ApiModelProperty(value = "申请主题包id")
private Long classifyTopicId;
/**
* 问答内容
* 站点ID
*/
@ApiModelProperty(value = "问答内容")
private String option_content;
@ApiModelProperty(value = "村数据下的站点id")
private Long siteId;
/**
......@@ -59,7 +56,7 @@ public class UploadDatumReq extends BaseReq implements Serializable {
* 0本人办理 1代办
*/
@ApiModelProperty(value = "0本人办理 1代办")
private Integer is_agent;
private Integer isAgent;
/**
* 0自主取件 1代办领取 (取件方式)
......@@ -67,17 +64,12 @@ public class UploadDatumReq extends BaseReq implements Serializable {
@ApiModelProperty(value = "0 自主取件 1 代办领取 (取件方式)")
private Integer manner;
/**
* 村ID
*/
@ApiModelProperty(value = "村ID")
private Long region_id;
/**
* 申请材料附件列表
* 申请事项列表
*
*/
@ApiModelProperty(value = "申请材料附件列表")
private List<UploadFileInfo> file_arr;
@ApiModelProperty(value = "申请事项列表")
private List<MatterReq> matterReqList;
}
......@@ -3,6 +3,7 @@ package com.mortals.xhx.busiz.uploadfile;
import lombok.Data;
/**
* 上传材料信息
* @author: zxfei
* @date: 2021/9/7 15:04
* @description:
......@@ -10,7 +11,19 @@ import lombok.Data;
@Data
public class UploadFileInfo {
private Long datumid;
/**
* 材料id
*/
private Long datumId;
private String file;
/**
* 附件名称
*/
private String fileName;
/**
* 附件存储地址
*/
private String filepath;
}
......@@ -227,14 +227,14 @@ public class RequestDispatchController {
chargesEntity.setCreateTime(new Date());
matterChargesService.save(chargesEntity);
MatterFlowlimitEntity flowlimitEntity = new MatterFlowlimitEntity();
flowlimitEntity.setMatterId(item.getId());
flowlimitEntity.setTitle(item.getName());
flowlimitEntity.setContent(mattersDetailEntity.getProcessBllc());
flowlimitEntity.setSource(0);
flowlimitEntity.setCreateUser("system");
flowlimitEntity.setCreateTime(new Date());
matterFlowlimitService.save(flowlimitEntity);
// MatterFlowlimitEntity flowlimitEntity = new MatterFlowlimitEntity();
// flowlimitEntity.setMatterId(item.getId());
// flowlimitEntity.setTitle(item.getName());
// flowlimitEntity.setContent(mattersDetailEntity.getProcessBllc());
// flowlimitEntity.setSource(0);
// flowlimitEntity.setCreateUser("system");
// flowlimitEntity.setCreateTime(new Date());
// matterFlowlimitService.save(flowlimitEntity);
MatterIntermediaryEntity intermediaryEntity = new MatterIntermediaryEntity();
intermediaryEntity.setMatterId(item.getId());
......
......@@ -18,8 +18,21 @@ Content-Type: application/json
{}
### 解析申请条件
POST {{baseUrl}}/m/test/datumn
### 解析常见问题
POST {{baseUrl}}/m/test/question
Content-Type: application/json
{}
### 解析办理条件
POST {{baseUrl}}/m/test/accept
Content-Type: application/json
{}
### 解析办理流程
POST {{baseUrl}}/m/test/flow
Content-Type: application/json
{}
......@@ -5,26 +5,36 @@ import com.mortals.framework.model.BaseEntityLong;
/**
*
* Description:MatterFlowlimit
* date: 2021-9-17 15:55:12
* date: 2021-9-23 13:21:04
*/
public class MatterFlowlimitEntity extends BaseEntityLong{
private static final long serialVersionUID = 1631865312190L;
private static final long serialVersionUID = 1632374464316L;
/**
* 事项基础表matter id
* 事项matter id
*/
private Long matterId;
/**
* 模板标题
* 办理流程
*/
private String title;
private String flowName;
/**
* 办理流程
* 办理时长
*/
private String flowTime;
/**
* 转外时限
*/
private String flowTurnOut;
/**
* 办理流程说明
*/
private String content;
private String flowDesc;
/**
* 事项来源,0:政务网,1:自定义,默认0
......@@ -55,46 +65,74 @@ public class MatterFlowlimitEntity extends BaseEntityLong{
}
/**
* 获取 事项基础表matter id
* 获取 事项matter id
* @return matterId
*/
public Long getMatterId() {
return this.matterId;
}
/**
* 设置 事项基础表matter id
* 设置 事项matter id
* @param matterId
*/
public void setMatterId(Long matterId) {
this.matterId = matterId;
}
/**
* 获取 模板标题
* @return title
* 获取 办理流程
* @return flowName
*/
public String getTitle() {
return this.title;
public String getFlowName() {
return this.flowName;
}
/**
* 设置 模板标题
* @param title
* 设置 办理流程
* @param flowName
*/
public void setTitle(String title) {
this.title = title;
public void setFlowName(String flowName) {
this.flowName = flowName;
}
/**
* 获取 办理流程
* @return content
* 获取 办理时长
* @return flowTime
*/
public String getContent() {
return this.content;
public String getFlowTime() {
return this.flowTime;
}
/**
* 设置 办理流程
* @param content
* 设置 办理时长
* @param flowTime
*/
public void setFlowTime(String flowTime) {
this.flowTime = flowTime;
}
/**
* 获取 转外时限
* @return flowTurnOut
*/
public String getFlowTurnOut() {
return this.flowTurnOut;
}
/**
* 设置 转外时限
* @param flowTurnOut
*/
public void setFlowTurnOut(String flowTurnOut) {
this.flowTurnOut = flowTurnOut;
}
/**
* 获取 办理流程说明
* @return flowDesc
*/
public String getFlowDesc() {
return this.flowDesc;
}
/**
* 设置 办理流程说明
* @param flowDesc
*/
public void setContent(String content) {
this.content = content;
public void setFlowDesc(String flowDesc) {
this.flowDesc = flowDesc;
}
/**
* 获取 事项来源,0:政务网,1:自定义,默认0
......@@ -189,8 +227,10 @@ public class MatterFlowlimitEntity extends BaseEntityLong{
sb
.append(",id:").append(getId())
.append(",matterId:").append(getMatterId())
.append(",title:").append(getTitle())
.append(",content:").append(getContent())
.append(",flowName:").append(getFlowName())
.append(",flowTime:").append(getFlowTime())
.append(",flowTurnOut:").append(getFlowTurnOut())
.append(",flowDesc:").append(getFlowDesc())
.append(",source:").append(getSource())
.append(",updateTime:").append(getUpdateTime())
.append(",updateUser:").append(getUpdateUser())
......@@ -202,8 +242,10 @@ public class MatterFlowlimitEntity extends BaseEntityLong{
public void initAttrValue(){
this.matterId = null;
this.title = null;
this.content = null;
this.flowName = null;
this.flowTime = null;
this.flowTurnOut = null;
this.flowDesc = null;
this.source = null;
this.updateTime = null;
this.updateUser = null;
......
......@@ -6,10 +6,10 @@ import java.util.Date;
/**
*
* Description:MatterFlowlimit
* date: 2021-9-17 15:55:12
* date: 2021-9-23 13:21:04
*/
public class MatterFlowlimitQuery extends MatterFlowlimitEntity{
private static final long serialVersionUID = 1631865312191L;
private static final long serialVersionUID = 1632374464325L;
/** 开始 主键,自增长 */
private Long idStart;
......@@ -22,24 +22,30 @@ public class MatterFlowlimitQuery extends MatterFlowlimitEntity{
/** 主键,自增长 */
private List <Long> idList;
/** 开始 事项基础表matter id */
/** 开始 事项matter id */
private Long matterIdStart;
/** 结束 事项基础表matter id */
/** 结束 事项matter id */
private Long matterIdEnd;
/** 增加 事项基础表matter id */
/** 增加 事项matter id */
private Long matterIdIncrement;
/** 事项基础表matter id */
/** 事项matter id */
private List <Long> matterIdList;
/** 模板标题 */
private List<String> titleList;
/** 办理流程 */
private List<String> contentList;
private List<String> flowNameList;
/** 办理时长 */
private List<String> flowTimeList;
/** 转外时限 */
private List<String> flowTurnOutList;
/** 办理流程说明 */
private List<String> flowDescList;
/** 开始 事项来源,0:政务网,1:自定义,默认0 */
private Integer sourceStart;
......@@ -143,7 +149,7 @@ public class MatterFlowlimitQuery extends MatterFlowlimitEntity{
this.idList = idList;
}
/**
* 获取 开始 事项基础表matter id
* 获取 开始 事项matter id
* @return matterIdStart
*/
public Long getMatterIdStart(){
......@@ -151,7 +157,7 @@ public class MatterFlowlimitQuery extends MatterFlowlimitEntity{
}
/**
* 设置 开始 事项基础表matter id
* 设置 开始 事项matter id
* @param matterIdStart
*/
public void setMatterIdStart(Long matterIdStart){
......@@ -159,7 +165,7 @@ public class MatterFlowlimitQuery extends MatterFlowlimitEntity{
}
/**
* 获取 结束 事项基础表matter id
* 获取 结束 事项matter id
* @return matterIdEnd
*/
public Long getMatterIdEnd(){
......@@ -167,7 +173,7 @@ public class MatterFlowlimitQuery extends MatterFlowlimitEntity{
}
/**
* 设置 结束 事项基础表matter id
* 设置 结束 事项matter id
* @param matterIdEnd
*/
public void setMatterIdEnd(Long matterIdEnd){
......@@ -175,7 +181,7 @@ public class MatterFlowlimitQuery extends MatterFlowlimitEntity{
}
/**
* 获取 增加 事项基础表matter id
* 获取 增加 事项matter id
* @return matterIdIncrement
*/
public Long getMatterIdIncrement(){
......@@ -183,7 +189,7 @@ public class MatterFlowlimitQuery extends MatterFlowlimitEntity{
}
/**
* 设置 增加 事项基础表matter id
* 设置 增加 事项matter id
* @param matterIdIncrement
*/
public void setMatterIdIncrement(Long matterIdIncrement){
......@@ -191,7 +197,7 @@ public class MatterFlowlimitQuery extends MatterFlowlimitEntity{
}
/**
* 获取 事项基础表matter id
* 获取 事项matter id
* @return matterIdList
*/
public List<Long> getMatterIdList(){
......@@ -199,41 +205,71 @@ public class MatterFlowlimitQuery extends MatterFlowlimitEntity{
}
/**
* 设置 事项基础表matter id
* 设置 事项matter id
* @param matterIdList
*/
public void setMatterIdList(List<Long> matterIdList){
this.matterIdList = matterIdList;
}
/**
* 获取 模板标题
* @return titleList
* 获取 办理流程
* @return flowNameList
*/
public List<String> getTitleList(){
return this.titleList;
public List<String> getFlowNameList(){
return this.flowNameList;
}
/**
* 设置 模板标题
* @param titleList
* 设置 办理流程
* @param flowNameList
*/
public void setTitleList(List<String> titleList){
this.titleList = titleList;
public void setFlowNameList(List<String> flowNameList){
this.flowNameList = flowNameList;
}
/**
* 获取 办理流程
* @return contentList
* 获取 办理时长
* @return flowTimeList
*/
public List<String> getContentList(){
return this.contentList;
public List<String> getFlowTimeList(){
return this.flowTimeList;
}
/**
* 设置 办理流程
* @param contentList
* 设置 办理时长
* @param flowTimeList
*/
public void setFlowTimeList(List<String> flowTimeList){
this.flowTimeList = flowTimeList;
}
/**
* 获取 转外时限
* @return flowTurnOutList
*/
public void setContentList(List<String> contentList){
this.contentList = contentList;
public List<String> getFlowTurnOutList(){
return this.flowTurnOutList;
}
/**
* 设置 转外时限
* @param flowTurnOutList
*/
public void setFlowTurnOutList(List<String> flowTurnOutList){
this.flowTurnOutList = flowTurnOutList;
}
/**
* 获取 办理流程说明
* @return flowDescList
*/
public List<String> getFlowDescList(){
return this.flowDescList;
}
/**
* 设置 办理流程说明
* @param flowDescList
*/
public void setFlowDescList(List<String> flowDescList){
this.flowDescList = flowDescList;
}
/**
* 获取 开始 事项来源,0:政务网,1:自定义,默认0
......@@ -438,7 +474,7 @@ public class MatterFlowlimitQuery extends MatterFlowlimitEntity{
}
/**
* 设置 事项基础表matter id
* 设置 事项matter id
* @param matterId
*/
public MatterFlowlimitQuery matterId(Long matterId){
......@@ -447,7 +483,7 @@ public class MatterFlowlimitQuery extends MatterFlowlimitEntity{
}
/**
* 设置 开始 事项基础表matter id
* 设置 开始 事项matter id
* @param matterIdStart
*/
public MatterFlowlimitQuery matterIdStart(Long matterIdStart){
......@@ -456,7 +492,7 @@ public class MatterFlowlimitQuery extends MatterFlowlimitEntity{
}
/**
* 设置 结束 事项基础表matter id
* 设置 结束 事项matter id
* @param matterIdEnd
*/
public MatterFlowlimitQuery matterIdEnd(Long matterIdEnd){
......@@ -465,7 +501,7 @@ public class MatterFlowlimitQuery extends MatterFlowlimitEntity{
}
/**
* 设置 增加 事项基础表matter id
* 设置 增加 事项matter id
* @param matterIdIncrement
*/
public MatterFlowlimitQuery matterIdIncrement(Long matterIdIncrement){
......@@ -474,7 +510,7 @@ public class MatterFlowlimitQuery extends MatterFlowlimitEntity{
}
/**
* 设置 事项基础表matter id
* 设置 事项matter id
* @param matterIdList
*/
public MatterFlowlimitQuery matterIdList(List<Long> matterIdList){
......@@ -482,39 +518,75 @@ public class MatterFlowlimitQuery extends MatterFlowlimitEntity{
return this;
}
/**
* 设置 模板标题
* @param title
* 设置 办理流程
* @param flowName
*/
public MatterFlowlimitQuery flowName(String flowName){
setFlowName(flowName);
return this;
}
/**
* 设置 办理流程
* @param flowNameList
*/
public MatterFlowlimitQuery flowNameList(List<String> flowNameList){
this.flowNameList = flowNameList;
return this;
}
/**
* 设置 办理时长
* @param flowTime
*/
public MatterFlowlimitQuery title(String title){
setTitle(title);
public MatterFlowlimitQuery flowTime(String flowTime){
setFlowTime(flowTime);
return this;
}
/**
* 设置 模板标题
* @param titleList
* 设置 办理时长
* @param flowTimeList
*/
public MatterFlowlimitQuery titleList(List<String> titleList){
this.titleList = titleList;
public MatterFlowlimitQuery flowTimeList(List<String> flowTimeList){
this.flowTimeList = flowTimeList;
return this;
}
/**
* 设置 办理流程
* @param content
* 设置 转外时限
* @param flowTurnOut
*/
public MatterFlowlimitQuery content(String content){
setContent(content);
public MatterFlowlimitQuery flowTurnOut(String flowTurnOut){
setFlowTurnOut(flowTurnOut);
return this;
}
/**
* 设置 办理流程
* @param contentList
* 设置 转外时限
* @param flowTurnOutList
*/
public MatterFlowlimitQuery flowTurnOutList(List<String> flowTurnOutList){
this.flowTurnOutList = flowTurnOutList;
return this;
}
/**
* 设置 办理流程说明
* @param flowDesc
*/
public MatterFlowlimitQuery flowDesc(String flowDesc){
setFlowDesc(flowDesc);
return this;
}
/**
* 设置 办理流程说明
* @param flowDescList
*/
public MatterFlowlimitQuery contentList(List<String> contentList){
this.contentList = contentList;
public MatterFlowlimitQuery flowDescList(List<String> flowDescList){
this.flowDescList = flowDescList;
return this;
}
......
......@@ -2,6 +2,8 @@ package com.mortals.xhx.module.one.service;
import com.mortals.framework.service.ICRUDService;
import com.mortals.xhx.busiz.oneProblemlist.OneProblemInfo;
import com.mortals.xhx.busiz.question.AnswerReq;
import com.mortals.xhx.busiz.question.QuestionInfo;
import com.mortals.xhx.module.one.model.OneClassifyTopicalEntity;
import java.util.HashMap;
......@@ -29,4 +31,7 @@ public interface OneClassifyTopicalService extends ICRUDService<OneClassifyTopic
*/
OneProblemInfo findAllQuestion(Long id);
QuestionInfo getMattersByAnswers(AnswerReq req);
}
\ No newline at end of file
......@@ -3,10 +3,17 @@ package com.mortals.xhx.module.one.service.impl;
import com.mortals.framework.exception.AppException;
import com.mortals.framework.model.Context;
import com.mortals.framework.model.OrderCol;
import com.mortals.xhx.base.system.param.service.ParamService;
import com.mortals.xhx.busiz.oneProblemlist.OneProblemInfo;
import com.mortals.xhx.busiz.question.*;
import com.mortals.xhx.common.code.YesNoEnum;
import com.mortals.xhx.common.key.Constant;
import com.mortals.xhx.common.utils.BeanUtil;
import com.mortals.xhx.module.matter.model.*;
import com.mortals.xhx.module.matter.service.*;
import com.mortals.xhx.module.one.model.*;
import com.mortals.xhx.module.one.service.OneClassifyService;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.mortals.framework.service.impl.AbstractCRUDServiceImpl;
......@@ -15,7 +22,6 @@ import com.mortals.xhx.module.one.service.OneClassifyTopicalService;
import org.springframework.util.ObjectUtils;
import java.util.Arrays;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.stream.Collectors;
......@@ -32,6 +38,20 @@ public class OneClassifyTopicalServiceImpl extends AbstractCRUDServiceImpl<OneCl
@Autowired
private OneClassifyService oneClassifyService;
@Autowired
private MatterService matterService;
@Autowired
private MatterDatumService matterDatumService;
@Autowired
private ParamService paramService;
@Autowired
private MatterDatumFileService matterDatumFileService;
@Autowired
private MatterFlowlimitService matterFlowlimitService;
@Autowired
private MatterQuestionService matterQuestionService;
@Autowired
private MatterAcceptService matterAcceptService;
@Override
......@@ -111,16 +131,11 @@ public class OneClassifyTopicalServiceImpl extends AbstractCRUDServiceImpl<OneCl
info.setParentId(rootClassify.getParentId());
info.setRemark(rootClassify.getSortRemarks());
info.setIsAns(rootClassify.getIsAns());
List<OneProblemInfo> collect = getOneClassifyEntities(rootClassify);
if(!ObjectUtils.isEmpty(collect)){
if (!ObjectUtils.isEmpty(collect)) {
info.setChildren(collect);
}
}
return info;
}
......@@ -140,12 +155,103 @@ public class OneClassifyTopicalServiceImpl extends AbstractCRUDServiceImpl<OneCl
List<OneProblemInfo> oneClassifyEntities = this.getOneClassifyEntities(item);
if(!ObjectUtils.isEmpty(oneClassifyEntities)){
if (!ObjectUtils.isEmpty(oneClassifyEntities)) {
info.setChildren(oneClassifyEntities);
}
return info;
}).collect(Collectors.toList());
return collect;
}
@Override
public QuestionInfo getMattersByAnswers(AnswerReq req) {
QuestionInfo questionInfo = new QuestionInfo();
Map<String, String> materialPropertyMap = paramService.getParamByFirstOrganize(Constant.Param_materialProperty);
Map<String, String> materialTypeMap = paramService.getParamByFirstOrganize(Constant.Param_materialType);
Map<String, String> electronicgsMap = paramService.getParamByFirstOrganize(Constant.Param_electronicgs);
Map<String, String> materialSourceMap = paramService.getParamByFirstOrganize(Constant.Param_materialSource);
//Map<String, String> paperGgMap = paramService.getParamByFirstOrganize(Constant.Param_paperGg);
Map<String, String> jianmMsMap = paramService.getParamByFirstOrganize(Constant.Param_jianmMs);
//Map<String, String> sealWayMap = paramService.getParamByFirstOrganize(Constant.Param_sealWay);
Map<String, String> isMustMap = paramService.getParamByFirstOrganize(Constant.Param_isMust);
//获取关联的所有事项
List<Long> matterIdsList = oneClassifyService.find(new OneClassifyQuery().idList(req.getOptionIds()))
.stream().flatMap(item ->
Arrays.asList(item.getMatterIds().split(",")).stream()
).map(Long::valueOf).distinct().collect(Collectors.toList());
//根据事项获取所有材料
List<MatterEntity> matterList = matterService.find(new MatterQuery().idList(matterIdsList));
List<MatterInfo> matterEntityList = matterList.stream().map(item -> {
MatterInfo matterinfo = new MatterInfo();
matterinfo.setId(item.getId());
matterinfo.setMatterName(item.getMatterName());
return matterinfo;
}).collect(Collectors.toList());
questionInfo.setMatterInfoList(matterEntityList);
List<DatumInfo> datumInfoList = matterDatumService.find(new MatterDatumQuery().matterIdList(matterIdsList))
.stream().distinct().map(item -> {
DatumInfo datumInfo = new DatumInfo();
BeanUtils.copyProperties(item, datumInfo, BeanUtil.getNullPropertyNames(item));
datumInfo.setId(item.getId());
datumInfo.setJianmMs(jianmMsMap.getOrDefault(item.getJianmMs().toString(), ""));
datumInfo.setIsMust(isMustMap.getOrDefault(item.getIsMust().toString(), ""));
datumInfo.setMaterialProperty(materialPropertyMap.getOrDefault(item.getMaterialProperty().toString(), ""));
datumInfo.setMaterialSource(materialSourceMap.getOrDefault(item.getMaterialSource().toString(), ""));
datumInfo.setMaterialSourceSm(item.getMaterialSourceSm());
datumInfo.setElectronicgs(electronicgsMap.getOrDefault(item.getElectronicgs().toString(), ""));
datumInfo.setMaterialType(materialTypeMap.getOrDefault(item.getMaterialType().toString(), ""));
datumInfo.setIsLack(YesNoEnum.getByValue(item.getIsLack()).getDesc());
datumInfo.setIsjianm(YesNoEnum.getByValue(item.getIsjianm()).getDesc());
datumInfo.setSealWay(item.getSealWayText());
datumInfo.setPaperGg(item.getPaperGgText());
List<DatumDownloadInfo> downloadInfoList = matterDatumFileService.find(new MatterDatumFileQuery().datumid(item.getId())).stream().map(file -> {
DatumDownloadInfo datumDownloadInfo = new DatumDownloadInfo();
BeanUtils.copyProperties(file, datumDownloadInfo, BeanUtil.getNullPropertyNames(file));
return datumDownloadInfo;
}).collect(Collectors.toList());
datumInfo.setAttachList(downloadInfoList);
return datumInfo;
}).collect(Collectors.toList());
questionInfo.setDatumInfoList(datumInfoList);
//根据事项获取所有申请条件
List<AcceptInfo> acceptInfoList = matterAcceptService.find(new MatterAcceptQuery().matterIdList(matterIdsList)).stream().map(item -> {
AcceptInfo acceptInfo = new AcceptInfo();
acceptInfo.setTitle(item.getTitle());
acceptInfo.setContent(item.getContent());
acceptInfo.setMatterId(item.getMatterId());
return acceptInfo;
}).collect(Collectors.toList());
questionInfo.setAcceptInfoList(acceptInfoList);
//根据事项获取所有办理流程
List<FlowLimitInfo> flowLimitInfoList = matterFlowlimitService.find(new MatterFlowlimitQuery().matterIdList(matterIdsList)).stream().map(item -> {
FlowLimitInfo flowLimitInfo = new FlowLimitInfo();
BeanUtils.copyProperties(item, flowLimitInfo, BeanUtil.getNullPropertyNames(item));
return flowLimitInfo;
}).collect(Collectors.toList());
questionInfo.setFlowLimitInfoList(flowLimitInfoList);
//根据事项获取所有常见问题
List<QAndAInfo> qAndAInfoList = matterQuestionService.find(new MatterQuestionQuery().matterIdList(matterIdsList)).stream().map(item -> {
QAndAInfo info = new QAndAInfo();
info.setQuestion(item.getTitle());
info.setAnswer(item.getContent());
info.setMatterId(item.getMatterId());
return info;
}).collect(Collectors.toList());
questionInfo.setQAndAInfoList(qAndAInfoList);
return questionInfo;
}
}
\ No newline at end of file
package com.mortals.xhx.module.yth.dao;
import com.mortals.framework.dao.ICRUDDao;
import com.mortals.xhx.module.yth.model.YthOnethingDetailEntity;
/**
* <p>Title: 一件事提交详细表</p>
* <p>Description: YthOnethingDetailDao DAO接口 </p>
* @author
* @version 1.0.0
*/
public interface YthOnethingDetailDao extends ICRUDDao<YthOnethingDetailEntity,Long>{
}
package com.mortals.xhx.module.yth.dao.ibatis;
import org.springframework.stereotype.Repository;
import com.mortals.framework.dao.ibatis.BaseCRUDDaoMybatis;
import com.mortals.xhx.module.yth.dao.YthOnethingDetailDao;
import com.mortals.xhx.module.yth.model.YthOnethingDetailEntity;
/**
* <p>Title: 一件事提交详细表</p>
* <p>Description: YthOnethingDetailDaoImpl DAO接口 </p>
* @author
* @version 1.0.0
*/
@Repository("ythOnethingDetailDao")
public class YthOnethingDetailDaoImpl extends BaseCRUDDaoMybatis<YthOnethingDetailEntity,Long> implements YthOnethingDetailDao {
}
package com.mortals.xhx.module.yth.model;
import lombok.Data;
/**
* 业务数据
*
* @author: zxfei
* @date: 2021/9/6 14:05
* @description:
**/
@Data
public class BusinessInfo {
/**
* 事项名称
*/
private String oneThingName;
/**
* 事项描述
*/
private String oneThingDesc;
}
package com.mortals.xhx.module.yth.model;
import java.util.Date;
import com.mortals.framework.model.BaseEntityLong;
/**
*
* Description:YthOnethingDetail
* date: 2021-9-23 16:22:50
*/
public class YthOnethingDetailEntity extends BaseEntityLong{
private static final long serialVersionUID = 1632385370714L;
/**
* 材料提交id
*/
private Long oneThingId;
/**
* 事项id
*/
private Long matterId;
/**
* 材料id
*/
private Long datumId;
/**
* 附件名称
*/
private String fileName;
/**
* 附件地址
*/
private String filepath;
/**
* 变更时间
*/
private Date updateTime;
/**
* 变更用户loginName
*/
private String updateUser;
/**
* 创建时间
*/
private Date createTime;
/**
* 创建用户loginName
*/
private String createUser;
public YthOnethingDetailEntity(){
}
/**
* 获取 材料提交id
* @return oneThingId
*/
public Long getOneThingId() {
return this.oneThingId;
}
/**
* 设置 材料提交id
* @param oneThingId
*/
public void setOneThingId(Long oneThingId) {
this.oneThingId = oneThingId;
}
/**
* 获取 事项id
* @return matterId
*/
public Long getMatterId() {
return this.matterId;
}
/**
* 设置 事项id
* @param matterId
*/
public void setMatterId(Long matterId) {
this.matterId = matterId;
}
/**
* 获取 材料id
* @return datumId
*/
public Long getDatumId() {
return this.datumId;
}
/**
* 设置 材料id
* @param datumId
*/
public void setDatumId(Long datumId) {
this.datumId = datumId;
}
/**
* 获取 附件名称
* @return fileName
*/
public String getFileName() {
return this.fileName;
}
/**
* 设置 附件名称
* @param fileName
*/
public void setFileName(String fileName) {
this.fileName = fileName;
}
/**
* 获取 附件地址
* @return filepath
*/
public String getFilepath() {
return this.filepath;
}
/**
* 设置 附件地址
* @param filepath
*/
public void setFilepath(String filepath) {
this.filepath = filepath;
}
/**
* 获取 变更时间
* @return updateTime
*/
public Date getUpdateTime() {
return this.updateTime;
}
/**
* 设置 变更时间
* @param updateTime
*/
public void setUpdateTime(Date updateTime) {
this.updateTime = updateTime;
}
/**
* 获取 变更用户loginName
* @return updateUser
*/
public String getUpdateUser() {
return this.updateUser;
}
/**
* 设置 变更用户loginName
* @param updateUser
*/
public void setUpdateUser(String updateUser) {
this.updateUser = updateUser;
}
/**
* 获取 创建时间
* @return createTime
*/
public Date getCreateTime() {
return this.createTime;
}
/**
* 设置 创建时间
* @param createTime
*/
public void setCreateTime(Date createTime) {
this.createTime = createTime;
}
/**
* 获取 创建用户loginName
* @return createUser
*/
public String getCreateUser() {
return this.createUser;
}
/**
* 设置 创建用户loginName
* @param createUser
*/
public void setCreateUser(String createUser) {
this.createUser = createUser;
}
@Override
public int hashCode() {
return this.getId().hashCode();
}
@Override
public boolean equals(Object obj) {
if (obj == null)
return false;
if (obj instanceof YthOnethingDetailEntity) {
YthOnethingDetailEntity tmp = (YthOnethingDetailEntity) obj;
if (this.getId().longValue() == tmp.getId().longValue()) {
return true;
}
}
return false;
}
public String toString(){
StringBuilder sb = new StringBuilder("");
sb
.append(",id:").append(getId())
.append(",oneThingId:").append(getOneThingId())
.append(",matterId:").append(getMatterId())
.append(",datumId:").append(getDatumId())
.append(",fileName:").append(getFileName())
.append(",filepath:").append(getFilepath())
.append(",updateTime:").append(getUpdateTime())
.append(",updateUser:").append(getUpdateUser())
.append(",createTime:").append(getCreateTime())
.append(",createUser:").append(getCreateUser())
;
return sb.toString();
}
public void initAttrValue(){
this.oneThingId = null;
this.matterId = null;
this.datumId = null;
this.fileName = null;
this.filepath = null;
this.updateTime = null;
this.updateUser = null;
this.createTime = null;
this.createUser = null;
}
}
\ No newline at end of file
......@@ -5,10 +5,10 @@ import com.mortals.framework.model.BaseEntityLong;
/**
*
* Description:YthOnething
* date: 2021-9-8 9:18:50
* date: 2021-9-23 16:00:52
*/
public class YthOnethingEntity extends BaseEntityLong{
private static final long serialVersionUID = 1631063930777L;
private static final long serialVersionUID = 1632384052549L;
/**
......@@ -27,24 +27,14 @@ public class YthOnethingEntity extends BaseEntityLong{
private Long memberId;
/**
* 微信openId
* 微信OPENID
*/
private String openId;
/**
* 事项ID
* 申请主题包id
*/
private Long matterid;
/**
* 上传时间
*/
private Integer uploadtime;
/**
* 1资料上传 2确认提交
*/
private Integer type;
private Long classifyTopicId;
/**
* 邮寄地址
......@@ -61,11 +51,6 @@ public class YthOnethingEntity extends BaseEntityLong{
*/
private Integer phone;
/**
* 0本人办理 1代办
*/
private Integer isAgent;
/**
* 取件方式 0自主取件 1邮寄
*/
......@@ -82,9 +67,9 @@ public class YthOnethingEntity extends BaseEntityLong{
private String number;
/**
* 问答内容
* 是否代办 0是本人办理 1他人代办
*/
private String optionContent;
private Integer isAgent;
/**
* 0是否撤销 1撤销
......@@ -167,60 +152,32 @@ public class YthOnethingEntity extends BaseEntityLong{
this.memberId = memberId;
}
/**
* 获取 微信openId
* 获取 微信OPENID
* @return openId
*/
public String getOpenId() {
return this.openId;
}
/**
* 设置 微信openId
* 设置 微信OPENID
* @param openId
*/
public void setOpenId(String openId) {
this.openId = openId;
}
/**
* 获取 事项ID
* @return matterid
*/
public Long getMatterid() {
return this.matterid;
}
/**
* 设置 事项ID
* @param matterid
*/
public void setMatterid(Long matterid) {
this.matterid = matterid;
}
/**
* 获取 上传时间
* @return uploadtime
* 获取 申请主题包id
* @return classifyTopicId
*/
public Integer getUploadtime() {
return this.uploadtime;
public Long getClassifyTopicId() {
return this.classifyTopicId;
}
/**
* 设置 上传时间
* @param uploadtime
* 设置 申请主题包id
* @param classifyTopicId
*/
public void setUploadtime(Integer uploadtime) {
this.uploadtime = uploadtime;
}
/**
* 获取 1资料上传 2确认提交
* @return type
*/
public Integer getType() {
return this.type;
}
/**
* 设置 1资料上传 2确认提交
* @param type
*/
public void setType(Integer type) {
this.type = type;
public void setClassifyTopicId(Long classifyTopicId) {
this.classifyTopicId = classifyTopicId;
}
/**
* 获取 邮寄地址
......@@ -265,20 +222,6 @@ public class YthOnethingEntity extends BaseEntityLong{
this.phone = phone;
}
/**
* 获取 0本人办理 1代办
* @return isAgent
*/
public Integer getIsAgent() {
return this.isAgent;
}
/**
* 设置 0本人办理 1代办
* @param isAgent
*/
public void setIsAgent(Integer isAgent) {
this.isAgent = isAgent;
}
/**
* 获取 取件方式 0自主取件 1邮寄
* @return manner
*/
......@@ -321,18 +264,18 @@ public class YthOnethingEntity extends BaseEntityLong{
this.number = number;
}
/**
* 获取 问答内容
* @return optionContent
* 获取 是否代办 0是本人办理 1他人代办
* @return isAgent
*/
public String getOptionContent() {
return this.optionContent;
public Integer getIsAgent() {
return this.isAgent;
}
/**
* 设置 问答内容
* @param optionContent
* 设置 是否代办 0是本人办理 1他人代办
* @param isAgent
*/
public void setOptionContent(String optionContent) {
this.optionContent = optionContent;
public void setIsAgent(Integer isAgent) {
this.isAgent = isAgent;
}
/**
* 获取 0是否撤销 1撤销
......@@ -458,17 +401,14 @@ public class YthOnethingEntity extends BaseEntityLong{
.append(",processInstanceId:").append(getProcessInstanceId())
.append(",memberId:").append(getMemberId())
.append(",openId:").append(getOpenId())
.append(",matterid:").append(getMatterid())
.append(",uploadtime:").append(getUploadtime())
.append(",type:").append(getType())
.append(",classifyTopicId:").append(getClassifyTopicId())
.append(",address:").append(getAddress())
.append(",linkman:").append(getLinkman())
.append(",phone:").append(getPhone())
.append(",isAgent:").append(getIsAgent())
.append(",manner:").append(getManner())
.append(",getnum:").append(getGetnum())
.append(",number:").append(getNumber())
.append(",optionContent:").append(getOptionContent())
.append(",isAgent:").append(getIsAgent())
.append(",isRevoke:").append(getIsRevoke())
.append(",siteid:").append(getSiteid())
.append(",status:").append(getStatus())
......@@ -482,48 +422,23 @@ public class YthOnethingEntity extends BaseEntityLong{
public void initAttrValue(){
this.taskId = null;
this.processInstanceId = null;
this.memberId = null;
this.openId = null;
this.matterid = null;
this.uploadtime = null;
this.type = null;
this.classifyTopicId = null;
this.address = null;
this.linkman = null;
this.phone = null;
this.isAgent = null;
this.manner = null;
this.getnum = null;
this.number = null;
this.optionContent = null;
this.isAgent = null;
this.isRevoke = null;
this.siteid = null;
this.status = null;
this.updateTime = null;
this.updateUser = null;
this.createTime = null;
this.createUser = null;
}
}
\ No newline at end of file
package com.mortals.xhx.module.yth.service;
import com.mortals.framework.service.ICRUDService;
import com.mortals.xhx.module.yth.model.YthOnethingDetailEntity;
/**
* <p>Title: 一件事提交详细表</p>
* <p>Description: YthOnethingDetailService service接口 </p>
* <p>Copyright: Copyright &reg; </p>
* @version 1.0.0
*/
public interface YthOnethingDetailService extends ICRUDService<YthOnethingDetailEntity,Long>{
}
\ No newline at end of file
......@@ -2,7 +2,7 @@ package com.mortals.xhx.module.yth.service;
import com.mortals.framework.exception.AppException;
import com.mortals.framework.service.ICRUDService;
import com.mortals.xhx.busiz.uploadfile.UploadDatumReq;
import com.mortals.xhx.busiz.uploadfile.SubmitDatumReq;
import com.mortals.xhx.module.yth.model.YthOnethingEntity;
/**
......@@ -17,5 +17,8 @@ public interface YthOnethingService extends ICRUDService<YthOnethingEntity,Long>
* 用户提交资料并发起审核流程
* @param req
*/
void datumUploadAndStartFlow(UploadDatumReq req) throws AppException;
void datumUploadAndStartFlow(SubmitDatumReq req) throws AppException;
void getBusinessDetail(String proInsId);
}
\ No newline at end of file
package com.mortals.xhx.module.yth.service.impl;
import org.springframework.stereotype.Service;
import com.mortals.framework.service.impl.AbstractCRUDServiceImpl;
import com.mortals.xhx.module.yth.dao.YthOnethingDetailDao;
import com.mortals.xhx.module.yth.model.YthOnethingDetailEntity;
import com.mortals.xhx.module.yth.service.YthOnethingDetailService;
/**
* <p>Title: 一件事提交详细表</p>
* <p>Description: YthOnethingDetailService service接口 </p>
* <p>Copyright: Copyright &reg; </p>
* @version 1.0.0
*/
@Service("ythOnethingDetailService")
public class YthOnethingDetailServiceImpl extends AbstractCRUDServiceImpl<YthOnethingDetailDao, YthOnethingDetailEntity, Long> implements YthOnethingDetailService {
}
\ No newline at end of file
package com.mortals.xhx.module.yth.service.impl;
import cn.hutool.core.util.PhoneUtil;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.github.javafaker.Faker;
import com.mortals.framework.exception.AppException;
import com.mortals.framework.service.impl.AbstractCRUDServiceImpl;
import com.mortals.xhx.base.framework.config.InterceptorConfig;
import com.mortals.xhx.base.system.param.service.ParamService;
import com.mortals.xhx.busiz.uploadfile.UploadDatumReq;
import com.mortals.xhx.busiz.uploadfile.MatterReq;
import com.mortals.xhx.busiz.uploadfile.SubmitDatumReq;
import com.mortals.xhx.common.code.ApproveStateEnum;
import com.mortals.xhx.common.code.MannerEnum;
import com.mortals.xhx.common.code.OneThingTypeEnum;
......@@ -16,18 +16,25 @@ import com.mortals.xhx.common.keys.BusizParams;
import com.mortals.xhx.feign.flowable.IApiFlowInstanceFeign;
import com.mortals.xhx.feign.rsp.ApiResp;
import com.mortals.xhx.feign.runtime.StartProcessInstanceReq;
import com.mortals.xhx.module.member.model.MemberEntity;
import com.mortals.xhx.module.member.model.MemberQuery;
import com.mortals.xhx.module.member.service.MemberService;
import com.mortals.xhx.module.one.model.OneClassifyEntity;
import com.mortals.xhx.module.one.model.OneClassifyTopicalEntity;
import com.mortals.xhx.module.one.service.OneClassifyService;
import com.mortals.xhx.module.one.service.OneClassifyTopicalService;
import com.mortals.xhx.module.yth.dao.YthOnethingDao;
import com.mortals.xhx.module.yth.model.YthOnethingDetailEntity;
import com.mortals.xhx.module.yth.model.YthOnethingDetailQuery;
import com.mortals.xhx.module.yth.model.YthOnethingEntity;
import com.mortals.xhx.module.yth.model.YthOnethingQuery;
import com.mortals.xhx.module.yth.service.YthOnethingDetailService;
import com.mortals.xhx.module.yth.service.YthOnethingService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.util.ObjectUtils;
import java.util.Date;
import java.util.List;
import java.util.Locale;
import java.util.Map;
import java.util.*;
import java.util.stream.Collectors;
/**
......@@ -49,21 +56,30 @@ public class YthOnethingServiceImpl extends AbstractCRUDServiceImpl<YthOnethingD
@Autowired
private InterceptorConfig config;
@Autowired
private YthOnethingDetailService ythOnethingDetailService;
@Autowired
private IApiFlowInstanceFeign apiFlowInstanceFeign;
@Autowired
private OneClassifyTopicalService oneClassifyTopicalService;
@Autowired
private OneClassifyService oneClassifyService;
@Override
public void datumUploadAndStartFlow(UploadDatumReq req) {
public void datumUploadAndStartFlow(SubmitDatumReq req) {
try {
//保存一件事
YthOnethingEntity entity = new YthOnethingEntity();
entity.setMemberId(memberService.selectOne(new MemberQuery().openId(req.getOpen_id()), null).getId());
entity.setOpenId(req.getOpen_id());
entity.setMatterid(req.getMatterid());
entity.setOptionContent(req.getOption_content());
MemberEntity memberEntity = memberService.selectOne(new MemberQuery().openId(req.getOpenId()));
if(ObjectUtils.isEmpty(memberEntity)){
throw new AppException(String.format("未找到当前openId:%s 对应的用户", req.getOpenId()));
}
entity.setMemberId(memberEntity.getId());
entity.setOpenId(req.getOpenId());
entity.setManner(MannerEnum.SELF.getValue());
entity.setSiteid(req.getSiteid().intValue());
entity.setIsAgent(req.getIs_agent());
entity.setSiteid(req.getSiteId().intValue());
entity.setIsAgent(req.getIsAgent());
entity.setIsRevoke(YesNoEnum.NO.getValue());
entity.setClassifyTopicId(req.getClassifyTopicId());
Faker faker = new Faker(Locale.CHINESE);
......@@ -72,27 +88,30 @@ public class YthOnethingServiceImpl extends AbstractCRUDServiceImpl<YthOnethingD
entity.setPhone(138);
entity.setGetnum(faker.number().digits(12));
entity.setNumber(faker.idNumber().validSvSeSsn());
entity.setUploadtime(123);
entity.setType(OneThingTypeEnum.UNSUBMIT.getValue());
entity.setStatus(ApproveStateEnum.UN_AUDIT.getValue());
entity.setCreateUser("admin");
entity.setCreateUser("system");
entity.setCreateTime(new Date());
YthOnethingEntity save = this.save(entity);
//保存材料附件
// List<DatumFileEntity> fileList = req.getFile_arr().stream().map(item -> {
// DatumFileEntity datumFileEntity = new DatumFileEntity();
// datumFileEntity.setTid(save.getId());
// datumFileEntity.setDatumid(item.getDatumid());
// datumFileEntity.setFile(item.getFile());
// datumFileEntity.setUploadtime(new Date());
// datumFileEntity.setCreateTime(new Date());
// datumFileEntity.setCreateUser("admin");
// return datumFileEntity;
// }).collect(Collectors.toList());
// datumFileService.save(fileList);
List<YthOnethingDetailEntity> detailList = req.getMatterReqList().stream().flatMap(item -> {
return item.getAttachmentList().stream().map(m1 -> {
YthOnethingDetailEntity detailEntity = new YthOnethingDetailEntity();
detailEntity.setMatterId(item.getMatterid());
detailEntity.setOneThingId(save.getId());
detailEntity.setDatumId(m1.getDatumId());
detailEntity.setFileName(m1.getFileName());
detailEntity.setFilepath(m1.getFilepath());
detailEntity.setCreateTime(new Date());
detailEntity.setCreateUser("system");
return detailEntity;
});
}).collect(Collectors.toList());
ythOnethingDetailService.save(detailList);
//获取流程定义key 发起流程 当前通过param参数固定获取
String oneThingKey = paramService.getValueByKey(BusizParams.SYS_PARAM_FLOW_KEY);
......@@ -111,7 +130,6 @@ public class YthOnethingServiceImpl extends AbstractCRUDServiceImpl<YthOnethingD
ApiResp<String> resp = apiFlowInstanceFeign.processStart(startProcessInstanceReq);
entity.setProcessInstanceId(resp.getData());
entity.setType(OneThingTypeEnum.SUBMIT.getValue());
entity.setStatus(ApproveStateEnum.AUDITING.getValue());
this.update(entity);
......@@ -120,5 +138,27 @@ public class YthOnethingServiceImpl extends AbstractCRUDServiceImpl<YthOnethingD
}
}
@Override
public void getBusinessDetail(String proInsId) {
YthOnethingEntity ythOnethingEntity = this.selectOne(new YthOnethingQuery().processInstanceId(proInsId));
if(ObjectUtils.isEmpty(ythOnethingEntity)){
throw new AppException("未找到相关业务!");
}
OneClassifyTopicalEntity classifyTopicalEntity = oneClassifyTopicalService.get(ythOnethingEntity.getClassifyTopicId());
OneClassifyEntity oneClassifyEntity = oneClassifyService.get(classifyTopicalEntity.getClassifyId());
//查询提交的附件信息及事项名称
YthOnethingDetailQuery query = new YthOnethingDetailQuery().oneThingId(ythOnethingEntity.getId());
query.setGroupList(Arrays.asList("matterId"));
List<YthOnethingDetailEntity> detailEntityList = ythOnethingDetailService.find(query);
}
}
\ No newline at end of file
package com.mortals.xhx.module.yth.web;
import com.alibaba.fastjson.JSONObject;
import com.mortals.framework.exception.AppException;
import com.mortals.framework.model.Context;
import com.mortals.framework.model.OrderCol;
import com.mortals.xhx.common.code.*;
import com.mortals.xhx.common.pdu.flow.FlowViewerPdu;
import io.swagger.annotations.ApiParam;
import org.springframework.util.ObjectUtils;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
import com.mortals.framework.web.BaseCRUDJsonMappingController;
import com.mortals.xhx.module.yth.model.YthOnethingEntity;
......@@ -13,6 +19,8 @@ import com.mortals.xhx.module.yth.service.YthOnethingService;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import java.util.Map;
......@@ -54,4 +62,26 @@ public class YthOnethingController extends BaseCRUDJsonMappingController<YthOnet
}
/**
* 获取业务详细信息
*/
@PostMapping(value = "getBusinessDetail")
public String getBusinessById(@ApiParam(value = "流程Id") @RequestParam(value = "proInsId") String proInsId) {
log.info("receive getBusinessDetail,proInsId:" + proInsId);
JSONObject ret = new JSONObject();
try {
//ret.put(KEY_RESULT_DATA, flowViewers);
ret.put(KEY_RESULT_CODE, VALUE_RESULT_SUCCESS);
} catch (Exception e) {
log.error("读取流程图片异常", e);
ret.put(KEY_RESULT_CODE, VALUE_RESULT_FAILURE);
ret.put(KEY_RESULT_MSG, super.convertException(e));
}
return ret.toJSONString();
}
}
\ No newline at end of file
package com.mortals.xhx.module.yth.web;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import com.mortals.framework.web.BaseCRUDJsonMappingController;
import com.mortals.xhx.module.yth.model.YthOnethingDetailEntity;
import com.mortals.xhx.module.yth.service.YthOnethingDetailService;
/**
* <p>Title: 一件事提交详细表</p>
* <p>Description: YthOnethingDetailController </p>
* <p>Copyright: Copyright &reg; </p>
* <p>Company: </p>
* @author zxfei
* @version 1.0.0
*/
@RestController
@RequestMapping("yth/onething/detail")
public class YthOnethingDetailController extends BaseCRUDJsonMappingController<YthOnethingDetailService,YthOnethingDetailForm,YthOnethingDetailEntity,Long> {
public YthOnethingDetailController(){
super.setFormClass(YthOnethingDetailForm.class);
super.setModuleDesc("一件事提交详细表");
}
}
\ No newline at end of file
package com.mortals.xhx.module.yth.web;
import com.mortals.framework.web.BaseCRUDFormLong;
import com.mortals.xhx.module.yth.model.YthOnethingDetailEntity;
import com.mortals.xhx.module.yth.model.YthOnethingDetailQuery;
/**
* <p>Title: 一件事提交详细表</p>
* <p>Description: YthOnethingDetailForm </p>
* @author
* @version 1.0.0
*/
public class YthOnethingDetailForm extends BaseCRUDFormLong<YthOnethingDetailEntity> {
private YthOnethingDetailEntity entity = new YthOnethingDetailEntity();
private YthOnethingDetailQuery query = new YthOnethingDetailQuery();
public YthOnethingDetailForm(){
}
@Override
public YthOnethingDetailEntity getEntity() {
return entity;
}
public void setYthOnethingDetail(YthOnethingDetailEntity entity) {
this.entity = entity;
}
@Override
public YthOnethingDetailQuery getQuery() {
return query;
}
public void setQuery(YthOnethingDetailQuery query) {
this.query = query;
}
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment