ttk-app-core
Version:
enterprise develop framework
315 lines (296 loc) • 14 kB
JavaScript
export function getMeta() {
return {
name: 'root',
component: 'Layout',
className: 'ttk-taxapply-app-financialtaxrpt',
_visible: '{{ data.other.allVisible}}',
children: [{
name: 'step1',
component: 'Layout',
className: 'ttk-taxapply-app-financialtaxrpt-step1content',
_visible: '{{ data.step.step1Visible}}',
children: [{
name: 'ttk-taxapply-app-financialtaxrpt-leadIn',
className: 'ttk-taxapply-app-financialtaxrpt-leadIn',
component: '::div',
children: [{
name: 'care',
component: '::div',
className: 'ttk-taxapply-app-financialtaxrpt-leadIn-care',
children: '{{$getUpdatePrompt()}}'
}, {
name: 'update-balancesheet-item',
component: '::div',
className: 'update-balancesheet-item',
_visible: '{{data.other.balancesheetStatus}}',
children: [{
component: '::span',
name: 'update-balancesheet-item-title',
className: 'update-balancesheet-item-title',
children: '资产负债表:'
}, {
component: '::span',
name: 'update-balancesheet-item-content',
name: 'button',
component: '::div',
type: 'primary',
className: 'update-balancesheet-item-content',
children: '{{$renderUpload("balancesheet")}}'
}]
}, {
name: 'update-balancesheet-item',
component: '::div',
className: 'update-balancesheet-item',
_visible: '{{data.other.profitstatementStatus}}',
children: [{
component: '::span',
name: 'update-balancesheet-item-title',
className: 'update-balancesheet-item-title',
children: '利润表:'
}, {
component: '::span',
name: 'update-balancesheet-item-content',
name: 'button',
component: '::div',
type: 'primary',
className: 'update-balancesheet-item-content',
children: '{{$renderUpload("profitstatement")}}'
}]
}, {
name: 'update-balancesheet-item',
component: '::div',
className: 'update-balancesheet-item',
_visible: '{{data.other.cashflowstatementStatus}}',
children: [{
component: '::span',
name: 'update-balancesheet-item-title',
className: 'update-balancesheet-item-title',
children: '现金流量表:'
}, {
component: '::span',
name: 'update-balancesheet-item-content',
name: 'button',
component: '::div',
type: 'primary',
className: 'update-balancesheet-item-content',
children: '{{$renderUpload("cashflowstatement")}}'
}]
}
, {
name: 'selectLocalRpt',
component: 'Button',
type: 'primary',
children: '转为局端格式',
onClick: '{{$selectLocalRptClick}}',
className: 'ttk-taxapply-app-financialtaxrpt-leadIn-localRpt',
disabled: '{{ !data.btnState.updateState }}',
}, {
name: 'nextBtn',
component: 'Link',
disabled: '{{data.btnState.nextState}}',
onClick: '{{$nextClick}}',
className: 'ttk-taxapply-app-financialtaxrpt-leadIn-next',
children: [{
name: 'nextBtnIcon',
component: 'Icon',
fontFamily: 'edficon',
type: 'zhuanhuandebaobiao',
}, {
name: 'nextBtnText',
component: '::span',
children: '转换的报表'
}],
}]
}]
}, {
name: 'step2',
component: 'Layout',
className: 'ttk-taxapply-app-financialtaxrpt-step2content',
_visible: '{{data.step.step2Visible}}',
children: [{
name: 'header',
component: '::div',
className: 'ttk-taxapply-app-financialtaxrpt-step2content-header',
children: [{
name: 'rpttype',
component: '::div',
className: 'ttk-taxapply-app-financialtaxrpt-step2content-header-rpttype',
children: [{
name: 'headRptType',
component: 'Radio.Group',
value: '{{data.other.rpttype}}',
onChange: `{{function(v){$rptTypeChange('data.other.rpttype',v.target.value)}}}`,
children: [{
name: 'balanceSheetRpt',
value: 'balanceSheetRpt',
component: 'Radio.Button',
children: '{{data.rptTitle.balanceSheetRpt}}'
}, {
name: 'profitStatementRpt',
value: 'profitStatementRpt',
component: 'Radio.Button',
children: '{{data.rptTitle.profitStatementRpt}}'
}, {
name: 'cashflowStatementRpt',
value: 'cashflowStatementRpt',
component: 'Radio.Button',
_visible: '{{data.other.cashflowstatementStatus}}',
children: '{{data.rptTitle.cashflowStatementRpt}}'
}]
}, {
className: 'ttk-taxapply-app-financialtaxrpt-step2content-header-rpttype-rightcontent',
component: '::div',
children: [{
className: 'ttk-taxapply-app-financialtaxrpt-step2content-header-rpttype-rightcontent-left',
component: '::div',
children: '注:原表与税局报表有不匹配的项目,请调整项目对应关系。调整后,以后属期可直接导入啦!'
}, {
component: '::div',
children: [{
name: 'reSelectRpt',
component: 'Button',
className: 'ttk-taxapply-app-financialtaxrpt-step2content-header-rpttype-rightcontent-right-otherbtn',
children: '重传Excel',
onClick: '{{$reSelectRptClick}}'
}, {
name: 'projectAdjust',
component: 'Button',
className: 'ttk-taxapply-app-financialtaxrpt-step2content-header-rpttype-rightcontent-right-otherbtn',
children: '调整项目',
onClick: '{{$projectAdjustClick}}'
}, {
name: 'generate',
component: 'Button',
className: 'ttk-taxapply-app-financialtaxrpt-step2content-header-rpttype-rightcontent-right-generatebtn',
children: '生成',
onClick: '{{$generateClick}}',
}]
}]
}]
}, {
name: 'maintitle',
component: '::div',
className: 'ttk-taxapply-app-financialtaxrpt-step2content-header-maintitle',
children: '{{data.rptHeader.mainTitle}}'
}, {
name: 'rpttopdesc',
component: '::div',
className: 'ttk-taxapply-app-financialtaxrpt-step2content-header-rpttopdesc',
children: [{
component: '::div',
className: 'rptHeaderLeft',
children: '{{data.rptHeader.vatTaxpayerNum}}'
}, {
component: '::div',
className: 'rptHeaderCenter',
children: '{{data.rptHeader.subTitle}}'
}, {
component: '::div',
className: 'rptHeaderRight',
children: '{{data.rptHeader.enterprise}}'
}]
}, {
name: 'rptbottomdesc',
component: '::div',
className: 'ttk-taxapply-app-financialtaxrpt-step2content-header-rptbottomdesc',
children: [{
component: '::div',
className: 'rptHeaderbottomLeft',
children: '{{data.rptHeader.compilingUnit}}'
}, {
component: '::div',
className: 'rptHeaderbottomCenter',
children: [{
component: '::div',
className: 'rptHeaderbottomSpace',
children: '{{data.rptHeader.fillReportDate}}'
}, {
component: '::div',
className: 'rptHeaderbottomSpace',
children: '{{data.rptHeader.reportperiod}}'
}]
}, {
component: '::div',
className: 'rptHeaderRight',
children: '{{data.rptHeader.unit}}'
}]
}]
}, {
name: 'content',//1、balanceSheetRpt 资产负债 2、profitStatementRpt 利润表 3、cashflowStatementRpt 现金流量表
className: 'ttk-taxapply-app-financialtaxrpt-step2content-content',
name: 'voucherItems',
component: 'Table',
pagination: false,
id: 'balanceSheetRptId',
scroll: '{{data.source.dataList.length> 0 ? data.tableOption:{}}}',
allowColResize: false,
enableSequenceColumn: false,
bordered: true,
dataSource: '{{data.source.dataList}}',
noDelCheckbox: true,
columns: '{{$tableColumns()}}',
loading: '{{data.other.loading}}',
}]
}]
}
}
export function getInitState() {
return {
data: {
tableOption: {
x: 900,
// y: 300
},
uploadFile: {},
btnState: {
updateState: false,
selectLocalDiabled: false,
nextState: true
},
step: {
//选择页面
step1Visible: true,
//报表页面
step2Visible: false,
},
list: [],
rptHeader: {
mainTitle: '资产负债表',
subTitle: '(适用执行企业会计准则的一般企业)',
vatTaxpayerNum: '', //纳税人识别号: 123123123123123123213123
fillReportDate: '',//填报日期:2018-04-18
compilingUnit: '',//编制单位:方欣科技股份公司
reportperiod: '',//报表属期:2018-01-01 至 2018-03-31
enterprise: '',//会企03表
unit: ''//单位:元
},
urlData: '',
source: {
headerList: [],
dataList: []
},
targetList: [],
other: {
allVisible: false,
isLoading: false,
rpttype: 'balanceSheetRpt',
care: '注:下方列表只显示不一致的项目。',
balancesheetDisabled: false,//页签是否可选
cashflowstatementDisabled: false,//true,
profitstatementDisabled: false,
balancesheetStatus: true,//upload
profitstatementStatus: true,//upload
cashflowstatementStatus: false, //upload
customAttribute: 0,
editStatus: false
},
rptTitle: {
balanceSheetRpt: '资产负债表',
profitStatementRpt: '利润表',
cashflowStatementRpt: '现金流量表'
},
//会计总则
accountingStandards: '',
}
}
}