工地直转点击通过
This commit is contained in:
parent
15ccee2af1
commit
9b67c44fe4
|
|
@ -44,7 +44,7 @@ public interface WorkSiteDirectManageMapper {
|
|||
|
||||
int batchDel(@Param("ids") ArrayList<Integer> ids);
|
||||
|
||||
String getMachineStatus(LeaseOutDetails leaseOutDetails);
|
||||
DirectApplyInfo getMachineStatus(LeaseOutDetails leaseOutDetails);
|
||||
|
||||
int updateLeaseApplyDetailsOutNum(@Param("record")LeaseOutDetails leaseOutDetails);
|
||||
|
||||
|
|
|
|||
|
|
@ -13,7 +13,6 @@ import com.bonus.sgzb.material.service.*;
|
|||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.ArrayList;
|
||||
|
|
@ -179,7 +178,7 @@ public class WorkSiteDirectManageImpl implements WorkSiteDirectManageService {
|
|||
@Transactional(rollbackFor = Exception.class)
|
||||
public int insertLeaseOutDetail(List<LeaseOutDetails> leaseOutDetails, TmTask lTask) {
|
||||
int res = 0;
|
||||
String maStatus = "15";
|
||||
String maStatus = "16";
|
||||
double outNum = 0.1;
|
||||
if (StringUtils.isNull(leaseOutDetails)) {
|
||||
log.info("领料出库失败,请检查参数是否填写完整!");
|
||||
|
|
@ -187,9 +186,9 @@ public class WorkSiteDirectManageImpl implements WorkSiteDirectManageService {
|
|||
}
|
||||
for (LeaseOutDetails leaseOutDetail : leaseOutDetails) {
|
||||
if (!(Objects.equals(Integer.valueOf(0), leaseOutDetail.getMaId()) || leaseOutDetail.getMaId() == null)) {
|
||||
String status = workSiteDirectManageMapper.getMachineStatus(leaseOutDetail);
|
||||
if (!maStatus.equals(status)) {
|
||||
log.info("领料出库失败,该设备不是在库状态!");
|
||||
DirectApplyInfo directApplyInfo = workSiteDirectManageMapper.getMachineStatus(leaseOutDetail);
|
||||
if (!maStatus.equals(directApplyInfo.getStatus())) {
|
||||
log.info("领料出库失败,该设备不是再用状态!");
|
||||
return res;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -431,8 +431,8 @@
|
|||
<select id="getDirectApplyInfoById" resultType="com.bonus.sgzb.base.api.domain.DirectApplyInfo">
|
||||
select * from direct_apply_info where id = #{id}
|
||||
</select>
|
||||
<select id="getMachineStatus" resultType="java.lang.String">
|
||||
select ma_status
|
||||
<select id="getMachineStatus" resultType="com.bonus.sgzb.base.api.domain.DirectApplyInfo">
|
||||
select ma_status as status
|
||||
from ma_machine
|
||||
where ma_id = #{maId}
|
||||
</select>
|
||||
|
|
|
|||
Loading…
Reference in New Issue