29 Commits

Author SHA1 Message Date
X1627315083@163.com
5eaa77596e fix 2026-05-13 16:36:23 +08:00
李志鹏
848e7b4692 更改卖家审批提示词 2026-05-12 11:23:18 +08:00
李志鹏
fd140ebc56 还原绑定 2026-05-12 11:08:18 +08:00
李志鹏
34094c8c92 Merge branch 'dev_vite' of http://18.167.251.121:10003/aidlab/aida_front into dev_vite 2026-05-12 11:01:54 +08:00
李志鹏
e4dc2bf729 还原绑定 2026-05-12 11:01:53 +08:00
李志鹏
7f226179d9 绑定修改 2026-05-11 10:50:17 +08:00
李志鹏
3edff6b05c Merge branch 'dev_vite' of http://18.167.251.121:10003/aidlab/aida_front into dev_vite 2026-05-11 10:01:19 +08:00
李志鹏
6fd1212298 修改 2026-05-11 10:01:18 +08:00
e093cccb8d bugfix: 没有产品主图时自动选中问题 2026-05-07 17:06:06 +08:00
b2c6c61515 bugfix: 封面必填校验 2026-05-07 15:53:47 +08:00
0219b1a2f4 docs: 商品编辑页面的agents.md 2026-05-07 13:53:06 +08:00
133433a260 feat: 视频保存 2026-05-07 13:15:21 +08:00
90a59a3dc5 feat: 视频显示到列表 2026-05-07 10:21:08 +08:00
c8a65ee2cb Merge branch 'dev_vite' of ssh://18.167.251.121:10002/aidlab/aida_front into dev_vite 2026-05-06 16:33:32 +08:00
226918e941 style: 裁剪弹窗标题被遮挡问题 2026-05-06 16:33:31 +08:00
李志鹏
494bfd68ca 1 2026-05-06 16:13:34 +08:00
X1627315083@163.com
95b70792ba Merge branch 'dev_vite' of ssh://18.167.251.121:10002/aidlab/aida_front into dev_vite 2026-05-06 16:06:56 +08:00
X1627315083@163.com
a0fffa5896 fix 2026-05-06 16:06:54 +08:00
李志鹏
06eaabc742 Merge branch 'dev_vite' of http://18.167.251.121:10003/aidlab/aida_front into dev_vite 2026-05-06 13:45:29 +08:00
李志鹏
27da4739a6 语言适配 2026-05-06 13:45:28 +08:00
52576aa0a1 style: 裁剪框被遮挡 2026-05-06 13:25:42 +08:00
22aa7c37cd bugfix: 裁剪组件重置状态 2026-05-06 11:04:46 +08:00
752b33f196 bugfix: 裁剪组件切换类型清除之前的缓存 2026-05-05 15:19:31 +08:00
f3b873b7ae Merge branch 'dev_vite' of ssh://18.167.251.121:10002/aidlab/aida_front into dev_vite 2026-05-05 15:10:16 +08:00
006c2e3f9c bugfix: 剪切组件顶部来源按钮样式 2026-05-05 15:10:14 +08:00
X1627315083@163.com
1f413b36ca fix 2026-05-05 14:53:49 +08:00
X1627315083@163.com
e7b052f100 fix 2026-05-05 14:43:00 +08:00
X1627315083@163.com
19bb412470 Merge branch 'dev_vite' of ssh://18.167.251.121:10002/aidlab/aida_front into dev_vite 2026-05-05 14:41:17 +08:00
X1627315083@163.com
a1e071f7bc fix 2026-05-05 14:41:14 +08:00
36 changed files with 2888 additions and 2436 deletions

View File

@@ -2,7 +2,7 @@ VITE_USER_NODE_ENV = 'development_cloud'
# VITE_APP_BASE_URL = 'https://aida.com.hk/test' # VITE_APP_BASE_URL = 'https://aida.com.hk/test'
# VITE_APP_BASE_URL = 'http://18.167.251.121:10088' # VITE_APP_BASE_URL = 'http://18.167.251.121:10088'
# VITE_APP_BASE_URL = 'https://api.aida.com.hk' # VITE_APP_BASE_URL = 'https://api.aida.com.hk'
VITE_APP_BASE_URL = 'https://develop.api.aida.com.hk' # VITE_APP_BASE_URL = 'https://develop.api.aida.com.hk'
# VITE_APP_BASE_URL = 'https://www.develop-ms.api.aida.com.hk/' VITE_APP_BASE_URL = 'https://www.develop-ms.api.aida.com.hk'
# VITE_APP_BASE_URL = 'http://localhost:22170' # VITE_APP_BASE_URL = 'http://localhost:22170'

View File

@@ -0,0 +1,3 @@
<svg width="14" height="14" viewBox="0 0 14 14" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M13.4872 5.28094L9.06266 0.853126C8.51506 0.306793 7.7733 0 7 0C6.2267 0 5.48494 0.306793 4.93734 0.853126L0.512757 5.28094C0.349671 5.44308 0.220373 5.636 0.132355 5.84851C0.0443375 6.06102 -0.000647733 6.2889 7.04636e-06 6.51894V12.249C7.04636e-06 12.7134 0.184381 13.1587 0.51257 13.4871C0.840758 13.8155 1.28588 14 1.75001 14H12.25C12.7141 14 13.1592 13.8155 13.4874 13.4871C13.8156 13.1587 14 12.7134 14 12.249V6.51894C14.0006 6.2889 13.9557 6.06102 13.8676 5.84851C13.7796 5.636 13.6503 5.44308 13.4872 5.28094ZM8.75 12.8326H5.25V10.5364C5.25 10.072 5.43438 9.62663 5.76256 9.29825C6.09075 8.96986 6.53587 8.78538 7 8.78538C7.46413 8.78538 7.90925 8.96986 8.23744 9.29825C8.56562 9.62663 8.75 10.072 8.75 10.5364V12.8326ZM12.8333 12.249C12.8333 12.4038 12.7719 12.5522 12.6625 12.6617C12.5531 12.7711 12.4047 12.8326 12.25 12.8326H9.91666V10.5364C9.91666 9.76241 9.60937 9.0201 9.06239 8.47279C8.51541 7.92549 7.77355 7.61801 7 7.61801C6.22645 7.61801 5.48459 7.92549 4.93761 8.47279C4.39063 9.0201 4.08334 9.76241 4.08334 10.5364V12.8326H1.75001C1.5953 12.8326 1.44692 12.7711 1.33753 12.6617C1.22813 12.5522 1.16667 12.4038 1.16667 12.249V6.51894C1.16721 6.36425 1.22862 6.216 1.33759 6.10627L5.76217 1.6802C6.09099 1.35272 6.53605 1.16887 7 1.16887C7.46394 1.16887 7.90901 1.35272 8.23783 1.6802L12.6624 6.10802C12.771 6.21732 12.8323 6.36486 12.8333 6.51894V12.249Z" fill="#585858"/>
</svg>

After

Width:  |  Height:  |  Size: 1.5 KiB

View File

@@ -12,7 +12,7 @@
<div class="upload_item"> <div class="upload_item">
<div class="upload_file_item upload_component"> <div class="upload_file_item upload_component">
<a-upload <a-upload
:action="uploadUrl + (upLoadHttpsUrl?upLoadHttpsUrl:'/api/element/upload')" :action="uploadUrl + (upLoadHttpsUrl?upLoadHttpsUrl:'/aida/api/element/upload')"
list-type="picture-card" list-type="picture-card"
:capture="null" :capture="null"
:multiple="true" :multiple="true"

View File

@@ -63,7 +63,7 @@
<a-upload <a-upload
class="search_upImg" class="search_upImg"
:capture="null" :capture="null"
:action="uploadUrl + '/api/element/upload'" :action="uploadUrl + '/aida/api/element/upload'"
list-type="picture-card" list-type="picture-card"
:data="{ :data="{
...upload ...upload
@@ -161,7 +161,7 @@
<a-upload <a-upload
class="search_upImg" class="search_upImg"
:capture="null" :capture="null"
:action="uploadUrl + '/api/element/upload'" :action="uploadUrl + '/aida/api/element/upload'"
list-type="picture-card" list-type="picture-card"
:data="{ :data="{
...upload ...upload

View File

@@ -24,7 +24,7 @@
<div class="upload_file_item upload_component" v-show="fileList.length < 15"> <div class="upload_file_item upload_component" v-show="fileList.length < 15">
<a-upload <a-upload
:capture="null" :capture="null"
:action="uploadUrl + '/api/element/upload'" :action="uploadUrl + '/aida/api/element/upload'"
list-type="picture-card" list-type="picture-card"
:data="{ :data="{
...upload ...upload

View File

@@ -13,7 +13,7 @@
</div> </div>
<div class="upload_file_item upload_component" v-show="fileList.length < 10"> <div class="upload_file_item upload_component" v-show="fileList.length < 10">
<a-upload <a-upload
:action="uploadUrl + '/api/element/upload'" :action="uploadUrl + '/aida/api/element/upload'"
:capture="null" :capture="null"
list-type="picture-card" list-type="picture-card"
:data="{ :data="{

View File

@@ -103,7 +103,7 @@
</div> </div>
<a-upload <a-upload
:capture="null" :capture="null"
:action="uploadUrl + '/api/element/upload'" :action="uploadUrl + '/aida/api/element/upload'"
list-type="picture-card" list-type="picture-card"
:data="{ :data="{
...upload, ...upload,

View File

@@ -45,7 +45,7 @@
<div class="upload_item" v-show="uploadList.length < 1"> <div class="upload_item" v-show="uploadList.length < 1">
<div class="upload_file_item upload_component"> <div class="upload_file_item upload_component">
<a-upload <a-upload
:action="uploadUrl + '/api/history/brandLogoUpload'" :action="uploadUrl + '/aida/api/history/brandLogoUpload'"
list-type="picture-card" list-type="picture-card"
:capture="null" :capture="null"
:headers="{ Authorization: token }" :headers="{ Authorization: token }"

View File

@@ -213,10 +213,10 @@
</div> </div>
</div> </div>
<div class="upload_file_item upload_component"> <div class="upload_file_item upload_component">
<!-- :action="uploadUrl + '/api/history/toProductImageElementUpload'" --> <!-- :action="uploadUrl + '/aida/api/history/toProductImageElementUpload'" -->
<a-upload <a-upload
:action=" :action="
getUploadUrl() + '/api/history/toProductImageElementUpload' getUploadUrl() + '/aida/api/history/toProductImageElementUpload'
" "
list-type="picture-card" list-type="picture-card"
:capture="null" :capture="null"

View File

@@ -60,7 +60,7 @@
> >
<a-upload <a-upload
:action="uploadUrl + '/api/element/upload'" :action="uploadUrl + '/aida/api/element/upload'"
list-type="picture-card" list-type="picture-card"
:capture="null" :capture="null"
:data="{ :data="{

View File

@@ -54,7 +54,7 @@
</div> </div>
<div class="upload_file_item upload_component" v-show="printboardList.length < 16"> <div class="upload_file_item upload_component" v-show="printboardList.length < 16">
<a-upload <a-upload
:action="uploadUrl + '/api/element/upload'" :action="uploadUrl + '/aida/api/element/upload'"
:capture="null" :capture="null"
list-type="picture-card" list-type="picture-card"
:before-upload="beforeUpload" :before-upload="beforeUpload"
@@ -415,7 +415,7 @@ export default defineComponent({
file:data.originFileObj file:data.originFileObj
} }
let fileUid = data.uid let fileUid = data.uid
Https.axiosPost('/api/element/upload', new_data,{headers:{'Content-Type': 'multipart/form-data'}}).then( Https.axiosPost('/aida/api/element/upload', new_data,{headers:{'Content-Type': 'multipart/form-data'}}).then(
(rv: any) => { (rv: any) => {
if (rv) { if (rv) {
for(let file of this.fileList){ for(let file of this.fileList){
@@ -491,7 +491,7 @@ export default defineComponent({
} }
this.isUpload = true this.isUpload = true
const hide = message.loading('loading', 0); const hide = message.loading('loading', 0);
Https.axiosPost('/api/element/upload', new_data,{headers:{'Content-Type': 'multipart/form-data'}}).then( Https.axiosPost('/aida/api/element/upload', new_data,{headers:{'Content-Type': 'multipart/form-data'}}).then(
(rv: any) => { (rv: any) => {
for(let file of this.fileList){ for(let file of this.fileList){
if(fileData.uid === file.uid){ if(fileData.uid === file.uid){

View File

@@ -70,7 +70,7 @@
v-show="sketchboardList.length < 20" v-show="sketchboardList.length < 20"
> >
<a-upload <a-upload
:action="uploadUrl + '/api/element/upload'" :action="uploadUrl + '/aida/api/element/upload'"
:capture="null" :capture="null"
list-type="picture-card" list-type="picture-card"
:data="{ :data="{

View File

@@ -11,7 +11,7 @@
:options="[{value:'product',label:'product'},{value:'sketch',label:'sketch'}]" :options="[{value:'product',label:'product'},{value:'sketch',label:'sketch'}]"
></a-select> ></a-select>
</div> --> </div> -->
<selectList @selectImgItem="selectImgItem" :deReconstructionList="segmentationTypeList" :isSegmentation="true" upLoadHttpsUrl="/api/element/imageSegmentation" level1Type="Sketchboard" :randomId="false" type="sketch" :catecoryList="sketchCatecoryList"> <selectList @selectImgItem="selectImgItem" :deReconstructionList="segmentationTypeList" :isSegmentation="true" upLoadHttpsUrl="/aida/api/element/imageSegmentation" level1Type="Sketchboard" :randomId="false" type="sketch" :catecoryList="sketchCatecoryList">
<template v-slot:selectSex> <template v-slot:selectSex>
<div class="generalModel_state" style="margin-left: auto"> <div class="generalModel_state" style="margin-left: auto">
<div class="generalModel_state_item smail" style="margin-right: 0"> <div class="generalModel_state_item smail" style="margin-right: 0">

View File

@@ -390,7 +390,7 @@ export default defineComponent({
// //fetch get请求携带token // //fetch get请求携带token
// fetch("https://develop.api.aida.com.hk/api/project/getThreeDGlb?threeDSimpleId=1", { // fetch("https://develop.api.aida.com.hk/aida/api/project/getThreeDGlb?threeDSimpleId=1", {
// headers:{ // headers:{
// authorization:'Bearer-eyJhbGciOiJIUzUxMiJ9.eyJqdGkiOiI4OCIsInN1YiI6IntcImNvdW50cnlcIjpcIkNoaW5hXCIsXCJpZFwiOjg4LFwibGFuZ3VhZ2VcIjpcIkVOR0xJU0hcIixcInVzZXJuYW1lXCI6XCJzaGJcIn0iLCJpYXQiOjE3NDMzNDkwNjQsImlzcyI6IkRXSiIsImF1dGhvcml0aWVzIjoiW10iLCJleHAiOjE3NTE5ODkwNjR9.gmL0JufYy9wd23qCY-ibwhgpXZ2X68WAiHSeC99I4x7cipWyxLaQmuIBk2SJSdWBm0tTN2Mx-etXO9a7MtQmpw', // authorization:'Bearer-eyJhbGciOiJIUzUxMiJ9.eyJqdGkiOiI4OCIsInN1YiI6IntcImNvdW50cnlcIjpcIkNoaW5hXCIsXCJpZFwiOjg4LFwibGFuZ3VhZ2VcIjpcIkVOR0xJU0hcIixcInVzZXJuYW1lXCI6XCJzaGJcIn0iLCJpYXQiOjE3NDMzNDkwNjQsImlzcyI6IkRXSiIsImF1dGhvcml0aWVzIjoiW10iLCJleHAiOjE3NTE5ODkwNjR9.gmL0JufYy9wd23qCY-ibwhgpXZ2X68WAiHSeC99I4x7cipWyxLaQmuIBk2SJSdWBm0tTN2Mx-etXO9a7MtQmpw',
// } // }

View File

@@ -78,7 +78,7 @@
<div class="upload_file_item"> <div class="upload_file_item">
<a-upload <a-upload
key="common" key="common"
:action="getUploadUrl() + '/api/history/toProductImageElementUpload'" :action="getUploadUrl() + '/aida/api/history/toProductImageElementUpload'"
list-type="picture-card" list-type="picture-card"
:capture="null" :capture="null"
:data="{ :data="{
@@ -111,7 +111,7 @@
<a-upload <a-upload
key="lastframes" key="lastframes"
:action=" :action="
getUploadUrl() + '/api/history/toProductImageElementUpload' getUploadUrl() + '/aida/api/history/toProductImageElementUpload'
" "
list-type="picture-card" list-type="picture-card"
:capture="null" :capture="null"

View File

@@ -50,7 +50,7 @@
<div class="upload_item item" v-show="!isDesignPage"> <div class="upload_item item" v-show="!isDesignPage">
<div class="upload_file_item"> <div class="upload_file_item">
<a-upload <a-upload
:action="uploadUrl + '/api/history/toProductImageElementUpload'" :action="uploadUrl + '/aida/api/history/toProductImageElementUpload'"
list-type="picture-card" list-type="picture-card"
:capture="null" :capture="null"
:data="{ :data="{

View File

@@ -24,6 +24,7 @@ export default {
SubscribeNow: '立即订阅', SubscribeNow: '立即订阅',
TaskList: '任务列表', TaskList: '任务列表',
ViewOrders: '查询订单', ViewOrders: '查询订单',
PersonalCenter: '个人中心',
BecomeSeller: '成为卖家', BecomeSeller: '成为卖家',
SellerDashboard: '卖家中心', SellerDashboard: '卖家中心',
toolsToProduct: '转产品图', toolsToProduct: '转产品图',
@@ -1535,7 +1536,7 @@ export default {
}, },
event: { event: {
back: '返回', back: '返回',
detail:'查看详情' detail: '查看详情'
}, },
admin: { admin: {
allUser: '所有用户', allUser: '所有用户',
@@ -1609,7 +1610,7 @@ export default {
Cancel: '取消', Cancel: '取消',
SelectPlan: '选择计划', SelectPlan: '选择计划',
AllPlan: '全部', AllPlan: '全部',
PlanStart:'订阅计划生效时间:' PlanStart: '订阅计划生效时间:'
}, },
Login: { Login: {
Login: '登录', Login: '登录',
@@ -1736,32 +1737,32 @@ export default {
showAgain: '不再提示', showAgain: '不再提示',
GetStarted: '开始体验', GetStarted: '开始体验',
}, },
SellerListEdit:{ SellerListEdit: {
saveDraft: "全部保存", saveDraft: "全部保存",
publish: "发布", publish: "发布",
sketch: "线稿图", sketch: "线稿图",
mainProductImage: "产品主图", mainProductImage: "产品主图",
cover: "封面", cover: "封面",
productImageDesc:'从产品图中选取', productImageDesc: '从产品图中选取',
cropDesc:'从主产品图或线稿图中裁剪', cropDesc: '从主产品图或线稿图中裁剪',
productImageMainTitle:'产品图 ', productImageMainTitle: '产品图/视频',
productImageSubTitle:' (来自设计集)', productImageSubTitle: ' (来自设计集)',
apparelSketchTitle:'服装线稿图 ', apparelSketchTitle: '服装线稿图 ',
apparelSketchSubTitle:' (来自设计集)', apparelSketchSubTitle: ' (来自设计集)',
productName:'商品名称', productName: '商品名称',
price:'价格', price: '价格',
productDescription:'商品描述', productDescription: '商品描述',
designFor:'目标人群', designFor: '目标人群',
productCategory:'商品类别', productCategory: '商品类别',
categoryTips:'请选择所有适用选项', categoryTips: '请选择所有适用选项',
policy:'默认情况下,所有销售均遵循平台的许可政策——买家在下载后将获得使用许可', policy: '默认情况下,所有销售均遵循平台的许可政策——买家在下载后将获得使用许可',
learnMore:'了解更多', learnMore: '了解更多',
requiredFieldTips:'请填写{field}', requiredFieldTips: '请填写{field}',
requiredFieldTipsWithPage:'第 {index} 个商品:请填写{field}', requiredFieldTipsWithPage: '第 {index} 个商品:请填写{field}',
draftSaved: '草稿已保存', draftSaved: '草稿已保存',
draftDesc: '您的商品已保存为草稿。\n您可以继续编辑或稍后在“我的商品”中发布。', draftDesc: '您的商品已保存为草稿。\n您可以继续编辑或稍后在“我的商品”中发布。',
listingLive:'商品已上架', listingLive: '商品已上架',
publishDesc:'您的商品现已上架。\n买家可以浏览并购买您的设计。' publishDesc: '您的商品现已上架。\n买家可以浏览并购买您的设计。'
}, },
Seller: { Seller: {
// Brand Profile // Brand Profile
@@ -1835,6 +1836,7 @@ export default {
draftMessage: '商品已保存为草稿。您可以继续编辑,或稍后在“我的商品”中发布。', draftMessage: '商品已保存为草稿。您可以继续编辑,或稍后在“我的商品”中发布。',
publishMessage: '商品现已上架。买家可以浏览并购买您的设计。', publishMessage: '商品现已上架。买家可以浏览并购买您的设计。',
ActiveListings: '已发布商品', ActiveListings: '已发布商品',
Praka: '线稿',
Drafts: '草稿', Drafts: '草稿',
Cancel: '取消', Cancel: '取消',
Delete: '删除', Delete: '删除',
@@ -1854,5 +1856,36 @@ export default {
SelectCollection: '选择商品', SelectCollection: '选择商品',
SelectSketch: '选择线稿图', SelectSketch: '选择线稿图',
EditListingDetails: '编辑商品详情', EditListingDetails: '编辑商品详情',
VideoWarning: '首次选中的图片素材会作为产品主图,视频不可作为产品主图',
selectSketchMaxNum: '最多选择9个线稿图',
},
ApplySeller: {
applySellerTitle: '申请成为卖家',
applySellerDesc: '加入Stylish Parade开始销售您的设计作品',
formTitle: '店铺信息',
formTip: '请提供一些详细信息来创建您的卖家资料。',
termsTitle: '服务条款',
termsTip: '请阅读并同意服务条款。',
agreementTitle: 'AiDA 卖家协议',
agreementTip: '请阅读并同意卖家协议。',
agreementItem1: '提供准确和真实的个人信息和店铺信息',
agreementItem2: '仅销售原创设计或内容,获得必要的许可证',
agreementItem3: '维护所有产品的高质量标准',
agreementItem4: '在48小时内回复客户咨询',
agreementItem5: '在承诺的时间内发货',
agreementItem6: '遵守AiDA的服务条款和社区指南',
agreementItem7: '支付适用的平台费用和交易费用',
agreementItem8: '专业和公平地处理客户纠纷',
agreementAgreement: '我已经阅读并同意了卖家协议,清楚地了解了自己在 AiDA 平台上作为卖家所应承担的责任和义务。',
submitApplication: '提交申请',
applicationSubmitted: '申请已提交',
applicationSubmittedTip: '预计很快就会批准。收到批准后,请在发布任何商品前,确保在 <span>卖家控制面板 > 设置</span> 中关联您的收款账户。',
auditStatus1_title: "步骤 1提交申请",
auditStatus1_tip: "请填写店铺信息并同意服务条款。",
auditStatus2_title: "步骤 2审核验证",
auditStatus2_tip: "我们的团队将在审核您的申请后1-3个工作日审核您的店铺信息。",
auditStatus3_title: "步骤 3开始销售",
auditStatus3_tip: "审核通过后,您可以开始销售您的商品。",
backToHomepage: "返回首页",
} }
} }

View File

@@ -24,6 +24,7 @@ export default {
SubscribeNow: 'Subscribe now', SubscribeNow: 'Subscribe now',
TaskList: 'Task List', TaskList: 'Task List',
ViewOrders: 'View Orders', ViewOrders: 'View Orders',
PersonalCenter: 'Personal Center',
BecomeSeller: 'Become a Seller', BecomeSeller: 'Become a Seller',
SellerDashboard: 'Seller Dashboard', SellerDashboard: 'Seller Dashboard',
toolsToProduct: 'To product image', toolsToProduct: 'To product image',
@@ -1795,7 +1796,7 @@ export default {
cover:'Cover', cover:'Cover',
productImageDesc:'Choose from product image', productImageDesc:'Choose from product image',
cropDesc:'Crop from main product image or sketch', cropDesc:'Crop from main product image or sketch',
productImageMainTitle:'Product Image ', productImageMainTitle:'Product Media ',
productImageSubTitle:'(from design collection)', productImageSubTitle:'(from design collection)',
apparelSketchTitle:'Apparel Sketch ', apparelSketchTitle:'Apparel Sketch ',
apparelSketchSubTitle:'(from design collection)', apparelSketchSubTitle:'(from design collection)',
@@ -1889,6 +1890,7 @@ export default {
draftMessage: 'Product moved to drafts and stats reset.', draftMessage: 'Product moved to drafts and stats reset.',
publishMessage: 'Item is now live on the Marketplace.', publishMessage: 'Item is now live on the Marketplace.',
ActiveListings: 'Active Listings', ActiveListings: 'Active Listings',
Praka: 'Praka',
Drafts: 'Drafts', Drafts: 'Drafts',
Cancel: 'Cancel', Cancel: 'Cancel',
Delete: 'Delete', Delete: 'Delete',
@@ -1908,5 +1910,36 @@ export default {
SelectCollection: 'Select Collection', SelectCollection: 'Select Collection',
SelectSketch: 'Select Sketch', SelectSketch: 'Select Sketch',
EditListingDetails: 'Edit Listing Details', EditListingDetails: 'Edit Listing Details',
VideoWarning:'The first selected item is the main product image. Videos cannot be used.',
selectSketchMaxNum: 'Select up to 9 sketches',
},
ApplySeller: {
applySellerTitle: 'Apply to Become a Seller',
applySellerDesc: 'Join the Stylish Parade and start selling your design work',
formTitle: 'Brand Information',
formTip: 'Share a few details to set up your seller profile',
termsTitle: 'Seller Terms',
termsTip: 'Please carefully read and agree to the following terms',
agreementTitle: 'AiDA Seller Agreement',
agreementTip: 'Please read and agree to the following agreement',
agreementItem1: "Provide accurate and truthful personal and store information",
agreementItem2: "Only sell original designs or content with proper licensing",
agreementItem3: "Maintain high quality standards for all products",
agreementItem4: "Respond to customer inquiries within 48 hours",
agreementItem5: "Ship orders within promised timeframes",
agreementItem6: "Comply with AiDA's terms of service and community guidelines",
agreementItem7: "Pay applicable platform fees and transaction charges",
agreementItem8: "Handle customer disputes professionally and fairly",
agreementAgreement: "I have read and agree to the Seller Agreement, understanding my responsibilities and obligations as a seller on the AiDA platform.",
submitApplication: "Submit Application",
applicationSubmitted: "Application Submitted",
applicationSubmittedTip: "Approval is expected shortly. Upon receipt, please ensure your payout account is linked under <span>Seller Dashboard > Settings</span> prior to listing any items.",
auditStatus1_title: "Step 1: Submit Application",
auditStatus1_tip: "Fill out the seller information form and agree to our terms",
auditStatus2_title: "Step 2: Review & Verification",
auditStatus2_tip: "Our team will review your application (typically 1-3 business days)",
auditStatus3_title: "Step 3: Start Selling",
auditStatus3_tip: "Once approved, access your seller dashboard and start listing products",
backToHomepage: "Back to Homepage",
} }
} }

View File

@@ -224,8 +224,8 @@ const routes: Array<RouteRecordRaw> = [
name: "becomeSeller", name: "becomeSeller",
meta: { meta: {
enter: "all", enter: "all",
sellerHeaderTitle: "Apply to Become a Seller", sellerHeaderTitle: "ApplySeller.applySellerTitle",
sellerHeaderTip: "Join the Stylish Parade and start selling your design work" sellerHeaderTip: "ApplySeller.applySellerDesc"
}, },
component: () => import("@/views/SellerDashboard/BecomeSeller/index.vue") component: () => import("@/views/SellerDashboard/BecomeSeller/index.vue")
}, },
@@ -235,6 +235,11 @@ const routes: Array<RouteRecordRaw> = [
meta: { enter: "all" }, meta: { enter: "all" },
component: () => import("@/views/SellerDashboard/index.vue"), component: () => import("@/views/SellerDashboard/index.vue"),
children: [ children: [
{
path: "",
meta: { enter: "all" },
redirect: "/home/seller/brandProfile"
},
{ {
path: "brandProfile", path: "brandProfile",
name: "brandProfile", name: "brandProfile",
@@ -283,7 +288,7 @@ const routes: Array<RouteRecordRaw> = [
name: "myListingsSelectItem", name: "myListingsSelectItem",
meta: { meta: {
enter: "all", enter: "all",
sellerHeaderTitleKey: "Seller.SelectCollection", sellerHeaderTitleKey: "Seller.SelectSketch",
sellerBreadcrumbs: [ sellerBreadcrumbs: [
myListingsBreadcrumb, myListingsBreadcrumb,
selectCollectionBreadcrumb, selectCollectionBreadcrumb,

View File

@@ -138,331 +138,331 @@ axios.interceptors.response.use(
export const Https = { export const Https = {
httpUrls: { httpUrls: {
interfaceUrl: '', interfaceUrl: '',
parseGoogleCredential: '/api/third/party/parseGoogleCredential', //谷歌登录注册 parseGoogleCredential: '/aida/api/third/party/parseGoogleCredential', //谷歌登录注册
parseWeChatCode: '/api/third/party/parseWeChatCode', //微信登录 parseWeChatCode: '/aida/api/third/party/parseWeChatCode', //微信登录
accountIsLogin: '/api/account/isLogin', //判断用户是否登录 accountIsLogin: '/aida/api/account/isLogin', //判断用户是否登录
accountLogin: `/api/account/login`, //账号密码登录接口 accountLogin: `/aida/api/account/login`, //账号密码登录接口
organizationNameSearch: `/api/account/organizationNameSearch`, //查询学校或者企业版名字 organizationNameSearch: `/aida/api/account/organizationNameSearch`, //查询学校或者企业版名字
getUserLanguage: `/api/account/getUserLanguage`, //获取当前用户语言 getUserLanguage: `/aida/api/account/getUserLanguage`, //获取当前用户语言
changeUserLanguage: `/api/account/changeUserLanguage`, //切换用户当前语言 changeUserLanguage: `/aida/api/account/changeUserLanguage`, //切换用户当前语言
uploadAvatar: `/api/account/uploadAvatar`, //修改头像 uploadAvatar: `/aida/api/account/uploadAvatar`, //修改头像
editUserName: `/api/account/editUserName`, //修改用户名 editUserName: `/aida/api/account/editUserName`, //修改用户名
updateUserInfo: `/api/account/updateUserInfo`, //修改国家职业 updateUserInfo: `/aida/api/account/updateUserInfo`, //修改国家职业
accountDetail: `/api/account/getAccountDetail`, //用户详细信息 accountDetail: `/aida/api/account/getAccountDetail`, //用户详细信息
trialUserLogout: `/api/account/trialUserLogout`, //试用用户退出登录接口 trialUserLogout: `/aida/api/account/trialUserLogout`, //试用用户退出登录接口
completeGuidancet: `/api/account/completeGuidance`, //用户指引结束 completeGuidancet: `/aida/api/account/completeGuidance`, //用户指引结束
getExpiredTime: `/api/account/getExpiredTime`, //获取用户到期时间 getExpiredTime: `/aida/api/account/getExpiredTime`, //获取用户到期时间
addNoLoginRequired: `/api/third/party/addNoLoginRequired`, //机房用户注册 addNoLoginRequired: `/aida/api/third/party/addNoLoginRequired`, //机房用户注册
deleteNoLoginRequired: `/api/third/party/deleteNoLoginRequired`, //机房用户注销 deleteNoLoginRequired: `/aida/api/third/party/deleteNoLoginRequired`, //机房用户注销
noLoginRequired: `/api/account/noLoginRequired`, //机房用户登录 noLoginRequired: `/aida/api/account/noLoginRequired`, //机房用户登录
existNoLoginRequired: `/api/third/party/existNoLoginRequired`, //获取唯一标识是否存在 existNoLoginRequired: `/aida/api/third/party/existNoLoginRequired`, //获取唯一标识是否存在
deleteNoLoginRequiredNew: `/api/third/party/deleteNoLoginRequiredNew`, //机房用户注销 deleteNoLoginRequiredNew: `/aida/api/third/party/deleteNoLoginRequiredNew`, //机房用户注销
addNoLoginRequiredNew: `/api/third/party/addNoLoginRequiredNew`, //机房用户注册 addNoLoginRequiredNew: `/aida/api/third/party/addNoLoginRequiredNew`, //机房用户注册
updateNoLoginRequiredNew: `/api/third/party/updateNoLoginRequiredNew`, //机房用户更新 updateNoLoginRequiredNew: `/aida/api/third/party/updateNoLoginRequiredNew`, //机房用户更新
endpoint: `/api/third/party/your-secured-endpoint`, //获取唯一标识是否存在 endpoint: `/aida/api/third/party/your-secured-endpoint`, //获取唯一标识是否存在
designWorksRegister: '/api/account/designWorksRegister', //注册 designWorksRegister: '/aida/api/account/designWorksRegister', //注册
designWorksRegisterCode: '/api/account/designWorksRegisterCode', //注册 designWorksRegisterCode: '/aida/api/account/designWorksRegisterCode', //注册
preLogin: '/api/account/preLogin', //预先登入 preLogin: '/aida/api/account/preLogin', //预先登入
schoolLogin: '/api/account/schoolLogin', //学校管理员登录 schoolLogin: '/aida/api/account/schoolLogin', //学校管理员登录
enterpriseLogin: '/api/account/enterpriseLogin', //企业管理员登录 enterpriseLogin: '/aida/api/account/enterpriseLogin', //企业管理员登录
accountSendEmail: `/api/account/sendEmail`, //发送邮件 accountSendEmail: `/aida/api/account/sendEmail`, //发送邮件
accountResetPwd: '/api/account/resetPwd', //忘记密码修改 accountResetPwd: '/aida/api/account/resetPwd', //忘记密码修改
accountLogout: '/api/account/logout', //登出 accountLogout: '/aida/api/account/logout', //登出
accountBindEmail: '/api/account/bindEmail', //绑定邮箱 accountBindEmail: '/aida/api/account/bindEmail', //绑定邮箱
bindGoogle: '/api/account/bindGoogle', //绑定谷歌 bindGoogle: '/aida/api/account/bindGoogle', //绑定谷歌
bindWeChat: '/api/account/bindWeChat', //绑定微信 bindWeChat: '/aida/api/account/bindWeChat', //绑定微信
unbindGoogle: `/api/account/unbindGoogle`, //取消绑定谷歌 unbindGoogle: `/aida/api/account/unbindGoogle`, //取消绑定谷歌
unbindWeChat: '/api/account/unbindWeChat', //取消绑定微信 unbindWeChat: '/aida/api/account/unbindWeChat', //取消绑定微信
elementGeneratePrint: '/api/element/generatePrint', //生成印花 elementGeneratePrint: '/aida/api/element/generatePrint', //生成印花
elementSavePrint: '/api/element/savePrint', //保存印花 elementSavePrint: '/aida/api/element/savePrint', //保存印花
getRgbByTcx: '/api/element/getRgbByTcx', // 通过hsv值获取潘通信息 getRgbByTcx: '/aida/api/element/getRgbByTcx', // 通过hsv值获取潘通信息
getRgbByHsv: '/api/element/getRgbByHsv', //通过hsv值获取潘通信息 getRgbByHsv: '/aida/api/element/getRgbByHsv', //通过hsv值获取潘通信息
elementDelete: '/api/element/delete', //删除上传的图片 elementDelete: '/aida/api/element/delete', //删除上传的图片
designCollection: `/api/design/designCollection`, //设计 Conllection designCollection: `/aida/api/design/designCollection`, //设计 Conllection
reDesignCollection: `/api/design/reDesignCollection`, //重新设计 Conllection reDesignCollection: `/aida/api/design/reDesignCollection`, //重新设计 Conllection
countDesignProcess: '/api/design/countDesignProcess', //统计design进度 countDesignProcess: '/aida/api/design/countDesignProcess', //统计design进度
getDesignResult: '/api/design/getDesignResult', //查询design结果 getDesignResult: '/aida/api/design/getDesignResult', //查询design结果
designSort: `/api/design/sort`, //design排序 designSort: `/aida/api/design/sort`, //design排序
collectionLikeUpdate: `/api/history/collectionLikeUpdate`, //赋值排序 collectionLikeUpdate: `/aida/api/history/collectionLikeUpdate`, //赋值排序
designProcess: `/api/design/designProcess`, //统计design进度 designProcess: `/aida/api/design/designProcess`, //统计design进度
designGetModel: `/api/design/getModel`, //导出获取模特链接 designGetModel: `/aida/api/design/getModel`, //导出获取模特链接
//充值相关 //充值相关
productList: `/api/product/list`, //获取商品列表 productList: `/aida/api/product/list`, //获取商品列表
payAlipay: `/api/ali-pay/trade/page/pay`, //支付宝确认支付 payAlipay: `/aida/api/ali-pay/trade/page/pay`, //支付宝确认支付
payAlipayHK: `/api/alipay-hk/createOrder`, //香港支付宝确认支付 payAlipayHK: `/aida/api/alipay-hk/createOrder`, //香港支付宝确认支付
payStripe: `/api/stripe/createOrder`, //Stripe支付 payStripe: `/aida/api/stripe/createOrder`, //Stripe支付
payPaypal: `/api/paypal/trade`, //paypal确认支付 payPaypal: `/aida/api/paypal/trade`, //paypal确认支付
getCredits: `/api/credits/getCredits`, //查询用户积分 getCredits: `/aida/api/credits/getCredits`, //查询用户积分
cancelSubscription: `/api/stripe/cancelSubscription`, //取消订阅 cancelSubscription: `/aida/api/stripe/cancelSubscription`, //取消订阅
orderInfoList: `/api/order-info/list`, //查询订单列表 orderInfoList: `/aida/api/order-info/list`, //查询订单列表
getCreditsDetail: `/api/credits/getCreditsDetail`, //查询积分列表 getCreditsDetail: `/aida/api/credits/getCreditsDetail`, //查询积分列表
tradeRefundAlipay: `/api/ali-pay/trade/refund`, //支付宝退款 tradeRefundAlipay: `/aida/api/ali-pay/trade/refund`, //支付宝退款
tradeRefundPaypal: `/api/paypal/trade/refund`, //paypal退款 tradeRefundPaypal: `/aida/api/paypal/trade/refund`, //paypal退款
tradeQuery: `/api/ali-pay/trade/query/{orderNo}`, //查询订单状态 tradeQuery: `/aida/api/ali-pay/trade/query/{orderNo}`, //查询订单状态
getRgbByHsvBatch: `/api/element/getRgbByHsvBatch`, //通过hsv值数组批量获取潘通信息 getRgbByHsvBatch: `/aida/api/element/getRgbByHsvBatch`, //通过hsv值数组批量获取潘通信息
designLike: `/api/design/like`, //Design Like designLike: `/aida/api/design/like`, //Design Like
designDislike: `/api/design/dislike`, //Design Dislike designDislike: `/aida/api/design/dislike`, //Design Dislike
queryUserGroup: `/api/history/queryUserGroup`, //History用户分页分组列表 queryUserGroup: `/aida/api/history/queryUserGroup`, //History用户分页分组列表
deleteUserGroup: `/api/history/deleteUserGroup`, //History删除用户分组 deleteUserGroup: `/aida/api/history/deleteUserGroup`, //History删除用户分组
updateUserGroupName: `/api/history/updateUserGroupName`, //History修改用户分组名 updateUserGroupName: `/aida/api/history/updateUserGroupName`, //History修改用户分组名
projectSaveOrUpdate: `/api/project/saveOrUpdate`, //History修改用户分组名 projectSaveOrUpdate: `/aida/api/project/saveOrUpdate`, //History修改用户分组名
historyChoose: `/api/history/choose`, //History choose historyChoose: `/aida/api/history/choose`, //History choose
getDesignDetail: `/api/design/detail/getDetail`, //查询design详情 getDesignDetail: `/aida/api/design/detail/getDetail`, //查询design详情
addSysSketchToLibrary: `/api/library/addSysSketchToLibrary`, //把系统衣服添加的library addSysSketchToLibrary: `/aida/api/library/addSysSketchToLibrary`, //把系统衣服添加的library
designSingleWithGradient: `/api/design/detail/designSingleWithGradient`, //查询需要更新mask列表 designSingleWithGradient: `/aida/api/design/detail/designSingleWithGradient`, //查询需要更新mask列表
getNextSysElement: '/api/design/detail/getNextSysElement', //切换系统的element getNextSysElement: '/aida/api/design/detail/getNextSysElement', //切换系统的element
detailPrintDot: '/api/design/detail/printDot', //print打点预览 detailPrintDot: '/aida/api/design/detail/printDot', //print打点预览
designSingle: `/api/design/detail/designSingle`, //单个design designSingle: `/aida/api/design/detail/designSingle`, //单个design
queryLibraryPage: `/api/library/queryLibraryPage`, //Library分页列表 queryLibraryPage: `/aida/api/library/queryLibraryPage`, //Library分页列表
libraryUpload: `/api/library/upload`, // Library文件上传 libraryUpload: `/aida/api/library/upload`, // Library文件上传
setSketchLibrary: `/api/library/updateLibraryLevel2Type`, // 修改图片类型 setSketchLibrary: `/aida/api/library/updateLibraryLevel2Type`, // 修改图片类型
updateElementLevel2Type: `/api/element/updateElementLevel2Type`, // 修改拼贴上传的衣服类型 updateElementLevel2Type: `/aida/api/element/updateElementLevel2Type`, // 修改拼贴上传的衣服类型
queryClassification: `/api/classification/queryClassification`, //标签类别查询 queryClassification: `/aida/api/classification/queryClassification`, //标签类别查询
classificationSaveOrUpdate: `/api/classification/saveOrUpdate`, //标签类别新增修改 classificationSaveOrUpdate: `/aida/api/classification/saveOrUpdate`, //标签类别新增修改
classificationDelete: `/api/classification/delete`, //标签类别新增修改 classificationDelete: `/aida/api/classification/delete`, //标签类别新增修改
relationLibrary: `/api/classification/relationLibrary`, //标签类别新增修改 relationLibrary: `/aida/api/classification/relationLibrary`, //标签类别新增修改
getRelClassificationIdList: `/api/classification/getRelClassificationIdList`, //标签类别新增修改 getRelClassificationIdList: `/aida/api/classification/getRelClassificationIdList`, //标签类别新增修改
getRelPublicClassificationIdList: `/api/classification/getRelPublicClassificationIdList`, //多选获取公共标签 getRelPublicClassificationIdList: `/aida/api/classification/getRelPublicClassificationIdList`, //多选获取公共标签
editRelPublicClassificationIdList: `/api/classification/editRelPublicClassificationIdList`, //多选修改公共标签 editRelPublicClassificationIdList: `/aida/api/classification/editRelPublicClassificationIdList`, //多选修改公共标签
//模块化 //模块化
llmStream: `/api/llm/streamNew`, //聊天 llmStream: `/aida/api/llm/streamNew`, //聊天
// llmStream:`/api/llm/stream`,//聊天 // llmStream:`/aida/api/llm/stream`,//聊天
chatCreateProject: `/api/llm/chatCreateProject`, //聊天创建项目 chatCreateProject: `/aida/api/llm/chatCreateProject`, //聊天创建项目
getChatHistory: `/api/llm/getChatHistory`, //获取聊天历史记录 getChatHistory: `/aida/api/llm/getChatHistory`, //获取聊天历史记录
llmUploadFile: `/api/llm/uploadFile`, //聊天上传文件 llmUploadFile: `/aida/api/llm/uploadFile`, //聊天上传文件
saveOrUpdate: `/api/project/saveOrUpdate`, //模块化新增修改 saveOrUpdate: `/aida/api/project/saveOrUpdate`, //模块化新增修改
getModuleContent: `/api/project/getModuleContent`, //获取模块内容 getModuleContent: `/aida/api/project/getModuleContent`, //获取模块内容
saveModuleContent: `/api/project/saveModuleContent`, //储存模块内容 saveModuleContent: `/aida/api/project/saveModuleContent`, //储存模块内容
historyProject: `/api/project/page`, //项目记录 historyProject: `/aida/api/project/page`, //项目记录
projectDetail: `/api/project/delete`, //删除项目 projectDetail: `/aida/api/project/delete`, //删除项目
//3d //3d
threeDPage: `/api/project/threeDPage`, threeDPage: `/aida/api/project/threeDPage`,
downloadZip: `/api/project/downloadZip`, //下载zip downloadZip: `/aida/api/project/downloadZip`, //下载zip
getThreeDSize: `/api/project/getThreeDSize`, //下载列表 getThreeDSize: `/aida/api/project/getThreeDSize`, //下载列表
getLayoutDetail: `/api/project/getLayoutDetail`, //获取3d详情 getLayoutDetail: `/aida/api/project/getLayoutDetail`, //获取3d详情
getThreeDGlb: `/api/project/getThreeDGlb`, getThreeDGlb: `/aida/api/project/getThreeDGlb`,
selectHistoryProject: `/api/project/choose`, //选择项目 selectHistoryProject: `/aida/api/project/choose`, //选择项目
getMannequinDetail: `/api/project/getMannequinDetail`, //模块化查看模特点位 getMannequinDetail: `/aida/api/project/getMannequinDetail`, //模块化查看模特点位
modifyProportion: `/api/generate/modifyProportion`, //模特拉伸 modifyProportion: `/aida/api/generate/modifyProportion`, //模特拉伸
addSysModelToLib: `/api/library/addSysModelToLib`, addSysModelToLib: `/aida/api/library/addSysModelToLib`,
poselikeOrDisike: `/api/generate/likeOrDislike`, //postTransform like poselikeOrDisike: `/aida/api/generate/likeOrDislike`, //postTransform like
getAllPose: `/api/generate/getAllPose`, //获取动作 getAllPose: `/aida/api/generate/getAllPose`, //获取动作
//拼贴 //拼贴
genSketchRecon: `/api/generate/genSketchRecon`, genSketchRecon: `/aida/api/generate/genSketchRecon`,
saveReconCanvas: `/api/generate/saveReconCanvas`, saveReconCanvas: `/aida/api/generate/saveReconCanvas`,
//动作变换 //动作变换
poseTransform: `/api/generate/poseTransform`, poseTransform: `/aida/api/generate/poseTransform`,
poseTransformResult: `/api/generate/poseTransformResult`, poseTransformResult: `/aida/api/generate/poseTransformResult`,
batchUpdateLibraryName: '/api/library/batchUpdateLibraryName', //Library修改用户文件名 batchUpdateLibraryName: '/aida/api/library/batchUpdateLibraryName', //Library修改用户文件名
batchDeleteLibrary: '/api/library/batchDeleteLibrary', //删除library batchDeleteLibrary: '/aida/api/library/batchDeleteLibrary', //删除library
queryLibraryTopAndBottomPage: '/api/library/queryLibraryTopAndBottomPage', //Library分页列表(查询top和bottom) queryLibraryTopAndBottomPage: '/aida/api/library/queryLibraryTopAndBottomPage', //Library分页列表(查询top和bottom)
saveOrEditTemplatePoint: '/api/library/saveOrEditTemplatePoint', //保存或者编辑template打点 saveOrEditTemplatePoint: '/aida/api/library/saveOrEditTemplatePoint', //保存或者编辑template打点
libraryModelsDot: '/api/library/modelsDot', //Models打点预览 libraryModelsDot: '/aida/api/library/modelsDot', //Models打点预览
chatStreamTest: `/api/python/chatStream`, //机器人助力 chatStreamTest: `/aida/api/python/chatStream`, //机器人助力
pictureLikeOrUnLike: `/api/python/pictureLikeOrUnLike`, //机器人生成图喜欢 pictureLikeOrUnLike: `/aida/api/python/pictureLikeOrUnLike`, //机器人生成图喜欢
getBloodBars: `/api/python/getBloodBars`, //机器人血条 getBloodBars: `/aida/api/python/getBloodBars`, //机器人血条
//工作空间 //工作空间
workspaceDetail: `/api/workspace/detail`, //用户习惯详情 workspaceDetail: `/aida/api/workspace/detail`, //用户习惯详情
workspaceenumValues: `/api/workspace/enumValues`, //getSex workspaceenumValues: `/aida/api/workspace/enumValues`, //getSex
workspaceRemove: `/api/workspace/remove`, //删除用户习惯详情 workspaceRemove: `/aida/api/workspace/remove`, //删除用户习惯详情
workspacesaveOrUpdate: `/api/workspace/saveOrUpdate`, //修改用户习惯详情 workspacesaveOrUpdate: `/aida/api/workspace/saveOrUpdate`, //修改用户习惯详情
getMannequins: `/api/workspace/getMannequins`, //模特 getMannequins: `/aida/api/workspace/getMannequins`, //模特
getStyleList: `/api/workspace/styleList`, //获取所有风格列表 getStyleList: `/aida/api/workspace/styleList`, //获取所有风格列表
workspaceList: `/api/workspace/list`, workspaceList: `/aida/api/workspace/list`,
sketchAndPrintGenerate: '/api/generate/sketchAndPrint', //sketchGenerate生成图片 sketchAndPrintGenerate: '/aida/api/generate/sketchAndPrint', //sketchGenerate生成图片
generatePrepare: '/api/generate/prepare', //开始生成generate图片 generatePrepare: '/aida/api/generate/prepare', //开始生成generate图片
generateStopWaiting: '/api/generate/stopWaiting', //取消生成 generateStopWaiting: '/aida/api/generate/stopWaiting', //取消生成
generateResult: '/api/generate/result', //获取生成结果 generateResult: '/aida/api/generate/result', //获取生成结果
generateLike: '/api/generate/like', //喜欢ganerate图片 generateLike: '/aida/api/generate/like', //喜欢ganerate图片
generateDislike: '/api/generate/dislike', //喜欢ganerate图片 generateDislike: '/aida/api/generate/dislike', //喜欢ganerate图片
imageToSketch: '/api/generate/imageToSketch', //成品图转为线稿 imageToSketch: '/aida/api/generate/imageToSketch', //成品图转为线稿
modifySketch: '/api/generate/modifySketch', //修改画布内容并且储存 modifySketch: '/aida/api/generate/modifySketch', //修改画布内容并且储存
elementUpload: `/api/element/upload`, //上传图片 elementUpload: `/aida/api/element/upload`, //上传图片
imageSegmentation: `/api/element/imageSegmentation`, //分割衣服 imageSegmentation: `/aida/api/element/imageSegmentation`, //分割衣服
convertRelightElement: `/api/history/convertRelightElement`, //toproduct复制到上传图片位置 convertRelightElement: `/aida/api/history/convertRelightElement`, //toproduct复制到上传图片位置
// oldHis:`/oldHis/history/queryUserGroup`,//上传图片 // oldHis:`/oldHis/history/queryUserGroup`,//上传图片
sketchBoardsBoundingBox: `/api/design/sketchBoardsBoundingBox`, //裁剪sketch图片 sketchBoardsBoundingBox: `/aida/api/design/sketchBoardsBoundingBox`, //裁剪sketch图片
trialOrderList: `/api/account/trialOrderList`, //获取审批列表 trialOrderList: `/aida/api/account/trialOrderList`, //获取审批列表
switchIsAutoApproval: `/api/account/switchIsAutoApproval`, //切换是否自动审批 switchIsAutoApproval: `/aida/api/account/switchIsAutoApproval`, //切换是否自动审批
getIsAutoApproval: `/api/account/getIsAutoApproval`, //获取是否自动审批 getIsAutoApproval: `/aida/api/account/getIsAutoApproval`, //获取是否自动审批
trialOrderApproval: `/api/account/trialOrderApproval`, //通过审批 trialOrderApproval: `/aida/api/account/trialOrderApproval`, //通过审批
trialOrderRefuse: `/api/account/trialOrderRefuse`, //拒绝审批 trialOrderRefuse: `/aida/api/account/trialOrderRefuse`, //拒绝审批
//管理员接口 //管理员接口
//查询所有试用用户 //查询所有试用用户
inquiryGetTrial: `/api/inquiry/getTrial`, //查询所有试用用户 inquiryGetTrial: `/aida/api/inquiry/getTrial`, //查询所有试用用户
getCities: `/api/inquiry/getCities`, //获取所有付款订单使用的国家 getCities: `/aida/api/inquiry/getCities`, //获取所有付款订单使用的国家
getUserInfo: `/api/inquiry/getUserInfo`, //查询所有用户 getUserInfo: `/aida/api/inquiry/getUserInfo`, //查询所有用户
queryTransaction: `/api/inquiry/queryTransaction`, //查询交易记录 queryTransaction: `/aida/api/inquiry/queryTransaction`, //查询交易记录
queryTransactionDownload: `/api/inquiry/queryTransaction/download`, //导出交易记录 queryTransactionDownload: `/aida/api/inquiry/queryTransaction/download`, //导出交易记录
createCoupon: `/api/stripe/createCoupon`, //创建优惠码 createCoupon: `/aida/api/stripe/createCoupon`, //创建优惠码
updatePromCodeInfo: `/api/stripe/updatePromCodeInfo`, //修改优惠码 updatePromCodeInfo: `/aida/api/stripe/updatePromCodeInfo`, //修改优惠码
getAllCoupons: `/api/stripe/getAllCoupons`, //查询优惠码列表 getAllCoupons: `/aida/api/stripe/getAllCoupons`, //查询优惠码列表
checkCoupon: `/api/stripe/checkCoupon`, //根据优惠码获取结算后的金额 checkCoupon: `/aida/api/stripe/checkCoupon`, //根据优惠码获取结算后的金额
deletePromCode: `/api/stripe/deletePromCode`, //删除优惠券 deletePromCode: `/aida/api/stripe/deletePromCode`, //删除优惠券
addOrganization: `/api/inquiry/addOrganization`, //添加企业版或者教育版 addOrganization: `/aida/api/inquiry/addOrganization`, //添加企业版或者教育版
queryOrganization: `/api/inquiry/queryOrganization`, //查询企业版或者教育版 queryOrganization: `/aida/api/inquiry/queryOrganization`, //查询企业版或者教育版
createSubscribePlan: '/api/subscription_plan/createPlan', // 创建订阅计划 createSubscribePlan: '/aida/api/subscription_plan/createPlan', // 创建订阅计划
deleteSubscribePlan: '/api/subscription_plan/deletePlan', // 删除订阅计划 deleteSubscribePlan: '/aida/api/subscription_plan/deletePlan', // 删除订阅计划
updateSubscribePlan: '/api/subscription_plan/updatePlan', // 修改订阅计划 updateSubscribePlan: '/aida/api/subscription_plan/updatePlan', // 修改订阅计划
searchAllSubscribePlan: '/api/subscription_plan/searchByPage', // 分页查询所有订阅计划 searchAllSubscribePlan: '/aida/api/subscription_plan/searchByPage', // 分页查询所有订阅计划
searchSubscribeByOrg: '/api/subscription_plan/searchByOrganizationIdAndStatus', // 不分页查询 searchSubscribeByOrg: '/aida/api/subscription_plan/searchByOrganizationIdAndStatus', // 不分页查询
switchSubscribePlan: '/api/subscription_plan/switchSubscriptionPlan', // 切换管理员订阅计划 switchSubscribePlan: '/aida/api/subscription_plan/switchSubscriptionPlan', // 切换管理员订阅计划
switchSubAccountSubscribePlan: switchSubAccountSubscribePlan:
'/api/subscription_plan/switchSubAccSubscriptionPlan', // 切换子账号订阅计划 '/aida/api/subscription_plan/switchSubAccSubscriptionPlan', // 切换子账号订阅计划
//云生成 //云生成
designCloud: `/api/design/designCloud`, //创建云生成 designCloud: `/aida/api/design/designCloud`, //创建云生成
cloudPage: `/api/design/cloudPage`, //创建云生成 cloudPage: `/aida/api/design/cloudPage`, //创建云生成
cloudTaskDelete: `/api/design/cloudTaskDelete`, //删除云生成 cloudTaskDelete: `/aida/api/design/cloudTaskDelete`, //删除云生成
cloudTaskNameUpdate: `/api/design/cloudTaskNameUpdate`, //修改云生成名字 cloudTaskNameUpdate: `/aida/api/design/cloudTaskNameUpdate`, //修改云生成名字
getDesignCloudResult: `/api/design/getDesignCloudResult`, //查询这条云生成记录的所有内容 getDesignCloudResult: `/aida/api/design/getDesignCloudResult`, //查询这条云生成记录的所有内容
//企业版教育版管理员页面 //企业版教育版管理员页面
subAccountList: `/api/account/subAccountList`, //查询子账号 subAccountList: `/aida/api/account/subAccountList`, //查询子账号
addOrUpdateSubAccount: `/api/account/addOrUpdateSubAccount`, //添加子账号 addOrUpdateSubAccount: `/aida/api/account/addOrUpdateSubAccount`, //添加子账号
deleteSubAccount: `/api/account/deleteSubAccount`, //删除子账号 deleteSubAccount: `/aida/api/account/deleteSubAccount`, //删除子账号
subAccountImportExcelDownload: `/api/account/subAccountImportExcelDownload`, //批量添加模板下载模板 subAccountImportExcelDownload: `/aida/api/account/subAccountImportExcelDownload`, //批量添加模板下载模板
exportAccountsToExcel: `/api/account/exportAccountsToExcel`, //教育版导出用户数据 exportAccountsToExcel: `/aida/api/account/exportAccountsToExcel`, //教育版导出用户数据
getNextSequence: `/api/project/getNextSequence`, //批量添加模板下载模板 getNextSequence: `/aida/api/project/getNextSequence`, //批量添加模板下载模板
subAccountImport: `/api/account/subAccountImport`, //模板导入 subAccountImport: `/aida/api/account/subAccountImport`, //模板导入
getGenerateFrequency: `/api/inquiry/getGenerateFrequency`, //积分使用详情 getGenerateFrequency: `/aida/api/inquiry/getGenerateFrequency`, //积分使用详情
getAllGenerateFuncName: `/api/inquiry/getAllGenerateFuncName`, //获取所有generate类型 getAllGenerateFuncName: `/aida/api/inquiry/getAllGenerateFuncName`, //获取所有generate类型
//查询某个时间内design点击次数 //查询某个时间内design点击次数
getDesignStatistic: `/api/inquiry/getDesignStatistic`, //拒绝审批 getDesignStatistic: `/aida/api/inquiry/getDesignStatistic`, //拒绝审批
getAllQuestionnaire: `/api/inquiry/getAllQuestionnaire`, //拒绝审批 getAllQuestionnaire: `/aida/api/inquiry/getAllQuestionnaire`, //拒绝审批
getActiveUserFunc: `/api/inquiry/getActiveUserFunc`, //获取各模块功能 getActiveUserFunc: `/aida/api/inquiry/getActiveUserFunc`, //获取各模块功能
toProductImageElementDelete: `/api/history/toProductImageElementDelete`, //删除指定模块上传的内容 toProductImageElementDelete: `/aida/api/history/toProductImageElementDelete`, //删除指定模块上传的内容
recentActiveUser: `/api/inquiry/recentActiveUser`, //获取近期活跃用户 recentActiveUser: `/aida/api/inquiry/recentActiveUser`, //获取近期活跃用户
recentActiveUserChart: `/api/inquiry/recentActiveUserChart`, //获取近期活跃用户图表数据 recentActiveUserChart: `/aida/api/inquiry/recentActiveUserChart`, //获取近期活跃用户图表数据
recentNewUser: `/api/inquiry/recentNewUser`, //获取近期新增用户 recentNewUser: `/aida/api/inquiry/recentNewUser`, //获取近期新增用户
recentNewUserChart: `/api/inquiry/recentNewUserChart`, //获取新增用户图表 recentNewUserChart: `/aida/api/inquiry/recentNewUserChart`, //获取新增用户图表
trialUserCountry: `/api/inquiry/trialUserCountry`, //试用用户国家-城市分布 trialUserCountry: `/aida/api/inquiry/trialUserCountry`, //试用用户国家-城市分布
conversionRate: `/api/inquiry/conversionRate`, //试用用户国家-城市分布 conversionRate: `/aida/api/inquiry/conversionRate`, //试用用户国家-城市分布
getAllUserId: `/api/inquiry/getAllUserId`, //获取所有用户id和Name getAllUserId: `/aida/api/inquiry/getAllUserId`, //获取所有用户id和Name
adminAddUser: `/api/inquiry/addUser`, //添加用户 adminAddUser: `/aida/api/inquiry/addUser`, //添加用户
modifyUser: `/api/inquiry/modifyUser`, //修改用户 modifyUser: `/aida/api/inquiry/modifyUser`, //修改用户
publishSysMessage: `/api/message/publishSysMessage`, //发布系统任务 publishSysMessage: `/aida/api/message/publishSysMessage`, //发布系统任务
//affiliate接口 //affiliate接口
viewsIncrease: `/api/affiliate/viewsIncrease`, //增加访问量 viewsIncrease: `/aida/api/affiliate/viewsIncrease`, //增加访问量
affiliateRegistration: `/api/affiliate/registration`, //affiliate注册 affiliateRegistration: `/aida/api/affiliate/registration`, //affiliate注册
personalCenter: `/api/affiliate/personalCenter`, //affiliate个人中心 personalCenter: `/aida/api/affiliate/personalCenter`, //affiliate个人中心
affiliateList: `/api/affiliate/list`, //affiliate审批列表 affiliateList: `/aida/api/affiliate/list`, //affiliate审批列表
updateCommission: `/api/affiliate/updateCommission`, //编辑佣金比例 updateCommission: `/aida/api/affiliate/updateCommission`, //编辑佣金比例
editAffiliate: `/api/affiliate/editAffiliate`, //编辑affiliate editAffiliate: `/aida/api/affiliate/editAffiliate`, //编辑affiliate
getEachAffiliateGeneratedRevenue: `/api/affiliate/getEachAffiliateGeneratedRevenue`, //affiliate每个用户根据日期查询收益 getEachAffiliateGeneratedRevenue: `/aida/api/affiliate/getEachAffiliateGeneratedRevenue`, //affiliate每个用户根据日期查询收益
affiliateApproval: `/api/affiliate/approval`, //affiliate同意 审批 affiliateApproval: `/aida/api/affiliate/approval`, //affiliate同意 审批
getPersonalMonthlyIncome: `/api/affiliate/getPersonalMonthlyIncome`, //affiliate图表接口 getPersonalMonthlyIncome: `/aida/api/affiliate/getPersonalMonthlyIncome`, //affiliate图表接口
getReferrals: `/api/affiliate/getReferrals`, //affiliate Referral列表 getReferrals: `/aida/api/affiliate/getReferrals`, //affiliate Referral列表
editReferral: `/api/affiliate/editReferral`, //affiliate编辑referral editReferral: `/aida/api/affiliate/editReferral`, //affiliate编辑referral
batchDeleteReferral: `/api/affiliate/batchDeleteReferral`, //affiliate删除referral batchDeleteReferral: `/aida/api/affiliate/batchDeleteReferral`, //affiliate删除referral
// batchDeleteReferral:`/api/affiliate/batchDeleteReferral`,//affiliate删除referral // batchDeleteReferral:`/aida/api/affiliate/batchDeleteReferral`,//affiliate删除referral
getTasksList: `/api/tasks/getList`, //获取w为执行完的所有任务 getTasksList: `/aida/api/tasks/getList`, //获取w为执行完的所有任务
getTasksHistory: `/api/tasks/getAllTask`, //获取所有任务列表 getTasksHistory: `/aida/api/tasks/getAllTask`, //获取所有任务列表
prepareForSR: `/api/python/prepareForSR`, //超分 prepareForSR: `/aida/api/python/prepareForSR`, //超分
//作品广场 //作品广场
publish: `/api/portfolio/publish`, //发布作品到作品广场 publish: `/aida/api/portfolio/publish`, //发布作品到作品广场
getPorfolio: `/api/portfolio/page`, //查询作品广场 getPorfolio: `/aida/api/portfolio/page`, //查询作品广场
getPorfolioDetail: `/api/portfolio/detail`, //查询作品广场作品详情 getPorfolioDetail: `/aida/api/portfolio/detail`, //查询作品广场作品详情
setPorfolioChoose: `/api/portfolio/choose`, //二次创作 setPorfolioChoose: `/aida/api/portfolio/choose`, //二次创作
portfolioLike: `/api/portfolio/like`, //作品广场点赞 portfolioLike: `/aida/api/portfolio/like`, //作品广场点赞
portfolioNoLike: `/api/portfolio/unlike`, //作品广场取消点赞 portfolioNoLike: `/aida/api/portfolio/unlike`, //作品广场取消点赞
portfolioComment: `/api/portfolio/comment`, //作品广场评论 portfolioComment: `/aida/api/portfolio/comment`, //作品广场评论
portfolioCommentPage: `/api/portfolio/commentPage`, //作品广场评论列表 portfolioCommentPage: `/aida/api/portfolio/commentPage`, //作品广场评论列表
commentDelete: `/api/portfolio/commentDelete`, //删除评论 commentDelete: `/aida/api/portfolio/commentDelete`, //删除评论
porfolioDelete: `/api/portfolio/delete`, //删除作品 porfolioDelete: `/aida/api/portfolio/delete`, //删除作品
porfolioFollow: `/api/portfolio/follow`, //删除作品 porfolioFollow: `/aida/api/portfolio/follow`, //删除作品
porfolioFollow: `/api/portfolio/follow`, //关注 porfolioFollow: `/aida/api/portfolio/follow`, //关注
porfolioCancelFollow: `/api/portfolio/cancelFollow`, //取消关注 porfolioCancelFollow: `/aida/api/portfolio/cancelFollow`, //取消关注
porfolioGetFolloweeList: `/api/portfolio/getFolloweeList`, //获取关注列表 porfolioGetFolloweeList: `/aida/api/portfolio/getFolloweeList`, //获取关注列表
porfolioGetFollowerList: `/api/portfolio/getFollowerList`, //获取粉丝列表 porfolioGetFollowerList: `/aida/api/portfolio/getFollowerList`, //获取粉丝列表
//product生成 //product生成
toProduct: `/api/history/toProduct`, //开始生成 toProduct: `/aida/api/history/toProduct`, //开始生成
toProductImageResult: `/api/history/toProductImageResult`, //获取结果 toProductImageResult: `/aida/api/history/toProductImageResult`, //获取结果
toProductImageElementUpload: `/api/history/toProductImageElementUpload`, //上传 toProductImageElementUpload: `/aida/api/history/toProductImageElementUpload`, //上传
historyDeleteResult: `/api/history/deleteResult`, //relight toproduct删除 historyDeleteResult: `/aida/api/history/deleteResult`, //relight toproduct删除
generateDeleteResult: `/api/generate/deleteResult`, //pose删除 generateDeleteResult: `/aida/api/generate/deleteResult`, //pose删除
productImageLike: `/api/history/productImageLike`, //like生成结果 productImageLike: `/aida/api/history/productImageLike`, //like生成结果
productImageUnLike: `/api/history/productImageUnLike`, //取消like生成结果 productImageUnLike: `/aida/api/history/productImageUnLike`, //取消like生成结果
productImageLikeList: `/api/history/productImageLikeList`, //like生成结果 productImageLikeList: `/aida/api/history/productImageLikeList`, //like生成结果
//打光 //打光
relight: `/api/history/relight`, //开始生成 relight: `/aida/api/history/relight`, //开始生成
relightResult: `/api/history/relightResult`, //开始生成 relightResult: `/aida/api/history/relightResult`, //开始生成
//保存画布 //保存画布
canvasElementUpload: `/api/history/canvasElementUpload`, //画布上传临时图片 canvasElementUpload: `/aida/api/history/canvasElementUpload`, //画布上传临时图片
exportSave: `/api/history/exportSave`, //保存画布 exportSave: `/aida/api/history/exportSave`, //保存画布
exportSearch: `/api/history/exportSearch`, //保存画布 exportSearch: `/aida/api/history/exportSearch`, //保存画布
//活动 //活动
activity: `/api/account/activity`, activity: `/aida/api/account/activity`,
//bradDNA //bradDNA
brandLogoUpload: `/api/history/brandLogoUpload`, //上传bradDNA brandLogoUpload: `/aida/api/history/brandLogoUpload`, //上传bradDNA
brandDNAGenerate: `/api/history/brandDNAGenerate`, //上传bradDNA brandDNAGenerate: `/aida/api/history/brandDNAGenerate`, //上传bradDNA
brandDNAUpload: `/api/history/brandDNAUpload`, //上传DNA图片 brandDNAUpload: `/aida/api/history/brandDNAUpload`, //上传DNA图片
getInitializeProgress: `/api/history/getInitializeProgress`, //获取brand进度 getInitializeProgress: `/aida/api/history/getInitializeProgress`, //获取brand进度
brandDNADelete: `/api/history/brandDNADelete`, //删除brandDna brandDNADelete: `/aida/api/history/brandDNADelete`, //删除brandDna
brandDNAPage: `/api/history/brandDNAPage`, //brand列表 brandDNAPage: `/aida/api/history/brandDNAPage`, //brand列表
brandDNASaveOrUpdate: `/api/history/brandDNASaveOrUpdate`, //提交个人信息 brandDNASaveOrUpdate: `/aida/api/history/brandDNASaveOrUpdate`, //提交个人信息
productImageInitialize: `/api/history/productImageInitialize`, //产品识别 productImageInitialize: `/aida/api/history/productImageInitialize`, //产品识别
//调查问卷 //调查问卷
questionnaire: `/api/account/questionnaire`, //保存画布 questionnaire: `/aida/api/account/questionnaire`, //保存画布
//消息系统 //消息系统
getUnreadCount: `/api/message/getUnreadCount`, //获取未读消息 getUnreadCount: `/aida/api/message/getUnreadCount`, //获取未读消息
setReadStatus: `/api/message/setReadStatus`, //设置消息已读 setReadStatus: `/aida/api/message/setReadStatus`, //设置消息已读
getHistoryNotification: `/api/message/getHistoryNotification`, //获取历史消息 getHistoryNotification: `/aida/api/message/getHistoryNotification`, //获取历史消息
oneClickRead: `/api/message/oneClickRead`, //全部设为已读 oneClickRead: `/aida/api/message/oneClickRead`, //全部设为已读
personalHomepage: `/api/account/personalHomepage`, //获取个人主页信息 personalHomepage: `/aida/api/account/personalHomepage`, //获取个人主页信息
refreshMinioUrl: `/api/third/party/refreshMinioUrl`, //获取可以使用的minio地址 refreshMinioUrl: `/aida/api/third/party/refreshMinioUrl`, //获取可以使用的minio地址
// 画布 // 画布
segAnything: `/api/python/segAnything`, //分割Anything segAnything: `/aida/api/python/segAnything`, //分割Anything
// award页面 // award页面
checkEmail: '/api/global-award/checkEmail', // 检查邮箱是否存在 checkEmail: '/aida/api/global-award/checkEmail', // 检查邮箱是否存在
checkOTP: '/api/global-award/checkCode', // 检查验证码是否正确 checkOTP: '/aida/api/global-award/checkCode', // 检查验证码是否正确
initPdfUpload: '/api/global-award/uploads/pdf/init', // 初始化pdf上传 initPdfUpload: '/aida/api/global-award/uploads/pdf/init', // 初始化pdf上传
initVideoUpload: '/api/global-award/uploads/video/init', // 初始化video上传 initVideoUpload: '/aida/api/global-award/uploads/video/init', // 初始化video上传
uploadPDF: '/api/global-award/uploads/pdf/chunk', // 上传pdf uploadPDF: '/aida/api/global-award/uploads/pdf/chunk', // 上传pdf
uploadVideo: '/api/global-award/uploads/video/chunk', // 上传video uploadVideo: '/aida/api/global-award/uploads/video/chunk', // 上传video
uploadPDFComplete: '/api/global-award/uploads/pdf/complete', // 上传pdf完成 uploadPDFComplete: '/aida/api/global-award/uploads/pdf/complete', // 上传pdf完成
uploadVideoComplete: '/api/global-award/uploads/video/complete', // 上传video完成 uploadVideoComplete: '/aida/api/global-award/uploads/video/complete', // 上传video完成
submitForm: '/api/global-award/contestants/save', // 提交表单 submitForm: '/aida/api/global-award/contestants/save', // 提交表单
getContestantByID: '/api/global-award/contestants/', // 获取表单 getContestantByID: '/aida/api/global-award/contestants/', // 获取表单
// 卖家端接口 // 卖家端接口
@@ -483,7 +483,7 @@ export const Https = {
axiosGet(url, config, pathParams) { axiosGet(url, config, pathParams) {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
if (isLoginTime && url != '/api/portfolio/page') { if (isLoginTime && url != '/aida/api/portfolio/page') {
resolve('') resolve('')
return return
} }
@@ -501,7 +501,7 @@ export const Https = {
axiosPut(url, data, pathParams) { axiosPut(url, data, pathParams) {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
if (isLoginTime && url != '/api/portfolio/page') { if (isLoginTime && url != '/aida/api/portfolio/page') {
resolve('') resolve('')
return return
} }
@@ -518,7 +518,7 @@ export const Https = {
axiosPost(url, data, config, pathParams) { axiosPost(url, data, config, pathParams) {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
if (isLoginTime && url != '/api/portfolio/page') { if (isLoginTime && url != '/aida/api/portfolio/page') {
resolve('') resolve('')
return return
} }
@@ -535,7 +535,7 @@ export const Https = {
axiosDelete(url, newData, pathParams) { axiosDelete(url, newData, pathParams) {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
if (isLoginTime && url != '/api/portfolio/page') { if (isLoginTime && url != '/aida/api/portfolio/page') {
resolve('') resolve('')
return return
} }

View File

@@ -318,7 +318,7 @@
</div> </div>
</div> </div>
<div class="homeMain_user"> <div class="homeMain_user">
<div class="homeMain_user_icon" @click="openAccount"> <div class="homeMain_user_icon">
<img :src="userDetail.avatar" alt="" /> <img :src="userDetail.avatar" alt="" />
</div> </div>
<div class="homeMain_user_detail"> <div class="homeMain_user_detail">
@@ -373,6 +373,10 @@
<i class="fi fi-rs-notebook"></i> <i class="fi fi-rs-notebook"></i>
<span class="select_item_des">{{ $t('Header.ViewOrders') }}</span> <span class="select_item_des">{{ $t('Header.ViewOrders') }}</span>
</div> </div>
<div class="select_item" @click="openAccount">
<span class="icon"><svg-icon name="home" /></span>
<span class="select_item_des">{{ $t('Header.PersonalCenter') }}</span>
</div>
<div class="select_item" @click="onBecomeSeller" v-if="!isSeller"> <div class="select_item" @click="onBecomeSeller" v-if="!isSeller">
<span class="icon"><svg-icon name="seller-sellerIndex" /></span> <span class="icon"><svg-icon name="seller-sellerIndex" /></span>
<span class="select_item_des">{{ $t('Header.BecomeSeller') }}</span> <span class="select_item_des">{{ $t('Header.BecomeSeller') }}</span>

View File

@@ -338,7 +338,7 @@
<a-upload <a-upload
class="search_upImg" class="search_upImg"
:capture="null" :capture="null"
:action="uploadUrl + '/api/element/upload'" :action="uploadUrl + '/aida/api/element/upload'"
list-type="picture-card" list-type="picture-card"
:before-upload="beforeUpload" :before-upload="beforeUpload"
:data="{ :data="{
@@ -387,7 +387,7 @@
<a-upload <a-upload
class="search_upImg" class="search_upImg"
:capture="null" :capture="null"
:action="uploadUrl + '/api/element/upload'" :action="uploadUrl + '/aida/api/element/upload'"
list-type="picture-card" list-type="picture-card"
:data="{ :data="{
...upload, ...upload,

View File

@@ -2,56 +2,58 @@
<div class="seller-apply"> <div class="seller-apply">
<div class="session"> <div class="session">
<div class="content mini-scrollbar"> <div class="content mini-scrollbar">
<div class="title">Brand Information</div> <div class="title">{{ $t("ApplySeller.formTitle") }}</div>
<div class="tip">Share a few details to set up your seller profile</div> <div class="tip">{{ $t("ApplySeller.formTip") }}</div>
<div class="form"> <div class="form">
<a-form :model="formData" :rules="formRules" layout="vertical" ref="formRef"> <a-form :model="formData" :rules="formRules" layout="vertical" ref="formRef">
<a-form-item label="Store Name" name="storeName"> <a-form-item :label="$t('Seller.storeName')" name="storeName">
<a-input <a-input
v-model:value="formData.storeName" v-model:value="formData.storeName"
placeholder="Enter the store name" :placeholder="$t('Seller.storeNameDesc')"
:maxlength="80" :maxlength="80"
/> />
<span class="tip-length">{{ formData.storeName.length }}/80</span> <span class="tip-length">{{ formData.storeName.length }}/80</span>
</a-form-item> </a-form-item>
<a-form-item label="Owners Full Name" name="fullName"> <a-form-item :label="$t('Seller.ownerName')" name="fullName">
<a-input <a-input
v-model:value="formData.fullName" v-model:value="formData.fullName"
placeholder="Enter store owner's full name" :placeholder="$t('Seller.ownerNameDesc')"
/> />
</a-form-item> </a-form-item>
<div class="form-group"> <div class="form-group">
<a-form-item label="Email" name="email"> <a-form-item :label="$t('Seller.email')" name="email">
<a-input <a-input
type="email" type="email"
v-model:value="formData.email" v-model:value="formData.email"
placeholder="Enter email" :placeholder="$t('Seller.emailDesc')"
/> />
</a-form-item> </a-form-item>
<a-form-item label="Phone Number" name="phoneNumber"> <a-form-item :label="$t('Seller.mobile')" name="mobile">
<a-input <a-input
type="tel" type="tel"
v-model:value="formData.phoneNumber" v-model:value="formData.mobile"
placeholder="Enter phone number" :placeholder="$t('Seller.mobileDesc')"
/> />
</a-form-item> </a-form-item>
</div> </div>
<a-form-item label="Store Description" name="description"> <a-form-item :label="$t('Seller.storeDescription')" name="description">
<a-textarea <a-textarea
v-model:value="formData.description" v-model:value="formData.description"
placeholder="Briefly describe your design style and store features..." :placeholder="$t('Seller.storeDescriptionDesc')"
:maxlength="500" :maxlength="500"
/> />
<span class="tip-length">{{ formData.description.length }}/500</span> <span class="tip-length">{{ formData.description.length }}/500</span>
</a-form-item> </a-form-item>
<a-form-item label="Portfoilo/Social Media Links"> <a-form-item :label="$t('Seller.links')">
<a-input <a-input
placeholder="https://" placeholder="https://"
v-for="(v, i) in formData.links" v-for="(v, i) in formData.links"
:key="i" :key="i"
v-model:value="formData.links[i]" v-model:value="formData.links[i]"
> >
<template #prefix>Link {{ i + 1 }}</template> <template #prefix>{{
$t("Seller.link", { index: i + 1 })
}}</template>
</a-input> </a-input>
<a-input <a-input
placeholder="https://" placeholder="https://"
@@ -71,33 +73,25 @@
</div> </div>
<div class="session"> <div class="session">
<div class="content"> <div class="content">
<div class="title">Brand Information</div> <div class="title">{{ $t("ApplySeller.termsTitle") }}</div>
<div class="tip">Share a few details to set up your seller profile</div> <div class="tip">{{ $t("ApplySeller.termsTip") }}</div>
<div class="agreement"> <div class="agreement">
<div class="title">AiDA Seller Agreement</div> <div class="title">{{ $t("ApplySeller.agreementTitle") }}</div>
<div class="tip"> <div class="tip">{{ $t("ApplySeller.agreementTip") }}</div>
By checking the box below, you agree to comply with the following terms:
</div>
<ul> <ul>
<li>Provide accurate and truthful personal and store information</li> <li v-for="(v, i) in 8" :key="i">
<li>Only sell original designs or content with proper licensing</li> {{ $t(`ApplySeller.agreementItem${i + 1}`) }}
<li>Maintain high quality standards for all products</li> </li>
<li>Respond to customer inquiries within 48 hours</li>
<li>Ship orders within promised timeframes</li>
<li>Comply with AiDA's terms of service and community guidelines</li>
<li>Pay applicable platform fees and transaction charges</li>
<li>Handle customer disputes professionally and fairly</li>
</ul> </ul>
</div> </div>
<a-checkbox class="agree-agreement" v-model:checked="isAgreement"> <a-checkbox class="agree-agreement" v-model:checked="isAgreement">
I have read and agree to the Seller Agreement, understanding my responsibilities {{ $t("ApplySeller.agreementAgreement") }}
and obligations as a seller on the AiDA platform.
</a-checkbox> </a-checkbox>
</div> </div>
<div class="btns"> <div class="btns">
<button class="cancel" @click="onCancel">Cancel</button> <button class="cancel" @click="onCancel">{{ $t("Seller.cancel") }}</button>
<button class="submit" :disabled="!isAgreement" @click="onSubmit"> <button class="submit" :disabled="!isAgreement" @click="onSubmit">
Submit Application {{ $t("ApplySeller.submitApplication") }}
</button> </button>
</div> </div>
</div> </div>
@@ -106,24 +100,26 @@
<script setup> <script setup>
import { ref, reactive } from "vue" import { ref, reactive } from "vue"
import { useI18n } from "vue-i18n"
const { t } = useI18n()
import { useRoute, useRouter } from "vue-router" import { useRoute, useRouter } from "vue-router"
const route = useRoute() const route = useRoute()
const router = useRouter() const router = useRouter()
import { Https } from "@/tool/https" import { Https } from "@/tool/https"
const emit = defineEmits(["submit"]) const emit = defineEmits(["submit"])
const formRules = { const formRules = {
storeName: [{ required: true, message: "Enter the store name" }], storeName: [{ required: true, message: t("Seller.storeNameDesc") }],
fullName: [{ required: true, message: "Enter store owner's full name" }], fullName: [{ required: true, message: t("Seller.ownerNameDesc") }],
email: [{ required: true, message: "Enter email" }], email: [{ required: true, message: t("Seller.emailDesc") }],
phoneNumber: [{ required: true, message: "Enter phone number" }], mobile: [{ required: true, message: t("Seller.mobileDesc") }],
description: [{ required: true, message: "Enter store description" }] description: [{ required: true, message: t("Seller.storeDescriptionErr") }]
} }
const formRef = ref(null) const formRef = ref(null)
const formData = reactive({ const formData = reactive({
storeName: "", storeName: "",
fullName: "", fullName: "",
email: "", email: "",
phoneNumber: "", mobile: "",
description: "", description: "",
links: ["", ""] links: ["", ""]
}) })
@@ -140,7 +136,6 @@
formRef.value formRef.value
.validate() .validate()
.then(() => { .then(() => {
console.log(formData)
const data = { const data = {
// userId: 0, // userId: 0,
shopName: formData.storeName, shopName: formData.storeName,
@@ -148,7 +143,7 @@
// brandBanner: "", // brandBanner: "",
ownerName: formData.fullName, ownerName: formData.fullName,
email: formData.email, email: formData.email,
mobile: formData.phoneNumber, mobile: formData.mobile,
description: formData.description, description: formData.description,
socialLinks: JSON.stringify(formData.links.filter((v) => v)) socialLinks: JSON.stringify(formData.links.filter((v) => v))
} }

View File

@@ -1,11 +1,11 @@
<template> <template>
<div class="seller-review"> <div class="seller-review">
<img class="success" src="@/assets/images/seller/success-1.png" /> <img class="success" src="@/assets/images/seller/success-1.png" />
<div class="title">Application Submitted</div> <div class="title">{{ $t("ApplySeller.applicationSubmitted") }}</div>
<div class="tip"> <div
Our team will review your application and get back to you within 13 business days. class="tip"
You'll receive a notification in your email once a decision has been made. v-html="$t('ApplySeller.applicationSubmittedTip', { click: 'onPersonalCenter' })"
</div> ></div>
<div class="step-list"> <div class="step-list">
<div v-for="v in list" :key="v.title" class="step-item"> <div v-for="v in list" :key="v.title" class="step-item">
<img v-show="!v.active" src="@/assets/images/seller/success-0.png" /> <img v-show="!v.active" src="@/assets/images/seller/success-0.png" />
@@ -16,7 +16,9 @@
</div> </div>
</div> </div>
</div> </div>
<button class="home-btn" @click="onBackToHome">Back to Homepage</button> <button class="home-btn" @click="onBackToHome">
{{ $t("ApplySeller.backToHomepage") }}
</button>
<div class="tip">ID: {{ userId }}</div> <div class="tip">ID: {{ userId }}</div>
</div> </div>
</template> </template>
@@ -26,6 +28,9 @@
import { useRoute, useRouter } from "vue-router" import { useRoute, useRouter } from "vue-router"
import { useStore } from "vuex" import { useStore } from "vuex"
import { ApplyStatus } from "@/store/seller/index.d" import { ApplyStatus } from "@/store/seller/index.d"
import { useI18n } from "vue-i18n"
const { t } = useI18n()
const route = useRoute() const route = useRoute()
const router = useRouter() const router = useRouter()
const store = useStore() const store = useStore()
@@ -33,24 +38,27 @@
const applyStatus = computed(() => store.state.seller.applyStatus) const applyStatus = computed(() => store.state.seller.applyStatus)
const list = computed(() => [ const list = computed(() => [
{ {
title: "Step 1: Submit Application", title: t("ApplySeller.auditStatus1_title"),
tip: "Fill out the seller information form and agree to our terms", tip: t("ApplySeller.auditStatus1_tip"),
active: [ApplyStatus.Pending, ApplyStatus.Approved].includes(applyStatus.value) active: [ApplyStatus.Pending, ApplyStatus.Approved].includes(applyStatus.value)
}, },
{ {
title: "Step 2: Review & Verification", title: t("ApplySeller.auditStatus2_title"),
tip: "Our team will review your application (typically 1-3 business days)", tip: t("ApplySeller.auditStatus2_tip"),
active: applyStatus.value === ApplyStatus.Approved active: applyStatus.value === ApplyStatus.Approved
}, },
{ {
title: "Step 3: Start Selling", title: t("ApplySeller.auditStatus3_title"),
tip: "Once approved, access your seller dashboard and start listing products ", tip: t("ApplySeller.auditStatus3_tip"),
active: applyStatus.value === ApplyStatus.Approved active: applyStatus.value === ApplyStatus.Approved
} }
]) ])
const onBackToHome = () => { const onBackToHome = () => {
router.push({ name: "home" }) router.push({ name: "home" })
} }
window.onPersonalCenter = () => {
router.push("/home/account")
}
</script> </script>
<style scoped lang="less"> <style scoped lang="less">
.seller-review { .seller-review {
@@ -75,11 +83,15 @@
color: #000; color: #000;
} }
> .tip { > .tip {
font-family: pingfang_medium; font-family: pingfang_regular;
font-size: 1.8rem; font-size: 1.8rem;
line-height: 170%; line-height: 170%;
text-align: center; text-align: center;
color: #585858; color: #585858;
&:deep(span) {
color: #585858;
font-family: pingfang_heavy;
}
} }
> .step-list { > .step-list {
margin: 2.6rem 0; margin: 2.6rem 0;

View File

@@ -10,6 +10,7 @@
:closable="false" :closable="false"
wrapClassName="#app" wrapClassName="#app"
:keyboard="false" :keyboard="false"
:destroyOnClose="true"
> >
<div class="image-clip-dialog-box"> <div class="image-clip-dialog-box">
<div class="header" :class="{ 'is-product': data.isProduct }"> <div class="header" :class="{ 'is-product': data.isProduct }">
@@ -27,7 +28,7 @@
</div> </div>
<div <div
class="origin-item product" class="origin-item product"
:class="{ selected: currentOrigin === 'mainProducImage' }" :class="{ selected: currentOrigin === 'mainProductImage' }"
@click="handleChangeOrigin('mainProductImage')" @click="handleChangeOrigin('mainProductImage')"
> >
{{ $t("Seller.mainProductImage") }} {{ $t("Seller.mainProductImage") }}
@@ -79,14 +80,12 @@
</template> </template>
<script setup> <script setup>
import { ref, reactive, computed } from "vue" import { ref, reactive, computed } from "vue"
import ImageClip from "./image-clip.vue" import ImageClip from "./image-clip.vue"
import { useI18n } from "vue-i18n" import { useI18n } from "vue-i18n"
const { t } = useI18n() const { t } = useI18n()
const props = defineProps({
const props = defineProps({
type: { type: {
type: String, type: String,
default: "" default: ""
@@ -95,9 +94,9 @@ const props = defineProps({
type: Boolean, type: Boolean,
default: false default: false
} }
}) })
const tips = computed(() => { const tips = computed(() => {
if (props.type === "cover") { if (props.type === "cover") {
return t("Seller.imageClipCoverTip") return t("Seller.imageClipCoverTip")
} }
@@ -110,9 +109,9 @@ const tips = computed(() => {
if (props.type === "apparel") { if (props.type === "apparel") {
return t("Seller.imageClipApparelTip") return t("Seller.imageClipApparelTip")
} }
}) })
const data = reactive({ const data = reactive({
url: "", url: "",
title: "Crop Image", title: "Crop Image",
preview_url: "", preview_url: "",
@@ -120,20 +119,28 @@ const data = reactive({
isPreview: true, isPreview: true,
callback: null, callback: null,
isProduct: false // 是否商品编辑 isProduct: false // 是否商品编辑
}) })
const currentOrigin = ref("sketch")
const coverOrigin = ref([])
const handleChangeOrigin = (type) => {
const targetOrigin = coverOrigin.value.find((el) => el.type === type)
if (!targetOrigin) return
const currentOrigin = ref("sketch")
const coverOrigin = ref([])
const handleChangeOrigin = (type) => {
currentOrigin.value = type currentOrigin.value = type
data.url = coverOrigin.value.filter((el) => el.type === type)[0].url data.url = targetOrigin.url
} }
const show = ref(false) const show = ref(false)
const open = (url, callback, options, origin) => { const open = (url, callback, options, origin) => {
if (!props.isProduct) { if (!props.isProduct) {
if (!url || !callback) return if (!url || !callback) return
} }
coverOrigin.value = []
data.url = null
currentOrigin.value = "sketch"
data.url = url data.url = url
data.callback = callback data.callback = callback
data.ratio = options.ratio || [1, 1] data.ratio = options.ratio || [1, 1]
@@ -146,30 +153,32 @@ const open = (url, callback, options, origin) => {
} }
if (origin?.length) { if (origin?.length) {
coverOrigin.value = origin coverOrigin.value = origin
data.url = origin[0].url const defaultOrigin = origin.find((el) => el.type === options?.coverFrom) || origin[0]
currentOrigin.value = defaultOrigin.type
data.url = defaultOrigin.url
} }
show.value = true show.value = true
} }
const onCancel = () => { const onCancel = () => {
show.value = false show.value = false
} }
const imageClipRef = ref(null) const imageClipRef = ref(null)
const onSubmit = () => { const onSubmit = () => {
imageClipRef.value.getCropBlob().then((blob) => { imageClipRef.value.getCropBlob().then((blob) => {
if (data.callback) data.callback(blobToFile(blob, "image.png")) if (data.callback) data.callback(blobToFile(blob, "image.png"), currentOrigin.value)
onCancel() onCancel()
}) })
} }
// 将blob转换为file对象 // 将blob转换为file对象
const blobToFile = (blob, fileName) => { const blobToFile = (blob, fileName) => {
return new File([blob], fileName, { type: blob.type }) return new File([blob], fileName, { type: blob.type })
} }
defineExpose({ defineExpose({
open open
}) })
</script> </script>
<style scoped lang="less"> <style scoped lang="less">
.image-clip-dialog-box { .image-clip-dialog-box {
width: 100%; width: 100%;
height: 100%; height: 100%;
overflow: hidden; overflow: hidden;
@@ -250,6 +259,7 @@ defineExpose({
.crop-wrapper { .crop-wrapper {
width: 100%; width: 100%;
padding-top: 1.2rem;
.tips { .tips {
text-align: center; text-align: center;
color: #585858; color: #585858;
@@ -332,5 +342,5 @@ defineExpose({
} }
} }
} }
} }
</style> </style>

View File

@@ -96,24 +96,26 @@
return label return label
} }
const centerLabelTop = "8px"
const cropLabelMap = { const cropLabelMap = {
cover: [ cover: [
{ text: "crown", top: "2.67%", className: "label-h" }, { text: "crown", top: "2.67%", className: "label-h" },
{ text: "hip line", top: "63.47%", className: "label-h" }, { text: "hip line", top: "63.47%", className: "label-h" },
{ text: "mid-thigh", top: "92.8%", className: "label-h" }, { text: "mid-thigh", top: "92.8%", className: "label-h" },
{ text: "center", top: "0", className: "label-v" } { text: "center", top: centerLabelTop, className: "label-v" }
], ],
mainProductImage: [ mainProductImage: [
{ text: "crown", top: "2.67%", className: "label-h" }, { text: "crown", top: "2.67%", className: "label-h" },
{ text: "footbase", top: "97.6%", className: "label-h" }, { text: "footbase", top: "97.6%", className: "label-h" },
{ text: "center", top: "0", className: "label-v" } { text: "center", top: centerLabelTop, className: "label-v" }
], ],
sketch: [ sketch: [
{ text: "crown", top: "2.67%", className: "label-h" }, { text: "crown", top: "2.67%", className: "label-h" },
{ text: "footbase", top: "97.6%", className: "label-h" }, { text: "footbase", top: "97.6%", className: "label-h" },
{ text: "center", top: "0", className: "label-v" } { text: "center", top: centerLabelTop, className: "label-v" }
], ],
apparel: [{ text: "center", top: "0", className: "label-v" }] apparel: [{ text: "center", top: centerLabelTop, className: "label-v" }]
} }
const injectCropLabel = () => { const injectCropLabel = () => {
@@ -288,11 +290,16 @@
left: 0; left: 0;
width: 100%; width: 100%;
height: 100%; height: 100%;
box-sizing: border-box;
border: 1px solid rgba(75, 165, 255, 0.85);
pointer-events: none; pointer-events: none;
z-index: 9; /* 位于图片之上,但在控制点之下 */ z-index: 9; /* 位于图片之上,但在控制点之下 */
background-image: none; background-image: none;
background-repeat: no-repeat; background-repeat: no-repeat;
} }
:deep(.vue-cropper .crop-point) {
z-index: 10;
}
} }
&[data-crop-type="cover"] { &[data-crop-type="cover"] {

View File

@@ -30,25 +30,67 @@ This directory owns the seller listing edit/create detail page.
Detail API images are mapped by `category`: Detail API images are mapped by `category`:
- `cover` -> `currentListing.cover` - `cover` -> `currentListing.cover`
- `cover_from` -> `currentListing.coverFrom`; `imageUrl` stores the source image URL, not the literal source key. Resolve it against `sketch` and `mainProductImage` when hydrating. Keep backward compatibility for old rows whose `imageUrl` is `sketch` or `mainProductImage`.
- `sketch` -> `currentListing.sketch` - `sketch` -> `currentListing.sketch`
- `mainProductImage` -> `currentListing.mainProductImage` - `mainProductImage` or `main_product` -> `currentListing.mainProductImage`
- `main_product` or `product` -> `currentListing.prodImageList` - `product` -> non-video entries in `currentListing.prodImageList`
- `firstFrame`, `gif`, and `video` -> one video entry in `currentListing.prodImageList` when the three rows share the same `sortOrder`
- `apparel` -> `currentListing.sketchList` - `apparel` -> `currentListing.sketchList`
When saving, preserve the backend's expected image categories. Confirm backend naming before changing `main_product`, `product`, or `mainProductImage`. When saving, preserve the backend's expected image categories. Confirm backend naming before changing `main_product`, `product`, `firstFrame`, `gif`, `video`, or `mainProductImage`.
中文补充:
- 详情接口返回的 `images` 要按 `category` 回填到页面状态,不要只按数组顺序猜类型。
- `cover_from` 不是封面图本身,而是记录封面裁剪来源。它的 `imageUrl` 传来源图片链接,回显时用这个 URL 和 `sketch``mainProductImage` 比较,恢复裁剪弹窗里的来源选择。
- `main_product` 表示页面右上方的主产品图 URL普通 `product` 只表示产品图列表里的非视频图片。
- 视频不要保存成 `product`。视频必须拆成 `firstFrame``gif``video` 三类,并在回显时按相同 `sortOrder` 合并成一个视频项。
## Product Image Rules ## Product Image Rules
- The `main` badge represents the first selected product image, not the most recently selected one. - The `main` badge represents the first selected product image, not the most recently selected one.
- `firstSelectedIndex` is stored on each `ListingItem` and passed to `ProductImageList.vue`. - `firstSelectedIndex` is stored on each `ListingItem` and passed to `ProductImageList.vue`.
- Hydrating detail data must only set `mainProductImage` from explicit `main_product` or `mainProductImage` rows. Never infer it from selected `product` rows.
- Selecting a product image should only set `mainProductImage` when no main image is currently tracked by that listing's `firstSelectedIndex`. - Selecting a product image should only set `mainProductImage` when no main image is currently tracked by that listing's `firstSelectedIndex`.
- Unselecting the current main product image clears `mainProductImage` and resets `firstSelectedIndex`. - Unselecting the current main product image clears `mainProductImage` and resets `firstSelectedIndex`.
- Videos can be selected and saved, but they cannot become `mainProductImage`, must not set `firstSelectedIndex`, and must not display the `main` badge.
中文补充:
- `main` 标识只给图片,不给视频。
- 数据回显时,只有接口明确返回 `main_product` / `mainProductImage` 才能设置主图。不要因为某个 `product` 是已选中状态,就自动把它当成 `mainProductImage` 或显示 `main`
- 第一次选择视频时可以弹 warning但视频本身仍然要保持选中只是不要把它写入 `mainProductImage`,也不要更新 `firstSelectedIndex`
- 如果先选中视频,再选中图片,图片仍然可以成为第一个主图。
- 如果取消的是当前主图图片,需要清空 `mainProductImage``firstSelectedIndex`;取消普通图片或视频不应影响主图。
## Save Image Ordering
- Every saved image row must include `sortOrder`.
- `sortOrder` is scoped per category; each category starts its own sequence.
- For `product` rows, save the image currently used as `mainProductImage` first, selected non-main images next, and unselected images last.
- Save video media as three rows with categories `firstFrame`, `gif`, and `video`. The three rows from the same video item must share the same `sortOrder`.
- When hydrating detail data, group `firstFrame`, `gif`, and `video` rows by matching `sortOrder` and restore the combined video item, including its selected state. Accept `isSelected`, old typo `isSeleted`, and `selected` from the API.
中文补充:
- `sortOrder` 是按 category 分开排的,不同 category 之间不要共用一个全局序号。
- `product` 的排序规则是:当前作为 `mainProductImage` 的图片第一,其他已选图片其次,未选图片最后。
- 同一个视频拆出的 `firstFrame``gif``video` 三条数据必须使用同一个 `sortOrder`。例如第一个视频三条都是 `sortOrder: 1`,第二个视频三条都是 `sortOrder: 2`
- 回显视频时,用相同 `sortOrder` 找回一组 `firstFrame/gif/video`。三条里任意一条带选中标记,都应恢复为这个视频已选中。
- 选中字段要兼容 `isSelected`、历史拼写 `isSeleted`、以及 `selected`
## Crop Flow ## Crop Flow
- `TopImageSection.vue` and `ApparelSketchList.vue` emit `crop`. - `TopImageSection.vue` and `ApparelSketchList.vue` emit `crop`.
- `index.vue` handles `handleClickCrop`, opens `ImageClipDialog`, uploads with `uploadFile`, then writes the returned URL into the correct field/list item. - `index.vue` handles `handleClickCrop`, opens `ImageClipDialog`, uploads with `uploadFile`, then writes the returned URL into the correct field/list item.
- Keep cover crop ratio at `[4, 5]`; other crop types use `[9, 16]`. - Keep cover crop ratio at `[4, 5]`; other crop types use `[9, 16]`.
- Cover crop can be based on `sketch` or `mainProductImage`. Store the chosen source in `coverFrom`, save it via `cover_from.imageUrl` as the source image URL, and pass it back into `ImageClipDialog` so reopening cover crop restores the selected source.
中文补充:
- cover 裁剪弹窗会在 `sketch``mainProductImage` 之间切来源。用户保存 cover 时,父组件需要同时保存裁剪后的 cover URL 和本次使用的来源。
- 下次重新打开 cover 裁剪时,应该按 `coverFrom` 恢复来源选择,并用对应的原图作为裁剪图,不要直接拿已裁好的 cover 图再次裁。
- 如果只有一个来源图可用,就按可用来源打开;如果两个来源都可用,要显示来源切换。
## Form Flow ## Form Flow

View File

@@ -1,20 +1,14 @@
import { Https } from "@/tool/https" import { Https } from "@/tool/https"
import type { ListingImageCategory, SketchDetailResponse } from "./types"
// 编辑时根据ID获取信息 // 编辑时根据ID获取信息
export const fetchListingDetailById = (id) => { export const fetchListingDetailById = (id) => {
return Https.axiosGet("/seller/listing/detail", { params: { id } }) return Https.axiosGet("/seller/listing/detail", { params: { id } })
} }
interface SketchIDs { type SketchIDs = Array<number | string>
designItemIds: Array
}
interface DetailReturns {
clothes: string[]
designItemId: number
toProductImageUrls: string[]
}
// 获取designItemId对应的产品图 // 获取designItemId对应的产品图
export const fetchSketchDetail = (data: SketchIDs): Array<DetailReturns> => { export const fetchSketchDetail = (data: SketchIDs): Promise<SketchDetailResponse[]> => {
let params = "?" let params = "?"
data.forEach((id, index) => { data.forEach((id, index) => {
if (index === data.length - 1) { if (index === data.length - 1) {
@@ -23,27 +17,30 @@ export const fetchSketchDetail = (data: SketchIDs): Array<DetailReturns> => {
params += `designItemIds=${id}&` params += `designItemIds=${id}&`
} }
}) })
return Https.axiosGet(`/api/seller/sketchDetail${params}`) return Https.axiosGet(`/aida/api/seller/sketchDetail${params}`)
} }
interface ImageObj { interface ImageObj {
id: number // 图片id,有值会更新,没有会自动新增 id?: number // 图片id,有值会更新,没有会自动新增
category: "cover" | "main_product" | "product" | "sketch" | "apparel" // 图片类型 category: ListingImageCategory // 图片类型
imageUrl?: string | null
isSelected?: number
sortOrder?: number
} }
interface DetailData { interface DetailData {
id: number | string // 商品Id id: number | string // 商品Id
title: string // 商品名 title: string // 商品名
description: string // 商品描述 description: string // 商品描述
price: number // 价格 price: number | string // 价格
stock?: number // 库存 stock?: number // 库存
viewCount?: number // 浏览量 viewCount?: number // 浏览量
status: 0 | 1 | 2 // 0草稿 1发布 2删除 status: 0 | 1 | 2 // 0草稿 1发布 2删除
images: ImageObj[] images: ImageObj[]
designFor: "male" | "female" designFor: "male" | "female"
productCategory: "outwear" | "trousers" | "blouse" | "dress" | "skirt" | "accessories" productCategory: string[] | null
} }
// 保存/更新表单 // 保存/更新表单
export const fetchUpdateListing = (data: DetailData) => { export const fetchUpdateListing = (data: DetailData[]) => {
return Https.axiosPost("/seller/listing/batch", data) return Https.axiosPost("/seller/listing/batch", data)
} }

View File

@@ -12,8 +12,10 @@
v-for="(item, index) in imageList" v-for="(item, index) in imageList"
:key="index" :key="index"
class="product-image-item flex flex-center" class="product-image-item flex flex-center"
:class="{ selected: item.selected }" :class="{ selected: item.selected, video: item.isVideo }"
@click="emit('select', index)" @click="emit('select', index)"
@mouseenter="handleMouseEnter(index, item)"
@mouseleave="handleMouseLeave(index, item)"
> >
<img <img
v-if="item.selected" v-if="item.selected"
@@ -21,8 +23,11 @@
class="checked" class="checked"
alt="" alt=""
/> />
<img class="img-src" :src="item.url" alt="" /> <img class="img-src" :src="getDisplayUrl(item, index)" alt="" />
<div v-if="item.selected && index === firstSelectedIndex" class="main-pic"> <div v-if="item.isVideo && durationMap[index]" class="video-duration">
{{ durationMap[index] }}
</div>
<div v-if="item.selected && index === firstSelectedIndex && !item.isVideo" class="main-pic">
main main
</div> </div>
</div> </div>
@@ -30,8 +35,8 @@
</div> </div>
</template> </template>
<script setup lang="ts"> <script setup lang="ts">
import { computed } from "vue" import { computed, ref, watch } from "vue"
import type { ListingItem } from "../types" import type { ListingItem, ProductMediaItem } from "../types"
const props = defineProps<{ const props = defineProps<{
imageList: ListingItem["prodImageList"] imageList: ListingItem["prodImageList"]
@@ -43,6 +48,70 @@
}>() }>()
const selectedCount = computed(() => props.imageList.filter((item) => item.selected).length) const selectedCount = computed(() => props.imageList.filter((item) => item.selected).length)
const hoveredVideoIndex = ref<number | null>(null)
const durationMap = ref<Record<number, string>>({})
const videoSourceKey = computed(() =>
props.imageList
.map((item) => `${item.videoUrl || ""}::${item.url || ""}`)
.join("|")
)
const getDisplayUrl = (item: ProductMediaItem, index: number) => {
if (item.isVideo && hoveredVideoIndex.value === index && item.gifUrl) {
return item.gifUrl
}
return item.url
}
const handleMouseEnter = (index: number, item: ProductMediaItem) => {
if (!item.isVideo || !item.gifUrl) return
hoveredVideoIndex.value = index
}
const handleMouseLeave = (index: number, item: ProductMediaItem) => {
if (!item.isVideo) return
if (hoveredVideoIndex.value === index) hoveredVideoIndex.value = null
}
const formatVideoDuration = (duration: number) => {
if (!Number.isFinite(duration) || duration <= 0) return ""
const totalSeconds = Math.round(duration)
const minutes = Math.floor(totalSeconds / 60)
const seconds = totalSeconds % 60
return `${String(minutes).padStart(2, "0")}:${String(seconds).padStart(2, "0")}`
}
const loadVideoDurations = () => {
durationMap.value = {}
props.imageList.forEach((item, index) => {
if (!item.isVideo || !item.videoUrl) return
const video = document.createElement("video")
video.preload = "metadata"
video.src = item.videoUrl
video.onloadedmetadata = () => {
durationMap.value = {
...durationMap.value,
[index]: formatVideoDuration(video.duration)
}
}
video.onerror = () => {
video.src = ""
}
})
}
watch(
videoSourceKey,
() => {
hoveredVideoIndex.value = null
loadVideoDurations()
},
{ immediate: true }
)
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>
@@ -135,6 +204,20 @@
object-fit: contain; object-fit: contain;
} }
.video-duration {
position: absolute;
right: 0.8rem;
bottom: 0.8rem;
z-index: 1;
padding: 0 0.8rem;
height: 2.4rem;
line-height: 2.4rem;
border-radius: 1.2rem;
background: rgba(0, 0, 0, 0.8);
color: #fff;
font-size: 1.2rem;
}
.main-pic { .main-pic {
position: absolute; position: absolute;
height: 2.4rem; height: 2.4rem;

View File

@@ -88,10 +88,16 @@
fetchUpdateListing fetchUpdateListing
} from "./api" } from "./api"
import type { import type {
CoverSourceType,
CropType,
ListingDetailImage, ListingDetailImage,
ListingDetailResponse, ListingDetailResponse,
ListingImageCategory,
ListingItem, ListingItem,
ProductMediaItem,
RadioOption, RadioOption,
SketchDetailResponse,
SketchDetailVideo,
StatusType StatusType
} from "./types" } from "./types"
@@ -121,18 +127,14 @@
desc: "", desc: "",
gender: "FEMALE", gender: "FEMALE",
category: null, category: null,
coverFrom: "sketch",
firstSelectedIndex: null, firstSelectedIndex: null,
prodImageList: [], prodImageList: [],
sketchList: [] sketchList: []
}) })
const genderOptions = computed(() => { const genderOptions = computed(() => {
return ( return STORE.state.UserHabit?.sex.value
STORE.state.UserHabit?.sex.value.map((el) => ({
...el,
// name: el.key.toLowerCase()
})) || []
)
}) })
const fallbackCategoryOptions: Record<string, RadioOption[]> = { const fallbackCategoryOptions: Record<string, RadioOption[]> = {
@@ -172,14 +174,50 @@
return [...images].sort((prev, next) => (prev.sortOrder ?? 0) - (next.sortOrder ?? 0)) return [...images].sort((prev, next) => (prev.sortOrder ?? 0) - (next.sortOrder ?? 0))
} }
const getImageSelected = (value: ListingDetailImage["isSelected"]) => const getImageSelected = (value: ListingDetailImage["isSelected"]) => {
value === true || value === 1 || value === "1" if (value === true || value === 1 || value === "1") return true
if (typeof value === "string") return value.toLowerCase() === "true"
return false
}
const getDetailImageSelected = (image: ListingDetailImage) =>
getImageSelected(image.isSelected) ||
getImageSelected(image.isSeleted) ||
getImageSelected(image.selected)
const normalizeCoverSource = (value: unknown): CoverSourceType =>
value === "mainProductImage" ? "mainProductImage" : "sketch"
const isCoverSource = (value: unknown): value is CoverSourceType =>
value === "sketch" || value === "mainProductImage"
const resolveCoverSourceFromImageUrl = (
imageUrl: string,
listing: ListingItem
): CoverSourceType => {
if (imageUrl === listing.mainProductImage) return "mainProductImage"
if (imageUrl === listing.sketch) return "sketch"
return normalizeCoverSource(imageUrl)
}
const videoImageCategories = ["firstFrame", "gif", "video"] as const
type VideoImageCategory = (typeof videoImageCategories)[number]
const isVideoImageCategory = (
category: ListingDetailImage["category"]
): category is VideoImageCategory =>
videoImageCategories.includes(category as VideoImageCategory)
const normalizeDetailGender = (value: ListingDetailResponse["designFor"]) => { const normalizeDetailGender = (value: ListingDetailResponse["designFor"]) => {
const gender = String(value || "").toUpperCase() const gender = String(value || "").toUpperCase()
return gender === "MALE" || gender === "FEMALE" ? gender : "FEMALE" return gender === "MALE" || gender === "FEMALE" ? gender : "FEMALE"
} }
const getListingDesignFor = (gender: ListingItem["gender"]): "male" | "female" =>
gender === "MALE" ? "male" : "female"
const normalizeDetailCategory = ( const normalizeDetailCategory = (
value: ListingDetailResponse["productCategory"] value: ListingDetailResponse["productCategory"]
): ListingItem["category"] => { ): ListingItem["category"] => {
@@ -193,6 +231,17 @@
const createListingItemFromDetail = (detail: ListingDetailResponse): ListingItem => { const createListingItemFromDetail = (detail: ListingDetailResponse): ListingItem => {
const listing = createListingItem() const listing = createListingItem()
let coverFromImageUrl = ""
const videoGroupMap = new Map<
number,
{
sortOrder: number
firstFrameUrl?: string
gifUrl?: string
videoUrl?: string
selected: boolean
}
>()
listing.productName = detail.title || "" listing.productName = detail.title || ""
listing.price = listing.price =
@@ -202,6 +251,11 @@
listing.category = normalizeDetailCategory(detail.productCategory) listing.category = normalizeDetailCategory(detail.productCategory)
getSortedDetailImages(detail.images || []).forEach((image) => { getSortedDetailImages(detail.images || []).forEach((image) => {
if (image.category === "cover_from") {
coverFromImageUrl = image.imageUrl || ""
return
}
const imageUrl = image.imageUrl || "" const imageUrl = image.imageUrl || ""
if (!imageUrl) return if (!imageUrl) return
@@ -215,7 +269,7 @@
return return
} }
if (image.category === "mainProductImage") { if (image.category === "mainProductImage" || image.category === "main_product") {
listing.mainProductImage = imageUrl listing.mainProductImage = imageUrl
return return
} }
@@ -223,23 +277,50 @@
if (image.category === "product") { if (image.category === "product") {
listing.prodImageList.push({ listing.prodImageList.push({
url: imageUrl, url: imageUrl,
selected: getImageSelected(image.isSelected) selected: getDetailImageSelected(image)
}) })
return return
} }
if (isVideoImageCategory(image.category)) {
if (image.sortOrder === null || typeof image.sortOrder === "undefined") return
const sortOrder = Number(image.sortOrder)
if (!Number.isFinite(sortOrder)) return
const group = videoGroupMap.get(sortOrder) || {
sortOrder,
selected: false
}
if (image.category === "firstFrame") group.firstFrameUrl = imageUrl
if (image.category === "gif") group.gifUrl = imageUrl
if (image.category === "video") group.videoUrl = imageUrl
group.selected = group.selected || getDetailImageSelected(image)
videoGroupMap.set(sortOrder, group)
return
}
if (image.category === "apparel") { if (image.category === "apparel") {
listing.sketchList.push({ url: imageUrl }) listing.sketchList.push({ url: imageUrl })
} }
}) })
if (!listing.mainProductImage) { Array.from(videoGroupMap.values())
listing.mainProductImage = .sort((prev, next) => prev.sortOrder - next.sortOrder)
listing.prodImageList.find((item) => item.selected)?.url || "" .forEach((video) => {
const videoItem = createProductVideoItem(video, video.selected)
if (videoItem) listing.prodImageList.push(videoItem)
})
if (coverFromImageUrl) {
listing.coverFrom = resolveCoverSourceFromImageUrl(coverFromImageUrl, listing)
} }
const selectedIndex = listing.prodImageList.findIndex((item) => item.selected) const mainProductIndex = listing.prodImageList.findIndex(
listing.firstSelectedIndex = selectedIndex === -1 ? null : selectedIndex (item) => !item.isVideo && item.url === listing.mainProductImage
)
listing.firstSelectedIndex = mainProductIndex === -1 ? null : mainProductIndex
listing.productImage = listing.prodImageList.map((item) => item.url) listing.productImage = listing.prodImageList.map((item) => item.url)
listing.apparelSketch = listing.sketchList listing.apparelSketch = listing.sketchList
@@ -249,6 +330,26 @@
return listing return listing
} }
const createProductVideoItem = (
video: SketchDetailVideo,
selected = false
): ProductMediaItem | null => {
const firstFrameUrl = video?.firstFrameUrl || ""
const gifUrl = video?.gifUrl || ""
const videoUrl = video?.videoUrl || ""
if (!firstFrameUrl || !videoUrl) return null
return {
url: firstFrameUrl,
firstFrameUrl,
gifUrl,
videoUrl,
isVideo: true,
selected
}
}
const handleSelectProdImg = (index: number) => { const handleSelectProdImg = (index: number) => {
const listing = currentListing.value const listing = currentListing.value
const target = prodImgList.value[index] const target = prodImgList.value[index]
@@ -257,6 +358,10 @@
target.selected = willSelect target.selected = willSelect
if (willSelect && listing.firstSelectedIndex === null) { if (willSelect && listing.firstSelectedIndex === null) {
if (target.isVideo) {
message.warning(t("Seller.VideoWarning"))
return
}
listing.mainProductImage = target.url listing.mainProductImage = target.url
listing.firstSelectedIndex = index listing.firstSelectedIndex = index
return return
@@ -268,25 +373,33 @@
} }
} }
const cropType = ref("") const getCoverOriginList = (item: ListingItem) => {
const handleClickCrop = (data: any, type: string, paramThree: any = []) => { const origin: Array<{ type: CoverSourceType; url: string }> = []
if (item.sketch) {
origin.push({ type: "sketch", url: item.sketch })
}
if (item.mainProductImage) {
origin.push({ type: "mainProductImage", url: item.mainProductImage })
}
return origin
}
const cropType = ref<CropType | "">("")
const handleClickCrop = (
data: string | null,
type: CropType,
paramThree: number | unknown[] = []
) => {
// 处理来自TopImageSection的调用: (data, type, list) // 处理来自TopImageSection的调用: (data, type, list)
// 处理来自ApparelSketchList的调用: (data, type, index) // 处理来自ApparelSketchList的调用: (data, type, index)
const index = typeof paramThree === "number" ? paramThree : undefined const index = typeof paramThree === "number" ? paramThree : undefined
const list = Array.isArray(paramThree) ? paramThree : []
// console.log(data, type) // console.log(data, type)
// console.log(selectList.value[currentIndex.value]) // console.log(selectList.value[currentIndex.value])
let origin = []
const currentItem = selectList.value[currentIndex.value] const currentItem = selectList.value[currentIndex.value]
if (currentItem.sketch) { const origin = type === "cover" ? getCoverOriginList(currentItem) : []
origin.push({ type: "sketch", url: currentItem.sketch }) const titleList: Record<CropType, string> = {
}
if (currentItem.mainProductImage) {
origin.push({ type: "mainProductImage", url: currentItem.mainProductImage })
}
if (type !== "cover") origin = []
const titleList = {
sketch: "Crop Sketch", sketch: "Crop Sketch",
mainProductImage: "Crop Main Product Image", mainProductImage: "Crop Main Product Image",
cover: "Crop Cover", cover: "Crop Cover",
@@ -296,17 +409,28 @@
cropType.value = type cropType.value = type
imageClipDialogRef.value.open( imageClipDialogRef.value.open(
data, data,
(file) => { (file: File, coverFrom?: CoverSourceType) => {
// console.log(file) // console.log(file)
uploadFile(file).then((res) => { uploadFile(file).then((res) => {
if (type === "apparel" && typeof index !== "undefined") { if (type === "apparel" && typeof index !== "undefined") {
selectList.value[currentIndex.value].sketchList[index].url = res selectList.value[currentIndex.value].sketchList[index].url = res
} else if (type === "cover") {
selectList.value[currentIndex.value].cover = res
if (isCoverSource(coverFrom)) {
selectList.value[currentIndex.value].coverFrom = coverFrom
}
} else { } else {
selectList.value[currentIndex.value][type] = res selectList.value[currentIndex.value][type] = res
} }
}) })
}, },
{ ratio, isPreview: true, title: titleList[type], isProduct: true }, {
ratio,
isPreview: true,
title: titleList[type],
isProduct: true,
coverFrom: currentItem.coverFrom
},
origin origin
) )
} }
@@ -315,10 +439,9 @@
value !== null && value !== undefined && String(value).trim() !== "" value !== null && value !== undefined && String(value).trim() !== ""
const getMissingRequiredField = (item: ListingItem) => { const getMissingRequiredField = (item: ListingItem) => {
const cover = item.cover || item.mainProductImage || item.sketch
const requiredFields = [ const requiredFields = [
{ value: item.sketch, label: t("SellerListEdit.sketch") }, { value: item.sketch, label: t("SellerListEdit.sketch") },
{ value: cover, label: t("SellerListEdit.cover") }, { value: item.cover, label: t("SellerListEdit.cover") },
{ value: item.productName, label: t("SellerListEdit.productName") }, { value: item.productName, label: t("SellerListEdit.productName") },
{ value: item.price, label: t("SellerListEdit.price") }, { value: item.price, label: t("SellerListEdit.price") },
{ value: item.desc, label: t("SellerListEdit.productDescription") }, { value: item.desc, label: t("SellerListEdit.productDescription") },
@@ -358,63 +481,120 @@
return true return true
} }
type SaveListingImage = {
category: ListingImageCategory
imageUrl: string | null
isSelected: number
sortOrder: number
}
const isMainProductMedia = (item: ListingItem, media: ProductMediaItem, index: number) =>
!media.isVideo &&
(item.firstSelectedIndex === index ||
(Boolean(item.mainProductImage) && item.mainProductImage === media.url))
const getSortedProductMedia = (item: ListingItem) => {
return item.prodImageList
.map((media, index) => ({ media, index }))
.filter(({ media }) => !media.isVideo)
.sort((prev, next) => {
const prevRank = isMainProductMedia(item, prev.media, prev.index)
? 0
: prev.media.selected
? 1
: 2
const nextRank = isMainProductMedia(item, next.media, next.index)
? 0
: next.media.selected
? 1
: 2
return prevRank - nextRank || prev.index - next.index
})
}
const buildListingImages = (item: ListingItem) => {
const images: SaveListingImage[] = []
const sortOrderMap: Partial<Record<ListingImageCategory, number>> = {}
const getNextSortOrder = (category: ListingImageCategory) => {
const sortOrder = (sortOrderMap[category] || 0) + 1
sortOrderMap[category] = sortOrder
return sortOrder
}
const pushImage = (
category: ListingImageCategory,
imageUrl: string | null,
isSelected = 1,
sortOrder = getNextSortOrder(category)
) => {
images.push({
category,
imageUrl,
isSelected,
sortOrder
})
}
const getCoverFromImageUrl = () => {
if (item.coverFrom === "mainProductImage") return item.mainProductImage || null
return item.sketch
}
pushImage("sketch", item.sketch)
pushImage("cover", item.cover)
pushImage("cover_from", getCoverFromImageUrl())
if (item.mainProductImage) {
pushImage("main_product", item.mainProductImage)
}
getSortedProductMedia(item).forEach(({ media }) => {
pushImage("product", media.url, Number(!!media.selected))
})
item.sketchList.forEach((sketch) => {
pushImage("apparel", sketch.url)
})
let videoSortOrder = 0
item.prodImageList
.filter((media) => media.isVideo)
.forEach((media) => {
videoSortOrder += 1
const isSelected = Number(!!media.selected)
pushImage(
"firstFrame",
media.firstFrameUrl || media.url,
isSelected,
videoSortOrder
)
pushImage("gif", media.gifUrl || "", isSelected, videoSortOrder)
pushImage("video", media.videoUrl || "", isSelected, videoSortOrder)
})
return images
}
const handleSaveForm = async (type: StatusType) => { const handleSaveForm = async (type: StatusType) => {
const paramsList = [] const paramsList = selectList.value.map((item: ListingItem) => {
selectList.value.forEach((item: ListingItem) => { return {
const params = {
id: itemId.value, id: itemId.value,
title: item.productName, title: item.productName,
description: item.desc, description: item.desc,
price: item.price, price: item.price,
status: type === "draft" ? 0 : 1, status: type === "draft" ? 0 : 1,
images: [], images: buildListingImages(item),
designFor: (item.gender || "FEMALE").toLowerCase(), designFor: getListingDesignFor(item.gender),
productCategory: item.category productCategory: item.category
} }
;["sketch", "cover"].forEach((el) => {
params.images.push({
category: el,
imageUrl: item[el],
isSelected: 1
})
})
if (item.mainProductImage) {
params.images.push({
category: "main_product",
imageUrl: item.mainProductImage,
isSeleted: 1
})
}
item.prodImageList.forEach((item) => {
params.images.push({
category: "product",
imageUrl: item.url,
isSelected: Number(!!item.selected)
})
})
item.sketchList.forEach((item) => {
params.images.push({
category: "apparel",
imageUrl: item.url,
isSelected: 1
})
})
paramsList.push(params)
}) })
await fetchUpdateListing(paramsList) await fetchUpdateListing(paramsList)
} }
const handleClickMenu = async (status: StatusType) => { const handleClickMenu = async (status: StatusType) => {
if (status === "draft" && !selectList.value[currentIndex.value].cover) {
message.error("请先完成封面制作")
return
}
if (!validatePublishRequired()) return if (!validatePublishRequired()) return
await handleSaveForm(status) await handleSaveForm(status)
if (status === "draft") { if (status === "draft") {
// save draft logic
// console.log("Saving draft...", currentListing.value)
ROUTER.push({ ROUTER.push({
name: "Status", name: "Status",
params: { status: "draft" }, params: { status: "draft" },
@@ -424,8 +604,6 @@
} }
}) })
} else if (status === "publish") { } else if (status === "publish") {
// publish logic
// console.log("Publishing...", currentListing.value)
ROUTER.push({ ROUTER.push({
name: "Status", name: "Status",
params: { status: "publish" }, params: { status: "publish" },
@@ -438,13 +616,18 @@
} }
const handleFetchItemDetial = (list) => { const handleFetchItemDetial = (list) => {
fetchSketchDetail(list).then((res) => { fetchSketchDetail(list).then((res: SketchDetailResponse[]) => {
res.forEach((item, index) => { res.forEach((item, index) => {
if (!selectList.value[index]) return if (!selectList.value[index]) return
selectList.value[index].sketchList = item.clothes.map((el) => ({ url: el })) selectList.value[index].sketchList = (item.clothes || []).map((el) => ({ url: el }))
selectList.value[index].prodImageList = item.toProductImageUrls.map((el) => ({ const imageItems = (item.toProductImageUrls || []).map((el) => ({
url: el url: el,
selected: false
})) }))
const videoItems = (item.videos || [])
.map((video) => createProductVideoItem(video))
.filter((video): video is ProductMediaItem => Boolean(video))
selectList.value[index].prodImageList = [...imageItems, ...videoItems]
}) })
}) })
} }

View File

@@ -7,6 +7,27 @@ export type RadioOption = {
export type TopImageType = "sketch" | "mainProductImage" | "cover" export type TopImageType = "sketch" | "mainProductImage" | "cover"
export type CropType = TopImageType | "apparel" export type CropType = TopImageType | "apparel"
export type CoverSourceType = "sketch" | "mainProductImage"
export type ListingImageCategory =
| "cover"
| "cover_from"
| "main_product"
| "mainProductImage"
| "product"
| "sketch"
| "apparel"
| "firstFrame"
| "gif"
| "video"
export type ProductMediaItem = {
url: string
selected?: boolean
isVideo?: boolean
videoUrl?: string
gifUrl?: string
firstFrameUrl?: string
}
export type ListingItem = { export type ListingItem = {
designItemId: number | string | null designItemId: number | string | null
@@ -20,18 +41,18 @@ export type ListingItem = {
desc: string desc: string
gender: string gender: string
category: string[] | null category: string[] | null
coverFrom: CoverSourceType
firstSelectedIndex: number | null firstSelectedIndex: number | null
prodImageList: Array<{ prodImageList: ProductMediaItem[]
url: string
selected?: boolean
}>
sketchList: Array<{ url: string | null }> sketchList: Array<{ url: string | null }>
} }
export type ListingDetailImage = { export type ListingDetailImage = {
category?: string | null category?: ListingImageCategory | string | null
imageUrl?: string | null imageUrl?: string | null
isSelected?: boolean | number | string | null isSelected?: boolean | number | string | null
isSeleted?: boolean | number | string | null
selected?: boolean | number | string | null
sortOrder?: number | null sortOrder?: number | null
} }
@@ -45,4 +66,17 @@ export type ListingDetailResponse = {
images?: ListingDetailImage[] | null images?: ListingDetailImage[] | null
} }
export type SketchDetailVideo = {
firstFrameUrl?: string | null
gifUrl?: string | null
videoUrl?: string | null
}
export type SketchDetailResponse = {
clothes?: string[] | null
designItemId?: number | string | null
toProductImageUrls?: string[] | null
videos?: SketchDetailVideo[] | null
}
export type StatusType = "draft" | "publish" export type StatusType = "draft" | "publish"

View File

@@ -7,6 +7,7 @@ import { Https } from '@/tool/https'
import { useRoute } from 'vue-router' import { useRoute } from 'vue-router'
import { useStore } from 'vuex' import { useStore } from 'vuex'
import { useI18n } from 'vue-i18n' import { useI18n } from 'vue-i18n'
import { message } from 'ant-design-vue';
// 定义组件名称 // 定义组件名称
defineOptions({ defineOptions({
@@ -45,6 +46,10 @@ const chooseItem = (item:any)=>{
if(chooseList.value.findIndex((i:any)=>i.designItemId == item.designItemId) != -1){ if(chooseList.value.findIndex((i:any)=>i.designItemId == item.designItemId) != -1){
chooseList.value.splice(chooseList.value.findIndex((i:any)=>i.designItemId == item.designItemId),1) chooseList.value.splice(chooseList.value.findIndex((i:any)=>i.designItemId == item.designItemId),1)
}else{ }else{
if(chooseList.value.length >= 9){
message.info(t('Seller.selectSketchMaxNum'))
return
}
chooseList.value.push(item) chooseList.value.push(item)
} }
} }
@@ -163,7 +168,7 @@ const {} = toRefs(data);
<template #right> <template #right>
<div class="header-right"> <div class="header-right">
<div class="chooseNum"> <div class="chooseNum">
{{ chooseList.length }} {{ t('Seller.sketchesSelected') }} {{ chooseList.length }} / 9 {{ t('Seller.sketchesSelected') }}
</div> </div>
<div class="button" @click="next"> <div class="button" @click="next">
<span>{{ $t('Seller.Next') }}</span> <span>{{ $t('Seller.Next') }}</span>
@@ -178,7 +183,7 @@ const {} = toRefs(data);
<div class="title"> <div class="title">
<div class="left"> <div class="left">
<i class="fi fi-rs-comments"></i> <i class="fi fi-rs-comments"></i>
<span>{{ $t('Seller.ActiveListings') }}</span> <span>{{ $t('Seller.Praka') }}</span>
</div> </div>
<div class="right"> <div class="right">
<div class="generalModel_state"> <div class="generalModel_state">
@@ -317,6 +322,7 @@ const {} = toRefs(data);
margin: 0 auto; margin: 0 auto;
overflow-y: auto; overflow-y: auto;
align-content: flex-start; align-content: flex-start;
min-width: 90%;
&::-webkit-scrollbar { &::-webkit-scrollbar {
display: none; display: none;
} }

View File

@@ -400,6 +400,7 @@ const { showDrafts } = toRefs(data);
margin: 0 auto; margin: 0 auto;
align-items: flex-start; align-items: flex-start;
overflow: auto; overflow: auto;
min-width: 90%;
&::-webkit-scrollbar { &::-webkit-scrollbar {
display: none; display: none;
} }

View File

@@ -132,6 +132,7 @@ const {} = toRefs(data);
width: 100%; width: 100%;
height: 100%; height: 100%;
object-fit: cover; object-fit: cover;
background-color: #fff;
} }
> .maskBtn{ > .maskBtn{
position: absolute; position: absolute;

View File

@@ -41,7 +41,7 @@ const {} = toRefs(data);
</script> </script>
<template> <template>
<div class="myListings-seller"> <div class="myListings-seller">
<seller-header> <seller-header :displayBack="false">
<template #right> <template #right>
<div class="button" @click="newListing"> <div class="button" @click="newListing">
<span>{{ $t('Seller.newListing') }}</span> <span>{{ $t('Seller.newListing') }}</span>

View File

@@ -1,6 +1,6 @@
<template> <template>
<div class="seller-header"> <div class="seller-header">
<div class="back" @click="() => router.back()"> <div class="back" v-if="displayBack" @click="() => router.back()">
<svg-icon name="seller-back" size="24" /> <svg-icon name="seller-back" size="24" />
</div> </div>
<div class="content"> <div class="content">
@@ -55,13 +55,16 @@
defineProps<{ defineProps<{
title?: string title?: string
tip?: string tip?: string
displayBack?: boolean
breadcrumbs?: SellerBreadcrumbSource[] breadcrumbs?: SellerBreadcrumbSource[]
}>(), }>(),
{ {
title: "", title: "",
tip: "", tip: "",
breadcrumbs: () => [] breadcrumbs: () => [],
displayBack: true
} }
) )
const route = useRoute() const route = useRoute()
const router = useRouter() const router = useRouter()