From 175a65b5c7bfb92f72851f48f2b72e1cf567f477 Mon Sep 17 00:00:00 2001
From: fanfan <franceesfan@163.com>
Date: Sat, 9 Nov 2024 13:35:44 +0800
Subject: [PATCH] =?UTF-8?q?=E7=BB=86=E8=8A=82?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

---
 pages/gamll/dailyReport.vue | 62 ++++++++++++++++++++++---------------
 1 file changed, 37 insertions(+), 25 deletions(-)

diff --git a/pages/gamll/dailyReport.vue b/pages/gamll/dailyReport.vue
index 869c16f..9cbd96a 100644
--- a/pages/gamll/dailyReport.vue
+++ b/pages/gamll/dailyReport.vue
@@ -27,25 +27,31 @@
 			</view>
 			<view class="report-name">今天 {{today}},{{fromData.header_content}}</view>
 			<!-- <view class="cdInfo"> -->
-				<scroll-view class="cdInfo" scroll-y="true">
-					<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>
+			<scroll-view class="cdInfo" scroll-y="true">
+				<view class="report-line" v-for="(item) in shortList">
+					<view class="" v-if="item.goods_name">
+						{{'★'+item.goods_name}}
 					</view>
-				</scroll-view>
+					<view class="" v-if="item.cost_price_min">
+						市场价:{{item.cost_price_min}}
+					</view>
+					<view class="" v-if="item.goods_price_min">
+						推广价:{{item.goods_price_min}}
+					</view>
+					<view class="" v-if="item.goods_no">
+						SKU:{{item.goods_no}}
+					</view>
+					<view class="" v-if="item.jd_short_url">
+						{{item.jd_short_url}}
+					</view>
+					<view class="" v-if="item.applet_short_url">
+						抢购链接:<text style="color:blue">{{item.applet_short_url}}</text>
+					</view>
+					<view class="" v-if="item.tail">
+						{{item.tail}}
+					</view>
+				</view>
+			</scroll-view>
 			<!-- </view> -->
 		</view>
 	</view>
@@ -81,7 +87,7 @@
 			onClickReport(item, type) {
 				this.fromData = item
 				uni.showLoading({
-					title: type==1?'加载中':'复制中'
+					title: type == 1 ? '加载中' : '复制中'
 				});
 				this.getJDShortLinks(item.id, type)
 				this.getCurrentDate()
@@ -107,7 +113,7 @@
 				let text = ''
 				that.shortList.forEach(function(obj) {
 					text +=
-						 '★'+obj.goods_name +
+						'★' + obj.goods_name +
 						'\n' +
 						'市场价:' +
 						obj.goods_price_min +
@@ -115,11 +121,17 @@
 						'推广价:' +
 						obj.cost_price_min +
 						'\n' +
-						'SKU:' +
-						obj.goods_no +
-						'\n' +
-						obj.jd_short_url +
-						'\n'+
+						(obj.goods_no ? 'SKU:' +
+							obj.goods_no +
+							'\n' : '') +
+						(obj.jd_short_url ? obj.jd_short_url +
+							'\n' : '') +
+						(obj.applet_short_url ? '抢购链接:' +
+							obj.applet_short_url +
+							'\n' : '') +
+						(obj.tail ? '尾端内容' +
+							obj.tail +
+							'\n' : '') +
 						' \n'
 				})
 				uni.setClipboardData({