import { until } from '@vueuse/shared';
import type { VxeGridProps, VxeColumnPropTypes } from 'vxe-table';
import XEUtils from 'xe-utils';

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;
  fixed?: string;
  filters?: [] | {};
  filterMethod?: any;
  filterMethodTp?: string;
  filterRender?: any;
}

export const tableFormData = [
  {
    serialNumber: "1",
    project: "软件开发项目情况",
    code: 'DEVPRJ',
    content: [
      { type: "text", value: "（1）本年度软件开发项目总数" },
      { type: "number", field: "DEVPRJ1",unit:"个" },
      { type: "brspace" },
      { type: "text", value: "其中：已完成的软件开发项目总数" },
      { type: "number", value: "", field: "DEVPRJ2",unit:"个" },

      { type: "brspace" },
      { type: "text", value: "软件开发重大项目数" },
      { type: "number", value: "", field: "DEVPRJ3" ,unit:"个"},

      { type: "brspace" },
      { type: "text", value: "自主开发项目数" },
      { type: "number", value: "", field: "DEVPRJ4" ,unit:"个"},

      { type: "brspace" },
      { type: "text", value: "部分外包开发项目数" },
      { type: "number", value: "", field: "DEVPRJ5" ,unit:"个"},

      { type: "brspace" },
      { type: "text", value: "整体外包开发项目数" },
      { type: "number", value: "", field: "DEVPRJ6" ,unit:"个"},

      { type: "br" },
     
      { type: "text", value: "（2）本年度软件开发项目工作量" },
      { type: "number", field: "DEVPRJ7",unit:"人月"},
      { type: "brspace" },
      { type: "text", value: " 其中：自主开发工作量" },
      { type: "number", field: "DEVPRJ8",unit:"人月" },
      
      { type: "brspace" },
      { type: "text", value: "外包开发工作量" },
      { type: "number", field: "DEVPRJ9",unit:"人月" },
    ],

    remarks: {
      rows:11,
      field:"DEVPRJ100"
    }

  },

  {
    serialNumber: "2",
    project: "项目管理",
    code: 'PRJMNG',
    content: [
      { type: "text", value: "（1）机构已建立专门的信息科技项目管理组织" },
      { type: "yesno", field: "PRJMNG1"},
      { type: "br" },

      { type: "text", value: "（2）定期向信息科技管理委员会（承担信息化工作的委员会）或高管层提交重大项目进度报告" },
      { type: "yesno", field: "PRJMNG2"},
      { type: "br" },
      
      
      { type: "text", value: "（3）信息安全人员参加软件开发重大项目评审" },
      { type: "yesno", field: "PRJMNG3"},
      { type: "brspace" },
      { type: "text", value: "参加本年度评审的软件开发重大项目数量" },
      { type: "number", field: "PRJMNG4" ,unit:"个"},
      { type: "br" },

      { type: "text", value: "（4）项目投产后，组织业务相关部门对软件开发重大项目进行后评价" },
      { type: "yesno", field: "C20A002"},
      { type: "brspace" },
      { type: "text", value: "本年度组织业务相关部门后评价的软件开发重大项目数量" },
      { type: "number", field: "C20A003" ,unit:"个"},
      { type: "br" },


      { type: "text", value: "（5）制定并实施项目管理制度" },
      { type: "yesno", field: "C20A004"},
      { type: "brspace" },
      { type: "text", value: "若是，涵盖范围" },
      
      { 
        type: "checkbox-group", 
        field: "C20A005",
        options: [
          "项目立项管理","项目采购和合同管理","项目范围管理","项目进度管理",
          "项目成本管理","项目质量管理","项目风险管理","项目人力资源管理",
          "项目沟通和干系人管理","项目投产验收管理","项目后评价管理"
        ]
      },
      { type: "br" },

      { type: "text", value: "（6）建立项目管理制度修订机制" },
      { type: "yesno", field: "PRJMNG9"},
      { type: "brspace" },
      { type: "text", value: "本年度新增或修订项目管理制度" },
      { type: "yesno", field: "PRJMN10"},
      { type: "br" },
    ],
    remarks: {
      rows:11,
      field:"PRJMNG100"
    }
    
  },
  {
    serialNumber: "3",
    project: "需求管理",
    code: 'DMDMNG',
    content: [
      { type: "text", value: "（1）软件需求通过相关部门的评审：" },
      { type: "yesno", field: "DMDMNG1"},
      { type: "brspace" },
      { type: "text", value: "负责需求评审的部门" },
      { 
        type: "checkbox-group", 
        field: "DMDMNG2",
        options: [
          "信息科技部门","需求部门"
        ]
      },
      { type: "br" },
      { type: "text", value: "（2）制定并实施安全需求规范" },
      { type: "yesno", field: "C20A006"},
      { type: "br" },
      { type: "text", value: "（3）软件需求包含的非功能性需求内容包括" },
      { type: "brspace" },
      { 
        type: "checkbox-group", 
        field: "DMDMNG3",
        options: [
          "性能需求","安全需求","容灾需求"
        ],
        otherOption:true,
        otherField:"DMDMNG4"
      },
     
      { type: "br" },
      { type: "text", value: "（4）软件需求变更经相关部门正式确认" },
      { type: "yesno", field: "C20A007"},
      { type: "text", value: "需要正式确认的部门" },
      { 
        type: "checkbox-group", 
        field: "C20A008",
        options: [
          "信息科技部门","需求部门"
        ],
      },
     
    ],
    remarks: {
      rows:11,
      field:"DMDMNG100"
    }
    
  },

  {
    serialNumber: "4",
    project: "开发管理",
    code: 'DEVMNG',
    content: [
      { type: "text", value: " （1）制定并实施应用安全技术规范" },
      { type: "yesno", field: "C20A009"},
      { type: "brspace" },
      { type: "text", value: "若是，应用安全技术规范涵盖" },
      { 
        type: "checkbox-group", 
        field: "DEVMNG3",
        options: [
          "Web安全","客户端安全","身份认证","访问控制","可信验证","密码技术", 
          "通信安全","安全审计","完整性","保密性","抗抵赖","软件容错" 
        ],
        otherOption:true,
        otherField:"DEVMNG4"      
      },
      { type: "br" },
      { type: "text", value: "（2）针对外购软件，制定检测标准和规范，使之符合机构应用安全技术规范" },
      { type: "yesno", field: "DEVMNG5"},
    
     
      { type: "br" },
      { type: "text", value: "（3）制定并实施安全编码规范" },
      { type: "yesno", field: "C20A010"},


      { type: "br" },
      { type: "text", value: "（4）软件开发模式中是否有敏捷开发" },
      { type: "yesno", field: "C20A011"},

      { type: "brspace" },
      { type: "text", value: "若是，制定敏捷开发安全规范" },
      { type: "yesno", field: "C20A012"},

      { type: "br" },
      { type: "text", value: "（5）对系统共用安全功能实现了统一的组件化管理" },
      { type: "yesno", field: "C20A013"},

      { type: "br" },
      { type: "text", value: "（6）存在系统开发和运行维护工作岗位职责未分离的情况" },
      { type: "yesno", field: "C23A001"},


      { type: "br" },
      { type: "text", value: "（7）定期向开发团队通报涉及本机构的重大网络和数据安全事件" },
      { type: "yesno", field: "C24A001"},
     
    ],
    remarks: {
      rows:11,
      field:"DEVMNG100"
    }
  },
  {
    serialNumber: "5",
    project: "测试管理",
    code: 'TSTMNG',
    content: [
      { type: "text", value: " （1）制定并实施软件测试规范" },
      { type: "yesno", field: "C20A014"},

      { type: "br" },
      { type: "text", value: "（2）建立充分、完整的测试体系，形成测试和验收报告" },
      { type: "yesno", field: "C20A015"},

      { type: "brspace" },
      { type: "text", value: "如是，测试结果确认部门" },
      { 
        type: "checkbox-group", 
        field: "C20A016",
        options: [
          "信息科技部门","相关业务部门"
        ],   
      },

      { type: "br" },
      { type: "text", value: "（3）测试环节若使用生产数据，" },
      { type: "yesno", field: "TSTMNG1"},

      { type: "brspace" },
      { type: "text", value: "如是，采取数据脱敏措施" },
      { 
        type: "checkbox-group", 
        field: "C20A017",
        options: [
          "手工脱敏","系统脱敏"
        ],   
      },
      { type: "br" },
      { type: "text", value: "（4）重要信息系统和互联网应用系统上线前均开展安全测试，且测试通过后方可上线" },
      { type: "yesno", field: "C20A018"},

      { type: "br" },
      { type: "text", value: "（5）建立网络和数据安全威胁测试用例集" },
      { type: "yesno", field: "C24A002"},
     
     
      { type: "br" },
      { type: "text", value: "（6）重要信息系统和互联网应用系统均开展源代码安全检查" },
      { type: "yesno", field: "C20A019"},
     
      { type: "brspace" },
      { type: "text", value: "如是，安全检查方式" },
      { 
        type: "checkbox-group", 
        field: "TSTMNG4",
        options: [
          "手工检查","专业工具检查"
        ],   
      },
     
    ],
    remarks: {
      rows:11,
      field:"TSTMNG100"
    }
  },
  {
    serialNumber: "6",
    project: "版本管理",
    code: 'VSNMNG',
    content: [
      { type: "text", value: "（1）设立专职的软件版本管理团队（组织）" },
      { type: "yesno", field: "VSNMNG1"},
      { type: "br" },
      { type: "text", value: "（2）制定并实施软件版本管理规范" },
      { type: "yesno", field: "C20A020"},
      { type: "br" },
      { type: "text", value: "（3）软件版本管理所采取的措施" },
      { type: "radio-group", field: "VSNMNG2",options:["手工管理","专业工具管理"]},
      { type: "br" },
      { type: "text", value: "（4）对程序资源库的修改、更新、发布进行授权和批准，并严格进行版本控制" },
      { type: "yesno", field: "C20A021"},
    ],
    remarks: {
      rows:11,
      field:"VSNMNG100"
    }
  },
  {
    serialNumber: "7",
    project: "投产管理",
    code: 'RLSMNG',
    content: [
      { type: "text", value: "（1）制定并实施系统投产管理规范" },
      { type: "yesno", field: "C20A022"},
      { type: "br" },
      { type: "text", value: "（2）重要信息系统建立与生产系统完全一致或基本一致的准生产系统" },
      { type: "yesno", field: "RLSMNG1"},
      { type: "br" },
      { type: "text", value: "（3）重要信息系统投产前，在准生产系统安装并测试" },
      { type: "radio-group", field: "RLSMNG2",options:["手工管理","专业工具管理"]},
      { type: "br" },
      { type: "text", value: "（4）重要信息系统投产变更前组织开展风险评估" },
      { type: "yesno", field: "C20A023"},
      { type: "br" },
      { type: "text", value: "（5）重要信息系统投产前开展投产评审工作" },
      { type: "yesno", field: "C20A024"},

      { type: "brspace" },
      { type: "text", value: "如是，负责投产评审的责任部门" },
      { 
        type: "checkbox-group", 
        field: "RLSMNG3",
        options: [
          "信息科技部门","业务部门"
        ],   
      },

      { type: "br" },
      { type: "text", value: "（6）重要信息系统投产时，同步发布操作手册等相关配套文档" },
      { type: "yesno", field: "C20A025"},
      { type: "br" },
    ],
    remarks: {
      rows:11,
      field:"RLSMNG100"
    }
  },
  {
    serialNumber: "8",
    project: "信息科技开发测试管理情况表-附件",
    code: 'ATTACH',
    type:"AttachTable",
    content:[
      { 
        field: 'col1',title: '名称', width:'20%',
      },{
        field: 'col2',title: '附件索引', width:'40%',slots: { default: 'form_default' },
      },{
        field: 'col3',title: '备注',slots: { default: 'form_default' },
      },
    ],
    datas: [
      { 
        col1: "信息科技项目管理明细报告",
        col2:{ formType:'input',field: "ATTACH1"},
        col3:{ formType:'input',field: "ATTACH100"},
      },
      { 
        col1: "开发安全管理规范（包含安全需求规范、应用安全技术规范、软件测试规范、软件版本管理规范、系统投产管理规范等）",
        col2:{ formType:'input',field: "C20A026"},
        col3:{ formType:'input',field: "ATTACH200"},
      },
  
    ],

    remarks: {
      rows:5,
      field:""
    }

  }
];


