|
@@ -433,7 +433,7 @@ const XMLStandard = (function () {
|
|
|
const attrs = [
|
|
|
// 项目编号
|
|
|
{
|
|
|
- name: 'Number', dName: '项目编号', required: true,
|
|
|
+ name: 'Number', dName: '工程编号', required: true, minLen: 1,
|
|
|
value: _util.getValueByKey(basicInformation, 'projNum')
|
|
|
},
|
|
|
// 项目名称
|
|
@@ -449,7 +449,7 @@ const XMLStandard = (function () {
|
|
|
// 工程类型
|
|
|
{
|
|
|
name: 'ProjectType', dName: '工程类型', required: true,
|
|
|
- value: getProjectType(projectData, true)
|
|
|
+ value: _util.getValueByKey(basicInformation, 'projectType')
|
|
|
},
|
|
|
// 建设性质
|
|
|
{
|
|
@@ -483,7 +483,7 @@ const XMLStandard = (function () {
|
|
|
},
|
|
|
// 建设单位
|
|
|
{
|
|
|
- name: 'BulidUnit', dName: '建设单位', required: true,
|
|
|
+ name: 'BulidUnit', dName: '建设单位', required: true, minLen: 1,
|
|
|
value: _util.getValueByKey(basicInformation, 'constructingUnits')
|
|
|
},
|
|
|
// 建设单位法定代表人或其授权人
|
|
@@ -499,7 +499,7 @@ const XMLStandard = (function () {
|
|
|
// 数据交换标准编号
|
|
|
{
|
|
|
name: 'StandardNumber', required: true,
|
|
|
- value: 'DBJ/T XX-XX-2018'
|
|
|
+ value: 'DBJ/T 15-145-2018'
|
|
|
},
|
|
|
// 建设(编制)范围
|
|
|
{
|
|
@@ -513,7 +513,7 @@ const XMLStandard = (function () {
|
|
|
},
|
|
|
// 建设规模单位
|
|
|
{
|
|
|
- name: 'Unit', dName: '建设规模单位', required: true,
|
|
|
+ name: 'Unit', dName: '建设规模单位', required: true, minLen: 1,
|
|
|
value: _util.getValueByKey(basicInformation, 'unit')
|
|
|
},
|
|
|
// 技术经济指标(元) 取单方造价
|
|
@@ -619,7 +619,7 @@ const XMLStandard = (function () {
|
|
|
},
|
|
|
// 招标单位编制时间
|
|
|
{
|
|
|
- name: 'TenderCompileDate', mustHasValue: true,
|
|
|
+ name: 'TenderCompileDate', mustHasValue: true, required: true,
|
|
|
value: _util.getValueByKey(basicInformation, 'tenderCompileDate')
|
|
|
},
|
|
|
// 招标单位审核人
|
|
@@ -1081,7 +1081,7 @@ const XMLStandard = (function () {
|
|
|
},
|
|
|
// 工程类型
|
|
|
{
|
|
|
- name: 'ProjectType', dName: '工程类型', required: true,
|
|
|
+ name: 'ProjectType', dName: '工程类型', required: true, minLen: 1,
|
|
|
value: _util.getValueByKey(projectFeature, 'projType')
|
|
|
},
|
|
|
// 计价模式
|
|
@@ -1096,7 +1096,7 @@ const XMLStandard = (function () {
|
|
|
},
|
|
|
// 地区类别 取建设项目-基本信息-地区类别,基本信息那已经自检一次,这里不自检 //type: _type.INT, required: true, enumeration: Object.values(AreaKind), enumerationHint: Object.keys(AreaKind)
|
|
|
{
|
|
|
- name: 'AreaKind', dName: '地区类别',
|
|
|
+ name: 'AreaKind', dName: '地区类别',
|
|
|
value: AreaKind[_util.getValueByKey(basicInformation, 'regionalCategories')]
|
|
|
},
|
|
|
// 金额
|
|
@@ -1126,7 +1126,7 @@ const XMLStandard = (function () {
|
|
|
},
|
|
|
// 建设规模单位 取单位工程-工程特征-建设规模单位
|
|
|
{
|
|
|
- name: 'Unit', dName: '建设规模单位', required: true,
|
|
|
+ name: 'Unit', dName: '建设规模单位', required: true, minLen: 1,
|
|
|
value: _util.getValueByKey(projectFeature, 'buildScaleUnit')
|
|
|
},
|
|
|
// 占总投资比例(%)
|
|
@@ -1433,23 +1433,24 @@ const XMLStandard = (function () {
|
|
|
// 清单项目
|
|
|
function WorkElement(node, kind, specialty) {
|
|
|
const bills = node.data;
|
|
|
+ const row = node.serialNo() + 1;
|
|
|
const attrs = [
|
|
|
// 项目编码
|
|
|
- { name: 'Number', dName: '项目编码', required: true, value: bills.code || '' },
|
|
|
+ { name: 'Number', dName: '项目编码', required: true, value: bills.code || '', minLen: 1, failHint: `第${row}行清单-“项目编码”` },
|
|
|
// 项目名称
|
|
|
- { name: 'Name', dName: '项目名称', required: true, value: bills.name },
|
|
|
+ { name: 'Name', dName: '项目名称', required: true, value: bills.name, minLen: 1, failHint: `第${row}行清单-“项目名称”` },
|
|
|
// 项目特征
|
|
|
{ name: 'Attr', value: bills.itemCharacterText },
|
|
|
// 工作内容
|
|
|
{ name: 'WorkContent', value: bills.jocContentText },
|
|
|
// 计量单位
|
|
|
- { name: 'Unit', dName: '计量单位', required: true, value: bills.unit },
|
|
|
+ { name: 'Unit', dName: '计量单位', required: true, value: bills.unit, minLen: 1, failHint: `第${row}行清单-“计量单位”` },
|
|
|
// 工程量
|
|
|
{ name: 'Quantity', type: _type.DECIMAL, value: bills.quantity },
|
|
|
// 计算基数
|
|
|
{ name: 'QtyFormula', value: getQtyFormula(node) },
|
|
|
// 单价(元)
|
|
|
- { name: 'Price', type: _type.DECIMAL, value: _util.getFee(bills.fees, 'common.unitFee') },
|
|
|
+ //{ name: 'Price', type: _type.DECIMAL, value: _util.getFee(bills.fees, 'common.unitFee') },
|
|
|
// 设备单价(元)指清单项目所采用设备的综合单价
|
|
|
{ name: 'EquipmentPrice', type: _type.DECIMAL, value: _util.getFee(bills.fees, 'equipment.unitFee') },
|
|
|
// 最低限价(元)
|
|
@@ -1457,7 +1458,7 @@ const XMLStandard = (function () {
|
|
|
// 最高限价(元)
|
|
|
{ name: 'PriceHigh', type: _type.DECIMAL, value: bills.maxPrice },
|
|
|
// 费率(%)
|
|
|
- { name: 'Rate', type: _type.DECIMAL, value: !commonUtil.isEmptyVal(bills.feeRate) ? bills.feeRate : '100' },
|
|
|
+ //{ name: 'Rate', type: _type.DECIMAL, value: !commonUtil.isEmptyVal(bills.feeRate) ? bills.feeRate : '100' },
|
|
|
// 合价(元)
|
|
|
{ name: 'Total', type: _type.DECIMAL, value: _util.getFee(bills.fees, 'common.totalFee') },
|
|
|
// 主要清单
|
|
@@ -1479,6 +1480,13 @@ const XMLStandard = (function () {
|
|
|
// 备注
|
|
|
{ name: 'Remark', value: bills.remark }
|
|
|
];
|
|
|
+ // 单价费率,单价与费率在同一个费用项目中不允许同时存在。(对于套定额的清单,则输出单价不输出费率rate;对于基数计算的,则输出费率不输出单价)
|
|
|
+ const showPrice = !!(node.children && node.children.length && node.children[0].sourceType === commonConstants.SourceType.RATION)
|
|
|
+ if (showPrice) {
|
|
|
+ attrs.push({ name: 'Price', type: _type.DECIMAL, value: _util.getFee(bills.fees, 'common.unitFee') });
|
|
|
+ } else {
|
|
|
+ attrs.push({ name: 'Rate', type: _type.DECIMAL, value: !commonUtil.isEmptyVal(bills.feeRate) ? bills.feeRate : '100' });
|
|
|
+ }
|
|
|
_base.Element.call(this, 'WorkElement', attrs, '清单');
|
|
|
}
|
|
|
// 工程量计算表
|
|
@@ -1507,16 +1515,18 @@ const XMLStandard = (function () {
|
|
|
_base.Element.call(this, 'WorkContent', attrs, '工序内容');
|
|
|
}
|
|
|
// 定额子目
|
|
|
- function Norm(ration, libCode, kind) {
|
|
|
+ function Norm(node, libCode, kind) {
|
|
|
+ const ration = node.data;
|
|
|
+ const row = node.serialNo() + 1;
|
|
|
// 通过定额库编码,读取编码中间的数字,如房建定额库编码是“GD 1 2018",工程专业取“1”。
|
|
|
const reg = /GD (\d+)/;
|
|
|
const matched = libCode.match(reg);
|
|
|
const specialty = matched && matched[1] || '1';
|
|
|
const attrs = [
|
|
|
// 定额编码
|
|
|
- { name: 'Number', dName: '定额编码', required: true, value: ration.code },
|
|
|
- { name: 'Name', dName: '定额名称', required: true, value: ration.name },
|
|
|
- { name: 'Unit', dName: '计量单位', required: true, value: ration.unit },
|
|
|
+ { name: 'Number', dName: '定额编码', required: true, value: ration.code, minLen: 1, failHint: `第${row}行定额-“定额编码”` },
|
|
|
+ { name: 'Name', dName: '定额名称', required: true, value: ration.name, minLen: 1, failHint: `第${row}行定额-“定额名称”` },
|
|
|
+ { name: 'Unit', dName: '计量单位', required: true, value: ration.unit, minLen: 1, failHint: `第${row}行定额-“计量单位”` },
|
|
|
{ name: 'Quantity', type: _type.DECIMAL, value: ration.quantity },
|
|
|
// 单价
|
|
|
{ name: 'Price', type: _type.DECIMAL, value: _util.getFee(ration.fees, 'common.unitFee') },
|
|
@@ -1580,7 +1590,7 @@ const XMLStandard = (function () {
|
|
|
// 工料机编码
|
|
|
{ name: 'Number', value: glj.code },
|
|
|
// 消耗量
|
|
|
- { name: 'Quantity', type: _type.DECIMAL, value: quantity },
|
|
|
+ { name: 'Quantity', type: _type.DECIMAL, value: (+quantity).toFixed(Decimal.GLJ) },
|
|
|
// 不计价材料
|
|
|
{ name: 'NOCost', typ: _type.BOOL, value: noCost },
|
|
|
// 备注
|
|
@@ -1659,9 +1669,9 @@ const XMLStandard = (function () {
|
|
|
// 计算基数
|
|
|
{ name: 'QtyFormula', value: getQtyFormula(node) },
|
|
|
// 单价
|
|
|
- { name: 'Price', type: _type.DECIMAL, value: _util.getFee(bills.fees, 'common.unitFee') },
|
|
|
+ //{ name: 'Price', type: _type.DECIMAL, value: _util.getFee(bills.fees, 'common.unitFee') },
|
|
|
// 费率
|
|
|
- { name: 'Rate', type: _type.DECIMAL, value: !commonUtil.isEmptyVal(bills.feeRate) ? bills.feeRate : '100' },
|
|
|
+ //{ name: 'Rate', type: _type.DECIMAL, value: !commonUtil.isEmptyVal(bills.feeRate) ? bills.feeRate : '100' },
|
|
|
// 金额
|
|
|
{ name: 'Total', type: _type.DECIMAL, value: _util.getFee(bills.fees, 'common.totalFee') },
|
|
|
// 费用代号
|
|
@@ -1671,7 +1681,14 @@ const XMLStandard = (function () {
|
|
|
// 备注
|
|
|
{ name: 'Remark', value: bills.remark }
|
|
|
];
|
|
|
- _base.Element.call(this, 'SundryCostsItem', attrs, '其他项目费明细');
|
|
|
+ // 单价费率,单价与费率在同一个费用项目中不允许同时存在。(对于套定额的清单,则输出单价不输出费率rate;对于基数计算的,则输出费率不输出单价)
|
|
|
+ const showPrice = !!(node.children && node.children.length && node.children[0].sourceType === commonConstants.SourceType.RATION);
|
|
|
+ if (showPrice) {
|
|
|
+ attrs.push({ name: 'Price', type: _type.DECIMAL, value: _util.getFee(bills.fees, 'common.unitFee') });
|
|
|
+ } else {
|
|
|
+ attrs.push({ name: 'Rate', type: _type.DECIMAL, value: !commonUtil.isEmptyVal(bills.feeRate) ? bills.feeRate : '100' });
|
|
|
+ }
|
|
|
+ _base.Element.call(this, 'SundryCostsItem', attrs, '清单');
|
|
|
}
|
|
|
// 暂列金额标题
|
|
|
function ProvisionalSumsGroup(node) {
|
|
@@ -1701,9 +1718,9 @@ const XMLStandard = (function () {
|
|
|
// 计算基数
|
|
|
{ name: 'QtyFormula', value: getQtyFormula(node) },
|
|
|
// 单价
|
|
|
- { name: 'Price', type: _type.DECIMAL, value: _util.getFee(bills.fees, 'common.unitFee') },
|
|
|
+ //{ name: 'Price', type: _type.DECIMAL, value: _util.getFee(bills.fees, 'common.unitFee') },
|
|
|
// 费率
|
|
|
- { name: 'Rate', type: _type.DECIMAL, value: !commonUtil.isEmptyVal(bills.feeRate) ? bills.feeRate : '100' },
|
|
|
+ // { name: 'Rate', type: _type.DECIMAL, value: !commonUtil.isEmptyVal(bills.feeRate) ? bills.feeRate : '100' },
|
|
|
// 金额
|
|
|
{ name: 'Total', type: _type.DECIMAL, value: _util.getFee(bills.fees, 'common.totalFee') },
|
|
|
// 汇总类型
|
|
@@ -1711,6 +1728,13 @@ const XMLStandard = (function () {
|
|
|
// 备注
|
|
|
{ name: 'Remark', value: bills.remark }
|
|
|
];
|
|
|
+ // 单价费率,单价与费率在同一个费用项目中不允许同时存在。(对于套定额的清单,则输出单价不输出费率rate;对于基数计算的,则输出费率不输出单价)
|
|
|
+ const showPrice = !!(node.children && node.children.length && node.children[0].sourceType === commonConstants.SourceType.RATION);
|
|
|
+ if (showPrice) {
|
|
|
+ attrs.push({ name: 'Price', type: _type.DECIMAL, value: _util.getFee(bills.fees, 'common.unitFee') });
|
|
|
+ } else {
|
|
|
+ attrs.push({ name: 'Rate', type: _type.DECIMAL, value: !commonUtil.isEmptyVal(bills.feeRate) ? bills.feeRate : '100' });
|
|
|
+ }
|
|
|
_base.Element.call(this, 'ProvisionalSumsItem', attrs, '暂列金额明细');
|
|
|
}
|
|
|
// 材料设备暂估价明细
|
|
@@ -1724,7 +1748,7 @@ const XMLStandard = (function () {
|
|
|
// 型号规格
|
|
|
{ name: 'Specification', value: glj.specs },
|
|
|
// 单位
|
|
|
- { name: 'Unit', dName: '单位', required: true, value: bills.unit },
|
|
|
+ { name: 'Unit', dName: '单位', required: true, value: glj.unit },
|
|
|
// 工程量(总消耗量)
|
|
|
{ name: 'Quantity', type: _type.DECIMAL, value: glj.quantity },
|
|
|
// 单价 取市场价
|
|
@@ -1768,9 +1792,9 @@ const XMLStandard = (function () {
|
|
|
// 计算基数
|
|
|
{ name: 'QtyFormula', value: getQtyFormula(node) },
|
|
|
// 单价
|
|
|
- { name: 'Price', type: _type.DECIMAL, value: _util.getFee(bills.fees, 'common.unitFee') },
|
|
|
+ //{ name: 'Price', type: _type.DECIMAL, value: _util.getFee(bills.fees, 'common.unitFee') },
|
|
|
// 费率
|
|
|
- { name: 'Rate', type: _type.DECIMAL, value: !commonUtil.isEmptyVal(bills.feeRate) ? bills.feeRate : '100' },
|
|
|
+ //{ name: 'Rate', type: _type.DECIMAL, value: !commonUtil.isEmptyVal(bills.feeRate) ? bills.feeRate : '100' },
|
|
|
// 金额
|
|
|
{ name: 'Total', type: _type.DECIMAL, value: _util.getFee(bills.fees, 'common.totalFee') },
|
|
|
// 汇总类型
|
|
@@ -1778,6 +1802,12 @@ const XMLStandard = (function () {
|
|
|
// 备注
|
|
|
{ name: 'Remark', value: bills.remark }
|
|
|
];
|
|
|
+ const showPrice = !!(node.children && node.children.length && node.children[0].sourceType === commonConstants.SourceType.RATION);
|
|
|
+ if (showPrice) {
|
|
|
+ attrs.push({ name: 'Price', type: _type.DECIMAL, value: _util.getFee(bills.fees, 'common.unitFee') });
|
|
|
+ } else {
|
|
|
+ attrs.push({ name: 'Rate', type: _type.DECIMAL, value: !commonUtil.isEmptyVal(bills.feeRate) ? bills.feeRate : '100' });
|
|
|
+ }
|
|
|
_base.Element.call(this, 'SpecialtyProvisionalPriceItem', attrs, '专业工程暂估价明细');
|
|
|
}
|
|
|
// 计日工标题
|
|
@@ -1884,9 +1914,9 @@ const XMLStandard = (function () {
|
|
|
// 计算基数
|
|
|
{ name: 'QtyFormula', value: getQtyFormula(node) },
|
|
|
// 单价
|
|
|
- { name: 'Price', value: _util.getFee(bills.fees, 'common.unitFee') },
|
|
|
+ //{ name: 'Price', type: _type.DECIMAL, value: _util.getFee(bills.fees, 'common.unitFee') },
|
|
|
// 费率
|
|
|
- { name: 'Rate', type: _type.DECIMAL, value: !commonUtil.isEmptyVal(bills.feeRate) ? bills.feeRate : '100' },
|
|
|
+ //{ name: 'Rate', type: _type.DECIMAL, value: !commonUtil.isEmptyVal(bills.feeRate) ? bills.feeRate : '100' },
|
|
|
// 金额
|
|
|
{ name: 'Total', type: _type.DECIMAL, value: _util.getFee(bills.fees, 'common.totalFee') },
|
|
|
// 依据
|
|
@@ -1896,6 +1926,12 @@ const XMLStandard = (function () {
|
|
|
// 备注
|
|
|
{ name: 'Remark', value: bills.remark }
|
|
|
];
|
|
|
+ const showPrice = !!(node.children && node.children.length && node.children[0].sourceType === commonConstants.SourceType.RATION);
|
|
|
+ if (showPrice) {
|
|
|
+ attrs.push({ name: 'Price', type: _type.DECIMAL, value: _util.getFee(bills.fees, 'common.unitFee') });
|
|
|
+ } else {
|
|
|
+ attrs.push({ name: 'Rate', type: _type.DECIMAL, value: !commonUtil.isEmptyVal(bills.feeRate) ? bills.feeRate : '100' });
|
|
|
+ }
|
|
|
_base.Element.call(this, eleName, attrs, '索赔费用明细');
|
|
|
}
|
|
|
// 规费
|
|
@@ -1966,8 +2002,8 @@ const XMLStandard = (function () {
|
|
|
{ name: 'Specification', value: glj.specs },
|
|
|
// 单位
|
|
|
{ name: 'Unit', dName: '单位', required: true, value: glj.unit },
|
|
|
- // 数量(总消耗量)
|
|
|
- { name: 'Quantity', type: _type.DECIMAL, value: glj.quantity },
|
|
|
+ // 数量(总消耗量) 用toFixed来补零没问题,因为补的位数是大于计算取舍位数,不会有toFixed的精度问题(2.35.toFixed(2) = 2.3)
|
|
|
+ { name: 'Quantity', type: _type.DECIMAL, value: (+glj.quantity).toFixed(Decimal.GLJ) },
|
|
|
// 风险系数 从承包人主要材料设备-造价信息差额调整法读取,取不到则输出"0"
|
|
|
{ name: 'ProviderRate', type: _type.DECIMAL, value: glj.riskCoe },
|
|
|
// 基准单价 从承包人主要材料设备-造价信息差额调整法读取,取不到则输出"0"
|
|
@@ -2132,10 +2168,14 @@ const XMLStandard = (function () {
|
|
|
// 建设项目
|
|
|
const constructionProject = new ConstructionProject(projectData, summaryInfo);
|
|
|
// 系统信息
|
|
|
+ // 软件相关信息进行base64编码(gbk to base64)
|
|
|
+ const hardwareID = _util.generateHardwareId();
|
|
|
+ const encodedData = await encodingUtil.getEncodedData([projectData.softInfo, hardwareID], 'gbk', true);
|
|
|
+ const ID1 = encodedData[projectData.softInfo];
|
|
|
+ const ID2 = encodedData[hardwareID];
|
|
|
const systemInfo = new SystemInfo({
|
|
|
- // 软件相关信息进行base64编码
|
|
|
- ID1: Base64.encode(projectData.softInfo),
|
|
|
- ID2: _util.generateHardwareId(),
|
|
|
+ ID1,
|
|
|
+ ID2,
|
|
|
makeDate: moment(Date.now()).format('YYYY-MM-DDTHH:mm:ss'),
|
|
|
});
|
|
|
// 工程信息
|
|
@@ -2376,7 +2416,7 @@ const XMLStandard = (function () {
|
|
|
.map(node => new UnitWorksSummaryItem(node));
|
|
|
otherGroup.children.push(...otherChildren);
|
|
|
// 除固定类别为“分部分项工程”、“措施项目”、“其他项目”以外的大项费用,通常无子项,所以显示到Item中。(即使造价书有子项,也显示到Item中,不再列出其子项数据)
|
|
|
- const flags = [fixedFlag.SUB_ENGINERRING, fixedFlag.MEASURE, fixedFlag.OTEHER];
|
|
|
+ const flags = [fixedFlag.SUB_ENGINERRING, fixedFlag.MEASURE, fixedFlag.OTHER];
|
|
|
const otherRoots = tenderDetail.mainTree.roots
|
|
|
.filter(node => !flags.includes(node.getFlag()))
|
|
|
.map(node => new UnitWorksSummaryItem(node));
|
|
@@ -2475,7 +2515,7 @@ const XMLStandard = (function () {
|
|
|
function loadRation(node, kind) {
|
|
|
// 定额
|
|
|
const libCode = getLibCode(node.data, tenderDetail.projectInfo.engineeringInfo.ration_lib);
|
|
|
- const norm = new Norm(node.data, libCode, kind);
|
|
|
+ const norm = new Norm(node, libCode, kind);
|
|
|
// 工程量计算表
|
|
|
const expressElement = loadQuantityExpressions(tenderDetail.quantity_detail.datas, false, node.data.ID);
|
|
|
if (expressElement.length) {
|
|
@@ -2858,9 +2898,32 @@ const XMLStandard = (function () {
|
|
|
for (const file of files) {
|
|
|
zip.file(file.fileName, file.blob, { binary: true });
|
|
|
}
|
|
|
- const zipFile = await zip.generateAsync({ type: 'blob' });
|
|
|
+ // 导出的文件名需要用gbk编码,否则广联达导入不了
|
|
|
+ // encodeFileName不支持异步,先调用一次generateAsync,获取string与Unit8Array的数据源映射
|
|
|
+ // 不用TextEncoder的原因:https://developer.mozilla.org/zh-CN/docs/Web/API/TextEncoder/TextEncoder
|
|
|
+ // - 在Firefox 48和Chrome 53之前,编码类型标签被接受为TextEncoder对象的参数
|
|
|
+ // - 现在这两个浏览器已经删除了除utf-8之外的任何编码器类型的支持,以符合规范。 传入TextEncoder构造函数的任何类型标签现在都将被忽略,并且将创建一个utf-8 TextEncoder。
|
|
|
+ const source = new Set();
|
|
|
+ await zip.generateAsync({
|
|
|
+ type: 'uint8array',
|
|
|
+ encodeFileName: (string) => {
|
|
|
+ source.add(string);
|
|
|
+ return string;
|
|
|
+ }
|
|
|
+ });
|
|
|
+ const encodedData = await encodingUtil.getEncodedData([...source], 'gbk');
|
|
|
+ const zipFile = await zip.generateAsync({
|
|
|
+ type: 'uint8array',
|
|
|
+ encodeFileName: (string) => {
|
|
|
+ const abSource = encodedData[string].data;
|
|
|
+ const ab = Uint8Array.from(abSource);
|
|
|
+ return ab;
|
|
|
+ }
|
|
|
+ });
|
|
|
+ // TypedBuffer to ArrayBuffer to blob
|
|
|
+ const saveAsBlob = new Blob([zipFile.buffer]);
|
|
|
const exportKindName = _config.EXPORT_KIND_NAME[exportKind];
|
|
|
- saveAs(zipFile, `广东标准交换数据(${exportKindName}).COS`);
|
|
|
+ saveAs(saveAsBlob, `广东标准交换数据(${exportKindName}).COS`);
|
|
|
}
|
|
|
}
|
|
|
|