Browse Source

git-svn-id: https://192.168.57.71/svn/jsgkj@236 931142cf-59ea-a443-aa0e-51397b428577

ld_xuhx 9 years ago
parent
commit
1a24327b96

+ 20 - 13
gkjsjy/trunk/src/com/xt/jygl/gkjygl/cghzyxxgl/dcsb/ctl/DcsbCtl.java

@@ -429,7 +429,7 @@ public class DcsbCtl extends BaseWebCtl {
 
 	// 查看
 	@RequestMapping(value = "/view")
-	public String view(Model model, String id, String flag, String path, String fhflag,String type) {
+	public String view(Model model, String id, String flag, String path, String fhflag, String type) {
 		model.addAttribute("fhflag", fhflag);
 		model.addAttribute("flag", flag);
 		model.addAttribute("path", path);
@@ -457,7 +457,7 @@ public class DcsbCtl extends BaseWebCtl {
 
 	// 修改
 	@RequestMapping(value = "/edit")
-	public String edit(Model model, String id, String flag, String path,String type) {
+	public String edit(Model model, String id, String flag, String path, String type) {
 		model.addAttribute("flag", flag);
 		model.addAttribute("path", path);
 		model.addAttribute("type", type);
@@ -718,7 +718,7 @@ public class DcsbCtl extends BaseWebCtl {
 				dcsb.setShzt("2402");
 				entity = dcsbService.submit(dcsb);
 			} else {
- 				entity = dcsbService.findOne(dcsb.getId());
+				entity = dcsbService.findOne(dcsb.getId());
 				if (!StringUtils.isEmpty(mtid)) {
 					entity.setMt(mtid);
 				}
@@ -748,12 +748,12 @@ public class DcsbCtl extends BaseWebCtl {
 				entity.setHc(dcsb.getHc());
 				entity.setZypmc(dcsb.getZypmc());
 				entity.setZysl(dcsb.getZysl());
-				//entity.setJcg(dcsb.getJcg());
+				// entity.setJcg(dcsb.getJcg());
 				entity.setBgsj(dcsb.getBgsj());
 				entity.setSg(dcsb.getSg());
 				entity.setXg(dcsb.getXg());
 				entity.setZyfs(dcsb.getZyfs());
-				//entity.setNwm(dcsb.getNwm());
+				// entity.setNwm(dcsb.getNwm());
 				entity.setMtlb(dcsb.getMtlb());
 				entity.setJzxsl(dcsb.getJzxsl());
 				entity.setHuxs(dcsb.getHuxs());
@@ -775,9 +775,10 @@ public class DcsbCtl extends BaseWebCtl {
 				entity.setBgr(dcsb.getBgr());
 				entity.setLxfs(dcsb.getLxfs());
 				entity.setShzt("2402");
-				dcsbService.submit(entity);
+				entity = dcsbService.submit(entity);
 			}
-
+			// rtx提醒
+			rtxSend(entity.getSzgq().getId(), Constants.ROLE_DCSBSC, "你有一条单船申报待办事务,请及时处理!");
 		} catch (Exception e) {
 			wr.setSuccess(false);
 			wr.setMessage("操作失败!");
@@ -861,12 +862,12 @@ public class DcsbCtl extends BaseWebCtl {
 		entity.setHc(dcsb.getHc());
 		entity.setZypmc(dcsb.getZypmc());
 		entity.setZysl(dcsb.getZysl());
-		//entity.setJcg(dcsb.getJcg());
+		// entity.setJcg(dcsb.getJcg());
 		entity.setBgsj(dcsb.getBgsj());
 		entity.setSg(dcsb.getSg());
 		entity.setXg(dcsb.getXg());
 		entity.setZyfs(dcsb.getZyfs());
-		//entity.setNwm(dcsb.getNwm());
+		// entity.setNwm(dcsb.getNwm());
 		entity.setMtlb(dcsb.getMtlb());
 		entity.setJzxsl(dcsb.getJzxsl());
 		entity.setHuxs(dcsb.getHuxs());
@@ -888,12 +889,14 @@ public class DcsbCtl extends BaseWebCtl {
 		entity.setBgr(dcsb.getBgr());
 		entity.setLxfs(dcsb.getLxfs());
 		entity.setShzt("2402");
-		dcsbService.save(entity);
+		entity = dcsbService.save(entity);
 		try {
 			if (dcsbService.getCandidateTaskByUserAndBusKey(SecUtils.getCurrUser().getId().toString(), dcsb.getId()) != null) {
 				dcsbService.claim(dcsb.getId(), SecUtils.getCurrUser().getId().toString());
 			}
 			dcsbService.changeAudit(null, entity, true);
+			// rtx提醒
+			rtxSend(entity.getSzgq().getId(), Constants.ROLE_DCSBSC, "你有一条单船申报待办事务,请及时处理!");
 		} catch (Exception e) {
 			wr.setSuccess(false);
 			wr.setMessage("操作失败!");
@@ -910,10 +913,10 @@ public class DcsbCtl extends BaseWebCtl {
 		try {
 			// 子类一并删除
 			dcsbService.logicDelete(id);
-			
+
 			DcsbEntity entity = dcsbService.findOne(id);
 			dcsbService.changeAudit(null, entity, true);
-			
+
 		} catch (Exception e) {
 			wr.setSuccess(false);
 			wr.setMessage("删除失败!");
@@ -958,7 +961,11 @@ public class DcsbCtl extends BaseWebCtl {
 			if (dcsbService.getCandidateTaskByUserAndBusKey(SecUtils.getCurrUser().getId().toString(), id) != null) {
 				dcsbService.claim(id, SecUtils.getCurrUser().getId().toString());
 			}
-			dcsbService.changeAudit(shyj, entity, flag);
+			boolean jflag  = dcsbService.changeAudit(shyj, entity, flag);
+			if(!jflag){
+				// rtx提醒
+				rtxSend(entity.getSzgq().getId(), Constants.ROLE_DCSBSC, "你有一条单船申报待办事务,请及时处理!");
+			}
 		} catch (Exception e) {
 			wr.setSuccess(false);
 			wr.setMessage("操作失败!");

+ 1 - 2
gkjsjy/trunk/src/com/xt/jygl/gkjygl/cghzyxxgl/dcsb/service/impl/DcsbServiceImpl.java

@@ -119,9 +119,8 @@ public class DcsbServiceImpl extends BaseWorkFlowServiceImpl<DcsbEntity, String>
 		if (flag == false) {
 			entity.setRecordStatus(BaseEntity.RECORD_STATE_REJECT);
 			this.save(entity);
-			return true;
 		}
-		return true;
+		return false;
 	}
 
 	@Override