
interface VxeColumn {
  type?: string;
  field?: string;
  title?: string;
  width?: number | string;
  minWidth?: number | string;
  maxWidth?: number | string;
  sortable?: boolean;
  formatter?: (value: any) => string;
  treeNode?: boolean;
  slots?: {};
  visible?: boolean;
  editRender?: {};
  align?: string;
  showOverflow?: boolean | string;
  span?:number
}

export const complianceCol: VxeColumn[] = [
  { field: 'cgrpPath', title: '分组',span:1,type:'html'},
  { field: 'item', title: '条目',span:3,type:'html'},
  { field: 'content', title: '内容',span:3,type:'html'},
  { field: 'fileName', title: '参考文件', visible: true, type:"html", slots: { default: 'fileName_default' }, showOverflow: 'ellipsis'},

];

export const innerCtlCol: VxeColumn[] = [
  { field: 'strategy', title: '策略',span:3,type:'html'},
  { field: 'claim', title: '内控要求',span:3,type:'html'},
  { field: 'fileName', title: '参考文件', span: 3,type:'html', slots: { default: 'fileName_default' }, showOverflow: 'ellipsis'},
];

export const innerCtlOrderCol: VxeColumn[] = [
  { field: 'execRule', title: '执行规则',span:3,type:'html'},
  { field: 'ctrlDesc', title: '内控要求',span:3,type:'html'},
  { field: 'fileName', title: '参考文件', span: 3,type:'html', slots: { default: 'fileName_default' }, showOverflow: 'ellipsis'},
];

export const problemCol: VxeColumn[] = [
  { field: 'pbItem', title: '问题项',span:3,type:'html'},
  { field: 'pbExample', title: '问题示例',span:3,type:'html'},
  { field: 'pbAdvise', title: '问题建议', span: 3,type:'html'},
  { field: 'pbAnalysis', title: '问题分析',span:3,type:'html'},
  { field: 'pbNature', title: '问题性质', span:3,type:'html'},
  { field: 'fileName', title: '参考文件', span: 3,type:'html', slots: { default: 'fileName_default' }, showOverflow: 'ellipsis'},
];

export const checkMethodCol: VxeColumn[] = [
  { field: 'content', title: '检查内容',span:3,type:'html'},
  { field: 'des', title: '备注', span:3,type:'html'},
  { field: 'fileName', title: '参考文件', span: 3,type:'html', slots: { default: 'fileName_default' }, showOverflow: 'ellipsis'},
];

export const riskEventCol: VxeColumn[] = [
  { field: 'riskEventName', title: '风险事件',span:3,type:'html'},
  { field: 'riskEventDesc', title: '风险事件描述',span:3,type:'html'},
  { field: 'fileName', title: '参考文件', span: 3,type:'html', slots: { default: 'fileName_default' }, showOverflow: 'ellipsis'},
];

export const practiceCol: VxeColumn[] = [
  { field: 'content', title: '行业实践',span:3,type:'html'},
  { field: 'exeRule', title: '执行规则',span:3,type:'html'},
  { field: 'fileName', title: '参考文件', span: 3,type:'html', slots: { default: 'fileName_default' }, showOverflow: 'ellipsis'},
];

export const actCol: VxeColumn[] = [
  { field: 'caName', title: '控制项名称',span:3,type:'html'},
  { field: 'caDesc', title: '说明',span:3,type:'html'},
  { field: 'domainName', title: '所属领域', span: 3,type:'html'},
  { field: 'labelNames', title: '标签', span: 3,type:'html'},
  { field: 'fileName', title: '参考文件', span: 3,type:'html', slots: { default: 'fileName_default' }, showOverflow: 'ellipsis'},
];


//查询数据
export const srhCompliane: string[] = ['cgrpPath', 'fileName', 'item', 'content'];
export const srhInnerCtl: string[] = ['fileName','strategy', 'claim'];
export const srhInnerOrder: string[] = ['fileName', 'execRule', 'ctrlDesc'];
export const srhProblem: string[] = ['fileName','pbItem', 'pbExample', 'pbAdvise'];
export const srhCheckMethod: string[] = ['cgrpPath', 'fileName', 'item', 'content'];
export const srhRiskEvent: string[] = ['scenarioName', 'riskEventName', 'riskEventDesc'];
export const srhPractice: string[] = ['fileName', 'content', 'exeRule'];
export const srhRiskScena: string[] = ['scenarioName', 'scenarioDesc'];
export const srhAct: string[] = ['domainName', 'caDesc'];

export const srhCond = {
  1: srhCompliane,
  2: srhInnerCtl,
  3: srhInnerOrder,
  4: srhProblem,
  5: srhCheckMethod,
  6: srhRiskEvent,
  7: srhPractice,
  8: srhRiskScena,
  9: srhAct,
};



export const auditCols = {
  1: complianceCol,
  2: innerCtlCol,
  3: innerCtlOrderCol,
  4: problemCol,
  5: checkMethodCol,
  6: riskEventCol,
  7: practiceCol,
  9: actCol,
};
