Merge branch 'dev_vite' of http://18.167.251.121:10003/aidlab/aida_front into dev_vite

This commit is contained in:
李志鹏
2026-01-02 11:26:09 +08:00
64 changed files with 6180 additions and 3862 deletions

View File

@@ -17,7 +17,8 @@
<div class="generalModel_btn">
<div class="generalModel_closeIcon" @click.stop="cancelDsign()">
<svg
width="100%" height="100%"
width="100%"
height="100%"
viewBox="0 0 46 46"
fill="none"
xmlns="http://www.w3.org/2000/svg"
@@ -49,7 +50,10 @@
</div>
<div class="allUserPoeration_center admin_page">
<div class="admin_state_item">
<span>{{ $t('admin.UserName') }}: <span>*</span></span>
<span>
{{ $t('admin.UserName') }}:
<span>*</span>
</span>
<input
v-model="userName"
:placeholder="$t('admin.enterUserName')"
@@ -58,7 +62,10 @@
/>
</div>
<div class="admin_state_item">
<span>{{ $t('admin.UserEmail') }}: <span>*</span></span>
<span>
{{ $t('admin.UserEmail') }}:
<span>*</span>
</span>
<input
v-model="userEmail"
:placeholder="$t('admin.enterEmail')"
@@ -67,7 +74,10 @@
/>
</div>
<div class="admin_state_item">
<span>{{ $t('admin.Password') }}: <span>*</span></span>
<span>
{{ $t('admin.Password') }}:
<span>*</span>
</span>
<input
@focus="focus"
@blur="blur"
@@ -86,6 +96,19 @@
style="width: 250px"
/>
</div>
<div class="admin_state_item" v-if="title?.value == 'Edit'">
<span>
{{ $t('admin.SubscribePlan') }}:
<span>*</span>
</span>
<a-select
v-model:value="subscriptionPlanId"
style="width: 250px"
:options="activePlanOptions"
:field-names="{ label: 'name', value: 'id' }"
:placeholder="$t('admin.SelectPlan')"
></a-select>
</div>
</div>
<div class="allUserPoeration_btn admin_page">
<div class="admin_search_item" @click="cancelDsign">{{ $t('admin.Close') }}</div>
@@ -96,7 +119,7 @@
<a-spin size="large" />
</div>
</template>
<script>
<script lang="ts">
import {
defineComponent,
ref,
@@ -105,90 +128,114 @@ import {
onMounted,
nextTick,
toRefs,
} from "vue";
import { Https } from "@/tool/https";
import { Modal, message } from "ant-design-vue";
import { ExclamationCircleOutlined } from "@ant-design/icons-vue";
import { formatTime, isEmail } from "@/tool/util";
import md5 from "md5";
computed
} from 'vue'
import { Https } from '@/tool/https'
import { Modal, message } from 'ant-design-vue'
import { ExclamationCircleOutlined } from '@ant-design/icons-vue'
import { formatTime, isEmail } from '@/tool/util'
import md5 from 'md5'
import { useI18n } from 'vue-i18n'
export default defineComponent({
components: {},
emits: ["searchHistoryList"],
props: {
planOptions: {
type: Array,
default: () => []
}
},
emits: ['searchHistoryList'],
setup(props, { emit }) {
const {t} = useI18n()
const { t } = useI18n()
const { planOptions } = toRefs(props)
// 筛选出状态为 ACTIVE 的订阅计划
const activePlanOptions = computed(() => {
if (!planOptions.value || !Array.isArray(planOptions.value)) {
return []
}
return planOptions.value.filter((plan: any) => plan.status === 'ACTIVE')
})
let operations = reactive({
operationsModal: false,
operationsEdit: false,
loadingShow: false,
title: null,
});
title: null
})
let operationsData = reactive({
accountId: -1,
userName: "",
userEmail: "",
password: "",
oldPassword: "",
credits: "",
});
userName: '',
userEmail: '',
password: '',
oldPassword: '',
credits: '',
subscriptionPlanId: '',
oldSubscriptionPlanId: ''
})
let state = ref([
{
label: "visitor",
value: "0",
label: 'visitor',
value: '0'
},
{
label: "yearly",
value: "1",
label: 'yearly',
value: '1'
},
{
label: "monthly",
value: "2",
label: 'monthly',
value: '2'
},
{
label: "trial",
value: "3",
},
]);
label: 'trial',
value: '3'
}
])
let init = (funStr, data) => {
operations.operationsModal = true;
operations.operationsEdit = true;
operations.title = funStr;
if (funStr.value == "Add") operations.operationsEdit = false;
if (funStr.value == "Edit") {
operationsData.accountId = data.id;
operationsData.userName = data.userName;
operationsData.userEmail = data.userEmail;
operationsData.password = data.userPassword?data.userPassword:null;
operationsData.oldPassword = data.userPassword;
operations.operationsModal = true
operations.operationsEdit = true
operations.title = funStr
if (funStr.value == 'Add') operations.operationsEdit = false
if (funStr.value == 'Edit') {
operationsData.accountId = data.id
operationsData.userName = data.userName
operationsData.userEmail = data.userEmail
operationsData.password = data.userPassword ? data.userPassword : null
operationsData.oldPassword = data.userPassword
// operationsData.validStartTime='2024-08-05T00:00:06'
// operationsData.validEndTime='2024-08-05T00:00:06'
operationsData.credits = data.creditsUsageLimit;
operationsData.credits = data.creditsUsageLimit
operationsData.subscriptionPlanId = data.subscriptionPlanId || ''
operationsData.oldSubscriptionPlanId = data.subscriptionPlanId || ''
// operationsData.accountId = data.accountId
// operationsData.userName = data.userName
// operationsData.userEmail = data.userEmail
// operationsData.validStartTime = formatTime(data.validStartTime)
// operationsData.validEndTime = formatTime(data.validEndTime)
}
};
let focus = (event) => {
if (funStr.value == 'Add') {
operationsData.subscriptionPlanId = ''
operationsData.oldSubscriptionPlanId = ''
}
}
let focus = event => {
if (operationsData.password == operationsData.oldPassword) {
operationsData.password = "";
operationsData.password = ''
}
};
let blur = (event) => {
console.log(operationsData.password == "" && operationsData.oldPassword);
if (operationsData.password == "" && operationsData.oldPassword) {
operationsData.password = operationsData.oldPassword;
}
let blur = event => {
console.log(operationsData.password == '' && operationsData.oldPassword)
if (operationsData.password == '' && operationsData.oldPassword) {
operationsData.password = operationsData.oldPassword
}
};
}
let setAddData = () => {
return {
creditsUsageLimit: operationsData.credits,
userEmail: operationsData.userEmail,
userPassword: operationsData.password?md5(operationsData.password + "abc"):'',
userPassword: operationsData.password ? md5(operationsData.password + 'abc') : '',
userName: operationsData.userName,
};
};
subscriptionPlanId: operationsData.subscriptionPlanId
}
}
let setEditData = () => {
return {
id: operationsData.accountId,
@@ -198,57 +245,63 @@ export default defineComponent({
userPassword:
operationsData.password == operationsData.oldPassword
? null
: md5(operationsData.password + "abc"),
};
};
let cancelDsign = () => {
operationsData.accountId = -1;
operationsData.userName = "";
operationsData.userEmail = "";
operationsData.password = "";
operationsData.credits = "";
operations.operationsModal = false;
};
let setOk = () => {
let data;
if (operations.title?.value == "Add") {
data = setAddData();
if (!isEmail(data.userEmail)) {
message.info(t('admin.jsContent1'));
return;
}
if (
!data.userName ||
!data.userEmail ||
!data.userPassword
)
return message.warning(t('admin.jsContent2'));
Https.axiosPost(Https.httpUrls.addOrUpdateSubAccount, data).then(
(rv) => {
if (rv) {
cancelDsign();
emit("searchHistoryList");
}
}
);
} else {
data = setEditData();
if (!isEmail(data.userEmail)) {
message.info("The email format is incorrect");
return;
}
if (!data.userName || !data.userEmail)
return message.warning("Please check the input box marked with *");
Https.axiosPost(Https.httpUrls.addOrUpdateSubAccount, data).then(
(rv) => {
if (rv) {
cancelDsign();
emit("searchHistoryList");
}
}
);
: md5(operationsData.password + 'abc'),
subscriptionPlanId: operationsData.subscriptionPlanId
}
};
}
let cancelDsign = () => {
operationsData.accountId = -1
operationsData.userName = ''
operationsData.userEmail = ''
operationsData.password = ''
operationsData.credits = ''
operationsData.subscriptionPlanId = ''
operationsData.oldSubscriptionPlanId = ''
operations.operationsModal = false
}
let setOk = () => {
let data
if (operations.title?.value == 'Add') {
data = setAddData()
if (!isEmail(data.userEmail)) {
message.info(t('admin.jsContent1'))
return
}
if (!data.userName || !data.userEmail || !data.userPassword)
return message.warning(t('admin.jsContent2'))
Https.axiosPost(Https.httpUrls.addOrUpdateSubAccount, data).then(rv => {
if (rv) {
cancelDsign()
emit('searchHistoryList')
}
})
} else {
data = setEditData()
if (!isEmail(data.userEmail)) {
message.info('The email format is incorrect')
return
}
if (!data.userName || !data.userEmail || !data.subscriptionPlanId)
return message.warning('Please check the input box marked with *')
const needSwitchPlan =
operationsData.subscriptionPlanId &&
operationsData.subscriptionPlanId !== operationsData.oldSubscriptionPlanId
Https.axiosPost(Https.httpUrls.addOrUpdateSubAccount, data).then(async rv => {
if (rv) {
if (needSwitchPlan) {
await Https.axiosGet(Https.httpUrls.switchSubAccountSubscribePlan, {
params: {
targetSubscriptionPlanId: operationsData.subscriptionPlanId,
subAccId: operationsData.accountId
}
})
}
cancelDsign()
emit('searchHistoryList')
}
})
}
}
return {
...toRefs(operations),
...toRefs(operationsData),
@@ -258,14 +311,16 @@ export default defineComponent({
focus,
blur,
setOk,
};
planOptions,
activePlanOptions
}
},
data() {
return {};
return {}
},
mounted() {},
methods: {},
});
methods: {}
})
</script>
<style lang="less" scoped>
:deep(.allUserPoeration_modal) {

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -585,7 +585,6 @@ export class ExportManager {
restoreOpacityInRedGreen && true
);
if (cloned) {
// 调整对象位置:将原画布坐标转换为以固定图层为原点的相对坐标
cloned.set({
left: canvasWidth / 2,
top: canvasHeight / 2,

View File

@@ -61,7 +61,7 @@
<model
ref="model"
:key="positionKey"
@addDetail="addDetail"
@canvasReload="canvasReload"
@detailEdit="detailEdit"
@addSketch="()=>isEditPattern.value = ''"
@@ -78,7 +78,16 @@
<div class="item detailRight" :class="{canvas:isEditPattern.value}">
<div class="submit">
</div>
<div class="contentRight" v-if="currentDetailType && !isEditPattern.value">
<div class="contentRight" v-if="currentDetailType === 'sketch' && !selectDetail?.newDetail?.[currentDetailType] && !selectDetail.sketchString && !isEditPattern.value">
<img
style="width: 100%; height: 100%;object-fit: contain;"
:src="
'/image/toolsGuide/' +
(locale == 'ENGLISH' ? 'detailEN' : 'detailCN') +
'.png'
" alt="">
</div>
<div class="contentRight" v-else-if="currentDetailType && !isEditPattern.value">
<detailRight ref="detailRight"></detailRight>
<div class="btn"
v-show="
@@ -102,7 +111,7 @@
</div> -->
</div>
</div>
<addDetails ref="addDetails" @setSloganData="setSloganData"></addDetails>
</a-modal>
<div class="mark_loading" v-show="loadingShow">
<a-spin size="large" />
@@ -128,17 +137,18 @@ import { useI18n } from 'vue-i18n'
import addDetails from '@/component/Detail/addDetails.vue'
export default defineComponent({
components:{
detailLeft,model,detailRight,canvasBox
detailLeft,model,detailRight,canvasBox,addDetails
},
emits:['destroy'],
setup(props,{emit}) {
const store = useStore();
const {locale} = useI18n()
const detailDom = reactive({
model:null,
canvasBox,
detailRight,
detailLeft:null as any,
addDetails:null as any,
})
const userDetail = computed(()=>{
return store.state.UserHabit.userDetail
@@ -506,6 +516,17 @@ export default defineComponent({
sessionStorage.setItem('revocation', JSON.stringify(revocation));
sessionStorage.setItem('oppositeRevocation',JSON.stringify([]));
}
const addDetail = () =>{
let addDetails:any = detailDom.addDetails
addDetails.init(detailData.selectDetail,'')
}
const setSloganData = (data:any)=>{
detailData.selectDetail.sketchString = data
if(detailData.currentDetailType == 'sketch' && detailData.selectDetail?.newDetail?.sketch){
detailData.selectDetail.newDetail.sketch = null
}
}
onMounted(()=>{
window.addEventListener('resize', handleResize);
})
@@ -518,6 +539,7 @@ export default defineComponent({
})
return{
locale,
...toRefs(detailDom),
...toRefs(detailData),
closeModal,
@@ -531,6 +553,8 @@ export default defineComponent({
canvasReload,
modelOnLoad,
sketchSysToLibrary,
addDetail,
setSloganData,
}
},

View File

@@ -238,7 +238,7 @@ export default defineComponent({
let size = {
...detailData.canvasConfig,
}
store.commit('DesignDetail/updataDetailItem',{maskUrl:value})
segmentImage(value,full,size).then(async (rv)=>{
let front = detailData.frontBack.front[detailData.imgDomIndex]
let back = detailData.frontBack.back[detailData.imgDomIndex]
@@ -251,7 +251,7 @@ export default defineComponent({
let base64 = await resizeImageWithNativeCanvas(front.oldMaskUrl,value)
front.maskUrl = base64
back.imageUrl = rv.targetBackUrl
store.commit('DesignDetail/updataDetailItem',{maskUrl:value})
// store.commit('DesignDetail/updataDetailItem',{maskUrl:value})
})
}

View File

@@ -141,6 +141,7 @@ export default defineComponent({
JSON.stringify(colorData.selectDetail.color.gradient) == JSON.stringify(color?.gradient)
&& colorData.selectDetail.color.rgba?.r
){
console.log('---',index)
isNoSelect = true
colorData.selectColor = item
colorData.colorList.index = index
@@ -160,8 +161,8 @@ export default defineComponent({
if(color?.gradient){
item.gradient = color?.gradient
}
colorData.colorList.index = index
colorData.selectColor = item
// colorData.colorList.index = index
// colorData.selectColor = item
}
colorData.colorList.list[newVal].push(item)
}

View File

@@ -6,7 +6,6 @@
<element v-show="currentDetailType == 'element'"></element>
<accessory v-show="currentDetailType == 'accessory'"></accessory>
<models v-show="currentDetailType == 'models'"></models>
<addDetails ref="addDetails" @setSloganData="setSloganData"></addDetails>
</div>
</template>
<script lang="ts">
@@ -22,12 +21,12 @@ import color from './colorBox/index.vue'
import element from './element.vue'
import accessory from './accessory.vue'
import models from './models.vue'
import addDetails from '@/component/Detail/addDetails.vue'
export default defineComponent({
components:{
sketch,print,color,addDetails,element,models,accessory
sketch,print,color,element,models,accessory
},
emit:['addDetail'],
setup(props,{emit}) {
const store = useStore();
const detailData = reactive({
@@ -45,14 +44,7 @@ export default defineComponent({
sketch:null as any,
})
const addDetail = () =>{
let addDetails:any = getDetailListDom.addDetails
addDetails.init(detailData.selectDetail,'')
}
const setSloganData = (data:any)=>{
detailData.selectDetail.sketchString = data
if(detailData.currentDetailType == 'sketch' && detailData.selectDetail?.newDetail?.sketch){
detailData.selectDetail.newDetail.sketch = null
}
emit('addDetail')
}
const sketchSysToLibrary = ()=>{//系统sketch添加到library更新library
getDetailListDom.sketch.sketchSysToLibrary()
@@ -63,7 +55,6 @@ export default defineComponent({
...toRefs(getDetailListData),
...toRefs(getDetailListDom),
addDetail,
setSloganData,
sketchSysToLibrary,
}
},

View File

@@ -350,6 +350,7 @@ export default defineComponent({
margin-top: 1rem;
justify-content: space-between;
align-content: flex-start;
padding-bottom: 2rem;
// &::-webkit-scrollbar{display: none;}
> .content_img_item{
width: calc((50% - 1rem));
@@ -368,9 +369,12 @@ export default defineComponent({
> .material_content_list_loding{
width: 100%;
aspect-ratio: 1/1;
height: 4rem;
overflow: hidden;
> img{
width: 100%;
height: 100%;
object-fit: contain;
}
}
}

View File

@@ -5,7 +5,7 @@
<!-- <img :src="selectDetail?.sketchString?selectDetail?.sketchString:selectDetail.path" alt=""> -->
<img :src="selectDetail.path" alt="">
<!-- <img :src="selectDetail.sketchString || selectDetail.path" alt=""> -->
<i :title="$t('DesignDetail.editSketchTitle')" class="fi fi-rs-pencil-paintbrush" @click.stop="openAddDetail"></i>
<!-- <i :title="$t('DesignDetail.editSketchTitle')" class="fi fi-rs-pencil-paintbrush" @click.stop="openAddDetail"></i> -->
</div>
<div class="select_sketch" v-else>
<div>

View File

@@ -14,6 +14,7 @@
<i class="icon iconfont icon-chehui" @click="revocation"></i>
<i class="icon iconfont icon-fanchehui" @click="oppositeRevocation"></i>
<!-- 编辑 -->
<i class="fi fi-rs-pencil-paintbrush" :title="$t('DesignDetail.editSketchTitle')" :class="{'pointerEventsNone':!selectDetail?.id}" @click="()=>$emit('addDetail')"></i>
<i class="fi fi-rr-edit" :title="$t('DesignDetail.editTitle')" :class="{active:isEditPattern.value == 'canvasEditor','pointerEventsNone':!selectDetail?.id}" @click="showDesignImgDetail('canvasEditor')"></i>
<i class="icon iconfont icon-clothes" :title="$t('Canvas.editFrontBack')" style="font-size: 3.2rem;" @click="showDesignImgDetail('redGreenExample')" :class="{active:isEditPattern.value == 'redGreenExample','pointerEventsNone':!selectDetail?.id}"></i>
@@ -50,7 +51,7 @@ export default defineComponent({
components:{
position,modelNav
},
emits:['detailEdit','canvasReload','addSketch','revocation','oppositeRevocation','modelOnLoad','sketchSysToLibrary'],
emits:['detailEdit','canvasReload','addSketch','revocation','oppositeRevocation','modelOnLoad','sketchSysToLibrary','addDetail'],
setup(props,{emit}) {
const {t} = useI18n()
const store = useStore();

View File

@@ -286,7 +286,8 @@
@click="generageAdd(item)"
:class="[
item.status != 'Success' ? 'hideEvents' : '',
item?.checked ? 'active' : ''
item?.checked ? 'active' : '',
(type_.type2 == 'Printboard' && item?.imgUrl)? 'maskBg' : ''
]"
>
<img v-if="item?.imgUrl" v-lazy="item.imgUrl" @click.stop="generageAdd(item)" />
@@ -1359,6 +1360,10 @@ export default defineComponent({
width: calc(25% - 2rem);
aspect-ratio: 1 / 1;
position: relative;
&.maskBg{
background-image: url("data:image/svg+xml,%3Csvg width='40' height='40' viewBox='0 0 40 40' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23666' fill-opacity='0.4'%3E%3Crect x='20' width='20' height='20'/%3E%3Crect y='20' width='20' height='20'/%3E%3C/g%3E%3C/svg%3E");
background-size: 2rem 2rem; /* 调整图案密度 */
}
&.active {
opacity: 0.5;
// border: 2px solid;
@@ -1379,6 +1384,7 @@ export default defineComponent({
display: flex;
align-items: center;
justify-content: center;
position: absolute;
}
img {
// width: calc(10rem*1.2);
@@ -1386,6 +1392,7 @@ export default defineComponent({
width: 100%;
height: 100%;
object-fit: contain;
}
&:hover .delete_like_file_block {
// display: block;

View File

@@ -486,7 +486,7 @@ export default defineComponent({
.my_material_header_left{
margin-right: auto;
.select_block{
border: calc(0.1rem* 1.2) solid #F1F1F1;
// border: calc(0.1rem* 1.2) solid #F1F1F1;
margin-right: calc(2.3rem*1.2);
height: auto;
.ant-select-selector{

View File

@@ -34,8 +34,8 @@
</div>
</div>
<div class="layout_centent" :class="{active:flex_direction}" id="layoutCentent">
<div v-for="item,index in layoutList" :key="item" :class="moodbClassName[index]" class="modal_imgItem" v-layout="item" @mousedown="setpitch(item,index)" @touchstart="setpitch(item,index)" ref="content" >
<img crossOrigin="anonymous" :src="item.imgUrl" :style="{'transform':`translate(-50%, -50%) scale(${item.zoom?item.zoom:1}) rotateZ(${item.angle?item.angle:0}deg)`}" draggable="false" :class="moodbClassName[index]" v-modelImg>
<div v-for="item,index in layoutList" :key="item" :class="moodbClassName[index]" class="modal_imgItem" v-layout="item" @mousedown="setpitch(item,index)" @touchstart="setpitch(item,index)" ref="content" :style="{'background-image':`url(${item.imgUrl})`,'transform':`scale(${item.zoom?item.zoom:1}) rotateZ(${item.angle?item.angle:0}deg)`}">
<!-- <img crossOrigin="anonymous" :src="item.imgUrl" :style="{'transform':`translate(-50%, -50%) scale(${item.zoom?item.zoom:1}) rotateZ(${item.angle?item.angle:0}deg)`}" draggable="false" :class="moodbClassName[index]" v-modelImg> -->
<ul v-show="item.setPitch" class="layout_btn" >
<li class="layout_btn_top" v-compile.stop="'top'"></li>
<li class="layout_btn_bottom" v-compile.stop="'bottom'"></li>
@@ -736,6 +736,7 @@ export default defineComponent({
setmoodb(item:any){
this.moodbClassName = item
this.$emit('setmoodbClass',this.moodbClassName)
this.styleObj.class = this.moodbClassName
if(this.content){
for (item of (this.content as any)) {
item.classList.remove('active')
@@ -772,7 +773,7 @@ export default defineComponent({
initDomStyle(){
nextTick(()=>{
this.content.forEach((item:any,index:any) => {
if(this.styleObj.domStyle[index]){
if(this.styleObj.domStyle[index]?.left){
item.classList.add('active')
this.initStyle(item,this.styleObj.domStyle[index])
}
@@ -794,7 +795,7 @@ export default defineComponent({
})
},
initStyle(dom:any,style:any){
if(!style)return
if(!style || !dom)return
for (const [property, value] of Object.entries(style)) {
dom.style.setProperty(property, value);
@@ -806,7 +807,7 @@ export default defineComponent({
this.styleObj.domStyle.push(this.setStyle(item.style))
this.domObj.dom.forEach((domName:any,index:any) => {
let style = this.domObj.domStyle[index]
let dom = item.querySelector(domName)
let dom = item.querySelector(domName) || item
this.styleObj[style].push(this.setStyle(dom.style))
})
});
@@ -840,7 +841,6 @@ export default defineComponent({
let config:any = {headers:{'Content-Type':'multipart/form-data','Accept':'*/*' }}
Https.axiosPost(Https.httpUrls.elementUpload,param,config)
.then((rv: any) => {
// console.log(rv);
rv.imgUrl = rv.url
this.layout = false
this.loadingShow = false
@@ -1062,27 +1062,12 @@ export default defineComponent({
// height: 100%;
// }
overflow: hidden;
background-repeat: no-repeat;
background-position: center;
background-size: cover;
&.active{
position: absolute;
}
img{
// object-fit: cover;
// width: 100%;
// height: 100%;
pointer-events: none;
float: left;
user-select:none;
-webkit-user-drag: none;
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%,-50%) scale(1);
}
::selection {
// background: rgba(0,0,0,0);
// background: yellow;
}
}
}
.wh1{

File diff suppressed because it is too large Load Diff

View File

@@ -41,7 +41,7 @@
<i v-else class="fi fi-br-check" @click="editChek('brandSlogan')"></i>
</div>
</div>
<div class="compute" style="flex:1;text-align: right;" v-show="fall?.list?.length > 0">
<div class="compute" style="margin-left: auto;text-align: right;" v-show="fall?.list?.length > 0">
<!-- <div @click="setProgress(50)">123123123</div> -->
<div class="gallery_btn" @click="compute" :class="{'loading':!(schedule.num == 1||(schedule.num == 0 && !schedule.state))}">
{{$t('brandDNA.Compute')}}
@@ -546,6 +546,7 @@ export default defineComponent({
}
.gallery_btn{
&.loading{
width: min-content;
pointer-events: none;
color: #5F5F5F;
}

View File

@@ -6,7 +6,7 @@
<!-- <div class="icon" @click="toGmailLogin"> -->
<div class="icon">
<img src="@/assets/images/loginPage/gmailIcon.svg" alt="">
<span>{{ $props.text }}</span>
<span>{{ displayText }}</span>
</div>
</div>
</template>
@@ -21,7 +21,7 @@
props: {
text: {
type: String,
default: 'Sign in with Google'
default: ''
}
},
setup(props, { emit }) {
@@ -108,6 +108,9 @@
const toGmailLogin = ()=>{
message.info(t('account.canNotUtilize'))
}
const displayText = computed(() => {
return props.text || t('Login.LoginWithGoogle')
})
onBeforeUnmount(()=>{
var existingScript = document.querySelector(`script[src="${data.scriptSrc}"]`);
if(existingScript){
@@ -120,6 +123,7 @@
})
return {
toGmailLogin,
displayText,
}
},
})

View File

@@ -9,14 +9,14 @@
<div>
<div class="login_form_content" :state="emailStap">
<div v-show="emailStap === 1">
<div class="login_form_title marign_top30">Enterprise</div>
<div class="login_form_title marign_top30">{{ t('LoginEnterprise.Enterprise') }}</div>
<div class="generalModel_state">
<div
class="generalModel_state_item"
style="width: 100%; margin: 0"
>
<a-select
placeholder="Select a school"
:placeholder="t('LoginEnterprise.SelectEnterprise')"
v-model:value="selectEnterprise"
:options="schoolList"
@change="schoolListChange"
@@ -36,21 +36,21 @@
</a-select>
</div>
</div>
<div class="login_form_title marign_top30">Email</div>
<div class="login_form_title marign_top30">{{ t('LoginEnterprise.Email') }}</div>
<input
class="login_form_input"
placeholder="Enter your email address"
:placeholder="t('LoginEnterprise.EnterEmail')"
v-model="email"
@keydown.enter="submitPerLogin()"
/>
<div class="login_form_title marign_top30">
<div>Password</div>
<div>{{ t('LoginEnterprise.Password') }}</div>
</div>
<div class="password_input_block">
<input
class="login_form_input"
:type="passwordType"
placeholder="Enter your password"
:placeholder="t('LoginEnterprise.EnterPassword')"
v-model="password"
@keydown.enter="submitPerLogin()"
/>
@@ -79,15 +79,15 @@
</div> -->
<div class="email_last_step_bottom">
<div class="email_last_step_des">
<div class="sent_email_content">Enter Code</div>
<div class="sent_email_content">{{ t('LoginEnterprise.EnterCode') }}</div>
<div class="tip_content">
<span v-show="time">{{ time }}s</span>
<span v-show="!time" @click="emailNextStepFun()"
>Resend</span
>{{ t('LoginEnterprise.Resend') }}</span
>
</div>
</div>
<div class="codeEmail">Weve sent an code to your email <span>{{ email }}</span></div>
<div class="codeEmail">{{ t('LoginEnterprise.SentCodeToEmail') }} <span>{{ email }}</span></div>
<div class="codeEmailInput">
<VerificationCodeInput
:ct="emailCode"
@@ -103,10 +103,10 @@
<label :class="{ active: emailStap == 2 }">
<input :state="emailStap" type="checkbox" v-model="checked" />
<span>
I agree to the
<a href="https://code-create.com.hk/aida-terms-and-conditions/" style="text-decoration: underline;color: #000;">Terms</a>,
<a href="https://aida.com.hk/privacy-policy.html" target="_blank" style="text-decoration: underline;color: #000;">Privacy Policy</a>,
and Fees.
{{ t('LoginEnterprise.AgreeTo') }}
<a href="https://code-create.com.hk/aida-terms-and-conditions/" style="text-decoration: underline;color: #000;">{{ t('LoginEnterprise.Terms') }}</a>,
<a href="https://aida.com.hk/privacy-policy.html" target="_blank" style="text-decoration: underline;color: #000;">{{ t('LoginEnterprise.PrivacyPolicy') }}</a>,
{{ t('LoginEnterprise.AndFees') }}
</span>
</label>
</div>
@@ -125,7 +125,7 @@
:state="emailStap"
@click="submitPerLogin()"
>
Sign in
{{ t('LoginEnterprise.SignIn') }}
</div>
<!-- <div class="login_text">
@@ -151,14 +151,14 @@
>
<!-- <i class="fi fi-br-arrow-left"></i> -->
<i class="fi fi-br-angle-left"></i>
<span class="forget_password_content_title">Retrieve password</span>
<span class="forget_password_content_title">{{ t('LoginEnterprise.RetrievePassword') }}</span>
</div>
<div v-show="frogetPasswordStep === 1">
<div class="forget_passored_form_content">
<div class="forget_passored_form_title">Email</div>
<div class="forget_passored_form_title">{{ t('LoginEnterprise.Email') }}</div>
<input
class="forget_passored_form_input"
placeholder="Enter your email"
:placeholder="t('LoginEnterprise.EnterEmail')"
v-model="forgetPasswordEmail"
@keydown.enter="forgetPasswordNextStepFun()"
/>
@@ -167,20 +167,20 @@
class="forget_submit_button marign_top40"
@click="forgetPasswordNextStepFun()"
>
Next step
{{ t('LoginEnterprise.NextStep') }}
</div>
</div>
<div v-show="frogetPasswordStep === 2">
<div class="forget_verif_code_des">Verification Code</div>
<div class="forget_verif_code_des">{{ t('LoginEnterprise.VerificationCode') }}</div>
<div class="email_last_step_des">
<div class="sent_email_content">
Sent to {{ forgetPasswordEmail }}
{{ t('LoginEnterprise.SentTo') }} {{ forgetPasswordEmail }}
</div>
<div class="tip_content">
<span v-show="time">{{ time }}s</span>
<span v-show="!time" @click="forgetPasswordNextStepFun()"
>Resend</span
>{{ t('LoginEnterprise.Resend') }}</span
>
</div>
</div>
@@ -192,7 +192,7 @@
<div v-show="frogetPasswordStep === 3">
<div class="forget_passored_form_content">
<div class="forget_passored_form_title">Password</div>
<div class="forget_passored_form_title">{{ t('LoginEnterprise.Password') }}</div>
<div v-show="passwordConditionShow" class="conditionShow">
<div class="item">
<div class="icon">
@@ -205,7 +205,7 @@
class="fi fi-br-check"
></i>
</div>
<div class="text">At least 8 characters long</div>
<div class="text">{{ t('LoginEnterprise.AtLeast8Chars') }}</div>
</div>
<div class="item">
<div class="icon">
@@ -218,7 +218,7 @@
class="fi fi-br-check"
></i>
</div>
<div class="text">Must contain special characters</div>
<div class="text">{{ t('LoginEnterprise.MustContainSpecial') }}</div>
</div>
<div class="item">
<div class="icon">
@@ -232,13 +232,13 @@
></i>
</div>
<div class="text">
Mix of uppercase, lowercase and numbers
{{ t('LoginEnterprise.MixUpperLowerNumbers') }}
</div>
</div>
</div>
<input
class="forget_passored_form_input"
placeholder="Enter a new password"
:placeholder="t('LoginEnterprise.EnterNewPassword')"
v-model="newPassword"
@focus="() => (passwordConditionShow = true)"
@blur="() => (passwordConditionShow = false)"
@@ -250,7 +250,7 @@
class="forget_submit_button marign_top40"
@click="submitResetPassword()"
>
Submit
{{ t('LoginEnterprise.Submit') }}
</div>
</div>
</div>
@@ -263,7 +263,7 @@
</template>
<script lang="ts">
import { defineComponent, ref, onMounted, reactive, toRefs } from "vue";
import { defineComponent, ref, onMounted, reactive, toRefs, inject } from "vue";
import { Https } from "@/tool/https";
import { isEmail } from "@/tool/util";
import { setCookie, WriteCookie } from "@/tool/cookie";
@@ -273,7 +273,6 @@ import googleLogin from "@/component/LoginPage/googleLogin.vue";
import weiXinLogin from "@/component/LoginPage/weiXinLogin.vue";
import phoneLogin from "@/component/LoginPage/phoneLogin.vue";
import { useStore } from "vuex";
import { useI18n } from "vue-i18n";
import { setLang } from "@/tool/guide";
import md5 from "md5";
export default defineComponent({
@@ -285,7 +284,8 @@ export default defineComponent({
},
setup() {
let timer: any = 0;
const { locale } = useI18n();
// 从父组件注入 i18n
const i18n = inject('i18n') as { t: any, locale: any };
const store = useStore();
let loadingShow = ref(false);
const data = reactive({
@@ -320,7 +320,8 @@ export default defineComponent({
...toRefs(data),
store,
timer,
locale,
locale: i18n?.locale,
t: i18n?.t,
loadingShow,
schoolListChange,
filterOption,
@@ -383,7 +384,7 @@ export default defineComponent({
//邮箱登录的下一步
emailNextStepFun() {
if (!isEmail(this.email)) {
message.info("The email format is incorrect");
message.info(this.t('LoginEnterprise.IncorrectEmailFormat'));
return;
}
let data = {
@@ -413,7 +414,7 @@ export default defineComponent({
//忘记密码的下一步
forgetPasswordNextStepFun() {
if (!isEmail(this.forgetPasswordEmail)) {
message.info("The email format is incorrect");
message.info(this.t('LoginEnterprise.IncorrectEmail'));
return;
}
let data = {
@@ -468,26 +469,26 @@ export default defineComponent({
return;
} else {
if (!this.password) {
message.info("Please enter your account number or password");
message.info(this.t('LoginEnterprise.PleaseEnterYourAccountNumberOrPassword'));
return;
}
//输入邮箱
if (!this.email) {
message.info("Please enter your email address");
message.info(this.t('LoginEnterprise.NeedEmail'));
return;
}
if (!this.selectEnterprise) {
message.info("Please select a school");
message.info(this.t('LoginEnterprise.SelectEnterprise'));
return;
}
//判断邮箱格式是否正确
if (!isEmail(this.email)) {
message.info("The email format is incorrect");
message.info(this.t('LoginEnterprise.IncorrectEmailFormat'));
return;
}
//判断是否同意隐私政策
if (!this.checked) {
message.info("Agree to all terms, privacy fees and policies");
message.info(this.t('Login.AgreePolicies'));
return;
}
let data = {
@@ -547,7 +548,7 @@ export default defineComponent({
});
},
isCheckAgreement() {
message.info("Agree to all terms, privacy fees and policies");
message.info(this.t('Login.AgreePolicies'));
},
//谷歌登录
@@ -584,7 +585,7 @@ export default defineComponent({
if (window.innerWidth < 768) {
message.info(
"If you need to design, please log in using an iPad or computer."
this.t('Login.Device')
);
this.turnToHomePage("/Square");
} else {
@@ -613,7 +614,7 @@ export default defineComponent({
//修改密码提交
submitResetPassword() {
if (this.isPassword(this.newPassword) < 3) {
message.info("You must satisfy ALL password conditions to register.");
message.info(this.t('Login.PasswordConditions'));
return;
}
let data = {

View File

@@ -14,21 +14,21 @@
v-model="username"
/> -->
<div v-show="emailStap === 1">
<div class="login_form_title marign_top30">Email</div>
<div class="login_form_title marign_top30">{{ t('LoginPersonal.Email') }}</div>
<input
class="login_form_input"
placeholder="Enter your email address"
:placeholder="t('LoginPersonal.EnterEmail')"
v-model="email"
@keydown.enter="submitPerLogin()"
/>
<div class="login_form_title marign_top30">
<div>Password</div>
<div>{{ t('LoginPersonal.Password') }}</div>
</div>
<div class="password_input_block">
<input
class="login_form_input"
:type="passwordType"
placeholder="Enter your password"
:placeholder="t('LoginPersonal.EnterPassword')"
v-model="password"
@keydown.enter="submitPerLogin()"
/>
@@ -57,15 +57,15 @@
</div> -->
<div class="email_last_step_bottom">
<div class="email_last_step_des">
<div class="sent_email_content">Enter Code</div>
<div class="sent_email_content">{{ t('LoginPersonal.EnterCode') }}</div>
<div class="tip_content">
<span v-show="time">{{ time }}s</span>
<span v-show="!time" @click="emailNextStepFun()"
>Resend</span
>{{ t('LoginPersonal.Resend') }}</span
>
</div>
</div>
<div class="codeEmail">Weve sent an code to your email <span>{{ email }}</span></div>
<div class="codeEmail">{{ t('LoginPersonal.SentCodeToEmail') }} <span>{{ email }}</span></div>
<div class="codeEmailInput">
<VerificationCodeInput
ref="verificationCodeInputDom"
@@ -80,17 +80,17 @@
<div class="login_text" v-show="emailStap !== 2">
<div class="forget_password_text" @click="changeIsLogin(2)">
Forgot your password
{{ t('LoginPersonal.ForgotPassword') }}
</div>
</div>
<div class="login_form_title marign_top40">
<label :class="{ active: emailStap == 2 }">
<input :state="emailStap" type="checkbox" v-model="checked" />
<span>
I agree to the
<a href="https://code-create.com.hk/aida-terms-and-conditions/" style="text-decoration: underline;color: #000;">Terms</a>,
<a href="https://aida.com.hk/privacy-policy.html" target="_blank" style="text-decoration: underline;color: #000;">Privacy Policy</a>,
and Fees.
{{ t('LoginPersonal.AgreeTo') }}
<a href="https://code-create.com.hk/aida-terms-and-conditions/" style="text-decoration: underline;color: #000;">{{ t('LoginPersonal.Terms') }}</a>,
<a href="https://aida.com.hk/privacy-policy.html" target="_blank" style="text-decoration: underline;color: #000;">{{ t('LoginPersonal.PrivacyPolicy') }}</a>,
{{ t('LoginPersonal.AndFees') }}
</span>
</label>
</div>
@@ -102,12 +102,12 @@
@click="submitPerLogin()"
@mousedown="loginBtnMousedown"
>
Sign in
{{ t('LoginPersonal.SignIn') }}
</div>
<div class="NewAccount" @click="newAccount()">Create New Account</div>
<div class="NewAccount" @click="newAccount()">{{ t('LoginPersonal.CreateNewAccount') }}</div>
<div class="segmentation">
<div class="wire"></div>
<div class="text">or</div>
<div class="text">{{ t('LoginPersonal.Or') }}</div>
<div class="wire"></div>
</div>
<div class="thirdPartyLogin marign_top30">
@@ -147,14 +147,14 @@
> -->
<!-- <i class="fi fi-br-arrow-left"></i> -->
<i class="fi fi-br-angle-left"></i>
<span class="forget_password_content_title">Retrieve password</span>
<span class="forget_password_content_title">{{ t('LoginPersonal.RetrievePassword') }}</span>
</div>
<div v-show="frogetPasswordStep === 1">
<div class="forget_passored_form_content">
<div class="forget_passored_form_title">Email</div>
<div class="forget_passored_form_title">{{ t('LoginPersonal.Email') }}</div>
<input
class="forget_passored_form_input"
placeholder="Enter your email"
:placeholder="t('LoginPersonal.EnterEmail')"
v-model="forgetPasswordEmail"
@keydown.enter="forgetPasswordNextStepFun()"
/>
@@ -163,20 +163,20 @@
class="forget_submit_button marign_top40"
@click="forgetPasswordNextStepFun()"
>
Next step
{{ t('LoginPersonal.NextStep') }}
</div>
</div>
<div v-show="frogetPasswordStep === 2">
<div class="forget_verif_code_des">Verification Code</div>
<div class="forget_verif_code_des">{{ t('LoginPersonal.VerificationCode') }}</div>
<div class="email_last_step_des">
<div class="sent_email_content">
Sent to {{ forgetPasswordEmail }}
{{ t('LoginPersonal.SentTo') }} {{ forgetPasswordEmail }}
</div>
<div class="tip_content">
<span v-show="time">{{ time }}s</span>
<span v-show="!time" @click="forgetPasswordNextStepFun()"
>Resend</span
>{{ t('LoginPersonal.Resend') }}</span
>
</div>
</div>
@@ -188,7 +188,7 @@
<div v-show="frogetPasswordStep === 3">
<div class="forget_passored_form_content">
<div class="forget_passored_form_title">Password</div>
<div class="forget_passored_form_title">{{ t('LoginPersonal.Password') }}</div>
<div v-show="passwordConditionShow" class="conditionShow">
<div class="item">
<div class="icon">
@@ -201,7 +201,7 @@
class="fi fi-br-check"
></i>
</div>
<div class="text">At least 8 characters long</div>
<div class="text">{{ t('LoginPersonal.AtLeast8Chars') }}</div>
</div>
<div class="item">
<div class="icon">
@@ -214,7 +214,7 @@
class="fi fi-br-check"
></i>
</div>
<div class="text">Must contain special characters</div>
<div class="text">{{ t('LoginPersonal.MustContainSpecial') }}</div>
</div>
<div class="item">
<div class="icon">
@@ -228,13 +228,13 @@
></i>
</div>
<div class="text">
Mix of uppercase, lowercase and numbers
{{ t('LoginPersonal.MixUpperLowerNumbers') }}
</div>
</div>
</div>
<input
class="forget_passored_form_input"
placeholder="Enter a new password"
:placeholder="t('LoginPersonal.EnterNewPassword')"
v-model="newPassword"
@focus="() => (passwordConditionShow = true)"
@blur="() => (passwordConditionShow = false)"
@@ -246,7 +246,7 @@
class="forget_submit_button marign_top40"
@click="submitResetPassword()"
>
Submit
{{ t('LoginPersonal.Submit') }}
</div>
</div>
</div>
@@ -290,7 +290,7 @@
</template>
<script lang="ts">
import { defineComponent, ref, onMounted } from "vue";
import { defineComponent, ref, onMounted, inject } from "vue";
import { Https } from "@/tool/https";
import { isEmail } from "@/tool/util";
import { setCookie, WriteCookie } from "@/tool/cookie";
@@ -300,11 +300,9 @@ import googleLogin from "@/component/LoginPage/googleLogin.vue";
import weiXinLogin from "@/component/LoginPage/weiXinLogin.vue";
import phoneLogin from "@/component/LoginPage/phoneLogin.vue";
import { useStore } from "vuex";
import { useI18n } from "vue-i18n";
import { useRouter } from "vue-router";
import { setLang } from "@/tool/guide";
import md5 from "md5";
import router from "@/router";
import { pass } from "three/tsl";
export default defineComponent({
components: {
VerificationCodeInput,
@@ -316,17 +314,18 @@ export default defineComponent({
let timer: any = 0;
let router = useRouter()
const { locale } = useI18n();
// 从父组件注入 i18n
const i18n = inject('i18n') as { t: any, locale: any };
const store = useStore();
let loadingShow = ref(false);
const newAccount = ()=>{
// router.spuh({path:'/register'})
router.push({path:'/register'})
}
return {
store,
timer,
locale,
locale: i18n?.locale,
t: i18n?.t,
loadingShow,
newAccount,
};
@@ -389,7 +388,7 @@ export default defineComponent({
//邮箱登录的下一步
emailNextStepFun() {
if (!isEmail(this.email)) {
message.info("The email format is incorrect");
message.info(this.$t('LoginPersonal.IncorrectEmailFormat'));
return;
}
let data = {
@@ -419,7 +418,7 @@ export default defineComponent({
//忘记密码的下一步
forgetPasswordNextStepFun() {
if (!isEmail(this.forgetPasswordEmail)) {
message.info("The email format is incorrect");
message.info(this.t('LoginPersonal.IncorrectEmail'));
return;
}
let data = {
@@ -473,7 +472,7 @@ export default defineComponent({
let verificationCodeInputDom:any = this.$refs.verificationCodeInputDom
let code = verificationCodeInputDom.getCtData.map(item => item).join('');
if(code.length !== this.emailCode.length){
message.info("Please enter the complete verification code.");
message.info(this.t('LoginPersonal.CompleteVerificationCode'));
}else{
this.submitEmailLogin(code)
}
@@ -482,22 +481,22 @@ export default defineComponent({
return;
} else {
if (!this.password) {
message.info("Please enter your account number or password");
message.info(this.t('LoginPersonal.PleaseEnterYourAccountNumberOrPassword'));
return;
}
//输入邮箱
if (!this.email) {
message.info("Please enter your email address");
message.info(this.t('LoginPersonal.NeedEmail'));
return;
}
//判断邮箱格式是否正确
if (!isEmail(this.email)) {
message.info("The email format is incorrect");
message.info(this.t('LoginPersonal.IncorrectEmailFormat'));
return;
}
//判断是否同意隐私政策
if (!this.checked) {
message.info("Agree to all terms, privacy fees and policies");
message.info(this.t('Login.AgreePolicies'));
return;
}
let data = {
@@ -554,18 +553,19 @@ export default defineComponent({
loginType: "EMAIL",
userId: this.userId,
};
this.$emit('update:isMask',true)
this.store.commit('set_loading', true)
Https.axiosPost(Https.httpUrls.accountLogin, data)
.then((rv: any) => {
this.setSuccessLogin(rv);
this.setSuccessLogin(rv);
this.store.commit('set_loading', false)
})
.catch((res) => {
this.$emit('update:isMask',false)
this.store.commit('set_loading', false)
});
},1000)
},
isCheckAgreement() {
message.info("Agree to all terms, privacy fees and policies");
message.info(this.t('Login.AgreePolicies'));
},
//谷歌登录
googelLogin(value: any) {
@@ -601,7 +601,7 @@ export default defineComponent({
if (window.innerWidth < 768) {
message.info(
"If you need to design, please log in using an iPad or computer."
this.t('Login.Device')
);
this.turnToHomePage("/Square");
} else {
@@ -630,7 +630,7 @@ export default defineComponent({
//修改密码提交
submitResetPassword() {
if (this.isPassword(this.newPassword) < 3) {
message.info("You must satisfy ALL password conditions to register.");
message.info(this.t('Login.PasswordConditions'));
return;
}
let data = {

View File

@@ -9,14 +9,14 @@
<div>
<div class="login_form_content" :state="emailStap">
<div v-show="emailStap === 1">
<div class="login_form_title marign_top30">School</div>
<div class="login_form_title marign_top30">{{ t('LoginSchool.School') }}</div>
<div class="generalModel_state">
<div
class="generalModel_state_item"
style="width: 100%; margin: 0"
>
<a-select
placeholder="Select a school"
:placeholder="t('LoginSchool.SelectSchool')"
v-model:value="selectSchool"
:options="schoolList"
@change="schoolListChange"
@@ -36,21 +36,21 @@
</a-select>
</div>
</div>
<div class="login_form_title marign_top30">Email</div>
<div class="login_form_title marign_top30">{{ t('LoginSchool.Email') }}</div>
<input
class="login_form_input"
placeholder="Enter your email address"
:placeholder="t('LoginSchool.EnterEmail')"
v-model="email"
@keydown.enter="submitPerLogin()"
/>
<div class="login_form_title marign_top30">
<div>Password</div>
<div>{{ t('LoginSchool.Password') }}</div>
</div>
<div class="password_input_block">
<input
class="login_form_input"
:type="passwordType"
placeholder="Enter your password"
:placeholder="t('LoginSchool.EnterPassword')"
v-model="password"
@keydown.enter="submitPerLogin()"
/>
@@ -79,15 +79,15 @@
</div> -->
<div class="email_last_step_bottom">
<div class="email_last_step_des">
<div class="sent_email_content">Enter Code</div>
<div class="sent_email_content">{{ t('LoginSchool.EnterCode') }}</div>
<div class="tip_content">
<span v-show="time">{{ time }}s</span>
<span v-show="!time" @click="emailNextStepFun()"
>Resend</span
>{{ t('LoginSchool.Resend') }}</span
>
</div>
</div>
<div class="codeEmail">Weve sent an code to your email <span>{{ email }}</span></div>
<div class="codeEmail">{{ t('LoginSchool.SentCodeToEmail') }} <span>{{ email }}</span></div>
<div class="codeEmailInput">
<VerificationCodeInput
ref="verificationCodeInputDom"
@@ -101,17 +101,17 @@
</div>
<div class="login_text" v-show="emailStap !== 2">
<div class="forget_password_text" @click="changeIsLogin(2)">
Forgot your password
{{ t('LoginSchool.ForgotPassword') }}
</div>
</div>
<div class="login_form_title marign_top30">
<label :class="{ active: emailStap == 2 }">
<input :state="emailStap" type="checkbox" v-model="checked" />
<span>
I agree to the
<a href="https://code-create.com.hk/aida-terms-and-conditions/" style="text-decoration: underline;color: #000;">Terms</a>,
<a href="https://aida.com.hk/privacy-policy.html" target="_blank" style="text-decoration: underline;color: #000;">Privacy Policy</a>,
and Fees.
{{ t('LoginSchool.AgreeTo') }}
<a href="https://code-create.com.hk/aida-terms-and-conditions/" style="text-decoration: underline;color: #000;">{{ t('LoginSchool.Terms') }}</a>,
<a href="https://aida.com.hk/privacy-policy.html" target="_blank" style="text-decoration: underline;color: #000;">{{ t('LoginSchool.PrivacyPolicy') }}</a>,
{{ t('LoginSchool.AndFees') }}
</span>
</label>
</div>
@@ -132,7 +132,7 @@
@click="submitPerLogin()"
@mousedown="loginBtnMousedown"
>
Sign in
{{ t('LoginSchool.SignIn') }}
</div>
<!-- <div class="login_text">
@@ -158,14 +158,14 @@
>
<!-- <i class="fi fi-br-arrow-left"></i> -->
<i class="fi fi-br-angle-left"></i>
<span class="forget_password_content_title">Retrieve password</span>
<span class="forget_password_content_title">{{ t('LoginSchool.RetrievePassword') }}</span>
</div>
<div v-show="frogetPasswordStep === 1">
<div class="forget_passored_form_content">
<div class="forget_passored_form_title">Email</div>
<div class="forget_passored_form_title">{{ t('LoginSchool.Email') }}</div>
<input
class="forget_passored_form_input"
placeholder="Enter your email"
:placeholder="t('LoginSchool.EnterEmail')"
v-model="forgetPasswordEmail"
@keydown.enter="forgetPasswordNextStepFun()"
/>
@@ -174,20 +174,20 @@
class="forget_submit_button marign_top40"
@click="forgetPasswordNextStepFun()"
>
Next step
{{ t('LoginSchool.NextStep') }}
</div>
</div>
<div v-show="frogetPasswordStep === 2">
<div class="forget_verif_code_des">Verification Code</div>
<div class="forget_verif_code_des">{{ t('LoginSchool.VerificationCode') }}</div>
<div class="email_last_step_des">
<div class="sent_email_content">
Sent to {{ forgetPasswordEmail }}
{{ t('LoginSchool.SentTo') }} {{ forgetPasswordEmail }}
</div>
<div class="tip_content">
<span v-show="time">{{ time }}s</span>
<span v-show="!time" @click="forgetPasswordNextStepFun()"
>Resend</span
>{{ t('LoginSchool.Resend') }}</span
>
</div>
</div>
@@ -199,7 +199,7 @@
<div v-show="frogetPasswordStep === 3">
<div class="forget_passored_form_content">
<div class="forget_passored_form_title">Password</div>
<div class="forget_passored_form_title">{{ t('LoginSchool.Password') }}</div>
<div v-show="passwordConditionShow" class="conditionShow">
<div class="item">
<div class="icon">
@@ -212,7 +212,7 @@
class="fi fi-br-check"
></i>
</div>
<div class="text">At least 8 characters long</div>
<div class="text">{{ t('LoginSchool.AtLeast8Chars') }}</div>
</div>
<div class="item">
<div class="icon">
@@ -225,7 +225,7 @@
class="fi fi-br-check"
></i>
</div>
<div class="text">Must contain special characters</div>
<div class="text">{{ t('LoginSchool.MustContainSpecial') }}</div>
</div>
<div class="item">
<div class="icon">
@@ -239,13 +239,13 @@
></i>
</div>
<div class="text">
Mix of uppercase, lowercase and numbers
{{ t('LoginSchool.MixUpperLowerNumbers') }}
</div>
</div>
</div>
<input
class="forget_passored_form_input"
placeholder="Enter a new password"
:placeholder="t('LoginSchool.EnterNewPassword')"
v-model="newPassword"
@focus="() => (passwordConditionShow = true)"
@blur="() => (passwordConditionShow = false)"
@@ -257,7 +257,7 @@
class="forget_submit_button marign_top40"
@click="submitResetPassword()"
>
Submit
{{ t('LoginSchool.Submit') }}
</div>
</div>
</div>
@@ -270,7 +270,7 @@
</template>
<script lang="ts">
import { defineComponent, ref, onMounted, reactive, toRefs } from "vue";
import { defineComponent, ref, onMounted, reactive, toRefs, inject } from "vue";
import { Https } from "@/tool/https";
import { isEmail } from "@/tool/util";
import { setCookie, WriteCookie } from "@/tool/cookie";
@@ -280,7 +280,6 @@ import googleLogin from "@/component/LoginPage/googleLogin.vue";
import weiXinLogin from "@/component/LoginPage/weiXinLogin.vue";
import phoneLogin from "@/component/LoginPage/phoneLogin.vue";
import { useStore } from "vuex";
import { useI18n } from "vue-i18n";
import { setLang } from "@/tool/guide";
import md5 from "md5";
export default defineComponent({
@@ -292,7 +291,8 @@ export default defineComponent({
},
setup() {
let timer: any = 0;
const { locale } = useI18n();
// 从父组件注入 i18n
const i18n = inject('i18n') as { t: any, locale: any };
const store = useStore();
let loadingShow = ref(false);
const data = reactive({
@@ -331,7 +331,8 @@ export default defineComponent({
...toRefs(data),
store,
timer,
locale,
locale: i18n?.locale,
t: i18n?.t,
loadingShow,
schoolListChange,
filterOption,
@@ -396,7 +397,7 @@ export default defineComponent({
//邮箱登录的下一步
emailNextStepFun() {
if (!isEmail(this.email)) {
message.info("The email format is incorrect");
message.info(this.t('LoginSchool.IncorrectEmailFormat'));
return;
}
let data = {
@@ -426,7 +427,7 @@ export default defineComponent({
//忘记密码的下一步
forgetPasswordNextStepFun() {
if (!isEmail(this.forgetPasswordEmail)) {
message.info("The email format is incorrect");
message.info(this.t('LoginSchool.IncorrectEmail'));
return;
}
let data = {
@@ -482,7 +483,7 @@ export default defineComponent({
let code = verificationCodeInputDom.getCtData.map(item => item).join('');
console.log(code)
if(code.length !== this.emailCode.length){
message.info("Please enter the complete verification code.");
message.info(this.t('LoginSchool.CompleteVerificationCode'));
}else{
this.submitEmailLogin(code)
}
@@ -491,26 +492,26 @@ export default defineComponent({
return;
} else {
if (!this.password) {
message.info("Please enter your account number or password");
message.info(this.t('LoginSchool.PleaseEnterYourAccountNumberOrPassword'));
return;
}
//输入邮箱
if (!this.email) {
message.info("Please enter your email address");
message.info(this.t('LoginSchool.NeedEmail'));
return;
}
if (!this.selectSchool) {
message.info("Please select a school");
message.info(this.t('LoginSchool.SelectSchool'));
return;
}
//判断邮箱格式是否正确
if (!isEmail(this.email)) {
message.info("The email format is incorrect");
message.info(this.t('LoginSchool.IncorrectEmailFormat'));
return;
}
//判断是否同意隐私政策
if (!this.checked) {
message.info("Agree to all terms, privacy fees and policies");
message.info(this.t('Login.AgreePolicies'));
return;
}
let data = {
@@ -576,7 +577,7 @@ export default defineComponent({
},1000)
},
isCheckAgreement() {
message.info("Agree to all terms, privacy fees and policies");
message.info(this.t('Login.AgreePolicies'));
},
//谷歌登录
googelLogin(value: any) {
@@ -612,7 +613,7 @@ export default defineComponent({
if (window.innerWidth < 768) {
message.info(
"If you need to design, please log in using an iPad or computer."
this.t('Login.Device')
);
this.turnToHomePage("/Square");
} else {
@@ -641,7 +642,7 @@ export default defineComponent({
//修改密码提交
submitResetPassword() {
if (this.isPassword(this.newPassword) < 3) {
message.info("You must satisfy ALL password conditions to register.");
message.info(this.t('Login.PasswordConditions'));
return;
}
let data = {

View File

@@ -62,10 +62,8 @@
},
methods: {
onInput(val, index) {
console.log("input", val, index);
clearTimeout(this.timeout);
this.timeout = setTimeout(() => {
console.log("input=>", val, index);
// val = val.replace(/[^0-9]/g, '');
val = String(val).replace(/\D/g, "");
this.getCtData[index] = val;

View File

@@ -2,7 +2,7 @@
<div class="Container">
<div class="icon" @click="openWeiXinModel">
<img src="@/assets/images/loginPage/weiXinIcon.svg" alt="" />
<span>{{ $props.text }}</span>
<span>{{ displayText }}</span>
</div>
<weiXinModel ref="weiXinModel"></weiXinModel>
</div>
@@ -18,6 +18,7 @@ import {
toRefs,
} from "vue";
import weiXinModel from "./weiXinModel.vue";
import { useI18n } from 'vue-i18n'
export default defineComponent({
name: "login",
components: {
@@ -26,20 +27,25 @@ export default defineComponent({
props: {
text: {
type: String,
default: "Sign in with Wechat",
default: ''
},
},
setup() {
setup(props) {
let weiXinDom = reactive({
weiXinModel: null,
});
const { t } = useI18n()
const openWeiXinModel = () => {
weiXinDom.weiXinModel.init();
};
const displayText = computed(() => {
return props.text || t('Login.LoginWithWechat')
})
onMounted(() => {});
return {
...toRefs(weiXinDom),
openWeiXinModel,
displayText,
};
},
});

View File

@@ -113,8 +113,8 @@
<img v-for="item in scaleImageData?.designPythonOutfitList" v-lazy="item.designUrl">
</div>
</div>
<div v-if="userDetail.systemList.indexOf(1) > -1 && scaleImageData.isMine != 1 && scaleImageData.selected != 1 && scaleImageData.openSource != 0" class="started_btn" @click="setChoose" >{{$t('newScaleImage.SecondaryCreation')}}</div>
<!-- <div v-if="systemUser.value == 1 && scaleImageData.isMine != 1 && scaleImageData.selected != 1" class="started_btn" @click="setChoose" :title="systemUser.value != 1?$t('newScaleImage.jsContent1'): scaleImageData.openSource == 0?$t('newScaleImage.jsContent2'):''" :class="{active:systemUser.value != 1?true:scaleImageData.openSource == 0}">{{$t('newScaleImage.SecondaryCreation')}}</div> -->
<!-- <div v-if="userDetail.systemList.indexOf(1) > -1 && scaleImageData.isMine != 1 && scaleImageData.selected != 1 && scaleImageData.openSource != 0" class="started_btn" @click="setChoose" >{{$t('newScaleImage.SecondaryCreation')}}</div> -->
<div v-if="userDetail.systemList.indexOf(1) > -1 && scaleImageData.openSource != 0" class="started_btn" @click="setChoose" >{{$t('newScaleImage.SecondaryCreation')}}</div>
</div>
<div v-else class="newScaleImage_right_content_generate">
<div class="scaleImage_chunk_item content_left_generate_item">
@@ -437,26 +437,37 @@ export default defineComponent({
})
}
let setChoose = async () =>{
if(userDetail.value.systemList.indexOf(1) == -1){
return message.info(t('newScaleImage.jsContent1'))
}
let flag = true
let setChoose = async()=>{
if(!flag) return
flag = false
try {
if(userDetail.value.systemList.indexOf(1) == -1){
message.info(t('newScaleImage.jsContent1'))
return
}
const targetDate = new Date('2025-09-01T00:00:00');
// 解析输入日期字符串
const inputDate = new Date(imgData.scaleImageData.createDate);
if(inputDate < targetDate){
return message.info(t('newScaleImage.jsContent2'))
const targetDate = new Date('2025-09-01T00:00:00');
// 解析输入日期字符串
const inputDate = new Date(imgData.scaleImageData.createDate);
if(inputDate < targetDate){
message.info(t('newScaleImage.jsContent2'))
return
}
if(imgData.scaleImageData.openSource == 0){
message.info(t('newScaleImage.jsContent2'))
return
}
store.state.Workspace.cachedRoutes = [];
let id = await getWorks(imgData.scaleImageData.id)
await router.push(`/home/history/${id}`)
store.commit('setChooseIsDesign',false)
} finally {
// 函数执行完成后恢复为 true确保无论成功还是失败都能再次点击
flag = true
}
if(imgData.scaleImageData.openSource == 0){
return message.info(t('newScaleImage.jsContent2'))
}
let id = await getWorks(imgData.scaleImageData.id)
router.push(`/home/history/${id}`)
// router.push({name:'home',params: {id:imgData.scaleImageData.id,type:'Works'}})
store.commit('setChooseIsDesign',false)
// router.push({name:'homePage',params: {id:imgData.scaleImageData.userLikeGroupSourceId,type:'Works'}})
}
let setCommentReply = (value:any,str:any)=>{
imgData.commentReply.leve1Id = value.id
imgData.commentReply.leve2Id = null

View File

@@ -132,8 +132,8 @@
</div>
<div class="modal_img_max">
<div v-if="!modalImg[0]?.id" class="modal_img" id="modal_img" :class="{active:flex_direction}">
<div v-for="item,index in layoutList" :class="[moodb_className[index]]" class="modal_imgItem">
<img :src="item.imgUrl" v-modelImg>
<!-- <div class="modal_img" id="modal_img" :class="{active:flex_direction}"> -->
<div v-for="item,index in layoutList" :class="[moodb_className[index]]" :style="{'background-image':`url(${item.imgUrl})`}" class="modal_imgItem">
</div>
</div>
<div v-else class="modal_img">
@@ -244,30 +244,6 @@ export default defineComponent({
this.token = getCookie("token") || "";
this.uploadUrl = getUploadUrl();
},
directives:{
modelImg:{
mounted(el) {
let parentNode = el.parentNode
if(parentNode.offsetHeight >= parentNode.offsetWidth){
el.style.height = 100+'%'
el.style.width = 'auto'
}else{
el.style.width = 100+'%'
el.style.height = 'auto'
}
},
updated (el) {
let parentNode = el.parentNode
if(parentNode.offsetHeight >= parentNode.offsetWidth){
el.style.height = 100+'%'
el.style.width = 'auto'
}else{
el.style.width = 100+'%'
el.style.height = 'auto'
}
}
}
},
methods: {
open(num: Number) {
this.openClick = num;
@@ -445,7 +421,7 @@ export default defineComponent({
}
}
this.edieShow = true
if(this.moodb_[arr.length-1].length == 2){
if(this.moodb_[arr.length-1].length == 1){
this.moodb_className = this.moodb_[arr.length-1][0]
}else{
this.moodb_className = this.moodb_[arr.length-1][random]
@@ -628,6 +604,7 @@ export default defineComponent({
height: calc(5rem*1.2);
overflow-x: hidden;
display: flex;
&.modal_img::-webkit-scrollbar {
display: none;
}
@@ -706,15 +683,9 @@ export default defineComponent({
position: relative;
overflow: hidden;
text-align: center;
img{
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%,-50%);
float: left;
user-select:none;
-webkit-user-drag: none;
}
background-repeat: no-repeat;
background-position: center;
background-size: cover;
}
.wh1{
width: 23%;

View File

@@ -155,7 +155,7 @@
<textarea
ref="textareaRef"
class="textarea"
:placeholder="$t('Generate.inputContent1')"
:placeholder="inputPlaceholder"
@input="ifMaximumLength"
@keydown.enter.prevent="getPrductimg()"
v-model="productimgSearchName"
@@ -242,7 +242,16 @@
</div>
</div>
<div class="prompt-input-container" v-show="!showMotion">
<div class="title">{{ $t('ProductImg.Prompt') }}</div>
<div class="title">
<span>{{ $t('ProductImg.Prompt') }}</span>
<SvgIcon
class="cursor-icon"
@click="handleNavigateHelp"
name="CHelpFlip"
size="18"
color="#000"
/>
</div>
<promptInput :content="prompt" ref="promptInputRef" />
</div>
<div class="transferPose" v-show="showMotion">
@@ -379,7 +388,10 @@
<div class="mark_loading" v-show="loadingShow">
<a-spin size="large" />
</div>
<Prompt v-model:showModal="showPromptAssist" isDesignPage />
<template>
<Prompt v-if="scaleImageList[scaleImageIndex]?.resultType === 'ToProductImage'" v-model:showModal="showPromptAssist" />
<PromptEditProduct v-if="scaleImageList[scaleImageIndex]?.resultType === 'Relight'" v-model:showModal="showPromptAssist" />
</template>
<Product
v-model:showModal="showProductList"
:frameList="fullProductImages"
@@ -399,6 +411,7 @@ import {
createVNode,
reactive,
computed,
watch,
useTemplateRef
} from 'vue'
import { Https } from '@/tool/https'
@@ -410,13 +423,14 @@ import { useStore } from 'vuex'
import Prompt from '@/component/home/tools/toProduct/Prompt.vue'
import promptInput from '@/component/home/tools/poseTransfer/promptInput.vue'
import Product from '@/component/home/tools/poseTransfer/Product.vue'
import PromptEditProduct from '@/component/home/tools/toProduct/PromptEditProduct.vue'
import {
getFirstFrame,
getFirstAndLastFrame
} from '@/component/home/tools/poseTransfer/prompt'
export default defineComponent({
components: { Prompt, promptInput, Product },
components: { Prompt, promptInput, Product, PromptEditProduct },
props: {
productData: {
type: Object,
@@ -445,7 +459,7 @@ export default defineComponent({
let userDetail: any = computed(() => {
return store.state.UserHabit.userDetail
})
let { t } = useI18n()
let { t, locale } = useI18n()
const textareaRef = useTemplateRef<HTMLTextAreaElement>('textareaRef')
const videoType = ref(2)
const showMotion = computed(() => videoType.value === 1)
@@ -494,10 +508,12 @@ export default defineComponent({
})
const showDropdown = computed(() => {
if (isPoseTransfer) {
if (isPoseTransfer.value) {
return videoType.value === 1
} else {
return scaleImageList[scaleImageIndex]?.resultType != 'Relight'
return (
productimg.scaleImageList[productimg.scaleImageIndex]?.resultType !== 'Relight'
)
}
})
let speed = reactive({
@@ -546,12 +562,22 @@ export default defineComponent({
document.removeEventListener('click', openSpeed)
}
}
const resetSpeedState = () => {
if (!speed.speedState) return
speed.speedState = false
document.removeEventListener('click', openSpeed)
}
const setSpeed = (item: any) => {
speed.speedData = item
document.removeEventListener('click', openSpeed)
speed.speedState = false
}
let scaleImage: any = ref(false)
watch(scaleImage, value => {
if (!value) {
resetSpeedState()
}
})
let loadingShow = ref(false)
let isComparison = ref(false) // home/design组件中修改的,当前组件没有修改
const visible = ref<boolean>(false)
@@ -582,13 +608,13 @@ export default defineComponent({
})
const showPromptAssist = ref(false)
const handleClickAssistBtn = () => {
const { httpType } = store.state.Workspace.probjects
const isSingleDesign = httpType === 'SINGLE_DESIGN'
if (!isSingleDesign) {
const promptText = t('ProductImg.Series')
productimg.productimgSearchName = promptText
return
}
// const { httpType } = store.state.Workspace.probjects
// const isSingleDesign = httpType === 'SINGLE_DESIGN'
// if (!isSingleDesign) {
// const promptText = t('ProductImg.Series')
// productimg.productimgSearchName = promptText
// return
// }
showPromptAssist.value = true
}
@@ -1275,6 +1301,15 @@ export default defineComponent({
'PoseTransfer'
)
})
const inputPlaceholder = computed(() => {
if (
productimg.scaleImageList[productimg.scaleImageIndex]?.resultType === 'Relight'
) {
return t('ProductImg.relightInput')
} else {
return t('ProductImg.productInput')
}
})
const showCompare = computed(() => {
// isComparison.value
@@ -1284,12 +1319,19 @@ export default defineComponent({
return videoType.value === 3 ? false : true
}
})
const handleNavigateHelp = () => {
const url =
locale === 'CHINESE_SIMPLIFIED'
? 'https://aida-user-manual-chinese.super.site/2b08f755cedd80a985cffdf2af80c538'
: 'https://aida-user-manual.super.site/advanced-tool/animated-product-image/to-product-video-prompt-assist '
window.open(url,'_blank')
}
onBeforeUnmount(() => {
clearInterval(prductimgTime)
clearInterval(remPrductimgTime)
productimg.productimgIsProductimg = false
productimg.productimgRemProductimg = false
resetSpeedState()
})
return {
t,
@@ -1346,7 +1388,9 @@ export default defineComponent({
setNewVideoRef,
handlePlayNewVideo,
isNewVideoPlaying,
showDropdown
showDropdown,
inputPlaceholder,
handleNavigateHelp
}
},
data() {
@@ -1758,12 +1802,16 @@ export default defineComponent({
:deep(.promptInput) {
box-sizing: border-box;
}
.title {
font-weight: 500;
color: #000;
font-size: 1.7rem;
margin-bottom: 1.4rem;
}
.title {
display: flex;
align-items: center;
column-gap: 1rem;
.cursor-icon {
display: flex;
width: auto;
cursor: pointer;
}
}
}
.prompt-container {
margin-top: 4rem;

View File

@@ -682,6 +682,7 @@ export default defineComponent({
store.commit("cancelDeleteDesignCollectionList",index);
}
const designMousedown = (e:any,design:any,str:string)=>{
collItemSize.isMove = false
if(str != 'disLike'){
if(design.resultType != 'Design' || designData.isUnfold)return
if(str != 'like' && showDesignMark.value) return
@@ -695,7 +696,6 @@ export default defineComponent({
startY = e.clientY,
left = item.el.offsetLeft,
top = item.el.offsetTop;
collItemSize.isMove = false
let moveFun = (e:any) => {
collItemSize.isMove = true
let X = e.clientX - startX + left;
@@ -1200,6 +1200,11 @@ export default defineComponent({
likeDesignCollectionList.value.forEach((likeItem:any,index:any)=>{
if(likeItem?.childList?.length > 0){
let index = likeItem.childList.findIndex((item:any)=>{return item.taskId == listItem})
likeItem.childList.forEach((item)=>{
if(item.sort > likeItem.childList[index].sort){
item.sort -= 1
}
})
likeItem.childList.splice(index,1)
}
})

View File

@@ -7,7 +7,7 @@
<!-- <div v-show="openType === 'history'" class="function">
<design :key="componentKey" ref="design"></design>
</div> -->
<router-view v-if="
<router-view v-show="
(openType && openType != 'history' && !routeQuery.id) ||
$route.path != '/home'"
@setTask="setTask"
@@ -23,7 +23,7 @@
<!-- <div v-else-if="routeQuery.id" class="function">
<design :key="componentKey" ref="design"></design>
</div> -->
<div v-else-if="!routeQuery.history" class="function">
<div v-if="!$route.params.id && !routeQuery.id" class="function">
<newPorject ref="newPorject" @newProject=newProject></newPorject>
</div>
<!-- <iframe src="https://kaput-relative-4bb.notion.site/ebd/22a8f755cedd809e98a2c8c6366ee701" width="100%" height="100%" frameborder="0" allowfullscreen /> -->
@@ -55,13 +55,16 @@ export default defineComponent({
const data = reactive({
openType:'',
componentKey:null,
isShowMark:false,
isShowMark:true,
routeQuery:{} as any,
selectObject:computed(()=>store.state.Workspace.probjects) as any,//选择的项目
chatData:null as any,
dataLoad:true as any,
cachedRoutes:computed(()=>store.state.Workspace.cachedRoutes),//
})
onMounted(()=>{
data.isShowMark = false
})
let settingGetHistory:any = inject('settingGetHistory')
const setIsShowMark = (boolean:boolean)=>{
data.isShowMark = boolean

View File

@@ -38,7 +38,7 @@
</div>
<div class="style marginBottom" v-if="show.style">
<div class="text">{{$t('Habit.Style')}}</div>
<div class="center">{{ selectObject?.styleName?selectObject?.styleName:'All' }}</div>
<div class="center">{{ selectObject?.styleName?selectObject?.styleName:$t('Header.All') }}</div>
<div class="gallery_btn" @click="setStyle">{{ $t('Habit.Select') }}</div>
</div>
<div class="style brand marginBottom">

View File

@@ -634,7 +634,10 @@ export default defineComponent({
let index = data.noLikeList.findIndex(
(obj: any) => obj.taskId === element.taskId
)
data.noLikeList[index] = element
data.noLikeList[index] = {
...element,
parentId: data.selectImg.parentId
}
list = ''
clearInterval(data.generateTime)
data.isGenerate = false
@@ -777,6 +780,7 @@ export default defineComponent({
})
}
const likeSetBtn = (id: any, str: string) => {
console.log(1111)
data.likeList.forEach((item: any, index: any) => {
if (item.id == id && id) {
if (str == 'zoom') {
@@ -813,7 +817,9 @@ export default defineComponent({
}
let likeFile = (item: any, str: any, index: any) => {
let url
console.log(item)
let value = {}
console.log(props.isDesignPage)
if (str == 'like') {
value = {
likeOrDislike: 'like',
@@ -832,6 +838,7 @@ export default defineComponent({
emit('unLike', item)
}
}
store.commit('set_loading', true)
Https.axiosPost(Https.httpUrls.poselikeOrDisike, {}, { params: value })
.then(rv => {
if (str == 'like') {
@@ -888,8 +895,10 @@ export default defineComponent({
}
store.commit('setPoseTransfer', addValue)
}
store.commit('set_loading', false)
})
.catch(res => {
store.commit('set_loading', false)
console.error('likeFile error:', res)
})
}
@@ -1669,7 +1678,7 @@ export default defineComponent({
.ant-upload-select-picture-card {
width: 100%;
height: 100%;
border: 1px solid #000;
border: 0.1rem solid #000;
background: #fff;
}
}

View File

@@ -65,7 +65,7 @@ defineExpose({
<style lang="less" scoped>
.promptInput {
--promptInputBorderRadius: 10px;
--promptInputBorder: 2px solid #dcdfe6;
--promptInputBorder: 1px solid #000;
--promptInputPadding: 1.5rem;
width: 100%;
@@ -86,7 +86,7 @@ defineExpose({
.sender-container {
position: relative;
border-radius: 10px;
border: 2px solid #dcdfe6;
border: 1px solid #000;
padding: 1.5rem;
font-size: 1.8rem;
.sender-wrapper {
@@ -100,7 +100,7 @@ defineExpose({
.textarea-container {
position: relative;
border-radius: 10px;
border: 2px solid #dcdfe6;
border: 1px solid #000;
padding: 1.5rem;
height: auto;
font-size: 1.8rem;

View File

@@ -93,7 +93,7 @@ import generatedSketch from '@/assets/images/product/generated_sketch.png'
import maleSingleGarmentSketch from '@/assets/images/product/male_single_garment_sketch.png'
import maleSingleGarmentResult from '@/assets/images/product/male_single_garment_result.png'
import maleSingleModelSketch from '@/assets/images/product/male_single_garment_model_sketch.png'
import maleSingleModelResult from '@/assets/images/product/male_single_garment_model_sketch.png'
import maleSingleModelResult from '@/assets/images/product/male_single_garment_model_result.png'
import femaleChildModelResult from '@/assets/images/product/single_female_child_model_result.png'
import maleSingleChildSketch from '@/assets/images/product/single_male_child_model_sketch.png'
import maleSingleChildResult from '@/assets/images/product/single_male_child_model_result.png'
@@ -121,7 +121,7 @@ const promptList = computed(() => {
return [t('ProductImg.UploadWithoutModel'), t('ProductImg.UploadWithModel')]
} else {
// 如果是从design来的
if (isSingleDesign) {
if (props.isDesignPage) {
// SINGLE_DESIGN: 两个提示词
// 根据年龄和性别选择对应的提示词
let firstPrompt: string // 不带模特的提示词
@@ -255,8 +255,8 @@ const exampleList = computed(() => {
}
} else {
const { ageGroup, httpType, sex } = store.state.Workspace.probjects
const isSingleDesign = httpType === 'SINGLE_DESIGN'
if (!isSingleDesign) return {}
// const isSingleDesign = httpType === 'SINGLE_DESIGN'
// if (!isSingleDesign) return {}
const isAdult = ageGroup === 'Adult'
const isFemale = sex === 'Female'
if (isAdult) {

View File

@@ -697,6 +697,7 @@ export default defineComponent({
emit('unLike', item)
}
}
store.commit('set_loading', true)
Https.axiosPost(url, data)
.then(rv => {
if (str == 'like') {
@@ -728,8 +729,11 @@ export default defineComponent({
store.commit('setRelightList', value)
}
}
store.commit('set_loading', false)
})
.catch(res => {})
.catch(res => {
store.commit('set_loading', false)
})
}
let remPrductimgTime: any = null
let prductimgTime: any = null
@@ -1101,13 +1105,13 @@ export default defineComponent({
const showPromptAssist = ref(false)
const handleClickAssistBtn = () => {
const { httpType } = store.state.Workspace.probjects
const isSingleDesign = httpType === 'SINGLE_DESIGN'
if (props.isDesignPage && !isSingleDesign) {
const promptText = t('ProductImg.Series')
productImgData.searchName[props.productimgMenu.value] = promptText
return
}
// const { httpType } = store.state.Workspace.probjects
// const isSingleDesign = httpType === 'SINGLE_DESIGN'
// if (props.isDesignPage && !isSingleDesign) {
// const promptText = t('ProductImg.Series')
// productImgData.searchName[props.productimgMenu.value] = promptText
// return
// }
showPromptAssist.value = true
}
@@ -1250,13 +1254,15 @@ export default defineComponent({
> .item {
margin-right: 1rem;
width: calc(100% / 2 - 0.5rem);
// width: calc(100% / 2 - 0.5rem);
// height: 25rem;
width: 12.7rem;
height: 17.8rem;
cursor: pointer;
overflow: hidden;
display: flex;
justify-content: center;
flex-shrink: 0;
height: 25rem;
position: relative;
// &.active{
// border: 2px solid;
@@ -1532,6 +1538,9 @@ export default defineComponent({
.ant-upload-select-picture-card {
width: 12.7rem;
height: 17.8rem;
border-width: 1px;
background: #fff;
border: 0.1rem solid #000;
}
}
}

File diff suppressed because it is too large Load Diff