This commit is contained in:
X1627315083
2025-09-01 14:03:30 +08:00
parent c387a71ba8
commit 89639aaec9
49 changed files with 819 additions and 232 deletions

File diff suppressed because one or more lines are too long

Before

Width:  |  Height:  |  Size: 7.8 KiB

After

Width:  |  Height:  |  Size: 509 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 834 KiB

View File

@@ -829,11 +829,9 @@ tr > .ant-picker-cell-in-view.ant-picker-cell-range-hover-start:last-child::afte
width: 100%; width: 100%;
} }
.generalModel_state .generalModel_state_item .el-cascader .el-input .el-input__wrapper .el-input__inner { .generalModel_state .generalModel_state_item .el-cascader .el-input .el-input__wrapper .el-input__inner {
padding: 0;
font-size: 1.8rem; font-size: 1.8rem;
} }
.generalModel_state .generalModel_state_item .el-cascader__tags {
padding-left: 1rem;
}
.generalModel_state .generalModel_state_item .el-cascader__tags, .generalModel_state .generalModel_state_item .el-cascader__tags,
.generalModel_state .generalModel_state_item .el-cascader__collapse-tag { .generalModel_state .generalModel_state_item .el-cascader__collapse-tag {
--el-color-primary: #d9d9d9; --el-color-primary: #d9d9d9;
@@ -867,7 +865,7 @@ tr > .ant-picker-cell-in-view.ant-picker-cell-range-hover-start:last-child::afte
margin: 0; margin: 0;
width: 100%; width: 100%;
height: 4.6rem; height: 4.6rem;
padding-left: 2.1rem; padding-left: 1.1rem;
line-height: 4.6rem; line-height: 4.6rem;
font-size: 1.8rem; font-size: 1.8rem;
box-sizing: border-box; box-sizing: border-box;
@@ -1370,12 +1368,12 @@ tr > .ant-picker-cell-in-view.ant-picker-cell-range-hover-start:last-child::afte
border-radius: 3rem; border-radius: 3rem;
color: #fff; color: #fff;
cursor: pointer; cursor: pointer;
margin: 0 2rem 2rem 0; margin: 0 1.5rem 1.5rem 0;
border: 1.8px solid #000;
background-color: #000; background-color: #000;
} }
.admin_page .admin_search_item:hover { .admin_page .admin_search_item:hover {
color: #000; color: #000;
border: 2px solid #000;
background-color: #fff; background-color: #fff;
} }
.admin_page .admin_search_item:last-child { .admin_page .admin_search_item:last-child {

View File

@@ -905,6 +905,7 @@ tr > .ant-picker-cell-in-view.ant-picker-cell-range-hover-start:last-child::afte
padding: 0; padding: 0;
width: 100%; width: 100%;
.el-input__inner{ .el-input__inner{
padding: 0;
font-size: 1.8rem; font-size: 1.8rem;
} }
} }
@@ -913,7 +914,7 @@ tr > .ant-picker-cell-in-view.ant-picker-cell-range-hover-start:last-child::afte
.el-cascader:hover{ .el-cascader:hover{
} }
.el-cascader__tags{ .el-cascader__tags{
padding-left: 1rem; // padding-left: 1rem;
} }
.el-cascader__tags,.el-cascader__collapse-tag{ .el-cascader__tags,.el-cascader__collapse-tag{
--el-color-primary: #d9d9d9; --el-color-primary: #d9d9d9;
@@ -943,7 +944,7 @@ tr > .ant-picker-cell-in-view.ant-picker-cell-range-hover-start:last-child::afte
margin: 0; margin: 0;
width: 100%; width: 100%;
height: 4.6rem; height: 4.6rem;
padding-left: 2.1rem; padding-left: 1.1rem;
line-height: 4.6rem; line-height: 4.6rem;
font-size: 1.8rem; font-size: 1.8rem;
box-sizing: border-box; box-sizing: border-box;
@@ -1498,11 +1499,11 @@ tr > .ant-picker-cell-in-view.ant-picker-cell-range-hover-start:last-child::afte
border-radius: 3rem; border-radius: 3rem;
color: #fff; color: #fff;
cursor: pointer; cursor: pointer;
margin: 0 2rem 2rem 0; margin: 0 1.5rem 1.5rem 0;
border: 1.8px solid #000;
background-color: #000; background-color: #000;
&:hover{ &:hover{
color: #000; color: #000;
border: 2px solid #000;
background-color: #fff; background-color: #fff;
} }
} }

View File

@@ -148,6 +148,7 @@ export default defineComponent({
.account_comment{ .account_comment{
width: 100%; width: 100%;
.account_generalMessage_item{ .account_generalMessage_item{
font-size: var(--aida-fsize1-6);
.account_generalMessage_item_right{ .account_generalMessage_item_right{
display: flex; display: flex;
align-items: center; align-items: center;

View File

@@ -140,6 +140,7 @@ export default defineComponent({
} }
.account_generalMessage_center{ .account_generalMessage_center{
.account_generalMessage_item{ .account_generalMessage_item{
font-size: var(--aida-fsize1-6);
.account_generalMessage_item_right{ .account_generalMessage_item_right{
display: flex; display: flex;
align-items: center; align-items: center;

View File

@@ -149,6 +149,7 @@ export default defineComponent({
width: 100%; width: 100%;
.account_generalMessage_center{ .account_generalMessage_center{
.account_generalMessage_item{ .account_generalMessage_item{
font-size: var(--aida-fsize1-6);
.account_generalMessage_item_right{ .account_generalMessage_item_right{
display: flex; display: flex;
align-items: center; align-items: center;

View File

@@ -45,11 +45,11 @@
</div> </div>
</div> </div>
<div class="modal_title_text"> <div class="modal_title_text">
<div>{{ title }} User</div> <div>{{ title.label }} User</div>
</div> </div>
<div class="allUserPoeration_center admin_page"> <div class="allUserPoeration_center admin_page">
<div class="admin_state_item"> <div class="admin_state_item">
<span>User Name: <span>*</span></span> <span>{{ $t('adminSeAllUser.UserName') }}: <span>*</span></span>
<input <input
v-model="userName" v-model="userName"
placeholder="Please enter user name" placeholder="Please enter user name"
@@ -58,7 +58,7 @@
/> />
</div> </div>
<div class="admin_state_item"> <div class="admin_state_item">
<span>User Email: <span>*</span></span> <span>{{ $t('adminSeAllUser.UserEmail') }}: <span>*</span></span>
<input <input
v-model="userEmail" v-model="userEmail"
placeholder="Please enter email" placeholder="Please enter email"
@@ -67,7 +67,7 @@
/> />
</div> </div>
<div class="admin_state_item"> <div class="admin_state_item">
<span>Password: <span>*</span></span> <span>{{ $t('adminSeAllUser.Password') }}: <span>*</span></span>
<input <input
@focus="focus" @focus="focus"
@blur="blur" @blur="blur"
@@ -78,7 +78,7 @@
/> />
</div> </div>
<div class="admin_state_item"> <div class="admin_state_item">
<span>Maximum Credits:</span> <span>{{ $t('adminSeAllUser.MaximumCredits') }}:</span>
<input <input
v-model="credits" v-model="credits"
placeholder="Please enter credits" placeholder="Please enter credits"
@@ -88,8 +88,8 @@
</div> </div>
</div> </div>
<div class="allUserPoeration_btn admin_page"> <div class="allUserPoeration_btn admin_page">
<div class="admin_search_item" @click="cancelDsign">Close</div> <div class="admin_search_item" @click="cancelDsign">{{ $t('adminSeAllUser.Close') }}</div>
<div class="admin_search_item" @click="setOk">OK</div> <div class="admin_search_item" @click="setOk">{{ $t('adminSeAllUser.OK') }}</div>
</div> </div>
</a-modal> </a-modal>
<div class="mark_loading" v-show="loadingShow"> <div class="mark_loading" v-show="loadingShow">
@@ -119,7 +119,7 @@ export default defineComponent({
operationsModal: false, operationsModal: false,
operationsEdit: false, operationsEdit: false,
loadingShow: false, loadingShow: false,
title: "", title: null,
}); });
let operationsData = reactive({ let operationsData = reactive({
accountId: -1, accountId: -1,
@@ -151,8 +151,8 @@ export default defineComponent({
operations.operationsModal = true; operations.operationsModal = true;
operations.operationsEdit = true; operations.operationsEdit = true;
operations.title = funStr; operations.title = funStr;
if (funStr == "Add") operations.operationsEdit = false; if (funStr.value == "Add") operations.operationsEdit = false;
if (funStr == "Edit") { if (funStr.value == "Edit") {
operationsData.accountId = data.id; operationsData.accountId = data.id;
operationsData.userName = data.userName; operationsData.userName = data.userName;
operationsData.userEmail = data.userEmail; operationsData.userEmail = data.userEmail;
@@ -195,7 +195,7 @@ export default defineComponent({
userEmail: operationsData.userEmail, userEmail: operationsData.userEmail,
userPassword: userPassword:
operationsData.password == operationsData.oldPassword operationsData.password == operationsData.oldPassword
? "" ? null
: md5(operationsData.password + "abc"), : md5(operationsData.password + "abc"),
}; };
}; };
@@ -209,19 +209,18 @@ export default defineComponent({
}; };
let setOk = () => { let setOk = () => {
let data; let data;
if (operations.title == "Add") { if (operations.title?.value == "Add") {
data = setAddData(); data = setAddData();
if (!isEmail(data.userEmail)) { if (!isEmail(data.userEmail)) {
message.info("The email format is incorrect"); message.info(t('adminSeAllUser.jsContent1'));
return; return;
} }
if ( if (
!data.userName || !data.userName ||
!data.userEmail || !data.userEmail ||
!data.userPassword || !data.userPassword
!data.creditsUsageLimit
) )
return message.warning("Please check the input box marked with *"); return message.warning(t('adminSeAllUser.jsContent2'));
Https.axiosPost(Https.httpUrls.addOrUpdateSubAccount, data).then( Https.axiosPost(Https.httpUrls.addOrUpdateSubAccount, data).then(
(rv) => { (rv) => {
if (rv) { if (rv) {
@@ -236,7 +235,7 @@ export default defineComponent({
message.info("The email format is incorrect"); message.info("The email format is incorrect");
return; return;
} }
if (!data.userName || !data.userEmail || !data.creditsUsageLimit) if (!data.userName || !data.userEmail)
return message.warning("Please check the input box marked with *"); return message.warning("Please check the input box marked with *");
Https.axiosPost(Https.httpUrls.addOrUpdateSubAccount, data).then( Https.axiosPost(Https.httpUrls.addOrUpdateSubAccount, data).then(
(rv) => { (rv) => {

View File

@@ -3,7 +3,7 @@
<div class="admin_table_search"> <div class="admin_table_search">
<div class="admin_state"> <div class="admin_state">
<div class="admin_state_item"> <div class="admin_state_item">
<span>Create Time:</span> <span>{{ $t('adminSeAllUser.CreateTime') }}:</span>
<a-range-picker <a-range-picker
style="width: 230px" style="width: 230px"
class="range_picker" class="range_picker"
@@ -45,7 +45,7 @@
/> />
</div> --> </div> -->
<div class="admin_state_item"> <div class="admin_state_item">
<span>User Name:</span> <span>{{ $t('adminSeAllUser.UserName') }}:</span>
<a-select <a-select
v-model:value="ids" v-model:value="ids"
mode="multiple" mode="multiple"
@@ -74,16 +74,22 @@
</div> </div>
<div class="admin_search"> <div class="admin_search">
<div class="admin_search_item" @click="searchHistoryList"> <div class="admin_search_item" @click="searchHistoryList">
Search {{ $t('adminSeAllUser.search') }}
</div> </div>
<div class="admin_search_item" @click="addhHistoryList"> <div class="admin_search_item" @click="addhHistoryList">
Add {{ $t('adminSeAllUser.add') }}
</div> </div>
<div class="admin_search_item" style="width: auto;padding: 0 2rem;" @click="downloadTemplate"> <div class="admin_search_item" style="width: auto;padding: 0 2rem;" @click="downloadTemplate">
Download template {{ $t('adminSeAllUser.DownloadTemplate') }}
</div> </div>
<div class="admin_search_item" style="width: auto;padding: 0 2rem;" @click="uploadTemplate"> <div class="admin_search_item" style="width: auto;padding: 0 2rem;" @click="uploadTemplate">
Upload template {{ $t('adminSeAllUser.UploadTemplate') }}
</div>
<div class="admin_search_item" style="width: auto;padding: 0 2rem;" @click="ExportAccountData">
{{ $t('adminSeAllUser.ExportAccountData') }}
</div>
<div class="admin_search_item" style="width: auto;padding: 0 2rem;" @click="deleteList">
{{ $t('adminSeAllUser.Delete') }}
</div> </div>
</div> </div>
<div class="admin_state_list"> <div class="admin_state_list">
@@ -91,19 +97,19 @@
class="admin_state_list_item" class="admin_state_list_item"
@click="lastGeTrialList('year')" @click="lastGeTrialList('year')"
> >
Nearly a year {{ $t('adminSeAllUser.NearlyAYear') }}
</div> </div>
<div <div
class="admin_state_list_item" class="admin_state_list_item"
@click="lastGeTrialList('month')" @click="lastGeTrialList('month')"
> >
Last month {{ $t('adminSeAllUser.LastMonth') }}
</div> </div>
<div <div
class="admin_state_list_item" class="admin_state_list_item"
@click="lastGeTrialList('week')" @click="lastGeTrialList('week')"
> >
Last week {{ $t('adminSeAllUser.LastWeek') }}
</div> </div>
</div> </div>
</div> </div>
@@ -113,6 +119,8 @@
:loading="tableLoading" :loading="tableLoading"
:columns="columns" :columns="columns"
:data-source="dataList" :data-source="dataList"
:row-selection="rowSelection"
rowKey="id"
:scroll="{ y: historyTableHeight }" :scroll="{ y: historyTableHeight }"
@change="changePage" @change="changePage"
:showSorterTooltip='false' :showSorterTooltip='false'
@@ -132,13 +140,13 @@
@click="setAagree(record)" @click="setAagree(record)"
style="margin-right: 2rem;" style="margin-right: 2rem;"
> >
Edit {{ $t('adminSeAllUser.Edit') }}
</div> </div>
<div <div
class="operate_item" class="operate_item"
@click="deleteAagree(record)" @click="deleteAagree(record)"
> >
Delete {{ $t('adminSeAllUser.Delete') }}
</div> </div>
<!-- <div <!-- <div
class="operate_item" class="operate_item"
@@ -169,18 +177,31 @@ import { Https } from "@/tool/https";
import { Modal,message } from 'ant-design-vue'; import { Modal,message } from 'ant-design-vue';
import { ExclamationCircleOutlined } from '@ant-design/icons-vue'; import { ExclamationCircleOutlined } from '@ant-design/icons-vue';
import allUserPoerationsVue from "./addAllUser.vue"; import allUserPoerationsVue from "./addAllUser.vue";
import { useI18n } from 'vue-i18n'
export default defineComponent({ export default defineComponent({
components: {allUserPoerationsVue,}, components: {allUserPoerationsVue,},
setup() { setup() {
const store:any = useStore() const store:any = useStore()
const selectedRowKeys = ref([]) as any;
const onSelectChange = (changableRowKeys: string[]) => {
selectedRowKeys.value = changableRowKeys;
};
let filter: any = reactive({ let filter: any = reactive({
dataList: [], dataList: [],
tableLoading: false, tableLoading: false,
allUserList: computed(()=>{ allUserList: computed(()=>{
return store.state.adminPage.allUserList return store.state.adminPage.allUserList
}), }),
allCountry:[] allCountry:[],
rowSelection:computed(() => {
return {
selectedRowKeys: unref(selectedRowKeys),
onChange: onSelectChange,
}
})
}); });
const {t} = useI18n()
let filterData: any = reactive({ let filterData: any = reactive({
rangePickerValue: [], rangePickerValue: [],
currentPage: 1, currentPage: 1,
@@ -196,37 +217,12 @@ export default defineComponent({
orderBy:'', orderBy:'',
userName: "", userName: "",
}); });
let state: any = ref([
{
label: "all",
value: "",
},
{
label:'visitor',
value:'0',
},
{
label:'yearly',
value:'1',
},
{
label:'monthly',
value:'2',
},
{
label:'trial',
value:'3',
},
{
label: "userInEvent",
value: "4",
},
]);
let renameData: any = ref({}); //修改名字选中的数据 let renameData: any = ref({}); //修改名字选中的数据
const columns: any = computed(() => { const columns: any = computed(() => {
return [ return [
{ {
title: "User Id", title: t("adminSeAllUser.UserId"),
align: "center", align: "center",
dataIndex: "id", dataIndex: "id",
key: "id", key: "id",
@@ -235,7 +231,7 @@ export default defineComponent({
sorter: true, sorter: true,
}, },
{ {
title: "Email", title: t("adminSeAllUser.Email"),
align: "center", align: "center",
dataIndex: "userEmail", dataIndex: "userEmail",
key: "userEmail", key: "userEmail",
@@ -243,7 +239,7 @@ export default defineComponent({
ellipsis:true ellipsis:true
}, },
{ {
title: "User Name", title: t("adminSeAllUser.UserName"),
align: "center", align: "center",
dataIndex: "userName", dataIndex: "userName",
key: "userName", key: "userName",
@@ -258,7 +254,7 @@ export default defineComponent({
// }, // },
}, },
{ {
title: "language", title: t("adminSeAllUser.language"),
align: "center", align: "center",
dataIndex: "language", dataIndex: "language",
key: "language", key: "language",
@@ -266,7 +262,7 @@ export default defineComponent({
ellipsis:true, ellipsis:true,
}, },
{ {
title: "Create Date", title: t("adminSeAllUser.CreateDate"),
align: "center", align: "center",
dataIndex: "createDate", dataIndex: "createDate",
key: "createDate", key: "createDate",
@@ -274,19 +270,19 @@ export default defineComponent({
sorter: true, sorter: true,
}, },
{ {
title: "Credits", title: t("adminSeAllUser.Credits"),
align: "center", align: "center",
// width: 150, // width: 150,
// minWidth: 100, // minWidth: 100,
// maxWidth: 200, // maxWidth: 200,
// resizable: true, // resizable: true,
dataIndex: "creditsUsageLimit", dataIndex: "credits",
key: "credits", key: "credits",
width:100, width:100,
sorter: true, sorter: true,
}, },
{ {
title: "Credits Usage", title: t("adminSeAllUser.CreditsUsage"),
align: "center", align: "center",
dataIndex: "creditsUsage", dataIndex: "creditsUsage",
key: "creditsUsage", key: "creditsUsage",
@@ -294,7 +290,7 @@ export default defineComponent({
sorter: true, sorter: true,
}, },
{ {
title: "Credits Usage Limit", title: t("adminSeAllUser.CreditsUsageLimit"),
align: "center", align: "center",
dataIndex: "creditsUsageLimit", dataIndex: "creditsUsageLimit",
key: "creditsUsageLimit", key: "creditsUsageLimit",
@@ -302,7 +298,7 @@ export default defineComponent({
sorter: true, sorter: true,
}, },
{ {
title: "Operations", title: t("adminSeAllUser.Operations"),
key: "operation", key: "operation",
width:120, width:120,
align: "center", align: "center",
@@ -418,11 +414,11 @@ export default defineComponent({
return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0; return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0;
}; };
let addhHistoryList = () => { let addhHistoryList = () => {
allUserPoerationsVue.value.init('Add','') allUserPoerationsVue.value.init({value:'Add',label:t('adminSeAllUser.add')},'')
}; };
let allUserPoerationsVue = ref() let allUserPoerationsVue = ref()
let setAagree = (data:any) =>{ let setAagree = (data:any) =>{
allUserPoerationsVue.value.init('Edit',data) allUserPoerationsVue.value.init({value:'Edit',label:t('adminSeAllUser.Edit')},data)
} }
const downloadTemplate = ()=>{ const downloadTemplate = ()=>{
Https.axiosGet(Https.httpUrls.subAccountImportExcelDownload,{responseType: 'blob',env:{binary:true}}).then((rv:any)=>{ Https.axiosGet(Https.httpUrls.subAccountImportExcelDownload,{responseType: 'blob',env:{binary:true}}).then((rv:any)=>{
@@ -436,6 +432,18 @@ export default defineComponent({
URL.revokeObjectURL(link.href); URL.revokeObjectURL(link.href);
}) })
} }
const ExportAccountData = ()=>{
Https.axiosGet(Https.httpUrls.exportAccountsToExcel,{headers:{responseType: 'blob',},env:{binary:true,binaryType:'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet;charset=UTF-8'}}).then((rv:any)=>{
const link = document.createElement('a');
link.href = rv.url;
link.download = 'file.xlsx'; // 设置正确的文件扩展名
document.body.appendChild(link);
link.click();
document.body.removeChild(link);
// 释放 URL 对象
URL.revokeObjectURL(link.href);
})
}
const uploadTemplate = ()=>{ const uploadTemplate = ()=>{
const fileInput = document.createElement('input'); const fileInput = document.createElement('input');
fileInput.type = 'file'; fileInput.type = 'file';
@@ -473,6 +481,18 @@ export default defineComponent({
}); });
}) })
} }
const deleteList = async ()=>{
console.log(selectedRowKeys.value)
if(selectedRowKeys.value.length == 0)return
let boolean:any = await confirmDelete()
if(!boolean){
return
}
Https.axiosPost(Https.httpUrls.deleteSubAccount,{deleteIdList:selectedRowKeys.value})
.then((rv:any)=>{
gettrialList();
})
}
const deleteAagree = async (event:any)=>{ const deleteAagree = async (event:any)=>{
let boolean:any = await confirmDelete() let boolean:any = await confirmDelete()
if(!boolean){ if(!boolean){
@@ -496,7 +516,6 @@ export default defineComponent({
return { return {
...toRefs(filter), ...toRefs(filter),
...toRefs(filterData), ...toRefs(filterData),
state,
columns, columns,
renameData, renameData,
changePage, changePage,
@@ -508,7 +527,9 @@ export default defineComponent({
allUserPoerationsVue, allUserPoerationsVue,
setAagree, setAagree,
downloadTemplate, downloadTemplate,
ExportAccountData,
uploadTemplate, uploadTemplate,
deleteList,
deleteAagree, deleteAagree,
}; };
}, },
@@ -530,13 +551,17 @@ export default defineComponent({
<style lang="less" scoped> <style lang="less" scoped>
.admin_page .admin_table_search .admin_state { .admin_page .admin_table_search .admin_state {
display: flex; display: flex;
width: 75%; width: 70%;
flex-wrap: wrap; flex-wrap: wrap;
align-content: flex-start; align-content: flex-start;
} }
.admin_page .admin_table_search .admin_search { .admin_page .admin_table_search .admin_search {
display: flex; display: flex;
flex-wrap: wrap; flex-wrap: wrap;
width: 25%; width: 30%;
> .admin_search_item{
height: 4rem;
font-size: 1.6rem;
}
} }
</style> </style>

View File

@@ -4,7 +4,7 @@
<div class="admin_state"> <div class="admin_state">
<div class="admin_state_item"> <div class="admin_state_item">
<span>Start Date:</span> <span>{{ $t('adminSeDesignDetail.StartDate') }}:</span>
<a-range-picker <a-range-picker
style="width:250px" style="width:250px"
class="range_picker" class="range_picker"
@@ -23,11 +23,11 @@
</a-range-picker> </a-range-picker>
</div> </div>
<div class="admin_state_item"> <div class="admin_state_item">
<span>Start Time:</span> <span>{{ $t('adminSeDesignDetail.StartTime') }}:</span>
<a-time-range-picker style="width:250px" class="range_picker" valueFormat="HH:mm:ss" v-model:value="rangeTimeValue" /> <a-time-range-picker style="width:250px" class="range_picker" valueFormat="HH:mm:ss" v-model:value="rangeTimeValue" />
</div> </div>
<div class="admin_state_item"> <div class="admin_state_item">
<span>Email:</span> <span>{{ $t('adminSeDesignDetail.Email') }}:</span>
<input <input
v-model="email" v-model="email"
placeholder="Please enter email" placeholder="Please enter email"
@@ -37,7 +37,7 @@
/> />
</div> </div>
<div class="admin_state_item"> <div class="admin_state_item">
<span>User Name:</span> <span>{{ $t('adminSeDesignDetail.UserName') }}:</span>
<a-select <a-select
v-model:value="ids" v-model:value="ids"
mode="multiple" mode="multiple"
@@ -79,6 +79,7 @@
import { defineComponent, ref, createVNode, computed } from "vue"; import { defineComponent, ref, createVNode, computed } from "vue";
import { useStore } from "vuex"; import { useStore } from "vuex";
import { Https } from "@/tool/https"; import { Https } from "@/tool/https";
import { useI18n } from 'vue-i18n'
export default defineComponent({ export default defineComponent({
components: { components: {
}, },
@@ -87,10 +88,11 @@ export default defineComponent({
let rangePickerValue: any = ref([]); let rangePickerValue: any = ref([]);
let rangeTimeValue: any = ref([]); let rangeTimeValue: any = ref([]);
let renameData: any = ref({}); //修改名字选中的数据 let renameData: any = ref({}); //修改名字选中的数据
const {t} = useI18n()
const columns: any = computed(() => { const columns: any = computed(() => {
return [ return [
{ {
title: 'Email', title: t('adminSeDesignDetail.Email'),
align: "center", align: "center",
dataIndex: "userEmail", dataIndex: "userEmail",
key: "userEmail", key: "userEmail",
@@ -98,7 +100,7 @@ export default defineComponent({
fixed: "left", fixed: "left",
}, },
{ {
title: 'User Id', title: t('adminSeDesignDetail.UserId'),
align: "center", align: "center",
ellipsis: true, ellipsis: true,
dataIndex: "accountId", dataIndex: "accountId",
@@ -106,7 +108,7 @@ export default defineComponent({
width:100, width:100,
}, },
{ {
title: 'User Name', title: t('adminSeDesignDetail.UserName'),
align: "center", align: "center",
ellipsis: 200, ellipsis: 200,
dataIndex: "userName", dataIndex: "userName",
@@ -121,7 +123,7 @@ export default defineComponent({
// }, // },
}, },
{ {
title: 'Frequency', title: t('adminSeDesignDetail.Frequency'),
align: "center", align: "center",
ellipsis: true, ellipsis: true,
dataIndex: "designTimes", dataIndex: "designTimes",
@@ -129,7 +131,7 @@ export default defineComponent({
width:100, width:100,
}, },
{ {
title: 'Create Time', title: t('adminSeDesignDetail.CreateTime'),
align: "center", align: "center",
ellipsis: true, ellipsis: true,
// width: 150, // width: 150,
@@ -141,7 +143,7 @@ export default defineComponent({
width:200, width:200,
}, },
{ {
title: 'Credits', title: t('adminSeDesignDetail.Credits'),
align: "center", align: "center",
ellipsis: true, ellipsis: true,
// width: 150, // width: 150,

View File

@@ -137,14 +137,14 @@ export default defineComponent({
return str; return str;
}, },
}, },
{ // {
title: 'Frequency', // title: 'Frequency',
align: "center", // align: "center",
ellipsis: true, // ellipsis: true,
dataIndex: "designTimes", // dataIndex: "designTimes",
key: "designTimes", // key: "designTimes",
width:100, // width:100,
}, // },
{ {
title: 'Country', title: 'Country',
align: "center", align: "center",
@@ -177,18 +177,14 @@ export default defineComponent({
key: "givenName", key: "givenName",
width:100, width:100,
}, },
{ // {
title: 'Create Time', // title: 'Create Time',
align: "center", // align: "center",
ellipsis: true, // ellipsis: true,
// width: 150, // dataIndex: "createTime",
// minWidth: 100, // key: "createTime",
// maxWidth: 200, // width:200,
// resizable: true, // },
dataIndex: "createTime",
key: "createTime",
width:200,
},
{ {
title: 'Credits', title: 'Credits',
align: "center", align: "center",

View File

@@ -64,8 +64,9 @@
refuse refuse
</div> </div>
</div> </div>
<div v-else-if="column?.Operations"> <div v-else-if="column?.Operations" class="operate_list">
{{ record.status }} <div class="operate_item">{{ record.status }}</div>
<div class="operate_item" @click="editAffiliate(record)">Edit</div>
</div> </div>
<div v-else-if="column?.openType" @click="openDetail(record,column?.openType)"> <div v-else-if="column?.openType" @click="openDetail(record,column?.openType)">
{{ text }} HDK {{ text }} HDK
@@ -74,6 +75,7 @@
</a-table> </a-table>
</div> </div>
<itemAffiliateDetail ref="itemAffiliateDetail"></itemAffiliateDetail> <itemAffiliateDetail ref="itemAffiliateDetail"></itemAffiliateDetail>
<editAudit ref="editAudit"></editAudit>
</div> </div>
</template> </template>
<script lang="ts"> <script lang="ts">
@@ -81,9 +83,10 @@ import { defineComponent, ref, createVNode, computed } from "vue";
import { Https } from "@/tool/https"; import { Https } from "@/tool/https";
import { Modal, message } from "ant-design-vue"; import { Modal, message } from "ant-design-vue";
import itemAffiliateDetail from "./itemAffiliateDetail.vue"; import itemAffiliateDetail from "./itemAffiliateDetail.vue";
import editAudit from "./editAudit.vue";
export default defineComponent({ export default defineComponent({
components: { components: {
itemAffiliateDetail, itemAffiliateDetail,editAudit
}, },
setup() { setup() {
let renameData: any = ref({}); //修改名字选中的数据 let renameData: any = ref({}); //修改名字选中的数据
@@ -199,6 +202,7 @@ export default defineComponent({
}, },
]) ])
const itemAffiliateDetail = ref() const itemAffiliateDetail = ref()
const editAudit = ref()
let collectionList: any = ref([]); let collectionList: any = ref([]);
let status: any = ref(0); let status: any = ref(0);
const openDetail = (value:any,openType:string)=>{ const openDetail = (value:any,openType:string)=>{
@@ -208,6 +212,9 @@ export default defineComponent({
} }
itemAffiliateDetail.value.init(data) itemAffiliateDetail.value.init(data)
} }
const editAffiliate = (item:any)=>[
editAudit.value.init(item)
]
return { return {
columns, columns,
collectionList, collectionList,
@@ -217,6 +224,8 @@ export default defineComponent({
itemAffiliateDetail, itemAffiliateDetail,
state, state,
openDetail, openDetail,
editAudit,
editAffiliate,
}; };
}, },
data() { data() {

View File

@@ -0,0 +1,182 @@
<template>
<div class="editAudit" ref="editAudit"></div>
<a-modal
class="editAudit_modal generalModel"
v-model:visible="operationsModal"
:footer="null"
:get-container="() => $refs.editAudit"
width="50%"
height="55rem"
:maskClosable="false"
:centered="true"
:closable="false"
:mask="true"
wrapClassName="#app"
:keyboard="false"
>
<div class="generalModel_btn">
<div class="generalModel_closeIcon" @click.stop="cancelDsign">
<svg
width="100%" height="100%"
viewBox="0 0 46 46"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<circle cx="23" cy="23" r="23" fill="black" fill-opacity="0.3" />
<rect
x="32.5063"
y="12"
width="3"
height="29"
rx="1.5"
transform="rotate(45 32.5063 12)"
fill="white"
/>
<rect
x="34.6274"
y="32.5059"
width="3"
height="29"
rx="1.5"
transform="rotate(135 34.6274 32.5059)"
fill="white"
/>
</svg>
</div>
</div>
<div class="modal_title_text">
<div>{{ title }} </div>
</div>
<div class="allUserPoeration_center admin_page">
<div class="admin_state_item">
<span>Commission: <span>*</span></span>
<input
v-model="commission"
placeholder="Please enter Commission"
type="text"
style="width: 250px"
/>
</div>
</div>
<div class="allUserPoeration_btn admin_page">
<div class="admin_search_item" @click="cancelDsign">Close</div>
<div class="admin_search_item" @click="setOk">OK</div>
</div>
</a-modal>
<div class="mark_loading" v-show="loadingShow">
<a-spin size="large" />
</div>
</template>
<script>
import {
defineComponent,
ref,
reactive,
watch,
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 md5 from "md5";
export default defineComponent({
components: {},
emits: ["searchHistoryList"],
props:{
},
setup(props, { emit }) {
let operations = reactive({
operationsModal: false,
loadingShow: false,
title: "",
});
let operationsData = reactive({
id: "",
commission: "",
});
let init = (data) => {
let funStr = 'Edit'
console.log(data)
operations.operationsModal = true;
operations.title = funStr;
if (funStr == "Edit") {
operationsData.id = data.id;
operationsData.commission = data.commissionPercent;
}
};
let setEditData = () => {
return {
id: operationsData.id,
commission: operationsData.commission,
};
};
let cancelDsign = () => {
operationsData.id = "";
operationsData.commission = "";
operations.operationsModal = false;
};
let setOk = () => {
let data;
data = setEditData();
if (
!data.commission
)
return message.warning("Please check the input box marked with *");
Https.axiosGet(Https.httpUrls.updateCommission, {params:data}).then(
(rv) => {
if (rv) {
cancelDsign();
emit("searchHistoryList");
}
}
);
};
return {
...toRefs(operations),
...toRefs(operationsData),
cancelDsign,
init,
setOk,
};
},
data() {
return {};
},
mounted() {},
methods: {},
});
</script>
<style lang="less" scoped>
:deep(.editAudit_modal) {
.ant-modal-body {
display: flex;
flex-direction: column;
}
}
</style>
<style lang="less" scoped>
.editAudit_modal {
.closeIcon {
z-index: 2;
}
.allUserPoeration_btn {
display: flex;
flex-direction: row;
height: auto;
justify-content: flex-end;
padding: 1rem 0;
.admin_search_item {
margin-bottom: 0;
}
}
.allUserPoeration_center {
flex: 1;
overflow-y: auto;
flex-direction: row;
flex-wrap: wrap;
}
}
</style>

View File

@@ -50,15 +50,18 @@
<div class="allUserPoeration_center admin_page"> <div class="allUserPoeration_center admin_page">
<div class="admin_state_item"> <div class="admin_state_item">
<span>Id: <span>*</span></span> <span>Id: <span>*</span></span>
<!-- input不可编辑 -->
<input <input
v-model="id" v-model="id"
placeholder="Please enter user name" placeholder="Please enter user Id"
disabled
type="text" type="text"
style="width: 250px" style="width: 250px"
/> />
</div> </div>
<div class="admin_state_item"> <div class="admin_state_item">
<span>Amount: <span>*</span></span> <span>Amount: </span>
<input <input
v-model="amount" v-model="amount"
placeholder="Please enter email" placeholder="Please enter email"
@@ -67,7 +70,7 @@
/> />
</div> </div>
<div class="admin_state_item"> <div class="admin_state_item">
<span>Status: <span>*</span></span> <span>Status: </span>
<a-select <a-select
v-model:value="selectStatus" v-model:value="selectStatus"
size="large" size="large"
@@ -159,11 +162,9 @@ export default defineComponent({
let data; let data;
data = setEditData(); data = setEditData();
if ( if (
!data.id || !data.id
!data.amount
) )
return message.warning("Please check the input box marked with *"); return message.warning("Please check the input box marked with *");
console.log(123)
Https.axiosPost(Https.httpUrls.editReferral, data).then( Https.axiosPost(Https.httpUrls.editReferral, data).then(
(rv) => { (rv) => {
if (rv) { if (rv) {

View File

@@ -109,7 +109,7 @@
</template> </template>
</a-table> </a-table>
</div> </div>
<editReferral ref="editReferral" :stateList="[...state].splice(1,state.length-1)" @searchHistoryList="searchHistoryList"></editReferral> <editReferral ref="editReferral" :stateList="[...state].filter((_, index) => ![0,3].includes(index))" @searchHistoryList="searchHistoryList"></editReferral>
</div> </div>
</template> </template>
<script lang="ts"> <script lang="ts">
@@ -175,8 +175,8 @@ export default defineComponent({
value:'Pending', value:'Pending',
}, },
{ {
label:'Access', label:'Accept',
value:'Access', value:'Accept',
}, },
{ {
label: "Rejected", label: "Rejected",
@@ -200,7 +200,12 @@ export default defineComponent({
dataIndex: "commission", dataIndex: "commission",
key: "commission", key: "commission",
width:200, width:200,
ellipsis:true ellipsis:true,
customRender: (record: any) => {
return `${record.text}%`
},
}, },
{ {
title: "User Name", title: "User Name",

View File

@@ -212,6 +212,10 @@ export default defineComponent({
{ {
label: "userInEvent", label: "userInEvent",
value: "4", value: "4",
},
{
label: "Edu Admin",
value: "7",
}, },
]); ]);
let renameData: any = ref({}); //修改名字选中的数据 let renameData: any = ref({}); //修改名字选中的数据

View File

@@ -91,7 +91,6 @@
style="width: 250px" style="width: 250px"
/> />
</div> </div>
<div class="admin_state_item"> <div class="admin_state_item">
<span>Country:</span> <span>Country:</span>
<input <input
@@ -103,7 +102,28 @@
style="width: 250px" style="width: 250px"
/> />
</div> </div>
<div class="admin_state_item">
<span>Organization Name:</span>
<input
:readonly="title != 'Add'"
:class="{active:title != 'Add'}"
v-model="organizationName"
placeholder="Please enter Organization Name"
type="text"
style="width: 250px"
/>
</div>
<div class="admin_state_item">
<span>Sub Account Num:</span>
<input
:readonly="title != 'Add'"
:class="{active:title != 'Add'}"
v-model="subAccountNum"
placeholder="Please enter Sub Account Num"
type="number"
style="width: 250px"
/>
</div>
</div> </div>
<div class="allUserPoeration_btn admin_page"> <div class="allUserPoeration_btn admin_page">
<div class="admin_search_item" @click="cancelDsign"> <div class="admin_search_item" @click="cancelDsign">
@@ -144,6 +164,8 @@ export default defineComponent({
systemUser:'', systemUser:'',
credits:'', credits:'',
country:'', country:'',
organizationName:'',
subAccountNum:0,
}) })
let state = ref([ let state = ref([
{ {
@@ -169,6 +191,8 @@ export default defineComponent({
operations.title = funStr operations.title = funStr
if(funStr == 'Add') operations.operationsEdit = false if(funStr == 'Add') operations.operationsEdit = false
if(funStr == 'Edit'){ if(funStr == 'Edit'){
operationsData.organizationName = data.organizationName
operationsData.subAccountNum = data.subAccountNum?data.subAccountNum:0
let startTime = data.validStartTime?formatTime(data.validStartTime / 1000,"YYYY-MM-DDThh:mm:ss"):'' let startTime = data.validStartTime?formatTime(data.validStartTime / 1000,"YYYY-MM-DDThh:mm:ss"):''
let endTime = data.validEndTime?formatTime(data.validEndTime / 1000,"YYYY-MM-DDThh:mm:ss"):'' let endTime = data.validEndTime?formatTime(data.validEndTime / 1000,"YYYY-MM-DDThh:mm:ss"):''
operationsData.accountId=data.id operationsData.accountId=data.id
@@ -207,7 +231,9 @@ export default defineComponent({
"userEmail": operationsData.userEmail, "userEmail": operationsData.userEmail,
"userName": operationsData.userName, "userName": operationsData.userName,
"validEndTime": setTime(operationsData.validEndTime), "validEndTime": setTime(operationsData.validEndTime),
"validStartTime": setTime(operationsData.validStartTime) "validStartTime": setTime(operationsData.validStartTime),
"organizationName": operationsData.organizationName?operationsData.organizationName:null,
"subAccountNum": operationsData.subAccountNum,
} }
} }
let setEditData = ()=>{ let setEditData = ()=>{
@@ -293,6 +319,11 @@ export default defineComponent({
.closeIcon { .closeIcon {
z-index: 2; z-index: 2;
} }
> .admin_state_item{
> span{
width: 15rem;
}
}
.allUserPoeration_btn{ .allUserPoeration_btn{
display: flex; display: flex;
flex-direction: row; flex-direction: row;

View File

@@ -20,6 +20,8 @@ import { SelectionManager } from "./managers/selection/SelectionManager";
import { RedGreenModeManager } from "./managers/RedGreenModeManager"; import { RedGreenModeManager } from "./managers/RedGreenModeManager";
import texturePresetManager from "./managers/brushes/TexturePresetManager"; import texturePresetManager from "./managers/brushes/TexturePresetManager";
import { BrushStore } from "./store/BrushStore"; import { BrushStore } from "./store/BrushStore";
import cuowuImg from '@/assets/images/homePage/cuowu.svg'
// import { MinimapManager } from "./managers/minimap/MinimapManager"; // import { MinimapManager } from "./managers/minimap/MinimapManager";
@@ -33,7 +35,7 @@ import LiquifyPanel from "./components/LiquifyPanel.vue"; // 引入液化编辑
import SelectionPanel from "./components/SelectionPanel.vue"; // 引入选区面板 import SelectionPanel from "./components/SelectionPanel.vue"; // 引入选区面板
import { LayerType, OperationType } from "./utils/layerHelper.js"; import { LayerType, OperationType } from "./utils/layerHelper.js";
import { ToolManager } from "./managers/toolManager.js"; import { ToolManager } from "./managers/toolManager.js";
// import { fabric } from "fabric-with-all"; import { fabric } from "fabric-with-all";
import { import {
uploadImageAndCreateLayer, uploadImageAndCreateLayer,
loadImageUrlToLayer, loadImageUrlToLayer,
@@ -402,6 +404,11 @@ onMounted(async () => {
canvasManagerLoaded.value = true; canvasManagerLoaded.value = true;
// 添加删除按钮
// if(!fabric.Object.prototype.controls.deleteControl)addRemoveBtn(removeLayer)
addRemoveBtn(removeLayer)
// 触发组件初始化事件 // 触发组件初始化事件
nextTick(() => { nextTick(() => {
// 确保所有依赖都已加载完成 // 确保所有依赖都已加载完成
@@ -490,6 +497,7 @@ onBeforeUnmount(() => {
liquifyManager = null; liquifyManager = null;
selectionManager = null; selectionManager = null;
redGreenModeManager = null; redGreenModeManager = null;
// fabric.Object.prototype.controls.deleteControl = undefined;
// 移除window resize事件监听 // 移除window resize事件监听
// window.removeEventListener("resize", handleWindowResize); // window.removeEventListener("resize", handleWindowResize);
@@ -604,6 +612,37 @@ function moveLayerDown(layerId) {
layerManager.moveLayer(layerId, "down"); layerManager.moveLayer(layerId, "down");
} }
function addRemoveBtn(fun){//添加删除按钮
const deleteIcon = cuowuImg
// 创建删除图片元素
let deleteImg = document.createElement('img')
deleteImg.src = deleteIcon
function renderIcon(icon) {
return function (ctx, left, top, styleOverride, fabricObject) {
var size = this.cornerSize;
ctx.save();
ctx.translate(left, top);
ctx.rotate(fabric.util.degreesToRadians(fabricObject.angle));
ctx.drawImage(icon, -size/3, -size/3, size/1.5, size/1.5);
ctx.restore();
}
}
fabric.Object.prototype.controls.deleteControl = new fabric.Control({
x: 0.5,
y: -0.5,
offsetY: -16,
offsetX: 16,
cursorStyle: 'pointer',
mouseUpHandler:deleteFun,
render: renderIcon(deleteImg),
cornerSize: 24
})
}
function deleteFun(){
removeLayer(layerManager.activeLayerId.value)
}
function removeLayer(layerId) { function removeLayer(layerId) {
// Check if this is the last layer - prevent deletion // Check if this is the last layer - prevent deletion
if (layers.value.length <= 2) { if (layers.value.length <= 2) {

View File

@@ -141,7 +141,7 @@ const allImages = computed(() => {
// 计算属性:根据选择的分类过滤图片 // 计算属性:根据选择的分类过滤图片
const filteredImages = computed(() => { const filteredImages = computed(() => {
if (selectedCategory.value === "全部") { if (selectedCategory.value === "All" || selectedCategory.value === "全部") {
return allImages.value; return allImages.value;
} }

View File

@@ -280,6 +280,14 @@ export default defineComponent({
if(detailDom.detailRight?.privewDetail)await (detailDom.detailRight as any).privewDetail() if(detailDom.detailRight?.privewDetail)await (detailDom.detailRight as any).privewDetail()
let gradient = null let gradient = null
let newData = list[i]?.newDetail?.[detailData.currentDetailType] let newData = list[i]?.newDetail?.[detailData.currentDetailType]
// newData[0].location=[
// -233.13985,
// 406.90964
// ]
// newData[0].scale=[
// 0.5,
// 0.35822305
// ]
let isCurrent = list[i].id == detailData?.selectDetail?.id let isCurrent = list[i].id == detailData?.selectDetail?.id
let color = (detailData.currentDetailType == 'color' && isCurrent && newData?.rgba?.r)?(newData?.rgba?.r?`${newData.rgba.r} ${newData.rgba.g} ${newData.rgba.b}`:''):(list[i].color?.rgba?.r?`${list[i].color.rgba.r} ${list[i].color.rgba.g} ${list[i].color.rgba.b}`:'') let color = (detailData.currentDetailType == 'color' && isCurrent && newData?.rgba?.r)?(newData?.rgba?.r?`${newData.rgba.r} ${newData.rgba.g} ${newData.rgba.b}`:''):(list[i].color?.rgba?.r?`${list[i].color.rgba.r} ${list[i].color.rgba.g} ${list[i].color.rgba.b}`:'')
if(detailData.currentDetailType == 'sketch' && newData){ if(detailData.currentDetailType == 'sketch' && newData){
@@ -293,12 +301,20 @@ export default defineComponent({
maskMinioUrl:list[i]?.maskMinioUrl, maskMinioUrl:list[i]?.maskMinioUrl,
// maskUrl:'', // maskUrl:'',
maskUrl:list[i].maskUrl, maskUrl:list[i].maskUrl,
// offset:[
// -233.13985,
// 406.90964
// ],
offset, offset,
partialDesign:detailData.isEditPattern.value?list[i].partialDesign:{}, partialDesign:detailData.isEditPattern.value?list[i].partialDesign:{},
path:(newData && detailData.currentDetailType == 'sketch' && isCurrent)?newData.minIOPath:list[i].minIOPath, path:(newData && detailData.currentDetailType == 'sketch' && isCurrent)?newData.minIOPath:list[i].minIOPath,
printObject:(newData && detailData.currentDetailType == 'print' && isCurrent)?{prints:newData}:list[i].printObject?list[i].printObject:{prints:[]}, printObject:(newData && detailData.currentDetailType == 'print' && isCurrent)?{prints:newData}:list[i].printObject?list[i].printObject:{prints:[]},
priority, priority,
scale, // scale:[
// 0.5,
// 0.35822305
// ],
scale:[scale[0]?scale[0]:1,scale[1]?scale[1]:1],
type:(newData && detailData.currentDetailType == 'sketch' && isCurrent)?newData.level2Type || newData.categoryValue:list[i].type, type:(newData && detailData.currentDetailType == 'sketch' && isCurrent)?newData.level2Type || newData.categoryValue:list[i].type,
sketchString:list[i].sketchString?list[i].sketchString:'', sketchString:list[i].sketchString?list[i].sketchString:'',
trims:(newData && detailData.currentDetailType == 'element' && isCurrent)?{prints:newData}:list[i].trims?list[i].trims:{prints:[]}, trims:(newData && detailData.currentDetailType == 'element' && isCurrent)?{prints:newData}:list[i].trims?list[i].trims:{prints:[]},

View File

@@ -10,7 +10,7 @@
<editCanvas v-if="canvasLoad" :config="canvasConfig" <editCanvas v-if="canvasLoad" :config="canvasConfig"
@canvasInit="canvasInit" @canvasInit="canvasInit"
@changeCanvas="changeCanvas" @changeCanvas="changeCanvas"
:clothingImageUrl="selectDetail.undividedLayer" :clothingImageUrl="selectDetail.undividedLayer || selectDetail.path"
showFixedLayer showFixedLayer
:canvasJSON="canvasJSON" :canvasJSON="canvasJSON"
:clothing-image-opts="{ :clothing-image-opts="{
@@ -142,7 +142,7 @@ export default defineComponent({
}else{ }else{
if(detailData.currentView === 'redGreenExample'){ if(detailData.currentView === 'redGreenExample'){
nextTick(()=>{ nextTick(()=>{
setCanvas(detailData.selectDetail.undividedLayer).then(()=>{ setCanvas(detailData.selectDetail.undividedLayer || detailData.selectDetail.path).then(()=>{
detailData.canvasLoad = true detailData.canvasLoad = true
}) })
}) })
@@ -158,7 +158,7 @@ export default defineComponent({
const privewDetail = async (oldSelectDetail = detailData.selectDetail)=>{ const privewDetail = async (oldSelectDetail = detailData.selectDetail)=>{
if(!detailDom.editCanvas)return if(!detailDom.editCanvas)return
return new Promise((res,reject)=>{ return new Promise((res,reject)=>{
detailDom.editCanvas.exportImage({isContainBg:false,isContainFixed:true}).then((rv)=>{ detailDom.editCanvas.exportImage({isContainBg:false,isContainFixed:false}).then((rv)=>{
if(oldSelectDetail?.partialDesign)oldSelectDetail.partialDesign.partialDesignBase64 = rv if(oldSelectDetail?.partialDesign)oldSelectDetail.partialDesign.partialDesignBase64 = rv
res('') res('')
}) })
@@ -271,9 +271,8 @@ export default defineComponent({
}) })
onMounted(()=>{ onMounted(()=>{
nextTick(async ()=>{ nextTick(async ()=>{
console.log(JSON.parse(JSON.stringify(detailData.selectDetail)))
detailData.isShowMark = true
if(detailData.selectDetail.canvasId){ if(detailData.selectDetail.canvasId){
detailData.isShowMark = true
await new Promise((resolve, reject) => { await new Promise((resolve, reject) => {
let value = { let value = {
module:'designItemDetail', module:'designItemDetail',
@@ -289,8 +288,7 @@ export default defineComponent({
}); });
}) })
} }
setCanvas(detailData.selectDetail.undividedLayer || detailData.selectDetail.path).then(()=>{
setCanvas(detailData.selectDetail.undividedLayer).then(()=>{
detailData.canvasLoad = true detailData.canvasLoad = true
}) })
}) })

View File

@@ -69,6 +69,7 @@
<img crossOrigin="anonymous" :src="item?.path" :style="{transform:`rotateZ(${item.pattern?.transform?.rotateZ}deg)`}" class="designOpenrtion_imgItme" draggable="false"> <img crossOrigin="anonymous" :src="item?.path" :style="{transform:`rotateZ(${item.pattern?.transform?.rotateZ}deg)`}" class="designOpenrtion_imgItme" draggable="false">
</div> </div>
</div> </div>
<!-- <img :src="selectDetail.path" alt="" class="designOpenrtion_sketch" ref="sketchImg"> -->
<img :src="selectDetail?.undividedLayer?selectDetail.undividedLayer:selectDetail.path" alt="" class="designOpenrtion_sketch" ref="sketchImg"> <img :src="selectDetail?.undividedLayer?selectDetail.undividedLayer:selectDetail.path" alt="" class="designOpenrtion_sketch" ref="sketchImg">
<div class="designOpenrtion_btn"> <div class="designOpenrtion_btn">
<ul v-if="overallSingle" v-for="item,index in printStyleList[type][stateOverallSingle]" :key="item" :class="{active:item?.pattern.designOpenrtionBtn?item?.pattern.designOpenrtionBtn:false}" class="designOpenrtion_Mousingle" :style="item?.pattern.style" @mousedown.stop="itemMoveMousedown(index,getMousePosition($event,false))" @touchstart.passive="itemMoveMousedown(index,getMousePosition($event,true))"> <ul v-if="overallSingle" v-for="item,index in printStyleList[type][stateOverallSingle]" :key="item" :class="{active:item?.pattern.designOpenrtionBtn?item?.pattern.designOpenrtionBtn:false}" class="designOpenrtion_Mousingle" :style="item?.pattern.style" @mousedown.stop="itemMoveMousedown(index,getMousePosition($event,false))" @touchstart.passive="itemMoveMousedown(index,getMousePosition($event,true))">
@@ -357,10 +358,26 @@ export default defineComponent({
editPrintElementData.overallSingle = state editPrintElementData.overallSingle = state
} }
} }
img.src = editPrintElementData.selectDetail.undividedLayer // undividedLayer
//计算宽高使用editPrintElementData.selectDetail.path
// img.src = editPrintElementData.selectDetail.path
img.src = editPrintElementData.selectDetail.undividedLayer?editPrintElementData.selectDetail.undividedLayer:editPrintElementData.selectDetail.path
}) })
} }
watch(()=>editPrintElementData.selectDetail?.id,(newVal)=>{ // watch(()=>editPrintElementData.selectDetail?.id,(newVal)=>{
// if(!newVal)return
// editPrintElementData.printStyleList[props.type] = {
// single:[],
// overall:[],
// }
// setPosition()
// },{immediate: true,})
watch(()=>editPrintElementData.currentPrintElement,(newVal)=>{
if(newVal){
addPrintELement(newVal)
}
})
watch(()=>((editPrintElementData.selectDetail?.undividedLayer || editPrintElementData.selectDetail?.id)),(newVal)=>{
if(!newVal)return if(!newVal)return
editPrintElementData.printStyleList[props.type] = { editPrintElementData.printStyleList[props.type] = {
single:[], single:[],
@@ -368,11 +385,6 @@ export default defineComponent({
} }
setPosition() setPosition()
},{immediate: true,}) },{immediate: true,})
watch(()=>editPrintElementData.currentPrintElement,(newVal)=>{
if(newVal){
addPrintELement(newVal)
}
})
//设置移动 //设置移动
const itemMoveMousedown = (index:number,event:any)=>{ const itemMoveMousedown = (index:number,event:any)=>{
if (event.target.tagName === 'IMG' || event.target.nodeName === 'IMG')return if (event.target.tagName === 'IMG' || event.target.nodeName === 'IMG')return

View File

@@ -375,6 +375,9 @@ export default defineComponent({
canvas.dispose(); canvas.dispose();
showPayOrder.value = false showPayOrder.value = false
} }
onBeforeUnmount(()=>{
fabric.Object.prototype.controls.deleteControl = null
})
return { return {
presentState, presentState,
showPayOrder, showPayOrder,

View File

@@ -156,7 +156,7 @@
:placeholder="$t('Renew.promotionCode')" :placeholder="$t('Renew.promotionCode')"
v-model="item.promotionData.code" v-model="item.promotionData.code"
/> />
<div style="cursor: pointer" @click="examine(item)"> <div style="cursor: pointer; background-color: #000; font-size: 1.2rem; color: #fff; padding: 0 .5rem;" @click="examine(item)">
{{ $t("Renew.use") }} {{ $t("Renew.use") }}
</div> </div>
</div> </div>
@@ -268,7 +268,7 @@
</template> </template>
<script lang="ts"> <script lang="ts">
import { defineComponent, computed, reactive, toRefs, onMounted } from "vue"; import { defineComponent, computed, reactive, toRefs, onMounted, onBeforeUnmount } from "vue";
import { message } from "ant-design-vue"; import { message } from "ant-design-vue";
import payMethod from "@/component/Pay/payMethod.vue"; import payMethod from "@/component/Pay/payMethod.vue";
import { useStore } from "vuex"; import { useStore } from "vuex";
@@ -297,6 +297,22 @@ export default defineComponent({
let renewData = reactive({ let renewData = reactive({
personage: [ personage: [
{ {
price: "100",
sellWell: true,
activity: false, //活动打折
type: {
value: "EcoMonth",
label: computed(()=>t("Renew.Monthly")),
},
PaymentType: "CreditCard",
promotionData: {
code: "",
error: "",
str: "",
price: "",
},
},
{
price: "500", price: "500",
sellWell: true, sellWell: true,
activity: false, //活动打折 activity: false, //活动打折
@@ -388,10 +404,11 @@ export default defineComponent({
}); });
const init = () => { const init = () => {
renew.renewModel = true; renew.renewModel = true;
renewData.current = renewData.personage[0]; renewData.current = renewData.personage[1];
}; };
const cancelDsign = () => { const cancelDsign = () => {
renew.renewModel = false; renew.renewModel = false;
store.dispatch('getLangType')
}; };
const setPaymentType = (str: any) => { const setPaymentType = (str: any) => {
renewData.current.PaymentType = str; renewData.current.PaymentType = str;
@@ -570,6 +587,8 @@ export default defineComponent({
color: #fff; color: #fff;
padding: 4rem 3.2rem; padding: 4rem 3.2rem;
position: relative; position: relative;
display: flex;
flex-direction: column;
> .video{ > .video{
position: absolute; position: absolute;
width: 100%; width: 100%;
@@ -598,6 +617,10 @@ export default defineComponent({
> .content { > .content {
flex-wrap: wrap; flex-wrap: wrap;
flex-direction: row; flex-direction: row;
flex: 1;
align-content: center;
align-items: center;
justify-content: center;
> .benefitsItem { > .benefitsItem {
display: flex; display: flex;
width: 50%; width: 50%;
@@ -655,7 +678,7 @@ export default defineComponent({
margin-bottom: 1rem; margin-bottom: 1rem;
border-radius: 1rem; border-radius: 1rem;
overflow: hidden; overflow: hidden;
border: 2px solid #eaecf0; border: 1.5px solid #eaecf0;
> .popular { > .popular {
background: #2d9f75; background: #2d9f75;

View File

@@ -31,9 +31,9 @@
<span v-if="scaleImageList[scaleImageIndex]?.resultType == 'ToProductImage'">{{$t('ProductImg.MagicTools')}}</span> <span v-if="scaleImageList[scaleImageIndex]?.resultType == 'ToProductImage'">{{$t('ProductImg.MagicTools')}}</span>
<span v-if="scaleImageList[scaleImageIndex]?.resultType == 'Relight'">{{$t('ProductImg.relightingTool')}}</span> <span v-if="scaleImageList[scaleImageIndex]?.resultType == 'Relight'">{{$t('ProductImg.relightingTool')}}</span>
</div> </div>
<div v-show="scaleImageList[scaleImageIndex]?.resultType == 'Relight'" class="productImg_content_item_title productImg_content_item_title_similarity"> <!-- <div v-show="scaleImageList[scaleImageIndex]?.resultType == 'Relight'" class="productImg_content_item_title productImg_content_item_title_similarity">
<span>{{$t('ProductImg.SelectionFunction')}}</span> <span>{{$t('ProductImg.SelectionFunction')}}</span>
</div> </div> -->
<!-- 暂时去掉 --> <!-- 暂时去掉 -->
<!-- <div v-show="scaleImageList[scaleImageIndex]?.resultType == 'Relight'" class="productImg_content_item_Direction generalModel_state_item" style="margin-bottom: 1rem;"> <!-- <div v-show="scaleImageList[scaleImageIndex]?.resultType == 'Relight'" class="productImg_content_item_Direction generalModel_state_item" style="margin-bottom: 1rem;">
<a-select size="large" style="width: 100%;" v-model:value="speedData.value" :options="speedList" :field-names="{ label: 'relightLabel', value: 'value' }"></a-select> <a-select size="large" style="width: 100%;" v-model:value="speedData.value" :options="speedList" :field-names="{ label: 'relightLabel', value: 'value' }"></a-select>

View File

@@ -69,6 +69,7 @@
/> />
</svg> </svg>
</div> </div>
<div class="info">{{ $t('brandDNA.LastCompletionTime') }}: {{finishTime}}</div>
</div> </div>
</div> </div>
<div class="content"> <div class="content">
@@ -173,6 +174,7 @@ export default defineComponent({
}, },
isNoData:false,//如果数据为空就不加载 isNoData:false,//如果数据为空就不加载
isNull:true, isNull:true,
finishTime:'',
}) })
const dataDom = reactive({ const dataDom = reactive({
Cropper:null as any, Cropper:null as any,
@@ -308,7 +310,7 @@ export default defineComponent({
data.logoUrl = value.minioUrl data.logoUrl = value.minioUrl
data.minioUrl = value.brandLogo data.minioUrl = value.brandLogo
clearInterval(data.getProgressTime) clearInterval(data.getProgressTime)
getProgress() getProgress(true)
// getLibraryList() // getLibraryList()
data.isNoData = false data.isNoData = false
data.currentPage = 0 data.currentPage = 0
@@ -344,25 +346,30 @@ export default defineComponent({
} }
const compute = ()=>{ const compute = ()=>{
Https.axiosPost(Https.httpUrls.productImageInitialize,{brandId:data.detail.id}).then((res:any)=>{ Https.axiosPost(Https.httpUrls.productImageInitialize,{brandId:data.detail.id}).then((res:any)=>{
getProgress() getProgress(false)
}).catch((err:any)=>{ }).catch((err:any)=>{
// console.log(err) // console.log(err)
}) })
} }
const getProgress = ()=>{ const getProgress = (boolean:boolean)=>{
console.log(boolean)
setTimeout setTimeout
if(props.selectCode != 'MyBrand'){ if(props.selectCode != 'MyBrand'){
clearTimeout(data.getProgressTime) clearTimeout(data.getProgressTime)
return return
} }
Https.axiosPost(Https.httpUrls.getInitializeProgress,{brandId:data.detail.id}).then((res:any)=>{ Https.axiosPost(Https.httpUrls.getInitializeProgress,{brandId:data.detail.id}).then((res:any)=>{
data.finishTime = res.computeTime
data.schedule.num = res.percent data.schedule.num = res.percent
data.schedule.state = res.analyzed data.schedule.state = res.analyzed
if(res.percent == 1 && !boolean){
message.success(t('brandDNA.Finish'))
}
if(res.percent == 1 || !res.analyzed){ if(res.percent == 1 || !res.analyzed){
return clearTimeout(data.getProgressTime) return clearTimeout(data.getProgressTime)
} }
data.getProgressTime = setTimeout(()=>{ data.getProgressTime = setTimeout(()=>{
getProgress() getProgress(boolean)
},5000) },5000)
// analyzed // analyzed
@@ -515,6 +522,11 @@ export default defineComponent({
position: relative; position: relative;
padding-right: 2rem; padding-right: 2rem;
} }
> .info{
color: #5f5f5f;
font-size: 1.2rem;
margin-top: .8rem;
}
.gallery_btn{ .gallery_btn{
&.loading{ &.loading{
pointer-events: none; pointer-events: none;

View File

@@ -144,7 +144,8 @@
class="forget_password_content_block" class="forget_password_content_block"
@click="forgetPasswordLastStepFun()" @click="forgetPasswordLastStepFun()"
> >
<i class="fi fi-br-arrow-left"></i> <!-- <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">Retrieve password</span>
</div> </div>
<div v-show="frogetPasswordStep === 1"> <div v-show="frogetPasswordStep === 1">
@@ -849,6 +850,24 @@ export default defineComponent({
.forget_password_content_block { .forget_password_content_block {
cursor: pointer; cursor: pointer;
font-size: 3.6rem;
font-weight: 500;
display: flex;
align-items: center;
margin-bottom: 1.2rem;
> i {
margin-right: 2.8rem;
font-size: 2rem;
display: flex;
cursor: pointer;
align-items: center;
width: 4.6rem;
height: 4.6rem;
border-radius: 1.2rem;
display: flex;
justify-content: center;
border: 1px solid #D8DADC;
}
} }
.fi-br-arrow-left { .fi-br-arrow-left {

View File

@@ -137,7 +137,8 @@
> >
<!-- <span class="icon iconfont fi-br-arrow-left"></span <!-- <span class="icon iconfont fi-br-arrow-left"></span
> --> > -->
<i class="fi fi-br-arrow-left"></i> <!-- <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">Retrieve password</span>
</div> </div>
<div v-show="frogetPasswordStep === 1"> <div v-show="frogetPasswordStep === 1">
@@ -835,6 +836,24 @@ export default defineComponent({
.forget_password_content_block { .forget_password_content_block {
cursor: pointer; cursor: pointer;
text-align: left; text-align: left;
font-size: 3.6rem;
font-weight: 500;
display: flex;
align-items: center;
margin-bottom: 1.2rem;
> i {
margin-right: 2.8rem;
font-size: 2rem;
display: flex;
cursor: pointer;
align-items: center;
width: 4.6rem;
height: 4.6rem;
border-radius: 1.2rem;
display: flex;
justify-content: center;
border: 1px solid #D8DADC;
}
} }
.fi-br-arrow-left { .fi-br-arrow-left {

View File

@@ -144,7 +144,8 @@
class="forget_password_content_block" class="forget_password_content_block"
@click="forgetPasswordLastStepFun()" @click="forgetPasswordLastStepFun()"
> >
<i class="fi fi-br-arrow-left"></i> <!-- <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">Retrieve password</span>
</div> </div>
<div v-show="frogetPasswordStep === 1"> <div v-show="frogetPasswordStep === 1">
@@ -852,6 +853,24 @@ export default defineComponent({
.forget_password_content_block { .forget_password_content_block {
cursor: pointer; cursor: pointer;
font-size: 3.6rem;
font-weight: 500;
display: flex;
align-items: center;
margin-bottom: 1.2rem;
> i {
margin-right: 2.8rem;
font-size: 2rem;
display: flex;
cursor: pointer;
align-items: center;
width: 4.6rem;
height: 4.6rem;
border-radius: 1.2rem;
display: flex;
justify-content: center;
border: 1px solid #D8DADC;
}
} }
.fi-br-arrow-left { .fi-br-arrow-left {

View File

@@ -154,7 +154,7 @@
</template> </template>
<script lang="ts"> <script lang="ts">
import { defineComponent, ref, reactive, toRefs, onMounted } from "vue"; import { defineComponent, ref, reactive, toRefs, onMounted, onBeforeUnmount } from "vue";
import { Https } from "@/tool/https"; import { Https } from "@/tool/https";
import { isEmail } from "@/tool/util"; import { isEmail } from "@/tool/util";
import { message } from "ant-design-vue"; import { message } from "ant-design-vue";
@@ -195,6 +195,7 @@ export default defineComponent({
}; };
const cancelDsign = () => { const cancelDsign = () => {
payMethod.payMethodModel = false; payMethod.payMethodModel = false;
store.dispatch('getLangType')
}; };
const payAffirm = () => { const payAffirm = () => {
if (!payMethodData.clause) { if (!payMethodData.clause) {
@@ -286,6 +287,7 @@ export default defineComponent({
setPaidBack(); setPaidBack();
emit("completePayment"); emit("completePayment");
}; };
return { return {
store, store,
...toRefs(payMethod), ...toRefs(payMethod),

View File

@@ -31,12 +31,12 @@
<span v-if="scaleImageList[scaleImageIndex]?.resultType == 'ToProductImage'">{{$t('ProductImg.MagicTools')}}</span> <span v-if="scaleImageList[scaleImageIndex]?.resultType == 'ToProductImage'">{{$t('ProductImg.MagicTools')}}</span>
<span v-if="scaleImageList[scaleImageIndex]?.resultType == 'Relight'">{{$t('ProductImg.relightingTool')}}</span> <span v-if="scaleImageList[scaleImageIndex]?.resultType == 'Relight'">{{$t('ProductImg.relightingTool')}}</span>
</div> </div>
<div v-show="scaleImageList[scaleImageIndex]?.resultType == 'Relight'" class="productImg_content_item_title productImg_content_item_title_similarity"> <!-- <div v-show="scaleImageList[scaleImageIndex]?.resultType == 'Relight'" class="productImg_content_item_title productImg_content_item_title_similarity">
<span>{{$t('ProductImg.SelectionFunction')}}</span> <span>{{$t('ProductImg.SelectionFunction')}}</span>
</div> </div>
<div v-show="scaleImageList[scaleImageIndex]?.resultType == 'Relight'" class="productImg_content_item_Direction generalModel_state_item" style="margin-bottom: 1rem;"> <div v-show="scaleImageList[scaleImageIndex]?.resultType == 'Relight'" class="productImg_content_item_Direction generalModel_state_item" style="margin-bottom: 1rem;">
<a-select size="large" style="width: 100%;" v-model:value="speedData.value" :options="speedList" :field-names="{ label: 'relightLabel', value: 'value' }"></a-select> <a-select size="large" style="width: 100%;" v-model:value="speedData.value" :options="speedList" :field-names="{ label: 'relightLabel', value: 'value' }"></a-select>
</div> </div> -->
<div v-show="scaleImageList[scaleImageIndex]?.resultType == 'ToProductImage' && speedData.value != 'flux'" class="productImg_content_item_title productImg_content_item_title_similarity"> <div v-show="scaleImageList[scaleImageIndex]?.resultType == 'ToProductImage' && speedData.value != 'flux'" class="productImg_content_item_title productImg_content_item_title_similarity">
<span>{{$t('ProductImg.Similarity')}}</span> <span>{{$t('ProductImg.Similarity')}}</span>
</div> </div>

View File

@@ -650,6 +650,7 @@ export default defineComponent({
} }
const setDesignItemStyle = ()=>{ const setDesignItemStyle = ()=>{
posiitonData.value.generateElList = [] posiitonData.value.generateElList = []
if(!collItemDom.value)return
let elArr = collItemDom.value.querySelectorAll('.content_img_GetWidth') let elArr = collItemDom.value.querySelectorAll('.content_img_GetWidth')
designCollectionList.value.forEach((item:any,index:any)=>{ designCollectionList.value.forEach((item:any,index:any)=>{
posiitonData.value.generateElList.unshift({ posiitonData.value.generateElList.unshift({

View File

@@ -329,9 +329,23 @@ export default defineComponent({
}); });
}) })
} }
const historyChooseData = (dataValue:any)=>{ const historyChooseData = async (dataValue:any)=>{
let ifMoodTemplateUrl = true
if(dataValue?.moodBoard?.moodTemplateUrl){
await new Promise<void>((resolve, reject) => {
let img = new Image()
img.src = dataValue.moodBoard?.moodTemplateUrl
img.onload = ()=>{
resolve()
}
img.onerror = ()=>{
ifMoodTemplateUrl = false
resolve()
}
})
}
let collectionData = { let collectionData = {
disposeMoodboard: dataValue.moodBoard?.moodTemplateId?[{ disposeMoodboard: (dataValue.moodBoard?.moodTemplateId && ifMoodTemplateUrl)?[{
id:dataValue.moodBoard?.moodTemplateId, id:dataValue.moodBoard?.moodTemplateId,
imgUrl:dataValue.moodBoard?.moodTemplateUrl, imgUrl:dataValue.moodBoard?.moodTemplateUrl,
resData:{ resData:{

View File

@@ -29,7 +29,6 @@ import {message} from 'ant-design-vue'
import { Https } from "@/tool/https"; import { Https } from "@/tool/https";
import { useStore } from "vuex"; import { useStore } from "vuex";
import { useI18n } from "vue-i18n"; import { useI18n } from "vue-i18n";
import canvasGeneral from "@/tool/canvasGeneralCopy";
import editCanvas from "@/component/Canvas/CanvasEditor/index.vue"; import editCanvas from "@/component/Canvas/CanvasEditor/index.vue";
import FemaleAdultModel from "@/assets/images/homePage/FemaleAdultModel.png" import FemaleAdultModel from "@/assets/images/homePage/FemaleAdultModel.png"
import FemaleChildModel from "@/assets/images/homePage/FemaleChildModel.png" import FemaleChildModel from "@/assets/images/homePage/FemaleChildModel.png"
@@ -156,7 +155,6 @@ export default defineComponent({
onBeforeUnmount(()=>{ onBeforeUnmount(()=>{
data.canvasLoad = false data.canvasLoad = false
data.isHiddenModel = true data.isHiddenModel = true
// canvasGeneral.canvasClear()
}) })
return { return {
...toRefs(data), ...toRefs(data),

View File

@@ -75,9 +75,9 @@
</a-slider> </a-slider>
<input style="margin-left: 2rem;" type="number" readonly v-model="similarity"> <input style="margin-left: 2rem;" type="number" readonly v-model="similarity">
</div> </div>
<div v-show="productimgMenu.value == 'Relight'" class="productImg_content_item_title productImg_content_item_title_similarity"> <!-- <div v-show="productimgMenu.value == 'Relight'" class="productImg_content_item_title productImg_content_item_title_similarity">
<span>{{$t('ProductImg.SelectionFunction')}}</span> <span>{{$t('ProductImg.SelectionFunction')}}</span>
</div> </div> -->
<!-- 暂时去掉 --> <!-- 暂时去掉 -->
<!-- <div v-show="productimgMenu.value == 'Relight'" class="productImg_content_item_Direction generalModel_state_item"> <!-- <div v-show="productimgMenu.value == 'Relight'" class="productImg_content_item_Direction generalModel_state_item">
<a-select size="large" style="width: 100%;" v-model:value="speedData.value" :options="speedList" :field-names="{ label: 'relightLabel', value: 'value' }"></a-select> <a-select size="large" style="width: 100%;" v-model:value="speedData.value" :options="speedList" :field-names="{ label: 'relightLabel', value: 'value' }"></a-select>
@@ -157,11 +157,11 @@
<img <img
class="guide" class="guide"
v-if="locale == 'ENGLISH' && likeList[productimgMenu.value] == 0 && generateList[productimgMenu.value] == 0" v-if="locale == 'ENGLISH' && likeList[productimgMenu.value] == 0 && generateList[productimgMenu.value] == 0"
:src="'/src/assets/images/homePage/toolsGuide/' + (productimgMenu.value == 'ToProductImage'?'productEN':'relightEN') + '.png'" alt=""> :src="'/image/toolsGuide/' + (productimgMenu.value == 'ToProductImage'?'productEN':'relightEN') + '.png'" alt="">
<img <img
class="guide" class="guide"
v-else-if="likeList[productimgMenu.value] == 0 && generateList[productimgMenu.value] == 0" v-else-if="likeList[productimgMenu.value] == 0 && generateList[productimgMenu.value] == 0"
:src="'/src/assets/images/homePage/toolsGuide/' + (productimgMenu.value == 'ToProductImage'?'productCN':'relightCN') + '.png'" alt=""> :src="'/image/toolsGuide/' + (productimgMenu.value == 'ToProductImage'?'productCN':'relightCN') + '.png'" alt="">
<generalDrag ref="generalDragLeft" :type="productimgMenu.value" :isCopy="!isDesignPage" @setBtn="selectSetBtn" :isDelete="false" :isLike="true" :list="likeList[productimgMenu.value]"></generalDrag> <generalDrag ref="generalDragLeft" :type="productimgMenu.value" :isCopy="!isDesignPage" @setBtn="selectSetBtn" :isDelete="false" :isLike="true" :list="likeList[productimgMenu.value]"></generalDrag>
</div> </div>
<!-- </div> --> <!-- </div> -->

View File

@@ -21,7 +21,7 @@
<div>{{ item?.custom }}</div> <div>{{ item?.custom }}</div>
<span style="font-size: 1.4rem;">{{ item?.customInfo }}</span> <span style="font-size: 1.4rem;">{{ item?.customInfo }}</span>
</div> </div>
<ul class="product_detail" :class="{'academic':item.type == 'academic'}"> <ul class="product_detail" :class="{'academic':(item.type == 'academic' && !isSelectSuccessively)}">
<li v-for="detailItem in item?.detailList">{{ detailItem }}</li> <li v-for="detailItem in item?.detailList">{{ detailItem }}</li>
</ul> </ul>
<div class="gallery_btn gallery_btn_radius" v-if="item?.btn != 'Contact us'" @click="createAccount">{{ item?.btn }}</div> <div class="gallery_btn gallery_btn_radius" v-if="item?.btn != 'Contact us'" @click="createAccount">{{ item?.btn }}</div>
@@ -64,8 +64,8 @@
img: '/image/homeIntroduct/personal.png', img: '/image/homeIntroduct/personal.png',
type:'personal', type:'personal',
info: "您的AI时尚设计助手", info: "您的AI时尚设计助手",
price: '¥100', price: 'HK$100',
detail: "每月·50积分", detail: "每月·500积分",
highlight: "免费试用5天", highlight: "免费试用5天",
discounts: '9折优惠', discounts: '9折优惠',
detailList: [ detailList: [
@@ -82,7 +82,7 @@
img: '/image/homeIntroduct/personal.png', img: '/image/homeIntroduct/personal.png',
type:'personal', type:'personal',
info: "您的AI时尚设计助手", info: "您的AI时尚设计助手",
price: '¥500', price: 'HK$500',
detail: "每月·3500积分", detail: "每月·3500积分",
highlight: "免费试用5天", highlight: "免费试用5天",
discounts: '9折优惠', discounts: '9折优惠',
@@ -107,10 +107,12 @@
discounts: '', discounts: '',
detailList: [ detailList: [
'灵活的自定义程序以满足学校需求', '灵活的自定义程序以满足学校需求',
"项目期间每月信用额度自动续期",
'可在用户之间灵活共享和分配账户信用额度', '可在用户之间灵活共享和分配账户信用额度',
'AI辅助设计教学功能', 'AI辅助设计教学功能',
'支持草图创意和设计灵感教学', "从设计灵感、草图创作到完整时装系列的尖端教学工具",
'基础3D设计功能', "基本3D设计功能",
"客户与技术支援",
], ],
btn: '联系我们', btn: '联系我们',
}, },
@@ -121,7 +123,7 @@
img: '/image/homeIntroduct/personal.png', img: '/image/homeIntroduct/personal.png',
type:'personal', type:'personal',
info: "您的AI时尚设计助手", info: "您的AI时尚设计助手",
price: '¥5,000', price: 'HK$5,000',
detail: "每年·50000积分", detail: "每年·50000积分",
highlight: "免费试用5天", highlight: "免费试用5天",
discounts: '9折优惠', discounts: '9折优惠',
@@ -145,10 +147,13 @@
highlight: "", highlight: "",
discounts: '', discounts: '',
detailList: [ detailList: [
'全校共享积分额度', '灵活的自定义程序以满足学校需求',
"项目期间每月信用额度自动续期",
'可在用户之间灵活共享和分配账户信用额度',
'AI辅助设计教学功能', 'AI辅助设计教学功能',
'支持草图创意和设计灵感教学', "从设计灵感、草图创作到完整时装系列的尖端教学工具",
'基础3D设计功能', "基本3D设计功能",
"客户与技术支援",
], ],
btn: '联系我们', btn: '联系我们',
}, },

View File

@@ -277,7 +277,8 @@
> >
<!-- <span class="icon iconfont fi-br-arrow-left"></span <!-- <span class="icon iconfont fi-br-arrow-left"></span
> --> > -->
<i class="fi fi-br-arrow-left"></i> <!-- <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">Retrieve password</span>
</div> </div>
<div v-show="frogetPasswordStep === 1"> <div v-show="frogetPasswordStep === 1">
@@ -1092,6 +1093,24 @@ export default defineComponent({
.forget_password_content_block { .forget_password_content_block {
cursor: pointer; cursor: pointer;
font-size: 3.6rem;
font-weight: 500;
display: flex;
align-items: center;
margin-bottom: 1.2rem;
> i {
margin-right: 2.8rem;
font-size: 2rem;
display: flex;
cursor: pointer;
align-items: center;
width: 4.6rem;
height: 4.6rem;
border-radius: 1.2rem;
display: flex;
justify-content: center;
border: 1px solid #D8DADC;
}
} }
.fi-br-arrow-left { .fi-br-arrow-left {

View File

@@ -23,7 +23,6 @@ import {message} from 'ant-design-vue'
import { Https } from "@/tool/https"; import { Https } from "@/tool/https";
import { useStore } from "vuex"; import { useStore } from "vuex";
import { useI18n } from "vue-i18n"; import { useI18n } from "vue-i18n";
import canvasGeneral from "@/tool/canvasGeneralCopy";
import editCanvas from "@/component/Canvas/CanvasEditor/index.vue"; import editCanvas from "@/component/Canvas/CanvasEditor/index.vue";
@@ -154,7 +153,6 @@ export default defineComponent({
}); });
onBeforeUnmount(()=>{ onBeforeUnmount(()=>{
data.canvasLoad = false data.canvasLoad = false
// canvasGeneral.canvasClear()
}) })
return { return {
...toRefs(data), ...toRefs(data),

View File

@@ -1,6 +1,3 @@
import { fontFamily } from "html2canvas/dist/types/css/property-descriptors/font-family";
import { opacity } from "html2canvas/dist/types/css/property-descriptors/opacity";
export default { export default {
Header: { Header: {
hello: "你好", hello: "你好",
@@ -282,7 +279,7 @@ export default {
LikeVideo: "已选择的", LikeVideo: "已选择的",
InputVideo: "生成结果", InputVideo: "生成结果",
GeneratedVideo: "生成的视频", GeneratedVideo: "生成的视频",
hint: "将草图改为逼真的照片,这条裙子的材质是牛仔布。", hint: "完整长度肖像,匹配参考图像中的服装风格、图案和面料纹理,精确复制服装设计细节,保持原始配色方案,高度忠实于参考服装,真实的光照效果,细致的面料渲染。",
jsContent1: "生成视频预计需要三分钟,请问是否继续", jsContent1: "生成视频预计需要三分钟,请问是否继续",
}, },
LibraryPage: { LibraryPage: {
@@ -753,6 +750,7 @@ export default {
remainingModifications: "本月剩余次数:", remainingModifications: "本月剩余次数:",
Country: "国家", Country: "国家",
CompanyName: "职业", CompanyName: "职业",
Status: "状态",
Valid: "有效", Valid: "有效",
Expire: "过期", Expire: "过期",
//account首页 //account首页
@@ -1012,6 +1010,8 @@ export default {
Slogan: "标语", Slogan: "标语",
Upload: "上传", Upload: "上传",
Delete: "删除", Delete: "删除",
Finish:'我们已经根据您的喜好确定了您的风格。',
LastCompletionTime:'上次完成时间',
textarea: "请阐述您对这个品牌的看法,我们将帮助您设计出名称、标志以及宣传语。", textarea: "请阐述您对这个品牌的看法,我们将帮助您设计出名称、标志以及宣传语。",
}, },
chat: { chat: {
@@ -1280,7 +1280,7 @@ export default {
wx:'基础', wx:'基础',
relightEdit:'编辑细节', relightEdit:'编辑细节',
changeBackground:'修改背景', changeBackground:'修改背景',
toproductFlus:'高', toproductFlus:'高质量',
toproductBasic:'基础', toproductBasic:'基础',
generateWx:'高级', generateWx:'高级',
generateFlux:'进阶', generateFlux:'进阶',
@@ -1298,5 +1298,48 @@ export default {
}, },
event:{ event:{
back:'返回' back:'返回'
} },
admin:{
allUser:'所有用户',
UserData:'用户数据',
},
adminSeAllUser:{
CreateTime:'创建时间',
UserName:'用户名',
search:'搜索',
add:'添加',
DownloadTemplate:'下载模板',
UploadTemplate:'上传模板',
ExportAccountData:'导出账号数据',
NearlyAYear:'近一年',
LastMonth:'上一个月',
LastWeek:'上一周',
Edit:'编辑',
Delete:'删除',
UserId:'用户ID',
Email:'邮箱',
UserEmail:'用户邮箱',
language:'语言',
CreateDate:'创建时间',
Credits:'积分',
CreditsUsage:'已被使用',
CreditsUsageLimit:'积分使用上限',
Operations:'操作',
Password:'密码',
MaximumCredits:'最大积分',
Close:'关闭',
OK:'确定',
jsContent1:'邮箱格式有误',
jsContent2:'请检查所有带 * 号的内容',
},
adminSeDesignDetail:{
StartDate:'开始日期',
StartTime:'开始时间',
Email:'邮箱',
UserName:'用户名',
UserId:'用户ID',
Frequency:'设计频率',
CreateTime:'创建时间',
Credits:'积分',
},
}; };

View File

@@ -279,7 +279,7 @@ export default {
LikeVideo: "Selected", LikeVideo: "Selected",
InputVideo: "Generated", InputVideo: "Generated",
GeneratedVideo: "Generated Video", GeneratedVideo: "Generated Video",
hint: "change the sketch to realistic photo, the material of the skirt is denim", hint: "Full length portrait, match the clothing style, patterns, and fabric texture from the reference image, replicate garment design details precisely, maintain original color scheme, high fidelity to reference attire, realistic lighting, detailed fabric rendering",
jsContent1: "Video generation will take approximately 3 minutes. Continue?", jsContent1: "Video generation will take approximately 3 minutes. Continue?",
}, },
LibraryPage: { LibraryPage: {
@@ -750,6 +750,7 @@ export default {
remainingModifications: "Remaining this month:", remainingModifications: "Remaining this month:",
Country: "Country", Country: "Country",
CompanyName: "Occupation", CompanyName: "Occupation",
Status: "Status",
Valid: "Valid", Valid: "Valid",
Expire: "Expire", Expire: "Expire",
//account首页 //account首页
@@ -1009,6 +1010,8 @@ export default {
Slogan: "Slogan", Slogan: "Slogan",
Upload: "Upload", Upload: "Upload",
Delete: "Delete", Delete: "Delete",
Finish:'We have calculated your preferred style.',
LastCompletionTime:'Last completion time',
textarea: "Please enter your thoughts about this brand, and we will help you generate the name, logo, and slogan.", textarea: "Please enter your thoughts about this brand, and we will help you generate the name, logo, and slogan.",
}, },
chat: { chat: {
@@ -1295,5 +1298,48 @@ export default {
}, },
event:{ event:{
back:'Back' back:'Back'
} },
admin:{
allUser:'All User',
UserData:'User Data',
},
adminSeAllUser:{
CreateTime:'Create Time',
UserName:'User Name',
search:'Search',
add:'Add',
DownloadTemplate:'Download Template',
UploadTemplate:'Upload Template',
ExportAccountData:'Export account data',
NearlyAYear:'Nearly a year',
LastMonth:'Last month',
LastWeek:'Last week',
Edit:'Edit',
Delete:'Delete',
UserId:'User ID',
Email:'Email',
UserEmail:'Ucser Email',
language:'Language',
CreateDate:'Create Date',
Credits:'Credits',
CreditsUsage:'Credits Usage',
CreditsUsageLimit:'Credits Usage Limit',
Operations:'Operations',
Password:'Password',
MaximumCredits:'Maximum Credits',
Close:'Close',
OK:'OK',
jsContent1:'The email format is incorrect',
jsContent2:'Please check the input box marked with *',
},
adminSeDesignDetail:{
StartDate:'Start Date',
StartTime:'Start Time',
Email:'Email',
UserName:'User Name',
UserId:'User ID',
Frequency:'Frequency',
CreateTime:'Create Time',
Credits:'Credits',
},
}; };

View File

@@ -360,6 +360,22 @@ const routes: Array<RouteRecordRaw> = [
}, },
component: () => import("@/views/feedbackSurveyCN.vue"), component: () => import("@/views/feedbackSurveyCN.vue"),
}, },
{
path: "/email3-1EN",
name: "email3-1EN",
meta: {
enter: "all",
},
component: () => import("@/views/emailPage/email3-1EN.vue"),
},
{
path: "/email3-1CN",
name: "email3-1CN",
meta: {
enter: "all",
},
component: () => import("@/views/emailPage/email3-1CN.vue"),
},
{ {
path: "/404", path: "/404",
name: "404", name: "404",

View File

@@ -261,7 +261,7 @@ const userHabit : Module<UserHabit,RootState> = {
*/ */
state.userDetail.affiliate = data.affiliate state.userDetail.affiliate = data.affiliate
state.userDetail.systemUser = data.systemUser state.userDetail.systemUser = data.systemUser
state.userDetail.systemUser = 3 // state.userDetail.systemUser = 3
// 身份列表1可以使用aida系统2:可以使用affiliate页面3系统管理员用户 // 身份列表1可以使用aida系统2:可以使用affiliate页面3系统管理员用户
state.userDetail.systemList = [] state.userDetail.systemList = []
if(data.systemUser != 0)state.userDetail.systemList.push(1) if(data.systemUser != 0)state.userDetail.systemList.push(1)
@@ -273,6 +273,7 @@ const userHabit : Module<UserHabit,RootState> = {
state.userDetail.systemList.push(3) state.userDetail.systemList.push(3)
} }
sessionStorage.setItem('vuex_systemList', JSON.stringify(state.userDetail.systemList)); sessionStorage.setItem('vuex_systemList', JSON.stringify(state.userDetail.systemList));
sessionStorage.setItem('vuex_systemUser', JSON.stringify(state.userDetail.systemUser));
state.userDetail.followeeCount = data.followeeCount//粉丝数量 state.userDetail.followeeCount = data.followeeCount//粉丝数量
state.userDetail.followerCount = data.followerCount//关注数量 state.userDetail.followerCount = data.followerCount//关注数量

View File

@@ -1,5 +1,5 @@
const adminRouter = { const all = (t)=>{
all:[{ return[{
name:'All User', name:'All User',
route:'/administrator/allUser', route:'/administrator/allUser',
icon:'yonghu', icon:'yonghu',
@@ -24,7 +24,7 @@ const adminRouter = {
// }, // },
// ], // ],
},{ },{
name:'Design Frequency', name:'User data',
route:'/administrator/testClickData', route:'/administrator/testClickData',
icon:'shenpi', icon:'shenpi',
expandIcon:'icon-xiala', expandIcon:'icon-xiala',
@@ -177,17 +177,19 @@ const adminRouter = {
route:'/administrator/organization', route:'/administrator/organization',
key:'sub13', key:'sub13',
isShow:true, isShow:true,
}], }]
schoolOrEnterprise:[ }
const schoolOrEnterprise = (t) =>{
return[
{ {
name:'All User', name:t('admin.allUser'),
route:'/administrator/allUserSE', route:'/administrator/allUserSE',
icon:'usetime', icon:'usetime',
key:'sub1', key:'sub1',
isShow:true, isShow:true,
}, },
{ {
name:'Design Frequency', name:t('admin.UserData'),
route:'/administrator/testClickDataSE', route:'/administrator/testClickDataSE',
icon:'usetime', icon:'usetime',
key:'sub2', key:'sub2',
@@ -222,4 +224,4 @@ const adminRouter = {
// } // }
] ]
} }
export {adminRouter} export default {all , schoolOrEnterprise}

View File

@@ -2,13 +2,14 @@ import html2canvas from "html2canvas";
const getJpeg = dom =>{ const getJpeg = dom =>{
return new Promise(resolve =>{ return new Promise(resolve =>{
setTimeout(() => { setTimeout(() => {
html2canvas(dom,{useCORS: true,}).then(canvas =>{ html2canvas(dom,{useCORS: true,backgroundColor: null}).then(canvas =>{
let base64 = canvas.toDataURL('image/jpeg',.9); let base64 = canvas.toDataURL('image/png',.9);
console.log(base64)
// let quality = 0.9 // 压缩系数0-1之间 // let quality = 0.9 // 压缩系数0-1之间
let newImage = new Image() let newImage = new Image()
newImage.src = base64 newImage.src = base64
newImage.setAttribute('crossOrigin', 'Anonymous') // url为外域时需要 newImage.setAttribute('crossOrigin', 'Anonymous') // url为外域时需要
const filename = new Date().toISOString() + '.jpg'; const filename = new Date().toISOString() + '.png';
resolve(base64ToFile(base64,filename)) resolve(base64ToFile(base64,filename))
newImage.remove() newImage.remove()
// } // }
@@ -29,7 +30,7 @@ function base64ToFile(base64,filename) {
const byteArray = new Uint8Array(byteNumbers); const byteArray = new Uint8Array(byteNumbers);
// 创建 File 对象 // 创建 File 对象
const file = new File([byteArray], filename, { type: 'image/jpeg' }); // 根据需要的类型进行修改 const file = new File([byteArray], filename, { type: 'image/png' }); // 根据需要的类型进行修改
return file; return file;
} }
//base64转成blob //base64转成blob
@@ -39,7 +40,7 @@ function dataURLtoFile(dataURI, type) {
for (let i = 0; i < binary.length; i++) { for (let i = 0; i < binary.length; i++) {
array.push(binary.charCodeAt(i)); array.push(binary.charCodeAt(i));
} }
return new Blob([new Uint8Array(array)], { type: "image/jpeg" }); return new Blob([new Uint8Array(array)], { type: "image/png" });
} }
//转换 //转换

View File

@@ -82,8 +82,8 @@ axios.interceptors.request.use((config) => {
},(error) =>{ },(error) =>{
return Promise.reject(error); return Promise.reject(error);
}); });
const binaryToUrl = (binary,type = 'application/octet-stream',res)=>{ const binaryToUrl = (binary,type = 'application/json',res)=>{
let blob = new Blob([binary], {'content-type':res.headers['content-type']}); let blob = new Blob([binary], {'content-type':type});
let url = URL.createObjectURL(blob); let url = URL.createObjectURL(blob);
return url return url
} }
@@ -364,6 +364,7 @@ export const Https = {
addOrUpdateSubAccount:`/api/account/addOrUpdateSubAccount`,//添加子账号 addOrUpdateSubAccount:`/api/account/addOrUpdateSubAccount`,//添加子账号
deleteSubAccount:`/api/account/deleteSubAccount`,//删除子账号 deleteSubAccount:`/api/account/deleteSubAccount`,//删除子账号
subAccountImportExcelDownload:`/api/account/subAccountImportExcelDownload`,//批量添加模板下载模板 subAccountImportExcelDownload:`/api/account/subAccountImportExcelDownload`,//批量添加模板下载模板
exportAccountsToExcel:`/api/account/exportAccountsToExcel`,//教育版导出用户数据
getNextSequence:`/api/project/getNextSequence`,//批量添加模板下载模板 getNextSequence:`/api/project/getNextSequence`,//批量添加模板下载模板
subAccountImport:`/api/account/subAccountImport`,//模板导入 subAccountImport:`/api/account/subAccountImport`,//模板导入
getGenerateFrequency:`/api/inquiry/getGenerateFrequency`,//积分使用详情 getGenerateFrequency:`/api/inquiry/getGenerateFrequency`,//积分使用详情
@@ -389,6 +390,7 @@ export const Https = {
affiliateRegistration:`/api/affiliate/registration`,//affiliate注册 affiliateRegistration:`/api/affiliate/registration`,//affiliate注册
personalCenter:`/api/affiliate/personalCenter`,//affiliate个人中心 personalCenter:`/api/affiliate/personalCenter`,//affiliate个人中心
affiliateList:`/api/affiliate/list`,//affiliate审批列表 affiliateList:`/api/affiliate/list`,//affiliate审批列表
updateCommission:`/api/affiliate/updateCommission`,//编辑佣金比例
getEachAffiliateGeneratedRevenue:`/api/affiliate/getEachAffiliateGeneratedRevenue`,//affiliate每个用户根据日期查询收益 getEachAffiliateGeneratedRevenue:`/api/affiliate/getEachAffiliateGeneratedRevenue`,//affiliate每个用户根据日期查询收益
affiliateApproval:`/api/affiliate/approval`,//affiliate同意 审批 affiliateApproval:`/api/affiliate/approval`,//affiliate同意 审批
getPersonalMonthlyIncome:`/api/affiliate/getPersonalMonthlyIncome`,//affiliate图表接口 getPersonalMonthlyIncome:`/api/affiliate/getPersonalMonthlyIncome`,//affiliate图表接口

View File

@@ -72,7 +72,7 @@ import { MailOutlined, AppstoreOutlined, SettingOutlined } from '@ant-design/ico
import { Https } from "@/tool/https"; import { Https } from "@/tool/https";
import { useStore } from "vuex"; import { useStore } from "vuex";
import { useRouter,useRoute } from 'vue-router' import { useRouter,useRoute } from 'vue-router'
import { adminRouter } from "@/tool/adminRouter"; import adminRouter from "@/tool/adminRouter";
import GO from "@/tool/GO"; import GO from "@/tool/GO";
import { country } from "@/tool/country"; import { country } from "@/tool/country";
import { getUploadUrl } from "@/tool/util"; import { getUploadUrl } from "@/tool/util";
@@ -91,6 +91,8 @@ export default defineComponent({
setup() { setup() {
const router = useRouter() const router = useRouter()
// const route:any = useRoute() // const route:any = useRoute()
const {t} = useI18n()
const store:any = useStore() const store:any = useStore()
let userDetail:any= computed(()=>{ let userDetail:any= computed(()=>{
return store.state.UserHabit.userDetail return store.state.UserHabit.userDetail
@@ -107,12 +109,12 @@ export default defineComponent({
const onOpenChange = (openKeys: string[]) => { const onOpenChange = (openKeys: string[]) => {
const latestOpenKey:any = openKeys.find(key => state.openKeys.indexOf(key) === -1); const latestOpenKey:any = openKeys.find(key => state.openKeys.indexOf(key) === -1);
if (state.rootSubmenuKeys.indexOf(latestOpenKey!) === -1) { if (state.rootSubmenuKeys.indexOf(latestOpenKey!) === -1) {
state.openKeys = openKeys; state.openKeys = openKeys;
} else { } else {
state.openKeys = latestOpenKey ? [latestOpenKey] : []; state.openKeys = latestOpenKey ? [latestOpenKey] : [];
} }
}; };
let handleClick = (event:any) => { let handleClick = (event:any) => {
// state.selectedKeys = [Number(event.key)] // state.selectedKeys = [Number(event.key)]
@@ -123,10 +125,11 @@ export default defineComponent({
router.push('/home'); router.push('/home');
} }
onMounted(() => { onMounted(() => {
if(userDetail.value.systemUser == 5 || userDetail.value.systemUser == 7){ var vuex_systemUser: any = sessionStorage.getItem("vuex_systemUser");
state.rootSubmenuKeys = adminRouter.schoolOrEnterprise; if(vuex_systemUser == 5 || vuex_systemUser == 7){
state.rootSubmenuKeys = adminRouter.schoolOrEnterprise(t);
}else{ }else{
state.rootSubmenuKeys = adminRouter.all; state.rootSubmenuKeys = adminRouter.all(t);
} }
const route = router.currentRoute.value const route = router.currentRoute.value
if(state.rootSubmenuKeys.some((item:any) => item.route === route.path) || route.path == "/administrator"){ if(state.rootSubmenuKeys.some((item:any) => item.route === route.path) || route.path == "/administrator"){

View File

@@ -132,7 +132,10 @@
<div class="left" v-show="leftShow"> <div class="left" v-show="leftShow">
<svg @click="()=>leftShow=!leftShow" class="leftShowOrHide" xmlns="http://www.w3.org/2000/svg" width="3rem" height="3rem" fill="currentColor" viewBox="0 0 24 24" data-v-1c7326d6=""><path fill-rule="evenodd" d="M6 5a1 1 0 0 0-1 1v12a1 1 0 0 0 1 1h2V5H6Zm4 0v14h8a1 1 0 0 0 1-1V6a1 1 0 0 0-1-1h-8ZM3 6a3 3 0 0 1 3-3h12a3 3 0 0 1 3 3v12a3 3 0 0 1-3 3H6a3 3 0 0 1-3-3V6Z" clip-rule="evenodd" data-v-1c7326d6=""></path></svg> <svg @click="()=>leftShow=!leftShow" class="leftShowOrHide" xmlns="http://www.w3.org/2000/svg" width="3rem" height="3rem" fill="currentColor" viewBox="0 0 24 24" data-v-1c7326d6=""><path fill-rule="evenodd" d="M6 5a1 1 0 0 0-1 1v12a1 1 0 0 0 1 1h2V5H6Zm4 0v14h8a1 1 0 0 0 1-1V6a1 1 0 0 0-1-1h-8ZM3 6a3 3 0 0 1 3-3h12a3 3 0 0 1 3 3v12a3 3 0 0 1-3 3H6a3 3 0 0 1-3-3V6Z" clip-rule="evenodd" data-v-1c7326d6=""></path></svg>
<div class="newObj marginT2" @click="newProject" > <div class="newObj marginT2" @click="newProject" >
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 25 24"><path stroke="#000" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M12.5 5v14m-7-7h14"></path></svg> <svg width="19" height="16" viewBox="0 0 19 16" fill="none" xmlns="http://www.w3.org/2000/svg">
<line x1="9.83398" y1="1" x2="9.83398" y2="15" stroke="black" stroke-width="4" stroke-linecap="round"/>
<path d="M1.5 8H17.5" stroke="black" stroke-width="4" stroke-linecap="round"/>
</svg>
<p style="white-space: nowrap;">{{$t('Header.NewProject')}}</p> <p style="white-space: nowrap;">{{$t('Header.NewProject')}}</p>
</div> </div>
</div> </div>
@@ -193,7 +196,7 @@
</div> </div>
<div class="homeMain_subscribe"> <div class="homeMain_subscribe">
<div> <div>
<span class="font">Status</span> <span class="font">{{$t('account.Status')}}</span>
<span v-if="userDetail.timeData.isExpiration" class="stateSucsess font">{{$t('account.Valid')}} <i class="fi fi-ss-check-circle"></i></span> <span v-if="userDetail.timeData.isExpiration" class="stateSucsess font">{{$t('account.Valid')}} <i class="fi fi-ss-check-circle"></i></span>
<span v-else class="stateError font">{{$t('account.Expire')}} <i class="fi fi-ss-check-circle"></i></span> <span v-else class="stateError font">{{$t('account.Expire')}} <i class="fi fi-ss-check-circle"></i></span>
<span class="time">{{ userDetail.timeData.text }}</span> <span class="time">{{ userDetail.timeData.text }}</span>
@@ -358,7 +361,7 @@ export default defineComponent({
} }
watch(() => route.query, watch(() => route.query,
(query, oldQuery) => { (query, oldQuery) => {
nextTick(()=>{ nextTick(async ()=>{
const key = Object.keys(query)?.[0] const key = Object.keys(query)?.[0]
if(key){ if(key){
if(query.id){ if(query.id){
@@ -367,20 +370,30 @@ export default defineComponent({
}else{ }else{
homeMainData.openType = Object.keys(query)[0] homeMainData.openType = Object.keys(query)[0]
homeMainData.openTypeChild = query[Object.keys(query)[0]] homeMainData.openTypeChild = query[Object.keys(query)[0]]
}
if((query?.id || query?.history) && !await getIdExistToHistory()){
router.push('/home')
return
} }
}else{ }else{
homeMainData.openType = '' homeMainData.openType = ''
homeMainData.openTypeChild = '' homeMainData.openTypeChild = ''
} }
if(query.create == 'true' || query?.source == 'batch')settingGetHistory() if(
query.create == 'true' ||
query?.source == 'batch' ||
(query.history && query.type == 'Works')
){
settingGetHistory()
}
}) })
}, },
{ immediate: true } // 立即触发一次以处理初始参数 { immediate: true } // 立即触发一次以处理初始参数
); );
watch(()=>homeMainData.openTypeList,()=>{ // watch(()=>homeMainData.openTypeList,()=>{
homeMainData.historyData.page = 1 // homeMainData.historyData.page = 1
}) // })
watch(()=>homeMainData.userDetailLanguage,(newVal)=>{ watch(()=>homeMainData.userDetailLanguage,(newVal)=>{
locale.value = newVal locale.value = newVal
}) })
@@ -463,12 +476,9 @@ export default defineComponent({
} }
const toUserManual = ()=>{ const toUserManual = ()=>{
const route = router.resolve({ name: 'userManual' }); const route = router.resolve({ name: 'userManual' });
window.open(route.href, '_blank'); window.open(route.href + '?lang=' + locale.value, '_blank');
} }
onMounted(async ()=>{ onMounted(async ()=>{
if((route.query?.id || route.query?.history) && !await getIdExistToHistory()){
router.push('/home')
}
let test = getCookie('isTest') let test = getCookie('isTest')
let isTest =JSON.parse(test) let isTest =JSON.parse(test)
//判断账号剩余时间是否太短 //判断账号剩余时间是否太短
@@ -911,7 +921,7 @@ export default defineComponent({
}, },
//教程 //教程
getTutorial(){ getTutorial(){
let url = 'https://code-create.com.hk/wp-content/uploads/2025/02/aida_3.0-Manual-2_5-CN.pdf' let url = 'https://aida-user-manual-chinese.super.site/'
if(this.locale == 'ENGLISH'){ if(this.locale == 'ENGLISH'){
url = 'https://code-create.com.hk/wp-content/uploads/2025/02/aida_3.0-Manual-2_5-EN.pdf' url = 'https://code-create.com.hk/wp-content/uploads/2025/02/aida_3.0-Manual-2_5-EN.pdf'
showViewVideo({url:'https://code-create.com.hk/wp-content/uploads/2025/02/AiDA-demo-video_2_5_EN.mp4'}) showViewVideo({url:'https://code-create.com.hk/wp-content/uploads/2025/02/AiDA-demo-video_2_5_EN.mp4'})
@@ -922,7 +932,7 @@ export default defineComponent({
const a = document.createElement('a'); const a = document.createElement('a');
a.href = url; a.href = url;
a.target = '_blank'; a.target = '_blank';
a.download = 'aida_3.0-Manual.pptx'; // 下载的文件名 // a.download = 'aida_3.0-Manual.pptx'; // 下载的文件名
document.body.appendChild(a); document.body.appendChild(a);
a.click(); a.click();
}, },
@@ -1512,7 +1522,8 @@ export default defineComponent({
padding: 0 1.2rem; padding: 0 1.2rem;
border: 1.72px solid #000; border: 1.72px solid #000;
span{ span{
width: 5rem; // width: 5rem;
max-width: 10rem;
display: inline-block; display: inline-block;
overflow: hidden; overflow: hidden;
display: flex; display: flex;

View File

@@ -1,20 +1,28 @@
<script setup lang="ts"> <script setup lang="ts">
import { ref, onMounted, onUnmounted, reactive, toRefs } from "vue"; import { ref, onMounted, onUnmounted, reactive, toRefs } from "vue";
import { useRouter,useRoute } from 'vue-router'
const route = useRoute()
//const props = defineProps({ //const props = defineProps({
//}) //})
//const emit = defineEmits([ //const emit = defineEmits([
//]) //])
let data = reactive({ let data = reactive({
lang: ''
}) })
onMounted(()=>{ onMounted(()=>{
data.lang = route?.query?.lang
console.log(lang)
}) })
onUnmounted(()=>{ onUnmounted(()=>{
}) })
defineExpose({}) defineExpose({})
const {} = toRefs(data); const {lang} = toRefs(data);
</script> </script>
<template> <template>
<div class="userManual"> <div class="userManual" v-if="lang == 'CHINESE_SIMPLIFIED'">
<iframe src="https://aida-user-manual-chinese.super.site/" width="100%" height="100%" frameborder="0" allowfullscreen />
</div>
<div class="userManual" v-else-if="lang">
<iframe src="https://aida-user-manual.super.site/" width="100%" height="100%" frameborder="0" allowfullscreen /> <iframe src="https://aida-user-manual.super.site/" width="100%" height="100%" frameborder="0" allowfullscreen />
</div> </div>
</template> </template>