Commit 2f0aa6b0 authored by cat's avatar cat

Merge remote-tracking branch 'origin/project9-8' into project9-8

parents 7e1cbb67 c3e65853
......@@ -22,6 +22,16 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="盘点状态" prop="status">
<el-select v-model="queryParams.status" placeholder="请选择" clearable>
<el-option
v-for="item in options"
:key="item.value"
:label="item.label"
:value="item.value">
</el-option>
</el-select>
</el-form-item>
<el-form-item>
<el-button type="primary" style="padding: 8px 7px;" size="small" icon="el-icon-search" @click="handleQuery">查询</el-button>
<el-button style="padding: 8px 7px;" icon="el-icon-refresh" size="small" @click="resetQuery">重置</el-button>
......@@ -112,6 +122,15 @@ export default {
name: 'Index',
data() {
return {
// 状态下拉框
options: [{
value: 1,
label: '已盘点'
},{
value: 0,
label: '未盘点'
},
],
// TODO: 表单里的单项详情参数
singleDetails: {
lot: '',
......@@ -173,22 +192,31 @@ export default {
methods: {
// TODO: 获取所选行详情信息操作
handleDetail(row) {
this.singleDetails = this.formReset
this.singleDetails = row
this.title = '详情信息'
this.openDetails = !this.openDetails
},
/** 查询角色列表 */
getList() {
this.loading = true
listdevice(this.queryParams).then(
response => {
console.log('list',response)
this.equipmentList = response.rows
this.total = response.total
this.loading = false
}
)
// 去除字段默认为0导致0对应的未盘点无法使用问题
let flag = 0;
this.loading = true;
if (this.queryParams.status === undefined || this.queryParams.status === '') {
flag = 1;
}
if (flag === 1) {
this.queryParams.status = -1
}
listdevice(this.queryParams).then(response => {
console.log('list',response)
this.equipmentList = response.rows
this.total = response.total
this.loading = false
})
if (flag == 1) {
this.queryParams.status = undefined
flag = 0;
}
},
// 取消按钮
cancel() {
......
......@@ -22,6 +22,16 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="盘点状态" prop="status">
<el-select v-model="queryParams.status" placeholder="请选择" clearable>
<el-option
v-for="item in options"
:key="item.value"
:label="item.label"
:value="item.value">
</el-option>
</el-select>
</el-form-item>
<el-form-item>
<el-button type="primary" style="padding: 8px 7px;" size="small" icon="el-icon-search" @click="handleQuery">查询</el-button>
<el-button style="padding: 8px 7px;" icon="el-icon-refresh" size="small" @click="resetQuery">重置</el-button>
......@@ -112,6 +122,15 @@ export default {
name: 'Index',
data() {
return {
// 状态下拉框
options: [{
value: 0,
label: '未盘点'
}, {
value: 1,
label: '已盘点'
},
],
// TODO: 表单里的单项详情参数
singleDetails: {
lot: '',
......@@ -173,22 +192,31 @@ export default {
methods: {
// TODO: 获取所选行详情信息操作
handleDetail(row) {
this.singleDetails = this.formReset
this.singleDetails = row
this.title = '详情信息'
this.openDetails = !this.openDetails
},
/** 查询角色列表 */
getList() {
this.loading = true
listdevice(this.queryParams).then(
response => {
// 去除字段默认为0导致0对应的未盘点无法使用问题
let flag = 0;
this.loading = true;
if (this.queryParams.status === undefined || this.queryParams.status === '') {
flag = 1;
}
if (flag === 1) {
this.queryParams.status = -1
}
listdevice(this.queryParams).then(response => {
console.log('list',response)
this.equipmentList = response.rows
this.total = response.total
this.loading = false
}
)
})
if (flag == 1) {
this.queryParams.status = undefined
flag = 0;
}
},
// 取消按钮
cancel() {
......
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