opt: 入库管理更新
This commit is contained in:
@@ -6,6 +6,7 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
|
|||||||
import com.baomidou.mybatisplus.extension.service.IService;
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
import org.nl.common.domain.query.PageQuery;
|
import org.nl.common.domain.query.PageQuery;
|
||||||
import org.nl.wms.basedata_manage.service.dao.Structattr;
|
import org.nl.wms.basedata_manage.service.dao.Structattr;
|
||||||
|
import org.nl.wms.warehouse_management.service.dao.IOStorInv;
|
||||||
import org.springframework.data.domain.Pageable;
|
import org.springframework.data.domain.Pageable;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
@@ -82,6 +83,8 @@ public interface IStructattrService extends IService<Structattr> {
|
|||||||
*/
|
*/
|
||||||
void changeActive(JSONObject json);
|
void changeActive(JSONObject json);
|
||||||
|
|
||||||
|
void updateStatusByCode(String operate, JSONObject JSONObject);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 更新锁状态
|
* 更新锁状态
|
||||||
* @param updateAttrList {
|
* @param updateAttrList {
|
||||||
|
|||||||
@@ -7,6 +7,8 @@ import com.alibaba.fastjson.JSON;
|
|||||||
import com.alibaba.fastjson.JSONArray;
|
import com.alibaba.fastjson.JSONArray;
|
||||||
import com.alibaba.fastjson.JSONObject;
|
import com.alibaba.fastjson.JSONObject;
|
||||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
|
||||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
@@ -24,6 +26,7 @@ import org.nl.wms.basedata_manage.service.dao.BsrealStorattr;
|
|||||||
import org.nl.wms.basedata_manage.service.dao.Sectattr;
|
import org.nl.wms.basedata_manage.service.dao.Sectattr;
|
||||||
import org.nl.wms.basedata_manage.service.dao.Structattr;
|
import org.nl.wms.basedata_manage.service.dao.Structattr;
|
||||||
import org.nl.wms.basedata_manage.service.dao.mapper.StructattrMapper;
|
import org.nl.wms.basedata_manage.service.dao.mapper.StructattrMapper;
|
||||||
|
import org.nl.wms.warehouse_management.service.dao.IOStorInv;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
import org.springframework.transaction.annotation.Transactional;
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
@@ -226,6 +229,37 @@ public class StructattrServiceImpl extends ServiceImpl<StructattrMapper, Structa
|
|||||||
// WQLObject.getWQLObject("sch_base_point").update(json, " point_code = '" + struct_code + "'");
|
// WQLObject.getWQLObject("sch_base_point").update(json, " point_code = '" + struct_code + "'");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateStatusByCode(String operate, JSONObject jsonObject) {
|
||||||
|
//operate:0生成、1单据确认、2取消分配
|
||||||
|
switch (operate){
|
||||||
|
case "0":
|
||||||
|
//锁定仓位
|
||||||
|
this.update(new LambdaUpdateWrapper<>(Structattr.class)
|
||||||
|
.set(Structattr::getInv_id,jsonObject.getString("inv_id"))
|
||||||
|
.set(Structattr::getInv_code,jsonObject.getString("inv_code"))
|
||||||
|
.set(Structattr::getInv_type,jsonObject.getString("inv_type"))
|
||||||
|
.set(Structattr::getLock_type,"01")
|
||||||
|
.eq(Structattr::getStruct_code,jsonObject.getString("struct_code"))
|
||||||
|
);
|
||||||
|
break;
|
||||||
|
case "1":
|
||||||
|
|
||||||
|
break;
|
||||||
|
|
||||||
|
case "2":
|
||||||
|
//解锁仓位
|
||||||
|
this.update(new LambdaUpdateWrapper<>(Structattr.class)
|
||||||
|
.set(Structattr::getInv_id,jsonObject.getString("inv_id"))
|
||||||
|
.set(Structattr::getInv_code,jsonObject.getString("inv_code"))
|
||||||
|
.set(Structattr::getInv_type,jsonObject.getString("inv_type"))
|
||||||
|
.set(Structattr::getLock_type,"00")
|
||||||
|
.eq(Structattr::getStruct_code,jsonObject.getString("struct_code"))
|
||||||
|
);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void updateLock(List<JSONObject> updateAttrList) {
|
public void updateLock(List<JSONObject> updateAttrList) {
|
||||||
List<Structattr> attrList = this.list(
|
List<Structattr> attrList = this.list(
|
||||||
|
|||||||
@@ -36,7 +36,8 @@ public class StInTask extends AbstractTask {
|
|||||||
task.setConfig_code(json.getString("task_type"));
|
task.setConfig_code(json.getString("task_type"));
|
||||||
task.setPoint_code1(json.getString("PickingLocation"));
|
task.setPoint_code1(json.getString("PickingLocation"));
|
||||||
task.setPoint_code2(json.getString("PlacedLocation"));
|
task.setPoint_code2(json.getString("PlacedLocation"));
|
||||||
task.setExt_group_data(json.getString("CarryIsEmptyTuoPan"));
|
task.setVehicle_code(json.getString("vehicle_code"));
|
||||||
|
task.setGroup_id(json.getString("group_id"));
|
||||||
task.setRequest_param(json.toString());
|
task.setRequest_param(json.toString());
|
||||||
task.setPriority(json.getString("Priority"));
|
task.setPriority(json.getString("Priority"));
|
||||||
task.setCreate_id(SecurityUtils.getCurrentUserId());
|
task.setCreate_id(SecurityUtils.getCurrentUserId());
|
||||||
|
|||||||
@@ -95,7 +95,7 @@ public class IOStorInv implements Serializable {
|
|||||||
private Integer detail_count;
|
private Integer detail_count;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 单据状态
|
* 单据状态 10生成 20分配中 30分配完 99完成
|
||||||
*/
|
*/
|
||||||
private String bill_status;
|
private String bill_status;
|
||||||
|
|
||||||
|
|||||||
@@ -28,77 +28,77 @@ public class IOStorInvDtl implements Serializable {
|
|||||||
private String iostorinv_id;
|
private String iostorinv_id;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 出入单标识
|
* 明细序号
|
||||||
*/
|
*/
|
||||||
private String seq_no;
|
private String seq_no;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 出入单标识
|
* 物料标识
|
||||||
*/
|
*/
|
||||||
private String material_id;
|
private String material_id;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 出入单标识
|
* 批次
|
||||||
*/
|
*/
|
||||||
private String pcsn;
|
private String pcsn;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 出入单标识
|
* 单据明细状态 10生成 20分配中 30分配完 99完成
|
||||||
*/
|
*/
|
||||||
private String bill_status;
|
private String bill_status;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 出入单标识
|
* 数量计量单位标识
|
||||||
*/
|
*/
|
||||||
private String qty_unit_id;
|
private String qty_unit_id;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 出入单标识
|
* 数量计量单位名称
|
||||||
*/
|
*/
|
||||||
private String qty_unit_name;
|
private String qty_unit_name;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 出入单标识
|
* 计划数量
|
||||||
*/
|
*/
|
||||||
private BigDecimal plan_qty;
|
private BigDecimal plan_qty;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 出入单标识
|
* 实际数量
|
||||||
*/
|
*/
|
||||||
private BigDecimal real_qty;
|
private BigDecimal real_qty;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 出入单标识
|
* 来源单据明细标识
|
||||||
*/
|
*/
|
||||||
private String source_billdtl_id;
|
private String source_billdtl_id;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 出入单标识
|
* 来源单据类型
|
||||||
*/
|
*/
|
||||||
private String source_bill_type;
|
private String source_bill_type;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 出入单标识
|
* 来源单编号
|
||||||
*/
|
*/
|
||||||
private String source_bill_code;
|
private String source_bill_code;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 出入单标识
|
* 来源单表名
|
||||||
*/
|
*/
|
||||||
private String source_bill_table;
|
private String source_bill_table;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 出入单标识
|
* 备注
|
||||||
*/
|
*/
|
||||||
private String remark;
|
private String remark;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 出入单标识
|
* 已分配数量
|
||||||
*/
|
*/
|
||||||
private BigDecimal assign_qty;
|
private BigDecimal assign_qty;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 出入单标识
|
* 未分配数量
|
||||||
*/
|
*/
|
||||||
private BigDecimal unassign_qty;
|
private BigDecimal unassign_qty;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,5 +15,5 @@ import java.util.List;
|
|||||||
@Mapper
|
@Mapper
|
||||||
public interface IOStorInvDisMapper extends BaseMapper<IOStorInvDis> {
|
public interface IOStorInvDisMapper extends BaseMapper<IOStorInvDis> {
|
||||||
|
|
||||||
List<IOStorInvDisDto> queryInBillDisDtlByIosId(@Param("iostorinv_id")String iostorinv_id);
|
List<IOStorInvDisDto> queryInBillDisDtlByIosId(@Param("iostorinvdtl_id")String iostorinvdtl_id);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -12,9 +12,9 @@
|
|||||||
LEFT JOIN md_me_materialbase mb ON mb.material_id = dis.material_id
|
LEFT JOIN md_me_materialbase mb ON mb.material_id = dis.material_id
|
||||||
where
|
where
|
||||||
(dis.task_id is null OR dis.task_id = '')
|
(dis.task_id is null OR dis.task_id = '')
|
||||||
<if test="iostorinv_id != null">
|
<if test="iostorinvdtl_id != null">
|
||||||
AND
|
AND
|
||||||
dis.iostorinv_id = #{iostorinv_id}
|
dis.iostorinvdtl_id = #{iostorinvdtl_id}
|
||||||
</if>
|
</if>
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
|||||||
@@ -8,6 +8,7 @@ import com.alibaba.fastjson.JSON;
|
|||||||
import com.alibaba.fastjson.JSONArray;
|
import com.alibaba.fastjson.JSONArray;
|
||||||
import com.alibaba.fastjson.JSONObject;
|
import com.alibaba.fastjson.JSONObject;
|
||||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
|
||||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
@@ -16,6 +17,7 @@ import org.nl.common.exception.BadRequestException;
|
|||||||
import org.nl.common.utils.CodeUtil;
|
import org.nl.common.utils.CodeUtil;
|
||||||
import org.nl.common.utils.IdUtil;
|
import org.nl.common.utils.IdUtil;
|
||||||
import org.nl.common.utils.SecurityUtils;
|
import org.nl.common.utils.SecurityUtils;
|
||||||
|
import org.nl.config.SpringContextHolder;
|
||||||
import org.nl.system.service.param.impl.SysParamServiceImpl;
|
import org.nl.system.service.param.impl.SysParamServiceImpl;
|
||||||
import org.nl.wms.basedata_manage.service.IBsrealStorattrService;
|
import org.nl.wms.basedata_manage.service.IBsrealStorattrService;
|
||||||
import org.nl.wms.basedata_manage.service.IStructattrService;
|
import org.nl.wms.basedata_manage.service.IStructattrService;
|
||||||
@@ -23,6 +25,10 @@ import org.nl.wms.basedata_manage.service.dao.BsrealStorattr;
|
|||||||
import org.nl.wms.basedata_manage.service.dao.MdPbStoragevehicleinfo;
|
import org.nl.wms.basedata_manage.service.dao.MdPbStoragevehicleinfo;
|
||||||
import org.nl.wms.basedata_manage.service.dao.Structattr;
|
import org.nl.wms.basedata_manage.service.dao.Structattr;
|
||||||
import org.nl.wms.basedata_manage.service.dao.mapper.MdPbStoragevehicleinfoMapper;
|
import org.nl.wms.basedata_manage.service.dao.mapper.MdPbStoragevehicleinfoMapper;
|
||||||
|
import org.nl.wms.sch_manage.service.dao.SchBasePoint;
|
||||||
|
import org.nl.wms.sch_manage.service.dao.mapper.SchBasePointMapper;
|
||||||
|
import org.nl.wms.sch_manage.service.util.AbstractTask;
|
||||||
|
import org.nl.wms.sch_manage.service.util.tasks.StInTask;
|
||||||
import org.nl.wms.warehouse_management.service.IRawAssistIStorService;
|
import org.nl.wms.warehouse_management.service.IRawAssistIStorService;
|
||||||
import org.nl.wms.warehouse_management.service.dao.GroupPlate;
|
import org.nl.wms.warehouse_management.service.dao.GroupPlate;
|
||||||
import org.nl.wms.warehouse_management.service.dao.IOStorInv;
|
import org.nl.wms.warehouse_management.service.dao.IOStorInv;
|
||||||
@@ -69,6 +75,9 @@ public class RawAssistIStorServiceImpl extends ServiceImpl<IOStorInvMapper, IOSt
|
|||||||
@Resource
|
@Resource
|
||||||
private MdPbStoragevehicleinfoMapper mdPbStoragevehicleinfoMapper;
|
private MdPbStoragevehicleinfoMapper mdPbStoragevehicleinfoMapper;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private SchBasePointMapper schBasePointMapper;
|
||||||
|
|
||||||
@Resource
|
@Resource
|
||||||
private GroupPlateMapper groupPlateMapper;
|
private GroupPlateMapper groupPlateMapper;
|
||||||
|
|
||||||
@@ -170,7 +179,8 @@ public class RawAssistIStorServiceImpl extends ServiceImpl<IOStorInvMapper, IOSt
|
|||||||
ioStorInvDtl.put("bill_status","10");
|
ioStorInvDtl.put("bill_status","10");
|
||||||
ioStorInvDtl.put("qty_unit_id",row.get("qty_unit_id"));
|
ioStorInvDtl.put("qty_unit_id",row.get("qty_unit_id"));
|
||||||
ioStorInvDtl.put("qty_unit_name",row.get("qty_unit_name"));
|
ioStorInvDtl.put("qty_unit_name",row.get("qty_unit_name"));
|
||||||
ioStorInvDtl.put("assign_qty",row.get("qty"));
|
ioStorInvDtl.put("assign_qty","0");
|
||||||
|
ioStorInvDtl.put("unassign_qty",row.get("plan_qty"));
|
||||||
ioStorInvDtl.put("plan_qty",row.get("plan_qty"));
|
ioStorInvDtl.put("plan_qty",row.get("plan_qty"));
|
||||||
total_qty += Double.parseDouble(row.get("qty").toString());
|
total_qty += Double.parseDouble(row.get("qty").toString());
|
||||||
|
|
||||||
@@ -366,10 +376,8 @@ public class RawAssistIStorServiceImpl extends ServiceImpl<IOStorInvMapper, IOSt
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
public void divStruct(Map whereJson) {
|
public void divStruct(Map whereJson) {
|
||||||
String currentUserId = SecurityUtils.getCurrentUserId();
|
|
||||||
String nickName = SecurityUtils.getCurrentNickName();
|
|
||||||
String now = DateUtil.now();
|
|
||||||
String sect_id = "";
|
String sect_id = "";
|
||||||
String sect_code = "";
|
String sect_code = "";
|
||||||
String sect_name = "";
|
String sect_name = "";
|
||||||
@@ -380,26 +388,16 @@ public class RawAssistIStorServiceImpl extends ServiceImpl<IOStorInvMapper, IOSt
|
|||||||
JSONObject whereJson2 = JSONObject.parseObject(JSON.toJSONString(whereJson));
|
JSONObject whereJson2 = JSONObject.parseObject(JSON.toJSONString(whereJson));
|
||||||
HashMap<String, String> map = rows.get(0);
|
HashMap<String, String> map = rows.get(0);
|
||||||
|
|
||||||
//判断该载具是否已经分配货位或者起点
|
//判断该分配明细是否已经分配货位
|
||||||
IOStorInvDis ioStorInvDis = ioStorInvDisMapper.selectOne(new LambdaQueryWrapper<>(IOStorInvDis.class)
|
IOStorInvDis ioStorInvDis = ioStorInvDisMapper.selectOne(new LambdaQueryWrapper<>(IOStorInvDis.class)
|
||||||
.eq(IOStorInvDis::getIostorinvdis_id,map.get("iostorinvdis_id"))
|
.eq(IOStorInvDis::getIostorinvdis_id,map.get("iostorinvdis_id"))
|
||||||
.isNull(IOStorInvDis::getStruct_code));
|
.isNull(IOStorInvDis::getStruct_code).or().eq(IOStorInvDis::getStruct_code,""));
|
||||||
if (ObjectUtil.isEmpty(ioStorInvDis)){
|
if (ObjectUtil.isEmpty(ioStorInvDis)){
|
||||||
throw new BadRequestException("该明细已经分配过货位,无法继续分配!");
|
throw new BadRequestException("该明细已经分配过货位,无法继续分配!");
|
||||||
}
|
}
|
||||||
|
|
||||||
String point_code = map.get("point_code");
|
|
||||||
// if (StrUtil.isNotEmpty(point_code)) {
|
|
||||||
// HashMap<String, String> point_map = new HashMap<>();
|
|
||||||
// PointDto pointDto = pointService.findByCode(point_code);
|
|
||||||
// point_map.put("point_code", pointDto.getPoint_code());
|
|
||||||
// point_map.put("point_id", pointDto.getPoint_id() + "");
|
|
||||||
// point_map.put("point_name", pointDto.getPoint_name());
|
|
||||||
// WQLObject.getWQLObject("ST_IVT_IOStorInvDis").update(point_map, "iostorinv_id = '" + map.get("iostorinv_id") + "' AND box_no = '" + map.get("box_no") + "'");
|
|
||||||
// }
|
|
||||||
|
|
||||||
Boolean checked = whereJson2.getBoolean("checked");
|
Boolean checked = whereJson2.getBoolean("checked");
|
||||||
//是否分配货位
|
//是否自动分配仓位
|
||||||
if (ObjectUtil.isNotEmpty(checked) && checked) {
|
if (ObjectUtil.isNotEmpty(checked) && checked) {
|
||||||
JSONObject jo_form = new JSONObject();
|
JSONObject jo_form = new JSONObject();
|
||||||
Structattr struct = new Structattr();
|
Structattr struct = new Structattr();
|
||||||
@@ -433,33 +431,6 @@ public class RawAssistIStorServiceImpl extends ServiceImpl<IOStorInvMapper, IOSt
|
|||||||
structattr.getZdepth().compareTo(mdPbStoragevehicleinfo.getVehicle_long()) <0){
|
structattr.getZdepth().compareTo(mdPbStoragevehicleinfo.getVehicle_long()) <0){
|
||||||
throw new BadRequestException("载具不符合,请检查!");
|
throw new BadRequestException("载具不符合,请检查!");
|
||||||
}
|
}
|
||||||
// // 校验仓位是否满足此木箱高度
|
|
||||||
// JSONObject jsonSub = WQLObject.getWQLObject("pdm_bi_subpackagerelation").query("package_box_sn = '" + map.get("box_no") + "'").uniqueResult(0);
|
|
||||||
// double box_high = jsonSub.getDoubleValue("box_high");
|
|
||||||
//
|
|
||||||
// JSONObject jsonAttr = WQLObject.getWQLObject("st_ivt_structattr").query("struct_code = '" + map.get("struct_code") + "'").uniqueResult(0);
|
|
||||||
//
|
|
||||||
// // 入库木箱下限
|
|
||||||
// String in_download_box_high = SpringContextHolder.getBean(SysParamServiceImpl.class).findByCode("in_download_box_high").getValue();
|
|
||||||
// // 入库木箱上线
|
|
||||||
// String in_up_box_high = SpringContextHolder.getBean(SysParamServiceImpl.class).findByCode("in_up_box_high").getValue();
|
|
||||||
//
|
|
||||||
// if (Double.parseDouble(in_download_box_high) < box_high && box_high <= Double.parseDouble(in_up_box_high)) {
|
|
||||||
// if (StrUtil.equals(jsonAttr.getString("layer_num"), "3")) {
|
|
||||||
// if (box_high > jsonAttr.getDoubleValue("height")) {
|
|
||||||
// throw new BadRequestException("木箱高度不符,请检查!");
|
|
||||||
// }
|
|
||||||
// } else if (StrUtil.equals(jsonAttr.getString("layer_num"), "1")) {
|
|
||||||
// if (box_high > Double.parseDouble(in_download_box_high)) {
|
|
||||||
// throw new BadRequestException("木箱高度不符,请检查!");
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// if (box_high > Double.parseDouble(in_up_box_high)) {
|
|
||||||
// throw new BadRequestException("木箱高度不符,请检查!");
|
|
||||||
// }
|
|
||||||
|
|
||||||
sect_id = map.get("sect_id");
|
sect_id = map.get("sect_id");
|
||||||
sect_code = map.get("sect_code");
|
sect_code = map.get("sect_code");
|
||||||
sect_name = map.get("sect_name");
|
sect_name = map.get("sect_name");
|
||||||
@@ -467,7 +438,7 @@ public class RawAssistIStorServiceImpl extends ServiceImpl<IOStorInvMapper, IOSt
|
|||||||
struct_code = map.get("struct_code");
|
struct_code = map.get("struct_code");
|
||||||
struct_name = map.get("struct_name");
|
struct_name = map.get("struct_name");
|
||||||
}
|
}
|
||||||
HashMap<String, String> dis_map = new HashMap();
|
JSONObject dis_map = new JSONObject();
|
||||||
dis_map.put("sect_id", sect_id);
|
dis_map.put("sect_id", sect_id);
|
||||||
dis_map.put("sect_code", sect_code);
|
dis_map.put("sect_code", sect_code);
|
||||||
dis_map.put("sect_name", sect_name);
|
dis_map.put("sect_name", sect_name);
|
||||||
@@ -476,107 +447,43 @@ public class RawAssistIStorServiceImpl extends ServiceImpl<IOStorInvMapper, IOSt
|
|||||||
dis_map.put("struct_name", struct_name);
|
dis_map.put("struct_name", struct_name);
|
||||||
|
|
||||||
//锁定货位
|
//锁定货位
|
||||||
// JSONObject lock_map = new JSONObject();
|
IOStorInv ioStorInv = ioStorInvMapper.selectById(map.get("iostorinv_id"));
|
||||||
// lock_map.put("end_point", struct_code);
|
JSONObject lock_map = new JSONObject();
|
||||||
// //查询主表信息
|
lock_map.put("struct_code", struct_code);
|
||||||
// JSONObject mst = WQLObject.getWQLObject("st_ivt_iostorinv").query("iostorinv_id = '" + map.get("iostorinv_id") + "'").uniqueResult(0);
|
lock_map.put("inv_id", ioStorInv.getIostorinv_id());
|
||||||
// lock_map.put("inv_type", mst.get("bill_type"));
|
lock_map.put("inv_code", ioStorInv.getBill_code());
|
||||||
// lock_map.put("inv_id", mst.get("iostorinv_id"));
|
lock_map.put("inv_type", ioStorInv.getBill_type());
|
||||||
// lock_map.put("inv_code", mst.get("bill_code"));
|
iStructattrService.updateStatusByCode("0",lock_map);
|
||||||
// inbillService.operatePoint("0", lock_map);
|
|
||||||
//
|
// 修改分配明细表
|
||||||
// //判断起点是否不为空
|
ioStorInvDisMapper.update(dis_map.toJavaObject(IOStorInvDis.class),new LambdaUpdateWrapper<>(IOStorInvDis.class)
|
||||||
// JSONObject ios_dis = WQLObject.getWQLObject("ST_IVT_IOStorInvDis").query("iostorinv_id = '" + map.get("iostorinv_id") + "' AND box_no = '" + map.get("box_no") + "'").uniqueResult(0);
|
.set(IOStorInvDis::getSect_id,dis_map.getString("sect_id"))
|
||||||
//
|
.set(IOStorInvDis::getSect_code,dis_map.getString("sect_code"))
|
||||||
// JSONObject sect_jo = WQLObject.getWQLObject("st_ivt_sectattr").query("sect_id ='" + sect_id + "'").uniqueResult(0);
|
.set(IOStorInvDis::getSect_name,dis_map.getString("sect_name"))
|
||||||
// boolean is_virtual = false;
|
.set(IOStorInvDis::getStruct_id,dis_map.getString("struct_id"))
|
||||||
// if ("09".equals(sect_jo.getString("sect_type_attr"))) {
|
.set(IOStorInvDis::getStruct_code,dis_map.getString("struct_code"))
|
||||||
// is_virtual = true;
|
.set(IOStorInvDis::getStruct_name,dis_map.getString("struct_name"))
|
||||||
// String task_id = cn.hutool.core.util.IdUtil.getSnowflake(1, 1).nextId() + "";
|
.eq(IOStorInvDis::getIostorinvdis_id,map.get("iostorinvdis_id"))
|
||||||
// dis_map.put("task_id", task_id);
|
);
|
||||||
// dis_map.put("work_status", "01");
|
|
||||||
// }
|
//维护单据明细表里 分配数量
|
||||||
// if (StrUtil.isNotEmpty(ios_dis.getString("point_id")) && !is_virtual) {
|
JSONObject jsonObject = new JSONObject();
|
||||||
// //创建任务并下发
|
jsonObject.put("iostorinvdtl_id",map.get("iostorinvdtl_id"));
|
||||||
// InTask task = new InTask();
|
jsonObject.put("bill_status","30");
|
||||||
// JSONObject task_form = new JSONObject();
|
jsonObject.put("assign_qty",map.get("plan_qty"));
|
||||||
// task_form.put("task_type", "010501");
|
jsonObject.put("unassign_qty","0");
|
||||||
// task_form.put("start_device_code", map.get("point_code"));
|
ioStorInvDtlMapper.updateById(jsonObject.toJavaObject(IOStorInvDtl.class));
|
||||||
// task_form.put("next_device_code", struct_code);
|
|
||||||
// task_form.put("vehicle_code", map.get("box_no"));
|
//根据单据标识判断分配明细是否都已经分配完成
|
||||||
// task_form.put("storagevehicle_type", map.get("storagevehicle_type"));
|
int disCount = ioStorInvDisMapper.selectCount(new LambdaQueryWrapper<>(IOStorInvDis.class)
|
||||||
// String task_id = task.createTask(task_form);
|
.eq(IOStorInvDis::getIostorinv_id,map.get("iostorinv_id"))
|
||||||
// // 下发
|
.isNull(IOStorInvDis::getStruct_code).or().eq(IOStorInvDis::getStruct_code,""));
|
||||||
// task.immediateNotifyAcs(task_id);
|
|
||||||
// /* if (whereJson.containsKey("auto_issue")) {
|
// 根据分配货位情况 更新主表单据状态
|
||||||
// }*/
|
IOStorInv ios = new IOStorInv();
|
||||||
// dis_map.put("task_id", task_id);
|
ios.setIostorinv_id(map.get("iostorinv_id"));
|
||||||
// dis_map.put("work_status", "01");
|
ios.setBill_status(disCount>0 ? "20" : "30");
|
||||||
// }
|
ioStorInvMapper.updateById(ios);
|
||||||
//
|
|
||||||
// WQLObject.getWQLObject("ST_IVT_IOStorInvDis").update(dis_map, "iostorinv_id = '" + map.get("iostorinv_id") + "' AND box_no = '" + map.get("box_no") + "'");
|
|
||||||
//
|
|
||||||
// //修改库存
|
|
||||||
// //直接取出入库分配表的库存
|
|
||||||
// JSONArray dis_rows = WQLObject.getWQLObject("ST_IVT_IOStorInvDis").query("iostorinv_id = '" + map.get("iostorinv_id") + "' AND box_no = '" + map.get("box_no") + "'").getResultJSONArray(0);
|
|
||||||
// JSONObject mst_jo = WQLObject.getWQLObject("ST_IVT_IOStorInv").query("iostorinv_id = '" + map.get("iostorinv_id") + "'").uniqueResult(0);
|
|
||||||
// for (int i = 0; i < dis_rows.size(); i++) {
|
|
||||||
// JSONObject dis_jo = dis_rows.getJSONObject(i);
|
|
||||||
// JSONObject i_form = new JSONObject();
|
|
||||||
// i_form.put("struct_id", dis_jo.getString("struct_id"));
|
|
||||||
// i_form.put("material_id", dis_jo.getString("material_id"));
|
|
||||||
// i_form.put("pcsn", dis_jo.getString("pcsn"));
|
|
||||||
// i_form.put("change_qty", dis_jo.getString("plan_qty"));
|
|
||||||
// i_form.put("bill_type_scode", mst_jo.getString("bill_type"));
|
|
||||||
// i_form.put("quality_scode", "01");
|
|
||||||
// i_form.put("inv_id", mst_jo.getString("iostorinv_id"));
|
|
||||||
// i_form.put("bill_code", mst_jo.getString("bill_code"));
|
|
||||||
// i_form.put("bill_table", "ST_IVT_IOStorInv");
|
|
||||||
// i_form.put("qty_unit_id", dis_jo.getString("qty_unit_id"));
|
|
||||||
// i_form.put("qty_unit_name", dis_jo.getString("qty_unit_name"));
|
|
||||||
// storPublicService.IOStor(i_form, "31");
|
|
||||||
//
|
|
||||||
// JSONObject dtl_jo = WQLObject.getWQLObject("ST_IVT_IOStorInvDtl").query("iostorinvdtl_id = '" + dis_jo.getString("iostorinvdtl_id") + "'").uniqueResult(0);
|
|
||||||
// if (StrUtil.isNotEmpty(ios_dis.getString("point_id")) || is_virtual) {
|
|
||||||
// if (dtl_jo.getDoubleValue("unassign_qty") == 0) {
|
|
||||||
// //判断该明细下是否还存在未分配货位的分配明细
|
|
||||||
// JSONArray disdiv_rows = WQLObject.getWQLObject("ST_IVT_IOStorInvDis").query("iostorinvdtl_id = '" + dis_jo.getString("iostorinvdtl_id") + "' AND (struct_id = '' OR struct_id is null) AND (point_id = '' OR point_id is null)").getResultJSONArray(0);
|
|
||||||
// if (disdiv_rows.size() == 0) {
|
|
||||||
// dtl_jo.put("bill_status", "40");
|
|
||||||
// WQLObject.getWQLObject("ST_IVT_IOStorInvDtl").update(dtl_jo);
|
|
||||||
// //判断主表下的明细是否都为40
|
|
||||||
// JSONArray dtl_rows = WQLObject.getWQLObject("ST_IVT_IOStorInvDtl").query("iostorinv_id = '" + dis_jo.getString("iostorinv_id") + "' AND bill_status < '40'").getResultJSONArray(0);
|
|
||||||
// if (dtl_rows.size() == 0) {
|
|
||||||
// mst_jo.put("bill_status", "40");
|
|
||||||
// mst_jo.put("dis_optid", currentUserId);
|
|
||||||
// mst_jo.put("dis_optname", nickName);
|
|
||||||
// mst_jo.put("dis_time", now);
|
|
||||||
// WQLObject.getWQLObject("ST_IVT_IOStorInv").update(mst_jo);
|
|
||||||
// } else {
|
|
||||||
// mst_jo.put("bill_status", "30");
|
|
||||||
// mst_jo.put("dis_optid", currentUserId);
|
|
||||||
// mst_jo.put("dis_optname", nickName);
|
|
||||||
// mst_jo.put("dis_time", now);
|
|
||||||
// WQLObject.getWQLObject("ST_IVT_IOStorInv").update(mst_jo);
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// } else {
|
|
||||||
// dtl_jo.put("bill_status", "30");
|
|
||||||
// WQLObject.getWQLObject("ST_IVT_IOStorInvDtl").update(dtl_jo);
|
|
||||||
// mst_jo.put("bill_status", "30");
|
|
||||||
// mst_jo.put("dis_optid", currentUserId);
|
|
||||||
// mst_jo.put("dis_optname", nickName);
|
|
||||||
// mst_jo.put("dis_time", now);
|
|
||||||
// WQLObject.getWQLObject("ST_IVT_IOStorInv").update(mst_jo);
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// //如果是虚拟区,直接更新完成分配任务
|
|
||||||
// if (is_virtual) {
|
|
||||||
// JSONObject dis_form = new JSONObject();
|
|
||||||
// dis_form.put("task_id", dis_map.get("task_id"));
|
|
||||||
// inbillService.confirmDis(dis_form);
|
|
||||||
// }
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -585,13 +492,89 @@ public class RawAssistIStorServiceImpl extends ServiceImpl<IOStorInvMapper, IOSt
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
public void unDivStruct(Map whereJson) {
|
public void unDivStruct(Map whereJson) {
|
||||||
|
|
||||||
|
ArrayList<HashMap> rows = (ArrayList<HashMap>) whereJson.get("tableMater");
|
||||||
|
HashMap<String, String> jo = rows.get(0);
|
||||||
|
|
||||||
|
//解锁原货位点位
|
||||||
|
JSONObject unlock_map = new JSONObject();
|
||||||
|
unlock_map.put("struct_code", jo.get("struct_code"));
|
||||||
|
unlock_map.put("inv_type", null);
|
||||||
|
unlock_map.put("inv_id", null);
|
||||||
|
unlock_map.put("inv_code", null);
|
||||||
|
iStructattrService.updateStatusByCode("2",unlock_map);
|
||||||
|
|
||||||
|
// 修改分配明细表
|
||||||
|
ioStorInvDisMapper.update(new IOStorInvDis(),new LambdaUpdateWrapper<>(IOStorInvDis.class)
|
||||||
|
.set(IOStorInvDis::getSect_id,null)
|
||||||
|
.set(IOStorInvDis::getSect_code,null)
|
||||||
|
.set(IOStorInvDis::getSect_name,null)
|
||||||
|
.set(IOStorInvDis::getStruct_id,null)
|
||||||
|
.set(IOStorInvDis::getStruct_code,null)
|
||||||
|
.set(IOStorInvDis::getStruct_name,null)
|
||||||
|
.eq(IOStorInvDis::getIostorinvdis_id,jo.get("iostorinvdis_id"))
|
||||||
|
);
|
||||||
|
|
||||||
|
//维护单据明细表里 分配数量
|
||||||
|
JSONObject jsonObject = new JSONObject();
|
||||||
|
jsonObject.put("iostorinvdtl_id",jo.get("iostorinvdtl_id"));
|
||||||
|
jsonObject.put("bill_status","10");
|
||||||
|
jsonObject.put("assign_qty","0");
|
||||||
|
jsonObject.put("unassign_qty",jo.get("plan_qty"));
|
||||||
|
ioStorInvDtlMapper.updateById(jsonObject.toJavaObject(IOStorInvDtl.class));
|
||||||
|
|
||||||
|
//根据单据标识判断分配明细是否都已经分配完成
|
||||||
|
int disCount = ioStorInvDisMapper.selectCount(new LambdaQueryWrapper<>(IOStorInvDis.class)
|
||||||
|
.eq(IOStorInvDis::getIostorinv_id,jo.get("iostorinv_id"))
|
||||||
|
.isNotNull(IOStorInvDis::getStruct_code).or().ne(IOStorInvDis::getStruct_code,""));
|
||||||
|
|
||||||
|
// 根据分配货位情况 更新主表单据状态
|
||||||
|
IOStorInv ios = new IOStorInv();
|
||||||
|
ios.setIostorinv_id(jo.get("iostorinv_id"));
|
||||||
|
ios.setBill_status(disCount>0 ? "20" : "10");
|
||||||
|
ioStorInvMapper.updateById(ios);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
public void divPoint(Map whereJson) {
|
public void divPoint(Map whereJson) {
|
||||||
|
ArrayList<HashMap> rows = (ArrayList<HashMap>) whereJson.get("tableMater");
|
||||||
|
String point_code = (String) whereJson.get("point_code");
|
||||||
|
HashMap<String, String> map = rows.get(0);
|
||||||
|
|
||||||
|
//判断是否已经分配好货位
|
||||||
|
IOStorInvDis ioStorInvDis = ioStorInvDisMapper.selectOne(new LambdaQueryWrapper<>(IOStorInvDis.class)
|
||||||
|
.eq(IOStorInvDis::getIostorinvdis_id,map.get("iostorinvdis_id"))
|
||||||
|
.isNotNull(IOStorInvDis::getStruct_code).or().ne(IOStorInvDis::getStruct_code,""));
|
||||||
|
if (ObjectUtil.isEmpty(ioStorInvDis)){
|
||||||
|
throw new BadRequestException("该明细还没分配货位,请先分配货位");
|
||||||
|
}
|
||||||
|
|
||||||
|
//创建任务
|
||||||
|
JSONObject task_form = new JSONObject();
|
||||||
|
task_form.put("task_type", "STInTask");
|
||||||
|
task_form.put("TaskCode",CodeUtil.getNewCode("TASK_CODE"));
|
||||||
|
task_form.put("PickingLocation", point_code);
|
||||||
|
task_form.put("PlacedLocation", ioStorInvDis.getStruct_code());
|
||||||
|
task_form.put("vehicle_code", map.get("storagevehicle_code"));
|
||||||
|
GroupPlate groupPlate = groupPlateMapper.selectOne(new LambdaQueryWrapper<>(GroupPlate.class)
|
||||||
|
.eq(GroupPlate::getStoragevehicle_code,map.get("storagevehicle_code"))
|
||||||
|
);
|
||||||
|
task_form.put("group_id", groupPlate.getGroup_id());
|
||||||
|
|
||||||
|
StInTask stInTask = SpringContextHolder.getBean("STInTask");
|
||||||
|
|
||||||
|
String task_id = stInTask.create(task_form);
|
||||||
|
|
||||||
|
//分配明细表更新任务相关数据
|
||||||
|
IOStorInvDis dis = new IOStorInvDis();
|
||||||
|
dis.setIostorinvdis_id(map.get("iostorinvdis_id"));
|
||||||
|
dis.setWork_status("01");
|
||||||
|
dis.setTask_id(task_id);
|
||||||
|
dis.setPoint_code(point_code);
|
||||||
|
ioStorInvDisMapper.updateById(dis);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -620,7 +603,31 @@ public class RawAssistIStorServiceImpl extends ServiceImpl<IOStorInvMapper, IOSt
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
public void confirm(Map whereJson) {
|
public void confirm(Map whereJson) {
|
||||||
|
IOStorInv ioStorInv = ioStorInvMapper.selectOne(new LambdaQueryWrapper<>(IOStorInv.class)
|
||||||
|
.eq(IOStorInv::getIostorinv_id,whereJson.get("iostorinv_id"))
|
||||||
|
);
|
||||||
|
|
||||||
|
if (ObjectUtil.isNotEmpty(ioStorInv) && !"20".equals(ioStorInv.getBill_status()) && !"30".equals(ioStorInv.getBill_status())){
|
||||||
|
throw new BadRequestException("主表状态必须为分配中、分配完!");
|
||||||
|
}
|
||||||
|
|
||||||
|
// 分配明细中 任务状态必须全部完成
|
||||||
|
int count = ioStorInvDisMapper.selectCount(new LambdaQueryWrapper<>(IOStorInvDis.class)
|
||||||
|
.eq(IOStorInvDis::getIostorinv_id,whereJson.get("iostorinv_id"))
|
||||||
|
.lt(IOStorInvDis::getWork_status,"99")
|
||||||
|
);
|
||||||
|
if (count > 0){
|
||||||
|
throw new BadRequestException("存在未完成的作业");
|
||||||
|
}
|
||||||
|
|
||||||
|
//将明细全部变成99
|
||||||
|
ioStorInvDtlMapper.update(new IOStorInvDtl(),new LambdaUpdateWrapper<>(IOStorInvDtl.class)
|
||||||
|
.set(IOStorInvDtl::getBill_status,"99")
|
||||||
|
.eq(IOStorInvDtl::getIostorinv_id,whereJson.get("iostorinv_id"))
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -632,8 +639,8 @@ public class RawAssistIStorServiceImpl extends ServiceImpl<IOStorInvMapper, IOSt
|
|||||||
@Override
|
@Override
|
||||||
public List<IOStorInvDisDto> getDisDtl(Map whereJson) {
|
public List<IOStorInvDisDto> getDisDtl(Map whereJson) {
|
||||||
//查询该明细下的所有入库分配载具明细
|
//查询该明细下的所有入库分配载具明细
|
||||||
String iostorinv_id = (String) whereJson.get("iostorinv_id");
|
String iostorinvdtl_id = (String) whereJson.get("iostorinvdtl_id");
|
||||||
return ioStorInvDisMapper.queryInBillDisDtlByIosId(iostorinv_id);
|
return ioStorInvDisMapper.queryInBillDisDtlByIosId(iostorinvdtl_id);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -645,25 +652,25 @@ public class RawAssistIStorServiceImpl extends ServiceImpl<IOStorInvMapper, IOSt
|
|||||||
public Structattr autoDis(JSONObject whereJson) {
|
public Structattr autoDis(JSONObject whereJson) {
|
||||||
String sect_id = whereJson.getString("sect_id");
|
String sect_id = whereJson.getString("sect_id");
|
||||||
String storagevehicle_code = whereJson.getString("storagevehicle_code");
|
String storagevehicle_code = whereJson.getString("storagevehicle_code");
|
||||||
// 过滤没有任务的仓位号
|
// 查询没有任务的仓位号
|
||||||
List<Structattr> structattrList = iStructattrService.list(new LambdaQueryWrapper<>(Structattr.class)
|
List<Structattr> structattrList = iStructattrService.list(new LambdaQueryWrapper<>(Structattr.class)
|
||||||
.eq(Structattr::getSect_id,sect_id)
|
.eq(Structattr::getSect_id,sect_id)
|
||||||
.eq(Structattr::getLock_type,"00")
|
.eq(Structattr::getLock_type,"00")
|
||||||
);
|
);
|
||||||
MdPbStoragevehicleinfo mdPbStoragevehicleinfo = mdPbStoragevehicleinfoMapper.selectOne(new LambdaQueryWrapper<>(MdPbStoragevehicleinfo.class)
|
|
||||||
.eq(MdPbStoragevehicleinfo::getStoragevehicle_code,storagevehicle_code)
|
|
||||||
);
|
|
||||||
if (ObjectUtil.isEmpty(structattrList)){
|
if (ObjectUtil.isEmpty(structattrList)){
|
||||||
throw new BadRequestException("该库区没有仓位");
|
throw new BadRequestException("该库区没有仓位");
|
||||||
}
|
}
|
||||||
|
MdPbStoragevehicleinfo mdPbStoragevehicleinfo = mdPbStoragevehicleinfoMapper.selectOne(new LambdaQueryWrapper<>(MdPbStoragevehicleinfo.class)
|
||||||
|
.eq(MdPbStoragevehicleinfo::getStoragevehicle_code,storagevehicle_code)
|
||||||
|
);
|
||||||
if (ObjectUtil.isEmpty(mdPbStoragevehicleinfo)){
|
if (ObjectUtil.isEmpty(mdPbStoragevehicleinfo)){
|
||||||
throw new BadRequestException("没有该载具号信息");
|
throw new BadRequestException("没有该载具号信息");
|
||||||
}
|
}
|
||||||
// 过滤掉不满足载具长宽高的仓位
|
// 过滤掉不满足载具长宽高的仓位
|
||||||
Structattr structattr = structattrList.stream().filter(st ->
|
Structattr structattr = structattrList.stream().filter(st ->
|
||||||
st.getWidth().compareTo(mdPbStoragevehicleinfo.getVehicle_width()) <0 &&
|
st.getWidth().compareTo(mdPbStoragevehicleinfo.getVehicle_width()) >=0 &&
|
||||||
st.getHeight().compareTo(mdPbStoragevehicleinfo.getVehicle_height()) <0 &&
|
st.getHeight().compareTo(mdPbStoragevehicleinfo.getVehicle_height()) >=0 &&
|
||||||
st.getZdepth().compareTo(mdPbStoragevehicleinfo.getVehicle_long()) <0
|
st.getZdepth().compareTo(mdPbStoragevehicleinfo.getVehicle_long()) >=0
|
||||||
).findAny().get();
|
).findAny().get();
|
||||||
|
|
||||||
if (ObjectUtil.isEmpty(structattr)){
|
if (ObjectUtil.isEmpty(structattr)){
|
||||||
|
|||||||
@@ -14,18 +14,18 @@
|
|||||||
<span class="el-dialog__title2">入库分配</span>
|
<span class="el-dialog__title2">入库分配</span>
|
||||||
<span class="crud-opts-right2">
|
<span class="crud-opts-right2">
|
||||||
<!--左侧插槽-->
|
<!--左侧插槽-->
|
||||||
<slot name="left">
|
<!-- <slot name="left">-->
|
||||||
<el-button
|
<!-- <el-button-->
|
||||||
:loading="allDivBtn"
|
<!-- :loading="allDivBtn"-->
|
||||||
class="filter-item"
|
<!-- class="filter-item"-->
|
||||||
type="primary"
|
<!-- type="primary"-->
|
||||||
icon="el-icon-plus"
|
<!-- icon="el-icon-plus"-->
|
||||||
size="mini"
|
<!-- size="mini"-->
|
||||||
@click="allDivStruct()"
|
<!-- @click="allDivStruct()"-->
|
||||||
>
|
<!-- >-->
|
||||||
全部分配
|
<!-- 全部分配-->
|
||||||
</el-button>
|
<!-- </el-button>-->
|
||||||
</slot>
|
<!-- </slot>-->
|
||||||
<el-button slot="left" type="info" @click="dialogVisible = false">关闭</el-button>
|
<el-button slot="left" type="info" @click="dialogVisible = false">关闭</el-button>
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
@@ -349,7 +349,6 @@ export default {
|
|||||||
this.crud.notify('请选择入库点', CRUD.NOTIFICATION_TYPE.INFO)
|
this.crud.notify('请选择入库点', CRUD.NOTIFICATION_TYPE.INFO)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
debugger
|
|
||||||
if (this.form.tableMater.length === 0) {
|
if (this.form.tableMater.length === 0) {
|
||||||
this.crud.notify('请先选择一条明细!', CRUD.NOTIFICATION_TYPE.INFO)
|
this.crud.notify('请先选择一条明细!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||||
return
|
return
|
||||||
@@ -364,23 +363,23 @@ export default {
|
|||||||
})
|
})
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
allDivStruct() {
|
// allDivStruct() {
|
||||||
if (!this.sect_id) {
|
// if (!this.sect_id) {
|
||||||
this.crud.notify('请先选择虚拟库区区域!', CRUD.NOTIFICATION_TYPE.INFO)
|
// this.crud.notify('请先选择虚拟库区区域!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||||
return
|
// return
|
||||||
}
|
// }
|
||||||
this.allDivBtn = true
|
// this.allDivBtn = true
|
||||||
const data = {}
|
// const data = {}
|
||||||
data.sect_id = this.sect_id
|
// data.sect_id = this.sect_id
|
||||||
data.iostorinv_id = this.openParam[0].iostorinv_id
|
// data.iostorinv_id = this.openParam[0].iostorinv_id
|
||||||
crudRawAssist.allDivStruct(data).then(res => {
|
// crudRawAssist.allDivStruct(data).then(res => {
|
||||||
crudRawAssist.getIODtl({ 'bill_code': this.openParam[0].bill_code, 'open_flag': '1' }).then(res => {
|
// crudRawAssist.getIODtl({ 'bill_code': this.openParam[0].bill_code, 'open_flag': '1' }).then(res => {
|
||||||
this.openParam = res
|
// this.openParam = res
|
||||||
})
|
// })
|
||||||
}).finally(() => {
|
// }).finally(() => {
|
||||||
this.allDivBtn = false
|
// this.allDivBtn = false
|
||||||
})
|
// })
|
||||||
},
|
// },
|
||||||
divStruct() {
|
divStruct() {
|
||||||
if (this.form.tableMater.length === 0) {
|
if (this.form.tableMater.length === 0) {
|
||||||
this.crud.notify('请先选择一条明细!', CRUD.NOTIFICATION_TYPE.INFO)
|
this.crud.notify('请先选择一条明细!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||||
|
|||||||
Reference in New Issue
Block a user