|
@ -40,8 +40,12 @@ import com.yxt.anrui.scm.api.scmvehiclegression.AppScmVehicleGressionDto; |
|
|
import com.yxt.anrui.scm.api.scmvehicleinventory.AppScmVehicleCarInventoryListPageQuery; |
|
|
import com.yxt.anrui.scm.api.scmvehicleinventory.AppScmVehicleCarInventoryListPageQuery; |
|
|
import com.yxt.anrui.scm.api.scmvehicleinventory.AppScmVehicleCarInventoryListPageVo; |
|
|
import com.yxt.anrui.scm.api.scmvehicleinventory.AppScmVehicleCarInventoryListPageVo; |
|
|
import com.yxt.anrui.scm.api.scmvehicleinventory.ScmVehicleInventory; |
|
|
import com.yxt.anrui.scm.api.scmvehicleinventory.ScmVehicleInventory; |
|
|
|
|
|
import com.yxt.anrui.scm.api.scmvehicleinventory.ScmVehicleInventoryVo; |
|
|
import com.yxt.anrui.scm.api.scmvehinventorymonth.*; |
|
|
import com.yxt.anrui.scm.api.scmvehinventorymonth.*; |
|
|
|
|
|
import com.yxt.anrui.scm.api.scmvehinventoryreport.RecipientListVo; |
|
|
|
|
|
import com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth.AppLiableListVo; |
|
|
import com.yxt.anrui.scm.biz.scmvehicleinventory.ScmVehicleInventoryService; |
|
|
import com.yxt.anrui.scm.biz.scmvehicleinventory.ScmVehicleInventoryService; |
|
|
|
|
|
import com.yxt.anrui.scm.biz.scmvehinventoryreport.ScmVehInventoryreportService; |
|
|
import org.apache.commons.lang3.StringUtils; |
|
|
import org.apache.commons.lang3.StringUtils; |
|
|
import com.yxt.common.base.service.MybatisBaseService; |
|
|
import com.yxt.common.base.service.MybatisBaseService; |
|
|
import com.yxt.common.base.utils.PagerUtil; |
|
|
import com.yxt.common.base.utils.PagerUtil; |
|
@ -58,9 +62,7 @@ import java.text.SimpleDateFormat; |
|
|
import java.time.LocalDateTime; |
|
|
import java.time.LocalDateTime; |
|
|
import java.time.ZoneId; |
|
|
import java.time.ZoneId; |
|
|
import java.time.format.DateTimeFormatter; |
|
|
import java.time.format.DateTimeFormatter; |
|
|
import java.util.Collections; |
|
|
import java.util.*; |
|
|
import java.util.Date; |
|
|
|
|
|
import java.util.List; |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* Project: aaa(aaa) <br/> |
|
|
* Project: aaa(aaa) <br/> |
|
@ -86,6 +88,8 @@ public class ScmVehInventorymonthService extends MybatisBaseService<ScmVehInvent |
|
|
SysUserFeign sysUserFeign; |
|
|
SysUserFeign sysUserFeign; |
|
|
@Autowired |
|
|
@Autowired |
|
|
ScmVehicleInventoryService scmVehicleInventoryService; |
|
|
ScmVehicleInventoryService scmVehicleInventoryService; |
|
|
|
|
|
@Autowired |
|
|
|
|
|
ScmVehInventoryreportService scmVehInventoryreportService; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private QueryWrapper<ScmVehInventorymonth> createQueryWrapper(ScmVehInventorymonthQuery query) { |
|
|
private QueryWrapper<ScmVehInventorymonth> createQueryWrapper(ScmVehInventorymonthQuery query) { |
|
@ -263,7 +267,7 @@ public class ScmVehInventorymonthService extends MybatisBaseService<ScmVehInvent |
|
|
record.setDamageNumber(String.valueOf(vo.getDamageNumber())); |
|
|
record.setDamageNumber(String.valueOf(vo.getDamageNumber())); |
|
|
record.setProfitNumber(String.valueOf(vo.getProfitNumber())); |
|
|
record.setProfitNumber(String.valueOf(vo.getProfitNumber())); |
|
|
record.setActualNumber(String.valueOf(vo.getProfitNumber() + vo.getNormalNumber() + vo.getDamageNumber() + vo.getLossNumber())); |
|
|
record.setActualNumber(String.valueOf(vo.getProfitNumber() + vo.getNormalNumber() + vo.getDamageNumber() + vo.getLossNumber())); |
|
|
if (record.getState().equals(0)) { |
|
|
if (record.getState() == 0) { |
|
|
if (vo.getSurplusNumber() == 0) { |
|
|
if (vo.getSurplusNumber() == 0) { |
|
|
record.setShowBtn(true); |
|
|
record.setShowBtn(true); |
|
|
} else { |
|
|
} else { |
|
@ -280,6 +284,21 @@ public class ScmVehInventorymonthService extends MybatisBaseService<ScmVehInvent |
|
|
ResultBean<AppScmVehInventorymonthInfoVo> rb = ResultBean.fireFail(); |
|
|
ResultBean<AppScmVehInventorymonthInfoVo> rb = ResultBean.fireFail(); |
|
|
AppScmVehInventorymonthInfoVo vo = new AppScmVehInventorymonthInfoVo(); |
|
|
AppScmVehInventorymonthInfoVo vo = new AppScmVehInventorymonthInfoVo(); |
|
|
AppScmVehInventorymonthInfoVo appScmVehInventorymonthInfoVo = baseMapper.selByMainSid(sid); |
|
|
AppScmVehInventorymonthInfoVo appScmVehInventorymonthInfoVo = baseMapper.selByMainSid(sid); |
|
|
|
|
|
List<RecipientListVo> recipientListVos = scmVehInventoryreportService.selectByMainSid(); |
|
|
|
|
|
if (recipientListVos.size() > 0) { |
|
|
|
|
|
if (StringUtils.isNotBlank(recipientListVos.get(0).getName())) { |
|
|
|
|
|
List<RecipientListVo> list = new ArrayList<>(); |
|
|
|
|
|
List<String> splitName = Arrays.asList(recipientListVos.get(0).getName().split(",")); |
|
|
|
|
|
List<String> splitSid = Arrays.asList(recipientListVos.get(0).getSid().split(",")); |
|
|
|
|
|
for (int i = 0; i < splitName.size(); i++) { |
|
|
|
|
|
RecipientListVo v = new RecipientListVo(); |
|
|
|
|
|
v.setName(splitName.get(i)); |
|
|
|
|
|
v.setSid(splitSid.get(i)); |
|
|
|
|
|
list.add(v); |
|
|
|
|
|
} |
|
|
|
|
|
vo.setRecipientList(list); |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
if (appScmVehInventorymonthInfoVo != null) { |
|
|
if (appScmVehInventorymonthInfoVo != null) { |
|
|
vo.setRecipient(appScmVehInventorymonthInfoVo.getRecipient()); |
|
|
vo.setRecipient(appScmVehInventorymonthInfoVo.getRecipient()); |
|
|
vo.setDate(appScmVehInventorymonthInfoVo.getDate()); |
|
|
vo.setDate(appScmVehInventorymonthInfoVo.getDate()); |
|
|