Commit 4d9b4de9 authored by CenXinYi's avatar CenXinYi

实现样品库出入记录排序功能

Signed-off-by: 's avatarCenXinYi <2810162984@qq.com>
parent afc9b993
......@@ -432,7 +432,6 @@ export default {
/** TODO:查询工序库的出入库记录列表 */
getList() {
this.loading = true
console.log('66666')
listLog(this.queryParams, this.addDateRange(this.queryEntity, this.dateRange)).then(response => {
this.inventoryRecordList = response.rows
this.total = response.total
......
......@@ -87,6 +87,7 @@
:key="queryParams.rows"
:all-table-arguments="allTableArguments"
@handle-detail="handleDetail"
@change-table-sort="changeTableSort"
/>
</transition>
<!--TODO: 分页组件-->
......@@ -118,8 +119,8 @@
<el-form-item label="lot:" prop="lot">
<el-input v-model.trim="singleDetails.lot" :readonly="isReadOnly" />
</el-form-item>
<el-form-item label="plocation:" prop="plocation">
<el-input v-model.trim="singleDetails.plocation" :readonly="isReadOnly" />
<el-form-item label="unit:" prop="unit">
<el-input v-model.trim="singleDetails.unit" :readonly="isReadOnly" />
</el-form-item>
</el-col>
......@@ -127,8 +128,11 @@
<el-form-item label="库类型:" prop="ptype">
{{ selectedPtype(singleDetails.ptype) }}
</el-form-item>
<el-form-item label="库状态:" prop="poperate">
{{ selectedPoperate(singleDetails.poperate) }}
<el-form-item label="qty:" prop="qty">
{{ selectedPtype(singleDetails.qty) }}
</el-form-item>
<el-form-item label="memo:" prop="memo">
<el-input v-model.trim="singleDetails.memo" :readonly="isReadOnly" />
</el-form-item>
</el-col>
</el-row>
......@@ -234,6 +238,9 @@ export default {
rows: 10
},
queryEntity: {
// TODO: 0表示倒序排序,1表示顺序排序
tableSortMark: 0,
entity: {
// TODO: 设备编码
pn: '',
......@@ -304,6 +311,7 @@ export default {
{
time: true,
prop: 'createDate',
sortable: 'custom',
label: '操作时间',
align: 'center'
},
......@@ -430,6 +438,18 @@ export default {
this.activateAbandonedState = false
this.singleLogIdAndFqYs = {}
},
/* TODO: 进行排序 */
changeTableSort: function(val) {
console.log('column', val)
// TODO:按照降序排序
if (val.order === 'descending') {
this.queryEntity.tableSortMark = 0
} else {
// TODO:按照升序排序
this.queryEntity.tableSortMark = 1
}
this.getList()
},
/* TODO: 获取详情信息*/
handleDetail: function(row) {
/* TODO: 如果库状态为‘废弃’,即为‘4’时,则可以进入 */
......@@ -438,6 +458,7 @@ export default {
} else {
/* TODO: 设置单项详情的查询的条件 */
this.singleLogIdAndFqYs['businessId'] = row.businessId
this.singleLogIdAndFqYs['fqYs'] = row.fqYs
/* TODO: 进行查询,如果返回的code为200,则表示返回的值成功 */
findSingleLogDetail(this.singleLogIdAndFqYs).then(
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment