Browse Source

opt:优化修改仓位管理功能

master
zds 1 month ago
parent
commit
08bf09b36a
  1. 110
      lms/nladmin-system/src/main/java/org/nl/wms/basedata/master/structattr/service/dao/Structattr.java
  2. 6
      lms/nladmin-system/src/main/java/org/nl/wms/basedata/master/structattr/service/dao/mapper/StructattrMapper.xml
  3. 100
      lms/nladmin-system/src/main/java/org/nl/wms/basedata/master/structattr/service/dto/StructattrDto.java
  4. 1
      lms/nladmin-system/src/main/java/org/nl/wms/basedata/master/structattr/service/impl/StructattrServiceImpl.java
  5. BIN
      lms/nladmin-system/src/main/java/org/nl/wms/basedata/st/wql/stivt.xls
  6. 3
      lms/nladmin-ui/src/views/wms/basedata/st/ivt/index.vue
  7. 22
      lms/nladmin-ui/src/views/wms/basedata/st/struct/OneCreateDialog.vue
  8. 132
      lms/nladmin-ui/src/views/wms/basedata/st/struct/index.vue

110
lms/nladmin-system/src/main/java/org/nl/wms/basedata/master/structattr/service/dao/Structattr.java

@ -68,54 +68,52 @@ public class Structattr implements Serializable {
private String stor_name;
/**
* 仓库类型
* 是否临时仓位
*/
private String stor_type;
private String is_tempstruct;
/**
* 容量
*
*/
private BigDecimal capacity;
private String row_num;
/**
* 宽度
*
*/
private BigDecimal width;
private String col_num;
/**
* 高度
*
*/
private BigDecimal height;
private String layer_num;
/**
* 深度
*
*/
private BigDecimal zdepth;
private String block_num;
/**
* 承受重量
* 入库顺序
*/
private BigDecimal weight;
private String in_order_seq;
/**
* 起始X坐标
* 出库顺序
*/
private BigDecimal xqty;
private String out_order_seq;
/**
* 起始Y坐标
* 入空载具顺序
*/
private BigDecimal yqty;
private String in_empty_seq;
/**
* 起始Z坐标
* 出空载具顺序
*/
private BigDecimal zqty;
private String out_empty_seq;
/**
* 是否临时仓位
* 放置类型
*/
private String is_tempstruct;
private String placement_type;
/**
* 创建人
@ -153,64 +151,58 @@ public class Structattr implements Serializable {
private String is_delete;
/**
* 背景色
*/
private String back_ground_color;
/**
* 前景色
* 是否启用
*/
private String front_ground_color;
private String is_used;
/**
* 背景图片
* 存储载具号
*/
private String back_ground_pic;
private String storagevehicle_code;
/**
* 字体显示方向
* 是否空载具
*/
private String font_direction_scode;
private String is_emptyvehicle;
/**
* 是否启用
* 载具数量
*/
private String is_used;
private BigDecimal storagevehicle_qty;
/**
* 是否判断高度
* 锁定类型
*/
private String is_zdepth;
private String lock_type;
/**
* 存储载具标识
* 锁定任务类型
*/
private Long storagevehicle_id;
private String taskdtl_type;
/**
* 存储载具号
* 锁定任务明细标识
*/
private String storagevehicle_code;
private String taskdtl_id;
/**
* 存储载具类型
* 锁定任务编码
*/
private String storagevehicle_type;
private String task_code;
/**
* 是否空载具
* 锁定单据类型
*/
private String is_emptyvehicle;
private String inv_type;
/**
* 载具数量
* 锁定单据标识
*/
private BigDecimal storagevehicle_qty;
private String inv_id;
/**
* 锁定类型
* 锁定单据编码
*/
private String lock_type;
private String inv_code;
/**
* 物料高度类型
@ -228,15 +220,9 @@ public class Structattr implements Serializable {
private String remark;
/**
* 放置类型
*/
private String placement_type;
/**
*
*/
private String block_num;
/**
*
* 存储载具类型
*/
private String layer_num;
private String storagevehicle_type;
}

6
lms/nladmin-system/src/main/java/org/nl/wms/basedata/master/structattr/service/dao/mapper/StructattrMapper.xml

@ -9,7 +9,7 @@
where sect.sect_type_attr = '09'
</select>
<select id="selectStructByCodesFsAnNum" resultType="com.alibaba.fastjson.JSONArray" parameterType="java.util.List">
<select id="selectStructByCodesFsAnNum" resultType="com.alibaba.fastjson.JSONObject" parameterType="java.util.List">
SELECT
attr.*,
sub.package_box_sn,
@ -30,7 +30,7 @@
</foreach>
</if>
</select>
<select id="queryAll" resultType="com.alibaba.fastjson.JSONArray" parameterType="java.lang.String">
<select id="queryAll" resultType="com.alibaba.fastjson.JSONObject" parameterType="java.lang.String">
SELECT attr.*,
sub.package_box_sn,
sub.quanlity_in_box,
@ -40,7 +40,7 @@
sub.product_description,
sub.net_weight
FROM st_ivt_structattr attr
LEFT JOIN pdm_bi_subpackagerelation sub ON sub.package_box_sn = attr.storagevehicle_code
LEFT JOIN pdm_bi_subpackagerelation sub ON sub.package_box_sn = attr.storagevehicle_code
WHERE attr.struct_id = #{struct_id}
</select>
</mapper>

100
lms/nladmin-system/src/main/java/org/nl/wms/basedata/master/structattr/service/dto/StructattrDto.java

@ -68,54 +68,52 @@ public class StructattrDto implements Serializable {
private String stor_name;
/**
* 仓库类型
* 是否临时仓位
*/
private String stor_type;
private String is_tempstruct;
/**
* 容量
*
*/
private BigDecimal capacity;
private String row_num;
/**
* 宽度
*
*/
private BigDecimal width;
private String col_num;
/**
* 高度
*
*/
private BigDecimal height;
private String layer_num;
/**
* 深度
*
*/
private BigDecimal zdepth;
private String block_num;
/**
* 承受重量
* 入库顺序
*/
private BigDecimal weight;
private String in_order_seq;
/**
* 起始X坐标
* 出库顺序
*/
private BigDecimal xqty;
private String out_order_seq;
/**
* 起始Y坐标
* 入空载具顺序
*/
private BigDecimal yqty;
private String in_empty_seq;
/**
* 起始Z坐标
* 出空载具顺序
*/
private BigDecimal zqty;
private String out_empty_seq;
/**
* 是否临时仓位
* 放置类型
*/
private String is_tempstruct;
private String placement_type;
/**
* 创建人
@ -153,64 +151,58 @@ public class StructattrDto implements Serializable {
private String is_delete;
/**
* 背景色
*/
private String back_ground_color;
/**
* 前景色
* 是否启用
*/
private String front_ground_color;
private String is_used;
/**
* 背景图片
* 存储载具号
*/
private String back_ground_pic;
private String storagevehicle_code;
/**
* 字体显示方向
* 是否空载具
*/
private String font_direction_scode;
private String is_emptyvehicle;
/**
* 是否启用
* 载具数量
*/
private String is_used;
private BigDecimal storagevehicle_qty;
/**
* 是否判断高度
* 锁定类型
*/
private String is_zdepth;
private String lock_type;
/**
* 存储载具标识
* 锁定任务类型
*/
private Long storagevehicle_id;
private String taskdtl_type;
/**
* 存储载具号
* 锁定任务明细标识
*/
private String storagevehicle_code;
private String taskdtl_id;
/**
* 存储载具类型
* 锁定任务编码
*/
private String storagevehicle_type;
private String task_code;
/**
* 是否空载具
* 锁定单据类型
*/
private String is_emptyvehicle;
private String inv_type;
/**
* 载具数量
* 锁定单据标识
*/
private BigDecimal storagevehicle_qty;
private String inv_id;
/**
* 锁定类型
* 锁定单据编码
*/
private String lock_type;
private String inv_code;
/**
* 物料高度类型
@ -228,7 +220,7 @@ public class StructattrDto implements Serializable {
private String remark;
/**
* 放置类型
* 存储载具类型
*/
private String placement_type;
private String storagevehicle_type;
}

1
lms/nladmin-system/src/main/java/org/nl/wms/basedata/master/structattr/service/impl/StructattrServiceImpl.java

@ -201,7 +201,6 @@ public class StructattrServiceImpl extends ServiceImpl<StructattrMapper, Structa
throw new BadRequestException("未发现载具号为【" + storagevehicle_code + "】的载具信息");
}
dto.setStoragevehicle_id(obj.getLong("storagevehicle_id"));
dto.setStoragevehicle_type(obj.getString("storagevehicle_type"));
}
structattrMapper.insert(BeanUtil.copyProperties(dto, Structattr.class));

BIN
lms/nladmin-system/src/main/java/org/nl/wms/basedata/st/wql/stivt.xls

Binary file not shown.

3
lms/nladmin-ui/src/views/wms/basedata/st/ivt/index.vue

@ -326,7 +326,6 @@ import crudStructivt from '@/views/wms/basedata/st/ivt/structivt'
import CRUD, { presenter, header, form, crud } from '@crud/crud'
import rrOperation from '@crud/RR.operation'
import crudOperation from '@crud/CRUD.operation'
import udOperation from '@crud/UD.operation'
import pagination from '@crud/Pagination'
import crudUserStor from '@/views/wms/basedata/st/userStor/userStor'
import UploadDialog from '@/views/wms/basedata/st/ivt/UploadDialog'
@ -355,7 +354,7 @@ const defaultForm = {
export default {
name: 'Structivt',
dicts: ['ST_QUALITY_SCODE', 'product_area', 'IS_OR_NOT', 'SUB_TYPE'],
components: { pagination, crudOperation, rrOperation, udOperation, UploadDialog },
components: { pagination, crudOperation, rrOperation, UploadDialog },
mixins: [presenter(), header(), form(defaultForm), crud()],
cruds() {
return CRUD({

22
lms/nladmin-ui/src/views/wms/basedata/st/struct/OneCreateDialog.vue

@ -24,13 +24,6 @@
/>
</el-form-item>
</el-col>
<!-- <el-col :span="8">
<el-form-item label="仓位前缀:">
<el-input v-model="formMst.prefix" placeholder="如:91、B21、C31等" size="mini" style="width: 210px" />
</el-form-item>
</el-col>-->
<el-col :span="8">
<el-form-item label="生成数量:">
<el-input-number :precision="0" :step="1" :min="1" :max="90000" v-model="formMst.num" size="mini" :controls="false" style="width: 210px" />
@ -61,7 +54,7 @@ import crudUserStor from '@/views/wms/basedata/st/userStor/userStor'
import crudStructattr from '@/views/wms/basedata/st/struct/structattr'
export default {
name: 'SunShowDialog',
name: 'OneCreateDialog',
mixins: [crud()],
props: {
dialogShow: {
@ -138,20 +131,7 @@ export default {
}).catch(() => {
this.loadingBut = false
})
},
blurQuery() {
this.loadingBut = true
crudStructattr.blurQuery({ 'prefix': this.formMst.prefix }).then(res => {
this.crud.notify('可使用此前缀!', CRUD.NOTIFICATION_TYPE.SUCCESS)
this.loadingBut = false
}).catch(() => {
this.loadingBut = false
})
}
}
}
</script>
<style scoped>
</style>

132
lms/nladmin-ui/src/views/wms/basedata/st/struct/index.vue

@ -88,7 +88,7 @@
inactive-value="1"
active-color="#C0CCDA"
inactive-color="#409EFF"
@change="hand"
@change="crud.toQuery"
/>
</el-form-item>
<rrOperation />
@ -232,39 +232,6 @@
</el-row>
<el-row :gutter="20">
<el-col :span="12">
<el-form-item label="容量" prop="capacity">
<label slot="label">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:</label>
<el-input v-model="form.capacity" style="width: 200px;" />
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="承受重量" prop="weight">
<el-input v-model="form.weight" style="width: 200px;" />
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20">
<el-col :span="12">
<el-form-item label="宽度" prop="width">
<label slot="label">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:</label>
<el-input v-model="form.width" style="width: 200px;" />
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="深度" prop="zdepth">
<label slot="label">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:</label>
<el-input v-model="form.zdepth" style="width: 200px;" />
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20">
<el-col :span="12">
<el-form-item label="高度" prop="height">
<label slot="label">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:</label>
<el-input v-model="form.height" style="width: 200px;" />
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="放置类型" prop="placement_type">
<el-select
@ -319,13 +286,10 @@
style="width: 100%;"
@selection-change="crud.selectionChangeHandler"
>
<!--
<el-table-column type="selection" width="55" />
-->
<el-table-column prop="struct_code" label="仓位编码" :min-width="flexWidth('struct_code',crud.data,'仓位编码')" />
<el-table-column prop="struct_name" label="仓位名称" :min-width="flexWidth('struct_name',crud.data,'仓位名称')" />
<el-table-column prop="simple_name" label="仓位简称" :min-width="flexWidth('simple_name',crud.data,'仓位简称')" />
<el-table-column prop="sect_name" label="所属库区" width="150" />
<el-table-column prop="sect_name" label="所属库区" width="150" :min-width="flexWidth('sect_name',crud.data,'所属库区')" />
<el-table-column prop="stor_name" label="所属仓库" width="150" />
<el-table-column prop="storagevehicle_code" label="载具号" :min-width="flexWidth('storagevehicle_code',crud.data,'载具号')" />
<el-table-column prop="lock_type" label="锁定类型" min-width="120" show-overflow-tooltip>
@ -333,13 +297,11 @@
{{ dict.label.d_lock_type[scope.row.lock_type] }}
</template>
</el-table-column>
<el-table-column prop="sect_name" label="库区名称" :min-width="flexWidth('sect_name',crud.data,'库区名称')" />
<el-table-column prop="placement_type" label="放置类型" min-width="120" show-overflow-tooltip>
<template slot-scope="scope">
{{ dict.label.placement_type[scope.row.placement_type] }}
</template>
</el-table-column>
<el-table-column prop="zdepth" label="深度" min-width="120" show-overflow-tooltip :formatter="zdepthType" />
<el-table-column prop="storagevehicle_type" label="托盘类型" min-width="120" show-overflow-tooltip :formatter="formattTwo" />
<el-table-column label="是否启用" align="center" prop="is_used">
<template slot-scope="scope">
@ -386,7 +348,8 @@ import rrOperation from '@crud/RR.operation'
import crudOperation from '@crud/CRUD.operation'
import udOperation from '@crud/UD.operation'
import pagination from '@crud/Pagination'
/* import checkoutbill from "@/api/wms/st/core/outbill/checkoutbill";*/
import UploadDialog from '@/views/wms/basedata/st/struct/OneCreateDialog'
import crudUserStor from '@/views/wms/basedata/st/userStor/userStor'
const defaultForm = {
struct_id: null,
@ -401,33 +364,13 @@ const defaultForm = {
stor_code: null,
stor_name: null,
stor_type: null,
capacity: null,
width: null,
height: null,
zdepth: null,
weight: null,
xqty: null,
yqty: null,
zqty: null,
is_tempstruct: '0',
create_id: null,
create_name: null,
create_time: null,
update_optid: null,
update_optname: null,
update_time: null,
placement_type: null,
is_delete: null,
back_ground_color: null,
front_ground_color: null,
back_ground_pic: null,
font_direction_scode: null,
is_used: null,
is_zdepth: null,
storagevehicle_id: null,
storagevehicle_code: null,
storagevehicle_type: null,
is_emptyvehicle: null,
storagevehicle_qty: null,
lock_type: null,
material_height_type: null,
ext_id: null,
@ -436,7 +379,7 @@ const defaultForm = {
export default {
name: 'Structattr',
dicts: ['ST_HEIGHT_TYPE', 'is_used', 'd_lock_type', 'SCH_TASK_TYPE_DTL', 'placement_type', 'zdepth', 'storagevehicle_type'],
components: { pagination, crudOperation, rrOperation, udOperation },
components: { pagination, crudOperation, rrOperation, udOperation, UploadDialog },
mixins: [presenter(), header(), form(defaultForm), crud()],
cruds() {
return CRUD({
@ -448,24 +391,15 @@ export default {
})
},
data() {
const numberOne = (rule, value, callback) => {
const numReg = /^[+]{0,1}(\d+)$|^[+]{0,1}(\d+\.\d+)$/
const numRe = new RegExp(numReg)
if (value) {
if (!numRe.test(value)) {
callback(new Error('只能输入数字'))
} else {
callback()
}
} else {
callback()
}
}
return {
openOneCreateDialog: false,
sects: [],
invtypelist: [],
permission: {},
permission: {
add: ['admin', 'structattr:add'],
edit: ['admin', 'structattr:edit'],
del: ['admin', 'structattr:del']
},
layerList: [
{ 'label': '1层', 'value': '1' },
{ 'label': '2层', 'value': '2' },
@ -509,26 +443,6 @@ export default {
stor_id: [
{ required: true, message: '仓库标识不能为空', trigger: 'blur' }
],
capacity: [
{ required: false, message: '不能为空', trigger: 'blur' },
{ validator: numberOne }
],
weight: [
{ required: false, message: '不能为空', trigger: 'blur' },
{ validator: numberOne }
],
width: [
{ required: false, message: '不能为空', trigger: 'blur' },
{ validator: numberOne }
],
height: [
{ required: false, message: '不能为空', trigger: 'blur' },
{ validator: numberOne }
],
zdepth: [
{ required: false, message: '不能为空', trigger: 'blur' },
{ validator: numberOne }
],
material_height_type: [
{ required: true, message: '物料高度类型不能为空', trigger: 'blur' }
]
@ -615,11 +529,14 @@ export default {
}
this.formMst.is_used = '1'
crudStructattr.tunConfirm(this.formMst).then(res => {
this.$refs['form2'].resetFields()
this.dialogVisible2 = false
this.crud.toQuery()
close()
})
},
close() {
this.$refs['form2'].resetFields()
this.dialogVisible2 = false
this.crud.toQuery()
},
tunClose() {
if (!this.formMst.block_num) {
this.crud.notify('请选择巷道!', CRUD.NOTIFICATION_TYPE.INFO)
@ -627,22 +544,9 @@ export default {
}
this.formMst.is_used = '0'
crudStructattr.tunConfirm(this.formMst).then(res => {
this.$refs['form2'].resetFields()
this.dialogVisible2 = false
this.crud.toQuery()
close()
})
},
zdepthType(row) {
if (row.zdepth === '1') {
return '浅货位'
}
if (row.zdepth === '2') {
return '深货位'
}
if (row.zdepth === '3') {
return '无'
}
},
formattTwo(row) {
if (row.storagevehicle_type === '1') {
return '小托盘'

Loading…
Cancel
Save