Merge remote-tracking branch 'origin/develop_master' into develop_3
This commit is contained in:
@@ -12,6 +12,8 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMethod;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Set;
|
||||
@@ -20,6 +22,12 @@ import java.util.Set;
|
||||
//@FeignClient(value = "shan6")
|
||||
public interface workFlowFeignClient {
|
||||
|
||||
@RequestMapping(value = "/bat-wkflow/busProcessModel/saveEditFile",method = RequestMethod.GET)
|
||||
BusProcessModelHis saveEditFile();
|
||||
|
||||
@RequestMapping(value = "/bat-wkflow/busProcessModel/processEditFile",method = RequestMethod.GET)
|
||||
BusProcessModelHis processEditFile(@RequestParam("id") String id);
|
||||
|
||||
@RequestMapping(value = "/bat-wkflow/busProcessModel/processModelHisOneUpdStatus",method = RequestMethod.GET)
|
||||
BusProcessModelHis processModelHisOneUpdStatus(@RequestParam("pid") String pid, @RequestParam("taskId") String taskId);
|
||||
|
||||
|
||||
@@ -16,6 +16,8 @@ import org.springframework.stereotype.Component;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
@@ -28,6 +30,16 @@ public class workFlowFeignClientImpl {
|
||||
@Autowired
|
||||
private IUserEOService userEOService;
|
||||
|
||||
public BusProcessModelHis saveEditFile(){
|
||||
BusProcessModelHis stringWrapper = workFlowFeignClient.saveEditFile();
|
||||
return stringWrapper;
|
||||
}
|
||||
|
||||
public BusProcessModelHis processEditFile(@RequestParam("id") String id){
|
||||
BusProcessModelHis stringWrapper = workFlowFeignClient.processEditFile(id);
|
||||
return stringWrapper;
|
||||
}
|
||||
|
||||
public BusProcessModelHis processModelHisOneUpdStatus(@RequestParam("pid") String pid,@RequestParam("taskId") String taskId){
|
||||
BusProcessModelHis stringWrapper = workFlowFeignClient.processModelHisOneUpdStatus(pid,taskId);
|
||||
return stringWrapper;
|
||||
|
||||
@@ -66,7 +66,64 @@ public class WorkFlowController {
|
||||
// @Autowired
|
||||
// private ExportExcelMapper exportExcelMapper;
|
||||
|
||||
@ApiOperation(value = "|File|下载文件")
|
||||
@GetMapping("/downloadFileForSar")
|
||||
// @RequiresPermissions("sys:file:downloadFileForSar")
|
||||
public void downloadFileForSar(String fileId, String oldFileName, HttpServletResponse response, HttpServletRequest request) throws Exception {
|
||||
BusProcessModelHis modelHisOne = workFlowFeignClient.processEditFile(fileId);
|
||||
InputStream is = null;
|
||||
OutputStream os = null;
|
||||
response.reset();
|
||||
try {
|
||||
String fileOldName = fileNameEncoding(oldFileName,request);
|
||||
response.setHeader("Content-Disposition", "attachment;filename=\""+fileOldName+"\"");
|
||||
response.setContentType("application/octet-stream");
|
||||
File file = new File(standEditFilePath+modelHisOne.getEditFilePath());
|
||||
is = new FileInputStream(file);
|
||||
os = response.getOutputStream();
|
||||
org.apache.commons.io.IOUtils.copy(is, os);
|
||||
os.flush();
|
||||
} catch (IOException e) {
|
||||
logger.error(e.getMessage(), e);
|
||||
} finally {
|
||||
org.apache.commons.io.IOUtils.closeQuietly(is);
|
||||
org.apache.commons.io.IOUtils.closeQuietly(os);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @Author super_liu
|
||||
* @Description 根据不同浏览器定义下载文件编码
|
||||
* Date 2018/10/11 10:40
|
||||
* @Param [fileName, request]
|
||||
* @return java.lang.String
|
||||
**/
|
||||
public String fileNameEncoding(String fileName, HttpServletRequest request) throws IOException {
|
||||
String agent = request.getHeader("User-Agent");
|
||||
if (agent.contains("Firefox")) {
|
||||
/*BASE64Encoder base64Encoder = new BASE64Encoder();
|
||||
fileName = "=?utf-8?B?"
|
||||
+ base64Encoder.encode(fileName.getBytes("utf-8")) + "?=";*/
|
||||
fileName = new String(fileName.getBytes("UTF-8"), "ISO8859-1"); // firefox浏览器
|
||||
} else {
|
||||
fileName = URLEncoder.encode(fileName, "utf-8");
|
||||
//谷歌中空格变为+问题
|
||||
fileName = fileName.replaceAll("\\+","%20");
|
||||
}
|
||||
return fileName;
|
||||
}
|
||||
|
||||
@ApiOperation(value = "存储在线编辑文件")
|
||||
@GetMapping("/saveEditFile")
|
||||
public BusProcessModelHis saveEditFile(){
|
||||
return workFlowFeignClient.saveEditFile();
|
||||
}
|
||||
|
||||
@ApiOperation(value = "查询在线编辑流程汇总文件编辑对象")
|
||||
@GetMapping("/processEditFile")
|
||||
public BusProcessModelHis processEditFile(@RequestParam("id") String id){
|
||||
return workFlowFeignClient.processEditFile(id);
|
||||
}
|
||||
|
||||
@ApiOperation(value = "手机获取token")
|
||||
@PostMapping(value = "/loginMobile")
|
||||
|
||||
@@ -72,6 +72,12 @@ public class WebMvcConfig implements WebMvcConfigurer {
|
||||
|
||||
addInterceptor.excludePathPatterns("/api/lawss/activiti/processModelHisOne");
|
||||
|
||||
addInterceptor.excludePathPatterns("/api/lawss/activiti/downloadFileForSar");
|
||||
|
||||
addInterceptor.excludePathPatterns("/api/lawss/activiti/saveEditFile");
|
||||
|
||||
addInterceptor.excludePathPatterns("/api/lawss/activiti/processEditFile");
|
||||
|
||||
addInterceptor.excludePathPatterns("/api/lawss/activiti/processModelHisOneCount");
|
||||
|
||||
addInterceptor.excludePathPatterns("/api/att/attFile/getSyncPdfFileInfo");
|
||||
|
||||
@@ -122,5 +122,7 @@ public class EsRevisePlan extends BasePage {
|
||||
@TableField(exist = false)
|
||||
private List<String> planStatusList;
|
||||
|
||||
|
||||
@ApiModelProperty(value = "立项单")
|
||||
@TableField("LXD")
|
||||
private String lxd;
|
||||
}
|
||||
|
||||
+1
-1
@@ -56,7 +56,7 @@ public class SarVppsTreeServiceImpl extends ServiceImpl<SarVppsTreeDao, SarVppsT
|
||||
|
||||
|
||||
if(parent.getLevel()!=0){
|
||||
sarMenuQueryWrapper.like("VPPS_CODE",parent.getId());
|
||||
sarMenuQueryWrapper.likeRight("VPPS_CODE",parent.getId());
|
||||
}
|
||||
List<SarVppsTree> children=this.baseMapper.selectList(sarMenuQueryWrapper);
|
||||
|
||||
|
||||
@@ -75,6 +75,7 @@
|
||||
<result property="useLevel" column="use_level"/>
|
||||
<result property="technologic" column="technologic"/>
|
||||
<result property="bussSort" column="buss_sort"/>
|
||||
<result property="lxd" column="LXD"/>
|
||||
</resultMap>
|
||||
<!-- 查询条件-->
|
||||
<sql id="Conditions">
|
||||
@@ -140,6 +141,7 @@
|
||||
es_revise_plan.use_level,
|
||||
es_revise_plan.technologic,
|
||||
es_revise_plan.buss_sort,
|
||||
es_revise_plan.LXD,
|
||||
sar_bussioness_stand.STAND_CODE as rqbName,
|
||||
sar_bussioness_stand.STAND_SORT as standType,
|
||||
(select group_concat(ts_institution.name) from ts_institution where find_in_set(ts_institution.id,unit)) as unitName,
|
||||
@@ -208,6 +210,7 @@
|
||||
es_revise_plan.use_level,
|
||||
es_revise_plan.technologic,
|
||||
es_revise_plan.buss_sort,
|
||||
es_revise_plan.LXD,
|
||||
sar_bussioness_stand.STAND_CODE as rqbName,
|
||||
sar_bussioness_stand.STAND_SORT as standType,
|
||||
sar_bussioness_stand.stand_number as standNum,
|
||||
@@ -280,6 +283,7 @@
|
||||
es_revise_plan.use_level,
|
||||
es_revise_plan.technologic,
|
||||
es_revise_plan.buss_sort,
|
||||
es_revise_plan.LXD,
|
||||
sar_bussioness_stand.STAND_CODE as rqbName,
|
||||
sar_bussioness_stand.STAND_SORT as standType,
|
||||
(select group_concat(ts_institution.name) from ts_institution where find_in_set(ts_institution.id,unit)) as unitName,
|
||||
@@ -354,6 +358,9 @@
|
||||
<if test="bussSort != null and bussSort != ''">
|
||||
buss_sort=#{bussSort},
|
||||
</if>
|
||||
<if test="lxd != null and lxd != ''">
|
||||
LXD=#{lxd},
|
||||
</if>
|
||||
</set>
|
||||
where id = #{id}
|
||||
</update>
|
||||
@@ -418,6 +425,9 @@
|
||||
<if test="bussSort != null and bussSort != ''">
|
||||
buss_sort,
|
||||
</if>
|
||||
<if test="lxd != null and lxd != ''">
|
||||
LXD,
|
||||
</if>
|
||||
</trim>
|
||||
values
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
@@ -478,6 +488,9 @@
|
||||
<if test="bussSort != null and bussSort != ''">
|
||||
#{bussSort},
|
||||
</if>
|
||||
<if test="lxd != null and lxd != ''">
|
||||
#{lxd},
|
||||
</if>
|
||||
</trim>
|
||||
</insert>
|
||||
<!-- 删除-->
|
||||
@@ -513,6 +526,7 @@
|
||||
es_revise_plan.use_level,
|
||||
es_revise_plan.technologic,
|
||||
es_revise_plan.buss_sort,
|
||||
es_revise_plan.LXD,
|
||||
sar_bussioness_stand.STAND_CODE as rqbName,
|
||||
sar_bussioness_stand.STAND_SORT as standType,
|
||||
(select group_concat(ts_institution.name) from ts_institution where find_in_set(ts_institution.id,unit)) as unitName,
|
||||
|
||||
Reference in New Issue
Block a user