|
@@ -1,6 +1,6 @@
|
|
|
import dayjs from "dayjs";
|
|
|
/**
|
|
|
- *
|
|
|
+ * 资格审查
|
|
|
* @param {*} workbook ExcelJs对象
|
|
|
* @param {*} sName 项目名称
|
|
|
* @param {*} kaibiaoTime 开标时间
|
|
@@ -186,7 +186,7 @@ export const genExamineExcel = (
|
|
|
};
|
|
|
|
|
|
/**
|
|
|
- *
|
|
|
+ * 响应性
|
|
|
* @param {*} workbook ExcelJs对象
|
|
|
* @param {*} sName 项目名称
|
|
|
* @param {*} kaibiaoTime 开标时间
|
|
@@ -372,7 +372,7 @@ export const genRespondExcel = (
|
|
|
};
|
|
|
|
|
|
/**
|
|
|
- *
|
|
|
+ * 技术性
|
|
|
* @param {*} workbook ExcelJs对象
|
|
|
* @param {*} sName 项目名称
|
|
|
* @param {*} kaibiaoTime 开标时间
|
|
@@ -569,3 +569,344 @@ export const genTechExcel = (
|
|
|
rowLast.height = 20;
|
|
|
rowLast.font = { name: "宋体", family: 4, size: 10 };
|
|
|
};
|
|
|
+
|
|
|
+/**
|
|
|
+ * 投标得分
|
|
|
+ * @param {*} workbook ExcelJs对象
|
|
|
+ * @param {*} tableData 数据
|
|
|
+ */
|
|
|
+export const genBidScoreExcel = (workbook, tableData) => {
|
|
|
+ const worksheet = workbook.addWorksheet("报价得分");
|
|
|
+ const columnWidth = [5, 34.5, 21.13, 21.13, 21.13, 21.13];
|
|
|
+ for (let cw = 1; cw <= columnWidth.length; cw++) {
|
|
|
+ worksheet.getColumn(cw).width = columnWidth[cw - 1] + 0.62;
|
|
|
+ }
|
|
|
+ worksheet.addRow(["投标报价得分计算表"]);
|
|
|
+ worksheet.mergeCells("A1:F1");
|
|
|
+ worksheet.getCell("A1").alignment = {
|
|
|
+ vertical: "middle",
|
|
|
+ horizontal: "center",
|
|
|
+ };
|
|
|
+ const row1 = worksheet.getRow(1);
|
|
|
+ row1.height = 32;
|
|
|
+ row1.font = { name: "宋体", family: 4, size: 20, bold: true };
|
|
|
+
|
|
|
+ worksheet.addRow(["", ""]);
|
|
|
+ worksheet.mergeCells("A2:C2");
|
|
|
+ worksheet.mergeCells("D2:F2");
|
|
|
+ const row2 = worksheet.getRow(2);
|
|
|
+ row2.height = 48;
|
|
|
+
|
|
|
+ worksheet.addRow([
|
|
|
+ "序号",
|
|
|
+ "投标人名称",
|
|
|
+ "投标报价(元)",
|
|
|
+ "评标基准价",
|
|
|
+ "偏差率(%)",
|
|
|
+ "报价得分",
|
|
|
+ ]);
|
|
|
+
|
|
|
+ const row3 = worksheet.getRow(3);
|
|
|
+ row3.height = 33;
|
|
|
+ row3.font = { name: "宋体", family: 4, size: 10.5 };
|
|
|
+
|
|
|
+ const tableHeader = ["A3", "B3", "C3", "D3", "E3", "F3"];
|
|
|
+ for (let th of tableHeader) {
|
|
|
+ worksheet.getCell(th).alignment = {
|
|
|
+ vertical: "middle",
|
|
|
+ horizontal: "center",
|
|
|
+ };
|
|
|
+ worksheet.getCell(th).border = {
|
|
|
+ top: { style: "thin" },
|
|
|
+ left: { style: "thin" },
|
|
|
+ bottom: { style: "thin" },
|
|
|
+ right: { style: "thin" },
|
|
|
+ };
|
|
|
+ }
|
|
|
+ const tableStartNum = 4;
|
|
|
+
|
|
|
+ const tbody = ["A", "B", "C", "D", "E", "F"];
|
|
|
+
|
|
|
+ for (let i = 0; i < tableData.length; i++) {
|
|
|
+ const data = [
|
|
|
+ i + 1,
|
|
|
+ tableData[i].hName,
|
|
|
+ tableData[i].quotePrice,
|
|
|
+ tableData[i].level,
|
|
|
+ tableData[i].percent,
|
|
|
+ tableData[i].score,
|
|
|
+ ];
|
|
|
+ for (let j = 0; j < data.length; j++) {
|
|
|
+ const td = tbody[j];
|
|
|
+ worksheet.getCell(`${td}${i + tableStartNum}`).border = {
|
|
|
+ top: { style: "thin" },
|
|
|
+ left: { style: "thin" },
|
|
|
+ bottom: { style: "thin" },
|
|
|
+ right: { style: "thin" },
|
|
|
+ };
|
|
|
+ let alignment = { vertical: "middle", horizontal: "center" };
|
|
|
+ let value = data[j];
|
|
|
+
|
|
|
+ worksheet.getCell(`${td}${i + tableStartNum}`).alignment = alignment;
|
|
|
+ worksheet.getCell(`${td}${i + tableStartNum}`).value = value;
|
|
|
+ worksheet.getCell(`${td}${i + tableStartNum}`).font = {
|
|
|
+ name: "宋体",
|
|
|
+ family: 4,
|
|
|
+ size: 10.5,
|
|
|
+ };
|
|
|
+ }
|
|
|
+ const row = worksheet.getRow(i + tableStartNum);
|
|
|
+ row.height = 30;
|
|
|
+ }
|
|
|
+
|
|
|
+ const huiZhongRowNum = tableData.length + tableStartNum;
|
|
|
+ worksheet.mergeCells(`D${tableStartNum}:D${huiZhongRowNum - 1}`);
|
|
|
+
|
|
|
+ worksheet.getCell(`A${huiZhongRowNum}`).alignment = {
|
|
|
+ vertical: "middle",
|
|
|
+ wrapText: true,
|
|
|
+ };
|
|
|
+ worksheet.getCell(`A${huiZhongRowNum}`).value = {
|
|
|
+ richText: [
|
|
|
+ {
|
|
|
+ font: { name: "宋体", family: 4, size: 11 },
|
|
|
+ text: `1、以评标标准值为基准,投标人的投标报价等于评标标准值得满分7分;
|
|
|
+2、每低于评标标准值的1%扣0.5分;
|
|
|
+3、每高于评标标准值的1%扣0.6分;
|
|
|
+4、中间值按插入法计算,所有计算得分最终保留小数点后2位,第3位将四舍五入。
|
|
|
+5、评标基准价计算方法:通过初步评审的投标报价参加报价得分计算。
|
|
|
+(1)有效投标报价<5家时,取所有有效投标报价的算数平均值为评标标准值;
|
|
|
+(2)有效投标报价≥5家时,去掉最高投标报价和最低投标报价后,其余有效投标报价的算数平均值为评标标准值。
|
|
|
+(3)分数值保留至小数点后两位,第三位四舍五入。
|
|
|
+6、投标报价的偏差率计算公式:
|
|
|
+偏差率=(投标报价−评标基准价)/评标基准价×100%`,
|
|
|
+ },
|
|
|
+ ],
|
|
|
+ };
|
|
|
+ worksheet.mergeCells(`A${huiZhongRowNum}:F${huiZhongRowNum}`);
|
|
|
+ worksheet.getCell(`A${huiZhongRowNum}`).border = {
|
|
|
+ top: { style: "thin" },
|
|
|
+ left: { style: "thin" },
|
|
|
+ bottom: { style: "thin" },
|
|
|
+ right: { style: "thin" },
|
|
|
+ };
|
|
|
+ const rowDenfen = worksheet.getRow(huiZhongRowNum);
|
|
|
+ rowDenfen.height = 141;
|
|
|
+
|
|
|
+ const lastRowNum = huiZhongRowNum + 1;
|
|
|
+ worksheet.addRow(["评标委员会成员签字:"]);
|
|
|
+ worksheet.mergeCells(`A${lastRowNum}:E${lastRowNum}`);
|
|
|
+ worksheet.getCell(`A${lastRowNum}`).alignment = { vertical: "middle" };
|
|
|
+ const rowLast = worksheet.getRow(lastRowNum);
|
|
|
+ rowLast.height = 28;
|
|
|
+ rowLast.font = { name: "宋体", family: 4, size: 10.5 };
|
|
|
+};
|
|
|
+
|
|
|
+/**
|
|
|
+ * 得分汇总
|
|
|
+ * @param {*} workbook ExcelJs对象
|
|
|
+ * @param {*} tableData 数据
|
|
|
+ */
|
|
|
+export const genTotalScoreExcel = (workbook, tableData, zjNames) => {
|
|
|
+ const worksheet = workbook.addWorksheet("评分汇总");
|
|
|
+ const columnWidth = [
|
|
|
+ 4.57, 35.25, 11.75, 11.75, 11.75, 11.75, 11.75, 9.48, 9.48, 9.48, 7.88,
|
|
|
+ ];
|
|
|
+ for (let cw = 1; cw <= columnWidth.length; cw++) {
|
|
|
+ worksheet.getColumn(cw).width = columnWidth[cw - 1] + 0.62;
|
|
|
+ }
|
|
|
+ worksheet.addRow([""]);
|
|
|
+ worksheet.mergeCells("A1:K1");
|
|
|
+ worksheet.getCell("A1").alignment = {
|
|
|
+ vertical: "middle",
|
|
|
+ horizontal: "center",
|
|
|
+ };
|
|
|
+ const row1 = worksheet.getRow(1);
|
|
|
+ row1.height = 30;
|
|
|
+ row1.font = { name: "宋体", family: 4, size: 16, bold: true };
|
|
|
+
|
|
|
+ worksheet.addRow(["评委评分汇总表"]);
|
|
|
+ worksheet.mergeCells("A2:K2");
|
|
|
+ worksheet.getCell("A2").alignment = {
|
|
|
+ vertical: "middle",
|
|
|
+ horizontal: "center",
|
|
|
+ };
|
|
|
+ const row2 = worksheet.getRow(2);
|
|
|
+ row2.height = 30;
|
|
|
+ row2.font = { name: "宋体", family: 4, size: 16, bold: true };
|
|
|
+
|
|
|
+ worksheet.addRow(["", ""]);
|
|
|
+ worksheet.mergeCells("A3:E3");
|
|
|
+ worksheet.mergeCells("F3:K3");
|
|
|
+ const row3 = worksheet.getRow(3);
|
|
|
+ row3.height = 48;
|
|
|
+
|
|
|
+ worksheet.addRow([
|
|
|
+ "序号",
|
|
|
+ "投标人名称",
|
|
|
+ "技术部分评分",
|
|
|
+ "",
|
|
|
+ "",
|
|
|
+ "",
|
|
|
+ "",
|
|
|
+ "综合得分",
|
|
|
+ "报价得分",
|
|
|
+ "总得分",
|
|
|
+ "排序",
|
|
|
+ ]);
|
|
|
+
|
|
|
+ worksheet.mergeCells("C4:G4");
|
|
|
+
|
|
|
+ //专家
|
|
|
+ let zjData = ["", ""];
|
|
|
+ zjData = zjData.concat(zjNames);
|
|
|
+ zjData.push("");
|
|
|
+ zjData.push("");
|
|
|
+ zjData.push("");
|
|
|
+ zjData.push("");
|
|
|
+ worksheet.addRow(zjData);
|
|
|
+
|
|
|
+ const mergeHeader = ["A", "B", "H", "I", "J", "K"];
|
|
|
+ for (let i = 0; i < mergeHeader.length; i++) {
|
|
|
+ worksheet.mergeCells(`${mergeHeader[i]}4:${mergeHeader[i]}5`);
|
|
|
+ worksheet.getCell(`${mergeHeader[i]}4`).alignment = {
|
|
|
+ vertical: "middle",
|
|
|
+ horizontal: "center",
|
|
|
+ };
|
|
|
+ worksheet.getCell(`${mergeHeader[i]}4`).border = {
|
|
|
+ top: { style: "thin" },
|
|
|
+ left: { style: "thin" },
|
|
|
+ bottom: { style: "thin" },
|
|
|
+ right: { style: "thin" },
|
|
|
+ };
|
|
|
+ }
|
|
|
+
|
|
|
+ const row4 = worksheet.getRow(4);
|
|
|
+ row4.height = 32;
|
|
|
+ row4.font = { name: "宋体", family: 4, size: 10.5, bold: true };
|
|
|
+
|
|
|
+ const row5 = worksheet.getRow(5);
|
|
|
+ row5.height = 46;
|
|
|
+ row5.font = { name: "宋体", family: 4, size: 10.5, bold: true };
|
|
|
+
|
|
|
+ const zjHeader = ["C", "D", "E", "F", "G"];
|
|
|
+ for (let i = 0; i < zjHeader.length; i++) {
|
|
|
+ worksheet.getCell(`${zjHeader[i]}4`).alignment = {
|
|
|
+ vertical: "middle",
|
|
|
+ horizontal: "center",
|
|
|
+ };
|
|
|
+ worksheet.getCell(`${zjHeader[i]}4`).font = {
|
|
|
+ name: "宋体",
|
|
|
+ family: 4,
|
|
|
+ size: 10.5,
|
|
|
+ };
|
|
|
+ worksheet.getCell(`${zjHeader[i]}4`).border = {
|
|
|
+ top: { style: "thin" },
|
|
|
+ left: { style: "thin" },
|
|
|
+ bottom: { style: "thin" },
|
|
|
+ right: { style: "thin" },
|
|
|
+ };
|
|
|
+ worksheet.getCell(`${zjHeader[i]}5`).alignment = {
|
|
|
+ vertical: "middle",
|
|
|
+ horizontal: "center",
|
|
|
+ };
|
|
|
+ worksheet.getCell(`${zjHeader[i]}5`).font = {
|
|
|
+ name: "宋体",
|
|
|
+ family: 4,
|
|
|
+ size: 10.5,
|
|
|
+ };
|
|
|
+ worksheet.getCell(`${zjHeader[i]}5`).border = {
|
|
|
+ top: { style: "thin" },
|
|
|
+ left: { style: "thin" },
|
|
|
+ bottom: { style: "thin" },
|
|
|
+ right: { style: "thin" },
|
|
|
+ };
|
|
|
+ }
|
|
|
+
|
|
|
+ const tableStartNum = 6;
|
|
|
+
|
|
|
+ const tbody = ["A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K"];
|
|
|
+
|
|
|
+ let zhongbiaoren = "";
|
|
|
+ for (let i = 0; i < tableData.length; i++) {
|
|
|
+ const techList = tableData[i].techList;
|
|
|
+ const data = [i + 1, tableData[i].hName];
|
|
|
+ if (i == 0) {
|
|
|
+ zhongbiaoren = tableData[i].hName;
|
|
|
+ }
|
|
|
+ for (let j = 0; j < techList.length; j++) {
|
|
|
+ data.push(techList[j].score);
|
|
|
+ }
|
|
|
+ data.push(tableData[i].averScore);
|
|
|
+ data.push(tableData[i].priceScore);
|
|
|
+ data.push(tableData[i].totalScore);
|
|
|
+ data.push(i + 1);
|
|
|
+ for (let j = 0; j < data.length; j++) {
|
|
|
+ const td = tbody[j];
|
|
|
+ worksheet.getCell(`${td}${i + tableStartNum}`).border = {
|
|
|
+ top: { style: "thin" },
|
|
|
+ left: { style: "thin" },
|
|
|
+ bottom: { style: "thin" },
|
|
|
+ right: { style: "thin" },
|
|
|
+ };
|
|
|
+ let alignment = { vertical: "middle", horizontal: "center" };
|
|
|
+ let value = data[j];
|
|
|
+ worksheet.getCell(`${td}${i + tableStartNum}`).alignment = alignment;
|
|
|
+ worksheet.getCell(`${td}${i + tableStartNum}`).value = value;
|
|
|
+ worksheet.getCell(`${td}${i + tableStartNum}`).font = {
|
|
|
+ name: "宋体",
|
|
|
+ family: 4,
|
|
|
+ size: 12,
|
|
|
+ };
|
|
|
+ }
|
|
|
+ const row = worksheet.getRow(i + tableStartNum);
|
|
|
+ row.height = 39;
|
|
|
+ }
|
|
|
+
|
|
|
+ const zhongbiaorenRowNum = tableData.length + tableStartNum;
|
|
|
+ worksheet.addRow(["预中标人", "", zhongbiaoren]);
|
|
|
+ worksheet.mergeCells(`A${zhongbiaorenRowNum}:B${zhongbiaorenRowNum}`);
|
|
|
+ worksheet.mergeCells(`C${zhongbiaorenRowNum}:K${zhongbiaorenRowNum}`);
|
|
|
+
|
|
|
+ worksheet.getCell(`A${zhongbiaorenRowNum}`).border = {
|
|
|
+ top: { style: "thin" },
|
|
|
+ left: { style: "thin" },
|
|
|
+ bottom: { style: "thin" },
|
|
|
+ right: { style: "thin" },
|
|
|
+ };
|
|
|
+ worksheet.getCell(`A${zhongbiaorenRowNum}`).alignment = {
|
|
|
+ vertical: "middle",
|
|
|
+ horizontal: "center",
|
|
|
+ };
|
|
|
+ worksheet.getCell(`A${zhongbiaorenRowNum}`).font = {
|
|
|
+ name: "宋体",
|
|
|
+ family: 4,
|
|
|
+ size: 12,
|
|
|
+ };
|
|
|
+ worksheet.getCell(`C${zhongbiaorenRowNum}`).border = {
|
|
|
+ top: { style: "thin" },
|
|
|
+ left: { style: "thin" },
|
|
|
+ bottom: { style: "thin" },
|
|
|
+ right: { style: "thin" },
|
|
|
+ };
|
|
|
+ worksheet.getCell(`C${zhongbiaorenRowNum}`).alignment = {
|
|
|
+ vertical: "middle",
|
|
|
+ horizontal: "center",
|
|
|
+ };
|
|
|
+ worksheet.getCell(`C${zhongbiaorenRowNum}`).font = {
|
|
|
+ name: "宋体",
|
|
|
+ family: 4,
|
|
|
+ size: 12,
|
|
|
+ };
|
|
|
+
|
|
|
+ const rowZhongbiaoren = worksheet.getRow(zhongbiaorenRowNum);
|
|
|
+ rowZhongbiaoren.height = 39;
|
|
|
+
|
|
|
+ const lastRowNum = zhongbiaorenRowNum + 1;
|
|
|
+ worksheet.addRow(["评标委员会全体成员签字:"]);
|
|
|
+ worksheet.mergeCells(`A${lastRowNum}:B${lastRowNum}`);
|
|
|
+ worksheet.getCell(`A${lastRowNum}`).alignment = { vertical: "bottom" };
|
|
|
+ const rowLast = worksheet.getRow(lastRowNum);
|
|
|
+ rowLast.height = 28;
|
|
|
+ rowLast.font = { name: "宋体", family: 4, size: 12 };
|
|
|
+};
|