From 839e7cc5f0d7ab5426ed0b0d05a67d520ba69e6b Mon Sep 17 00:00:00 2001
From: "DESKTOP-A1SENDA\\HUzy" <472860318@qq.com>
Date: Thu, 13 May 2021 15:33:08 +0800
Subject: [PATCH] =?UTF-8?q?=E5=85=A8=E9=83=A8=E7=BA=B8=E5=8E=82=E7=BA=B8?=
=?UTF-8?q?=E5=8E=82=E5=90=8D=E8=B6=85=E9=95=BF=E7=9C=81=E7=95=A5=E6=98=BE?=
=?UTF-8?q?=E7=A4=BA?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
app.js | 2 +-
pages/article/allNewInfo/index.wxml | 17 +++++++++++++++--
2 files changed, 16 insertions(+), 3 deletions(-)
diff --git a/app.js b/app.js
index 6bb01c5..6b9d64e 100644
--- a/app.js
+++ b/app.js
@@ -1,7 +1,7 @@
//app.js
App({
//----------------------------------------------globalData--------------------------------------
- evn: 0,//0:开发环境,1:测试环境,2:生产环境
+ evn: 1,//0:开发环境,1:测试环境,2:生产环境
tmplIds: ['SUjEgwDopCv9xkkSZ4KbS0L7XbAiVQor6GmPg14K760'],
agentMsgIds: ['kG8DErWDpyzBHCFaLlSKYMF7xVy8UpgogCwV_WSNt10', 'lOQ8Gvyy_dTk68bYGpRVnVA0M7DsYYrV81Gd39GUPBA'],
version: 152,
diff --git a/pages/article/allNewInfo/index.wxml b/pages/article/allNewInfo/index.wxml
index fc00af0..637147c 100644
--- a/pages/article/allNewInfo/index.wxml
+++ b/pages/article/allNewInfo/index.wxml
@@ -29,7 +29,7 @@
- {{item.shortName}}
+ {{m2.newString(item.shortName)}}
已关注
未关注
@@ -92,4 +92,17 @@
\ No newline at end of file
+ -->
+
+ var newString = function (string) {
+ if (string.length > 4) {
+ var newString = string.substring(0, 4)
+
+ return newString + '...';
+ }else{
+ return string
+ }
+
+ }
+ module.exports.newString = newString;
+
\ No newline at end of file