Commit 402ede39 by 张立顺

解决冲突

2 parents d229ccfa b3e9cdeb
...@@ -94,9 +94,17 @@ Component({ ...@@ -94,9 +94,17 @@ Component({
}) })
}, },
download() { download() {
const filePath = this.data.poster const filePath = this.data.poster,
_this = this
wx.saveImageToPhotosAlbum({ wx.saveImageToPhotosAlbum({
filePath filePath,
success(){
wx.$api.showToast('保存成功')
},
fail(err) {
const auth = _this.selectComponent('#auth')
auth.check()
}
}) })
}, },
hide() { hide() {
...@@ -105,6 +113,11 @@ Component({ ...@@ -105,6 +113,11 @@ Component({
poster: '' poster: ''
}) })
}, },
noScroll() {} noScroll() {},
authFail(e) {
this.setData({
showAuth: true
})
}
} }
}) })
\ No newline at end of file \ No newline at end of file
{ {
"component": true, "component": true,
"usingComponents": {} "usingComponents": {
"authorize":"/components/Authorize/Authorize"
}
} }
\ No newline at end of file \ No newline at end of file
...@@ -7,4 +7,5 @@ ...@@ -7,4 +7,5 @@
提示:这是您的专属活动海报,请下载转发给门店员工注册并参与活动分享。请不要将此海报转发给非相关活动参与者,避免活动数据泄漏。 提示:这是您的专属活动海报,请下载转发给门店员工注册并参与活动分享。请不要将此海报转发给非相关活动参与者,避免活动数据泄漏。
</view> </view>
</view> </view>
</block>
\ No newline at end of file \ No newline at end of file
</block>
<authorize scopeType="writePhotosAlbum" bindfail="authFail" show="{{showAuth}}" isShowCheck="{{false}}" id="auth"></authorize>
\ No newline at end of file \ No newline at end of file
...@@ -66,7 +66,7 @@ ...@@ -66,7 +66,7 @@
.active::after { .active::after {
position: absolute; position: absolute;
left: 50%; left: 50%;
bottom: -18rpx; bottom: -17rpx;
display: block; display: block;
content: ""; content: "";
width: 16rpx; width: 16rpx;
......
// packageOutput/pages/summary/components/CrowdfundPoster/CrowdfundPoster.js
import Draw from '~/utils/Draw'
Component({
/**
* 组件的属性列表
*/
properties: {
item: {
type: Object,
observer(n) {
console.log(n, '=================')
this.init(n)
}
}
},
/**
* 组件的初始数据
*/
data: {
},
/**
* 组件的方法列表
*/
methods: {
async init(n) {
wx.$api.showLoading()
const drawfun = new Draw({
width: 279,
height: 554
}, this),
{
userInfo
} = wx.$storage.get(),
merchantName = userInfo.merchantName.length > 12 ? `${userInfo.merchantName.substring(0, 12)}...` : userInfo.merchantName,
res = await drawfun.begin({
imageList: [{
x: 0,
y: 0,
width: 279,
height: 66,
url: 'https://img02.glsx.com.cn/weapp/resource/saas/business-assistant/output/poster-bg.png'
},
{
x: 16,
y: 70,
width: 247,
height: 472,
url: n.posterUrl
}
],
textList: [{
x: 12,
y: 14,
fontSize: 14,
color: '#2D2D33',
text: merchantName,
textBaseline: 'top'
},
{
x: 16 + drawfun.getTextWidth(merchantName, 14),
y: 15,
fontSize: 12,
color: '#6E6E7A',
text: '邀请你参加',
textBaseline: 'top'
},
{
x: 12,
y: 36,
fontSize: 14,
color: '#1B233D',
text: n.activityName,
textBaseline: 'top',
fontWeight: 500
},
{
x: 14 + drawfun.getTextWidth(n.activityName, 14) + 9,
y: 39,
fontSize: 10,
color: '#4466F0',
text: '众筹',
border: {
width: 1,
color: '#8FA5FF',
radius: 2,
padding: [5, 5]
}
}
],
})
console.log(res)
wx.hideLoading()
this.setData({
poster: res.path
})
},
download() {
const filePath = this.data.poster,
_this = this
wx.saveImageToPhotosAlbum({
filePath,
success(){
wx.$api.showToast('保存成功')
},
fail(err) {
const auth = _this.selectComponent('#auth')
auth.check()
}
}
)
},
hide() {
this.setData({
poster: ''
})
},
noScroll() {},
authFail(e) {
this.setData({
showAuth: true
})
}
}
})
\ No newline at end of file \ No newline at end of file
{
"component": true,
"usingComponents": {
"authorize":"/components/Authorize/Authorize"
}
}
\ No newline at end of file \ No newline at end of file
/* packageOutput/pages/summary/components/CrowdfundPoster/CrowdfundPoster.wxss */
.layout {
position: fixed;
top: 0;
right: 0;
bottom: 0;
left: 0;
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(28, 27, 35, 0.60);
}
.poster {
width: 558rpx;
height: 60%;
border-radius: 8rpx;
}
.btn {
width: 320rpx;
height: 88rpx;
line-height: 88rpx;
background-image: linear-gradient(-60deg, #556AF5 0%, #7197FF 100%);
border-radius: 16rpx;
font-weight: 500;
font-size: 32rpx;
color: #FFFFFF;
text-align: center;
margin-top: 32rpx;
}
.tips {
margin: 16rpx 80rpx 0;
font-size: 24rpx;
color: #FFFFFF;
line-height: 36rpx;
}
}
\ No newline at end of file \ No newline at end of file
<block wx:if="{{poster}}">
<view class="layout" catchtouchmove="noScroll">
<view class="bg" bindtap="hide"></view>
<image src="{{poster}}" class="poster" mode="aspectFit"></image>
<view class="btn" bindtap="download">保存至相册</view>
<view class="tips">
提示:这是您的专属活动海报,请下载转发给门店员工注册并参与活动分享。请不要将此海报转发给非相关活动参与者,避免活动数据泄漏。
</view>
</view>
</block>
<authorize scopeType="writePhotosAlbum" bindfail="authFail" show="{{showAuth}}" id="auth"></authorize>
\ No newline at end of file \ No newline at end of file
...@@ -66,6 +66,12 @@ ...@@ -66,6 +66,12 @@
// line-height: 32rpx; // line-height: 32rpx;
line-height: 37rpx; line-height: 37rpx;
} }
.icon-download {
width: 18px;
height: 18px;
vertical-align: middle;
}
} }
.content { .content {
......
...@@ -16,7 +16,7 @@ Page({ ...@@ -16,7 +16,7 @@ Page({
scene3: null, scene3: null,
scene4: null scene4: null
}, },
sceneActive: 1, sceneActive: 4,
scenePriceList: [{ scenePriceList: [{
total: 0 total: 0
}, { }, {
...@@ -115,9 +115,6 @@ Page({ ...@@ -115,9 +115,6 @@ Page({
sceneCode: sceneCode sceneCode: sceneCode
} }
outputApi.getSceneProStatus(params).then(res => { outputApi.getSceneProStatus(params).then(res => {
// var proList = res.find(item => item.sceneCode == sceneCode)
// 删---
// proList.productList[1].productStatus = 2
this.setData({ this.setData({
['sceneActivityObj.scene1']: res[0].productList, ['sceneActivityObj.scene1']: res[0].productList,
['sceneActivityObj.scene2']: res[1].productList, ['sceneActivityObj.scene2']: res[1].productList,
...@@ -195,11 +192,11 @@ Page({ ...@@ -195,11 +192,11 @@ Page({
} }
// 总金额 // 总金额
this.setData({ this.setData({
['scenePriceList[' + (isFirst ? 1 : (this.data.sceneActive - 1)) + '].total']: curTotal ['scenePriceList[' + (isFirst ? 1 : (this.data.sceneActive - 1)) + '].total']: curTotal.toFixed(2)
}) })
if(isChangeOtherTotal) { if(isChangeOtherTotal) {
this.setData({ this.setData({
['scenePriceList[' + (isFirst ? 2 : (otherScene - 1)) + '].total']: otherTotal ['scenePriceList[' + (isFirst ? 2 : (otherScene - 1)) + '].total']: otherTotal.toFixed(2)
}) })
} }
!isFirst && this.setCurActivity() !isFirst && this.setCurActivity()
...@@ -245,11 +242,6 @@ Page({ ...@@ -245,11 +242,6 @@ Page({
if (curItem) { if (curItem) {
curItem.totalNum = curItem.activityList.length curItem.totalNum = curItem.activityList.length
curItem.activityList.forEach(k => { curItem.activityList.forEach(k => {
// 删---
// var list = k.staffList
// for (var i = 0; i < 10; i++) {
// k.staffList = k.staffList.concat(list)
// }
// 时间 // 时间
k.time = k.startTime.slice(5).replace(/-/g, '/') + '~' + k.endTime.slice(5).replace(/-/g, '/') k.time = k.startTime.slice(5).replace(/-/g, '/') + '~' + k.endTime.slice(5).replace(/-/g, '/')
// 0-未开始;1-活动中;2-已结束 // 0-未开始;1-活动中;2-已结束
...@@ -295,7 +287,7 @@ Page({ ...@@ -295,7 +287,7 @@ Page({
}) })
} }
this.setData({ this.setData({
['scenePriceList[3].total']: total ['scenePriceList[3].total']: total.toFixed(2)
}) })
!isFirst && this.setCurActivity() !isFirst && this.setCurActivity()
}).finally(() => { }).finally(() => {
...@@ -308,17 +300,6 @@ Page({ ...@@ -308,17 +300,6 @@ Page({
*/ */
onLoad(options) { onLoad(options) {
// 删---
// this.setData({
// merchantInfo: {
// pMerchantId: 44209845,
// merchantId: 44209390,
// merchantName: '????'
// },
// sceneCodeList: ['SC001', 'SC002', 'SC003', 'SC004']
// })
// this.getSceneProStatus(this.data.sceneCodeList[this.data.sceneActive - 1])
wx.$router.getData(obj => { wx.$router.getData(obj => {
var scene = {} var scene = {}
Object.keys(this.data.sceneObj).forEach(item => { Object.keys(this.data.sceneObj).forEach(item => {
......
...@@ -96,7 +96,8 @@ Page({ ...@@ -96,7 +96,8 @@ Page({
// 看线索部分 // 看线索部分
unreadClueCount: 0, unreadClueCount: 0,
cluePageSize: 10, cluePageSize: 10,
clueCurrentPage: 1 clueCurrentPage: 1,
disLikeFlag: true
}, },
//引导图 //引导图
...@@ -472,6 +473,9 @@ Page({ ...@@ -472,6 +473,9 @@ Page({
this.prompt = this.selectComponent('#toast') this.prompt = this.selectComponent('#toast')
}, },
showToast: function (e) { showToast: function (e) {
this.setData({
disLikeFlag: false
})
let { type, item } = e.currentTarget.dataset let { type, item } = e.currentTarget.dataset
console.log('type,item: ', type, item) console.log('type,item: ', type, item)
let tipObj = {} let tipObj = {}
......
...@@ -158,12 +158,34 @@ page { ...@@ -158,12 +158,34 @@ page {
width: 23px; width: 23px;
height: 23px; height: 23px;
} }
.disLike-tit {
width: 172rpx;
background: rgba(0,0,0,0.60);
padding: 8rpx 0rpx;
font-family: PingFangSC-Regular;
font-size: 20rpx;
color: #FFFFFF;
line-height: 36rpx;
text-align: center;
border-radius: 8rpx;
position: absolute;
right: 0rpx;
top: 61rpx;
}
.disLike-titsan {
width: 0;
height: 0;
border: 18rpx solid;
border-color: transparent transparent #686868;
position: absolute;
right: 27rpx;
top: 30rpx;
}
.name { .name {
display: flex; display: flex;
align-items: center; align-items: center;
// font-weight: 400; // font-weight: 400;
font-size: 14px; font-size: 28rpx;
color: #323436; color: #323436;
.avatar { .avatar {
...@@ -200,7 +222,7 @@ page { ...@@ -200,7 +222,7 @@ page {
.action-wrap { .action-wrap {
display: flex; display: flex;
align-items: center; align-items: center;
font-size: 12px; font-size: 24rpx;
color: #393b3e; color: #393b3e;
} }
...@@ -227,7 +249,7 @@ page { ...@@ -227,7 +249,7 @@ page {
} }
.phone { .phone {
font-size: 12px; font-size: 24rpx;
color: #3666fe; color: #3666fe;
} }
...@@ -358,7 +380,9 @@ page { ...@@ -358,7 +380,9 @@ page {
// background-image: url("https://img02.glsx.com.cn/weapp/resource/saas/business-assistant/index/act.png"); // background-image: url("https://img02.glsx.com.cn/weapp/resource/saas/business-assistant/index/act.png");
// background-size: 100% 100%; // background-size: 100% 100%;
border: 1px solid var(--btnColor); border: 1px solid var(--btnColor);
box-shadow: 0 2rpx 4rpx 0 rgba(180, 186, 204, 0.4); // box-shadow: 0 2rpx 4rpx 0 rgba(180, 186, 204, 0.4);
background-image: linear-gradient(145deg, #F0F7FF 0%, #FFFFFF 73%);
box-shadow: 0 4rpx 8rpx 0 rgba(180, 186, 204, 0.32), 0 8rpx 20rpx 0 rgba(180, 186, 204, 0.40);
&::after { &::after {
position: absolute; position: absolute;
......
...@@ -165,6 +165,10 @@ ...@@ -165,6 +165,10 @@
data-outidx="{{index}}" data-outidx="{{index}}"
data-item="{{item}}" data-item="{{item}}"
bindtap="showToast" /> bindtap="showToast" />
<view class="disLike-tit" wx:if="{{item.clueType == 1 && item.starTag == 0 && disLikeFlag}}">
标记为意向客户
</view>
<view class="disLike-titsan" wx:if="{{item.clueType == 1 && item.starTag == 0 && disLikeFlag}}"></view>
<view class="name" hover-class="none" hover-stop-propagation="false"> <view class="name" hover-class="none" hover-stop-propagation="false">
{{item.nickName}} {{item.nickName}}
<image class="avatar" src="{{IMG_URL}}index/avatar.png" wx:if="{{item.clueType != 3}}" /> <image class="avatar" src="{{IMG_URL}}index/avatar.png" wx:if="{{item.clueType != 3}}" />
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!