出门证优化
This commit is contained in:
parent
99d867ea4e
commit
7902b21197
|
|
@ -597,6 +597,17 @@ public class BackApplyInfoController extends BaseController {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ApiOperation(value = "出门证领料单号下拉")
|
||||||
|
@GetMapping("/getCodeList")
|
||||||
|
public AjaxResult getCodeList(ExitPermit bean) {
|
||||||
|
try {
|
||||||
|
return AjaxResult.success(backApplyInfoService.getCodeList(bean));
|
||||||
|
} catch (Exception e) {
|
||||||
|
return AjaxResult.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 新增出门证
|
* 新增出门证
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -37,6 +37,9 @@ public class ExitPermit implements Serializable {
|
||||||
@ApiModelProperty(value = "日期")
|
@ApiModelProperty(value = "日期")
|
||||||
private String addDate;
|
private String addDate;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "领料单号")
|
||||||
|
private String code;
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 创建人
|
* 创建人
|
||||||
|
|
@ -67,4 +70,9 @@ public class ExitPermit implements Serializable {
|
||||||
|
|
||||||
private String endTime;
|
private String endTime;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 单号来源
|
||||||
|
*/
|
||||||
|
private String source;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -517,4 +517,11 @@ public interface BackApplyInfoMapper {
|
||||||
BackApplyDetails selectCheckREDetails(BackApplyDetails details);
|
BackApplyDetails selectCheckREDetails(BackApplyDetails details);
|
||||||
|
|
||||||
BackApplyDetails selectIsFinishByMaId(Long maId);
|
BackApplyDetails selectIsFinishByMaId(Long maId);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 出门证领料单号下拉
|
||||||
|
* @param bean
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
List<ExitPermit> getCodeList(ExitPermit bean);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -251,5 +251,12 @@ public interface IBackApplyInfoService {
|
||||||
int syncProjectDetails(BackApplyInfo backApplyInfo);
|
int syncProjectDetails(BackApplyInfo backApplyInfo);
|
||||||
|
|
||||||
AjaxResult selectBackApplyInfoByIdClz(Long id, String keyWord);
|
AjaxResult selectBackApplyInfoByIdClz(Long id, String keyWord);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 出门证领料单号下拉
|
||||||
|
* @param bean
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
List<ExitPermit> getCodeList(ExitPermit bean);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -404,6 +404,16 @@ public class BackApplyInfoServiceImpl implements IBackApplyInfoService {
|
||||||
return ajaxResult;
|
return ajaxResult;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 出门证领料单号下拉
|
||||||
|
* @param bean
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public List<ExitPermit> getCodeList(ExitPermit bean) {
|
||||||
|
return backApplyInfoMapper.getCodeList(bean);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 检查是否有编码设备
|
* 检查是否有编码设备
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -60,6 +60,7 @@ public class BmReportController extends BaseController {
|
||||||
reportInfo.setPurchasePrice(info.getPurchasePrice());
|
reportInfo.setPurchasePrice(info.getPurchasePrice());
|
||||||
reportInfo.setPurchasePriceNoTax(info.getPurchasePriceNoTax());
|
reportInfo.setPurchasePriceNoTax(info.getPurchasePriceNoTax());
|
||||||
reportInfo.setPendingInputNum(info.getPendingInputNum());
|
reportInfo.setPendingInputNum(info.getPendingInputNum());
|
||||||
|
reportInfo.setNotPassNum(info.getNotPassNum());
|
||||||
}
|
}
|
||||||
return AjaxResult.success(reportInfo);
|
return AjaxResult.success(reportInfo);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -46,6 +46,10 @@ public class PurChaseReportInfo {
|
||||||
@Excel(name = "验收合格数量", cellType = Excel.ColumnType.NUMERIC, align = HorizontalAlignment.RIGHT)
|
@Excel(name = "验收合格数量", cellType = Excel.ColumnType.NUMERIC, align = HorizontalAlignment.RIGHT)
|
||||||
private BigDecimal passNum;
|
private BigDecimal passNum;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "未验收数量")
|
||||||
|
@Excel(name = "未验收数量", cellType = Excel.ColumnType.NUMERIC, align = HorizontalAlignment.RIGHT)
|
||||||
|
private BigDecimal notPassNum;
|
||||||
|
|
||||||
@ApiModelProperty(value = "入库数量")
|
@ApiModelProperty(value = "入库数量")
|
||||||
@Excel(name = "入库数量", cellType = Excel.ColumnType.NUMERIC, align = HorizontalAlignment.RIGHT)
|
@Excel(name = "入库数量", cellType = Excel.ColumnType.NUMERIC, align = HorizontalAlignment.RIGHT)
|
||||||
private BigDecimal inputNum;
|
private BigDecimal inputNum;
|
||||||
|
|
@ -102,4 +106,7 @@ public class PurChaseReportInfo {
|
||||||
private String keyWord;
|
private String keyWord;
|
||||||
|
|
||||||
private Long userId;
|
private Long userId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "状态(已验收1,未入库2)")
|
||||||
|
private String status;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -45,6 +45,7 @@ public class BmReportServiceImpl implements BmReportService {
|
||||||
BigDecimal totalPurchasePrice = BigDecimal.ZERO.setScale(2, RoundingMode.HALF_UP);
|
BigDecimal totalPurchasePrice = BigDecimal.ZERO.setScale(2, RoundingMode.HALF_UP);
|
||||||
BigDecimal totalPurchasePriceNoTax = BigDecimal.ZERO.setScale(2, RoundingMode.HALF_UP);
|
BigDecimal totalPurchasePriceNoTax = BigDecimal.ZERO.setScale(2, RoundingMode.HALF_UP);
|
||||||
BigDecimal totalPendingInputNum = BigDecimal.ZERO.setScale(3, RoundingMode.HALF_UP);
|
BigDecimal totalPendingInputNum = BigDecimal.ZERO.setScale(3, RoundingMode.HALF_UP);
|
||||||
|
BigDecimal totalNotPassNum = BigDecimal.ZERO.setScale(3, RoundingMode.HALF_UP);
|
||||||
List<PurChaseReportInfo> list = bmReportMapper.getPurChaseReportList(bean);
|
List<PurChaseReportInfo> list = bmReportMapper.getPurChaseReportList(bean);
|
||||||
if (CollectionUtils.isNotEmpty(list)) {
|
if (CollectionUtils.isNotEmpty(list)) {
|
||||||
for (PurChaseReportInfo purChaseReportInfo : list) {
|
for (PurChaseReportInfo purChaseReportInfo : list) {
|
||||||
|
|
@ -54,6 +55,7 @@ public class BmReportServiceImpl implements BmReportService {
|
||||||
totalPurchasePrice = totalPurchasePrice.add(purChaseReportInfo.getPurchasePrice());
|
totalPurchasePrice = totalPurchasePrice.add(purChaseReportInfo.getPurchasePrice());
|
||||||
totalPurchasePriceNoTax = totalPurchasePriceNoTax.add(purChaseReportInfo.getPurchasePriceNoTax());
|
totalPurchasePriceNoTax = totalPurchasePriceNoTax.add(purChaseReportInfo.getPurchasePriceNoTax());
|
||||||
totalPendingInputNum = totalPendingInputNum.add(purChaseReportInfo.getPendingInputNum());
|
totalPendingInputNum = totalPendingInputNum.add(purChaseReportInfo.getPendingInputNum());
|
||||||
|
totalNotPassNum = totalNotPassNum.add(purChaseReportInfo.getNotPassNum());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (bean.getIsExport() == 0) {
|
if (bean.getIsExport() == 0) {
|
||||||
|
|
@ -64,6 +66,7 @@ public class BmReportServiceImpl implements BmReportService {
|
||||||
info.setPurchasePrice(totalPurchasePrice);
|
info.setPurchasePrice(totalPurchasePrice);
|
||||||
info.setPurchasePriceNoTax(totalPurchasePriceNoTax);
|
info.setPurchasePriceNoTax(totalPurchasePriceNoTax);
|
||||||
info.setPendingInputNum(totalPendingInputNum);
|
info.setPendingInputNum(totalPendingInputNum);
|
||||||
|
info.setNotPassNum(totalNotPassNum);
|
||||||
info.setUnitName("合计");
|
info.setUnitName("合计");
|
||||||
list.add(0, info);
|
list.add(0, info);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -72,7 +72,7 @@ public class RepairCost extends BaseEntity {
|
||||||
@ApiModelProperty(value = "委外维修费用")
|
@ApiModelProperty(value = "委外维修费用")
|
||||||
private BigDecimal outSourceCosts;
|
private BigDecimal outSourceCosts;
|
||||||
|
|
||||||
/** 维修方式(1内部2返厂3报废) */
|
/** 维修方式(1内部2返厂3报废4现场维修) */
|
||||||
@Excel(name = "维修方式", readConverterExp = "1=内部2返厂3报废")
|
@Excel(name = "维修方式", readConverterExp = "1=内部2返厂3报废")
|
||||||
private String repairType;
|
private String repairType;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -800,8 +800,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
<insert id="addExitPermit">
|
<insert id="addExitPermit">
|
||||||
insert into bm_exit_permit (material,name,car_code,add_date,create_by,create_time)
|
insert into bm_exit_permit (material,name,car_code,add_date,create_by,create_time,code)
|
||||||
values (#{material}, #{name}, #{carCode}, #{addDate}, #{createBy}, now())
|
values (#{material}, #{name}, #{carCode}, #{addDate}, #{createBy}, now(), #{code})
|
||||||
</insert>
|
</insert>
|
||||||
<insert id="syncProject" useGeneratedKeys="true" keyProperty="id">
|
<insert id="syncProject" useGeneratedKeys="true" keyProperty="id">
|
||||||
INSERT INTO archives_record_info
|
INSERT INTO archives_record_info
|
||||||
|
|
@ -1507,7 +1507,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
`name`,
|
`name`,
|
||||||
material,
|
material,
|
||||||
car_code as carCode,
|
car_code as carCode,
|
||||||
add_date as addDate
|
add_date as addDate,
|
||||||
|
code as code
|
||||||
FROM
|
FROM
|
||||||
bm_exit_permit
|
bm_exit_permit
|
||||||
WHERE
|
WHERE
|
||||||
|
|
@ -1629,4 +1630,28 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
</if>
|
</if>
|
||||||
limit 1
|
limit 1
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
<select id="getCodeList" resultType="com.bonus.material.back.domain.ExitPermit">
|
||||||
|
SELECT
|
||||||
|
tt.`code` AS code,
|
||||||
|
tt.create_time AS createTime,
|
||||||
|
1 AS source
|
||||||
|
FROM
|
||||||
|
tm_task tt
|
||||||
|
LEFT JOIN lease_apply_info lp ON tt.task_id = lp.task_id
|
||||||
|
WHERE
|
||||||
|
task_type = 2
|
||||||
|
AND lp.direct_id IS NULL
|
||||||
|
UNION ALL
|
||||||
|
SELECT
|
||||||
|
`code` AS code,
|
||||||
|
create_time AS createTime,
|
||||||
|
2 AS source
|
||||||
|
FROM
|
||||||
|
lease_publish_details
|
||||||
|
GROUP BY
|
||||||
|
code
|
||||||
|
ORDER BY
|
||||||
|
createTime DESC;
|
||||||
|
</select>
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|
|
||||||
|
|
@ -13,6 +13,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
mt1.unit_name as unitName,
|
mt1.unit_name as unitName,
|
||||||
IFNULL(pcd.purchase_num, 0) as purchaseNum,
|
IFNULL(pcd.purchase_num, 0) as purchaseNum,
|
||||||
IFNULL(pcd.check_num, 0) as passNum,
|
IFNULL(pcd.check_num, 0) as passNum,
|
||||||
|
IFNULL(pcd.purchase_num, 0) - IFNULL(pcd.check_num, 0) as notPassNum,
|
||||||
IFNULL(pcd.input_num, 0) as inputNum,
|
IFNULL(pcd.input_num, 0) as inputNum,
|
||||||
IFNULL(pcd.purchase_price, 0) as purchasePrice,
|
IFNULL(pcd.purchase_price, 0) as purchasePrice,
|
||||||
IFNULL(pcd.purchase_tax_price, 0) as purchasePriceNoTax,
|
IFNULL(pcd.purchase_tax_price, 0) as purchasePriceNoTax,
|
||||||
|
|
@ -42,7 +43,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
LEFT JOIN ma_type mt4 ON mt4.type_id = mt3.parent_id
|
LEFT JOIN ma_type mt4 ON mt4.type_id = mt3.parent_id
|
||||||
LEFT JOIN ma_type_manage mtm ON mt4.type_id = mtm.type_id
|
LEFT JOIN ma_type_manage mtm ON mt4.type_id = mtm.type_id
|
||||||
WHERE
|
WHERE
|
||||||
pcd.check_num > 0 and tt.task_type = 0
|
tt.task_type = 0
|
||||||
<if test="userId != null ">
|
<if test="userId != null ">
|
||||||
and mtm.user_id = #{userId}
|
and mtm.user_id = #{userId}
|
||||||
</if>
|
</if>
|
||||||
|
|
@ -58,7 +59,23 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<if test="startTime != null and startTime != '' and endTime != null and endTime != ''">
|
<if test="startTime != null and startTime != '' and endTime != null and endTime != ''">
|
||||||
<![CDATA[and DATE_FORMAT( pci.create_time, '%Y-%m-%d' ) BETWEEN #{startTime} AND #{endTime} ]]>
|
<![CDATA[and DATE_FORMAT( pci.create_time, '%Y-%m-%d' ) BETWEEN #{startTime} AND #{endTime} ]]>
|
||||||
</if>
|
</if>
|
||||||
ORDER BY pcd.input_time DESC
|
<if test="status != null">
|
||||||
|
<choose>
|
||||||
|
<when test="status == 1">
|
||||||
|
and IFNULL(pcd.check_num, 0) > 0
|
||||||
|
</when>
|
||||||
|
<when test="status == 2">
|
||||||
|
and (
|
||||||
|
IFNULL(pcd.input_num, 0) = 0
|
||||||
|
or IFNULL(pcd.check_num, 0) > IFNULL(pcd.input_num, 0)
|
||||||
|
)
|
||||||
|
</when>
|
||||||
|
<otherwise>
|
||||||
|
and 1 = 1
|
||||||
|
</otherwise>
|
||||||
|
</choose>
|
||||||
|
</if>
|
||||||
|
ORDER BY pcd.input_time
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="getPurChaseReportDetailsList"
|
<select id="getPurChaseReportDetailsList"
|
||||||
|
|
|
||||||
|
|
@ -1268,9 +1268,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
sai.is_slt = '0'
|
sai.is_slt = '0'
|
||||||
AND sai.`status` = '0'
|
AND sai.`status` = '0'
|
||||||
AND bu.unit_name = #{teamName}
|
AND bu.unit_name = #{teamName}
|
||||||
<if test="externalId != null and externalId != ''">
|
|
||||||
AND bu.project_id = #{externalId}
|
|
||||||
</if>
|
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="getClzAgreementId" resultType="com.bonus.material.clz.domain.vo.MaterialRetainedEquipmentInfo">
|
<select id="getClzAgreementId" resultType="com.bonus.material.clz.domain.vo.MaterialRetainedEquipmentInfo">
|
||||||
|
|
@ -1284,9 +1281,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
WHERE
|
WHERE
|
||||||
sai.is_slt = '0'
|
sai.is_slt = '0'
|
||||||
AND bu.unit_name = #{teamName}
|
AND bu.unit_name = #{teamName}
|
||||||
<if test="externalId != null and externalId != ''">
|
|
||||||
AND bu.project_id = #{externalId}
|
|
||||||
</if>
|
|
||||||
</select>
|
</select>
|
||||||
<select id="selectProAuthorizeInfo" resultType="com.bonus.material.materialStation.domain.ProAuthorizeInfo">
|
<select id="selectProAuthorizeInfo" resultType="com.bonus.material.materialStation.domain.ProAuthorizeInfo">
|
||||||
SELECT
|
SELECT
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue