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 55c0c112
authored
Nov 11, 2022
by
chenwq
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
联调,样式
1 parent
9fb68234
Hide whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
312 additions
and
111 deletions
api/outputApi/output.js
components/SceneBox/SceneBox.wxml
login/index/components/Box/Box.js
packagesList/packageOutput/components/outputCrowdfund/outputCrowdfund.js
packagesList/packageOutput/components/outputCrowdfund/outputCrowdfund.json
packagesList/packageOutput/components/outputCrowdfund/outputCrowdfund.scss
packagesList/packageOutput/components/outputCrowdfund/outputCrowdfund.wxml
packagesList/packageOutput/components/poster/poster.js
packagesList/packageOutput/components/poster/poster.json
packagesList/packageOutput/components/poster/poster.scss
packagesList/packageOutput/components/poster/poster.wxml
packagesList/packageOutput/pages/openBusiness.wxml
packagesList/packageOutput/pages/summary.js
packagesList/packageOutput/pages/summary.wxml
api/outputApi/output.js
View file @
55c0c11
...
@@ -95,7 +95,7 @@ class outputApi {
...
@@ -95,7 +95,7 @@ class outputApi {
/**获取活动最新战报 */
/**获取活动最新战报 */
getNewReportUrl
(
data
)
{
getNewReportUrl
(
data
)
{
return
api
.
post
({
return
api
.
post
({
method
:
'scrm.api.assistant.crowd.activity.newest.report'
,
method
:
'scrm.api.
sto
assistant.crowd.activity.newest.report'
,
...
data
...
data
})
})
}
}
...
...
components/SceneBox/SceneBox.wxml
View file @
55c0c11
...
@@ -7,7 +7,7 @@
...
@@ -7,7 +7,7 @@
<image webp wx:if="{{formData['scene' + (index + 1)]}}" class="scene-img" src="{{IMGURL}}output/caracticon0{{index + 1}}.png?v={{img_version}}"></image>
<image webp wx:if="{{formData['scene' + (index + 1)]}}" class="scene-img" src="{{IMGURL}}output/caracticon0{{index + 1}}.png?v={{img_version}}"></image>
<view wx:else class="no-open-img">
<view wx:else class="no-open-img">
<image webp wx:if="{{hasLockIcon}}" class="lock-img" src="{{IMGURL}}output/carlock0{{index + 1}}.png?v={{img_version}}"></image>
<image webp wx:if="{{hasLockIcon}}" class="lock-img" src="{{IMGURL}}output/carlock0{{index + 1}}.png?v={{img_version}}"></image>
<image webp wx:else="" class="scene-img" src="{{IMGURL}}output/car0{{index + 1}}.png?v={{img_version}}"></image>
<image webp wx:else="" class="scene-img" src="{{IMGURL}}output/
icon-
car0{{index + 1}}.png?v={{img_version}}"></image>
</view>
</view>
<view class="scene-title {{formData['scene' + (index + 1)] ? '' : 'on-open'}}">
<view class="scene-title {{formData['scene' + (index + 1)] ? '' : 'on-open'}}">
{{item.title}}
{{item.title}}
...
...
login/index/components/Box/Box.js
View file @
55c0c11
...
@@ -267,7 +267,7 @@ Component({
...
@@ -267,7 +267,7 @@ Component({
}
catch
({
}
catch
({
errMsg
errMsg
})
{
})
{
console
.
error
(
errMsg
)
//
console.error(errMsg)
this
.
reLogin
()
this
.
reLogin
()
}
}
},
},
...
...
packagesList/packageOutput/components/outputCrowdfund/outputCrowdfund.js
View file @
55c0c11
...
@@ -32,6 +32,7 @@ Component({
...
@@ -32,6 +32,7 @@ Component({
IMGURL
:
IMG_URL
,
IMGURL
:
IMG_URL
,
IMAGES
,
IMAGES
,
isShowTip
:
true
,
isShowTip
:
true
,
isShowPoster
:
false
,
orderFormList
:
[{
orderFormList
:
[{
label
:
'总场次'
,
label
:
'总场次'
,
name
:
'totalNum'
name
:
'totalNum'
...
@@ -58,18 +59,19 @@ Component({
...
@@ -58,18 +59,19 @@ Component({
{
{
label
:
'订单数'
,
label
:
'订单数'
,
name
:
'orderCount'
,
name
:
'orderCount'
,
isNumber
:
true
className
:
'font-number'
},
},
{
{
label
:
'产值'
,
label
:
'产值'
,
name
:
'realAmount'
,
name
:
'realAmount'
,
className
:
'red'
,
className
:
'red
font-number
'
,
prefix
:
'¥'
,
prefix
:
'¥'
,
isNumber
:
true
isNumber
:
true
},
},
{
{
label
:
'预估产值'
,
label
:
'预估产值'
,
name
:
'predictAmount'
,
name
:
'predictAmount'
,
className
:
'font-number'
,
prefix
:
'¥'
,
prefix
:
'¥'
,
isNumber
:
true
isNumber
:
true
}
}
...
@@ -178,7 +180,7 @@ Component({
...
@@ -178,7 +180,7 @@ Component({
const
{
const
{
item
item
}
=
e
.
currentTarget
.
dataset
,
}
=
e
.
currentTarget
.
dataset
,
posterObj
=
this
.
selectComponent
(
'#
p
oster'
),
posterObj
=
this
.
selectComponent
(
'#
crowdP
oster'
),
{
options
}
=
wx
.
$router
.
getPageInstance
()
{
options
}
=
wx
.
$router
.
getPageInstance
()
console
.
log
(
options
)
console
.
log
(
options
)
try
{
try
{
...
@@ -194,7 +196,7 @@ Component({
...
@@ -194,7 +196,7 @@ Component({
}).
then
(
res
=>
{
}).
then
(
res
=>
{
item
.
posterUrl
=
res
item
.
posterUrl
=
res
this
.
setData
({
this
.
setData
({
p
osterItem
:
item
,
crowdP
osterItem
:
item
,
isShowTip
:
false
isShowTip
:
false
})
})
}).
catch
(()
=>
{
}).
catch
(()
=>
{
...
@@ -213,20 +215,49 @@ Component({
...
@@ -213,20 +215,49 @@ Component({
})
})
console
.
log
(
res
)
console
.
log
(
res
)
},
},
/**长按战报/喜报 */
async
handlePosterTouch
(
e
)
{
},
/**战报 */
/**战报 */
handleReport
(
e
)
{
handleReport
(
e
)
{
const
{
const
{
item
item
}
=
e
.
currentTarget
.
dataset
}
=
e
.
currentTarget
.
dataset
wx
.
$api
.
showLoading
(
"战报生成中"
)
outputApi
.
getNewReportUrl
({
activityId
:
item
.
activityId
}).
then
(
res
=>
{
outputApi
.
getNewReportUrl
({
activityId
:
item
.
activityId
}).
then
(
res
=>
{
console
.
log
(
res
)
console
.
log
(
res
)
// item.posterUrl = res
// item.posterUrl = res
// this.setData({
var
posterItem
=
{
// posterItem: item,
posterUrl
:
res
||
'https://wx.glsx.com.cn/upload/biz/592250239952490496.png'
,
// isShowTip: false
date
:
new
Date
().
toLocaleDateString
()
// })
}
this
.
setData
({
posterItem
:
posterItem
,
isShowPoster
:
true
})
}).
catch
(()
=>
{
}).
catch
(()
=>
{
wx
.
$api
.
showToast
(
'下载战报失败'
)
wx
.
$api
.
showToast
(
'下载战报失败'
)
}).
finally
(()
=>
{
wx
.
$api
.
hideLoading
()
})
},
/**喜报 */
handleXiReport
(
e
)
{
const
{
item
}
=
e
.
currentTarget
.
dataset
if
(
!
item
.
goodUrl
)
{
wx
.
$api
.
showToast
(
'喜报生成失败'
)
return
true
}
var
posterItem
=
{
posterUrl
:
item
.
goodUrl
,
date
:
item
.
goodReportDate
}
this
.
setData
({
posterItem
:
posterItem
,
isShowPoster
:
true
})
})
}
}
}
}
...
...
packagesList/packageOutput/components/outputCrowdfund/outputCrowdfund.json
View file @
55c0c11
{
{
"component"
:
true
,
"component"
:
true
,
"usingComponents"
:
{}
"usingComponents"
:
{
"poster"
:
"../poster/poster"
}
}
}
packagesList/packageOutput/components/outputCrowdfund/outputCrowdfund.scss
View file @
55c0c11
...
@@ -141,8 +141,9 @@
...
@@ -141,8 +141,9 @@
height
:
72rpx
;
height
:
72rpx
;
line-height
:
72rpx
;
line-height
:
72rpx
;
text-align
:
center
;
text-align
:
center
;
font-size
:
2
0
rpx
;
font-size
:
2
6
rpx
;
color
:
#5A6066
;
color
:
#5A6066
;
font-weight
:
600
;
border-bottom
:
1rpx
solid
rgba
(
204
,
206
,
209
,
0
.50
);
border-bottom
:
1rpx
solid
rgba
(
204
,
206
,
209
,
0
.50
);
// .activity-status {
// .activity-status {
...
@@ -195,6 +196,12 @@
...
@@ -195,6 +196,12 @@
margin-right
:
12rpx
;
margin-right
:
12rpx
;
}
}
.name-disabled
{
font-size
:
24rpx
;
color
:
#5A6066
;
margin-right
:
12rpx
;
}
&
-dept
{
&
-dept
{
color
:
#8A8C90
;
color
:
#8A8C90
;
}
}
...
@@ -226,11 +233,15 @@
...
@@ -226,11 +233,15 @@
.rank-price
{
.rank-price
{
text-align
:
right
;
text-align
:
right
;
font-size
:
26rpx
;
font-size
:
26rpx
;
color
:
#
F35251
;
color
:
#
8A8C90
;
height
:
64rpx
;
height
:
64rpx
;
line-height
:
64rpx
;
line-height
:
64rpx
;
}
}
.txt-red
{
color
:
#F35251
;
}
// .th,
// .th,
// .td {
// .td {
// width: calc((100% - 116rpx) / 4);
// width: calc((100% - 116rpx) / 4);
...
...
packagesList/packageOutput/components/outputCrowdfund/outputCrowdfund.wxml
View file @
55c0c11
<!-- packageOutput/pages/summary/components/outputCrowdfund/outputCrowdfund.wxml -->
<!-- packageOutput/pages/summary/components/outputCrowdfund/outputCrowdfund.wxml -->
<wxs src="../../index.wxs" module="filter" />
<wxs src="../../index.wxs" module="filter" />
<view class="crowdfund-layout">
<view class="crowdfund-layout">
<view class="box order">
<view class="box order">
<view class="order-block" wx:for="{{orderFormList}}" wx:key="index">
<view class="order-block" wx:for="{{orderFormList}}" wx:key="index">
<view class="order-txt font-number">
<view class="order-txt font-number">
<text wx:if="{{item.prefix}}">{{item.prefix}}</text>
<text wx:if="{{item.prefix}}">{{item.prefix}}</text>
{{filter.money_three_for_two_thousands(orderObj[item.name] || 0.00)}}
{{filter.money_three_for_two_thousands(orderObj[item.name] || 0.00)}}
</view>
</view>
<view class="order-label">{{item.label}}</view>
<view class="order-label">{{item.label}}</view>
</view>
</view>
</view>
</view>
<view class="box merchant" wx:for="{{orderObj.activityList}}" wx:key="index">
<view class="box merchant" wx:for="{{orderObj.activityList}}" wx:key="index">
<view class="head">
<view class="head">
<!-- text-hide -->
<!-- text-hide -->
<view class=" head-title" bindtap="handleJumpH5" data-item="{{item}}">
<view class=" head-title" bindtap="handleJumpH5" data-item="{{item}}">
{{item.activityName}}
{{item.activityName}}
</view>
</view>
<view class="head-link" bindtap="download" data-item="{{item}}">
<view class="head-link" bindtap="download" data-item="{{item}}">
<image src="{{IMAGES.download}}" class="downloadIcon" webp></image>
<image src="{{IMAGES.download}}" class="downloadIcon" webp></image>
母链海报
母链海报
</view>
</view>
<view class="down-tips" wx:if="{{index == 0 && isShowTip}}">下载活动海报分享给门店开展活动</view>
<view class="down-tips" wx:if="{{index == 0 && isShowTip}}">下载活动海报分享给门店开展活动</view>
</view>
</view>
<view class="content">
<view class="content">
<view
<view class="content-row" wx:for="{{merchantFormList}}" wx:for-item="subItem" wx:for-index="idx" wx:key="idx">
class="content-row"
<view class="content-label">{{subItem.label}}</view>
wx:for="{{merchantFormList}}"
<view class="content-txt {{subItem.className}}">
wx:for-item="subItem"
<text wx:if="{{subItem.prefix}}">{{subItem.prefix}}</text>
wx:for-index="idx"
{{subItem.isNumber ? filter.money_three_for_two_thousands(item[subItem.name]) : item[subItem.name]}}
wx:key="idx">
</view>
<view class="content-label">{{subItem.label}}</view>
</view>
<view class="content-txt {{subItem.isNumber ? 'font-number': ''}} {{subItem.className}}">
<!-- 排名 -->
<text wx:if="{{subItem.prefix}}">{{subItem.prefix}}</text>
<view class="content-rank" wx:if="{{item.showStaffList.length}}">
{{subItem.isNumber ? filter.money_three_for_two_thousands(item[subItem.name]) : item[subItem.name]}}
<view class="rank-title">员工任务排名</view>
</view>
</view>
<!-- 排名 -->
<view class="content-rank" wx:if="{{item.showStaffList.length}}">
<view class="rank-title">员工任务排名</view>
<!-- <view class="rank-head">
<view>员工任务排名</view>
<view class="activity-status" wx:if="{{item.activityStatus == 1}}">
距离开始{{item.interDays}}天
</view>
<view class="activity-status" wx:if="{{item.activityStatus == 2}}">
已开始{{item.interDays}}天
</view>
<view class="activity-status" wx:if="{{item.activityStatus == 3 && item.interDays < 8}}">
已结束{{item.interDays}}天
</view>
</view> -->
<!-- <view class="rank-table">
<view class="tr">
<view class="th" style="width: {{subItem.width || ''}};" wx:for="{{tableHeadList}}" wx:for-item="subItem" wx:for-index="idx" wx:key="idx">
{{subItem.label}}
</view>
</view>
<view>
<block wx:for="{{item.showStaffList}}" wx:for-item="subItem" wx:for-index="idx" wx:key="idx">
<view class="tr">
<view class="td text-hide" style="width: {{i.width || ''}};" wx:for="{{tableHeadList}}" wx:for-item="i" wx:for-index="j" wx:key="j">
<view wx:if="{{j == 0 && idx < 3}}">
<image class="icon-rank" src="{{IMGURL}}output/rank0{{idx + 1}}.png?v={{img_version}}" />
</view>
<text wx:if="{{i.prefix}}">{{i.prefix}}</text>
{{subItem[i.name]}}
</view>
</view>
</block>
<view wx:if="{{item.staffList.length}}" class="btn-more" bindtap="handleMore" data-idx="{{index}}">
查看更多
</view>
</view>
</view> -->
<view class="rank-table">
<view class="rank-table">
<view wx:for="{{item.showStaffList}}" wx:for-item="subItem" wx:for-index="idx" wx:key="idx">
<view wx:for="{{item.showStaffList}}" wx:for-item="subItem" wx:for-index="idx" wx:key="idx">
<view class="rank">
<view class="rank">
...
@@ -81,21 +41,18 @@
...
@@ -81,21 +41,18 @@
<glsx-image class="rank-head" src="output/icon-head.webp"></glsx-image>
<glsx-image class="rank-head" src="output/icon-head.webp"></glsx-image>
<view class="rank-content">
<view class="rank-content">
<view class="rank-row">
<view class="rank-row">
<text class="rank-row-name">{{subItem.shareName}}</text>
<text wx:if="{{subItem.totalAmount}}" class="rank-row-name" bindtap="handleXiReport" data-item="{{subItem}}">{{subItem.shareName}}</text>
<text class="rank-row-dept">运营部</text>
<text wx:else class="name-disabled">{{subItem.shareName}}</text>
<text class="rank-row-dept">{{subItem.departmentName}}</text>
</view>
</view>
<view class="rank-row">
<view class="rank-row">
<text class="rank-row-txt">访客
136
人</text>
<text class="rank-row-txt">访客
<text class="font-number">{{subItem.browseCount || 0}}</text>
人</text>
<text class="rank-row-txt">成交</text>
<text class="rank-row-txt">成交<
text class="font-number">{{subItem.dealCount || 0}}</text>单<
/text>
</view>
</view>
</view>
</view>
</view>
</view>
<view class="rank-price">¥ {{subItem.totalAmount}}</view>
<view wx:if="{{subItem.totalAmount}}" class="rank-price txt-red font-number">¥ {{subItem.totalAmount}}</view>
<!-- <view class="td text-hide" style="width: {{i.width || ''}};" wx:for="{{tableHeadList}}" wx:for-item="i" wx:for-index="j" wx:key="j">
<view wx:else class="rank-price">暂无业绩</view>
<view wx:if="{{j == 0}}">{{idx + 1}}</view>
<text wx:if="{{i.prefix}}">{{i.prefix}}</text>
{{subItem[i.name]}}
</view> -->
</view>
</view>
</view>
</view>
<view wx:if="{{item.staffList.length}}" class="btn-more" bindtap="handleMore" data-idx="{{index}}">
<view wx:if="{{item.staffList.length}}" class="btn-more" bindtap="handleMore" data-idx="{{index}}">
...
@@ -107,7 +64,6 @@
...
@@ -107,7 +64,6 @@
<view class="content-suggest" wx:if="{{item.activityStatus == 2 && item.suggestTxtList.length}}">
<view class="content-suggest" wx:if="{{item.activityStatus == 2 && item.suggestTxtList.length}}">
<view class="suggest-title"># 活动诊断</view>
<view class="suggest-title"># 活动诊断</view>
<view class="suggest-txt">
<view class="suggest-txt">
<!-- <text wx:if="{{item.toEndDays < 8}}">距离活动结束剩余{{item.interDays}}天,</text> -->
{{item.suggestTxt}}推荐以下建议:
{{item.suggestTxt}}推荐以下建议:
</view>
</view>
<view class="suggest-block">
<view class="suggest-block">
...
@@ -118,15 +74,15 @@
...
@@ -118,15 +74,15 @@
</view>
</view>
</view>
</view>
<!-- 战报 -->
<!-- 战报 -->
<view class="new-report">
<view class="new-report"
wx:if="{{item.activityStatus != 1}}"
>
<view class="report-left" bindtap="handleReport" data-item="{{item}}">
<view class="report-left" bindtap="handleReport" data-item="{{item}}">
<glsx-image class="icon-report" src="output/icon-report.webp"></glsx-image>
<glsx-image class="icon-report" src="output/icon-report.webp"></glsx-image>
生成最新战报
生成最新战报
</view>
</view>
<view
>最新更新:
</view>
<view
wx:if="{{item.reportDate}}">最新更新:{{item.reportDate}}
</view>
</view>
</view>
</view>
</view>
</view>
</view>
</view>
</view>
<crowdfund-poster item="{{
posterItem}}" id="poster" scrollImg="{{false}}"
bindlongtouch="longtouch" />
<crowdfund-poster item="{{
crowdPosterItem}}" id="crowdPoster" scrollImg="{{false}}"
bindlongtouch="longtouch" />
<poster posterItem="{{posterItem}}" id="poster" show="{{isShowPoster}}" bindlongtouch="handlePosterTouch" />
\ No newline at end of file
\ No newline at end of file
packagesList/packageOutput/components/poster/poster.js
0 → 100644
View file @
55c0c11
// packagesList/packageOutput/components/poster/poster.js
Component
({
/**
* 组件的属性列表
*/
properties
:
{
posterItem
:
{
type
:
Object
,
value
:
{}
},
show
:
{
type
:
Boolean
,
value
:
false
},
scrollImg
:
{
type
:
Boolean
,
value
:
true
}
},
/**
* 组件的初始数据
*/
data
:
{
},
/**
* 组件的方法列表
*/
methods
:
{
hide
()
{
this
.
setData
({
show
:
false
,
poster
:
''
})
}
}
})
packagesList/packageOutput/components/poster/poster.json
0 → 100644
View file @
55c0c11
{
"component"
:
true
,
"usingComponents"
:
{}
}
\ No newline at end of file
\ No newline at end of file
packagesList/packageOutput/components/poster/poster.scss
0 → 100644
View file @
55c0c11
/* packagesList/packageOutput/components/poster/poster.wxss */
.layout
{
position
:
fixed
;
top
:
0
;
right
:
0
;
bottom
:
0
;
left
:
0
;
width
:
100vw
;
height
:
100vh
;
z-index
:
998
;
display
:
flex
;
flex-direction
:
column
;
align-items
:
center
;
justify-content
:
center
;
.bg
{
position
:
absolute
;
width
:
100%
;
height
:
100%
;
z-index
:
-1
;
background
:
rgba
(
0
,
0
,
0
,.
8
);
}
.bg-white
{
padding
:
32rpx
32rpx
0
32rpx
;
background-color
:
#FFFFFF
;
}
.poster
{
width
:
500rpx
;
height
:
68%
;
// height: 1108rpx;
overflow
:
scroll
;
border-radius
:
8rpx
8rpx
0
0
;
}
.btn
{
display
:
flex
;
align-items
:
center
;
justify-content
:
center
;
width
:
500rpx
;
height
:
90rpx
;
background
:
#F7F8FA
;
border-radius
:
0
0
12rpx
12rpx
;
font-weight
:
500
;
font-size
:
32rpx
;
color
:
#3666FE
;
margin-top
:
-2rpx
;
.icon
{
width
:
40rpx
;
height
:
40rpx
;
margin-right
:
12rpx
;
}
}
.tips
{
margin
:
40rpx
80rpx
0
;
font-size
:
24rpx
;
color
:
#FFFFFF
;
line-height
:
36rpx
;
.underline
{
font-weight
:
600
;
text-decoration
:
underline
;
}
}
}
\ No newline at end of file
\ No newline at end of file
packagesList/packageOutput/components/poster/poster.wxml
0 → 100644
View file @
55c0c11
<!--packagesList/packageOutput/components/poster/poster.wxml-->
<block wx:if="{{show}}">
<!-- catchtouchmove="noScroll" -->
<view class="layout">
<view class="bg" bindtap="hide" />
<block wx:if="{{scrollImg}}">
<view class="poster">
<!-- <scroll-view scroll-x="false" scroll-y="true" style="height: 100%"> -->
<image src="{{posterItem.posterUrl}}" mode="widthFix" show-menu-by-longpress />
<!-- </scroll-view> -->
</view>
</block>
<block wx:else>
<image src="{{posterItem.posterUrl}}" class="poster" mode="widthFix" show-menu-by-longpress bindlongpress="longpress" />
</block>
<view class="btn">
<glsx-image src="output/longtap.png" class="icon"></glsx-image>
长按图片转发
</view>
<view class="tips">最近更新时间:{{posterItem.date}} </view>
</view>
</block>
<!-- <authorize scopeType="writePhotosAlbum" bindfail="authFail" show="{{showAuth}}" isShowCheck="{{false}}" id="auth" /> -->
packagesList/packageOutput/pages/openBusiness.wxml
View file @
55c0c11
...
@@ -18,9 +18,9 @@
...
@@ -18,9 +18,9 @@
<view class="activity-box" wx:if="{{sceneActive != 1}}">
<view class="activity-box" wx:if="{{sceneActive != 1}}">
<view wx:for="{{activityList}}" wx:key="index" class="activity-item">
<view wx:for="{{activityList}}" wx:key="index" class="activity-item">
<!-- productStatus:0未申请;1申请中;2已开通;3:已结束 -->
<!-- productStatus:0未申请;1申请中;2已开通;3:已结束 -->
<view wx:if="{{item.openFlag != 0}}">
<view wx:if="{{item.openFlag != 0
&& item.productStatus == 2
}}">
<glsx-image wx:if="{{
item.productStatus == 1
}}" src="output/mark-active.webp" class="icon-mark"></glsx-image>
<glsx-image wx:if="{{
sceneActive == 4
}}" src="output/mark-active.webp" class="icon-mark"></glsx-image>
<glsx-image wx:if="{{
item.productStatus == 2
}}" src="output/mark-open.webp" class="icon-mark"></glsx-image>
<glsx-image wx:if="{{
sceneActive == 2 || sceneActive == 3
}}" src="output/mark-open.webp" class="icon-mark"></glsx-image>
</view>
</view>
<view wx:if="{{item.openFlag == 0}}" class="text-hide {{ item.checked ? 'active' : '' }}" bindtap="handleActClick" data-idx="{{index}}">{{item.productName}}</view>
<view wx:if="{{item.openFlag == 0}}" class="text-hide {{ item.checked ? 'active' : '' }}" bindtap="handleActClick" data-idx="{{index}}">{{item.productName}}</view>
<view class="text-hide item-disabled" wx:else>{{item.productName}}</view>
<view class="text-hide item-disabled" wx:else>{{item.productName}}</view>
...
...
packagesList/packageOutput/pages/summary.js
View file @
55c0c11
...
@@ -74,6 +74,8 @@ Page({
...
@@ -74,6 +74,8 @@ Page({
activityActive
:
idx
,
activityActive
:
idx
,
// productStatus:0未申请;1申请中;2已开通;3:已结束
// productStatus:0未申请;1申请中;2已开通;3:已结束
isShowData
:
[
2
,
3
].
includes
(
+
this
.
data
.
activityList
[
idx
].
productStatus
)
isShowData
:
[
2
,
3
].
includes
(
+
this
.
data
.
activityList
[
idx
].
productStatus
)
// 删----
// isShowData: true
})
})
if
([
2
,
3
].
includes
(
this
.
data
.
sceneActive
))
{
if
([
2
,
3
].
includes
(
this
.
data
.
sceneActive
))
{
this
.
getCustomerDetail
(
false
,
false
)
this
.
getCustomerDetail
(
false
,
false
)
...
@@ -289,18 +291,29 @@ Page({
...
@@ -289,18 +291,29 @@ Page({
getActivityRevenue
(
isFirst
=
false
)
{
getActivityRevenue
(
isFirst
=
false
)
{
wx
.
showLoading
()
wx
.
showLoading
()
var
params
=
this
.
dealSearchStatus
()
var
params
=
this
.
dealSearchStatus
()
outputApi
.
getActivityRevenue
({
merchantId
:
this
.
data
.
merchantInfo
.
merchantId
,
...
params
}).
then
(
res
=>
{
// 删----
// outputApi.getActivityRevenue({ merchantId: 44211227, ...params }).then(res => {
outputApi
.
getActivityRevenue
({
merchantId
:
this
.
data
.
merchantInfo
.
merchantId
,
...
params
}).
then
(
res
=>
{
// console.log(this.data.sceneActivityObj, '++++++')
// console.log(this.data.sceneActivityObj, '++++++')
var
actList
=
this
.
data
.
sceneActivityObj
[
'scene'
+
(
isFirst
?
4
:
this
.
data
.
sceneActive
)]
var
actList
=
this
.
data
.
sceneActivityObj
[
'scene'
+
(
isFirst
?
4
:
this
.
data
.
sceneActive
)]
var
total
=
0
var
total
=
0
res
.
forEach
(
item
=>
{
res
.
forEach
(
item
=>
{
total
=
total
+
item
.
totalAmount
total
=
total
+
item
.
totalAmount
})
})
console
.
log
(
actList
)
var
activitingIdx
=
-
1
actList
.
forEach
((
item
,
idx
)
=>
{
actList
.
forEach
((
item
,
idx
)
=>
{
var
curItem
=
res
.
find
(
k
=>
k
.
goodsCategoryCode
==
item
.
productCode
)
var
curItem
=
res
.
find
(
k
=>
k
.
goodsCategoryCode
==
item
.
productCode
)
if
(
curItem
)
{
if
(
curItem
)
{
curItem
.
totalNum
=
curItem
.
activityList
.
length
curItem
.
totalNum
=
curItem
.
activityList
.
length
curItem
.
activityList
.
forEach
(
k
=>
{
curItem
.
shareBtnIdx
=
-
1
let
shareFlag
=
false
curItem
.
activityList
.
forEach
((
k
,
kIdx
)
=>
{
// 分享按钮判断shareStatus:活动分享状态 0:未分享 1:已分享
if
(
k
.
activityStatus
==
2
&&
k
.
shareStatus
==
0
)
{
curItem
.
shareBtnIdx
=
shareFlag
?
-
1
:
kIdx
shareFlag
=
true
}
// 时间
// 时间
k
.
time
=
k
.
startTime
.
slice
(
0
,
16
).
replace
(
/-/g
,
'.'
)
+
' - '
+
k
.
endTime
.
slice
(
0
,
16
).
replace
(
/-/g
,
'.'
)
k
.
time
=
k
.
startTime
.
slice
(
0
,
16
).
replace
(
/-/g
,
'.'
)
+
' - '
+
k
.
endTime
.
slice
(
0
,
16
).
replace
(
/-/g
,
'.'
)
let
startTimeFormat
=
k
.
startTime
.
slice
(
0
,
10
).
replace
(
/-/g
,
'/'
)
+
' 00:00:00'
let
startTimeFormat
=
k
.
startTime
.
slice
(
0
,
10
).
replace
(
/-/g
,
'/'
)
+
' 00:00:00'
...
@@ -315,11 +328,11 @@ Page({
...
@@ -315,11 +328,11 @@ Page({
let
endTimeFormat
=
k
.
endTime
.
slice
(
0
,
10
).
replace
(
/-/g
,
'/'
)
+
' 23:59:59'
let
endTimeFormat
=
k
.
endTime
.
slice
(
0
,
10
).
replace
(
/-/g
,
'/'
)
+
' 23:59:59'
k
.
interDays
=
parseInt
((
new
Date
().
getTime
()
-
new
Date
(
startTimeFormat
).
getTime
())
/
(
1000
*
60
*
60
*
24
))
+
1
k
.
interDays
=
parseInt
((
new
Date
().
getTime
()
-
new
Date
(
startTimeFormat
).
getTime
())
/
(
1000
*
60
*
60
*
24
))
+
1
k
.
toEndDays
=
parseInt
((
new
Date
(
endTimeFormat
).
getTime
()
-
new
Date
(
nowDateFormat
).
getTime
())
/
(
1000
*
60
*
60
*
24
))
+
1
k
.
toEndDays
=
parseInt
((
new
Date
(
endTimeFormat
).
getTime
()
-
new
Date
(
nowDateFormat
).
getTime
())
/
(
1000
*
60
*
60
*
24
))
+
1
k
.
realTime
=
'-
'
k
.
realTime
=
k
.
realStartTime
?.
slice
(
0
,
16
).
replace
(
/-/g
,
'.'
)
+
' - '
+
'已开始'
+
k
.
interDays
+
'天
'
break
break
case
3
:
case
3
:
k
.
interDays
=
parseInt
((
new
Date
(
nowDateFormat
).
getTime
()
-
new
Date
(
k
.
endTime
.
replace
(
/-/g
,
'/'
)).
getTime
())
/
(
1000
*
60
*
60
*
24
))
+
1
k
.
interDays
=
parseInt
((
new
Date
(
nowDateFormat
).
getTime
()
-
new
Date
(
k
.
endTime
.
replace
(
/-/g
,
'/'
)).
getTime
())
/
(
1000
*
60
*
60
*
24
))
+
1
k
.
realTime
=
'-'
k
.
realTime
=
(
k
.
realStartTime
?.
slice
(
0
,
16
).
replace
(
/-/g
,
'.'
)
||
''
)
+
' - '
+
(
k
.
realEndTime
?.
slice
(
0
,
16
).
replace
(
/-/g
,
'.'
)
||
''
)
break
break
}
}
k
.
suggestTxtList
=
[]
k
.
suggestTxtList
=
[]
...
@@ -341,6 +354,10 @@ Page({
...
@@ -341,6 +354,10 @@ Page({
k
.
suggestTxt
=
k
.
suggestTxtList
.
join
(
','
)
+
'。'
k
.
suggestTxt
=
k
.
suggestTxtList
.
join
(
','
)
+
'。'
}
}
})
})
// 定位进行中的活动
if
(
activitingIdx
==
-
1
&&
curItem
.
shareBtnIdx
!=
-
1
)
{
activitingIdx
=
idx
}
actList
[
idx
].
outputData
=
curItem
actList
[
idx
].
outputData
=
curItem
}
else
{
}
else
{
actList
[
idx
].
outputData
=
[]
actList
[
idx
].
outputData
=
[]
...
@@ -350,16 +367,67 @@ Page({
...
@@ -350,16 +367,67 @@ Page({
this
.
setData
({
this
.
setData
({
[
'sceneActivityObj.scene'
+
this
.
data
.
sceneActive
]:
actList
[
'sceneActivityObj.scene'
+
this
.
data
.
sceneActive
]:
actList
})
})
this
.
setCurActivity
()
}
if
(
this
.
data
.
sceneActive
==
4
)
{
var
params
=
{
currentTarget
:
{
dataset
:
{
idx
:
activitingIdx
}
}
}
this
.
handleActChange
(
params
)
}
}
this
.
setData
({
this
.
setData
({
[
'scenePriceList[3].total'
]:
total
.
toFixed
(
2
)
[
'scenePriceList[3].total'
]:
total
.
toFixed
(
2
)
})
})
!
isFirst
&&
this
.
setCurActivity
()
}).
finally
(()
=>
{
}).
finally
(()
=>
{
wx
.
hideLoading
()
wx
.
hideLoading
()
})
})
},
},
// 分享母链
async
handleBtnShare
(
e
)
{
const
idx
=
this
.
data
.
activityList
[
this
.
data
.
activityActive
].
outputData
.
shareBtnIdx
const
item
=
this
.
data
.
activityList
[
this
.
data
.
activityActive
].
outputData
.
activityList
[
idx
]
const
posterObj
=
this
.
selectComponent
(
'#crowdPoster'
)
const
{
options
}
=
wx
.
$router
.
getPageInstance
()
console
.
log
(
options
)
try
{
let
flag
=
await
posterObj
.
check
(
item
)
posterObj
.
setData
({
poster
:
flag
,
show
:
true
})
}
catch
(
error
)
{
wx
.
$api
.
showLoading
(
'加载中...'
)
outputApi
.
getPosterUrl
({
id
:
item
.
activityId
}).
then
(
res
=>
{
item
.
posterUrl
=
res
this
.
setData
({
crowdPosterItem
:
item
,
isShowTip
:
false
})
}).
catch
(()
=>
{
wx
.
$api
.
showToast
(
'下载海报失败'
)
})
}
},
/**长按海报 */
async
longtouch
(
e
)
{
console
.
log
(
'长按海报'
,
e
)
let
{
activityId
}
=
e
.
detail
const
res
=
await
outputApi
.
reportPosterTrack
({
activityId
})
console
.
log
(
res
)
this
.
getSceneProStatus
(
this
.
data
.
sceneCodeList
[
this
.
data
.
sceneActive
-
1
])
},
/**
/**
* 生命周期函数--监听页面加载
* 生命周期函数--监听页面加载
*/
*/
...
...
packagesList/packageOutput/pages/summary.wxml
View file @
55c0c11
...
@@ -60,9 +60,10 @@
...
@@ -60,9 +60,10 @@
<view class="btn-disabled">点击开通</view>
<view class="btn-disabled">点击开通</view>
</view>
</view>
</view>
</view>
<view wx:if="{{sceneActive == 4
}}" class="isFullSucreen btn-box shadow
">
<view wx:if="{{sceneActive == 4
&& activityList[activityActive].outputData.shareBtnIdx != -1}}" class="isFullSucreen btn-box shadow" bindtap="handleBtnShare" data-item="
">
<view class="btn">
<view class="btn">
<view class="btn-share">活动进行中,分享母链海报开展活动</view>
<view class="btn-share">活动进行中,分享母链海报开展活动</view>
</view>
</view>
</view>
</view>
</view>
\ No newline at end of file
\ No newline at end of file
</view>
<crowdfund-poster item="{{crowdPosterItem}}" id="crowdPoster" scrollImg="{{false}}" bindlongtouch="longtouch" />
\ No newline at end of file
\ No newline at end of file
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