|
|
|
@ -3,7 +3,7 @@ |
|
|
|
|
<view class="park" :style="{backgroundImage:`url(${indexBackgroundImage})`}"> |
|
|
|
|
<view style="margin-top:870rpx;overflow: hidden;height: 830rpx;"> |
|
|
|
|
<view class="report" v-if="list.length>0"> |
|
|
|
|
<view class="report-box" v-for="(a,index) in list"> |
|
|
|
|
<view class="report-box" v-for="(a,index) in list" @click="onClickReport(a)"> |
|
|
|
|
{{a.channel_name}} |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
@ -13,6 +13,42 @@ |
|
|
|
|
好东西就要分享给大家让生活更美好 |
|
|
|
|
</view> --> |
|
|
|
|
</view> |
|
|
|
|
<!-- 催单弹框 --> |
|
|
|
|
<view class="dia" v-if="cdDia" catchtouchmove="true"> |
|
|
|
|
<view class="diaMain"> |
|
|
|
|
<!-- <view class="ld" @click="cdDia=false"> |
|
|
|
|
<u-icon name="close" color="#999" size="32"></u-icon> |
|
|
|
|
</view> --> |
|
|
|
|
<view class="report-name">今天 {{today}},{{fromData.header_content}}</view> |
|
|
|
|
<view class="cdInfo"> |
|
|
|
|
<view class="report-line" v-for="(item) in shortList"> |
|
|
|
|
<view class=""> |
|
|
|
|
{{item.goods_name}} |
|
|
|
|
</view> |
|
|
|
|
<view class=""> |
|
|
|
|
市场价:{{item.cost_price_min}} |
|
|
|
|
</view> |
|
|
|
|
<view class=""> |
|
|
|
|
推广价:{{item.goods_price_min}} |
|
|
|
|
</view> |
|
|
|
|
<view class=""> |
|
|
|
|
SKU:{{item.goods_no}} |
|
|
|
|
</view> |
|
|
|
|
<view class=""> |
|
|
|
|
{{item.jd_short_url}} |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
<view class="reportCopy"> |
|
|
|
|
<view class="reportbut" style="color: rgb(96, 98, 102);" @click="cdDia=false"> |
|
|
|
|
取消 |
|
|
|
|
</view> |
|
|
|
|
<view class="reportbut" @click="copyData"> |
|
|
|
|
复制 |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
</template> |
|
|
|
|
|
|
|
|
@ -24,7 +60,11 @@ |
|
|
|
|
background: { |
|
|
|
|
background: 'none' |
|
|
|
|
}, |
|
|
|
|
cdDia: false, |
|
|
|
|
list: [], |
|
|
|
|
shortList: [], |
|
|
|
|
today: '', |
|
|
|
|
fromData: '', |
|
|
|
|
indexBackgroundImage: 'https://www.amiami.com.cn/static/openshop.png?t=' + new Date().getTime(), |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
@ -32,13 +72,72 @@ |
|
|
|
|
this.getTipOffList() |
|
|
|
|
}, |
|
|
|
|
methods: { |
|
|
|
|
getCurrentDate() { |
|
|
|
|
let now = new Date() |
|
|
|
|
let year = now.getFullYear() |
|
|
|
|
let month = now.getMonth() + 1 |
|
|
|
|
let day = now.getDate() |
|
|
|
|
this.today = year + '年' + month + '月' + day + '日' |
|
|
|
|
}, |
|
|
|
|
onClickReport(item) { |
|
|
|
|
this.fromData = item |
|
|
|
|
uni.showLoading({ |
|
|
|
|
title: '加载中' |
|
|
|
|
}); |
|
|
|
|
this.getJDShortLinks(item.id) |
|
|
|
|
this.getCurrentDate() |
|
|
|
|
}, |
|
|
|
|
getJDShortLinks(id) { |
|
|
|
|
help.JDShortLinks({ |
|
|
|
|
id: id |
|
|
|
|
}).then(result => { |
|
|
|
|
if (result.status == 200) { |
|
|
|
|
this.shortList = result.data.goodsList |
|
|
|
|
this.cdDia = true |
|
|
|
|
uni.hideLoading(); |
|
|
|
|
} |
|
|
|
|
}) |
|
|
|
|
}, |
|
|
|
|
copyData() { |
|
|
|
|
let that = this |
|
|
|
|
let text = '' |
|
|
|
|
that.shortList.forEach(function(obj) { |
|
|
|
|
text += |
|
|
|
|
obj.goods_name + |
|
|
|
|
'\n' + |
|
|
|
|
'市场价:' + |
|
|
|
|
obj.goods_price_min + |
|
|
|
|
'\n' + |
|
|
|
|
'推广价:' + |
|
|
|
|
obj.cost_price_min + |
|
|
|
|
'\n' + |
|
|
|
|
'SKU:' + |
|
|
|
|
obj.goods_no + |
|
|
|
|
'\n' + |
|
|
|
|
obj.jd_short_url + |
|
|
|
|
';\n' |
|
|
|
|
}) |
|
|
|
|
uni.setClipboardData({ |
|
|
|
|
data: '今天' + that.today + ',' + this.fromData.header_content + '\n' + text, |
|
|
|
|
success: () => { |
|
|
|
|
// 可以添加用户友好的提示,例如使用uni.showToast提示复制成功 |
|
|
|
|
uni.showToast({ |
|
|
|
|
title: '复制成功', |
|
|
|
|
icon: 'none' |
|
|
|
|
}); |
|
|
|
|
}, |
|
|
|
|
fail: () => { |
|
|
|
|
uni.showToast({ |
|
|
|
|
title: '复制成功', |
|
|
|
|
icon: 'none' |
|
|
|
|
}); |
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
}, |
|
|
|
|
getTipOffList() { |
|
|
|
|
help.tipOffList().then(result => { |
|
|
|
|
if (result.status == 200) { |
|
|
|
|
this.list = result.data.list.data |
|
|
|
|
// this.list = [...result.data.list.data, ...result.data.list.data, ...result.data.list.data, |
|
|
|
|
// ...result.data.list.data, ...result.data.list.data, ...result.data.list.data |
|
|
|
|
// ] |
|
|
|
|
} |
|
|
|
|
}) |
|
|
|
|
} |
|
|
|
@ -53,6 +152,88 @@ |
|
|
|
|
} |
|
|
|
|
</style> |
|
|
|
|
<style lang="scss" scoped> |
|
|
|
|
.dia { |
|
|
|
|
position: fixed; |
|
|
|
|
top: 0; |
|
|
|
|
left: 0; |
|
|
|
|
width: 100%; |
|
|
|
|
height: 100%; |
|
|
|
|
background: rgba(0, 0, 0, 0.7); |
|
|
|
|
z-index: 99; |
|
|
|
|
display: flex; |
|
|
|
|
align-items: center; |
|
|
|
|
justify-content: center; |
|
|
|
|
|
|
|
|
|
.reportCopy { |
|
|
|
|
height: 80rpx; |
|
|
|
|
width: 100%; |
|
|
|
|
border-top: 1rpx solid #f7f7f7; |
|
|
|
|
display: flex; |
|
|
|
|
|
|
|
|
|
.reportbut { |
|
|
|
|
width: 50%; |
|
|
|
|
line-height: 80rpx; |
|
|
|
|
text-align: center; |
|
|
|
|
font-size: 28rpx; |
|
|
|
|
font-family: PingFang SC, PingFang SC; |
|
|
|
|
font-weight: 400; |
|
|
|
|
color: rgb(41, 121, 255); |
|
|
|
|
; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
.report-name { |
|
|
|
|
font-size: 28rpx; |
|
|
|
|
color: #000; |
|
|
|
|
font-weight: 700; |
|
|
|
|
margin: 20rpx 24rpx; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
.report-line { |
|
|
|
|
font-size: 28rpx; |
|
|
|
|
color: #000; |
|
|
|
|
padding-top: 16rpx; |
|
|
|
|
margin-top: 16rpx; |
|
|
|
|
border-top: 1rpx dashed #999; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
.report-line:nth-child(1) { |
|
|
|
|
border-top: none !important; |
|
|
|
|
margin-top: 0 !important; |
|
|
|
|
padding-top: 0 !important; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
.diaMain { |
|
|
|
|
width: 600rpx; |
|
|
|
|
max-height: 900rpx; |
|
|
|
|
background: #fff; |
|
|
|
|
border-radius: 12rpx 12rpx 12rpx 12rpx; |
|
|
|
|
opacity: 1; |
|
|
|
|
position: relative; |
|
|
|
|
overflow: hidden; |
|
|
|
|
|
|
|
|
|
.ld { |
|
|
|
|
width: 40rpx; |
|
|
|
|
height: 40rpx; |
|
|
|
|
position: absolute; |
|
|
|
|
top: 24rpx; |
|
|
|
|
right: 24rpx; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
.cdInfo { |
|
|
|
|
overflow: hidden; |
|
|
|
|
max-height: 620rpx; |
|
|
|
|
overflow-y: auto; |
|
|
|
|
font-size: 28rpx; |
|
|
|
|
font-family: PingFang SC, PingFang SC; |
|
|
|
|
font-weight: 400; |
|
|
|
|
color: #727272; |
|
|
|
|
line-height: 38rpx; |
|
|
|
|
margin: 0 24rpx 20rpx 24rpx; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
.park { |
|
|
|
|
overflow: hidden; |
|
|
|
|
width: 100%; |
|
|
|
|