Compare commits
3 Commits
089a266c35
...
135adb3907
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
135adb3907 | ||
|
|
24e221902e | ||
|
|
9f338a772d |
@@ -120,7 +120,7 @@ const router = createRouter({
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: '/workshop/selectStyle',
|
path: '/workshop/selectStyle',
|
||||||
name: 'selectStyle',
|
name: 'SelectStyle',
|
||||||
component: () => import('../views/Workshop/selectStyle/index.vue'),
|
component: () => import('../views/Workshop/selectStyle/index.vue'),
|
||||||
meta: { verify: () => VerifyIDs(2) }
|
meta: { verify: () => VerifyIDs(2) }
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -95,28 +95,10 @@ export const useGenerateStore = defineStore({
|
|||||||
...data,
|
...data,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
clearStyle() {
|
|
||||||
this.style = {
|
|
||||||
id: '',
|
|
||||||
path: '',
|
|
||||||
isLike: false,
|
|
||||||
taskId:'',
|
|
||||||
status: ''
|
|
||||||
}
|
|
||||||
this.styleList = [
|
|
||||||
{id:'',taskId:'',status:'',path:''},
|
|
||||||
{id:'',taskId:'',status:'',path:''},
|
|
||||||
{id:'',taskId:'',status:'',path:''},
|
|
||||||
{id:'',taskId:'',status:'',path:''},
|
|
||||||
]
|
|
||||||
},
|
|
||||||
//模特相关
|
//模特相关
|
||||||
selectModel(data: any) {
|
selectModel(data: any) {
|
||||||
this.model.id = data.id
|
this.model.id = data.id
|
||||||
},
|
},
|
||||||
setIsGenerate(isGenerate: boolean) {
|
|
||||||
this.isGenerate = isGenerate
|
|
||||||
},
|
|
||||||
clearProductData() {
|
clearProductData() {
|
||||||
this.styleList = [
|
this.styleList = [
|
||||||
{id:'',taskId:'',status:'',path:''},
|
{id:'',taskId:'',status:'',path:''},
|
||||||
@@ -134,12 +116,14 @@ export const useGenerateStore = defineStore({
|
|||||||
this.model = {
|
this.model = {
|
||||||
id: ''
|
id: ''
|
||||||
}
|
}
|
||||||
|
this.clearTryOn()
|
||||||
|
},
|
||||||
|
clearTryOn() {
|
||||||
this.originalTryOn = {
|
this.originalTryOn = {
|
||||||
id: '',
|
id: '',
|
||||||
isLike: false,
|
isLike: false,
|
||||||
tryOnUrl: ''
|
tryOnUrl: ''
|
||||||
}
|
}
|
||||||
this.isGenerate = false
|
|
||||||
},
|
},
|
||||||
/** 更新顾客照片信息 */
|
/** 更新顾客照片信息 */
|
||||||
updatePhotoInfo(data: any) {
|
updatePhotoInfo(data: any) {
|
||||||
|
|||||||
@@ -115,6 +115,7 @@
|
|||||||
}
|
}
|
||||||
// 选择另一个穿搭
|
// 选择另一个穿搭
|
||||||
const onChooseOutfit = () => {
|
const onChooseOutfit = () => {
|
||||||
|
generateStore.clearTryOn()
|
||||||
router.push({ name: 'SelectStyle' })
|
router.push({ name: 'SelectStyle' })
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -166,7 +166,7 @@ const { isLoading } = toRefs(data);
|
|||||||
</template>
|
</template>
|
||||||
</gradientButton>
|
</gradientButton>
|
||||||
</div>
|
</div>
|
||||||
<div class="btnItem style2" @click.stop="onContinue">Continue</div>
|
<div class="btnItem style2" @click.stop="onContinue">{{ isHistoryFlow?'Finish':'Continue' }}</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -75,7 +75,7 @@ const toProduct = ()=>{
|
|||||||
const requestOutfit = async ({num})=>{
|
const requestOutfit = async ({num})=>{
|
||||||
let rv:any = await new Promise<void>((resolve, reject) => {
|
let rv:any = await new Promise<void>((resolve, reject) => {
|
||||||
if(isHistoryFlow.value){
|
if(isHistoryFlow.value){
|
||||||
retrieveAndRegenerate({tryOnEffectsId:hGenerateStore.originalTryOn.id}).then((rv:any)=>{
|
retrieveAndRegenerate({tryOnEffectsId:hGenerateStore.originalTryOn.id,checkInId:generateStore.visitRecordId}).then((rv:any)=>{
|
||||||
resolve(rv)
|
resolve(rv)
|
||||||
})
|
})
|
||||||
}else{
|
}else{
|
||||||
@@ -93,7 +93,7 @@ const requestOutfit = async ({num})=>{
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
isLoading.value = true
|
isLoading.value = true
|
||||||
generateStore.clearStyle()
|
generateStore.clearProductData()
|
||||||
data.select.taskId = rv[0]
|
data.select.taskId = rv[0]
|
||||||
rv.forEach((item,index)=>data.styleList[index].taskId = item)
|
rv.forEach((item,index)=>data.styleList[index].taskId = item)
|
||||||
getRequestOutfitList(rv)
|
getRequestOutfitList(rv)
|
||||||
@@ -204,7 +204,7 @@ const { styleListVue } = toRefs(dataDom);
|
|||||||
</template>
|
</template>
|
||||||
</gradientButton>
|
</gradientButton>
|
||||||
</div>
|
</div>
|
||||||
<div class="btnItem style2" @click.stop="toProduct">Continue</div>
|
<div class="btnItem style2" @click.stop="toProduct">{{ isHistoryFlow?'Finish':'Continue' }}</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<!-- <div class="footer placeholder"></div> -->
|
<!-- <div class="footer placeholder"></div> -->
|
||||||
|
|||||||
Reference in New Issue
Block a user