Commit df909a25c9669e48adc9bc54a2732dfcbe64c29c

Authored by xp.Huang
2 parents d7bbedf1 18facbf6

Merge branch 'ft' into 'main_dev'

pref: 优化脚本管理里的提示信息

See merge request yunteng/thingskit-front!575
... ... @@ -2,7 +2,70 @@
2 2 <div>
3 3 <!-- 首页基础信息 -->
4 4 <div class="md:flex">
5   - <Card size="small" class="md:w-1/3 w-full !md:mt-0 !mt-4 !md:mr-4" style="color: #666">
  5 + <Card
  6 + v-if="!isAdmin(role)"
  7 + size="small"
  8 + class="md:w-1/3 w-full !md:mt-0 !mt-4 !md:mr-4"
  9 + style="color: #666"
  10 + >
  11 + <div class="flex" style="height: 100px">
  12 + <div class="mr-4">
  13 + <img
  14 + v-if="!isAdmin(role)"
  15 + src="/src/assets/images/product.png"
  16 + style="width: 5.625rem; height: 5.625rem"
  17 + />
  18 + <img
  19 + v-else
  20 + src="/src/assets/images/product.png"
  21 + style="width: 5.625rem; height: 5.625rem"
  22 + />
  23 + </div>
  24 + <div class="flex-auto">
  25 + <div class="flex justify-between" style="align-items: center">
  26 + <div
  27 + v-if="!isAdmin(role)"
  28 + style="font-size: 1.625rem; color: #333; font-weight: bold"
  29 + >
  30 + <CountTo
  31 + v-if="growCardList?.productInfo?.sumCount"
  32 + :end-val="growCardList.productInfo.sumCount"
  33 + />
  34 + <CountTo v-else :end-val="0" />
  35 + </div>
  36 + <div style="font-size: 1.625rem; color: #333; font-weight: bold" v-else>
  37 + <CountTo
  38 + v-if="growCardList?.productInfo?.sumCount"
  39 + :end-val="growCardList.productInfo?.sumCount"
  40 + />
  41 + <CountTo v-else :end-val="0" />
  42 + </div>
  43 + <Tooltip>
  44 + <template #title>
  45 + {{
  46 + !isAdmin(role)
  47 + ? `产品数:${growCardList?.productInfo?.sumCount} 今日新增 ${toThousands(
  48 + growCardList?.productInfo?.todayAdd
  49 + )}`
  50 + : `产品数:${growCardList?.customerInfo?.sumCount} 今日新增 ${toThousands(
  51 + growCardList?.productInfo?.todayAdd
  52 + )}`
  53 + }}
  54 + </template>
  55 + <img src="/src/assets/images/tip.png" style="width: 1.125rem; height: 1.125rem" />
  56 + </Tooltip>
  57 + </div>
  58 + <div> {{ !isAdmin(role) ? `产品数` : '产品数' }}</div>
  59 + </div>
  60 + </div>
  61 + <div v-if="!isAdmin(role)" class="ml-2 pt-4" style="border-top: 2px solid #f0f2f5">
  62 + 今日新增 {{ toThousands(growCardList?.productInfo?.todayAdd) }}</div
  63 + >
  64 + <div v-else class="ml-2 pt-4" style="border-top: 2px solid #f0f2f5">
  65 + 今日新增 {{ toThousands(growCardList?.productInfo?.todayAdd) }}</div
  66 + >
  67 + </Card>
  68 + <Card size="small" class="md:w-1/3 w-full !md:mt-0 !mt-4" style="color: #666">
6 69 <div class="flex" style="height: 100px">
7 70 <div class="mr-4"
8 71 ><img
... ... @@ -33,7 +96,7 @@
33 96 今日新增 {{ toThousands(growCardList?.deviceInfo?.todayAdd) }}
34 97 </div>
35 98 </Card>
36   - <Card size="small" class="md:w-1/3 w-full !md:mt-0 !mt-4 !md:mr-4" style="color: #666">
  99 + <Card size="small" class="md:w-1/3 w-full !md:mt-0 !mt-4 !md:ml-4" style="color: #666">
37 100 <div class="flex" style="height: 100px">
38 101 <div class="mr-4">
39 102 <img
... ... @@ -70,7 +133,7 @@
70 133 growCardList?.alarmInfo?.todayAdd
71 134 )}`
72 135 : `租户总量:${growCardList?.tenantInfo?.sumCount} 今日新增 ${toThousands(
73   - growCardList?.alarmInfo?.todayAdd
  136 + growCardList?.tenantInfo?.todayAdd
74 137 )}`
75 138 }}
76 139 </template>
... ... @@ -87,7 +150,7 @@
87 150 今日新增 {{ toThousands(growCardList?.tenantInfo?.todayAdd) }}</div
88 151 >
89 152 </Card>
90   - <Card size="small" class="md:w-1/3 w-full !md:mt-0 !mt-4" style="color: #666">
  153 + <Card size="small" class="md:w-1/3 w-full !md:mt-0 !mt-4 !md:ml-4" style="color: #666">
91 154 <div class="flex" style="height: 100px">
92 155 <div class="mr-4">
93 156 <img
... ... @@ -104,8 +167,8 @@
104 167 style="font-size: 1.625rem; color: #333; font-weight: bold"
105 168 >
106 169 <CountTo
107   - v-if="growCardList?.messageInfo?.messageCount"
108   - :end-val="growCardList.messageInfo.messageCount"
  170 + v-if="growCardList?.messageInfo?.todayMessageAdd"
  171 + :end-val="growCardList.messageInfo.todayMessageAdd"
109 172 />
110 173 <CountTo v-else :end-val="0" />
111 174 </div>
... ... @@ -120,88 +183,25 @@
120 183 <template #title>
121 184 {{
122 185 !isAdmin(role)
123   - ? `消息数:${growCardList?.messageInfo?.messageCount} 今日新增 ${toThousands(
  186 + ? `今日消息数:${
124 187 growCardList?.messageInfo?.todayMessageAdd
125   - )}`
  188 + } 近30日新增 ${toThousands(growCardList?.messageInfo?.messageCount)}`
126 189 : `客户总量:${growCardList?.customerInfo?.sumCount} 今日新增 ${toThousands(
127   - growCardList?.messageInfo?.todayMessageAdd
  190 + growCardList?.customerInfo?.todayAdd
128 191 )}`
129 192 }}
130 193 </template>
131 194 <img src="/src/assets/images/tip.png" style="width: 1.125rem; height: 1.125rem" />
132 195 </Tooltip>
133 196 </div>
134   - <div> {{ !isAdmin(role) ? `消息数` : '客户总量' }}</div>
  197 + <div> {{ !isAdmin(role) ? `今日消息数` : '客户总量' }}</div>
135 198 </div>
136 199 </div>
137 200 <div v-if="!isAdmin(role)" class="ml-2 pt-4" style="border-top: 2px solid #f0f2f5">
138   - 今日新增 {{ toThousands(growCardList?.messageInfo?.todayMessageAdd) }}</div
  201 + 近30日新增 {{ toThousands(growCardList?.messageInfo?.messageCount) }}</div
139 202 >
140 203 <div v-else class="ml-2 pt-4" style="border-top: 2px solid #f0f2f5">
141   - 今日新增 {{ toThousands(growCardList?.customerInfo?.todayAdd) }}</div
142   - >
143   - </Card>
144   - <Card
145   - v-if="!isAdmin(role)"
146   - size="small"
147   - class="md:w-1/3 w-full !md:mt-0 !mt-4 !md:ml-4"
148   - style="color: #666"
149   - >
150   - <div class="flex" style="height: 100px">
151   - <div class="mr-4">
152   - <img
153   - v-if="!isAdmin(role)"
154   - src="/src/assets/images/product.png"
155   - style="width: 5.625rem; height: 5.625rem"
156   - />
157   - <img
158   - v-else
159   - src="/src/assets/images/product.png"
160   - style="width: 5.625rem; height: 5.625rem"
161   - />
162   - </div>
163   - <div class="flex-auto">
164   - <div class="flex justify-between" style="align-items: center">
165   - <div
166   - v-if="!isAdmin(role)"
167   - style="font-size: 1.625rem; color: #333; font-weight: bold"
168   - >
169   - <CountTo
170   - v-if="growCardList?.productInfo?.sumCount"
171   - :end-val="growCardList.productInfo.sumCount"
172   - />
173   - <CountTo v-else :end-val="0" />
174   - </div>
175   - <div style="font-size: 1.625rem; color: #333; font-weight: bold" v-else>
176   - <CountTo
177   - v-if="growCardList?.productInfo?.sumCount"
178   - :end-val="growCardList.productInfo?.sumCount"
179   - />
180   - <CountTo v-else :end-val="0" />
181   - </div>
182   - <Tooltip>
183   - <template #title>
184   - {{
185   - !isAdmin(role)
186   - ? `产品数:${growCardList?.productInfo?.sumCount} 今日新增 ${toThousands(
187   - growCardList?.productInfo?.todayAdd
188   - )}`
189   - : `产品数:${growCardList?.customerInfo?.sumCount} 今日新增 ${toThousands(
190   - growCardList?.productInfo?.todayAdd
191   - )}`
192   - }}
193   - </template>
194   - <img src="/src/assets/images/tip.png" style="width: 1.125rem; height: 1.125rem" />
195   - </Tooltip>
196   - </div>
197   - <div> {{ !isAdmin(role) ? `产品数` : '产品数' }}</div>
198   - </div>
199   - </div>
200   - <div v-if="!isAdmin(role)" class="ml-2 pt-4" style="border-top: 2px solid #f0f2f5">
201   - 今日新增 {{ toThousands(growCardList?.productInfo?.todayAdd) }}</div
202   - >
203   - <div v-else class="ml-2 pt-4" style="border-top: 2px solid #f0f2f5">
204   - 今日新增 {{ toThousands(growCardList?.productInfo?.todayAdd) }}</div
  204 + 近30日新增 {{ toThousands(growCardList?.customerInfo?.todayAdd) }}</div
205 205 >
206 206 </Card>
207 207 </div>
... ...
1 1 <template>
2 2 <BasicDrawer
3   - :maskClosable="false"
  3 + :maskClosable="true"
4 4 @close="handleClose"
5 5 destroyOnClose
6 6 v-bind="$attrs"
... ...
... ... @@ -107,7 +107,7 @@ out.datas = teleData;
107 107 */
108 108 out.telemetry = true;
109 109 /*
110   -必填:设备或命令下发的唯一标识,设备的唯一标识必须与设备信息的“设备名称/SN码”一致
  110 +必填:设备或命令下发的唯一标识,设备的唯一标识必须与设备信息的“设备名称”一致
111 111 */
112 112 out.identifier = "01";
113 113 /*
... ... @@ -150,7 +150,7 @@ out.datas = teleData;
150 150 */
151 151 out.telemetry = true;
152 152 /*
153   -必填:设备或命令下发的唯一标识,设备的唯一标识必须与设备信息的“设备名称/SN码”一致
  153 +必填:设备或命令下发的唯一标识,设备的唯一标识必须与设备信息的“设备名称”一致
154 154 */
155 155 out.identifier = "01";
156 156 /*
... ...