Commit 4ef853eb authored by 高滢's avatar 高滢

feat(资金计划): 资金来源表格六列

parent b3dd25b9
......@@ -59,3 +59,6 @@ ul {
.tableshow {
display: revert;
}
.vben-editable-cell__action{
display: none;
}
......@@ -219,8 +219,6 @@ import {onMounted, ref, unref} from 'vue';
dataIndex: 'totalOwnFunds',
width: 180,
},
],
},
{
title: '资金缺口',
dataIndex: 'fundingGap',
......@@ -228,6 +226,8 @@ import {onMounted, ref, unref} from 'vue';
},
],
},
],
},
];
} else {
return [
......@@ -295,8 +295,6 @@ import {onMounted, ref, unref} from 'vue';
dataIndex: 'totalOwnFunds',
width: 180,
},
],
},
{
title: '资金缺口',
dataIndex: 'fundingGap',
......@@ -304,6 +302,8 @@ import {onMounted, ref, unref} from 'vue';
},
],
},
],
},
];
}
}
......
import { FormProps, FormSchema, BasicColumn } from '@/components/Table';
import { FormSchema, BasicColumn } from '@/components/Table';
export function getBasicColumns(): BasicColumn[] {
return [
......@@ -10,9 +10,7 @@ export function getBasicColumns(): BasicColumn[] {
{
title: '数值(万元)',
dataIndex: 'value',
width: 150,
// sorter: true,
// defaultHidden: true,
width: 80,
edit: true,
editable: true,
editRule: true,
......@@ -31,9 +29,7 @@ export function basicColumnsDisabled(): BasicColumn[] {
{
title: '数值(万元)',
dataIndex: 'value',
width: 150,
// sorter: true,
// defaultHidden: true,
width: 80,
editComponent: 'InputNumber',
},
];
......@@ -44,52 +40,69 @@ export function getBasicColumnsTwo(): BasicColumn[] {
{
title: '季度',
dataIndex: 'quarter',
width: 80,
width: 50,
fixed: 'left',
},
{
title: '政府拨款',
title: '政府拨款(万元)',
dataIndex: 'governmentGrant',
width: 150,
// sorter: true,
// defaultHidden: true,
width: 50,
edit: true,
editable: true,
editRule: true,
editComponent: 'InputNumber',
},
{
title: '专项债拨款',
title: '专项债拨款(万元)',
dataIndex: 'specialBond',
width: 150,
// sorter: true,
// defaultHidden: true,
width: 50,
edit: true,
editable: true,
editRule: true,
editComponent: 'InputNumber',
},
{
title: '银行融资',
title: '银行融资(万元)',
dataIndex: 'bankFinancing',
width: 150,
// sorter: true,
// defaultHidden: true,
width: 50,
edit: true,
editable: true,
editRule: true,
editComponent: 'InputNumber',
},
{
title: '自有资金',
title: '自有资金(万元)',
dataIndex: 'ownFunds',
width: 150,
// sorter: true,
// defaultHidden: true,
width: 50,
edit: true,
editable: true,
editRule: true,
editComponent: 'InputNumber',
},
{
title: '资金缺口(万元)',
dataIndex: 'fundingGap',
width: 50,
edit: true,
editable: true,
editRule: true,
editComponent: 'InputNumber',
},
{
title: '资金计划额(万元)',
dataIndex: 'totalValue',
width: 50,
customRender: ({ record }) => {
// 这里可以根据record的其他字段计算值
record.totalValue =
record.ownFunds +
record.specialBond +
record.bankFinancing +
record.governmentGrant +
record.fundingGap; // 计算新值
return record.totalValue; // 返回计算后的值
},
},
];
}
......@@ -104,32 +117,36 @@ export function basicColumnsTwoDisabled(): BasicColumn[] {
title: '政府拨款',
dataIndex: 'governmentGrant',
width: 150,
// sorter: true,
// defaultHidden: true,
editComponent: 'InputNumber',
},
{
title: '专项债拨款',
dataIndex: 'specialBond',
width: 150,
// sorter: true,
// defaultHidden: true,
editComponent: 'InputNumber',
},
{
title: '银行融资',
dataIndex: 'bankFinancing',
width: 150,
// sorter: true,
// defaultHidden: true,
editComponent: 'InputNumber',
},
{
title: '自有资金',
dataIndex: 'ownFunds',
width: 150,
// sorter: true,
// defaultHidden: true,
editComponent: 'InputNumber',
},
{
title: '资金缺口(万元)',
dataIndex: 'fundingGap',
width: 50,
editComponent: 'InputNumber',
},
{
title: '资金计划额(万元)',
dataIndex: 'totalValue',
width: 50,
editComponent: 'InputNumber',
},
];
......@@ -262,6 +279,21 @@ export function formSchema(year, planType): FormSchema[] {
},
colProps: { span: 7, offset: 1 },
},
{
field: 'fundSource',
label: '资金来源',
required: true,
component: 'Select',
componentProps: {
options: [
{ label: '政府投资项目', value: '政府投资项目' },
{ label: '公司投资项目', value: '公司投资项目' },
{ label: '专项债项目', value: '专项债项目' },
{ label: '承建项目', value: '承建项目' },
],
},
colProps: { span: 7, offset: 1 },
},
{
field: 'time',
component: 'RangePicker',
......@@ -303,17 +335,17 @@ export function formSchema(year, planType): FormSchema[] {
component: 'Input',
colProps: { span: 7, offset: 1 },
},
{
field: 'fundingGap',
label: '2024资金缺口:',
labelWidth: 200,
required: true,
component: 'InputNumber',
componentProps: {
addonAfter: '万元',
},
colProps: { span: 7, offset: 1 },
},
// {
// field: 'fundingGap',
// label: '2024资金缺口:',
// labelWidth: 200,
// required: true,
// component: 'InputNumber',
// componentProps: {
// addonAfter: '万元',
// },
// colProps: { span: 7, offset: 1 },
// },
{
label: '备注',
field: 'remarks',
......
......@@ -49,6 +49,16 @@ export let formSchema: FormSchema[] = [
style: { width: '100%' },
},
},
{
field: 'projectInvestment',
label: '立项总投资',
required: true,
component: 'InputNumber',
componentProps: {
addonAfter: '万元',
},
labelWidth: '140px',
},
{
field: 'isReserveProject',
label: '储备项目',
......
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