营运车辆修改同步行车三检

dev
xiepeng 2024-05-13 18:00:59 +08:00
parent d2932af28d
commit 3ddaa3b2c5
10 changed files with 79 additions and 2 deletions

View File

@ -234,6 +234,8 @@ public class BeidouController extends BaseController {
data.put("ARCHIVES_TYPE", "1");
} else if ("1".equals(data.getString("OPEAR_ISASSIGNED")) || "1".equals(data.getString("FREIGHT_ISASSIGNED"))) {
data.put("ARCHIVES_TYPE", "2");
}else {
data.put("ARCHIVES_TYPE", "0");
}
return false;
});

View File

@ -55,6 +55,10 @@ public class AppTrafficSecurityWaybillRegistrationController extends BaseControl
if(Tools.notEmpty(KEYWORDS))pd.put("KEYWORDS", KEYWORDS.trim());
page.setPd(pd);
List<PageData> varList = trafficSecurityWaybillRegistrationService.listForSecurityWaybill(page);
varList.stream().forEach(data -> {
data.put("TRANSPORTVEHICLE", data.getString("PLATE_NUMBER"));
});
System.out.println("varList = " + varList);
map.put("varList", varList);
map.put("page", page);

View File

@ -142,6 +142,7 @@ public class TrafficSecurityCustomerManagementController extends BaseController
pd = this.getPageData();
pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID()); //企业ID
List<PageData> varList = customerManagementService.getTrafficCustomerSelectList(pd);
System.out.println("varList = " + varList);
map.put("varList", varList);
map.put("result", errInfo);
return map;

View File

@ -6,6 +6,7 @@ import com.zcloud.controller.base.BaseController;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import com.zcloud.service.comprehensive.*;
import com.zcloud.service.operatingvehicles.OperatingVehiclesService;
import com.zcloud.service.system.UsersService;
import com.zcloud.util.*;
import org.apache.commons.lang.ObjectUtils;
@ -39,6 +40,9 @@ public class TrafficSecurityWaybillRegistrationController extends BaseController
@Autowired
private TrafficDrivingSignService trafficDrivingSignService;
@Autowired
private OperatingVehiclesService operatingVehiclesService;
@Autowired
private UsersService usersService;
@ -53,6 +57,10 @@ public class TrafficSecurityWaybillRegistrationController extends BaseController
pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID()); //企业ID
page.setPd(pd);
List<PageData> varList = trafficSecurityWaybillRegistrationService.listForSecurityWaybill(page);
varList.forEach(data -> {
data.put("TRANSPORTVEHICLE", data.getString("PLATE_NUMBER"));
});
System.out.println("varList = " + varList);
map.put("varList", varList);
map.put("page", page);
map.put("result", errInfo);
@ -199,6 +207,7 @@ public class TrafficSecurityWaybillRegistrationController extends BaseController
pd = trafficSecurityWaybillRegistrationService.findById(pd);//根据ID读
pd.put("ENTRUST_PERSON", pd.getString("CLIENTCONTACTPERSON"));
pd.put("CONFIRM_PERSON", pd.getString("CONFIRMINGPERSON"));
pd.put("TRANSPORTVEHICLE", pd.getString("PLATE_NUMBER"));
List<String> dispatchers = Arrays.stream(pd.getString("DISPATCHER").split(",")).collect(Collectors.toList());
List<PageData> names = new ArrayList<>();
dispatchers.forEach(data -> {
@ -269,7 +278,15 @@ public class TrafficSecurityWaybillRegistrationController extends BaseController
}
}
}
PageData pageData = new PageData();
pageData.put("PLATE_NUMBER", pd.getString("TRANSPORTVEHICLE"));
pageData.put("CORPINFO_ID", pd.getString("CORPINFO_ID"));
PageData vehicle = operatingVehiclesService.findByfindByPlateNumber(pageData);
if(!ObjectUtil.isEmpty(vehicle)) {
pd.put("TRANSPORTVEHICLE", vehicle.getString("OPERATING_ID"));
}
trafficSecurityWaybillRegistrationService.edit(pd);
map.put("result", errInfo);
map.put("pd", pd);
return map;

View File

@ -180,11 +180,14 @@ public class InspectAnnuallyController extends BaseController {
pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID()); //企业ID
page.setPd(pd);
List<PageData> varList = inspectAnnuallyService.list(page); //列出年检列表
System.out.println("varList = " + varList);
varList.stream().anyMatch(data -> {
if ("1".equals(data.getString("OPEAR_ISSCRAP")) || "1".equals(data.getString("FREIGHT_ISSCRAP"))) {
data.put("ARCHIVES_TYPE", "2");
} else if ("1".equals(data.getString("OPEAR_ISASSIGNED")) || "1".equals(data.getString("FREIGHT_ISASSIGNED"))) {
data.put("ARCHIVES_TYPE", "1");
}else{
data.put("ARCHIVES_TYPE", "0");
}
return false;
});

View File

@ -28,7 +28,10 @@ import org.springframework.web.servlet.ModelAndView;
import java.io.File;
import java.util.*;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
import java.util.stream.Collectors;
import java.util.stream.Stream;
@Controller
@RequestMapping("/operatingvehicles")

View File

@ -178,6 +178,8 @@ public class OperationsController extends BaseController {
data.put("ARCHIVES_TYPE", "2");
} else if ("1".equals(data.getString("OPEAR_ISASSIGNED")) || "1".equals(data.getString("FREIGHT_ISASSIGNED"))) {
data.put("ARCHIVES_TYPE", "1");
}else{
data.put("ARCHIVES_TYPE", "0");
}
return false;
});

View File

@ -2,6 +2,7 @@ package com.zcloud.controller.taxationManage;
import cn.hutool.core.util.ObjectUtil;
import com.alibaba.excel.util.DateUtils;
import com.aliyuncs.facebody.model.v20191230.PedestrianDetectAttributeResponse;
import com.zcloud.controller.base.BaseController;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
@ -21,6 +22,8 @@ import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.multipart.MultipartFile;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.*;
import java.util.function.Predicate;
import java.util.stream.Collectors;
@ -168,6 +171,43 @@ public class TaxationManageController extends BaseController {
}
return false;
});
varList.forEach(data -> {
Date dueDate = DateUtil.fomatDate(data.getString("EXPIRE_DATE"));
Date reminderDate = DateUtil.fomatDate(data.getString("REMINDER_DATA"));
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
String toDay = sdf.format(new Date());
Date date = null;
try {
date = sdf.parse(toDay);
} catch (ParseException e) {
throw new RuntimeException(e);
}
// 已到期
if(dueDate.before(date)) {
data.put("EXPIRE_STATUS", "0");
try {
taxationManageService.edit(data);
} catch (Exception e) {
throw new RuntimeException(e);
}
// 即将到期
} else if ((dueDate.after(date) || dueDate.equals(date)) && (reminderDate.before(date) || reminderDate.equals(date))) {
data.put("EXPIRE_STATUS", "2");
try {
taxationManageService.edit(data);
} catch (Exception e) {
throw new RuntimeException(e);
}
// 未到期
}else{
data.put("EXPIRE_STATUS", "1");
try {
taxationManageService.edit(data);
} catch (Exception e) {
throw new RuntimeException(e);
}
}
});
map.put("varList", varList);
map.put("page", page);
map.put("result", errInfo);

View File

@ -77,6 +77,7 @@ public class TrafficDrivingTypeServiceImpl implements TrafficDrivingTypeService
*/
public PageData infoCategory(PageData pd)throws Exception{
PageData cpd = TrafficSecurityWaybillRegistrationMapper.findById(pd); // 根据ID读取
cpd.put("TRANSPORTVEHICLE", cpd.getString("PLATE_NUMBER"));
List<PageData> varOList = trafficDrivingTypeMapper.findListbyDetail(pd);
List<PageData> vList = trafficDrivingTypeMapper.findCategory(pd);

View File

@ -206,7 +206,8 @@
c.CUSTOMERNAME AS CLIENT_NAME,
c2.CUSTOMERNAME AS CONFIRMER_NAME,
t.OPERATTIME AS STARTTIME,
p.OPERATTIME AS STOPTIME
p.OPERATTIME AS STOPTIME,
bto.PLATE_NUMBER
from
<include refid="tableName"></include> f
left join bus_corp_info i on f.CORPINFO_ID = i.CORPINFO_ID
@ -217,6 +218,7 @@
left join bus_traffic_customer_management c2 on f.CONFIRMER = c2.CUSTOMERNAME_ID
left join bus_traffic_driving_sign t on t.WAYBILLREGISTRATION_ID = f.WAYBILLREGISTRATION_ID and t.CHECKTYPE_ID = 'status001'
left join bus_traffic_driving_sign p on p.WAYBILLREGISTRATION_ID = f.WAYBILLREGISTRATION_ID and p.CHECKTYPE_ID = 'status003'
left join bus_traffic_operatingvehicle bto on bto.OPERATING_ID = f.TRANSPORTVEHICLE
where f.ISDELETE = '0' and f.CORPINFO_ID = #{pd.CORPINFO_ID}
<if test="pd.WAYBILLSTATUS != null and pd.WAYBILLSTATUS != ''"><!-- 关键词检索-运单状态 -->
and f.WAYBILLSTATUS = #{pd.WAYBILLSTATUS}
@ -260,7 +262,8 @@
b2.ADMINISTRATIVEREGIONS AS GOAL_ADDR,
oa.NAME AS DEPARTMENTNAME,
btcc.CONTACT AS ENTRUSTPERSON,
btcc2.CONTACT AS CONFIRMPERSON
btcc2.CONTACT AS CONFIRMPERSON,
bto.PLATE_NUMBER
from
<include refid="tableName"></include> f
left join bus_traffic_operatingvehicle e on f.TRANSPORTVEHICLE = e.PLATE_NUMBER
@ -275,6 +278,7 @@
left join bus_traffic_customer_contact btcc on btcc.CONTACT_ID = f.CLIENTCONTACTPERSON
left join bus_traffic_customer_contact btcc2 on btcc2.CONTACT_ID = f.CONFIRMINGPERSON
left join oa_department oa on oa.DEPARTMENT_ID = f.DEPARTMENT_ID
left join bus_traffic_operatingvehicle bto on bto.OPERATING_ID = f.TRANSPORTVEHICLE
where
f.WAYBILLREGISTRATION_ID = #{WAYBILLREGISTRATION_ID}
AND