Commit 92de6a43 authored by 15008242619's avatar 15008242619 Committed by jingnan

工作包页面优化

parent 49d3369b
...@@ -135,7 +135,7 @@ ...@@ -135,7 +135,7 @@
> >
<el-option v-for="(item, i) in wpOptions" :key="i" :label="item.name" :value="item.id" /> <el-option v-for="(item, i) in wpOptions" :key="i" :label="item.name" :value="item.id" />
</el-select> </el-select>
<span v-else>{{ $utils.getParamsFromLists(wpOptions, 'id', scope.row[scope.column.property], 'name') }}</span> <span v-else>{{ $utils.getParamsFromLists(wpDictionary, 'id', scope.row[scope.column.property], 'name') }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
...@@ -306,8 +306,10 @@ export default { ...@@ -306,8 +306,10 @@ export default {
total: 0, total: 0,
pageSizes: [5, 10, 20, 50] pageSizes: [5, 10, 20, 50]
}, },
// 工作包数据 // 工作包数据(有效)
wpOptions: [], wpOptions: [],
// 工作包数据字典(包含有效和无效)
wpDictionary: [],
// 加载中 // 加载中
loading: false, loading: false,
curRowId: null, curRowId: null,
...@@ -376,10 +378,6 @@ export default { ...@@ -376,10 +378,6 @@ export default {
'children': [], 'children': [],
'items': [ 'items': [
{ {
'fieldName': 'workState',
'operator': 'EQ',
'value': 'Y'
}, {
'fieldName': 'sorties', 'fieldName': 'sorties',
'operator': 'EQ', 'operator': 'EQ',
'value': data.serialNo 'value': data.serialNo
...@@ -401,10 +399,16 @@ export default { ...@@ -401,10 +399,16 @@ export default {
} }
post('/ExtWorkPackage/search', params).then(res => { post('/ExtWorkPackage/search', params).then(res => {
this.wpOptions = res.items.content.map(row => { this.wpOptions = res.items.content.map(row => {
return { if (row.workState === 'Y') {
this.wpOptions.push({
name: row.name, name: row.name,
id: row.id id: row.id
})
} }
this.wpDictionary.push({
name: row.name,
id: row.id
})
}) })
}) })
}, },
......
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