diff --git a/src/tool/guide.js b/src/tool/guide.js index a83d0a15..67f9d01f 100644 --- a/src/tool/guide.js +++ b/src/tool/guide.js @@ -204,7 +204,6 @@ function removeDiv(element){ const openGuide = () =>{ let isBeginner = JSON.parse(getCookie('isBeginner')) - console.log(isBeginner); // console.log(isBeginner); let isBeginnerNum = JSON.parse(getCookie('isBeginnerNum')?getCookie('isBeginnerNum'):'0') let data diff --git a/src/tool/https.js b/src/tool/https.js index b2c24c96..bd6ea70a 100644 --- a/src/tool/https.js +++ b/src/tool/https.js @@ -114,6 +114,7 @@ export const Https = { reDesignCollection:`/api/design/reDesignCollection`,//重新设计 Conllection countDesignProcess:'/api/design/countDesignProcess', //统计design进度 designProcess:`/api/design/designProcess`, //统计design进度 + designGetModel:`/api/design/getModel`, //导出获取模特链接 getRgbByHsvBatch:`/api/element/getRgbByHsvBatch`, //通过hsv值数组批量获取潘通信息 designLike:`/api/design/like`, //Design Like diff --git a/src/views/HomeView.vue b/src/views/HomeView.vue index 4e5b4596..dd98aace 100644 --- a/src/views/HomeView.vue +++ b/src/views/HomeView.vue @@ -912,7 +912,7 @@ export default defineComponent({ // this.isShowMark = true; let img:any = [] await html2canvas(collectionReview, { useCORS: true, scale: 3 }).then( - (canvas) => { + async (canvas) => { let blob: any = dataURLtoBlob( canvas.toDataURL("image/png") ); @@ -963,15 +963,17 @@ export default defineComponent({ index++; }) let mannequinList:any = [] - // Https.axiosPost(Https.httpUrls.designLike, dataList) - // .then((rv: any) => { - // }) - // .catch((rv) => { - // }); + await Https.axiosPost(Https.httpUrls.designGetModel, dataList) + .then((rv: any) => { + mannequinList = rv + }) + .catch((rv) => { + }); + mannequinList.forEach((item:any) => { - let nameTail = item?.imgUrl?.split(".").pop().split("?").shift(); + let nameTail = item?.split(".").pop().split("?").shift(); let data = { - imgUrl: item.imgUrl, + imgUrl: item, name: 'mannequin' + index + @@ -981,10 +983,6 @@ export default defineComponent({ img.push(data); index++; }); - - - - // a.setAttribute('href', URL.createObjectURL(blob)); // a.setAttribute('download', `collection.png`); // a.click(); @@ -1012,6 +1010,7 @@ export default defineComponent({ // }); // } // ); + // return this.downImg(img); },