import { MockRequest } from '@delon/mock'; // 项目执行 const projectImplementationList = ["67", "37", "43", "26", "27", "17", null, "13", null, "12", "35", "34", "0", "64", "66", "30", "56", "41", "42" , "60", "63", null, "38", null, "32", null, "33", null, "65", "31", "56", "40", "42", "60", "40", "42", "56", "57", "55", "58", "26", "1", "2", "7", "9", "45", "36", "53", "54", "10", "46", "47", "62", "8", "59", "26", "48", "69", "51", "52", "20", "68", "49", "50", "5", "21", "61", "39", "24", "25", "29", "22", "23", "11", "28", "44", "6", "3", "4", "11", "39", "26", "18", "44", "15", "14", "16", "19", "5"]; // 工时 const workingHourList = [12, 7, 28, 10, 10, 12, 4, 12, 4, 36, 12, 20, 8, 32, 16, 16, 44, 42, 28, 8, 8, 16, 16, 8, 320, 16, 16, 4, 16, 24, 24, 24, 24, 10, 24, 14, 7, 8, 8, 24, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null]; // 预计成本 const estimatedCost = [2064, 1204, 4816, 1720, 1720, 2064, 688, 2064, 688, 6192, 2064, 3440, 1376, 5504, 2752, 2752, 7568, 7224, 4816, 1376, 1376, 2752, 2752, 1376, 55040, 2752, 2752, 688, 2752, 4128, 4128, 4128, 4128, 1720, 4128, 2408, 1204, 1376, 1376, 4128, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null]; // 备注 const memoList = ["假设是共建中心,中心对接;(非共建中心额外增加工时和差旅)", "假设议程2h,会议3h,纪要2h", "伦理计划沟通,timeline沟通,2小时/周,14周;", null, "假设TC会议4h, 会前准备4h, 会后总结2h;如需出差,需另外结算;", "假设PMP 起草4h,审阅修订6h,定稿2h", "假设PD审阅PMP 4h", "假设MP 起草6h,审阅修订4h,定稿2h", "假设PD审阅MP 4h", "ICF-12h,SD-20h,AD-4h", "假设伦理材料 12h", "EC binder 准备8h;递交12h", null, "遗传资料准备,审阅,签章搜集", "合同起草和审阅12h,沟通和签署12h。", "供应商(CRC和招募)选择8h,合同起草,审阅签署8h;", "TMF创建2h, 和更新,3h/周,预估14周", "与申办方沟通/会议/周报:伦理阶段,每周3h,14周;", "CRO内部沟通/会议/周期:伦理阶段,每周2h,预估14周;", "DM相关文件-4h, SAP-2h, 验证和分析方案-2h;", "启动会PPT准备和审阅6h,培训2h;", "启动会培训", "会前准备,物资等4h,启动会4h,报告4h;差旅8h;", "会前审阅4h,报告审阅4h;", "本项目合同约定空腹、餐后各5次常规监查,每次32h;", "报告审阅+定稿,4小时/次;", "假设onsite 8h,报告4h;差旅8h;", "报告审阅+定稿,4小时/次;", "假设20h/次,8h onsite,8h 差旅,4小时报告+定稿;预估2次;", "假设1供应商(CRC);每周2h,预估10周;如有其它外部供应商,需增加工时;", "TMF文档更新,2h/周,预估10周;", "与申办方沟通/会议/周报:临床数据阶段,每周4h,预估9周;", "CRO内部沟通/会议/周报:临床数据阶段,每周4h,预估9周;", "DMR-2h; SAR-2h; Bio-R-2h; CSR-4h;", "与申办方沟通/会议/周报:主攻结题阶段,每周4h,预估7周;", "CRO内部沟通/会议/周报:主攻结题阶段,每周2h,预估7周;", "TMF更新并转交申办方,1h/周,预估7周;", null, "打印邮寄", "各方盖章邮寄12h/周;"]; function setBaseData(): any[] { const list: any[] = []; for (let i = 0; i < 89;) { list.push({ index: i++, contractorId: "1", // 公司 departId: "0", // 部门 projectPhaseId: "9",// 项目阶段 phaseId: "2", // 阶段 projectImplementationId: projectImplementationList[i - 1],// 项目执行 roleId: "3", // 角色 hour: workingHourList[i - 1], // 工时 unitCost: 172, // 单位人工成本 estimatedCost: estimatedCost[i - 1], // 预计成本 memo: memoList[i - 1], // 注释 sort: i, }) } // CSR 0 // 锁库 1 // 准备 2 list.forEach((element, i) => { if (i > 18) { element.projectPhaseId = "3" element.phaseId = "1" } if (i > 32) { element.projectPhaseId = "8" element.phaseId = "0" } if (i > 36) { element.projectPhaseId = "7" } if (i > 39) { element.departId = "2" element.phaseId = "2" element.roleId = null element.projectPhaseId = "5" } if (i > 42) { element.phaseId = "1" } if (i > 54) { element.projectPhaseId = "6" } if (i > 60) { element.phaseId = "0" } if (i > 66) { element.departId = "1" element.phaseId = "2" element.projectPhaseId = "2" } if (i > 74) { element.projectPhaseId = "0" element.phaseId = "0" } if (i > 79) { element.projectPhaseId = "1" } if (i === 0 || i === 1) { element.projectPhaseId = "4" } if (i === 55) { element.phaseId = "2" } if (i === 6 || i === 8) { element.roleId = "2" } if (i === 16 || i === 30 || i === 36 || i === 38) { element.roleId = "1" } if (i === 21 || i === 22 || i === 24 || i === 26) { element.roleId = "0" } }) return list; } /** * @description: 过手费成本 * @param {type} * @author: 段亚鑫 */ const costOverchargeList = ["0", "1", "2", "3", "4", "5", "6"]; // 过手费成本 const company = ["2", null, "2", null, null, "1", "2"];// 公司 const contractPartyName = ["上海方达生物技术有限公司", null, "上海方达生物技术有限公司", null, null, "方达医药技术(上海)有限公司", "上海方达生物技术有限公司"];// 公司name const hospitalList = ['新郑市人民医院', null, '康贝瑞', null, null, null, '保险'];// 临床中心 const startDate = ['2019-06-04', null, '2019-08-01', null, null, '2019-01-01'];// 计划开始日期 const endDate = [null, null, '2020-08-01', null, null, '2020-12-31']; // 计划结束日期 const numberOfSubjects = [null, null, 52]; const unitCostList = [null, null, 3200]; const moneyList = [5000, null, 166400, null, null, 26400, 15600]; const taxRate = ["6", null, "3", null, null, "0", "6"]; const costExcludesTaxes = [4716.98, null, 161553.40, null, null, 26400.00, 14716.98]; function setDisposalCost(): any[] { const dataList: any[] = []; for (let i = 0; i < 7;) { i.toString(); dataList.push({ costOverchargeId: costOverchargeList[i++], contractPartyId: company[i - 1], // 内存溢出 contractPartyName: contractPartyName[i - 1], clinicalCenter: hospitalList[i - 1], startDate: startDate[i - 1], endDate: endDate[i - 1], numberOfSubjects: numberOfSubjects[i - 1], unitCost: unitCostList[i - 1], money: moneyList[i - 1], tax: taxRate[i - 1], costNotTax: costExcludesTaxes[i - 1], index: i }) } return dataList; } /** * @description: 差旅费用 * @param {type} * @author: 段亚鑫 */ const travelExpense = ["0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13"]; const wordsFee = ["1000", "100", "200", "2000", "1000", "1000", "1000", "1000", "0", "1000", "1000", "200", "200", "200"]; const traveExpectedNumber = [1, 6, 2, 2, 8, 2, 1, 1, 0, 4, 1, 0, 2, 0]; const traveFees = [1000, 600, 400, 4000, 8000, 2000, 1000, 1000, 0, 4000, 1000, 0, 400, 0]; function setTravelExpense() { const data = []; for (let i = 0; i < 14;) { data.push({ costType: "01", index: i++, costId: travelExpense[i - 1], singleCost: wordsFee[i - 1], estimateFrequency: traveExpectedNumber[i - 1], total: traveFees[i - 1] }) } return data; } /** * @description: 文件打印和运输费用 * @param {type} * @author: 段亚鑫 */ // 伦理打印费 0 修改删除 // 其他文件 1 const filePrintCostList = ["0", "1"]; const singleCostList = ["300", "200"]; const fileFees = [600, 400]; function setFilePrintCost() { const data = []; for (let i = 0; i < 2;) { data.push({ costType: "02", index: i++, costId: filePrintCostList[i - 1], singleCost: singleCostList[i - 1], estimateFrequency: 2, total: fileFees[i - 1] }) } return data; } /** * @description: 固定费用 * @param {type} * @author: 段亚鑫 */ const onceFees = ["100", "500"]; const fixed_FrequencyList = ["10", "2"]; const fixedFees = [1000, 1000]; function setOtherFixedFees() { const data = []; for (let i = 0; i < 2;) { data.push({ costType: "03", index: i++, costId: filePrintCostList[i - 1], singleCost: onceFees[i - 1], estimateFrequency: fixed_FrequencyList[i - 1], total: fixedFees[i - 1] }) } return data; } export const data = { '/baseData/list': () => setBaseData(), '/baseData/disposCost': () => setDisposalCost(), '/baseData/travelExpense': () => setTravelExpense(), "/baseData/filePrintCost": () => setFilePrintCost(), "/baseData/otherFixedFees": () => setOtherFixedFees() };