|
@@ -133,6 +133,7 @@
|
|
|
components: {
|
|
|
// CostModelXmxqWxModal
|
|
|
},
|
|
|
+ props: ['id', 'type'],
|
|
|
data () {
|
|
|
return {
|
|
|
description: '项目外协导入详情管理页面',
|
|
@@ -260,6 +261,7 @@
|
|
|
methods: {
|
|
|
// 获取页面列表
|
|
|
loadData(arg) {
|
|
|
+ this.queryParam.xiangmuId = this.id
|
|
|
if(!this.url.list){
|
|
|
this.$message.error("请设置url.list属性!")
|
|
|
return
|
|
@@ -274,6 +276,20 @@
|
|
|
if (res.success) {
|
|
|
//update-begin---author:zhangyafei Date:20201118 for:适配不分页的数据列表------------
|
|
|
this.dataSource = res.result.records||res.result;
|
|
|
+
|
|
|
+ if (this.type == 'max') {
|
|
|
+ this.columns.push({ title:'单价(最大值)', align:"center", dataIndex: 'maxDanjia', fixed: 'right' },
|
|
|
+ { title:'价格(最大值)', align:"center", dataIndex: 'maxPrice', fixed: 'right' })
|
|
|
+ }
|
|
|
+ if (this.type == 'min') {
|
|
|
+ this.columns.splice(7,0,{ title:'单价(最小值)', align:"center", dataIndex: 'minDanjia', fixed: 'right' },
|
|
|
+ { title:'价格(最小值)', align:"center", dataIndex: 'minPrice', fixed: 'right' })
|
|
|
+ }
|
|
|
+ if (this.type == 'ave') {
|
|
|
+ this.columns.splice(7,0,{ title:'单价(平均值)', align:"center", dataIndex: 'aveDanjia', fixed: 'right' },
|
|
|
+ { title:'价格(平均值)', align:"center", dataIndex: 'avePrice', fixed: 'right' })
|
|
|
+ }
|
|
|
+
|
|
|
if(res.result.total)
|
|
|
{
|
|
|
this.ipagination.total = res.result.total;
|
|
@@ -303,28 +319,28 @@
|
|
|
fieldList.push({type:'string',value:'remark',text:'描述',dictCode:''})
|
|
|
this.superFieldList = fieldList
|
|
|
},
|
|
|
- getList(id,type){
|
|
|
- this.queryParam.id = id
|
|
|
- this.loadData(1)
|
|
|
- if (type == 'max') {
|
|
|
- // this.columns.push({ title:'单价(最大值)', align:"center", dataIndex: 'maxDanjia' })
|
|
|
- // this.columns.push({ title:'价格(最大值)', align:"center", dataIndex: 'maxPrice' })
|
|
|
- this.columns.splice(7,0,{ title:'单价(最大值)', align:"center", dataIndex: 'maxDanjia' },
|
|
|
- { title:'价格(最大值)', align:"center", dataIndex: 'maxPrice' })
|
|
|
- }
|
|
|
- if (type == 'min') {
|
|
|
- // this.columns.push({ title:'单价(最小值)', align:"center", dataIndex: 'minDanjia' })
|
|
|
- // this.columns.push({ title:'价格(最小值)', align:"center", dataIndex: 'minPrice' })
|
|
|
- this.columns.splice(7,0,{ title:'单价(最小值)', align:"center", dataIndex: 'minDanjia' },
|
|
|
- { title:'价格(最小值)', align:"center", dataIndex: 'minPrice' })
|
|
|
- }
|
|
|
- if (type == 'ave') {
|
|
|
- // this.columns.push({ title:'单价(平均值)', align:"center", dataIndex: 'aveDanjia' })
|
|
|
- // this.columns.push({ title:'价格(平均值)', align:"center", dataIndex: 'avePrice' })
|
|
|
- this.columns.splice(7,0,{ title:'单价(平均值)', align:"center", dataIndex: 'aveDanjia' },
|
|
|
- { title:'价格(平均值)', align:"center", dataIndex: 'avePrice' })
|
|
|
- }
|
|
|
- }
|
|
|
+ // getList(id,type){
|
|
|
+ // this.queryParam.id = id
|
|
|
+ // this.loadData(1)
|
|
|
+ // if (type == 'max') {
|
|
|
+ // // this.columns.push({ title:'单价(最大值)', align:"center", dataIndex: 'maxDanjia' })
|
|
|
+ // // this.columns.push({ title:'价格(最大值)', align:"center", dataIndex: 'maxPrice' })
|
|
|
+ // this.columns.splice(7,0,{ title:'单价(最大值)', align:"center", dataIndex: 'maxDanjia' },
|
|
|
+ // { title:'价格(最大值)', align:"center", dataIndex: 'maxPrice' })
|
|
|
+ // }
|
|
|
+ // if (type == 'min') {
|
|
|
+ // // this.columns.push({ title:'单价(最小值)', align:"center", dataIndex: 'minDanjia' })
|
|
|
+ // // this.columns.push({ title:'价格(最小值)', align:"center", dataIndex: 'minPrice' })
|
|
|
+ // this.columns.splice(7,0,{ title:'单价(最小值)', align:"center", dataIndex: 'minDanjia' },
|
|
|
+ // { title:'价格(最小值)', align:"center", dataIndex: 'minPrice' })
|
|
|
+ // }
|
|
|
+ // if (type == 'ave') {
|
|
|
+ // // this.columns.push({ title:'单价(平均值)', align:"center", dataIndex: 'aveDanjia' })
|
|
|
+ // // this.columns.push({ title:'价格(平均值)', align:"center", dataIndex: 'avePrice' })
|
|
|
+ // this.columns.splice(7,0,{ title:'单价(平均值)', align:"center", dataIndex: 'aveDanjia' },
|
|
|
+ // { title:'价格(平均值)', align:"center", dataIndex: 'avePrice' })
|
|
|
+ // }
|
|
|
+ // }
|
|
|
}
|
|
|
}
|
|
|
</script>
|