Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
B
bigwood
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
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
罗超
bigwood
Commits
99eb9318
Commit
99eb9318
authored
Apr 13, 2025
by
罗超
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改
parent
63575108
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
345 additions
and
358 deletions
+345
-358
redEnvelope.vue
src/components/passbook/redEnvelope.vue
+215
-220
index.ts
src/i18n/en-US/index.ts
+2
-1
index.ts
src/i18n/ja-RB/index.ts
+3
-2
index.ts
src/i18n/zh-SW/index.ts
+3
-2
index.ts
src/i18n/zh-TW/index.ts
+3
-2
passbook.vue
src/pages/passbook/passbook.vue
+119
-131
No files found.
src/components/passbook/redEnvelope.vue
View file @
99eb9318
This diff is collapsed.
Click to expand it.
src/i18n/en-US/index.ts
View file @
99eb9318
...
...
@@ -1524,7 +1524,7 @@ export default {
text6
:
'Revenue in the past six months'
,
text7
:
'Time selection'
,
text8
:
'Select month'
,
text9
:
'
Accumulated number of transactions
this year'
,
text9
:
'
Number of people
this year'
,
text10
:
'Accumulated revenue'
,
text11
:
'Month Number'
,
text12
:
'Activated, expected revenue'
,
...
...
@@ -1532,6 +1532,7 @@ export default {
text14
:
'Estimated Revenue'
,
text15
:
'Monthly transaction amount has been reached'
,
text16
:
'Return'
,
text17
:
'up'
,
},
col
:
{
title1
:
'Order'
,
...
...
src/i18n/ja-RB/index.ts
View file @
99eb9318
...
...
@@ -1522,14 +1522,15 @@ export default {
text6
:
'半年近くの収益'
,
text7
:
'時間の選択'
,
text8
:
'選択月'
,
text9
:
'本年の累計
取引総額です
'
,
text9
:
'本年の累計
人数
'
,
text10
:
'累積収益'
,
text11
:
'
当面の取引額
'
,
text11
:
'
現在の人数
'
,
text12
:
'活性化しています,収益見込み'
,
text13
:
'まだまだ'
,
text14
:
'収益予想'
,
text15
:
'月の取引額はすでに達しました'
,
text16
:
'返します'
,
text17
:
'以下'
,
},
col
:{
title1
:
'註文します'
,
...
...
src/i18n/zh-SW/index.ts
View file @
99eb9318
...
...
@@ -1525,14 +1525,15 @@ export default {
text6
:
'近半年收益'
,
text7
:
'时间选择'
,
text8
:
'选择月份'
,
text9
:
'本年累计
交易总额
'
,
text9
:
'本年累计
人数
'
,
text10
:
'累计收益'
,
text11
:
'当前
交易额
'
,
text11
:
'当前
人数
'
,
text12
:
'已激活,预计收益'
,
text13
:
'还差'
,
text14
:
'预计收益'
,
text15
:
'月交易额已达'
,
text16
:
'返'
,
text17
:
'以上'
,
},
col
:{
title1
:
'订单'
,
...
...
src/i18n/zh-TW/index.ts
View file @
99eb9318
...
...
@@ -1527,14 +1527,15 @@ export default {
text6
:
'近半年收益'
,
text7
:
'時間選擇'
,
text8
:
'選擇月份'
,
text9
:
'本年累計
交易總額
'
,
text9
:
'本年累計
人數
'
,
text10
:
'累計收益'
,
text11
:
'當前
交易額
'
,
text11
:
'當前
人數
'
,
text12
:
'已激活,預計收益'
,
text13
:
'還差'
,
text14
:
'預計收益'
,
text15
:
'月交易額已達'
,
text16
:
'返'
,
text17
:
'以上'
,
},
col
:{
title1
:
'訂單'
,
...
...
src/pages/passbook/passbook.vue
View file @
99eb9318
<
template
>
<div
class=
"column items-center"
>
<div
class=
"q-mt-sm q-mb-lg"
:class=
"[$q.platform.is.desktop?'passbook-form':'']"
:style=
"
{'width':$q.platform.is.mobile?'100%':''}">
<transition-group
v-if=
"!isUseDetails"
appear
enter-active-class=
"animated fadeInRight"
leave-active-class=
"animated fadeInLeft"
>
<template
v-if=
"MonthObj&&datainfo"
>
<passbookHead
:dataNum=
"datainfo?datainfo.Client_Balance:0"
/>
<!--
<rebate/>
-->
<redEnvelope
:Obj=
"MonthObj"
:info=
"datainfo"
/>
</
template
>
</transition-group>
<transition
v-else
appear
enter-active-class=
"animated fadeInLeft"
leave-active-class=
"animated fadeInRight"
>
<useDetails/>
</transition>
</div>
<div
class=
"column items-center"
>
<div
class=
"q-mt-sm q-mb-lg"
:class=
"[$q.platform.is.desktop ? 'passbook-form' : '']"
:style=
"
{ width: $q.platform.is.mobile ? '100%' : '' }">
<transition-group
v-if=
"!isUseDetails"
appear
enter-active-class=
"animated fadeInRight"
leave-active-class=
"animated fadeInLeft"
>
<template
v-if=
"MonthObj && datainfo"
>
<passbookHead
:dataNum=
"datainfo ? datainfo.Client_Balance : 0"
/>
<!--
<rebate/>
-->
<redEnvelope
:Obj=
"MonthObj"
:info=
"datainfo"
/>
</
template
>
</transition-group>
<transition
v-else
appear
enter-active-class=
"animated fadeInLeft"
leave-active-class=
"animated fadeInRight"
>
<useDetails
/>
</transition>
</div>
</div>
</template>
<
script
lang=
"ts"
>
import
useMetaModule
from
'../../module/meta/metaModule'
import
{
useRouter
}
from
'vue-router'
;
import
{
defineComponent
,
ref
,
reactive
,
toRefs
,
provide
,
inject
}
from
'vue'
import
{
useQuasar
}
from
'quasar'
import
{
ApiResult
}
from
'../../@types/enumHelper'
import
message
from
'../../utils/message'
import
{
useI18n
}
from
'vue-i18n'
import
Store
from
'../../store'
import
{
DirtionmaryHelper
}
from
'../../config/dictionary'
import
passbookHead
from
'../../components/passbook/passbookHead.vue'
import
rebate
from
'../../components/passbook/rebate.vue'
import
redEnvelope
from
'../../components/passbook/redEnvelope.vue'
import
useDetails
from
'../../components/passbook/useDetails.vue'
import
passbookService
from
'../../api/passbook'
export
default
defineComponent
({
name
:
'user-info'
,
components
:
{
passbookHead
,
rebate
,
redEnvelope
,
useDetails
},
props
:
{},
setup
()
{
import
useMetaModule
from
'../../module/meta/metaModule'
import
{
useRouter
}
from
'vue-router'
import
{
defineComponent
,
ref
,
reactive
,
toRefs
,
provide
,
inject
}
from
'vue'
import
{
useQuasar
}
from
'quasar'
import
{
ApiResult
}
from
'../../@types/enumHelper'
import
message
from
'../../utils/message'
import
{
useI18n
}
from
'vue-i18n'
import
Store
from
'../../store'
import
{
DirtionmaryHelper
}
from
'../../config/dictionary'
import
passbookHead
from
'../../components/passbook/passbookHead.vue'
import
rebate
from
'../../components/passbook/rebate.vue'
import
redEnvelope
from
'../../components/passbook/redEnvelope.vue'
import
useDetails
from
'../../components/passbook/useDetails.vue'
import
passbookService
from
'../../api/passbook'
export
default
defineComponent
({
name
:
'user-info'
,
components
:
{
passbookHead
,
rebate
,
redEnvelope
,
useDetails
},
props
:
{},
setup
()
{
const
$router
=
useRouter
()
const
$q
=
useQuasar
()
const
data
=
reactive
({
datainfo
:
null
as
Object
,
xMonth
:
[]
as
Array
<
any
>
,
yMoney1
:
[]
as
Array
<
any
>
,
yMoney2
:
[]
as
Array
<
any
>
,
MonthObj
:
null
as
Object
})
const
$router
=
useRouter
();
const
$q
=
useQuasar
()
const
data
=
reactive
({
datainfo
:
null
as
Object
,
xMonth
:[]
as
Array
<
any
>
,
yMoney1
:[]
as
Array
<
any
>
,
yMoney2
:[]
as
Array
<
any
>
,
MonthObj
:
null
as
Object
})
let
{
setTitle
}
=
useMetaModule
()
const
{
locale
,
t
}
=
useI18n
()
const
pageTitle
=
inject
(
DirtionmaryHelper
.
PAGE_TITLE_KEY
)
as
any
pageTitle
.
value
=
t
(
'v104.passbook.pageTitle'
)
setTitle
(
pageTitle
.
value
)
const
ratioListBase
=
ref
([
{
Money
:
5
,
Ratio
:
100000
,
},
{
Money
:
11
,
Ratio
:
150000
,
},
{
Money
:
16
,
Ratio
:
200000
,
},
{
Money
:
21
,
Ratio
:
250000
,
},
])
const
isUseDetails
=
ref
(
false
)
provide
(
DirtionmaryHelper
.
PASSBOOK_DETAILS
,
isUseDetails
)
const
methods
=
{
GetBigRedEnvelope
()
{
let
CustomerId
if
(
Store
.
state
&&
Store
.
state
.
user
?.
userDetail
)
{
CustomerId
=
Store
.
state
.
user
?.
userDetail
?.
customerId
}
$q
.
loading
.
show
()
passbookService
.
GetCustomerBigRedEnvelope
(
CustomerId
)
.
then
(
r
=>
{
let
arr1
=
[
'-'
,
'-'
,
'-'
,
'-'
];
let
newarr
=
[];
if
(
r
.
data
.
resultCode
==
ApiResult
.
SUCCESS
)
{
data
.
datainfo
=
r
.
data
.
data
;
data
.
datainfo
.
JQLRList
.
forEach
((
item
,
index
)
=>
{
data
.
xMonth
.
push
(
item
.
Date
)
if
(
index
<
5
){
data
.
yMoney1
.
push
(
item
.
Money
)
}
if
(
index
>
3
){
newarr
.
push
(
item
.
Money
);
data
.
yMoney2
=
arr1
.
concat
(
newarr
);
}
})
data
.
datainfo
.
RatioList
=
ratioListBase
.
value
data
.
datainfo
.
RatioList
.
forEach
(
item
=>
{
item
.
percent
=
data
.
datainfo
.
Amount
/
item
.
Money
;
item
.
width
=
(
item
.
percent
)
*
100
;
})
console
.
log
(
data
.
datainfo
.
RatioList
)
data
.
yMoney1
=
data
.
yMoney1
.
concat
([
"-"
]);
data
.
MonthObj
=
{
xMonth
:
data
.
xMonth
,
yMoney1
:
data
.
yMoney1
,
yMoney2
:
data
.
yMoney2
let
{
setTitle
}
=
useMetaModule
()
const
{
locale
,
t
}
=
useI18n
()
const
pageTitle
=
inject
(
DirtionmaryHelper
.
PAGE_TITLE_KEY
)
as
any
pageTitle
.
value
=
t
(
'v104.passbook.pageTitle'
)
setTitle
(
pageTitle
.
value
)
const
ratioListBase
=
ref
([
{
Money
:
5
,
Ratio
:
100000
},
{
Money
:
11
,
Ratio
:
150000
},
{
Money
:
16
,
Ratio
:
200000
},
{
Money
:
21
,
Ratio
:
250000
}
])
const
isUseDetails
=
ref
(
false
)
provide
(
DirtionmaryHelper
.
PASSBOOK_DETAILS
,
isUseDetails
)
const
methods
=
{
GetBigRedEnvelope
()
{
let
CustomerId
if
(
Store
.
state
&&
Store
.
state
.
user
?.
userDetail
)
{
CustomerId
=
Store
.
state
.
user
?.
userDetail
?.
customerId
}
$q
.
loading
.
show
()
passbookService
.
GetCustomerBigRedEnvelope
(
CustomerId
)
.
then
(
r
=>
{
let
arr1
=
[
'-'
,
'-'
,
'-'
,
'-'
]
let
newarr
=
[]
if
(
r
.
data
.
resultCode
==
ApiResult
.
SUCCESS
)
{
data
.
datainfo
=
r
.
data
.
data
data
.
datainfo
.
JQLRList
.
forEach
((
item
,
index
)
=>
{
data
.
xMonth
.
push
(
item
.
Date
)
if
(
index
<
5
)
{
data
.
yMoney1
.
push
(
item
.
Money
)
}
}
else
{
message
.
errorMsg
(
r
.
data
.
message
)
if
(
index
>
3
)
{
newarr
.
push
(
item
.
Money
)
data
.
yMoney2
=
arr1
.
concat
(
newarr
)
}
})
data
.
datainfo
.
RatioList
=
ratioListBase
.
value
data
.
datainfo
.
GuestNum
=
data
.
datainfo
.
GuestNum
?
data
.
datainfo
.
GuestNum
:
0
data
.
datainfo
.
RatioList
.
forEach
(
item
=>
{
item
.
percent
=
data
.
datainfo
.
GuestNum
/
item
.
Money
item
.
width
=
item
.
percent
*
100
})
data
.
yMoney1
=
data
.
yMoney1
.
concat
([
'-'
])
data
.
MonthObj
=
{
xMonth
:
data
.
xMonth
,
yMoney1
:
data
.
yMoney1
,
yMoney2
:
data
.
yMoney2
}
$q
.
loading
.
hide
()
})
.
catch
(
r
=>
{
$q
.
loading
.
hide
()
message
.
errorMsg
(
r
.
message
)
})
},
}
else
{
message
.
errorMsg
(
r
.
data
.
message
)
}
$q
.
loading
.
hide
()
})
.
catch
(
r
=>
{
$q
.
loading
.
hide
()
message
.
errorMsg
(
r
.
message
)
})
}
methods
.
GetBigRedEnvelope
()
return
{...
toRefs
(
data
),
isUseDetails
,...
methods
}
}
})
</
script
>
methods
.
GetBigRedEnvelope
()
return
{
...
toRefs
(
data
),
isUseDetails
,
...
methods
}
}
})
</
script
>
<
style
>
.passbook-form
{
width
:
963px
;
/* min-width: 663px; */
.passbook-form
{
width
:
963px
;
/* min-width: 663px; */
}
</
style
>
\ No newline at end of file
</
style
>
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