Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas_plus
/
business-assistant
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 33266a7b
authored
Nov 18, 2022
by
张立顺
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
bug 修复
1 parent
42e28241
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
24 additions
and
25 deletions
packagesList/mineDetail/pages/messageBox.js
packagesList/mineDetail/pages/messageBox.wxml
pages/tab/index/index.js
utils/format.js
packagesList/mineDetail/pages/messageBox.js
View file @
33266a7
...
@@ -36,6 +36,7 @@ Component({
...
@@ -36,6 +36,7 @@ Component({
list
:
'messageList'
list
:
'messageList'
}
}
},
},
findKey
:
''
,
warReportList
:
[],
warReportList
:
[],
messageList
:
[],
messageList
:
[],
serviceMerchantId
:
''
serviceMerchantId
:
''
...
@@ -88,29 +89,21 @@ Component({
...
@@ -88,29 +89,21 @@ Component({
showPoster
(
e
)
{
showPoster
(
e
)
{
const
{
item
}
=
e
.
currentTarget
.
dataset
const
{
item
}
=
e
.
currentTarget
.
dataset
this
.
setData
({
this
.
setData
({
findKey
:
'crowdFundActivityId'
,
posterItem
:
{
posterItem
:
{
activityName
:
item
.
activityName
,
activityName
:
item
.
activityName
,
posterUrl
:
item
.
valueUrl
,
posterUrl
:
item
.
valueUrl
,
crowdFundActivityId
:
item
.
valueUrl
crowdFundActivityId
:
item
.
valueUrl
,
type
:
'warReport'
}
}
})
})
},
},
// copyLink(e) {
// console.log(e)
// let that = this
// let { url } = e.currentTarget.dataset
// this.ewmChange(url)
// setTimeout(() => {
// this.share()
// }, 100)
// },
async
copyLink
(
e
)
{
async
copyLink
(
e
)
{
const
{
item
}
=
e
.
currentTarget
.
dataset
,
const
{
item
}
=
e
.
currentTarget
.
dataset
,
posterObj
=
this
.
selectComponent
(
'#poster'
)
posterObj
=
this
.
selectComponent
(
'#poster'
)
// { options } = wx.$router.getPageInstance()
this
.
setData
({
findKey
:
'activityId'
// item.crowdFundActivityId
})
// console.log(options)
try
{
try
{
let
flag
=
await
posterObj
.
check
(
item
)
let
flag
=
await
posterObj
.
check
(
item
)
posterObj
.
setData
({
posterObj
.
setData
({
...
...
packagesList/mineDetail/pages/messageBox.wxml
View file @
33266a7
...
@@ -118,6 +118,6 @@
...
@@ -118,6 +118,6 @@
</scroll-view>
</scroll-view>
</view>
</view>
</view>
</view>
<crowdfund-poster findKey="
crowdFundActivityId
" id="poster" item="{{posterItem}}" />
<crowdfund-poster findKey="
{{findKey}}
" id="poster" item="{{posterItem}}" />
<canvas class="erweimaCanvas" style="width: 600rpx; height: 600rpx;" canvas-id="myQrcode" />
<canvas class="erweimaCanvas" style="width: 600rpx; height: 600rpx;" canvas-id="myQrcode" />
pages/tab/index/index.js
View file @
33266a7
const
navStyle
=
'background-color: transparent;'
const
navStyle
=
'background-color: transparent;'
import
{
IMG_URL
}
from
'~/utils/constantData.js'
import
{
IMG_URL
}
from
'~/utils/constantData.js'
import
Util
from
'~/utils/util.js'
// import Util from '~/utils/util.js'
import
{
deleteSecond
}
from
'~/utils/format'
import
{
senceData
}
from
'./constant/data'
import
{
senceData
}
from
'./constant/data'
const
IMAGES
=
Object
.
freeze
({
const
IMAGES
=
Object
.
freeze
({
arrow
:
`
${
IMG_URL
}
/index/point.png`
,
arrow
:
`
${
IMG_URL
}
/index/point.png`
,
...
@@ -329,7 +330,7 @@ Page({
...
@@ -329,7 +330,7 @@ Page({
//视频弹窗
//视频弹窗
wx
.
$eventbus
.
on
(
'getvideo'
,
e
=>
{
wx
.
$eventbus
.
on
(
'getvideo'
,
e
=>
{
// console.log('getvideo event bus: ', e);
// console.log('getvideo event bus: ', e);
let
url
=
U
til
.
getCurrentPageUrl
()
let
url
=
wx
.
$u
til
.
getCurrentPageUrl
()
if
(
url
==
'/pages/tab/index/index'
)
{
if
(
url
==
'/pages/tab/index/index'
)
{
let
obj
=
{
let
obj
=
{
videoTitle
:
e
.
title
,
videoTitle
:
e
.
title
,
...
@@ -430,20 +431,14 @@ Page({
...
@@ -430,20 +431,14 @@ Page({
if
(
posterId
==
result
.
valueUrl
)
return
if
(
posterId
==
result
.
valueUrl
)
return
// 为2是已经展示过了
// 为2是已经展示过了
wx
.
$storage
.
set
(
'posterId'
,
result
.
valueUrl
)
wx
.
$storage
.
set
(
'posterId'
,
result
.
valueUrl
)
let
time
=
result
.
updatedTime
.
split
(
' '
)
let
updatedTime
=
deleteSecond
(
result
.
updatedTime
)
let
moth
=
time
[
0
].
split
(
'-'
)
let
hour
=
time
[
1
].
split
(
':'
)
moth
.
shift
()
hour
=
hour
.
slice
(
0
,
-
1
)
moth
=
moth
.
join
(
'-'
)
hour
=
hour
.
join
(
':'
)
let
updatedTime
=
`
${
moth
}
${
hour
}
`
console
.
log
(
updatedTime
)
console
.
log
(
updatedTime
)
this
.
setData
({
this
.
setData
({
posterItem
:
{
posterItem
:
{
activityName
:
result
.
activityName
,
activityName
:
result
.
activityName
,
// posterUrl: 'https://wx.glsx.com.cn/upload/biz/587076735934271488.png'
// posterUrl: 'https://wx.glsx.com.cn/upload/biz/587076735934271488.png'
posterUrl
:
result
.
valueUrl
,
posterUrl
:
result
.
valueUrl
,
crowdFundActivityId
:
item
.
valueUrl
,
updatedTime
,
updatedTime
,
type
:
'warReport'
type
:
'warReport'
}
}
...
...
utils/format.js
View file @
33266a7
...
@@ -151,3 +151,14 @@ export function setPrice(price) {
...
@@ -151,3 +151,14 @@ export function setPrice(price) {
if
(
!
decimal
)
decimal
=
'00'
if
(
!
decimal
)
decimal
=
'00'
return
(
num
||
0
).
toString
().
replace
(
/
(\d)(?=(?:\d{3})
+$
)
/g
,
'$1,'
)
+
`.
${
decimal
}
`
return
(
num
||
0
).
toString
().
replace
(
/
(\d)(?=(?:\d{3})
+$
)
/g
,
'$1,'
)
+
`.
${
decimal
}
`
}
}
export
function
deleteSecond
(
time
)
{
time
=
time
.
split
(
' '
)
let
moth
=
time
[
0
].
split
(
'-'
)
let
hour
=
time
[
1
].
split
(
':'
)
moth
.
shift
()
hour
=
hour
.
slice
(
0
,
-
1
)
moth
=
moth
.
join
(
'-'
)
hour
=
hour
.
join
(
':'
)
return
`
${
moth
}
${
hour
}
`
}
Write
Preview
Markdown
is supported
Attach a file
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 post a comment