沧州矿石数据对接盲板作业、临时用电、吊装作业
parent
4e4ac731e6
commit
ba3754c78f
|
@ -109,6 +109,7 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
pd.put("OTHER_PROTECTIVE_MEASURES", (StringUtils.isNotBlank(pd.getString("OTHER_PROTECTIVE_MEASURES")) ? pd.getString("OTHER_PROTECTIVE_MEASURES") : "") + ";_;");
|
||||
pd.put("ISDELETE", "0"); //是否删除 1-是 0-否
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
|
@ -117,6 +118,8 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
|
||||
pd.put("APPLY_USER_SIGNER_PATH", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName);
|
||||
pd.put("APPLY_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
}
|
||||
map.put("dockData",JSON.toJSONString(pd));
|
||||
GFblindboardService.save(pd);
|
||||
|
@ -224,13 +227,16 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
PageData pd = new PageData();
|
||||
pd = this.getPageData();
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
String fileName = this.get32UUID()+file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
|
||||
smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile);
|
||||
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
map.put("path", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
}
|
||||
|
||||
map.put("result", errInfo);
|
||||
|
@ -251,6 +257,7 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
PageData pd = new PageData();
|
||||
pd = this.getPageData();
|
||||
smb.deleteFile(pd.getString("path"));
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
map.put("result", errInfo);
|
||||
return map;
|
||||
}
|
||||
|
@ -260,12 +267,14 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
*/
|
||||
@RequestMapping(value="/delete")
|
||||
@ResponseBody
|
||||
@DockAnnotation
|
||||
public Object delete() throws Exception{
|
||||
Map<String,String> map = new HashMap<String,String>();
|
||||
String errInfo = "success";
|
||||
PageData pd = new PageData();
|
||||
pd = this.getPageData();
|
||||
GFblindboardService.delete(pd);
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
map.put("result", errInfo); //返回结果
|
||||
return map;
|
||||
}
|
||||
|
@ -277,6 +286,7 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
@RequestMapping(value="/edit")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
@DockAnnotation(hasAnnex = true)
|
||||
public Object edit(
|
||||
@RequestParam(value="FFILE",required=false) MultipartFile[] files
|
||||
) throws Exception{
|
||||
|
@ -287,6 +297,7 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
pd.put("OPERATTIME", DateUtil.date2Str(new Date())); //修改时间
|
||||
pd.put("OTHER_PROTECTIVE_MEASURES", (StringUtils.isNotBlank(pd.getString("OTHER_PROTECTIVE_MEASURES")) ? pd.getString("OTHER_PROTECTIVE_MEASURES") : "") + ";_;");
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
|
@ -295,12 +306,17 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
|
||||
pd.put("APPLY_USER_SIGNER_PATH", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName);
|
||||
pd.put("APPLY_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
}
|
||||
GFblindboardService.edit(pd);
|
||||
|
||||
GFblindBoardInfoService.delete(pd);
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
if(pd.get("boardList")!=null){
|
||||
List<JSONObject> list = (List<JSONObject>) JSON.parse(pd.get("boardList").toString());
|
||||
HashMap<String, String> infoMap = new HashMap<String, String>();
|
||||
int count = 1;
|
||||
for (JSONObject json : list) {
|
||||
PageData board = new PageData();
|
||||
board.put("BLINDBOARDINFO_ID", this.get32UUID()); // 主键
|
||||
|
@ -310,13 +326,18 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
board.put("BOARD_SPECIFICATION", json.get("BOARD_SPECIFICATION"));
|
||||
board.put("BOARD_NO", json.get("BOARD_NO"));
|
||||
board.put("ISDELETE", 0);
|
||||
infoMap.put("other"+count, JSON.toJSONString(board));
|
||||
count+=1;
|
||||
GFblindBoardInfoService.save(board);
|
||||
}
|
||||
map.put("infoMap", JSON.toJSONString(infoMap));
|
||||
}
|
||||
|
||||
GFblindBoardToMeasuresService.delete(pd);
|
||||
if(pd.get("measuresList")!=null){
|
||||
List<JSONObject> list = (List<JSONObject>) JSON.parse(pd.get("measuresList").toString());
|
||||
HashMap<String, String> measuresMap = new HashMap<String, String>();
|
||||
int count = 1;
|
||||
for (JSONObject json : list) {
|
||||
PageData measures = new PageData();
|
||||
measures.put("BLINDBOARDTOMEASURES_ID", this.get32UUID()); // 主键
|
||||
|
@ -325,8 +346,11 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
measures.put("STATUS", json.get("STATUS"));
|
||||
measures.put("CONFIRM_ID", pd.get("OPERATOR"));
|
||||
measures.put("CONFIRM_NAME", pd.get("ACTION_USER"));
|
||||
measuresMap.put("other"+count, JSON.toJSONString(measures));
|
||||
count+=1;
|
||||
GFblindBoardToMeasuresService.save(measures);
|
||||
}
|
||||
map.put("measuresMap", JSON.toJSONString(measuresMap));
|
||||
}
|
||||
|
||||
if(!pd.get("APPLY_STATUS").equals("0")) {
|
||||
|
@ -337,6 +361,7 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
log.put("CREATOR",pd.get("ACTION_USER"));
|
||||
log.put("CREATTIME", DateUtil.date2Str(new Date()));
|
||||
GFblindBoardLogService.save(log);
|
||||
map.put("logData", JSON.toJSONString(log));
|
||||
|
||||
|
||||
// 发短信
|
||||
|
@ -381,6 +406,7 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
@RequestMapping(value="/editStatus")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
@DockAnnotation(hasAnnex = true)
|
||||
public Object editStatus(
|
||||
@RequestParam(value="FFILE",required=false) MultipartFile[] files
|
||||
) throws Exception{
|
||||
|
@ -408,22 +434,28 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
switch (status) {
|
||||
case "4"://作业负责人
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
String fileName = this.get32UUID()+file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
|
||||
smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile);
|
||||
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
pd2.put("CONSTRUCTION_USER_SIGNER_PATH", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName);
|
||||
pd2.put("CONSTRUCTION_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
pd2.put("CONSTRUCTION_CONTENT", pd.get("CONTENT"));
|
||||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
pd2.put("OTHER_PROTECTIVE_MEASURES", OTHER_PROTECTIVE_MEASURES);
|
||||
GFblindboardService.edit(pd2);
|
||||
map.put("pd2Data", JSON.toJSONString(pd2));
|
||||
log.put("ACTION", "作业负责人通过");
|
||||
if(pd.get("boardList")!=null){
|
||||
GFblindBoardInfoService.delete(pd);
|
||||
List<JSONObject> list = (List<JSONObject>) JSON.parse(pd.get("boardList").toString());
|
||||
HashMap<String,String> boardMap = new HashMap<String,String>();
|
||||
int boardCount = 1;
|
||||
for (JSONObject json : list) {
|
||||
PageData board = new PageData();
|
||||
board.put("BLINDBOARDINFO_ID", this.get32UUID()); // 主键
|
||||
|
@ -433,13 +465,19 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
board.put("BOARD_SPECIFICATION", json.get("BOARD_SPECIFICATION"));
|
||||
board.put("BOARD_NO", json.get("BOARD_NO"));
|
||||
board.put("ISDELETE", 0);
|
||||
boardMap.put("other"+boardCount, JSON.toJSONString(board));
|
||||
boardCount+=1;
|
||||
GFblindBoardInfoService.save(board);
|
||||
}
|
||||
map.put("boardMap", JSON.toJSONString(boardMap));
|
||||
}
|
||||
|
||||
GFblindBoardToMeasuresService.delete(pd);
|
||||
map.put("pdData", JSON.toJSONString(pd));
|
||||
if(pd.get("measuresList")!=null){
|
||||
List<JSONObject> list = (List<JSONObject>) JSON.parse(pd.get("measuresList").toString());
|
||||
HashMap<String,String> measuresMap = new HashMap<String,String>();
|
||||
int measuresCount = 1;
|
||||
for (JSONObject json : list) {
|
||||
PageData measures = new PageData();
|
||||
measures.put("BLINDBOARDTOMEASURES_ID", this.get32UUID()); // 主键
|
||||
|
@ -448,8 +486,11 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
measures.put("STATUS", json.get("STATUS"));
|
||||
measures.put("CONFIRM_ID", pd.get("OPERATOR"));
|
||||
measures.put("CONFIRM_NAME", pd.get("ACTION_USER"));
|
||||
measuresMap.put("other"+measuresCount, JSON.toJSONString(measures));
|
||||
measuresCount+=1;
|
||||
GFblindBoardToMeasuresService.save(measures);
|
||||
}
|
||||
map.put("measuresData", JSON.toJSONString(measuresMap));
|
||||
}
|
||||
|
||||
|
||||
|
@ -460,11 +501,14 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
|
||||
case "5"://所在单位审核通过
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
String fileName = this.get32UUID()+file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
|
||||
smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile);
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
|
||||
pd2.put("LEADER_USER_SIGNER_PATH", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName);
|
||||
pd2.put("LEADER_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
|
@ -472,6 +516,7 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
pd2.put("OTHER_PROTECTIVE_MEASURES", OTHER_PROTECTIVE_MEASURES);
|
||||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
GFblindboardService.edit(pd2);
|
||||
map.put("pd2Data", JSON.toJSONString(pd2));
|
||||
log.put("ACTION", "所在单位审核通过");
|
||||
|
||||
// 发短信
|
||||
|
@ -481,18 +526,22 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
|
||||
case "6"://验收人
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
String fileName = this.get32UUID()+file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
|
||||
smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile);
|
||||
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
pd2.put("ACCEPT_USER_SIGNER_PATH", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName);
|
||||
pd2.put("ACCEPT_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
pd2.put("ACCEPT_CONTENT", pd.get("CONTENT"));
|
||||
pd2.put("OTHER_PROTECTIVE_MEASURES", OTHER_PROTECTIVE_MEASURES);
|
||||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
GFblindboardService.edit(pd2);
|
||||
map.put("pd2Data", JSON.toJSONString(pd2));
|
||||
log.put("ACTION", "验收通过");
|
||||
// 发短信
|
||||
this.switchMessages(pd.get("APPLY_STATUS").toString(),pd2);
|
||||
|
@ -503,6 +552,7 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
pd2.put("SAFETY_CONTENT", pd.get("CONTENT"));
|
||||
GFblindboardService.edit(pd2);
|
||||
map.put("pd2Data", JSON.toJSONString(pd2));
|
||||
|
||||
// 发短信
|
||||
this.switchMessages(pd.get("APPLY_STATUS").toString(),pd2);
|
||||
|
@ -512,6 +562,7 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
pd2.put("LEADER_CONTENT", pd.get("CONTENT"));
|
||||
GFblindboardService.edit(pd2);
|
||||
map.put("pd2Data", JSON.toJSONString(pd2));
|
||||
|
||||
// 发短信
|
||||
this.switchMessages(pd.get("APPLY_STATUS").toString(),pd2);
|
||||
|
@ -521,6 +572,7 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
pd2.put("ACCEPT_CONTENT", pd.get("CONTENT"));
|
||||
GFblindboardService.edit(pd2);
|
||||
map.put("pd2Data", JSON.toJSONString(pd2));
|
||||
|
||||
// 发短信
|
||||
this.switchMessages(pd.get("APPLY_STATUS").toString(),pd2);
|
||||
|
@ -529,6 +581,7 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
break;
|
||||
}
|
||||
GFblindBoardLogService.save(log);
|
||||
map.put("logData", JSON.toJSONString(log));
|
||||
map.put("result", errInfo);
|
||||
return map;
|
||||
}
|
||||
|
@ -597,6 +650,7 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
@RequestMapping(value="/editAcceptStatus")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
@DockAnnotation(hasAnnex = true)
|
||||
public Object editAcceptStatus(MultipartRequest request) throws Exception{
|
||||
Map<String,Object> map = new HashMap<String,Object>();
|
||||
String errInfo = "success";
|
||||
|
@ -613,6 +667,7 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
log.put("CREATOR",pd.get("ACTION_USER"));
|
||||
log.put("CREATTIME", DateUtil.date2Str(new Date()));
|
||||
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
String status = pd.get("STATUS").toString();
|
||||
String OTHER_PROTECTIVE_MEASURES = (StringUtils.isNotBlank(pd2.getString("OTHER_PROTECTIVE_MEASURES")) ? pd2.getString("OTHER_PROTECTIVE_MEASURES") : "") +
|
||||
(StringUtils.isNotBlank(pd.getString("OTHER_PROTECTIVE_MEASURES")) ? (pd.getString("OTHER_PROTECTIVE_MEASURES") + ";_;") : ";_;");
|
||||
|
@ -628,16 +683,19 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
String SIGNTIME[] = pd.getString("SIGNTIME").split(",");
|
||||
|
||||
for (int i = 0; i < SIGNTIME.length; i++) {
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
signertime = SIGNTIME[i];
|
||||
fileList.add(request.getFile("file"+i));
|
||||
MultipartFile[] fileArr = new MultipartFile[fileList.size()];
|
||||
saveAcceptImg(fileList.toArray(fileArr),signertime,pd.getString("BLINDBOARD_ID"),pd.getString("CORPINFO_ID"),pd.getString("ACCEPT_USER_ID"),pd.getString("ACCEPT_DEPARTMENT_ID"));
|
||||
saveAcceptImg(fileList.toArray(fileArr),signertime,pd.getString("BLINDBOARD_ID"),pd.getString("CORPINFO_ID"),pd.getString("ACCEPT_USER_ID"),pd.getString("ACCEPT_DEPARTMENT_ID"),pictureList);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
fileList.clear();
|
||||
}
|
||||
pd2.put("ACCEPT_CONTENT", pd.get("CONTENT"));
|
||||
pd2.put("OTHER_PROTECTIVE_MEASURES", OTHER_PROTECTIVE_MEASURES);
|
||||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
GFblindboardService.edit(pd2);
|
||||
map.put("pd2Data", JSON.toJSONString(pd2));
|
||||
log.put("ACTION", "验收通过");
|
||||
// 发短信
|
||||
this.switchMessages(pd.get("APPLY_STATUS").toString(),pd2);
|
||||
|
@ -649,6 +707,7 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
pd2.put("ACCEPT_CONTENT", pd.get("CONTENT"));
|
||||
GFblindboardService.edit(pd2);
|
||||
map.put("pd2Data", JSON.toJSONString(pd2));
|
||||
|
||||
// 发短信
|
||||
this.switchMessages(pd.get("APPLY_STATUS").toString(),pd2);
|
||||
|
@ -657,11 +716,12 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
break;
|
||||
}
|
||||
GFblindBoardLogService.save(log);
|
||||
map.put("logData", JSON.toJSONString(log));
|
||||
map.put("result", errInfo);
|
||||
return map;
|
||||
}
|
||||
|
||||
private void saveAcceptImg(MultipartFile[] files,String signertime, String BLINDBOARD_ID, String CORPINFO_ID, String ACCEPT_USER_ID, String ACCEPT_DEPARTMENT_ID) throws Exception{
|
||||
private void saveAcceptImg(MultipartFile[] files,String signertime, String BLINDBOARD_ID, String CORPINFO_ID, String ACCEPT_USER_ID, String ACCEPT_DEPARTMENT_ID, ArrayList<String> pictureList) throws Exception{
|
||||
if (files != null && files.length > 0) {
|
||||
for (int i = 0; i < files.length; i++) {
|
||||
PageData cpd = new PageData();
|
||||
|
@ -682,6 +742,7 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
cpd.put("ACCEPT_CONFESS_DEPARTMENT_ID", "");
|
||||
cpd.put("ACCEPT_CONFESS_USER_ID", "");
|
||||
cpd.put("ACCEPT_DEPARTMENT_ID", ACCEPT_DEPARTMENT_ID);
|
||||
pictureList.add(Const.FILEPATHFILE + cpd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
blindboardacceptuserService.save(cpd);
|
||||
}
|
||||
}
|
||||
|
@ -695,6 +756,7 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
*/
|
||||
@RequestMapping(value="/deleteAll")
|
||||
@ResponseBody
|
||||
@DockAnnotation
|
||||
public Object deleteAll() throws Exception{
|
||||
Map<String,Object> map = new HashMap<String,Object>();
|
||||
String errInfo = "success";
|
||||
|
@ -708,6 +770,7 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
}else{
|
||||
errInfo = "error";
|
||||
}
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
map.put("result", errInfo); //返回结果
|
||||
return map;
|
||||
}
|
||||
|
@ -886,6 +949,7 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
@RequestMapping(value="/editGuardian")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
@DockAnnotation(hasAnnex = true)
|
||||
public Object editGuardian(
|
||||
@RequestParam(value="FFILE",required=false) MultipartFile[] files
|
||||
) throws Exception{
|
||||
|
@ -898,15 +962,19 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
pd2.put("OPERATOR", pd.get("OPERATOR")); //修改人
|
||||
pd2.put("OPERATTIME", DateUtil.date2Str(new Date())); //修改时间
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
String fileName = this.get32UUID()+file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
|
||||
smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile);
|
||||
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
pd2.put("GUARDIAN_USER_SIGNER_PATH", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName);
|
||||
pd2.put("GUARDIAN_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
GFblindboardService.edit(pd2);
|
||||
map.put("dockData", JSON.toJSONString(pd2));
|
||||
}
|
||||
map.put("result", errInfo);
|
||||
return map;
|
||||
|
@ -979,6 +1047,7 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
@RequestMapping(value="/editConfess")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
@DockAnnotation(hasAnnex = true)
|
||||
public Object editConfess(
|
||||
@RequestParam(value="FFILE",required=false) MultipartFile[] files
|
||||
) throws Exception{
|
||||
|
@ -991,15 +1060,19 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
pd2.put("OPERATOR", pd.get("OPERATOR")); //修改人
|
||||
pd2.put("OPERATTIME", DateUtil.date2Str(new Date())); //修改时间
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
String fileName = this.get32UUID()+file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
|
||||
smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile);
|
||||
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
pd2.put("CONFESS_USER_SIGNER_PATH", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName);
|
||||
pd2.put("CONFESS_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
GFblindboardService.edit(pd2);
|
||||
map.put("dockData", JSON.toJSONString(pd2));
|
||||
}
|
||||
map.put("result", errInfo);
|
||||
return map;
|
||||
|
@ -1011,6 +1084,7 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
@RequestMapping(value="/editAcceptconfess")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
@DockAnnotation(hasAnnex = true)
|
||||
public Object editAcceptconfess(
|
||||
MultipartRequest request
|
||||
) throws Exception {
|
||||
|
@ -1022,21 +1096,26 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
pd2 = GFblindboardService.findById(pd);
|
||||
pd2.put("OPERATOR", pd.get("OPERATOR")); //修改人
|
||||
pd2.put("OPERATTIME", DateUtil.date2Str(new Date())); //修改时间
|
||||
map.put("dockData", JSON.toJSONString(pd2));
|
||||
List<MultipartFile> fileList = new ArrayList<MultipartFile>();
|
||||
String signertime = "";
|
||||
String SIGNTIME[] = pd.getString("SIGNTIME").split(",");
|
||||
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
for (int i = 0; i < SIGNTIME.length; i++) {
|
||||
signertime = SIGNTIME[i];
|
||||
fileList.add(request.getFile("file"+i));
|
||||
MultipartFile[] fileArr = new MultipartFile[fileList.size()];
|
||||
saveImg(fileList.toArray(fileArr),signertime,pd.getString("BLINDBOARD_ID"),pd.getString("CORPINFO_ID"),pd.getString("ACCEPT_CONFESS_USER_ID"),pd.getString("ACCEPT_CONFESS_DEPARTMENT_ID"));
|
||||
saveImg(fileList.toArray(fileArr),signertime,pd.getString("BLINDBOARD_ID"),pd.getString("CORPINFO_ID"),
|
||||
pd.getString("ACCEPT_CONFESS_USER_ID"),pd.getString("ACCEPT_CONFESS_DEPARTMENT_ID"),pictureList);
|
||||
fileList.clear();
|
||||
}
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
map.put("result", errInfo);
|
||||
return map;
|
||||
}
|
||||
private void saveImg(MultipartFile[] files,String signertime, String BLINDBOARD_ID, String CORPINFO_ID, String ACCEPT_CONFESS_USER_ID, String ACCEPT_CONFESS_DEPARTMENT_ID) throws Exception{
|
||||
private void saveImg(MultipartFile[] files,String signertime, String BLINDBOARD_ID, String CORPINFO_ID,
|
||||
String ACCEPT_CONFESS_USER_ID, String ACCEPT_CONFESS_DEPARTMENT_ID, ArrayList<String> pictureList) throws Exception{
|
||||
if (files != null && files.length > 0) {
|
||||
for (int i = 0; i < files.length; i++) {
|
||||
PageData pd = new PageData();
|
||||
|
@ -1057,6 +1136,7 @@ public class AppGFBlindBoardController extends BaseController {
|
|||
pd.put("ACCEPT_CONFESS_DEPARTMENT_ID", ACCEPT_CONFESS_DEPARTMENT_ID);
|
||||
pd.put("ACCEPT_USER_ID","");
|
||||
pd.put("ACCEPT_DEPARTMENT_ID", "");
|
||||
pictureList.add(Const.FILEPATHFILE + CORPINFO_ID + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
blindboardacceptuserService.save(pd);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -422,6 +422,7 @@ public class AppGFConfinedSpaceController extends BaseController {
|
|||
pd2.put("OPERATOR", pd.get("OPERATOR")); //修改人
|
||||
pd2.put("OPERATTIME", DateUtil.date2Str(new Date())); //修改时间
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
|
@ -432,8 +433,10 @@ public class AppGFConfinedSpaceController extends BaseController {
|
|||
pd2.put("GUARDIAN_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
// pd2.put("GUARDIAN_CONTENT", pd.get("CONTENT"));
|
||||
// pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
pictureList.add(Const.FILEPATHFILE + Jurisdiction.getCORPINFO_ID() + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
GFconfinedspaceService.edit(pd2);
|
||||
map.put("dockData", JSON.toJSONString(pd2));
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
}
|
||||
|
||||
if(pd.get("APPLY_STATUS").equals("1")) {
|
||||
|
@ -500,6 +503,7 @@ public class AppGFConfinedSpaceController extends BaseController {
|
|||
pd2.put("OPERATOR", pd.get("OPERATOR")); //修改人
|
||||
pd2.put("OPERATTIME", DateUtil.date2Str(new Date())); //修改时间
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
|
@ -510,8 +514,10 @@ public class AppGFConfinedSpaceController extends BaseController {
|
|||
pd2.put("CONFESS_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
// pd2.put("GUARDIAN_CONTENT", pd.get("CONTENT"));
|
||||
// pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
pictureList.add(Const.FILEPATHFILE + Jurisdiction.getCORPINFO_ID() + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
GFconfinedspaceService.edit(pd2);
|
||||
map.put("dockData", JSON.toJSONString(pd2));
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
}
|
||||
map.put("result", errInfo);
|
||||
return map;
|
||||
|
@ -556,7 +562,7 @@ public class AppGFConfinedSpaceController extends BaseController {
|
|||
@RequestMapping(value="/editAcceptconfess")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
@DockAnnotation
|
||||
@DockAnnotation(hasAnnex = true)
|
||||
public Object editAcceptconfess(MultipartRequest request) throws Exception {
|
||||
Map<String, Object> map = new HashMap<String, Object>();
|
||||
String errInfo = "success";
|
||||
|
@ -571,18 +577,20 @@ public class AppGFConfinedSpaceController extends BaseController {
|
|||
String signertime = "";
|
||||
String SIGNTIME[] = pd.getString("SIGNTIME").split(",");
|
||||
|
||||
ArrayList<String> pictureList = new ArrayList<>();
|
||||
for (int i = 0; i < SIGNTIME.length; i++) {
|
||||
signertime = SIGNTIME[i];
|
||||
fileList.add(request.getFile("file"+i));
|
||||
MultipartFile[] fileArr = new MultipartFile[fileList.size()];
|
||||
saveImg(fileList.toArray(fileArr),signertime,pd.getString("CONFINEDSPACE_ID"),pd.getString("CORPINFO_ID"),pd.getString("ACCEPT_CONFESS_USER_ID"),pd.getString("ACCEPT_CONFESS_DEPARTMENT_ID"));
|
||||
saveImg(fileList.toArray(fileArr),signertime,pd.getString("CONFINEDSPACE_ID"),pd.getString("CORPINFO_ID"),pd.getString("ACCEPT_CONFESS_USER_ID"),pd.getString("ACCEPT_CONFESS_DEPARTMENT_ID"),pictureList);
|
||||
fileList.clear();
|
||||
}
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
map.put("result", errInfo);
|
||||
return map;
|
||||
}
|
||||
private void saveImg(MultipartFile[] files,String signertime, String CONFINEDSPACE_ID, String CORPINFO_ID, String ACCEPT_CONFESS_USER_ID, String ACCEPT_CONFESS_DEPARTMENT_ID) throws Exception{
|
||||
private void saveImg(MultipartFile[] files,String signertime, String CONFINEDSPACE_ID, String CORPINFO_ID, String ACCEPT_CONFESS_USER_ID, String ACCEPT_CONFESS_DEPARTMENT_ID, ArrayList<String> pictureList) throws Exception{
|
||||
if (files != null && files.length > 0) {
|
||||
for (int i = 0; i < files.length; i++) {
|
||||
PageData pd = new PageData();
|
||||
|
@ -603,6 +611,7 @@ public class AppGFConfinedSpaceController extends BaseController {
|
|||
pd.put("ACCEPT_CONFESS_DEPARTMENT_ID", ACCEPT_CONFESS_DEPARTMENT_ID);
|
||||
pd.put("ACCEPT_USER_ID","");
|
||||
pd.put("ACCEPT_DEPARTMENT_ID", "");
|
||||
pictureList.add(Const.FILEPATHFILE + CORPINFO_ID + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
confinedspaceacceptuserService.save(pd);
|
||||
}
|
||||
}
|
||||
|
@ -611,7 +620,7 @@ public class AppGFConfinedSpaceController extends BaseController {
|
|||
@RequestMapping(value="/editAcceptStatus")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
@DockAnnotation
|
||||
@DockAnnotation(hasAnnex = true)
|
||||
public Object editAcceptStatus(MultipartRequest request) throws Exception{
|
||||
Map<String,Object> map = new HashMap<String,Object>();
|
||||
String errInfo = "success";
|
||||
|
@ -644,13 +653,15 @@ public class AppGFConfinedSpaceController extends BaseController {
|
|||
String signertime = "";
|
||||
String SIGNTIME[] = pd.getString("SIGNTIME").split(",");
|
||||
|
||||
ArrayList<String> pictureList = new ArrayList<>();
|
||||
for (int i = 0; i < SIGNTIME.length; i++) {
|
||||
signertime = SIGNTIME[i];
|
||||
fileList.add(request.getFile("file"+i));
|
||||
MultipartFile[] fileArr = new MultipartFile[fileList.size()];
|
||||
saveAcceptImg(fileList.toArray(fileArr),signertime,pd.getString("CONFINEDSPACE_ID"),pd.getString("CORPINFO_ID"),pd.getString("ACCEPT_USER_ID"),pd.getString("ACCEPT_DEPARTMENT_ID"));
|
||||
saveAcceptImg(fileList.toArray(fileArr),signertime,pd.getString("CONFINEDSPACE_ID"),pd.getString("CORPINFO_ID"),pd.getString("ACCEPT_USER_ID"),pd.getString("ACCEPT_DEPARTMENT_ID"),pictureList);
|
||||
fileList.clear();
|
||||
}
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
|
||||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
pd2.put("ACCEPT_CONTENT", pd.get("CONTENT"));
|
||||
|
@ -719,7 +730,7 @@ public class AppGFConfinedSpaceController extends BaseController {
|
|||
map.put("result", errInfo);
|
||||
return map;
|
||||
}
|
||||
private void saveAcceptImg(MultipartFile[] files,String signertime, String CONFINEDSPACE_ID, String CORPINFO_ID, String ACCEPT_USER_ID, String ACCEPT_DEPARTMENT_ID) throws Exception{
|
||||
private void saveAcceptImg(MultipartFile[] files,String signertime, String CONFINEDSPACE_ID, String CORPINFO_ID, String ACCEPT_USER_ID, String ACCEPT_DEPARTMENT_ID, ArrayList<String> pictureList) throws Exception{
|
||||
if (files != null && files.length > 0) {
|
||||
for (int i = 0; i < files.length; i++) {
|
||||
PageData cpd = new PageData();
|
||||
|
@ -740,6 +751,7 @@ public class AppGFConfinedSpaceController extends BaseController {
|
|||
cpd.put("ACCEPT_CONFESS_DEPARTMENT_ID", "");
|
||||
cpd.put("ACCEPT_CONFESS_USER_ID", "");
|
||||
cpd.put("ACCEPT_DEPARTMENT_ID", ACCEPT_DEPARTMENT_ID);
|
||||
pictureList.add(Const.FILEPATHFILE + CORPINFO_ID + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
confinedspaceacceptuserService.save(cpd);
|
||||
}
|
||||
}
|
||||
|
@ -754,7 +766,7 @@ public class AppGFConfinedSpaceController extends BaseController {
|
|||
@RequestMapping(value="/editStatus")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
@DockAnnotation
|
||||
@DockAnnotation(hasAnnex = true)
|
||||
public Object editStatus(
|
||||
@RequestParam(value="FFILE",required=false) MultipartFile[] files
|
||||
) throws Exception{
|
||||
|
@ -785,6 +797,7 @@ public class AppGFConfinedSpaceController extends BaseController {
|
|||
switch (status) {
|
||||
case "4"://确认
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
|
@ -803,9 +816,11 @@ public class AppGFConfinedSpaceController extends BaseController {
|
|||
pd2.put("ACCEPT_CONFESS_DEPARTMENT_ID", pd.get("ACCEPT_CONFESS_DEPARTMENT_ID"));
|
||||
pd2.put("ACCEPT_CONFESS_USER_ID", pd.get("ACCEPT_CONFESS_USER_ID"));
|
||||
pd2.put("EDUCATE_USER", pd.get("EDUCATE_USER"));
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
GFconfinedspaceService.edit(pd2);
|
||||
GFconfinedspaceToMeasuresService.delete(pd2);
|
||||
map.put("dockData", JSON.toJSONString(pd2));
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
List<JSONObject> list = (List<JSONObject>) JSON.parse(pd.get("measuresList").toString());
|
||||
for (JSONObject json : list) {
|
||||
PageData measures = new PageData();
|
||||
|
@ -867,6 +882,7 @@ public class AppGFConfinedSpaceController extends BaseController {
|
|||
|
||||
case "3"://监护人确认
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
|
@ -877,8 +893,10 @@ public class AppGFConfinedSpaceController extends BaseController {
|
|||
pd2.put("GUARDIAN_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
// pd2.put("GUARDIAN_CONTENT", pd.get("CONTENT"));
|
||||
// pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
GFconfinedspaceService.edit(pd2);
|
||||
map.put("dockData", JSON.toJSONString(pd2));
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
log.put("ACTION", "监护人确认通过");
|
||||
}
|
||||
return map;
|
||||
|
@ -995,6 +1013,7 @@ public class AppGFConfinedSpaceController extends BaseController {
|
|||
|
||||
case "5"://所在单位确认
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
|
@ -1005,8 +1024,10 @@ public class AppGFConfinedSpaceController extends BaseController {
|
|||
pd2.put("APPROVE_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
pd2.put("APPROVE_CONTENT", pd.get("CONTENT"));
|
||||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
GFconfinedspaceService.edit(pd2);
|
||||
map.put("dockData", JSON.toJSONString(pd2));
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
log.put("ACTION", "所在单位审批通过");
|
||||
|
||||
|
||||
|
@ -1064,6 +1085,7 @@ public class AppGFConfinedSpaceController extends BaseController {
|
|||
|
||||
case "6"://验收人
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
|
@ -1074,8 +1096,10 @@ public class AppGFConfinedSpaceController extends BaseController {
|
|||
pd2.put("ACCEPT_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
pd2.put("ACCEPT_CONTENT", pd.get("CONTENT"));
|
||||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
GFconfinedspaceService.edit(pd2);
|
||||
map.put("dockData", JSON.toJSONString(pd2));
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
log.put("ACTION", "验收通过");
|
||||
|
||||
// 发短信
|
||||
|
|
|
@ -2,6 +2,7 @@ package com.zcloud.controller.gf;
|
|||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.zcloud.aspect.DockAnnotation;
|
||||
import com.zcloud.controller.base.BaseController;
|
||||
import com.zcloud.dto.TenCorpConst;
|
||||
import com.zcloud.dto.TenCorpDto;
|
||||
|
@ -84,6 +85,7 @@ public class AppGFElectricityController extends BaseController {
|
|||
@RequestMapping(value="/add")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
@DockAnnotation(isAdd = true)
|
||||
public Object add() throws Exception{
|
||||
Map<String,Object> map = new HashMap<String,Object>();
|
||||
String errInfo = "success";
|
||||
|
@ -105,6 +107,7 @@ public class AppGFElectricityController extends BaseController {
|
|||
pd.put("CREATTIME", DateUtil.date2Str(new Date())); //添加时间
|
||||
pd.put("OPERATTIME", DateUtil.date2Str(new Date())); //修改时间
|
||||
pd.put("ISDELETE", "0"); //是否删除 1-是 0-否
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
GFelectricityService.save(pd);
|
||||
|
||||
if(pd.get("APPLY_STATUS").equals("1")) {
|
||||
|
@ -114,6 +117,7 @@ public class AppGFElectricityController extends BaseController {
|
|||
log.put("ELECTRICITY_ID", pd.get("ELECTRICITY_ID"));
|
||||
log.put("CREATOR",pd.get("ACTION_USER"));
|
||||
log.put("CREATTIME", DateUtil.date2Str(new Date()));
|
||||
map.put("dockDataLog", JSON.toJSONString(log));
|
||||
GFelectricityLogService.save(log);
|
||||
|
||||
// 发短信
|
||||
|
@ -184,12 +188,14 @@ public class AppGFElectricityController extends BaseController {
|
|||
*/
|
||||
@RequestMapping(value="/delete")
|
||||
@ResponseBody
|
||||
@DockAnnotation
|
||||
public Object delete() throws Exception{
|
||||
Map<String,String> map = new HashMap<String,String>();
|
||||
String errInfo = "success";
|
||||
PageData pd = new PageData();
|
||||
pd = this.getPageData();
|
||||
GFelectricityService.delete(pd);
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
map.put("result", errInfo); //返回结果
|
||||
return map;
|
||||
}
|
||||
|
@ -201,12 +207,14 @@ public class AppGFElectricityController extends BaseController {
|
|||
@RequestMapping(value="/edit")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
@DockAnnotation
|
||||
public Object edit() throws Exception{
|
||||
Map<String,Object> map = new HashMap<String,Object>();
|
||||
String errInfo = "success";
|
||||
PageData pd = new PageData();
|
||||
pd = this.getPageData();
|
||||
GFelectricityService.edit(pd);
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
if(pd.get("APPLY_STATUS").equals("1")) {
|
||||
PageData log = new PageData();
|
||||
log.put("ELECTRICITYLOG_ID", this.get32UUID());
|
||||
|
@ -214,6 +222,7 @@ public class AppGFElectricityController extends BaseController {
|
|||
log.put("ELECTRICITY_ID", pd.get("ELECTRICITY_ID"));
|
||||
log.put("CREATOR",pd.get("ACTION_USER"));
|
||||
log.put("CREATTIME", DateUtil.date2Str(new Date()));
|
||||
map.put("dockDataLog", JSON.toJSONString(log));
|
||||
GFelectricityLogService.save(log);
|
||||
|
||||
// 发短信
|
||||
|
@ -267,6 +276,7 @@ public class AppGFElectricityController extends BaseController {
|
|||
@RequestMapping(value="/editGuardian")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
@DockAnnotation(hasAnnex = true)
|
||||
public Object editGuardian(
|
||||
@RequestParam(value="FFILE",required=false) MultipartFile[] files
|
||||
) throws Exception{
|
||||
|
@ -279,21 +289,26 @@ public class AppGFElectricityController extends BaseController {
|
|||
pd2.put("OPERATOR", pd.get("OPERATOR")); //修改人
|
||||
pd2.put("OPERATTIME", DateUtil.date2Str(new Date())); //修改时间
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
String fileName = this.get32UUID()+file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
|
||||
smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile);
|
||||
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
pd2.put("GUARDIAN_USER_SIGNER_PATH", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName);
|
||||
pd2.put("GUARDIAN_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
// pd2.put("GUARDIAN_CONTENT", pd.get("CONTENT"));
|
||||
// pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
GFelectricityService.edit(pd2);
|
||||
map.put("dockData", JSON.toJSONString(pd2));
|
||||
}
|
||||
map.put("result", errInfo);
|
||||
return map;
|
||||
}
|
||||
|
||||
/**修改
|
||||
* @param
|
||||
* @throws Exception
|
||||
|
@ -301,6 +316,7 @@ public class AppGFElectricityController extends BaseController {
|
|||
@RequestMapping(value="/editConfess")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
@DockAnnotation(hasAnnex = true)
|
||||
public Object editConfess(
|
||||
@RequestParam(value="FFILE",required=false) MultipartFile[] files
|
||||
) throws Exception{
|
||||
|
@ -313,21 +329,26 @@ public class AppGFElectricityController extends BaseController {
|
|||
pd2.put("OPERATOR", pd.get("OPERATOR")); //修改人
|
||||
pd2.put("OPERATTIME", DateUtil.date2Str(new Date())); //修改时间
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
String fileName = this.get32UUID()+file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
|
||||
smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile);
|
||||
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
pd2.put("CONFESS_USER_SIGNER_PATH", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName);
|
||||
pd2.put("CONFESS_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
// pd2.put("GUARDIAN_CONTENT", pd.get("CONTENT"));
|
||||
// pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
GFelectricityService.edit(pd2);
|
||||
map.put("dockData", JSON.toJSONString(pd2));
|
||||
}
|
||||
map.put("result", errInfo);
|
||||
return map;
|
||||
}
|
||||
|
||||
/**修改
|
||||
* @param
|
||||
* @throws Exception
|
||||
|
@ -335,6 +356,7 @@ public class AppGFElectricityController extends BaseController {
|
|||
@RequestMapping(value="/editAcceptconfess")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
@DockAnnotation(hasAnnex = true)
|
||||
public Object editAcceptconfess(MultipartRequest request) throws Exception {
|
||||
Map<String, Object> map = new HashMap<String, Object>();
|
||||
String errInfo = "success";
|
||||
|
@ -348,17 +370,23 @@ public class AppGFElectricityController extends BaseController {
|
|||
String signertime = "";
|
||||
String SIGNTIME[] = pd.getString("SIGNTIME").split(",");
|
||||
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
for (int i = 0; i < SIGNTIME.length; i++) {
|
||||
signertime = SIGNTIME[i];
|
||||
fileList.add(request.getFile("file"+i));
|
||||
MultipartFile[] fileArr = new MultipartFile[fileList.size()];
|
||||
saveImg(fileList.toArray(fileArr),signertime,pd.getString("ELECTRICITY_ID"),pd.getString("CORPINFO_ID"),pd.getString("ACCEPT_CONFESS_USER_ID"),pd.getString("ACCEPT_CONFESS_DEPARTMENT_ID"));
|
||||
saveImg(fileList.toArray(fileArr),signertime,pd.getString("ELECTRICITY_ID"),
|
||||
pd.getString("CORPINFO_ID"),pd.getString("ACCEPT_CONFESS_USER_ID"),
|
||||
pd.getString("ACCEPT_CONFESS_DEPARTMENT_ID"),pictureList);
|
||||
fileList.clear();
|
||||
}
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
map.put("result", errInfo);
|
||||
return map;
|
||||
}
|
||||
private void saveImg(MultipartFile[] files,String signertime, String ELECTRICITY_ID, String CORPINFO_ID, String ACCEPT_CONFESS_USER_ID, String ACCEPT_CONFESS_DEPARTMENT_ID) throws Exception{
|
||||
private void saveImg(MultipartFile[] files,String signertime, String ELECTRICITY_ID,
|
||||
String CORPINFO_ID, String ACCEPT_CONFESS_USER_ID,
|
||||
String ACCEPT_CONFESS_DEPARTMENT_ID, ArrayList<String> pictureList) throws Exception{
|
||||
if (files != null && files.length > 0) {
|
||||
for (int i = 0; i < files.length; i++) {
|
||||
PageData pd = new PageData();
|
||||
|
@ -379,6 +407,7 @@ public class AppGFElectricityController extends BaseController {
|
|||
pd.put("ACCEPT_CONFESS_DEPARTMENT_ID", ACCEPT_CONFESS_DEPARTMENT_ID);
|
||||
pd.put("ACCEPT_USER_ID","");
|
||||
pd.put("ACCEPT_DEPARTMENT_ID", "");
|
||||
pictureList.add(Const.FILEPATHFILE + CORPINFO_ID + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
electricityacceptuserService.save(pd);
|
||||
}
|
||||
}
|
||||
|
@ -390,6 +419,7 @@ public class AppGFElectricityController extends BaseController {
|
|||
@RequestMapping(value="/editAcceptStatus")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
@DockAnnotation(hasAnnex = true)
|
||||
public Object editAcceptStatus(MultipartRequest request) throws Exception{
|
||||
Map<String,Object> map = new HashMap<String,Object>();
|
||||
String errInfo = "success";
|
||||
|
@ -406,6 +436,7 @@ public class AppGFElectricityController extends BaseController {
|
|||
log.put("CREATOR",pd.get("ACTION_USER"));
|
||||
log.put("CREATTIME", DateUtil.date2Str(new Date()));
|
||||
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
String status = pd.get("STATUS").toString();
|
||||
if ("2".equals(status) || "3".equals(status) || "4".equals(status)) {
|
||||
String OTHER_PROTECTIVE_MEASURES = (StringUtils.isNotBlank(pd2.getString("OTHER_PROTECTIVE_MEASURES")) ? pd2.getString("OTHER_PROTECTIVE_MEASURES") : "") +
|
||||
|
@ -425,15 +456,20 @@ public class AppGFElectricityController extends BaseController {
|
|||
String SIGNTIME[] = pd.getString("SIGNTIME").split(",");
|
||||
|
||||
for (int i = 0; i < SIGNTIME.length; i++) {
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
signertime = SIGNTIME[i];
|
||||
fileList.add(request.getFile("file"+i));
|
||||
MultipartFile[] fileArr = new MultipartFile[fileList.size()];
|
||||
saveAcceptImg(fileList.toArray(fileArr),signertime,pd.getString("ELECTRICITY_ID"),pd.getString("CORPINFO_ID"),pd.getString("ACCEPT_USER_ID"),pd.getString("ACCEPT_DEPARTMENT_ID"));
|
||||
saveAcceptImg(fileList.toArray(fileArr),signertime,pd.getString("ELECTRICITY_ID"),
|
||||
pd.getString("CORPINFO_ID"),pd.getString("ACCEPT_USER_ID"),
|
||||
pd.getString("ACCEPT_DEPARTMENT_ID"),pictureList);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
fileList.clear();
|
||||
}
|
||||
pd2.put("ACCEPT_CONTENT", pd.get("CONTENT"));
|
||||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
GFelectricityService.edit(pd2);
|
||||
map.put("dockDatapd2", JSON.toJSONString(pd2));
|
||||
log.put("ACTION", "验收通过");
|
||||
|
||||
// 发短信
|
||||
|
@ -462,6 +498,7 @@ public class AppGFElectricityController extends BaseController {
|
|||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
pd2.put("ACCEPT_CONTENT", pd.get("CONTENT"));
|
||||
GFelectricityService.edit(pd2);
|
||||
map.put("dockDatapd2", JSON.toJSONString(pd2));
|
||||
|
||||
PageData mes3 = new PageData();
|
||||
mes3.put("RECEIVER_ID", pd2.get("APPLY_USER_ID"));// 收信人userid
|
||||
|
@ -492,12 +529,13 @@ public class AppGFElectricityController extends BaseController {
|
|||
break;
|
||||
}
|
||||
GFelectricityLogService.save(log);
|
||||
map.put("dockDataLog", JSON.toJSONString(log));
|
||||
|
||||
map.put("result", errInfo);
|
||||
return map;
|
||||
}
|
||||
|
||||
private void saveAcceptImg(MultipartFile[] files,String signertime, String ELECTRICITY_ID, String CORPINFO_ID, String ACCEPT_USER_ID, String ACCEPT_DEPARTMENT_ID) throws Exception{
|
||||
private void saveAcceptImg(MultipartFile[] files,String signertime, String ELECTRICITY_ID, String CORPINFO_ID, String ACCEPT_USER_ID, String ACCEPT_DEPARTMENT_ID, ArrayList<String> pictureList) throws Exception{
|
||||
if (files != null && files.length > 0) {
|
||||
for (int i = 0; i < files.length; i++) {
|
||||
PageData cpd = new PageData();
|
||||
|
@ -518,6 +556,7 @@ public class AppGFElectricityController extends BaseController {
|
|||
cpd.put("ACCEPT_CONFESS_DEPARTMENT_ID", "");
|
||||
cpd.put("ACCEPT_CONFESS_USER_ID", "");
|
||||
cpd.put("ACCEPT_DEPARTMENT_ID", ACCEPT_DEPARTMENT_ID);
|
||||
pictureList.add(Const.FILEPATHFILE + CORPINFO_ID + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
electricityacceptuserService.save(cpd);
|
||||
}
|
||||
}
|
||||
|
@ -531,6 +570,7 @@ public class AppGFElectricityController extends BaseController {
|
|||
@RequestMapping(value="/editStatus")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
@DockAnnotation(hasAnnex = true)
|
||||
public Object editStatus(
|
||||
@RequestParam(value="FFILE",required=false) MultipartFile[] files
|
||||
) throws Exception{
|
||||
|
@ -549,6 +589,7 @@ public class AppGFElectricityController extends BaseController {
|
|||
log.put("CREATOR",pd.get("ACTION_USER"));
|
||||
log.put("CREATTIME", DateUtil.date2Str(new Date()));
|
||||
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
String status = pd.get("STATUS").toString();
|
||||
if ("2".equals(status) || "3".equals(status) || "4".equals(status)) {
|
||||
String OTHER_PROTECTIVE_MEASURES = (StringUtils.isNotBlank(pd2.getString("OTHER_PROTECTIVE_MEASURES")) ? pd2.getString("OTHER_PROTECTIVE_MEASURES") : "") +
|
||||
|
@ -563,20 +604,27 @@ public class AppGFElectricityController extends BaseController {
|
|||
switch (status) {
|
||||
case "2"://作业单位
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
String fileName = this.get32UUID()+file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
|
||||
smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile);
|
||||
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
pd2.putAll(pd);
|
||||
pd2.put("CONFIRM_USER_SIGNER_PATH", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName);
|
||||
pd2.put("CONFIRM_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
pd2.put("CONFIRM_CONTENT", pd.get("CONTENT"));
|
||||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
GFelectricityService.edit(pd2);
|
||||
map.put("dockDatapd2", JSON.toJSONString(pd2));
|
||||
GFelectricityToMeasuresService.delete(pd);
|
||||
map.put("dockDataDel", JSON.toJSONString(pd));
|
||||
List<JSONObject> list = (List<JSONObject>) JSON.parse(pd.get("measuresList").toString());
|
||||
HashMap<String, String> measuresMap = new HashMap<String, String>();
|
||||
int measuresCount = 1;
|
||||
for (JSONObject json : list) {
|
||||
PageData measures = new PageData();
|
||||
measures.put("ELECTRICITYTOMEASURES_ID", this.get32UUID()); // 主键
|
||||
|
@ -585,8 +633,11 @@ public class AppGFElectricityController extends BaseController {
|
|||
measures.put("STATUS", json.get("STATUS"));
|
||||
measures.put("CONFIRM_ID", pd.get("OPERATOR"));
|
||||
measures.put("CONFIRM_NAME", pd.get("ACTION_USER"));
|
||||
measuresMap.put("other"+measuresCount, JSON.toJSONString(measures));
|
||||
measuresCount+=1;
|
||||
GFelectricityToMeasuresService.save(measures);
|
||||
}
|
||||
map.put("dockDatameasures", JSON.toJSONString(measuresMap));
|
||||
log.put("ACTION", "作业单位通过");
|
||||
|
||||
// 发短信
|
||||
|
@ -635,17 +686,21 @@ public class AppGFElectricityController extends BaseController {
|
|||
|
||||
case "3"://用电单位审核
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
String fileName = this.get32UUID()+file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
|
||||
smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile);
|
||||
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
pd2.put("AUDIT_USER_SIGNER_PATH", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName);
|
||||
pd2.put("AUDIT_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
pd2.put("AUDIT_CONTENT", pd.get("CONTENT"));
|
||||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
GFelectricityService.edit(pd2);
|
||||
map.put("dockDatapd2", JSON.toJSONString(pd2));
|
||||
log.put("ACTION", "用电单位审核通过");
|
||||
|
||||
// 发短信
|
||||
|
@ -682,17 +737,21 @@ public class AppGFElectricityController extends BaseController {
|
|||
|
||||
case "4"://配送电单位审批
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
String fileName = this.get32UUID()+file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
|
||||
smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile);
|
||||
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
pd2.put("APPROVE_USER_SIGNER_PATH", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName);
|
||||
pd2.put("APPROVE_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
pd2.put("APPROVE_CONTENT", pd.get("CONTENT"));
|
||||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
GFelectricityService.edit(pd2);
|
||||
map.put("dockDatapd2", JSON.toJSONString(pd2));
|
||||
log.put("ACTION", "配送电单位审批通过");
|
||||
|
||||
// 发短信
|
||||
|
@ -729,17 +788,21 @@ public class AppGFElectricityController extends BaseController {
|
|||
|
||||
case "5"://验收人
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
String fileName = this.get32UUID()+file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
|
||||
smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile);
|
||||
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
pd2.put("ACCEPT_USER_SIGNER_PATH", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName);
|
||||
pd2.put("ACCEPT_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
pd2.put("ACCEPT_CONTENT", pd.get("CONTENT"));
|
||||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
GFelectricityService.edit(pd2);
|
||||
map.put("dockDatapd2", JSON.toJSONString(pd2));
|
||||
log.put("ACTION", "验收通过");
|
||||
|
||||
// 发短信
|
||||
|
@ -768,6 +831,7 @@ public class AppGFElectricityController extends BaseController {
|
|||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
pd2.put("CONFIRM_CONTENT", pd.get("CONTENT"));
|
||||
GFelectricityService.edit(pd2);
|
||||
map.put("dockDatapd2", JSON.toJSONString(pd2));
|
||||
|
||||
PageData mes = new PageData();
|
||||
mes.put("RECEIVER_ID", pd2.get("APPLY_USER_ID"));// 收信人userid
|
||||
|
@ -799,6 +863,7 @@ public class AppGFElectricityController extends BaseController {
|
|||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
pd2.put("AUDIT_CONTENT", pd.get("CONTENT"));
|
||||
GFelectricityService.edit(pd2);
|
||||
map.put("dockDatapd2", JSON.toJSONString(pd2));
|
||||
|
||||
PageData mes1 = new PageData();
|
||||
mes1.put("RECEIVER_ID", pd2.get("APPLY_USER_ID"));// 收信人userid
|
||||
|
@ -829,6 +894,7 @@ public class AppGFElectricityController extends BaseController {
|
|||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
pd2.put("APPROVE_CONTENT", pd.get("CONTENT"));
|
||||
GFelectricityService.edit(pd2);
|
||||
map.put("dockDatapd2", JSON.toJSONString(pd2));
|
||||
|
||||
// 发短信
|
||||
PageData mes2 = new PageData();
|
||||
|
@ -861,6 +927,7 @@ public class AppGFElectricityController extends BaseController {
|
|||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
pd2.put("ACCEPT_CONTENT", pd.get("CONTENT"));
|
||||
GFelectricityService.edit(pd2);
|
||||
map.put("dockDatapd2", JSON.toJSONString(pd2));
|
||||
|
||||
PageData mes3 = new PageData();
|
||||
mes3.put("RECEIVER_ID", pd2.get("APPLY_USER_ID"));// 收信人userid
|
||||
|
@ -891,6 +958,7 @@ public class AppGFElectricityController extends BaseController {
|
|||
break;
|
||||
}
|
||||
GFelectricityLogService.save(log);
|
||||
map.put("dockDataLog", JSON.toJSONString(log));
|
||||
map.put("result", errInfo);
|
||||
return map;
|
||||
}
|
||||
|
@ -981,6 +1049,7 @@ public class AppGFElectricityController extends BaseController {
|
|||
*/
|
||||
@PostMapping(value="/cancel")
|
||||
@ResponseBody
|
||||
@DockAnnotation
|
||||
public void cancel(@RequestBody PageData pd) throws Exception{
|
||||
Map<String,String> map = new HashMap<String,String>();
|
||||
String errInfo = "success";
|
||||
|
@ -1004,6 +1073,7 @@ public class AppGFElectricityController extends BaseController {
|
|||
if (workTime - analyzeTime >= 0) {
|
||||
return;
|
||||
} else {
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
GFelectricityService.cancel(pd);
|
||||
PageData mes = new PageData();
|
||||
mes.put("RECEIVER_ID", pd.get("CONFIRM_USER_ID"));// 收信人userid
|
||||
|
@ -1028,12 +1098,14 @@ public class AppGFElectricityController extends BaseController {
|
|||
e.printStackTrace();
|
||||
}
|
||||
}else{
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
GFelectricityService.cancel(pd);
|
||||
PageData pd2 = new PageData();
|
||||
pd2 = GFelectricityService.checkno(pd);
|
||||
PageData pd3 = new PageData();
|
||||
pd3.put("CHECK_NO",pd2.getString("CHECK_NO"));
|
||||
pd3.put("CORPINFO_ID",pd.getString("CORPINFO_ID"));
|
||||
map.put("dockDatapd2", JSON.toJSONString(pd3));
|
||||
GFelectricityService.editSpecialwork(pd3);
|
||||
GFelectricityService.editSpecialwork1(pd3);
|
||||
GFelectricityService.editSpecialwork2(pd3);
|
||||
|
@ -1109,12 +1181,14 @@ public class AppGFElectricityController extends BaseController {
|
|||
*/
|
||||
@RequestMapping(value="/gas/delete")
|
||||
@ResponseBody
|
||||
@DockAnnotation
|
||||
public Object gasDel() throws Exception{
|
||||
Map<String,String> map = new HashMap<String,String>();
|
||||
String errInfo = "success";
|
||||
PageData pd = new PageData();
|
||||
pd = this.getPageData();
|
||||
GFelectricityGasService.delete(pd);
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
map.put("result", errInfo); //返回结果
|
||||
return map;
|
||||
}
|
||||
|
@ -1125,6 +1199,7 @@ public class AppGFElectricityController extends BaseController {
|
|||
*/
|
||||
@RequestMapping(value="/gas/save")
|
||||
@ResponseBody
|
||||
@DockAnnotation(isAdd = true)
|
||||
public Object gasSave() throws Exception{
|
||||
Map<String,String> map = new HashMap<String,String>();
|
||||
String errInfo = "success";
|
||||
|
@ -1134,6 +1209,7 @@ public class AppGFElectricityController extends BaseController {
|
|||
pd.put("ISDELETE", "0"); //是否删除 1-是 0-否
|
||||
GFelectricityGasService.save(pd);
|
||||
GFelectricityService.edittime(pd);
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
map.put("result", errInfo); //返回结果
|
||||
return map;
|
||||
}
|
||||
|
|
|
@ -2,6 +2,7 @@ package com.zcloud.controller.gf;
|
|||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.zcloud.aspect.DockAnnotation;
|
||||
import com.zcloud.controller.base.BaseController;
|
||||
import com.zcloud.entity.Page;
|
||||
import com.zcloud.entity.PageData;
|
||||
|
@ -72,6 +73,7 @@ public class AppGFHoistingController extends BaseController {
|
|||
@RequestMapping(value="/add")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
@DockAnnotation(isAdd = true,hasAnnex = true)
|
||||
public Object add() throws Exception{
|
||||
Map<String,Object> map = new HashMap<String,Object>();
|
||||
String errInfo = "success";
|
||||
|
@ -93,6 +95,7 @@ public class AppGFHoistingController extends BaseController {
|
|||
pd.put("CREATTIME", DateUtil.date2Str(new Date())); //添加时间
|
||||
pd.put("OPERATTIME", DateUtil.date2Str(new Date())); //修改时间
|
||||
pd.put("ISDELETE", "0"); //是否删除 1-是 0-否
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
GFhoistingService.save(pd);
|
||||
|
||||
if(pd.get("APPLY_STATUS").equals("1")) {
|
||||
|
@ -102,6 +105,7 @@ public class AppGFHoistingController extends BaseController {
|
|||
log.put("HOISTING_ID", pd.get("HOISTING_ID"));
|
||||
log.put("CREATOR",pd.get("ACTION_USER"));
|
||||
log.put("CREATTIME", DateUtil.date2Str(new Date()));
|
||||
map.put("logData", JSON.toJSONString(log));
|
||||
GFhighWorkLogService.save(log);
|
||||
|
||||
// 发短信
|
||||
|
@ -143,12 +147,14 @@ public class AppGFHoistingController extends BaseController {
|
|||
*/
|
||||
@RequestMapping(value="/delete")
|
||||
@ResponseBody
|
||||
@DockAnnotation
|
||||
public Object delete() throws Exception{
|
||||
Map<String,String> map = new HashMap<String,String>();
|
||||
String errInfo = "success";
|
||||
PageData pd = new PageData();
|
||||
pd = this.getPageData();
|
||||
GFhoistingService.delete(pd);
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
map.put("result", errInfo); //返回结果
|
||||
return map;
|
||||
}
|
||||
|
@ -160,12 +166,14 @@ public class AppGFHoistingController extends BaseController {
|
|||
@RequestMapping(value="/edit")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
@DockAnnotation
|
||||
public Object edit() throws Exception{
|
||||
Map<String,Object> map = new HashMap<String,Object>();
|
||||
String errInfo = "success";
|
||||
PageData pd = new PageData();
|
||||
pd = this.getPageData();
|
||||
GFhoistingService.edit(pd);
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
if(pd.get("APPLY_STATUS").equals("1")) {
|
||||
PageData log = new PageData();
|
||||
log.put("HOISTINGLOG_ID", this.get32UUID());
|
||||
|
@ -174,6 +182,7 @@ public class AppGFHoistingController extends BaseController {
|
|||
log.put("CREATOR",pd.get("ACTION_USER"));
|
||||
log.put("CREATTIME", DateUtil.date2Str(new Date()));
|
||||
GFhighWorkLogService.save(log);
|
||||
map.put("logData", JSON.toJSONString(log));
|
||||
|
||||
// 发短信
|
||||
PageData mes = new PageData();
|
||||
|
@ -215,6 +224,7 @@ public class AppGFHoistingController extends BaseController {
|
|||
@RequestMapping(value="/editGuardian")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
@DockAnnotation(hasAnnex = true)
|
||||
public Object editGuardian(
|
||||
@RequestParam(value="FFILE",required=false) MultipartFile[] files
|
||||
) throws Exception{
|
||||
|
@ -227,14 +237,17 @@ public class AppGFHoistingController extends BaseController {
|
|||
pd2.put("OPERATOR", pd.get("OPERATOR")); //修改人
|
||||
pd2.put("OPERATTIME", DateUtil.date2Str(new Date())); //修改时间
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
String fileName = this.get32UUID()+file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
|
||||
Smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile);
|
||||
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
pd2.put("GUARDIAN_USER_SIGNER_PATH", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName);
|
||||
pd2.put("GUARDIAN_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
map.put("dockData", JSON.toJSONString(pd2));
|
||||
GFhoistingService.edit(pd2);
|
||||
}
|
||||
|
||||
|
@ -248,6 +261,7 @@ public class AppGFHoistingController extends BaseController {
|
|||
@RequestMapping(value="/editConfess")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
@DockAnnotation(hasAnnex = true)
|
||||
public Object editConfess(
|
||||
@RequestParam(value="FFILE",required=false) MultipartFile[] files
|
||||
) throws Exception{
|
||||
|
@ -260,16 +274,20 @@ public class AppGFHoistingController extends BaseController {
|
|||
pd2.put("OPERATOR", pd.get("OPERATOR")); //修改人
|
||||
pd2.put("OPERATTIME", DateUtil.date2Str(new Date())); //修改时间
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
String fileName = this.get32UUID()+file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
|
||||
Smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile);
|
||||
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
pd2.put("CONFESS_USER_SIGNER_PATH", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName);
|
||||
pd2.put("CONFESS_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
// pd2.put("GUARDIAN_CONTENT", pd.get("CONTENT"));
|
||||
// pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
map.put("dockData", JSON.toJSONString(pd2));
|
||||
GFhoistingService.edit(pd2);
|
||||
}
|
||||
map.put("result", errInfo);
|
||||
|
@ -282,30 +300,35 @@ public class AppGFHoistingController extends BaseController {
|
|||
@RequestMapping(value="/editAcceptconfess")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
@DockAnnotation(hasAnnex = true)
|
||||
public Object editAcceptconfess(MultipartRequest request) throws Exception {
|
||||
Map<String, Object> map = new HashMap<String, Object>();
|
||||
String errInfo = "success";
|
||||
PageData pd = new PageData();
|
||||
pd = this.getPageData();
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
PageData pd2 = new PageData();
|
||||
pd2 = GFhoistingService.findById(pd);
|
||||
pd2.put("OPERATOR", pd.get("OPERATOR")); //修改人
|
||||
pd2.put("OPERATTIME", DateUtil.date2Str(new Date())); //修改时间
|
||||
map.put("dockData2", JSON.toJSONString(pd2));
|
||||
List<MultipartFile> fileList = new ArrayList<MultipartFile>();
|
||||
String signertime = "";
|
||||
String SIGNTIME[] = pd.getString("SIGNTIME").split(",");
|
||||
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
for (int i = 0; i < SIGNTIME.length; i++) {
|
||||
signertime = SIGNTIME[i];
|
||||
fileList.add(request.getFile("file"+i));
|
||||
MultipartFile[] fileArr = new MultipartFile[fileList.size()];
|
||||
saveImg(fileList.toArray(fileArr),signertime,pd.getString("HOISTING_ID"),pd.getString("CORPINFO_ID"),pd.getString("ACCEPT_CONFESS_USER_ID"),pd.getString("ACCEPT_CONFESS_DEPARTMENT_ID"));
|
||||
saveImg(fileList.toArray(fileArr),signertime,pd.getString("HOISTING_ID"),pd.getString("CORPINFO_ID"),pd.getString("ACCEPT_CONFESS_USER_ID"),pd.getString("ACCEPT_CONFESS_DEPARTMENT_ID"),pictureList);
|
||||
fileList.clear();
|
||||
}
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
map.put("result", errInfo);
|
||||
return map;
|
||||
}
|
||||
private void saveImg(MultipartFile[] files,String signertime, String HOISTING_ID, String CORPINFO_ID, String ACCEPT_CONFESS_USER_ID, String ACCEPT_CONFESS_DEPARTMENT_ID) throws Exception{
|
||||
private void saveImg(MultipartFile[] files,String signertime, String HOISTING_ID, String CORPINFO_ID, String ACCEPT_CONFESS_USER_ID, String ACCEPT_CONFESS_DEPARTMENT_ID,ArrayList<String> pictureList) throws Exception{
|
||||
if (files != null && files.length > 0) {
|
||||
for (int i = 0; i < files.length; i++) {
|
||||
PageData pd = new PageData();
|
||||
|
@ -326,6 +349,7 @@ public class AppGFHoistingController extends BaseController {
|
|||
pd.put("ACCEPT_CONFESS_DEPARTMENT_ID", ACCEPT_CONFESS_DEPARTMENT_ID);
|
||||
pd.put("ACCEPT_USER_ID","");
|
||||
pd.put("ACCEPT_DEPARTMENT_ID", "");
|
||||
pictureList.add(Const.FILEPATHFILE + CORPINFO_ID + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
hoistingacceptuserService.save(pd);
|
||||
}
|
||||
}
|
||||
|
@ -338,6 +362,7 @@ public class AppGFHoistingController extends BaseController {
|
|||
@RequestMapping(value="/editAcceptStatus")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
@DockAnnotation(hasAnnex = true)
|
||||
public Object editAcceptStatus(MultipartRequest request) throws Exception{
|
||||
Map<String,Object> map = new HashMap<String,Object>();
|
||||
String errInfo = "success";
|
||||
|
@ -356,6 +381,7 @@ public class AppGFHoistingController extends BaseController {
|
|||
log.put("CREATOR",pd.get("ACTION_USER"));
|
||||
log.put("CREATTIME", DateUtil.date2Str(new Date()));
|
||||
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
String status = pd.get("STATUS").toString();
|
||||
String OTHER_PROTECTIVE_MEASURES = (StringUtils.isNotBlank(pd2.getString("OTHER_PROTECTIVE_MEASURES")) ? pd2.getString("OTHER_PROTECTIVE_MEASURES") : "") +
|
||||
(StringUtils.isNotBlank(pd.getString("OTHER_PROTECTIVE_MEASURES")) ? (pd.getString("OTHER_PROTECTIVE_MEASURES") + ";_;") : ";_;");
|
||||
|
@ -373,15 +399,18 @@ public class AppGFHoistingController extends BaseController {
|
|||
String SIGNTIME[] = pd.getString("SIGNTIME").split(",");
|
||||
|
||||
for (int i = 0; i < SIGNTIME.length; i++) {
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
signertime = SIGNTIME[i];
|
||||
fileList.add(request.getFile("file"+i));
|
||||
MultipartFile[] fileArr = new MultipartFile[fileList.size()];
|
||||
saveAcceptImg(fileList.toArray(fileArr),signertime,pd.getString("HOISTING_ID"),pd.getString("CORPINFO_ID"),pd.getString("ACCEPT_USER_ID"),pd.getString("ACCEPT_DEPARTMENT_ID"));
|
||||
saveAcceptImg(fileList.toArray(fileArr),signertime,pd.getString("HOISTING_ID"),pd.getString("CORPINFO_ID"),pd.getString("ACCEPT_USER_ID"),pd.getString("ACCEPT_DEPARTMENT_ID"),pictureList);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
fileList.clear();
|
||||
}
|
||||
pd2.put("ACCEPT_CONTENT", pd.get("CONTENT"));
|
||||
pd2.put("OTHER_PROTECTIVE_MEASURES", OTHER_PROTECTIVE_MEASURES);
|
||||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
map.put("dockData2", JSON.toJSONString(pd2));
|
||||
GFhoistingService.edit(pd2);
|
||||
log.put("ACTION", "验收通过");
|
||||
|
||||
|
@ -412,6 +441,7 @@ public class AppGFHoistingController extends BaseController {
|
|||
log.put("ACTION", "验收人打回");
|
||||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
pd2.put("ACCEPT_CONTENT", pd.get("CONTENT"));
|
||||
map.put("dockData2", JSON.toJSONString(pd2));
|
||||
GFhoistingService.edit(pd2);
|
||||
|
||||
|
||||
|
@ -443,11 +473,13 @@ public class AppGFHoistingController extends BaseController {
|
|||
default:
|
||||
break;
|
||||
}
|
||||
map.put("dockDataLog", JSON.toJSONString(log));
|
||||
GFhighWorkLogService.save(log);
|
||||
map.put("result", errInfo);
|
||||
return map;
|
||||
}
|
||||
private void saveAcceptImg(MultipartFile[] files,String signertime, String HOISTING_ID, String CORPINFO_ID, String ACCEPT_USER_ID, String ACCEPT_DEPARTMENT_ID) throws Exception{
|
||||
private void saveAcceptImg(MultipartFile[] files,String signertime, String HOISTING_ID,
|
||||
String CORPINFO_ID, String ACCEPT_USER_ID, String ACCEPT_DEPARTMENT_ID, ArrayList<String> pictureList) throws Exception{
|
||||
if (files != null && files.length > 0) {
|
||||
for (int i = 0; i < files.length; i++) {
|
||||
PageData cpd = new PageData();
|
||||
|
@ -468,6 +500,7 @@ public class AppGFHoistingController extends BaseController {
|
|||
cpd.put("ACCEPT_CONFESS_DEPARTMENT_ID", "");
|
||||
cpd.put("ACCEPT_CONFESS_USER_ID", "");
|
||||
cpd.put("ACCEPT_DEPARTMENT_ID", ACCEPT_DEPARTMENT_ID);
|
||||
pictureList.add(Const.FILEPATHFILE + CORPINFO_ID + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
hoistingacceptuserService.save(cpd);
|
||||
}
|
||||
}
|
||||
|
@ -481,6 +514,7 @@ public class AppGFHoistingController extends BaseController {
|
|||
@RequestMapping(value="/editStatus")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
@DockAnnotation(hasAnnex = true)
|
||||
public Object editStatus(
|
||||
@RequestParam(value="FFILE",required=false) MultipartFile[] files
|
||||
) throws Exception{
|
||||
|
@ -498,6 +532,7 @@ public class AppGFHoistingController extends BaseController {
|
|||
log.put("CREATOR",pd.get("ACTION_USER"));
|
||||
log.put("CREATTIME", DateUtil.date2Str(new Date()));
|
||||
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
String status = pd.get("STATUS").toString();
|
||||
String OTHER_PROTECTIVE_MEASURES = (StringUtils.isNotBlank(pd2.getString("OTHER_PROTECTIVE_MEASURES")) ? pd2.getString("OTHER_PROTECTIVE_MEASURES") : "") +
|
||||
(StringUtils.isNotBlank(pd.getString("OTHER_PROTECTIVE_MEASURES")) ? (pd.getString("OTHER_PROTECTIVE_MEASURES") + ";_;") : ";_;");
|
||||
|
@ -506,12 +541,15 @@ public class AppGFHoistingController extends BaseController {
|
|||
switch (status) {
|
||||
case "2"://作业指挥
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
String fileName = this.get32UUID()+file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
|
||||
Smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile);
|
||||
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
pd2.put("LEADER_USER_SIGNER_PATH", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName);
|
||||
pd2.put("LEADER_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
pd2.put("LEADER_CONTENT", pd.get("CONTENT"));
|
||||
|
@ -527,9 +565,13 @@ public class AppGFHoistingController extends BaseController {
|
|||
}
|
||||
pd2.put("OTHER_PROTECTIVE_MEASURES", OTHER_PROTECTIVE_MEASURES);
|
||||
// pd2.put("HAZARD_IDENTIFICATION", HAZARD_IDENTIFICATION);
|
||||
map.put("dockData2", JSON.toJSONString(pd2));
|
||||
GFhoistingService.edit(pd2);
|
||||
map.put("dockDataDel", JSON.toJSONString(pd));
|
||||
GFhighWorkToMeasuresService.delete(pd);
|
||||
List<JSONObject> list = (List<JSONObject>) JSON.parse(pd.get("measuresList").toString());
|
||||
HashMap<String, String> measuresMap = new HashMap<String, String>();
|
||||
int measuresCount = 1;
|
||||
for (JSONObject json : list) {
|
||||
PageData measures = new PageData();
|
||||
measures.put("HOISTINGTOMEASURES_ID", this.get32UUID()); // 主键
|
||||
|
@ -539,8 +581,11 @@ public class AppGFHoistingController extends BaseController {
|
|||
measures.put("STATUS", json.get("STATUS"));
|
||||
measures.put("CONFIRM_ID", pd.get("OPERATOR"));
|
||||
measures.put("CONFIRM_NAME", pd.get("ACTION_USER"));
|
||||
measuresMap.put("other"+measuresCount, JSON.toJSONString(measures));
|
||||
measuresCount+=1;
|
||||
GFhighWorkToMeasuresService.save(measures);
|
||||
}
|
||||
map.put("measuresData", JSON.toJSONString(measuresMap));
|
||||
log.put("ACTION", "作业指挥通过");
|
||||
|
||||
// 发短信
|
||||
|
@ -595,12 +640,15 @@ public class AppGFHoistingController extends BaseController {
|
|||
|
||||
case "3"://所在单位
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
String fileName = this.get32UUID()+file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
|
||||
Smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile);
|
||||
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
pd2.put("CONSTRUCTION_USER_SIGNER_PATH", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName);
|
||||
pd2.put("CONSTRUCTION_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
pd2.put("CONSTRUCTION_CONTENT", pd.get("CONTENT"));
|
||||
|
@ -612,6 +660,7 @@ public class AppGFHoistingController extends BaseController {
|
|||
}
|
||||
pd2.put("OTHER_PROTECTIVE_MEASURES", OTHER_PROTECTIVE_MEASURES);
|
||||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
map.put("dockData2", JSON.toJSONString(pd2));
|
||||
GFhoistingService.edit(pd2);
|
||||
log.put("ACTION", "所在单位通过");
|
||||
|
||||
|
@ -663,12 +712,15 @@ public class AppGFHoistingController extends BaseController {
|
|||
|
||||
case "4"://审核部门
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
String fileName = this.get32UUID()+file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
|
||||
Smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile);
|
||||
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
pd2.put("AUDIT_USER_SIGNER_PATH", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName);
|
||||
pd2.put("AUDIT_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
pd2.put("AUDIT_CONTENT", pd.get("CONTENT"));
|
||||
|
@ -677,6 +729,7 @@ public class AppGFHoistingController extends BaseController {
|
|||
}
|
||||
pd2.put("OTHER_PROTECTIVE_MEASURES", OTHER_PROTECTIVE_MEASURES);
|
||||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
map.put("dockData2", JSON.toJSONString(pd2));
|
||||
GFhoistingService.edit(pd2);
|
||||
log.put("ACTION", "审核部门通过");
|
||||
|
||||
|
@ -722,17 +775,21 @@ public class AppGFHoistingController extends BaseController {
|
|||
|
||||
case "5"://审批部门
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
String fileName = this.get32UUID()+file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
|
||||
Smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile);
|
||||
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
pd2.put("APPROVE_USER_SIGNER_PATH", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName);
|
||||
pd2.put("APPROVE_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
pd2.put("APPROVE_CONTENT", pd.get("CONTENT"));
|
||||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
pd2.put("OTHER_PROTECTIVE_MEASURES", OTHER_PROTECTIVE_MEASURES);
|
||||
map.put("dockData2", JSON.toJSONString(pd2));
|
||||
GFhoistingService.edit(pd2);
|
||||
log.put("ACTION", "审批部门通过");
|
||||
|
||||
|
@ -770,17 +827,21 @@ public class AppGFHoistingController extends BaseController {
|
|||
|
||||
case "6"://验收人
|
||||
if (files != null && files.length > 0) {
|
||||
ArrayList<String> pictureList = new ArrayList<String>();
|
||||
MultipartFile file = files[0];
|
||||
|
||||
String ffile = DateUtil.getDays();
|
||||
String fileName = this.get32UUID()+file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf("."));
|
||||
Smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile);
|
||||
|
||||
pictureList.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName + "@@" + fileName);
|
||||
map.put("sendPicturesList", JSON.toJSONString(pictureList));
|
||||
pd2.put("ACCEPT_USER_SIGNER_PATH", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName);
|
||||
pd2.put("ACCEPT_USER_SIGNER_TIME", pd.get("SIGNER_TIME"));
|
||||
pd2.put("ACCEPT_CONTENT", pd.get("CONTENT"));
|
||||
pd2.put("OTHER_PROTECTIVE_MEASURES", OTHER_PROTECTIVE_MEASURES);
|
||||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
map.put("dockData2", JSON.toJSONString(pd2));
|
||||
GFhoistingService.edit(pd2);
|
||||
log.put("ACTION", "验收通过");
|
||||
|
||||
|
@ -810,6 +871,7 @@ public class AppGFHoistingController extends BaseController {
|
|||
log.put("ACTION", "作业指挥打回");
|
||||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
pd2.put("LEADER_CONTENT", pd.get("CONTENT"));
|
||||
map.put("dockData2", JSON.toJSONString(pd2));
|
||||
GFhoistingService.edit(pd2);
|
||||
|
||||
|
||||
|
@ -843,6 +905,7 @@ public class AppGFHoistingController extends BaseController {
|
|||
log.put("ACTION", "所在单位打回");
|
||||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
pd2.put("CONSTRUCTION_CONTENT", pd.get("CONTENT"));
|
||||
map.put("dockData2", JSON.toJSONString(pd2));
|
||||
GFhoistingService.edit(pd2);
|
||||
|
||||
// 发短信
|
||||
|
@ -874,6 +937,7 @@ public class AppGFHoistingController extends BaseController {
|
|||
log.put("ACTION", "审核部门打回");
|
||||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
pd2.put("AUDIT_CONTENT", pd.get("CONTENT"));
|
||||
map.put("dockData2", JSON.toJSONString(pd2));
|
||||
GFhoistingService.edit(pd2);
|
||||
|
||||
// 发短信
|
||||
|
@ -905,6 +969,7 @@ public class AppGFHoistingController extends BaseController {
|
|||
log.put("ACTION", "审批部门打回");
|
||||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
pd2.put("APPROVE_CONTENT", pd.get("CONTENT"));
|
||||
map.put("dockData2", JSON.toJSONString(pd2));
|
||||
GFhoistingService.edit(pd2);
|
||||
|
||||
// 发短信
|
||||
|
@ -936,6 +1001,7 @@ public class AppGFHoistingController extends BaseController {
|
|||
log.put("ACTION", "验收人打回");
|
||||
pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS"));
|
||||
pd2.put("ACCEPT_CONTENT", pd.get("CONTENT"));
|
||||
map.put("dockData2", JSON.toJSONString(pd2));
|
||||
GFhoistingService.edit(pd2);
|
||||
|
||||
|
||||
|
@ -967,6 +1033,7 @@ public class AppGFHoistingController extends BaseController {
|
|||
default:
|
||||
break;
|
||||
}
|
||||
map.put("dockDataLog", JSON.toJSONString(log));
|
||||
GFhighWorkLogService.save(log);
|
||||
map.put("result", errInfo);
|
||||
return map;
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
package com.zcloud.controller.gf;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.zcloud.aspect.DockAnnotation;
|
||||
import com.zcloud.controller.base.BaseController;
|
||||
import com.zcloud.entity.Page;
|
||||
import com.zcloud.entity.PageData;
|
||||
|
@ -50,6 +52,7 @@ public class GFConfinedSpaceController extends BaseController {
|
|||
@RequestMapping(value="/add")
|
||||
@RequiresPermissions("confinedspace:add")
|
||||
@ResponseBody
|
||||
@DockAnnotation(isAdd = true)
|
||||
public Object add() throws Exception{
|
||||
Map<String,Object> map = new HashMap<String,Object>();
|
||||
String errInfo = "success";
|
||||
|
@ -57,6 +60,7 @@ public class GFConfinedSpaceController extends BaseController {
|
|||
pd = this.getPageData();
|
||||
pd.put("CONFINEDSPACE_ID", this.get32UUID()); //主键
|
||||
GFconfinedspaceService.save(pd);
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
map.put("result", errInfo);
|
||||
return map;
|
||||
}
|
||||
|
@ -68,12 +72,14 @@ public class GFConfinedSpaceController extends BaseController {
|
|||
@RequestMapping(value="/delete")
|
||||
@RequiresPermissions("confinedspace:del")
|
||||
@ResponseBody
|
||||
@DockAnnotation
|
||||
public Object delete() throws Exception{
|
||||
Map<String,String> map = new HashMap<String,String>();
|
||||
String errInfo = "success";
|
||||
PageData pd = new PageData();
|
||||
pd = this.getPageData();
|
||||
GFconfinedspaceService.delete(pd);
|
||||
map.put("pd", JSON.toJSONString(pd));
|
||||
map.put("result", errInfo); //返回结果
|
||||
return map;
|
||||
}
|
||||
|
@ -85,12 +91,14 @@ public class GFConfinedSpaceController extends BaseController {
|
|||
@RequestMapping(value="/edit")
|
||||
@RequiresPermissions("confinedspace:edit")
|
||||
@ResponseBody
|
||||
@DockAnnotation
|
||||
public Object edit() throws Exception{
|
||||
Map<String,Object> map = new HashMap<String,Object>();
|
||||
String errInfo = "success";
|
||||
PageData pd = new PageData();
|
||||
pd = this.getPageData();
|
||||
GFconfinedspaceService.edit(pd);
|
||||
map.put("pd", JSON.toJSONString(pd));
|
||||
map.put("result", errInfo);
|
||||
return map;
|
||||
}
|
||||
|
@ -100,7 +108,7 @@ public class GFConfinedSpaceController extends BaseController {
|
|||
* @throws Exception
|
||||
*/
|
||||
@RequestMapping(value="/list")
|
||||
@RequiresPermissions("confinedspace:list")
|
||||
// @RequiresPermissions("confinedspace:list")
|
||||
@ResponseBody
|
||||
public Object list(Page page) throws Exception{
|
||||
Map<String,Object> map = new HashMap<String,Object>();
|
||||
|
@ -155,6 +163,7 @@ public class GFConfinedSpaceController extends BaseController {
|
|||
@RequestMapping(value="/deleteAll")
|
||||
@RequiresPermissions("confinedspace:del")
|
||||
@ResponseBody
|
||||
@DockAnnotation
|
||||
public Object deleteAll() throws Exception{
|
||||
Map<String,Object> map = new HashMap<String,Object>();
|
||||
String errInfo = "success";
|
||||
|
@ -168,6 +177,7 @@ public class GFConfinedSpaceController extends BaseController {
|
|||
}else{
|
||||
errInfo = "error";
|
||||
}
|
||||
map.put("pd", JSON.toJSONString(pd));
|
||||
map.put("result", errInfo); //返回结果
|
||||
return map;
|
||||
}
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
package com.zcloud.controller.gf;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.zcloud.aspect.DockAnnotation;
|
||||
import com.zcloud.controller.base.BaseController;
|
||||
import com.zcloud.entity.Page;
|
||||
import com.zcloud.entity.PageData;
|
||||
|
@ -40,6 +42,7 @@ public class GFLimitSpaceApproveController extends BaseController {
|
|||
@RequestMapping(value="/add")
|
||||
@RequiresPermissions("limitspaceapprove:add")
|
||||
@ResponseBody
|
||||
@DockAnnotation(isAdd = true)
|
||||
public Object add() throws Exception{
|
||||
Map<String,Object> map = new HashMap<String,Object>();
|
||||
String errInfo = "success";
|
||||
|
@ -53,6 +56,7 @@ public class GFLimitSpaceApproveController extends BaseController {
|
|||
pd.put("OPERATTIME", DateUtil.date2Str(new Date())); //修改时间
|
||||
pd.put("ISDELETE", ""); //是否删除 1-是 0-否
|
||||
GFlimitspaceapproveService.save(pd);
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
map.put("result", errInfo);
|
||||
return map;
|
||||
}
|
||||
|
@ -64,12 +68,14 @@ public class GFLimitSpaceApproveController extends BaseController {
|
|||
@RequestMapping(value="/delete")
|
||||
@RequiresPermissions("limitspaceapprove:del")
|
||||
@ResponseBody
|
||||
@DockAnnotation
|
||||
public Object delete() throws Exception{
|
||||
Map<String,String> map = new HashMap<String,String>();
|
||||
String errInfo = "success";
|
||||
PageData pd = new PageData();
|
||||
pd = this.getPageData();
|
||||
GFlimitspaceapproveService.delete(pd);
|
||||
map.put("pd", JSON.toJSONString(pd));
|
||||
map.put("result", errInfo); //返回结果
|
||||
return map;
|
||||
}
|
||||
|
@ -150,6 +156,7 @@ public class GFLimitSpaceApproveController extends BaseController {
|
|||
@RequestMapping(value="/deleteAll")
|
||||
@RequiresPermissions("limitspaceapprove:del")
|
||||
@ResponseBody
|
||||
@DockAnnotation
|
||||
public Object deleteAll() throws Exception{
|
||||
Map<String,Object> map = new HashMap<String,Object>();
|
||||
String errInfo = "success";
|
||||
|
@ -163,6 +170,7 @@ public class GFLimitSpaceApproveController extends BaseController {
|
|||
}else{
|
||||
errInfo = "error";
|
||||
}
|
||||
map.put("pd", JSON.toJSONString(pd));
|
||||
map.put("result", errInfo); //返回结果
|
||||
return map;
|
||||
}
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
package com.zcloud.controller.gf;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.zcloud.aspect.DockAnnotation;
|
||||
import com.zcloud.controller.base.BaseController;
|
||||
import com.zcloud.entity.Page;
|
||||
import com.zcloud.entity.PageData;
|
||||
|
@ -46,6 +48,7 @@ public class GFLimitSpaceController extends BaseController {
|
|||
@RequestMapping(value="/add")
|
||||
@RequiresPermissions("limitspace:add")
|
||||
@ResponseBody
|
||||
@DockAnnotation(isAdd = true)
|
||||
public Object add() throws Exception{
|
||||
Map<String,Object> map = new HashMap<String,Object>();
|
||||
String errInfo = "success";
|
||||
|
@ -59,6 +62,7 @@ public class GFLimitSpaceController extends BaseController {
|
|||
pd.put("OPERATTIME", DateUtil.date2Str(new Date())); //修改时间
|
||||
pd.put("ISDELETE", "0"); //是否删除
|
||||
GFlimitspaceService.save(pd);
|
||||
map.put("dockData", JSON.toJSONString(pd));
|
||||
map.put("result", errInfo);
|
||||
return map;
|
||||
}
|
||||
|
@ -70,6 +74,7 @@ public class GFLimitSpaceController extends BaseController {
|
|||
@RequestMapping(value="/delete")
|
||||
@RequiresPermissions("limitspace:del")
|
||||
@ResponseBody
|
||||
@DockAnnotation
|
||||
public Object delete() throws Exception{
|
||||
Map<String,String> map = new HashMap<String,String>();
|
||||
String errInfo = "success";
|
||||
|
@ -78,6 +83,7 @@ public class GFLimitSpaceController extends BaseController {
|
|||
pd.put("OPERATOR", Jurisdiction.getUsername()); //修改人
|
||||
pd.put("OPERATTIME", DateUtil.date2Str(new Date())); //修改时间
|
||||
GFlimitspaceService.delete(pd);
|
||||
map.put("pd",JSON.toJSONString(pd));
|
||||
map.put("result", errInfo); //返回结果
|
||||
return map;
|
||||
}
|
||||
|
@ -89,6 +95,7 @@ public class GFLimitSpaceController extends BaseController {
|
|||
@RequestMapping(value="/edit")
|
||||
@RequiresPermissions("limitspace:edit")
|
||||
@ResponseBody
|
||||
@DockAnnotation
|
||||
public Object edit() throws Exception{
|
||||
Map<String,Object> map = new HashMap<String,Object>();
|
||||
String errInfo = "success";
|
||||
|
@ -97,6 +104,7 @@ public class GFLimitSpaceController extends BaseController {
|
|||
pd.put("OPERATOR", Jurisdiction.getUsername()); //修改人
|
||||
pd.put("OPERATTIME", DateUtil.date2Str(new Date())); //修改时间
|
||||
GFlimitspaceService.edit(pd);
|
||||
map.put("pd", JSON.toJSONString(pd));
|
||||
map.put("result", errInfo);
|
||||
return map;
|
||||
}
|
||||
|
@ -106,7 +114,7 @@ public class GFLimitSpaceController extends BaseController {
|
|||
* @throws Exception
|
||||
*/
|
||||
@RequestMapping(value="/list")
|
||||
@RequiresPermissions("limitspace:list")
|
||||
// @RequiresPermissions("limitspace:list")
|
||||
@ResponseBody
|
||||
public Object list(Page page) throws Exception{
|
||||
Map<String,Object> map = new HashMap<String,Object>();
|
||||
|
@ -157,6 +165,7 @@ public class GFLimitSpaceController extends BaseController {
|
|||
@RequestMapping(value="/deleteAll")
|
||||
@RequiresPermissions("limitspace:del")
|
||||
@ResponseBody
|
||||
@DockAnnotation
|
||||
public Object deleteAll() throws Exception{
|
||||
Map<String,Object> map = new HashMap<String,Object>();
|
||||
String errInfo = "success";
|
||||
|
@ -173,6 +182,7 @@ public class GFLimitSpaceController extends BaseController {
|
|||
}else{
|
||||
errInfo = "error";
|
||||
}
|
||||
map.put("pd",JSON.toJSONString(pd));
|
||||
map.put("result", errInfo); //返回结果
|
||||
return map;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue