Commit b3c01c31 authored by 远方不远's avatar 远方不远
parents d8fa6a21 b1fab10a
......@@ -281,6 +281,7 @@ export default {
<style lang="scss" scoped>
.part-container{
min-width: 1300px;
padding: 0;
}
.part-main{
......
......@@ -49,9 +49,9 @@ export default {
defaultSort: {prop: 'projectTotalInvestment', order: 'descending'},
forData: [
{label: '项目名称', prop: 'projectName', minWidth: '300', slot: true},
{label: '项目总投资(亿元)', prop: 'projectTotalInvestment', sortable: 'custom', descending: '1', ascending: '2', width: '160'},
{label: '项目资本金(亿元)', prop: 'projectCapital', sortable: 'custom', descending: '17', ascending: '18', width: '160'},
{label: '专项债用作资本金(亿元)', prop: 'specialBondCapital', sortable: 'custom', descending: '19', ascending: '20', width: '200'}
{label: '项目总投资(元)', prop: 'projectTotalInvestment', sortable: 'custom', descending: '1', ascending: '2', width: '160'},
{label: '项目资本金(元)', prop: 'projectCapital', sortable: 'custom', descending: '17', ascending: '18', width: '160'},
{label: '专项债用作资本金(元)', prop: 'specialBondCapital', sortable: 'custom', descending: '19', ascending: '20', width: '200'}
],
formData: [
{ type: 3, fieldName: 'keys', value: '', placeholder: '输入项目名称关键词查询', options: [], width: 220},
......
......@@ -28,7 +28,7 @@
<el-table-column
prop="percent"
align="right"
label="占比">
label="占比(%)">
</el-table-column>
<template slot="empty">
<div style="padding: 30px 0">
......@@ -81,7 +81,7 @@ export default {
if(res.code==200 && res.data){
let data = res.data, totalVal = data.map(item => item.value).reduce((prev, cur) => prev + cur)
this.viewData = data.map(item => {
let it = {name:item.name, value:item.value, percent:parseFloat(Number(Number(item.value)/Number(totalVal)*100).toFixed(2))+'%'}
let it = {name:item.name, value:item.value, percent:parseFloat(Number(Number(item.value)/Number(totalVal)*100).toFixed(2))}
return it
})
if(this.viewData.length>0){
......
......@@ -23,7 +23,7 @@
<el-table-column
prop="bl"
align="right"
label="占比">
label="占比(%)">
<template slot-scope="scope">
<span>{{ scope.row.bl }}</span>
</template>
......@@ -139,7 +139,7 @@ export default {
this.viewData = this.viewData.map(item => {
let number = this.statistic[item.category]&&this.statistic[item.category][item.field]?this.statistic[item.category][item.field]:0
let bl = number ? parseFloat(Number(Number(number)/Number(totalVal)*100).toFixed(2)) : 0
let it = {name:item.name, value:number, tz: '', bl:bl+'%'}
let it = {name:item.name, value:number, tz: '', bl:bl}
return it
})
this.viewData.sort((a, b) => {
......@@ -161,7 +161,7 @@ export default {
if(params.data.tz){
result+='<p style="color: rgba(35,35,35,0.8);padding: 0;margin: 0;" >'+ params.data.tz +'亿元</p>'
}
result+='<p style="color: rgba(35,35,35,0.8);padding: 0;margin: 0;">'+ params.data.bl+'</p>'
result+='<p style="color: rgba(35,35,35,0.8);padding: 0;margin: 0;">'+ params.data.bl+'%</p>'
return result;
},
extraCssText:'width:150px!important;',
......
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