修复用户指引进入detail无法定位到单件衣服

This commit is contained in:
X1627315083
2024-01-11 09:33:11 +08:00
parent d1891feb45
commit a7d8e63f50

View File

@@ -419,7 +419,6 @@ export default defineComponent({
}) })
this.currentIndex = 0 this.currentIndex = 0
await this.setImgSize()
this.store.commit('setDesignItemDetail',rv) this.store.commit('setDesignItemDetail',rv)
this.removeRevocation() this.removeRevocation()
this.setRevocation(rv,'') this.setRevocation(rv,'')
@@ -437,6 +436,7 @@ export default defineComponent({
this.generateHighDesignImg = rv.highDesignUrl this.generateHighDesignImg = rv.highDesignUrl
this.designDetailShow = true this.designDetailShow = true
this.loadingShow = false this.loadingShow = false
await this.setImgSize()
if(this.driver__.driver){ if(this.driver__.driver){
nextTick().then(()=>{ nextTick().then(()=>{
// driverObj__.moveNext(); // driverObj__.moveNext();
@@ -455,6 +455,7 @@ export default defineComponent({
let front:any = [] let front:any = []
let back:any = [] let back:any = []
let body:any let body:any
if(this.body){ if(this.body){
designItemDetail.clothes.forEach((v:any,index:number)=>{ designItemDetail.clothes.forEach((v:any,index:number)=>{
let zIndex = 3 let zIndex = 3
@@ -473,7 +474,6 @@ export default defineComponent({
this.frontBack.body = item this.frontBack.body = item
} }
}); });
console.log(2);
let ratio:any = await this?.setPostition(body?.layersObject?.[0]?.imageUrl) let ratio:any = await this?.setPostition(body?.layersObject?.[0]?.imageUrl)
if(Number.isNaN(ratio) || ratio == 0){ if(Number.isNaN(ratio) || ratio == 0){
this.setImgSize() this.setImgSize()
@@ -511,6 +511,16 @@ export default defineComponent({
} }
let onresizeTime:any let onresizeTime:any
let this_ = this let this_ = this
this.frontBack = {
front:front,
back:back,
body:body,
}
await new Promise((resolve, reject) => {
nextTick().then(()=>{
resolve('')
})
});
window.onresize = () => { window.onresize = () => {
return (() => { return (() => {
clearTimeout(onresizeTime) clearTimeout(onresizeTime)
@@ -521,11 +531,7 @@ export default defineComponent({
})() })()
} }
this.frontBack = {
front:front,
back:back,
body:body,
}
}, },
setDesignCoverage(str:string){ setDesignCoverage(str:string){