Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Q
quantum-blocks
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ui
quantum-blocks
Commits
c767e282
Commit
c767e282
authored
Jun 11, 2025
by
孙 楠
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add more i18n messages
parent
ee7a9c05
Changes
15
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
15 changed files
with
853 additions
and
799 deletions
+853
-799
navigator.ts
app/controller/navigator.ts
+5
-5
en.js
app/i18n/en.js
+414
-387
zh.js
app/i18n/zh.js
+414
-387
records.ts
app/service/records.ts
+3
-3
index.vue
app/web/lib/Form/index.vue
+1
-1
coupon.column.ts
...cForm/component/CouponTableModal/columns/coupon.column.ts
+1
-1
index.ts
...component/DynamicForm/component/CouponTableModal/index.ts
+2
-2
goodsSpecial.column.ts
.../component/GoodsTableModal/columns/goodsSpecial.column.ts
+1
-1
index.vue
...component/DynamicForm/component/SeckillSelector/index.vue
+2
-2
index.vue
...nt/DynamicForm/component/SnapUpActivitySelector/index.vue
+2
-2
index.ts
...ditor/component/DynamicForm/component/TableModal/index.ts
+3
-3
index.vue
app/web/page/editor/component/QgTable/index.vue
+2
-2
goodsTabs.mixin.ts
app/web/page/editor/mixins/goodsTabs.mixin.ts
+1
-1
index.vue
app/web/page/editor/view/navigator/index.vue
+1
-1
http.service.ts
app/web/service/http.service.ts
+1
-1
No files found.
app/controller/navigator.ts
View file @
c767e282
...
@@ -8,7 +8,7 @@ export default class NavigatorController extends Controller {
...
@@ -8,7 +8,7 @@ export default class NavigatorController extends Controller {
const
list
=
await
ctx
.
service
.
navigator
.
getList
(
pageNo
,
pageSize
,
name
,
author
);
const
list
=
await
ctx
.
service
.
navigator
.
getList
(
pageNo
,
pageSize
,
name
,
author
);
ctx
.
body
=
ctx
.
helper
.
ok
(
list
);
ctx
.
body
=
ctx
.
helper
.
ok
(
list
);
}
catch
(
e
)
{
}
catch
(
e
)
{
ctx
.
logger
.
info
(
`
获取导航配置数据异常,
${
JSON
.
stringify
(
e
)}
`
);
ctx
.
logger
.
info
(
`
${
$t
(
'
failed.to.get.navigation.config
'
)}
${
JSON
.
stringify
(
e
)}
`
);
ctx
.
body
=
ctx
.
helper
.
fail
({
ctx
.
body
=
ctx
.
helper
.
fail
({
message
:
$t
(
'
data.fetch.error
'
)
message
:
$t
(
'
data.fetch.error
'
)
});
});
...
@@ -21,7 +21,7 @@ export default class NavigatorController extends Controller {
...
@@ -21,7 +21,7 @@ export default class NavigatorController extends Controller {
const
list
=
await
ctx
.
service
.
navigator
.
getNavigatorConfigListWithRelation
(
pageNo
,
pageSize
,
name
,
author
,
id
);
const
list
=
await
ctx
.
service
.
navigator
.
getNavigatorConfigListWithRelation
(
pageNo
,
pageSize
,
name
,
author
,
id
);
ctx
.
body
=
ctx
.
helper
.
ok
(
list
);
ctx
.
body
=
ctx
.
helper
.
ok
(
list
);
}
catch
(
e
)
{
}
catch
(
e
)
{
ctx
.
logger
.
info
(
`
获取导航配置数据异常,
${
JSON
.
stringify
(
e
)}
`
);
ctx
.
logger
.
info
(
`
${
$t
(
'
failed.to.get.navigation.config
'
)}
${
JSON
.
stringify
(
e
)}
`
);
ctx
.
body
=
ctx
.
helper
.
fail
({
ctx
.
body
=
ctx
.
helper
.
fail
({
message
:
$t
(
'
data.fetch.error
'
)
message
:
$t
(
'
data.fetch.error
'
)
});
});
...
@@ -34,7 +34,7 @@ export default class NavigatorController extends Controller {
...
@@ -34,7 +34,7 @@ export default class NavigatorController extends Controller {
await
ctx
.
service
.
navigator
.
deleteById
(
id
);
await
ctx
.
service
.
navigator
.
deleteById
(
id
);
ctx
.
body
=
ctx
.
helper
.
ok
({});
ctx
.
body
=
ctx
.
helper
.
ok
({});
}
catch
(
e
)
{
}
catch
(
e
)
{
ctx
.
logger
.
info
(
`
删除导航配置异常,
${
JSON
.
stringify
(
e
)}
`
);
ctx
.
logger
.
info
(
`
${
$t
(
'
failed.to.delete.navigation.config
'
)}
${
JSON
.
stringify
(
e
)}
`
);
ctx
.
body
=
ctx
.
helper
.
fail
({
ctx
.
body
=
ctx
.
helper
.
fail
({
message
:
$t
(
'
failed.to.delete.nav.config
'
)
message
:
$t
(
'
failed.to.delete.nav.config
'
)
});
});
...
@@ -63,7 +63,7 @@ export default class NavigatorController extends Controller {
...
@@ -63,7 +63,7 @@ export default class NavigatorController extends Controller {
await
ctx
.
service
.
navigator
.
saveOrUpdate
(
pageInfo
);
await
ctx
.
service
.
navigator
.
saveOrUpdate
(
pageInfo
);
ctx
.
body
=
ctx
.
helper
.
ok
({});
ctx
.
body
=
ctx
.
helper
.
ok
({});
}
catch
(
e
)
{
}
catch
(
e
)
{
ctx
.
logger
.
info
(
`
保存导航配置异常,
${
JSON
.
stringify
(
e
)}
`
);
ctx
.
logger
.
info
(
`
${
$t
(
'
failed.to.save.navigation.config
'
)}
${
JSON
.
stringify
(
e
)}
`
);
ctx
.
body
=
ctx
.
helper
.
fail
({
ctx
.
body
=
ctx
.
helper
.
fail
({
message
:
$t
(
'
failed.to.save.nav.config
'
)
message
:
$t
(
'
failed.to.save.nav.config
'
)
});
});
...
@@ -76,7 +76,7 @@ export default class NavigatorController extends Controller {
...
@@ -76,7 +76,7 @@ export default class NavigatorController extends Controller {
const
res
=
await
ctx
.
service
.
navigator
.
getDetail
(
navId
);
const
res
=
await
ctx
.
service
.
navigator
.
getDetail
(
navId
);
ctx
.
body
=
ctx
.
helper
.
ok
(
res
);
ctx
.
body
=
ctx
.
helper
.
ok
(
res
);
}
catch
(
e
)
{
}
catch
(
e
)
{
ctx
.
logger
.
info
(
`
查询导航配置异常,
${
JSON
.
stringify
(
e
)}
`
);
ctx
.
logger
.
info
(
`
${
$t
(
'
failed.to.query.navigation.config
'
)}
${
JSON
.
stringify
(
e
)}
`
);
ctx
.
body
=
ctx
.
helper
.
fail
({
ctx
.
body
=
ctx
.
helper
.
fail
({
message
:
$t
(
'
failed.to.query.nav.config
'
)
message
:
$t
(
'
failed.to.query.nav.config
'
)
});
});
...
...
app/i18n/en.js
View file @
c767e282
This diff is collapsed.
Click to expand it.
app/i18n/zh.js
View file @
c767e282
This diff is collapsed.
Click to expand it.
app/service/records.ts
View file @
c767e282
...
@@ -10,7 +10,7 @@ export default class RecordsService extends Service {
...
@@ -10,7 +10,7 @@ export default class RecordsService extends Service {
// 操作记录表直接删除一年以上的操作记录
// 操作记录表直接删除一年以上的操作记录
const
limitDate
=
new
Date
(
new
Date
().
getTime
()
-
365
*
24
*
3600
*
1000
).
toLocaleDateString
().
replace
(
/
\/
/g
,
'
-
'
)
const
limitDate
=
new
Date
(
new
Date
().
getTime
()
-
365
*
24
*
3600
*
1000
).
toLocaleDateString
().
replace
(
/
\/
/g
,
'
-
'
)
try
{
try
{
this
.
context
.
logger
.
info
(
`
开始删除页面历史记录,删除范围为日期在
${
limitDate
}
之前的所有记录
`
);
this
.
context
.
logger
.
info
(
`
${
$t
(
'
deleting.page.history.from.date
'
)}${
limitDate
}${
$t
(
'
all.previous.records
'
)}
`
);
await
this
.
context
.
model
.
PageHistory
.
destroy
({
await
this
.
context
.
model
.
PageHistory
.
destroy
({
where
:
{
where
:
{
updated_at
:
{
updated_at
:
{
...
@@ -18,9 +18,9 @@ export default class RecordsService extends Service {
...
@@ -18,9 +18,9 @@ export default class RecordsService extends Service {
}
}
}
}
});
});
this
.
context
.
logger
.
info
(
`
页面历史记录删除成功,删除范围为日期在
${
limitDate
}
之前的所有记录
`
);
this
.
context
.
logger
.
info
(
`
${
$t
(
'
page.history.deleted.from.date
'
)}${
limitDate
}${
$t
(
'
all.previous.records
'
)}
`
);
}
catch
(
err
)
{
}
catch
(
err
)
{
this
.
context
.
logger
.
info
(
`
页面历史记录删除失败,失败原因:
${
JSON
.
stringify
(
err
)}
`
);
this
.
context
.
logger
.
info
(
`
${
$t
(
'
failed.to.delete.page.history
'
)}
${
JSON
.
stringify
(
err
)}
`
);
}
}
return
;
return
;
}
}
...
...
app/web/lib/Form/index.vue
View file @
c767e282
...
@@ -115,7 +115,7 @@ export default {
...
@@ -115,7 +115,7 @@ export default {
return
!
isPhone
(
this
.
formData
.
phoneNo
);
return
!
isPhone
(
this
.
formData
.
phoneNo
);
},
},
captchaBtnText
()
{
captchaBtnText
()
{
return
this
.
showCount
?
`
剩余
${
this
.
count
}
秒
`
:
$t
(
'
get.verification.code
'
);
return
this
.
showCount
?
`
${
$t
(
'
remaining
'
)}${
this
.
count
}${
$t
(
'
seconds
'
)}
`
:
$t
(
'
get.verification.code
'
);
},
},
btnStyles
()
{
btnStyles
()
{
return
this
.
btnImage
?
{
return
this
.
btnImage
?
{
...
...
app/web/page/editor/component/DynamicForm/component/CouponTableModal/columns/coupon.column.ts
View file @
c767e282
...
@@ -108,7 +108,7 @@ const columns: object[] = [
...
@@ -108,7 +108,7 @@ const columns: object[] = [
key
:
''
,
key
:
''
,
hideSearch
:
true
,
hideSearch
:
true
,
render
:
(
h
,
params
)
=>
{
render
:
(
h
,
params
)
=>
{
const
obj
=
params
.
row
.
couponType
===
1
?
`
满
${
params
.
row
.
limitAmt
}
减
${
params
.
row
.
couponAmt
}
元`
:
`满
${
params
.
row
.
limitAmt
}
可用
`
;
const
obj
=
params
.
row
.
couponType
===
1
?
`
${
$t
(
'
full
'
)}${
params
.
row
.
limitAmt
}${
$t
(
'
minus
'
)}${
params
.
row
.
couponAmt
}${
$t
(
'
yuan
'
)}
`
:
`
${
$t
(
'
full
'
)}${
params
.
row
.
limitAmt
}${
$t
(
'
available
'
)}
`
;
return
h
(
'
div
'
,
obj
);
return
h
(
'
div
'
,
obj
);
},
},
},
},
...
...
app/web/page/editor/component/DynamicForm/component/CouponTableModal/index.ts
View file @
c767e282
...
@@ -37,8 +37,8 @@ export default class CouponTableModal extends Vue {
...
@@ -37,8 +37,8 @@ export default class CouponTableModal extends Vue {
item
.
useTime
=
item
.
useTimeStart
item
.
useTime
=
item
.
useTimeStart
?
`
${
item
.
useTimeStart
}
-
${
item
.
useTimeEnd
}
`
?
`
${
item
.
useTimeStart
}
-
${
item
.
useTimeEnd
}
`
:
item
.
validHours
:
item
.
validHours
?
`
自领取后有效
${
item
.
validHours
}
小时
`
?
`
${
$t
(
'
valid.since.claim
'
)}${
item
.
validHours
}${
$t
(
'
hours
'
)}
`
:
`
自领取
${
item
.
receiverDaysValid
}
天后生效,有效天数
${
item
.
validDays
}
天
`
;
:
`
${
$t
(
'
valid.after.claim
'
)}${
item
.
receiverDaysValid
}${
$t
(
'
takes.effect.in.days.valid.for.1.days
'
)}${
item
.
validDays
}${
$t
(
'
days
'
)}
`
;
// item.useTime = item.useTimeStart ? `${item.useTimeStart}-${item.useTimeEnd}` : `自领取${item.receiverDaysValid}天后生效,有效天数${item.validDays}天`;
// item.useTime = item.useTimeStart ? `${item.useTimeStart}-${item.useTimeEnd}` : `自领取${item.receiverDaysValid}天后生效,有效天数${item.validDays}天`;
}
}
const
selections
=
this
.
templates
.
length
?
this
.
templates
:
this
.
coupon
;
const
selections
=
this
.
templates
.
length
?
this
.
templates
:
this
.
coupon
;
...
...
app/web/page/editor/component/DynamicForm/component/GoodsTableModal/columns/goodsSpecial.column.ts
View file @
c767e282
...
@@ -20,7 +20,7 @@ const groupColumns = function() {
...
@@ -20,7 +20,7 @@ const groupColumns = function() {
key
:
'
validityTime
'
,
key
:
'
validityTime
'
,
hideSearch
:
true
,
hideSearch
:
true
,
render
:
(
h
,
params
)
=>
{
render
:
(
h
,
params
)
=>
{
const
time
=
`
${
params
.
row
.
startTime
}
至
${
params
.
row
.
endTime
}
`
;
const
time
=
`
${
params
.
row
.
startTime
}
${
$t
(
'
to
'
)}
${
params
.
row
.
endTime
}
`
;
return
h
(
'
div
'
,
time
);
return
h
(
'
div
'
,
time
);
},
},
},
},
...
...
app/web/page/editor/component/DynamicForm/component/SeckillSelector/index.vue
View file @
c767e282
...
@@ -79,7 +79,7 @@ export default {
...
@@ -79,7 +79,7 @@ export default {
invalidArr
.
map
(
item
=>
{
invalidArr
.
map
(
item
=>
{
ids
+=
`
${
item
.
id
}
,`
ids
+=
`
${
item
.
id
}
,`
})
})
this
.
$Notice
.
error
({
title
:
$t
(
'
hint
'
),
desc
:
`
以下活动id不符合当前活动类型:
${
ids
}
`
});
this
.
$Notice
.
error
({
title
:
$t
(
'
hint
'
),
desc
:
`
${
$t
(
'
activity.id.does.not.match.current.type
'
)}
${
ids
}
`
});
return
;
return
;
}
}
// 判断填入的活动ID是否存在重复的渠道ID的情况
// 判断填入的活动ID是否存在重复的渠道ID的情况
...
@@ -110,7 +110,7 @@ export default {
...
@@ -110,7 +110,7 @@ export default {
console
.
log
(
channel2Id
,
'
channel2Id
'
)
console
.
log
(
channel2Id
,
'
channel2Id
'
)
for
(
let
i
in
channel2Id
)
{
for
(
let
i
in
channel2Id
)
{
if
(
channel2Id
[
i
].
length
>
1
)
{
if
(
channel2Id
[
i
].
length
>
1
)
{
this
.
$Notice
.
error
({
title
:
$t
(
'
hint
'
),
desc
:
`
${
i
==
'
common
'
?
'
通用渠道
'
:
$t
(
'
channel
'
)
+
i
}
存在重复的活动ID:
${
channel2Id
[
i
].
join
(
'
,
'
)}
`
});
this
.
$Notice
.
error
({
title
:
$t
(
'
hint
'
),
desc
:
`
${
i
==
'
common
'
?
'
通用渠道
'
:
$t
(
'
channel
'
)
+
i
}
${
$t
(
'
duplicate.activity.id
'
)}
${
channel2Id
[
i
].
join
(
'
,
'
)}
`
});
return
;
return
;
}
}
}
}
...
...
app/web/page/editor/component/DynamicForm/component/SnapUpActivitySelector/index.vue
View file @
c767e282
...
@@ -80,7 +80,7 @@ export default {
...
@@ -80,7 +80,7 @@ export default {
invalidArr
.
map
(
item
=>
{
invalidArr
.
map
(
item
=>
{
ids
+=
`${item.id
}
,`
ids
+=
`${item.id
}
,`
}
)
}
)
this
.
$Notice
.
error
({
title
:
$t
(
'
hint
'
),
desc
:
`
以下活动id不符合当前活动类型:
${ids
}
`
}
);
this
.
$Notice
.
error
({
title
:
$t
(
'
hint
'
),
desc
:
`
${$t('activity.id.does.not.match.current.type')
}
${ids
}
`
}
);
return
;
return
;
}
}
// 判断填入的活动ID是否存在重复的渠道ID的情况
// 判断填入的活动ID是否存在重复的渠道ID的情况
...
@@ -111,7 +111,7 @@ export default {
...
@@ -111,7 +111,7 @@ export default {
console
.
log
(
channel2Id
,
'
channel2Id
'
)
console
.
log
(
channel2Id
,
'
channel2Id
'
)
for
(
let
i
in
channel2Id
)
{
for
(
let
i
in
channel2Id
)
{
if
(
channel2Id
[
i
].
length
>
1
)
{
if
(
channel2Id
[
i
].
length
>
1
)
{
this
.
$Notice
.
error
({
title
:
$t
(
'
hint
'
),
desc
:
`${i == 'common' ? '通用渠道' : $t('channel') + i
}
存在重复的活动ID:
${channel2Id[i].join(',')
}
`
}
);
this
.
$Notice
.
error
({
title
:
$t
(
'
hint
'
),
desc
:
`${i == 'common' ? '通用渠道' : $t('channel') + i
}
${$t('duplicate.activity.id')
}
${channel2Id[i].join(',')
}
`
}
);
return
;
return
;
}
}
}
}
...
...
app/web/page/editor/component/DynamicForm/component/TableModal/index.ts
View file @
c767e282
...
@@ -208,13 +208,13 @@ export default class DynamicForm extends Mixins(DynamicFormMixin) {
...
@@ -208,13 +208,13 @@ export default class DynamicForm extends Mixins(DynamicFormMixin) {
let
rs
=
''
;
let
rs
=
''
;
switch
(
type
)
{
switch
(
type
)
{
case
'
edit
'
:
case
'
edit
'
:
rs
=
`
编辑
${
this
.
title
}
`
;
rs
=
`
${
$t
(
'
edit
'
)}
${
this
.
title
}
`
;
break
;
break
;
case
'
add
'
:
case
'
add
'
:
rs
=
`
添加
${
this
.
title
}
`
;
rs
=
`
${
$t
(
'
add
'
)}
${
this
.
title
}
`
;
break
;
break
;
case
'
choose
'
:
case
'
choose
'
:
rs
=
`
选择
${
this
.
title
}
`
;
rs
=
`
${
$t
(
'
select
'
)}
${
this
.
title
}
`
;
break
;
break
;
}
}
return
rs
;
return
rs
;
...
...
app/web/page/editor/component/QgTable/index.vue
View file @
c767e282
...
@@ -28,7 +28,7 @@
...
@@ -28,7 +28,7 @@
</div>
</div>
</div>
</div>
<Tabs
class=
"table-tabs"
v-if=
"showSelected"
:value=
"selectedTab"
>
<Tabs
class=
"table-tabs"
v-if=
"showSelected"
:value=
"selectedTab"
>
<TabPane
name=
"1"
:label=
"`
全部
$
{title}`">
<TabPane
name=
"1"
:label=
"`
$
{$t('all')}
${title}`">
<Table
<Table
:height=
"height"
:height=
"height"
@
on-select-cancel=
"selectionCancel"
@
on-select-cancel=
"selectionCancel"
...
@@ -49,7 +49,7 @@
...
@@ -49,7 +49,7 @@
@
on-page-size-change=
"changePageSize"
@
on-page-size-change=
"changePageSize"
/>
/>
</TabPane>
</TabPane>
<TabPane
name=
"2"
:label=
"`
已选
$
{title}`">
<TabPane
name=
"2"
:label=
"`
$
{$t('selected')}
${title}`">
<Table
<Table
:height=
"height"
:height=
"height"
@
on-select-cancel=
"selectionCancel"
@
on-select-cancel=
"selectionCancel"
...
...
app/web/page/editor/mixins/goodsTabs.mixin.ts
View file @
c767e282
...
@@ -114,7 +114,7 @@ export default class GoodsTabsMixin extends Vue {
...
@@ -114,7 +114,7 @@ export default class GoodsTabsMixin extends Vue {
if
(
element
.
name
===
'
cs-goods-tabs
'
||
element
.
name
===
'
cs-floor-nav
'
)
{
if
(
element
.
name
===
'
cs-goods-tabs
'
||
element
.
name
===
'
cs-floor-nav
'
)
{
element
.
props
?.
list
.
forEach
(
item
=>
{
element
.
props
?.
list
.
forEach
(
item
=>
{
if
(
item
.
componentId
&&
selectedComponentIds
.
includes
(
item
.
componentId
))
{
if
(
item
.
componentId
&&
selectedComponentIds
.
includes
(
item
.
componentId
))
{
throw
new
Error
(
`
组件<
${
element
.
title
}${
element
.
id
}
>存在重复组件,请修改后继续操作
`
);
throw
new
Error
(
`
${
$t
(
'
component
'
)}${
element
.
title
}${
element
.
id
}${
$t
(
'
duplicate.component.exists.please.modify
'
)}
`
);
}
else
{
}
else
{
selectedComponentIds
.
push
(
item
.
componentId
);
selectedComponentIds
.
push
(
item
.
componentId
);
}
}
...
...
app/web/page/editor/view/navigator/index.vue
View file @
c767e282
...
@@ -146,7 +146,7 @@ export default {
...
@@ -146,7 +146,7 @@ export default {
// 删除
// 删除
this
.
$Modal
.
confirm
({
this
.
$Modal
.
confirm
({
title
:
$t
(
'
hint
'
),
title
:
$t
(
'
hint
'
),
content
:
`
是否删除导航
${
row
.
name
}
`
,
content
:
`
${
$t
(
'
delete.navigation
'
)}
${
row
.
name
}
`
,
onOk
:
async
()
=>
{
onOk
:
async
()
=>
{
const
deleteRes
=
await
navigatorApi
.
deleteNavigator
({
const
deleteRes
=
await
navigatorApi
.
deleteNavigator
({
id
:
row
.
id
id
:
row
.
id
...
...
app/web/service/http.service.ts
View file @
c767e282
...
@@ -170,7 +170,7 @@ instance.interceptors.response.use(
...
@@ -170,7 +170,7 @@ instance.interceptors.response.use(
// 错误提示
// 错误提示
let
message
=
''
;
let
message
=
''
;
if
(
err
.
response
)
{
if
(
err
.
response
)
{
message
=
ERR_MESSAGE_MAP
.
status
[
err
.
response
.
status
]
||
`
连接错误
${
err
.
response
.
status
}
`
;
message
=
ERR_MESSAGE_MAP
.
status
[
err
.
response
.
status
]
||
`
${
$t
(
'
connection.error
'
)}
${
err
.
response
.
status
}
`
;
}
else
{
}
else
{
message
=
$t
(
'
failed.to.connect.to.server
'
);
message
=
$t
(
'
failed.to.connect.to.server
'
);
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment