|
@@ -656,17 +656,33 @@
|
|
|
let res = JSON.stringify(exportJson)
|
|
|
console.log(res);
|
|
|
util.ajaxJson("正在导入中", "http://10.149.85.91:7777/sheet/excel/importFile", { exceldata: res, id: excelId }, function (res) {
|
|
|
-
|
|
|
console.log(res);
|
|
|
+ if (res.code === '1') {
|
|
|
+ // 销毁原来的excel
|
|
|
+ window.luckysheet.destroy();
|
|
|
+ // // 重新加载
|
|
|
+ var a = exportJson.sheets[0];
|
|
|
+ a.name = '';
|
|
|
+ if (res.code === '1') {
|
|
|
+
|
|
|
+ }
|
|
|
+ initExcel([a], name.replace('.xlsx', ''), excelId);
|
|
|
+ // // 绑定按钮事件
|
|
|
+ initHandel()
|
|
|
+ }
|
|
|
+
|
|
|
});
|
|
|
- // 销毁原来的excel
|
|
|
- window.luckysheet.destroy();
|
|
|
- // // 重新加载
|
|
|
- var a = exportJson.sheets[0];
|
|
|
- a.name = '';
|
|
|
- initExcel([a], name.replace('.xlsx', ''), excelId);
|
|
|
- // // 绑定按钮事件
|
|
|
- initHandel()
|
|
|
+ // // 销毁原来的excel
|
|
|
+ // window.luckysheet.destroy();
|
|
|
+ // // // 重新加载
|
|
|
+ // var a = exportJson.sheets[0];
|
|
|
+ // a.name = '';
|
|
|
+ // if (res.code === '1') {
|
|
|
+
|
|
|
+ // }
|
|
|
+ // initExcel([a], name.replace('.xlsx', ''), excelId);
|
|
|
+ // // // 绑定按钮事件
|
|
|
+ // initHandel()
|
|
|
}
|
|
|
);
|
|
|
});
|