'use strict'; /** * 前台页面展示相关 * * @author Ellisran * @date * @version */ // { title: '打开项目管理系统', name: 'openManagement', value: pageStatus.show, type: 'checkbox' }, const pageStatus = { show: 1, hide: 0, }; // 模块管理开关 const managerPageControl = [ { title: '决策大屏', name: 'openDataCollect', value: pageStatus.show, type: 'checkbox', tip: '开启后,前台配置用户权限后方可显示' }, { title: '合同管理', name: 'openContract', value: pageStatus.show, type: 'checkbox' }, { title: '资料归集', name: 'openFile', value: pageStatus.show, type: 'checkbox' }, { title: '动态投资', name: 'openBudget', value: pageStatus.show, type: 'checkbox', tip: '开启后,前台配置用户权限后方可显示' }, { title: '支付审批', name: 'openPayment', value: pageStatus.show, type: 'checkbox', tip: '开启后,前台配置用户权限后方可显示' }, { title: '资金监管', name: 'openFinancial', value: pageStatus.show, type: 'checkbox' }, ]; // 标段功能开关 const tenderPageControl = [ { title: '部位台帐', name: 'bwtz', value: pageStatus.show, type: 'checkbox', tip: '「部位台帐」显示在「0号台帐」以及「各期计量」侧栏菜单中', tipClass: '' }, { title: '其他台账', name: 'stageExtra', value: pageStatus.show, type: 'checkbox' }, { title: '合同支付独立审批', name: 'phasePay', value: pageStatus.show, type: 'checkbox' }, { title: '投资进度', name: 'xxjd', value: pageStatus.show, type: 'checkbox' }, { title: '材料调差', name: 'openMaterial', value: pageStatus.show, type: 'checkbox' }, { title: '过程结算', name: 'openSettle', value: pageStatus.show, type: 'checkbox' }, { title: '施工日志', name: 'openConstruction', value: pageStatus.show, type: 'checkbox' }, { title: '合同管理', name: 'openTenderContract', value: pageStatus.show, type: 'checkbox' }, ]; // 报表相关开关 const reportPageControl = [ { title: '关闭报表「导出PDF」', name: 'closeExportPdf', value: pageStatus.show, type: 'checkbox' }, { title: '关闭报表「导出Excel」', name: 'closeExportExcel', value: pageStatus.show, type: 'checkbox' }, { title: '关闭报表「水印」', name: 'closeWatermark', value: pageStatus.show, type: 'checkbox', tip: '审批未通过的计量期,报表将显示水印「审批未通过」', tipClass: '' }, { title: '关闭「定制报表」默认加载报表功能', name: 'closeShowAllCustomized', value: pageStatus.show, type: 'checkbox', tip: '关闭后,定制报表将默认不显示(用户定制选择除外)', tipClass: '' }, { title: '开启报表「跨标段批量签名」', name: 'openSign', value: pageStatus.show, type: 'checkbox' }, { title: '开启个人「签字」功能', name: 'individualSign', value: pageStatus.show, type: 'checkbox', tip: '签字仅可选择当前人账号,管理员账号可选择所有人', tipClass: '' }, { title: '开启签名「网证通电子签名」', name: 'openNetCaSign', value: pageStatus.show, type: 'checkbox' }, { title: '开启文本「签字」', name: 'isTextSignature', value: pageStatus.show, type: 'checkbox', tip: '开启后,所有签名将以文字代替图片', tipClass: '' }, { title: '开启「报表数据预设」', name: 'isPreset', value: pageStatus.show, type: 'checkbox', tip: '', tipClass: '' }, { title: '开启「审批完成过滤」', name: 'isOnlyChecked', value: pageStatus.show, type: 'checkbox', tip: '关闭后,「工程变更」将包含未上报、审批中等全部状态的数据,影响 开启「报表数据预设」', tipClass: '' }, { title: '开启「归档时不生成签字和签章」', name: 'closeArchiveSignature', value: pageStatus.show, type: 'checkbox', tip: '开启后,归档时所有报表的签名(名、章、文本等)都不显示', tipClass: '' }, ]; // 功能设置页name名列表,功能设置需要设置的name必须添加到这个列表中,否则有可能清空数据 const settingNameArray = (function(controlArr){ const result = []; controlArr.forEach(control => { const key = control.map(x => { return x.name; }); result.push(...key); }); })([managerPageControl, tenderPageControl]); // 设置默认值,同步前台的const/page_show.js文件 const defaultSetting = { bwtz: 0, xxjd: 0, openMaterial: 1, stageExtra: 1, phasePay: 0, closeExportPdf: 0, closeExportExcel: 0, closeWatermark: 0, closeShowAllCustomized: 0, openSign: 0, individualSign: 0, openNetCaSign: 0, isTextSignature: 0, openChangeRevise: 1, openMaterialTax: 0, addDataCollect: 1, closeWapYfSf: 0, close1stStageCheckDealParam: 0, openManagement: 0, isPreset: 0, isOnlyChecked: 1, closeArchiveSignature: 0, openSettle: 0, openContractExpr: 0, openMultiStageCalc: 0, maxMultiStageCount: 5, openDataCollect: 1, openFile: 1, openBudget: 1, openPayment: 1, openConstruction: 1, openMaterialStageRepeat: 0, openContract: 1, openFinancial: 1, openTenderContract: 1, openStageAudit: 0, stageAuditEarly: 3, stageAuditWorry: 8, }; module.exports = { pageStatus, managerPageControl, tenderPageControl, defaultSetting, settingNameArray, };