forked from integrated_whb/integrated_whb
行车三检
parent
8feddb6b97
commit
d282d1a2a7
|
@ -0,0 +1,180 @@
|
||||||
|
package com.zcloud.controller.comprehensive;
|
||||||
|
|
||||||
|
import com.zcloud.controller.base.BaseController;
|
||||||
|
import com.zcloud.entity.Page;
|
||||||
|
import com.zcloud.entity.PageData;
|
||||||
|
import com.zcloud.logs.LogAnno;
|
||||||
|
import com.zcloud.service.comprehensive.TrafficDrivingItemService;
|
||||||
|
import com.zcloud.service.comprehensive.TrafficDrivingSignService;
|
||||||
|
import com.zcloud.service.comprehensive.TrafficSecurityWaybillRegistrationService;
|
||||||
|
import com.zcloud.util.Const;
|
||||||
|
import com.zcloud.util.DateUtil;
|
||||||
|
import com.zcloud.util.Jurisdiction;
|
||||||
|
import com.zcloud.util.Smb;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Controller;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestParam;
|
||||||
|
import org.springframework.web.bind.annotation.ResponseBody;
|
||||||
|
import org.springframework.web.multipart.MultipartFile;
|
||||||
|
import org.springframework.web.multipart.MultipartRequest;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
|
||||||
|
@Controller
|
||||||
|
@RequestMapping("/app/drivingitem")
|
||||||
|
public class AppTrafficDrivingItemController extends BaseController {
|
||||||
|
@Autowired
|
||||||
|
private TrafficDrivingItemService trafficDrivingItemService;
|
||||||
|
@Autowired
|
||||||
|
private TrafficDrivingSignService trafficDrivingSignService;
|
||||||
|
@Autowired
|
||||||
|
private TrafficSecurityWaybillRegistrationService trafficSecurityWaybillRegistrationService;
|
||||||
|
@Autowired
|
||||||
|
private Smb smb;
|
||||||
|
|
||||||
|
|
||||||
|
/**新增
|
||||||
|
* @param
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
@RequestMapping(value="/add")
|
||||||
|
@ResponseBody
|
||||||
|
@Transactional
|
||||||
|
public Object add(MultipartRequest request) throws Exception{
|
||||||
|
Map<String,Object> map = new HashMap<String,Object>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = new PageData();
|
||||||
|
pd = this.getPageData();
|
||||||
|
List<MultipartFile> fileList = new ArrayList<MultipartFile>();
|
||||||
|
String SIGNTIME[] = pd.getString("SIGNTIME").split(",");
|
||||||
|
|
||||||
|
for (int i = 0; i < SIGNTIME.length; i++) {
|
||||||
|
fileList.add(request.getFile("file" + i));
|
||||||
|
}
|
||||||
|
pd.put("DRIVING_SIGN_ID", this.get32UUID());
|
||||||
|
pd.put("ISDELETE", "0"); //是否删除
|
||||||
|
pd.put("CREATORNAME", pd.getString("USER_NAME")); //是否发送短信0不发1发
|
||||||
|
pd.put("CREATOR", pd.getString("USER_ID")); //创建人
|
||||||
|
pd.put("CREATTIME", DateUtil.date2Str(new Date())); //创建时间
|
||||||
|
pd.put("OPERATOR", pd.getString("USER_ID")); //操作人
|
||||||
|
pd.put("OPERATORNAME", pd.getString("USER_NAME")); //操作人
|
||||||
|
pd.put("OPERATTIME", DateUtil.date2Str(new Date())); //操作时间
|
||||||
|
pd.put("PRACTITIONER", pd.getString("USER_ID")); //操作时间
|
||||||
|
trafficDrivingItemService.save(pd, fileList.toArray(new MultipartFile[fileList.size()]));
|
||||||
|
|
||||||
|
map.put("pd",pd);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**修改
|
||||||
|
* @param
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
@RequestMapping(value="/edit")
|
||||||
|
@ResponseBody
|
||||||
|
public Object edit() throws Exception{
|
||||||
|
Map<String,Object> map = new HashMap<String,Object>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = new PageData();
|
||||||
|
pd = this.getPageData();
|
||||||
|
pd.put("OPERATOR", Jurisdiction.getUSER_ID()); //操作人
|
||||||
|
pd.put("OPERATORNAME", Jurisdiction.getUsername()); //操作人
|
||||||
|
pd.put("OPERATTIME", DateUtil.date2Str(new Date())); //操作时间
|
||||||
|
trafficDrivingItemService.edit(pd);
|
||||||
|
|
||||||
|
map.put("pd",pd);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
//列表
|
||||||
|
@RequestMapping(value = "/listForSafetyDrivingItem")
|
||||||
|
@ResponseBody
|
||||||
|
public Object listForSecurityNotice(Page page) throws Exception {
|
||||||
|
Map<String, Object> map = new HashMap<String, Object>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = new PageData();
|
||||||
|
pd = this.getPageData();
|
||||||
|
|
||||||
|
page.setPd(pd);
|
||||||
|
List<PageData> varList = trafficDrivingItemService.listForDrivingItem(page);
|
||||||
|
map.put("varList", varList);
|
||||||
|
map.put("page", page);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取排查项类型
|
||||||
|
*
|
||||||
|
* @param
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
@RequestMapping(value = "/getDrivingItem")
|
||||||
|
@ResponseBody
|
||||||
|
public Object getRisk() throws Exception {
|
||||||
|
Map<String, Object> map = new HashMap<String, Object>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = new PageData();
|
||||||
|
pd = this.getPageData();
|
||||||
|
pd = trafficSecurityWaybillRegistrationService.findById(pd); // 根据ID读取
|
||||||
|
List<PageData> varList = trafficDrivingItemService.listAllType(pd);
|
||||||
|
List<PageData> vList = trafficDrivingSignService.listByID(pd);
|
||||||
|
if(vList != null && vList.size()>0){
|
||||||
|
if(vList.size()==0){
|
||||||
|
pd.put("IsExist",1);
|
||||||
|
}else if(vList.size()==1){
|
||||||
|
pd.put("IsExist",2);
|
||||||
|
}else{
|
||||||
|
pd.put("IsExist",3);
|
||||||
|
}
|
||||||
|
}else{
|
||||||
|
pd.put("IsExist",0);
|
||||||
|
}
|
||||||
|
map.put("pd", pd);
|
||||||
|
map.put("varList", varList);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**删除
|
||||||
|
* @param
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
@RequestMapping(value="/delete")
|
||||||
|
@ResponseBody
|
||||||
|
public Object delete() throws Exception{
|
||||||
|
Map<String,String> map = new HashMap<String,String>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = new PageData();
|
||||||
|
pd = this.getPageData();
|
||||||
|
pd.put("DELETOR", Jurisdiction.getUSER_ID());//删除人id
|
||||||
|
pd.put("DELETORNAME", Jurisdiction.getUsername());//删除人姓名
|
||||||
|
pd.put("DELETETIME", DateUtil.date2Str(new Date()));//删除时间
|
||||||
|
trafficDrivingItemService.delete(pd);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查看详情
|
||||||
|
* @return
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
@RequestMapping(value="/goEdit")
|
||||||
|
@ResponseBody
|
||||||
|
public Object goEdit() throws Exception {
|
||||||
|
Map<String, Object> map = new HashMap<>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = this.getPageData();
|
||||||
|
pd = trafficDrivingItemService.findById(pd); // 根据ID读取
|
||||||
|
map.put("pd", pd);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,152 @@
|
||||||
|
package com.zcloud.controller.comprehensive;
|
||||||
|
|
||||||
|
import com.zcloud.controller.base.BaseController;
|
||||||
|
import com.zcloud.entity.Page;
|
||||||
|
import com.zcloud.entity.PageData;
|
||||||
|
import com.zcloud.service.comprehensive.TrafficDrivingTypeService;
|
||||||
|
import com.zcloud.util.Const;
|
||||||
|
import com.zcloud.util.DateUtil;
|
||||||
|
import com.zcloud.util.Jurisdiction;
|
||||||
|
import com.zcloud.util.Smb;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Controller;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestParam;
|
||||||
|
import org.springframework.web.bind.annotation.ResponseBody;
|
||||||
|
import org.springframework.web.multipart.MultipartFile;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
import java.util.HashMap;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
@Controller
|
||||||
|
@RequestMapping("/app/drivingtype")
|
||||||
|
public class AppTrafficDrivingTypeController extends BaseController {
|
||||||
|
@Autowired
|
||||||
|
private TrafficDrivingTypeService trafficDrivingTypeService;
|
||||||
|
@Autowired
|
||||||
|
private Smb smb;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**新增
|
||||||
|
* @param
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
@RequestMapping(value="/add")
|
||||||
|
@ResponseBody
|
||||||
|
@Transactional
|
||||||
|
public Object add() throws Exception{
|
||||||
|
Map<String,Object> map = new HashMap<String,Object>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = new PageData();
|
||||||
|
pd = this.getPageData();
|
||||||
|
pd.put("DRIVINGTYPE_ID", this.get32UUID());
|
||||||
|
pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID()); //主键
|
||||||
|
pd.put("ISDELETE", "0"); //是否删除
|
||||||
|
pd.put("CREATORNAME", Jurisdiction.getUsername()); //是否发送短信0不发1发
|
||||||
|
pd.put("CREATOR", Jurisdiction.getUSER_ID()); //创建人
|
||||||
|
pd.put("CREATTIME", DateUtil.date2Str(new Date())); //创建时间
|
||||||
|
pd.put("OPERATOR", Jurisdiction.getUSER_ID()); //操作人
|
||||||
|
pd.put("OPERATORNAME", Jurisdiction.getUsername()); //操作人
|
||||||
|
pd.put("OPERATTIME", DateUtil.date2Str(new Date())); //操作时间
|
||||||
|
trafficDrivingTypeService.save(pd);
|
||||||
|
|
||||||
|
map.put("pd",pd);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**修改
|
||||||
|
* @param
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
@RequestMapping(value="/edit")
|
||||||
|
@ResponseBody
|
||||||
|
public Object edit() throws Exception{
|
||||||
|
Map<String,Object> map = new HashMap<String,Object>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = new PageData();
|
||||||
|
pd = this.getPageData();
|
||||||
|
pd.put("OPERATOR", Jurisdiction.getUSER_ID()); //操作人
|
||||||
|
pd.put("OPERATORNAME", Jurisdiction.getUsername()); //操作人
|
||||||
|
pd.put("OPERATTIME", DateUtil.date2Str(new Date())); //操作时间
|
||||||
|
trafficDrivingTypeService.edit(pd);
|
||||||
|
|
||||||
|
map.put("pd",pd);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
//列表
|
||||||
|
@RequestMapping(value = "/listForSafetyDrivingType")
|
||||||
|
@ResponseBody
|
||||||
|
public Object listForSecurityNotice(Page page) throws Exception {
|
||||||
|
Map<String, Object> map = new HashMap<String, Object>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = new PageData();
|
||||||
|
pd = this.getPageData();
|
||||||
|
|
||||||
|
page.setPd(pd);
|
||||||
|
List<PageData> varList = trafficDrivingTypeService.listForDrivingType(page);
|
||||||
|
map.put("varList", varList);
|
||||||
|
map.put("page", page);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
@RequestMapping("/saveFile")
|
||||||
|
@ResponseBody
|
||||||
|
public Object saveFile(@RequestParam(value="file",required=false) MultipartFile file) throws Exception{
|
||||||
|
Map<String,Object> map = new HashMap<>();
|
||||||
|
String errorInfo = "success";
|
||||||
|
PageData pd = new PageData();
|
||||||
|
pd = this.getPageData();
|
||||||
|
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);
|
||||||
|
map.put("FILE_PATH", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName);
|
||||||
|
map.put("result",errorInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**删除
|
||||||
|
* @param
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
@RequestMapping(value="/delete")
|
||||||
|
@ResponseBody
|
||||||
|
public Object delete() throws Exception{
|
||||||
|
Map<String,String> map = new HashMap<String,String>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = new PageData();
|
||||||
|
pd = this.getPageData();
|
||||||
|
pd.put("DELETOR", Jurisdiction.getUSER_ID());//删除人id
|
||||||
|
pd.put("DELETORNAME", Jurisdiction.getUsername());//删除人姓名
|
||||||
|
pd.put("DELETETIME", DateUtil.date2Str(new Date()));//删除时间
|
||||||
|
trafficDrivingTypeService.delete(pd);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查看详情
|
||||||
|
* @return
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
@RequestMapping(value="/goEdit")
|
||||||
|
@ResponseBody
|
||||||
|
public Object goEdit() throws Exception {
|
||||||
|
Map<String, Object> map = new HashMap<>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = this.getPageData();
|
||||||
|
pd = trafficDrivingTypeService.findById(pd); // 根据ID读取
|
||||||
|
map.put("pd", pd);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,120 @@
|
||||||
|
package com.zcloud.controller.comprehensive;
|
||||||
|
|
||||||
|
import com.zcloud.controller.base.BaseController;
|
||||||
|
import com.zcloud.entity.Page;
|
||||||
|
import com.zcloud.entity.PageData;
|
||||||
|
import com.zcloud.service.comprehensive.TrafficDrivingCommitmentService;
|
||||||
|
import com.zcloud.service.comprehensive.TrafficSecurityWaybillRegistrationService;
|
||||||
|
import com.zcloud.util.DateUtil;
|
||||||
|
import com.zcloud.util.Jurisdiction;
|
||||||
|
import com.zcloud.util.Tools;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Controller;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.ResponseBody;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
import java.util.HashMap;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
@Controller
|
||||||
|
@RequestMapping("/app/waybillregistration")
|
||||||
|
public class AppTrafficSecurityWaybillRegistrationController extends BaseController {
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private TrafficSecurityWaybillRegistrationService trafficSecurityWaybillRegistrationService;
|
||||||
|
@Autowired
|
||||||
|
private TrafficDrivingCommitmentService trafficDrivingCommitmentService;
|
||||||
|
|
||||||
|
|
||||||
|
@RequestMapping(value = "/listForSecurityWaybillre")
|
||||||
|
@ResponseBody
|
||||||
|
public Object listForSecurityWaybillRegistra(Page page) throws Exception {
|
||||||
|
Map<String, Object> map = new HashMap<String, Object>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = new PageData();
|
||||||
|
pd = this.getPageData();
|
||||||
|
|
||||||
|
String TITLE = pd.getString("TITLE"); // 关键词检索条件
|
||||||
|
if (Tools.notEmpty(TITLE))
|
||||||
|
pd.put("TITLE", TITLE.trim());
|
||||||
|
|
||||||
|
String REPLYSTATUS = pd.getString("REPLYSTATUS"); // 关键词检索条件
|
||||||
|
if (Tools.notEmpty(REPLYSTATUS))
|
||||||
|
pd.put("REPLYSTATUS", REPLYSTATUS.trim());
|
||||||
|
String KEYWORDS = pd.getString("KEYWORDS"); //关键词检索条件
|
||||||
|
if(Tools.notEmpty(KEYWORDS))pd.put("KEYWORDS", KEYWORDS.trim());
|
||||||
|
page.setPd(pd);
|
||||||
|
List<PageData> varList = trafficSecurityWaybillRegistrationService.listForSecurityWaybill(page);
|
||||||
|
|
||||||
|
map.put("varList", varList);
|
||||||
|
map.put("page", page);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
@RequestMapping(value = "/forSecurityPerson")
|
||||||
|
@ResponseBody
|
||||||
|
public Object forSecurityPerson() throws Exception {
|
||||||
|
Map<String, Object> map = new HashMap<String, Object>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = new PageData();
|
||||||
|
pd = this.getPageData();
|
||||||
|
pd.put("TRANSPORTATIONCOMPANY", Jurisdiction.getCORPINFO_ID());
|
||||||
|
pd = trafficSecurityWaybillRegistrationService.forSecurityPerson(pd);
|
||||||
|
pd.put("PRACTITIONER", Jurisdiction.getName());
|
||||||
|
map.put("pd", pd);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查看详情
|
||||||
|
* @return
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
@RequestMapping(value="/getDetail")
|
||||||
|
@ResponseBody
|
||||||
|
public Object goEdit() throws Exception {
|
||||||
|
Map<String, Object> map = new HashMap<>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = this.getPageData();
|
||||||
|
pd = trafficSecurityWaybillRegistrationService.findById(pd); // 根据ID读取
|
||||||
|
List<PageData> commitmentList = trafficDrivingCommitmentService.getDrivingCommitment(pd);
|
||||||
|
map.put("commitmentList", commitmentList);
|
||||||
|
map.put("pd", pd);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
//新增
|
||||||
|
@RequestMapping(value = "/add")
|
||||||
|
@ResponseBody
|
||||||
|
public Object add() throws Exception {
|
||||||
|
Map<String, Object> map = new HashMap<String, Object>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = this.getPageData();
|
||||||
|
String waybillregistrationId = this.get32UUID();
|
||||||
|
|
||||||
|
pd.put("CREATOR", Jurisdiction.getUSER_ID()); // 创建人id
|
||||||
|
pd.put("CREATORNAME", Jurisdiction.getName()); // 创建人姓名
|
||||||
|
pd.put("TRANSPORTATIONCOMPANY", Jurisdiction.getCORPINFO_ID()); // 运输企业
|
||||||
|
pd.put("WAYBILLREGISTRATION_ID", waybillregistrationId); // 主键
|
||||||
|
pd.put("CREATETIME", DateUtil.date2Str(new Date())); // 添加时间
|
||||||
|
pd.put("WAYBILLNUMBER", this.get32UUID()); // 添加时间
|
||||||
|
pd.put("ISDELETE", "0");
|
||||||
|
Date shippingDate = DateUtil.str2Date(pd.getString("SHIPPINGDATE"));
|
||||||
|
if (shippingDate != null && shippingDate.after(new Date())) {
|
||||||
|
pd.put("WAYBILLSTATUS", "1");
|
||||||
|
} else {
|
||||||
|
pd.put("WAYBILLSTATUS", "0");
|
||||||
|
}
|
||||||
|
|
||||||
|
trafficSecurityWaybillRegistrationService.save(pd);
|
||||||
|
|
||||||
|
map.put("result", errInfo);
|
||||||
|
map.put("pd", pd);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,137 @@
|
||||||
|
package com.zcloud.controller.comprehensive;
|
||||||
|
|
||||||
|
import com.zcloud.controller.base.BaseController;
|
||||||
|
import com.zcloud.entity.Page;
|
||||||
|
import com.zcloud.entity.PageData;
|
||||||
|
import com.zcloud.logs.LogAnno;
|
||||||
|
import com.zcloud.service.comprehensive.TrafficDrivingCommitmentService;
|
||||||
|
import com.zcloud.util.*;
|
||||||
|
import org.apache.commons.lang.StringUtils;
|
||||||
|
import org.apache.shiro.SecurityUtils;
|
||||||
|
import org.apache.shiro.crypto.hash.SimpleHash;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Controller;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestParam;
|
||||||
|
import org.springframework.web.bind.annotation.ResponseBody;
|
||||||
|
import org.springframework.web.multipart.MultipartFile;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
import java.util.HashMap;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
@Controller
|
||||||
|
@RequestMapping("/drivingcommitment")
|
||||||
|
public class TrafficDrivingCommitmentController extends BaseController {
|
||||||
|
@Autowired
|
||||||
|
private TrafficDrivingCommitmentService trafficDrivingCommitmentService;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**新增
|
||||||
|
* @param
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
@RequestMapping(value="/add")
|
||||||
|
@ResponseBody
|
||||||
|
@Transactional
|
||||||
|
public Object add() throws Exception{
|
||||||
|
Map<String,Object> map = new HashMap<String,Object>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = new PageData();
|
||||||
|
pd = this.getPageData();
|
||||||
|
pd.put("DRIVINGCOMMITMENT_ID", this.get32UUID());
|
||||||
|
pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID()); //主键
|
||||||
|
pd.put("ISDELETE", "0"); //是否删除
|
||||||
|
pd.put("INQUIRYCONCLUSION","正常");
|
||||||
|
pd.put("CREATORNAME", Jurisdiction.getUsername()); //是否发送短信0不发1发
|
||||||
|
pd.put("CREATOR", Jurisdiction.getUSER_ID()); //创建人
|
||||||
|
pd.put("CREATTIME", DateUtil.date2Str(new Date())); //创建时间
|
||||||
|
pd.put("OPERATOR", Jurisdiction.getUSER_ID()); //操作人
|
||||||
|
pd.put("OPERATORNAME", Jurisdiction.getUsername()); //操作人
|
||||||
|
pd.put("OPERATTIME", DateUtil.date2Str(new Date())); //操作时间
|
||||||
|
trafficDrivingCommitmentService.save(pd);
|
||||||
|
|
||||||
|
map.put("pd",pd);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**修改
|
||||||
|
* @param
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
@RequestMapping(value="/edit")
|
||||||
|
@ResponseBody
|
||||||
|
public Object edit() throws Exception{
|
||||||
|
Map<String,Object> map = new HashMap<String,Object>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = new PageData();
|
||||||
|
pd = this.getPageData();
|
||||||
|
pd.put("OPERATOR", Jurisdiction.getUSER_ID()); //操作人
|
||||||
|
pd.put("OPERATORNAME", Jurisdiction.getUsername()); //操作人
|
||||||
|
pd.put("OPERATTIME", DateUtil.date2Str(new Date())); //操作时间
|
||||||
|
trafficDrivingCommitmentService.edit(pd);
|
||||||
|
|
||||||
|
map.put("pd",pd);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
//列表
|
||||||
|
@RequestMapping(value = "/listForSafetyDrivingCommitment")
|
||||||
|
@ResponseBody
|
||||||
|
public Object listForSecurityNotice(Page page) throws Exception {
|
||||||
|
Map<String, Object> map = new HashMap<String, Object>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = new PageData();
|
||||||
|
pd = this.getPageData();
|
||||||
|
|
||||||
|
page.setPd(pd);
|
||||||
|
List<PageData> varList = trafficDrivingCommitmentService.listForDrivingCommitment(page);
|
||||||
|
map.put("varList", varList);
|
||||||
|
map.put("page", page);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**删除
|
||||||
|
* @param
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
@RequestMapping(value="/delete")
|
||||||
|
@ResponseBody
|
||||||
|
public Object delete() throws Exception{
|
||||||
|
Map<String,String> map = new HashMap<String,String>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = new PageData();
|
||||||
|
pd = this.getPageData();
|
||||||
|
pd.put("DELETOR", Jurisdiction.getUSER_ID());//删除人id
|
||||||
|
pd.put("DELETORNAME", Jurisdiction.getUsername());//删除人姓名
|
||||||
|
pd.put("DELETETIME", DateUtil.date2Str(new Date()));//删除时间
|
||||||
|
trafficDrivingCommitmentService.delete(pd);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查看详情
|
||||||
|
* @return
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
@RequestMapping(value="/goEdit")
|
||||||
|
@ResponseBody
|
||||||
|
public Object goEdit() throws Exception {
|
||||||
|
Map<String, Object> map = new HashMap<>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = this.getPageData();
|
||||||
|
pd = trafficDrivingCommitmentService.findById(pd); // 根据ID读取
|
||||||
|
map.put("pd", pd);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,131 @@
|
||||||
|
package com.zcloud.controller.comprehensive;
|
||||||
|
|
||||||
|
import com.zcloud.controller.base.BaseController;
|
||||||
|
import com.zcloud.entity.Page;
|
||||||
|
import com.zcloud.entity.PageData;
|
||||||
|
import com.zcloud.service.comprehensive.TrafficDrivingTypeService;
|
||||||
|
import com.zcloud.util.DateUtil;
|
||||||
|
import com.zcloud.util.Jurisdiction;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Controller;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.ResponseBody;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
import java.util.HashMap;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
@Controller
|
||||||
|
@RequestMapping("/drivingtype")
|
||||||
|
public class TrafficDrivingTypeController extends BaseController {
|
||||||
|
@Autowired
|
||||||
|
private TrafficDrivingTypeService trafficDrivingTypeService;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**新增
|
||||||
|
* @param
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
@RequestMapping(value="/add")
|
||||||
|
@ResponseBody
|
||||||
|
@Transactional
|
||||||
|
public Object add() throws Exception{
|
||||||
|
Map<String,Object> map = new HashMap<String,Object>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = new PageData();
|
||||||
|
pd = this.getPageData();
|
||||||
|
pd.put("DRIVINGTYPE_ID", this.get32UUID());
|
||||||
|
pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID()); //主键
|
||||||
|
pd.put("ISDELETE", "0"); //是否删除
|
||||||
|
pd.put("CREATORNAME", Jurisdiction.getUsername()); //是否发送短信0不发1发
|
||||||
|
pd.put("CREATOR", Jurisdiction.getUSER_ID()); //创建人
|
||||||
|
pd.put("CREATTIME", DateUtil.date2Str(new Date())); //创建时间
|
||||||
|
pd.put("OPERATOR", Jurisdiction.getUSER_ID()); //操作人
|
||||||
|
pd.put("OPERATORNAME", Jurisdiction.getUsername()); //操作人
|
||||||
|
pd.put("OPERATTIME", DateUtil.date2Str(new Date())); //操作时间
|
||||||
|
trafficDrivingTypeService.save(pd);
|
||||||
|
|
||||||
|
map.put("pd",pd);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**修改
|
||||||
|
* @param
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
@RequestMapping(value="/edit")
|
||||||
|
@ResponseBody
|
||||||
|
public Object edit() throws Exception{
|
||||||
|
Map<String,Object> map = new HashMap<String,Object>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = new PageData();
|
||||||
|
pd = this.getPageData();
|
||||||
|
pd.put("OPERATOR", Jurisdiction.getUSER_ID()); //操作人
|
||||||
|
pd.put("OPERATORNAME", Jurisdiction.getUsername()); //操作人
|
||||||
|
pd.put("OPERATTIME", DateUtil.date2Str(new Date())); //操作时间
|
||||||
|
trafficDrivingTypeService.edit(pd);
|
||||||
|
|
||||||
|
map.put("pd",pd);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
//列表
|
||||||
|
@RequestMapping(value = "/listForSafetyDrivingType")
|
||||||
|
@ResponseBody
|
||||||
|
public Object listForSecurityNotice(Page page) throws Exception {
|
||||||
|
Map<String, Object> map = new HashMap<String, Object>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = new PageData();
|
||||||
|
pd = this.getPageData();
|
||||||
|
|
||||||
|
page.setPd(pd);
|
||||||
|
List<PageData> varList = trafficDrivingTypeService.listForDrivingType(page);
|
||||||
|
map.put("varList", varList);
|
||||||
|
map.put("page", page);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**删除
|
||||||
|
* @param
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
@RequestMapping(value="/delete")
|
||||||
|
@ResponseBody
|
||||||
|
public Object delete() throws Exception{
|
||||||
|
Map<String,String> map = new HashMap<String,String>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = new PageData();
|
||||||
|
pd = this.getPageData();
|
||||||
|
pd.put("DELETOR", Jurisdiction.getUSER_ID());//删除人id
|
||||||
|
pd.put("DELETORNAME", Jurisdiction.getUsername());//删除人姓名
|
||||||
|
pd.put("DELETETIME", DateUtil.date2Str(new Date()));//删除时间
|
||||||
|
trafficDrivingTypeService.delete(pd);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查看详情
|
||||||
|
* @return
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
@RequestMapping(value="/goEdit")
|
||||||
|
@ResponseBody
|
||||||
|
public Object goEdit() throws Exception {
|
||||||
|
Map<String, Object> map = new HashMap<>();
|
||||||
|
String errInfo = "success";
|
||||||
|
PageData pd = this.getPageData();
|
||||||
|
pd = trafficDrivingTypeService.findById(pd); // 根据ID读取
|
||||||
|
map.put("pd", pd);
|
||||||
|
map.put("result", errInfo);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,44 @@
|
||||||
|
package com.zcloud.mapper.datasource.comprehensive;
|
||||||
|
|
||||||
|
import com.zcloud.entity.Page;
|
||||||
|
import com.zcloud.entity.PageData;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Mapper
|
||||||
|
public interface TrafficDrivingCommitmentMapper {
|
||||||
|
|
||||||
|
/**新增
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
void save(PageData pd);
|
||||||
|
|
||||||
|
/**修改
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
void edit(PageData pd);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 列表
|
||||||
|
* @param page
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
List<PageData> datalistPage(Page page);
|
||||||
|
|
||||||
|
List<PageData> getDrivingCommitment(PageData pd);
|
||||||
|
|
||||||
|
/**删除
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
void delete(PageData pd);
|
||||||
|
|
||||||
|
/**通过id获取数据
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
PageData findById(PageData pd);
|
||||||
|
}
|
|
@ -0,0 +1,44 @@
|
||||||
|
package com.zcloud.mapper.datasource.comprehensive;
|
||||||
|
|
||||||
|
import com.zcloud.entity.Page;
|
||||||
|
import com.zcloud.entity.PageData;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Mapper
|
||||||
|
public interface TrafficDrivingItemMapper {
|
||||||
|
|
||||||
|
/**新增
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
void save(PageData pd);
|
||||||
|
|
||||||
|
/**修改
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
void edit(PageData pd);
|
||||||
|
|
||||||
|
List<PageData> listAllType(PageData pd);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 列表
|
||||||
|
* @param page
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
List<PageData> datalistPage(Page page);
|
||||||
|
|
||||||
|
/**删除
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
void delete(PageData pd);
|
||||||
|
|
||||||
|
/**通过id获取数据
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
PageData findById(PageData pd);
|
||||||
|
}
|
|
@ -0,0 +1,47 @@
|
||||||
|
package com.zcloud.mapper.datasource.comprehensive;
|
||||||
|
|
||||||
|
import com.zcloud.entity.Page;
|
||||||
|
import com.zcloud.entity.PageData;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Mapper
|
||||||
|
public interface TrafficDrivingSignMapper {
|
||||||
|
|
||||||
|
/**新增
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
void save(PageData pd);
|
||||||
|
|
||||||
|
/**修改
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
void edit(PageData pd);
|
||||||
|
|
||||||
|
|
||||||
|
List<PageData> listByID(PageData pd);
|
||||||
|
|
||||||
|
List<PageData> listAllType(PageData pd);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 列表
|
||||||
|
* @param page
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
List<PageData> datalistPage(Page page);
|
||||||
|
|
||||||
|
/**删除
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
void delete(PageData pd);
|
||||||
|
|
||||||
|
/**通过id获取数据
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
PageData findById(PageData pd);
|
||||||
|
}
|
|
@ -0,0 +1,43 @@
|
||||||
|
package com.zcloud.mapper.datasource.comprehensive;
|
||||||
|
|
||||||
|
import com.zcloud.entity.Page;
|
||||||
|
import com.zcloud.entity.PageData;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Mapper
|
||||||
|
public interface TrafficDrivingTypeMapper {
|
||||||
|
|
||||||
|
/**新增
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
void save(PageData pd);
|
||||||
|
|
||||||
|
/**修改
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
void edit(PageData pd);
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 列表
|
||||||
|
* @param page
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
List<PageData> datalistPage(Page page);
|
||||||
|
|
||||||
|
/**删除
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
void delete(PageData pd);
|
||||||
|
|
||||||
|
/**通过id获取数据
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
PageData findById(PageData pd);
|
||||||
|
}
|
|
@ -18,5 +18,13 @@ public interface TrafficSecurityWaybillRegistrationMapper {
|
||||||
|
|
||||||
void save(PageData pd);
|
void save(PageData pd);
|
||||||
|
|
||||||
|
void editStatus(PageData pd);
|
||||||
|
|
||||||
PageData forSecurityPerson(PageData pd);
|
PageData forSecurityPerson(PageData pd);
|
||||||
|
|
||||||
|
/**通过id获取数据
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
PageData findById(PageData pd);
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,28 @@
|
||||||
|
package com.zcloud.service.comprehensive;
|
||||||
|
|
||||||
|
import com.zcloud.entity.Page;
|
||||||
|
import com.zcloud.entity.PageData;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public interface TrafficDrivingCommitmentService {
|
||||||
|
/**新增
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
public void save(PageData pd)throws Exception;
|
||||||
|
|
||||||
|
/**修改
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
public void edit(PageData pd)throws Exception;
|
||||||
|
|
||||||
|
List<PageData> listForDrivingCommitment(Page page);
|
||||||
|
|
||||||
|
List<PageData> getDrivingCommitment(PageData pd);
|
||||||
|
|
||||||
|
void delete(PageData pd);
|
||||||
|
|
||||||
|
PageData findById(PageData pd);
|
||||||
|
}
|
|
@ -0,0 +1,34 @@
|
||||||
|
package com.zcloud.service.comprehensive;
|
||||||
|
|
||||||
|
import com.zcloud.entity.Page;
|
||||||
|
import com.zcloud.entity.PageData;
|
||||||
|
import org.springframework.web.multipart.MultipartFile;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public interface TrafficDrivingItemService {
|
||||||
|
/**新增
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
public void save(PageData pd, MultipartFile[] files)throws Exception;
|
||||||
|
|
||||||
|
/**修改
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
public void edit(PageData pd)throws Exception;
|
||||||
|
|
||||||
|
/**排查项类型
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
public List<PageData> listAllType(PageData pd)throws Exception;
|
||||||
|
|
||||||
|
|
||||||
|
List<PageData> listForDrivingItem(Page page);
|
||||||
|
|
||||||
|
void delete(PageData pd);
|
||||||
|
|
||||||
|
PageData findById(PageData pd) throws Exception;
|
||||||
|
}
|
|
@ -0,0 +1,34 @@
|
||||||
|
package com.zcloud.service.comprehensive;
|
||||||
|
|
||||||
|
import com.zcloud.entity.Page;
|
||||||
|
import com.zcloud.entity.PageData;
|
||||||
|
import org.springframework.web.multipart.MultipartFile;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public interface TrafficDrivingSignService {
|
||||||
|
/**新增
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
public void save(PageData pd, MultipartFile[] files)throws Exception;
|
||||||
|
|
||||||
|
/**修改
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
public void edit(PageData pd)throws Exception;
|
||||||
|
|
||||||
|
/**排查项类型
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
public List<PageData> listByID(PageData pd)throws Exception;
|
||||||
|
|
||||||
|
|
||||||
|
List<PageData> listForDrivingItem(Page page);
|
||||||
|
|
||||||
|
void delete(PageData pd);
|
||||||
|
|
||||||
|
PageData findById(PageData pd) throws Exception;
|
||||||
|
}
|
|
@ -0,0 +1,28 @@
|
||||||
|
package com.zcloud.service.comprehensive;
|
||||||
|
|
||||||
|
import com.zcloud.entity.Page;
|
||||||
|
import com.zcloud.entity.PageData;
|
||||||
|
import org.springframework.web.multipart.MultipartFile;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public interface TrafficDrivingTypeService {
|
||||||
|
/**新增
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
public void save(PageData pd)throws Exception;
|
||||||
|
|
||||||
|
/**修改
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
public void edit(PageData pd)throws Exception;
|
||||||
|
|
||||||
|
|
||||||
|
List<PageData> listForDrivingType(Page page);
|
||||||
|
|
||||||
|
void delete(PageData pd);
|
||||||
|
|
||||||
|
PageData findById(PageData pd) throws Exception;
|
||||||
|
}
|
|
@ -11,4 +11,6 @@ public interface TrafficSecurityWaybillRegistrationService {
|
||||||
void save(PageData pd);
|
void save(PageData pd);
|
||||||
|
|
||||||
PageData forSecurityPerson(PageData pd);
|
PageData forSecurityPerson(PageData pd);
|
||||||
|
|
||||||
|
PageData findById(PageData pd);
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,62 @@
|
||||||
|
package com.zcloud.service.comprehensive.impl;
|
||||||
|
|
||||||
|
import com.zcloud.entity.Page;
|
||||||
|
import com.zcloud.entity.PageData;
|
||||||
|
import com.zcloud.mapper.datasource.comprehensive.TrafficDrivingCommitmentMapper;
|
||||||
|
import com.zcloud.service.comprehensive.TrafficDrivingCommitmentService;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Service
|
||||||
|
public class TrafficDrivingCommitmentServiceImpl implements TrafficDrivingCommitmentService {
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private TrafficDrivingCommitmentMapper trafficDrivingCommitmentMapper;
|
||||||
|
|
||||||
|
|
||||||
|
/**新增
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
public void save(PageData pd)throws Exception{
|
||||||
|
trafficDrivingCommitmentMapper.save(pd);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**修改
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
public void edit(PageData pd)throws Exception{
|
||||||
|
trafficDrivingCommitmentMapper.edit(pd);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 列表
|
||||||
|
* @param page
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public List<PageData> listForDrivingCommitment(Page page) {
|
||||||
|
return trafficDrivingCommitmentMapper.datalistPage(page);
|
||||||
|
}
|
||||||
|
|
||||||
|
public List<PageData> getDrivingCommitment(PageData pd) {
|
||||||
|
return trafficDrivingCommitmentMapper.getDrivingCommitment(pd);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除
|
||||||
|
* @param pd
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public void delete(PageData pd) {
|
||||||
|
trafficDrivingCommitmentMapper.delete(pd);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageData findById(PageData pd) {
|
||||||
|
return trafficDrivingCommitmentMapper.findById(pd);
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,107 @@
|
||||||
|
package com.zcloud.service.comprehensive.impl;
|
||||||
|
|
||||||
|
import com.alibaba.fastjson.JSON;
|
||||||
|
import com.alibaba.fastjson.JSONObject;
|
||||||
|
import com.zcloud.entity.Page;
|
||||||
|
import com.zcloud.entity.PageData;
|
||||||
|
import com.zcloud.mapper.datasource.comprehensive.TrafficDrivingItemMapper;
|
||||||
|
import com.zcloud.mapper.datasource.comprehensive.TrafficDrivingSignMapper;
|
||||||
|
import com.zcloud.mapper.datasource.comprehensive.TrafficSecurityWaybillRegistrationMapper;
|
||||||
|
import com.zcloud.service.comprehensive.TrafficDrivingItemService;
|
||||||
|
import com.zcloud.util.Const;
|
||||||
|
import com.zcloud.util.DateUtil;
|
||||||
|
import com.zcloud.util.Smb;
|
||||||
|
import com.zcloud.util.UuidUtil;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import org.springframework.web.multipart.MultipartFile;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Service
|
||||||
|
public class TrafficDrivingItemServiceImpl implements TrafficDrivingItemService {
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private TrafficDrivingItemMapper trafficDrivingItemMapper;
|
||||||
|
@Autowired
|
||||||
|
private TrafficDrivingSignMapper trafficDrivingSignMapper;
|
||||||
|
@Autowired
|
||||||
|
private com.zcloud.mapper.datasource.comprehensive.TrafficSecurityWaybillRegistrationMapper TrafficSecurityWaybillRegistrationMapper;
|
||||||
|
@Autowired
|
||||||
|
private Smb smb;
|
||||||
|
|
||||||
|
/**新增
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
public void save(PageData pd, MultipartFile[] files)throws Exception{
|
||||||
|
List<String> filePaths = new ArrayList<>();
|
||||||
|
for (int i = 0; i < files.length; i++) {
|
||||||
|
//保存签名文件
|
||||||
|
String ffile = DateUtil.getDays();
|
||||||
|
String fileName = UuidUtil.get32UUID() + files[i].getOriginalFilename().substring(files[i].getOriginalFilename().lastIndexOf("."));
|
||||||
|
smb.sshSftp(files[i], fileName, Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile);
|
||||||
|
filePaths.add(Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName);
|
||||||
|
}
|
||||||
|
pd.put("SIGN_TIME", pd.getString("SIGNTIME"));
|
||||||
|
pd.put("SIGN_PATH", String.join(",",filePaths));
|
||||||
|
trafficDrivingSignMapper.save(pd);
|
||||||
|
TrafficSecurityWaybillRegistrationMapper.editStatus(pd);
|
||||||
|
if (pd.get("checklist") != null && !pd.get("checklist").equals("")) { //安全措施确认步骤
|
||||||
|
List<JSONObject> list = (List<JSONObject>) JSON.parse(pd.get("checklist").toString());
|
||||||
|
for (JSONObject json : list) {
|
||||||
|
PageData checklist = new PageData();
|
||||||
|
checklist.put("DRIVING_SIGN_ID",pd.get("DRIVING_SIGN_ID"));
|
||||||
|
checklist.put("DRIVINGTYPE_ID",json.get("DRIVINGTYPE_ID"));
|
||||||
|
checklist.put("REMARK", json.get("REMARK"));
|
||||||
|
checklist.put("STATUS", json.get("ISNORMAL"));
|
||||||
|
checklist.put("OPERATTIME", json.get("OPERATTIME"));
|
||||||
|
checklist.put("OPERATORNAME", json.get("OPERATORNAME"));
|
||||||
|
checklist.put("OPERATOR", json.get("OPERATOR"));
|
||||||
|
checklist.put("ISDELETE", json.get("ISDELETE"));
|
||||||
|
checklist.put("DRIVING_ITEM_ID", UuidUtil.get32UUID());
|
||||||
|
trafficDrivingItemMapper.save(checklist);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public List<PageData> listAllType(PageData pd)throws Exception{
|
||||||
|
return trafficDrivingItemMapper.listAllType(pd);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**修改
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
public void edit(PageData pd)throws Exception{
|
||||||
|
trafficDrivingItemMapper.edit(pd);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 列表
|
||||||
|
* @param page
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public List<PageData> listForDrivingItem(Page page) {
|
||||||
|
return trafficDrivingItemMapper.datalistPage(page);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除
|
||||||
|
* @param pd
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public void delete(PageData pd) {
|
||||||
|
trafficDrivingItemMapper.delete(pd);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageData findById(PageData pd) throws Exception {
|
||||||
|
PageData pageData = trafficDrivingItemMapper.findById(pd);
|
||||||
|
return pageData;
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,65 @@
|
||||||
|
package com.zcloud.service.comprehensive.impl;
|
||||||
|
|
||||||
|
import com.zcloud.entity.Page;
|
||||||
|
import com.zcloud.entity.PageData;
|
||||||
|
import com.zcloud.mapper.datasource.comprehensive.TrafficDrivingSignMapper;
|
||||||
|
import com.zcloud.service.comprehensive.TrafficDrivingSignService;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import org.springframework.web.multipart.MultipartFile;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Service
|
||||||
|
public class TrafficDrivingSignServiceImpl implements TrafficDrivingSignService {
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private TrafficDrivingSignMapper trafficDrivingSignMapper;
|
||||||
|
|
||||||
|
|
||||||
|
/**新增
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
public void save(PageData pd)throws Exception{
|
||||||
|
trafficDrivingSignMapper.save(pd);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void save(PageData pd, MultipartFile[] files) throws Exception {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
/**修改
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
public void edit(PageData pd)throws Exception{
|
||||||
|
trafficDrivingSignMapper.edit(pd);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<PageData> listByID(PageData pd) throws Exception{
|
||||||
|
return trafficDrivingSignMapper.listByID(pd);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<PageData> listForDrivingItem(Page page) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除
|
||||||
|
* @param pd
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public void delete(PageData pd) {
|
||||||
|
trafficDrivingSignMapper.delete(pd);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageData findById(PageData pd) {
|
||||||
|
return trafficDrivingSignMapper.findById(pd);
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,58 @@
|
||||||
|
package com.zcloud.service.comprehensive.impl;
|
||||||
|
|
||||||
|
import com.zcloud.entity.Page;
|
||||||
|
import com.zcloud.entity.PageData;
|
||||||
|
import com.zcloud.mapper.datasource.comprehensive.TrafficDrivingTypeMapper;
|
||||||
|
import com.zcloud.service.comprehensive.TrafficDrivingTypeService;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Service
|
||||||
|
public class TrafficDrivingTypeServiceImpl implements TrafficDrivingTypeService {
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private TrafficDrivingTypeMapper trafficDrivingTypeMapper;
|
||||||
|
|
||||||
|
|
||||||
|
/**新增
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
public void save(PageData pd)throws Exception{
|
||||||
|
trafficDrivingTypeMapper.save(pd);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**修改
|
||||||
|
* @param pd
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
public void edit(PageData pd)throws Exception{
|
||||||
|
trafficDrivingTypeMapper.edit(pd);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 列表
|
||||||
|
* @param page
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public List<PageData> listForDrivingType(Page page) {
|
||||||
|
return trafficDrivingTypeMapper.datalistPage(page);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除
|
||||||
|
* @param pd
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public void delete(PageData pd) {
|
||||||
|
trafficDrivingTypeMapper.delete(pd);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageData findById(PageData pd) {
|
||||||
|
return trafficDrivingTypeMapper.findById(pd);
|
||||||
|
}
|
||||||
|
}
|
|
@ -28,4 +28,8 @@ public class TrafficSecurityWaybillRegistrationServiceImpl implements TrafficSec
|
||||||
public PageData forSecurityPerson(PageData pd) {
|
public PageData forSecurityPerson(PageData pd) {
|
||||||
return TrafficSecurityWaybillRegistrationMapper.forSecurityPerson(pd);
|
return TrafficSecurityWaybillRegistrationMapper.forSecurityPerson(pd);
|
||||||
}
|
}
|
||||||
|
@Override
|
||||||
|
public PageData findById(PageData pd) {
|
||||||
|
return TrafficSecurityWaybillRegistrationMapper.findById(pd);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,138 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.zcloud.mapper.datasource.comprehensive.TrafficDrivingCommitmentMapper">
|
||||||
|
<!--表名 -->
|
||||||
|
<sql id="tableName">
|
||||||
|
BUS_TRAFFIC_DRIVING_COMMITMENT
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!--数据字典表名 -->
|
||||||
|
<sql id="dicTableName">
|
||||||
|
SYS_DICTIONARIES
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!-- 字段 -->
|
||||||
|
<sql id="Field">
|
||||||
|
f.DRIVINGCOMMITMENT_ID,
|
||||||
|
f.INQUIRYCONTENT,
|
||||||
|
f.INQUIRYCONCLUSION,
|
||||||
|
f.CORPINFO_ID,
|
||||||
|
f.ISDELETE,
|
||||||
|
f.DELETOR,
|
||||||
|
f.DELETORNAME,
|
||||||
|
f.DELETETIME,
|
||||||
|
f.CREATOR,
|
||||||
|
f.CREATORNAME,
|
||||||
|
f.CREATTIME,
|
||||||
|
f.OPERATOR,
|
||||||
|
f.OPERATORNAME,
|
||||||
|
f.OPERATTIME
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!-- 字段用于新增 -->
|
||||||
|
<sql id="Field2">
|
||||||
|
DRIVINGCOMMITMENT_ID,
|
||||||
|
INQUIRYCONTENT,
|
||||||
|
INQUIRYCONCLUSION,
|
||||||
|
CORPINFO_ID,
|
||||||
|
ISDELETE,
|
||||||
|
DELETOR,
|
||||||
|
DELETORNAME,
|
||||||
|
DELETETIME,
|
||||||
|
CREATOR,
|
||||||
|
CREATORNAME,
|
||||||
|
CREATTIME,
|
||||||
|
OPERATOR,
|
||||||
|
OPERATORNAME,
|
||||||
|
OPERATTIME
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!-- 字段值 -->
|
||||||
|
<sql id="FieldValue">
|
||||||
|
#{DRIVINGCOMMITMENT_ID},
|
||||||
|
#{INQUIRYCONTENT},
|
||||||
|
#{INQUIRYCONCLUSION},
|
||||||
|
#{CORPINFO_ID},
|
||||||
|
#{ISDELETE},
|
||||||
|
#{DELETOR},
|
||||||
|
#{DELETORNAME},
|
||||||
|
#{DELETETIME},
|
||||||
|
#{CREATOR},
|
||||||
|
#{CREATORNAME},
|
||||||
|
#{CREATTIME},
|
||||||
|
#{OPERATOR},
|
||||||
|
#{OPERATORNAME},
|
||||||
|
#{OPERATTIME}
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!-- 新增-->
|
||||||
|
<insert id="save" parameterType="pd">
|
||||||
|
insert into
|
||||||
|
<include refid="tableName"></include>
|
||||||
|
(
|
||||||
|
<include refid="Field2"></include>
|
||||||
|
) values (
|
||||||
|
<include refid="FieldValue"></include>
|
||||||
|
)
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="edit" parameterType="pd">
|
||||||
|
update
|
||||||
|
<include refid="tableName"></include>
|
||||||
|
set
|
||||||
|
INQUIRYCONTENT = #{INQUIRYCONTENT},
|
||||||
|
INQUIRYCONCLUSION = #{INQUIRYCONCLUSION},
|
||||||
|
OPERATORNAME = #{OPERATORNAME},
|
||||||
|
OPERATOR = #{OPERATOR},
|
||||||
|
OPERATTIME = #{OPERATTIME}
|
||||||
|
where
|
||||||
|
DRIVINGCOMMITMENT_ID = #{DRIVINGCOMMITMENT_ID}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<!--列表-->
|
||||||
|
<select id="datalistPage" parameterType="page" resultType="pd">
|
||||||
|
select
|
||||||
|
<include refid="Field"></include>,
|
||||||
|
b.CORP_NAME
|
||||||
|
from
|
||||||
|
<include refid="tableName"></include> f
|
||||||
|
left join bus_corp_info b on b.CORPINFO_ID = f.CORPINFO_ID
|
||||||
|
where f.ISDELETE = '0'
|
||||||
|
<if test="pd.INQUIRYCONTENT != null and pd.INQUIRYCONTENT != ''"><!-- 关键词检索 -->
|
||||||
|
and f.INQUIRYCONTENT LIKE CONCAT(CONCAT('%', #{pd.INQUIRYCONTENT}),'%')
|
||||||
|
</if>
|
||||||
|
order by f.OPERATTIME DESC
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="getDrivingCommitment" parameterType="page" resultType="pd">
|
||||||
|
select
|
||||||
|
<include refid="Field"></include>,
|
||||||
|
b.CORP_NAME
|
||||||
|
from
|
||||||
|
<include refid="tableName"></include> f
|
||||||
|
left join bus_corp_info b on b.CORPINFO_ID = f.CORPINFO_ID
|
||||||
|
where f.ISDELETE = '0'
|
||||||
|
order by f.OPERATTIME DESC
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="findById" resultType="com.zcloud.entity.PageData" parameterType="pd">
|
||||||
|
select
|
||||||
|
<include refid="Field"></include>
|
||||||
|
from
|
||||||
|
<include refid="tableName"></include> f
|
||||||
|
where
|
||||||
|
f.DRIVINGCOMMITMENT_ID = #{DRIVINGCOMMITMENT_ID}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<!-- 删除-->
|
||||||
|
<delete id="delete" parameterType="pd">
|
||||||
|
update
|
||||||
|
<include refid="tableName"></include>
|
||||||
|
set
|
||||||
|
ISDELETE = '1',
|
||||||
|
DELETOR = #{DELETOR},
|
||||||
|
DELETETIME = #{DELETETIME}
|
||||||
|
where
|
||||||
|
DRIVINGCOMMITMENT_ID = #{DRIVINGCOMMITMENT_ID}
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
|
@ -0,0 +1,143 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.zcloud.mapper.datasource.comprehensive.TrafficDrivingItemMapper">
|
||||||
|
<!--表名 -->
|
||||||
|
<sql id="tableName">
|
||||||
|
BUS_TRAFFIC_DRIVING_ITEM
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!--数据字典表名 -->
|
||||||
|
<sql id="dicTableName">
|
||||||
|
SYS_DICTIONARIES
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!-- 字段 -->
|
||||||
|
<sql id="Field">
|
||||||
|
f.DRIVING_ITEM_ID,
|
||||||
|
f.DRIVINGTYPE_ID,
|
||||||
|
f.DRIVING_SIGN_ID,
|
||||||
|
f.STATUS,
|
||||||
|
f.REMARK,
|
||||||
|
f.ISDELETE,
|
||||||
|
f.DELETOR,
|
||||||
|
f.DELETORNAME,
|
||||||
|
f.DELETETIME,
|
||||||
|
f.CREATOR,
|
||||||
|
f.CREATORNAME,
|
||||||
|
f.CREATTIME,
|
||||||
|
f.OPERATOR,
|
||||||
|
f.OPERATORNAME,
|
||||||
|
f.OPERATTIME
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!-- 字段用于新增 -->
|
||||||
|
<sql id="Field2">
|
||||||
|
DRIVING_ITEM_ID,
|
||||||
|
DRIVINGTYPE_ID,
|
||||||
|
DRIVING_SIGN_ID,
|
||||||
|
STATUS,
|
||||||
|
REMARK,
|
||||||
|
ISDELETE,
|
||||||
|
DELETOR,
|
||||||
|
DELETORNAME,
|
||||||
|
DELETETIME,
|
||||||
|
CREATOR,
|
||||||
|
CREATORNAME,
|
||||||
|
CREATTIME,
|
||||||
|
OPERATOR,
|
||||||
|
OPERATORNAME,
|
||||||
|
OPERATTIME
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!-- 字段值 -->
|
||||||
|
<sql id="FieldValue">
|
||||||
|
#{DRIVING_ITEM_ID},
|
||||||
|
#{DRIVINGTYPE_ID},
|
||||||
|
#{DRIVING_SIGN_ID},
|
||||||
|
#{STATUS},
|
||||||
|
#{REMARK},
|
||||||
|
#{ISDELETE},
|
||||||
|
#{DELETOR},
|
||||||
|
#{DELETORNAME},
|
||||||
|
#{DELETETIME},
|
||||||
|
#{CREATOR},
|
||||||
|
#{CREATORNAME},
|
||||||
|
#{CREATTIME},
|
||||||
|
#{OPERATOR},
|
||||||
|
#{OPERATORNAME},
|
||||||
|
#{OPERATTIME}
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!-- 新增-->
|
||||||
|
<insert id="save" parameterType="pd">
|
||||||
|
insert into
|
||||||
|
<include refid="tableName"></include>
|
||||||
|
(
|
||||||
|
<include refid="Field2"></include>
|
||||||
|
) values (
|
||||||
|
<include refid="FieldValue"></include>
|
||||||
|
)
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="edit" parameterType="pd">
|
||||||
|
update
|
||||||
|
<include refid="tableName"></include>
|
||||||
|
set
|
||||||
|
DRIVING_ITEM_ID = #{DRIVING_ITEM_ID},
|
||||||
|
DRIVINGTYPE_ID = #{DRIVINGTYPE_ID},
|
||||||
|
DRIVING_SIGN_ID = #{DRIVING_SIGN_ID},
|
||||||
|
STATUS = #{STATUS},
|
||||||
|
REMARK = #{REMARK},
|
||||||
|
OPERATORNAME = #{OPERATORNAME},
|
||||||
|
OPERATOR = #{OPERATOR},
|
||||||
|
OPERATTIME = #{OPERATTIME}
|
||||||
|
where
|
||||||
|
DRIVING_ITEM_ID = #{DRIVING_ITEM_ID}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<select id="listAllType" parameterType="pd" resultType="pd">
|
||||||
|
select
|
||||||
|
f.*,
|
||||||
|
r.NAME as CHECKTYPE_NAME
|
||||||
|
from
|
||||||
|
BUS_TRAFFIC_DRIVING_TYPE f
|
||||||
|
left join sys_dictionaries r on r.BIANMA=f.CHECKTYPE_ID
|
||||||
|
where
|
||||||
|
f.ISDELETE = '0'
|
||||||
|
group by f.CHECKTYPE_ID
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<!--列表-->
|
||||||
|
<select id="datalistPage" parameterType="page" resultType="pd">
|
||||||
|
select
|
||||||
|
<include refid="Field"></include>,
|
||||||
|
b.CORP_NAME
|
||||||
|
from
|
||||||
|
<include refid="tableName"></include> f
|
||||||
|
left join bus_corp_info b on b.CORPINFO_ID = f.CORPINFO_ID
|
||||||
|
where f.ISDELETE = '0'
|
||||||
|
order by f.OPERATTIME DESC
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="findById" resultType="com.zcloud.entity.PageData" parameterType="pd">
|
||||||
|
select
|
||||||
|
<include refid="Field"></include>
|
||||||
|
from
|
||||||
|
<include refid="tableName"></include> f
|
||||||
|
where
|
||||||
|
f.DRIVINGTYPE_ID = #{DRIVINGTYPE_ID}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<!-- 删除-->
|
||||||
|
<delete id="delete" parameterType="pd">
|
||||||
|
update
|
||||||
|
<include refid="tableName"></include>
|
||||||
|
set
|
||||||
|
ISDELETE = '1',
|
||||||
|
DELETOR = #{DELETOR},
|
||||||
|
DELETORNAME = #{DELETORNAME},
|
||||||
|
DELETETIME = #{DELETETIME}
|
||||||
|
where
|
||||||
|
DRIVING_ITEM_ID = #{DRIVING_ITEM_ID}
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
|
@ -0,0 +1,165 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.zcloud.mapper.datasource.comprehensive.TrafficDrivingSignMapper">
|
||||||
|
<!--表名 -->
|
||||||
|
<sql id="tableName">
|
||||||
|
BUS_TRAFFIC_DRIVING_SIGN
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!--数据字典表名 -->
|
||||||
|
<sql id="dicTableName">
|
||||||
|
SYS_DICTIONARIES
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!-- 字段 -->
|
||||||
|
<sql id="Field">
|
||||||
|
f.DRIVING_SIGN_ID,
|
||||||
|
f.IMG_PATH,
|
||||||
|
f.CORPINFO_ID,
|
||||||
|
f.SIGN_TIME,
|
||||||
|
f.SIGN_PATH,
|
||||||
|
f.ISDELETE,
|
||||||
|
f.DELETOR,
|
||||||
|
f.DELETORNAME,
|
||||||
|
f.DELETETIME,
|
||||||
|
f.CREATOR,
|
||||||
|
f.CREATORNAME,
|
||||||
|
f.CREATTIME,
|
||||||
|
f.OPERATOR,
|
||||||
|
f.OPERATORNAME,
|
||||||
|
f.OPERATTIME,
|
||||||
|
f.PRACTITIONER,
|
||||||
|
f.WAYBILLREGISTRATION_ID,
|
||||||
|
f.CHECKTYPE_ID
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!-- 字段用于新增 -->
|
||||||
|
<sql id="Field2">
|
||||||
|
DRIVING_SIGN_ID,
|
||||||
|
IMG_PATH,
|
||||||
|
CORPINFO_ID,
|
||||||
|
SIGN_TIME,
|
||||||
|
SIGN_PATH,
|
||||||
|
ISDELETE,
|
||||||
|
DELETOR,
|
||||||
|
DELETORNAME,
|
||||||
|
DELETETIME,
|
||||||
|
CREATOR,
|
||||||
|
CREATORNAME,
|
||||||
|
CREATTIME,
|
||||||
|
OPERATOR,
|
||||||
|
OPERATORNAME,
|
||||||
|
OPERATTIME,
|
||||||
|
PRACTITIONER,
|
||||||
|
WAYBILLREGISTRATION_ID,
|
||||||
|
CHECKTYPE_ID
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!-- 字段值 -->
|
||||||
|
<sql id="FieldValue">
|
||||||
|
#{DRIVING_SIGN_ID},
|
||||||
|
#{IMG_PATH},
|
||||||
|
#{CORPINFO_ID},
|
||||||
|
#{SIGN_TIME},
|
||||||
|
#{SIGN_PATH},
|
||||||
|
#{ISDELETE},
|
||||||
|
#{DELETOR},
|
||||||
|
#{DELETORNAME},
|
||||||
|
#{DELETETIME},
|
||||||
|
#{CREATOR},
|
||||||
|
#{CREATORNAME},
|
||||||
|
#{CREATTIME},
|
||||||
|
#{OPERATOR},
|
||||||
|
#{OPERATORNAME},
|
||||||
|
#{OPERATTIME},
|
||||||
|
#{PRACTITIONER},
|
||||||
|
#{WAYBILLREGISTRATION_ID},
|
||||||
|
#{CHECKTYPE_ID}
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!-- 新增-->
|
||||||
|
<insert id="save" parameterType="pd">
|
||||||
|
insert into
|
||||||
|
<include refid="tableName"></include>
|
||||||
|
(
|
||||||
|
<include refid="Field2"></include>
|
||||||
|
) values (
|
||||||
|
<include refid="FieldValue"></include>
|
||||||
|
)
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="edit" parameterType="pd">
|
||||||
|
update
|
||||||
|
<include refid="tableName"></include>
|
||||||
|
set
|
||||||
|
DRIVING_SIGN_ID = #{DRIVING_SIGN_ID},
|
||||||
|
PRACTITIONER = #{PRACTITIONER},
|
||||||
|
IMG_PATH = #{IMG_PATH},
|
||||||
|
CORPINFO_ID = #{CORPINFO_ID},
|
||||||
|
SIGN_TIME = #{SIGN_TIME},
|
||||||
|
SIGN_PATH = #{SIGN_PATH},
|
||||||
|
OPERATORNAME = #{OPERATORNAME},
|
||||||
|
OPERATOR = #{OPERATOR},
|
||||||
|
OPERATTIME = #{OPERATTIME},
|
||||||
|
WAYBILLREGISTRATION_ID = #{WAYBILLREGISTRATION_ID},
|
||||||
|
CHECKTYPE_ID = #{CHECKTYPE_ID}
|
||||||
|
where
|
||||||
|
DRIVING_SIGN_ID = #{DRIVING_SIGN_ID}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<select id="listAllType" parameterType="pd" resultType="pd">
|
||||||
|
select
|
||||||
|
f.*,
|
||||||
|
r.NAME as CHECKTYPE_NAME
|
||||||
|
from
|
||||||
|
BUS_TRAFFIC_DRIVING_TYPE f
|
||||||
|
left join sys_dictionaries r on r.BIANMA=f.CHECKTYPE_ID
|
||||||
|
where
|
||||||
|
f.ISDELETE = '0'
|
||||||
|
group by f.CHECKTYPE_ID
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="listByID" parameterType="pd" resultType="pd">
|
||||||
|
select
|
||||||
|
f.*
|
||||||
|
from
|
||||||
|
BUS_TRAFFIC_DRIVING_SIGN f
|
||||||
|
where
|
||||||
|
f.ISDELETE = '0' and f.WAYBILLREGISTRATION_ID = #{WAYBILLREGISTRATION_ID}
|
||||||
|
group by f.CHECKTYPE_ID
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<!--列表-->
|
||||||
|
<select id="datalistPage" parameterType="page" resultType="pd">
|
||||||
|
select
|
||||||
|
<include refid="Field"></include>,
|
||||||
|
b.CORP_NAME
|
||||||
|
from
|
||||||
|
<include refid="tableName"></include> f
|
||||||
|
left join bus_corp_info b on b.CORPINFO_ID = f.CORPINFO_ID
|
||||||
|
where f.ISDELETE = '0'
|
||||||
|
order by f.OPERATTIME DESC
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="findById" resultType="com.zcloud.entity.PageData" parameterType="pd">
|
||||||
|
select
|
||||||
|
<include refid="Field"></include>
|
||||||
|
from
|
||||||
|
<include refid="tableName"></include> f
|
||||||
|
where
|
||||||
|
f.WAYBILLREGISTRATION_ID = #{WAYBILLREGISTRATION_ID} and f.PRACTITIONER = #{USER_ID}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<!-- 删除-->
|
||||||
|
<delete id="delete" parameterType="pd">
|
||||||
|
update
|
||||||
|
<include refid="tableName"></include>
|
||||||
|
set
|
||||||
|
ISDELETE = '1',
|
||||||
|
DELETOR = #{DELETOR},
|
||||||
|
DELETORNAME = #{DELETORNAME},
|
||||||
|
DELETETIME = #{DELETETIME}
|
||||||
|
where
|
||||||
|
DRIVING_SIGN_ID = #{DRIVING_SIGN_ID}
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
|
@ -0,0 +1,136 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.zcloud.mapper.datasource.comprehensive.TrafficDrivingTypeMapper">
|
||||||
|
<!--表名 -->
|
||||||
|
<sql id="tableName">
|
||||||
|
BUS_TRAFFIC_DRIVING_TYPE
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!--数据字典表名 -->
|
||||||
|
<sql id="dicTableName">
|
||||||
|
SYS_DICTIONARIES
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!-- 字段 -->
|
||||||
|
<sql id="Field">
|
||||||
|
f.DRIVINGTYPE_ID,
|
||||||
|
f.CHECKTYPE_ID,
|
||||||
|
f.CHECKITEMNAME,
|
||||||
|
f.REMARKS,
|
||||||
|
f.CORPINFO_ID,
|
||||||
|
f.ISDELETE,
|
||||||
|
f.DELETOR,
|
||||||
|
f.DELETORNAME,
|
||||||
|
f.DELETETIME,
|
||||||
|
f.CREATOR,
|
||||||
|
f.CREATORNAME,
|
||||||
|
f.CREATTIME,
|
||||||
|
f.OPERATOR,
|
||||||
|
f.OPERATORNAME,
|
||||||
|
f.OPERATTIME
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!-- 字段用于新增 -->
|
||||||
|
<sql id="Field2">
|
||||||
|
DRIVINGTYPE_ID,
|
||||||
|
CHECKTYPE_ID,
|
||||||
|
CHECKITEMNAME,
|
||||||
|
REMARKS,
|
||||||
|
CORPINFO_ID,
|
||||||
|
ISDELETE,
|
||||||
|
DELETOR,
|
||||||
|
DELETORNAME,
|
||||||
|
DELETETIME,
|
||||||
|
CREATOR,
|
||||||
|
CREATORNAME,
|
||||||
|
CREATTIME,
|
||||||
|
OPERATOR,
|
||||||
|
OPERATORNAME,
|
||||||
|
OPERATTIME
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!-- 字段值 -->
|
||||||
|
<sql id="FieldValue">
|
||||||
|
#{DRIVINGTYPE_ID},
|
||||||
|
#{CHECKTYPE_ID},
|
||||||
|
#{CHECKITEMNAME},
|
||||||
|
#{REMARKS},
|
||||||
|
#{CORPINFO_ID},
|
||||||
|
#{ISDELETE},
|
||||||
|
#{DELETOR},
|
||||||
|
#{DELETORNAME},
|
||||||
|
#{DELETETIME},
|
||||||
|
#{CREATOR},
|
||||||
|
#{CREATORNAME},
|
||||||
|
#{CREATTIME},
|
||||||
|
#{OPERATOR},
|
||||||
|
#{OPERATORNAME},
|
||||||
|
#{OPERATTIME}
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!-- 新增-->
|
||||||
|
<insert id="save" parameterType="pd">
|
||||||
|
insert into
|
||||||
|
<include refid="tableName"></include>
|
||||||
|
(
|
||||||
|
<include refid="Field2"></include>
|
||||||
|
) values (
|
||||||
|
<include refid="FieldValue"></include>
|
||||||
|
)
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="edit" parameterType="pd">
|
||||||
|
update
|
||||||
|
<include refid="tableName"></include>
|
||||||
|
set
|
||||||
|
DRIVINGTYPE_ID = #{DRIVINGTYPE_ID},
|
||||||
|
CHECKTYPE_ID = #{CHECKTYPE_ID},
|
||||||
|
CHECKITEMNAME = #{CHECKITEMNAME},
|
||||||
|
REMARKS = #{REMARKS},
|
||||||
|
CORPINFO_ID = #{CORPINFO_ID},
|
||||||
|
OPERATORNAME = #{OPERATORNAME},
|
||||||
|
OPERATOR = #{OPERATOR},
|
||||||
|
OPERATTIME = #{OPERATTIME}
|
||||||
|
where
|
||||||
|
DRIVINGTYPE_ID = #{DRIVINGTYPE_ID}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<!--列表-->
|
||||||
|
<select id="datalistPage" parameterType="page" resultType="pd">
|
||||||
|
select
|
||||||
|
<include refid="Field"></include>,
|
||||||
|
b.CORP_NAME,
|
||||||
|
d.NAME as CHECKTYPE_NAME
|
||||||
|
from
|
||||||
|
<include refid="tableName"></include> f
|
||||||
|
left join bus_corp_info b on b.CORPINFO_ID = f.CORPINFO_ID
|
||||||
|
left join sys_dictionaries d on d.BIANMA = f.CHECKTYPE_ID
|
||||||
|
where f.ISDELETE = '0'
|
||||||
|
<if test="pd.CHECKTYPE_ID != null and pd.CHECKTYPE_ID != ''"><!-- 关键词检索 -->
|
||||||
|
and f.CHECKTYPE_ID = #{pd.CHECKTYPE_ID}
|
||||||
|
</if>
|
||||||
|
order by f.OPERATTIME DESC
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="findById" resultType="com.zcloud.entity.PageData" parameterType="pd">
|
||||||
|
select
|
||||||
|
<include refid="Field"></include>
|
||||||
|
from
|
||||||
|
<include refid="tableName"></include> f
|
||||||
|
where
|
||||||
|
f.DRIVINGTYPE_ID = #{DRIVINGTYPE_ID}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<!-- 删除-->
|
||||||
|
<delete id="delete" parameterType="pd">
|
||||||
|
update
|
||||||
|
<include refid="tableName"></include>
|
||||||
|
set
|
||||||
|
ISDELETE = '1',
|
||||||
|
DELETOR = #{DELETOR},
|
||||||
|
DELETORNAME = #{DELETORNAME},
|
||||||
|
DELETETIME = #{DELETETIME}
|
||||||
|
where
|
||||||
|
DRIVINGTYPE_ID = #{DRIVINGTYPE_ID}
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
|
@ -132,14 +132,26 @@
|
||||||
)
|
)
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
|
<update id="editStatus" parameterType="pd">
|
||||||
|
update
|
||||||
|
<include refid="tableName"></include>
|
||||||
|
set
|
||||||
|
WAYBILLSTATUS = #{WAYBILLSTATUS}
|
||||||
|
where
|
||||||
|
WAYBILLREGISTRATION_ID = #{WAYBILLREGISTRATION_ID}
|
||||||
|
</update>
|
||||||
<!--列表-->
|
<!--列表-->
|
||||||
<select id="datalistPage" parameterType="page" resultType="pd">
|
<select id="datalistPage" parameterType="page" resultType="pd">
|
||||||
select
|
select
|
||||||
f.*,
|
f.*,
|
||||||
|
o.LOCATIONNAME as ORIGIN_NAME,
|
||||||
|
d.LOCATIONNAME as DESTINATION_NAME,
|
||||||
i.CORP_NAME
|
i.CORP_NAME
|
||||||
from
|
from
|
||||||
<include refid="tableName"></include> f
|
<include refid="tableName"></include> f
|
||||||
left join bus_corp_info i on f.TRANSPORTATIONCOMPANY = i.CORPINFO_ID
|
left join bus_corp_info i on f.TRANSPORTATIONCOMPANY = i.CORPINFO_ID
|
||||||
|
left join bus_traffic_location_management o on o.LOCATIONMANAGEMENT_ID = f.ORIGIN
|
||||||
|
left join bus_traffic_location_management d on d.LOCATIONMANAGEMENT_ID = f.DESTINATION
|
||||||
where f.ISDELETE = '0'
|
where f.ISDELETE = '0'
|
||||||
<if test="pd.WAYBILLSTATUS != null and pd.WAYBILLSTATUS != ''"><!-- 关键词检索-运单状态 -->
|
<if test="pd.WAYBILLSTATUS != null and pd.WAYBILLSTATUS != ''"><!-- 关键词检索-运单状态 -->
|
||||||
and f.WAYBILLSTATUS = #{pd.WAYBILLSTATUS}
|
and f.WAYBILLSTATUS = #{pd.WAYBILLSTATUS}
|
||||||
|
@ -147,6 +159,17 @@
|
||||||
<if test="pd.TRANSPORTVEHICLE != null and pd.TRANSPORTVEHICLE != ''"><!-- 关键词检索-车辆车牌 -->
|
<if test="pd.TRANSPORTVEHICLE != null and pd.TRANSPORTVEHICLE != ''"><!-- 关键词检索-车辆车牌 -->
|
||||||
and f.TRANSPORTVEHICLE = #{pd.TRANSPORTVEHICLE}
|
and f.TRANSPORTVEHICLE = #{pd.TRANSPORTVEHICLE}
|
||||||
</if>
|
</if>
|
||||||
|
<if test="pd.USER_ID != null and pd.USER_ID != ''"><!-- 关键词检索-从业人员 -->
|
||||||
|
and f.PRACTITIONER = #{pd.USER_ID}
|
||||||
|
</if>
|
||||||
|
<if test="pd.KEYWORDS != null and pd.KEYWORDS != ''"><!-- 关键词检索 -->
|
||||||
|
and
|
||||||
|
(
|
||||||
|
f.WAYBILLNUMBER LIKE CONCAT(CONCAT('%', #{pd.KEYWORDS}),'%')
|
||||||
|
or
|
||||||
|
f.TRANSPORTVEHICLE LIKE CONCAT(CONCAT('%', #{pd.KEYWORDS}),'%')
|
||||||
|
)
|
||||||
|
</if>
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="forSecurityPerson" resultType="com.zcloud.entity.PageData"
|
<select id="forSecurityPerson" resultType="com.zcloud.entity.PageData"
|
||||||
|
@ -158,4 +181,13 @@
|
||||||
where i.CORPINFO_ID = #{TRANSPORTATIONCOMPANY}
|
where i.CORPINFO_ID = #{TRANSPORTATIONCOMPANY}
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
<select id="findById" resultType="com.zcloud.entity.PageData" parameterType="pd">
|
||||||
|
select
|
||||||
|
<include refid="Field"></include>
|
||||||
|
from
|
||||||
|
<include refid="tableName"></include> f
|
||||||
|
where
|
||||||
|
f.WAYBILLREGISTRATION_ID = #{WAYBILLREGISTRATION_ID}
|
||||||
|
</select>
|
||||||
|
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|
Loading…
Reference in New Issue