| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192 |
- 'use strict';
- /**
- * 合同管理
- *
- * @author ELlisran
- * @date 2019/10/20
- * @version
- */
- // 类型
- const type = {
- expenses: 1,
- income: 2,
- };
- const typeMap = {
- 1: 'expenses',
- 2: 'income',
- };
- const typeName = {
- 1: '支付',
- 2: '回款',
- };
- const colSet = {
- [type.expenses]: [
- { name: '合同类型', field: 'type', fixed: ['alias'], gd: true },
- { name: '累计应付', field: 'yf_price', fixed: ['alias'] },
- { name: '应付进度', field: 'stackedBar', fixed: ['alias'] },
- { name: '累计实付', field: 'sf_price', fixed: ['alias'] },
- { name: '实付进度', field: 'stackedBarSf', fixed: ['alias'] },
- { name: '备注1', field: 'remark1', fixed: [] },
- { name: '备注2', field: 'remark2', fixed: [] },
- { name: '计算1', field: 'calc', fixed: [] },
- { name: '计算2', field: 'calc2', fixed: [] },
- ],
- [type.income]: [
- { name: '合同类型', field: 'type', fixed: ['alias'], gd: true },
- { name: '累计应回', field: 'yf_price', fixed: ['alias'] },
- { name: '应回进度', field: 'stackedBar', fixed: ['alias'] },
- { name: '累计实回', field: 'sf_price', fixed: ['alias'] },
- { name: '实回进度', field: 'stackedBarSf', fixed: ['alias'] },
- { name: '备注1', field: 'remark1', fixed: [] },
- { name: '备注2', field: 'remark2', fixed: [] },
- { name: '计算1', field: 'calc', fixed: [] },
- { name: '计算2', field: 'calc2', fixed: [] },
- ],
- };
- const defaultColSet = {
- [type.expenses]: [
- { field: 'type', show: 1, gd: true },
- { field: 'yf_price', show: 1 },
- { field: 'stackedBar', show: 1 },
- { field: 'sf_price', show: 0 },
- { field: 'stackedBarSf', show: 0 },
- { field: 'remark1', show: 0, alias: '备注1' },
- { field: 'remark2', show: 0, alias: '备注2' },
- { field: 'calc', show: 0, alias: '计算1' },
- { field: 'calc2', show: 0, alias: '计算2' },
- ],
- [type.income]: [
- { field: 'type', show: 1, gd: true },
- { field: 'yf_price', show: 1 },
- { field: 'stackedBar', show: 1 },
- { field: 'sf_price', show: 0 },
- { field: 'stackedBarSf', show: 0 },
- { field: 'remark1', show: 0, alias: '备注1' },
- { field: 'remark2', show: 0, alias: '备注2' },
- { field: 'calc', show: 0, alias: '计算1' },
- { field: 'calc2', show: 0, alias: '计算2' },
- ],
- };
- const defaultAttribute = [
- { name: '税率(%)', field: 'type', fixed: ['alias'], type: 'int' },
- { name: '数值', field: 'num_val', fixed: [], type: 'int' },
- { name: '丙方', field: 'third', fixed: [], type: 'text' },
- { name: '丁方', field: 'fourth', fixed: [], type: 'text' },
- { name: '文本', field: 'text', fixed: [], type: 'text' },
- { name: '合同内容', field: 'contract_content', fixed: [], type: 'long_text', tip: '独占一行,上限1000' },
- { name: '支付条件', field: 'pay_condition', fixed: [], type: 'long_text', tip: '独占一行,上限1000' },
- ];
- module.exports = {
- type,
- typeMap,
- typeName,
- colSet,
- defaultColSet,
- };
|