修改bug 寄售 预验收 带票库存详情加排序

ywj_dev
wangwei 2 years ago
parent e3b110dcd7
commit b830ee1db5

@ -58,7 +58,8 @@
</el-button-group>
</el-form-item>
</el-form>
<el-table v-loading="loading" :data="list" style="width: 100%" border>
<el-table v-loading="loading" :data="list" style="width: 100%"
:default-sort="defaultSort" @sort-change="handleSortChange" border>
<el-table-column label="序号" type="index"></el-table-column>
<el-table-column
label="UDI码"
@ -106,6 +107,7 @@
prop="orderTime"
width="150"
show-overflow-tooltip
:sort-orders="['ascending', 'descending']"
></el-table-column>
</el-table>
@ -147,6 +149,7 @@ export default {
list: [],
total: 0,
loading: false,
defaultSort: {prop: 'orderTime', order: 'desc'},
};
},
methods: {
@ -176,6 +179,17 @@ export default {
this.invPreProductDetailQuery.page = val;
this.getList();
},
handleSortChange(column, prop, order) {
if (column.order === 'descending') {
this.invPreProductDetailQuery.sort = 'desc'
} else {
this.invPreProductDetailQuery.sort = 'asc'
}
this.invPreProductDetailQuery.orderBy = column.prop;
this.getList();
},
getList() {
this.loading = true;
this.invPreProductDetailQuery.relId = this.inputQuery.relId;

@ -58,7 +58,8 @@
</el-button-group>
</el-form-item>
</el-form>
<el-table v-loading="loading" :data="list" style="width: 100%">
<el-table v-loading="loading" :data="list" style="width: 100%"
:default-sort="defaultSort" @sort-change="handleSortChange" >
<el-table-column label="序号" type="index"></el-table-column>
<el-table-column
label="UDI码"
@ -106,6 +107,7 @@
prop="orderTime"
width="150"
show-overflow-tooltip
:sort-orders="['ascending', 'descending']"
></el-table-column>
</el-table>
@ -147,6 +149,7 @@ export default {
list: [],
total: 0,
loading: false,
defaultSort: {prop: 'orderTime', order: 'desc'},
};
},
methods: {
@ -176,6 +179,17 @@ export default {
this.invPreProductDetailQuery.page = val;
this.getList();
},
handleSortChange(column, prop, order) {
if (column.order === 'descending') {
this.invPreProductDetailQuery.sort = 'desc'
} else {
this.invPreProductDetailQuery.sort = 'asc'
}
this.invPreProductDetailQuery.orderBy = column.prop;
this.getList();
},
getList() {
this.loading = true;
this.invPreProductDetailQuery.relId = this.inputQuery.relId;

@ -56,7 +56,8 @@
</el-button-group>
</el-form-item>
</el-form>
<el-table v-loading="loading" :data="list" style="width: 100%" border>
<el-table v-loading="loading" :data="list" style="width: 100%" :default-sort="defaultSort"
@sort-change="handleSortChange" border>
<el-table-column label="序号" type="index"></el-table-column>
<el-table-column
label="UDI码"
@ -104,6 +105,7 @@
prop="orderTime"
width="150"
show-overflow-tooltip
:sort-orders="['ascending', 'descending']"
></el-table-column>
</el-table>
<pagination
@ -144,6 +146,7 @@ export default {
list: [],
total: 0,
loading: false,
defaultSort: {prop: 'orderTime', order: 'desc'},
};
},
methods: {
@ -173,6 +176,16 @@ export default {
this.invProductDetailQuery.page = val;
this.getList();
},
handleSortChange(column, prop, order) {
if (column.order === 'descending') {
this.invProductDetailQuery.sort = 'desc'
} else {
this.invProductDetailQuery.sort = 'asc'
}
this.invProductDetailQuery.orderBy = column.prop;
this.getList();
},
getList() {
this.loading = true;
this.invProductDetailQuery.relId = this.inputQuery.relId;

@ -305,6 +305,11 @@ export default {
getInvListByUser(query)
.then((response) => {
this.invList = response.data || [];
for(var i=0;i< this.invList.length;i++){
if(this.invList[i].advanceType == 2){
this.filterQuery.invCode=this.invList[i].code;
}
}
this.getList();
})
.catch(() => {
@ -389,7 +394,7 @@ export default {
}
this.findMethod();
this.getInvList();
this.getList();
// this.getList();
},
};
</script>

@ -302,6 +302,12 @@ export default {
getInvListByUser(query)
.then((response) => {
this.invList = response.data || [];
for(var i=0;i< this.invList.length;i++){
if(this.invList[i].advanceType == 3){
this.filterQuery.invCode=this.invList[i].code;
}
}
this.getList();
})
.catch(() => {
@ -386,7 +392,7 @@ export default {
}
this.findMethod();
this.getInvList();
this.getList();
//this.getList();
},
};
</script>

@ -22,14 +22,14 @@
<el-col :span="8">
<el-form-item label="采购部门">
<el-select
v-model="filterQuery.invCode"
v-model="filterQuery.deptCode"
placeholder="请选择收货仓库"
style="width: 90%"
placeholder="请选择采购部门"
clearable
>
<el-option
v-for="item in invList"
:key="item.name"
v-for="item in deptList"
:key="item.code"
:label="item.name"
:value="item.code"
>
@ -41,14 +41,14 @@
<el-col :span="8">
<el-form-item label="收货仓库">
<el-select
v-model="filterQuery.deptCode"
placeholder="请选择收货仓库"
v-model="filterQuery.invCode"
style="width: 90%"
placeholder="请选择采购部门"
clearable
>
<el-option
v-for="item in deptList"
:key="item.code"
v-for="item in invList"
:key="item.name"
:label="item.name"
:value="item.code"
>

Loading…
Cancel
Save