|
@@ -102,6 +102,7 @@
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
+import * as baseUrls from "@/utils/request.js";
|
|
|
import informationAdd from "./informationAdd.vue";
|
|
|
export default {
|
|
|
components: { informationAdd },
|
|
@@ -268,7 +269,41 @@ export default {
|
|
|
},
|
|
|
methods: {
|
|
|
downErrorData() {
|
|
|
- console.log(this.errorobj);
|
|
|
+ if (!this.errorobj.length) {
|
|
|
+ this.$message.warning("无失败录入数据");
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ const LIST = this.errorobj.map((item) => {
|
|
|
+ let subjectName = "";
|
|
|
+ for (let i = 0; i < this.sujectList.length; i++) {
|
|
|
+ if (this.sujectList[i].id == item.subjectId) {
|
|
|
+ subjectName = this.sujectList[i].subjectName;
|
|
|
+ break;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ return {
|
|
|
+ cause: item.errmsg,
|
|
|
+ idCard: item.idCard,
|
|
|
+ realname: item.realname,
|
|
|
+ subjectName: subjectName,
|
|
|
+ telphone: item.telphone,
|
|
|
+ goodsName: item.goodsName,
|
|
|
+ goodsPrice: item.standPrice,
|
|
|
+ goodsRealPrice: item.goodsRealPrice,
|
|
|
+ goodsReceived: item.goodsReceived,
|
|
|
+ };
|
|
|
+ });
|
|
|
+ this.$api.inquireorderexportWrongInputOrder(LIST).then((res) => {
|
|
|
+ let url =
|
|
|
+ baseUrls.baseURL + "common/download?fileName=" + res.data.excel.msg;
|
|
|
+ let link = document.createElement("a");
|
|
|
+ let fileName = "导入模板" + ".xlsx";
|
|
|
+ document.body.appendChild(link);
|
|
|
+ link.href = url;
|
|
|
+ link.dowmload = fileName;
|
|
|
+ link.click();
|
|
|
+ link.remove();
|
|
|
+ });
|
|
|
},
|
|
|
backSearch() {
|
|
|
const jump = () => {
|