Explorar el Código

系统消息提醒添加app我的标记,并优化逻辑。

DESKTOP-6LTVLN7\Liumouren hace 2 años
padre
commit
f9ce3ac379
Se han modificado 2 ficheros con 212 adiciones y 255 borrados
  1. 79 168
      src/components/layout/Header.vue
  2. 133 87
      src/views/MessageList.vue

+ 79 - 168
src/components/layout/Header.vue

@@ -1,30 +1,14 @@
 <template>
   <div id="layoutHeader">
     <el-row>
-      <el-col
-        :span="8"
-        v-if="$store.state.windowsSize.width >= 1300"
-        class="logoBox"
-      >
+      <el-col :span="8" v-if="$store.state.windowsSize.width >= 1300" class="logoBox">
         <div class="logo"></div>
         <div class="title">
-          {{
-            systemInfo.system_name
-              ? systemInfo.system_name
-              : "浦东新区资源环境智慧审计平台"
-          }}
-          <span class="title_version"
-            >Version:{{
-              systemInfo.version ? systemInfo.version : "版本信息获取失败!"
-            }}</span
-          >
+          {{ systemInfo.system_name ? systemInfo.system_name : "浦东新区资源环境智慧审计平台" }}
+          <span class="title_version">Version:{{ systemInfo.version ? systemInfo.version : "版本信息获取失败!" }}</span>
         </div>
       </el-col>
-      <el-col
-        :span="2"
-        v-if="$store.state.windowsSize.width < 1300"
-        class="logoBox"
-      >
+      <el-col :span="2" v-if="$store.state.windowsSize.width < 1300" class="logoBox">
         <div class="logo"></div>
       </el-col>
       <el-col :span="$store.state.windowsSize.width < 1300 ? 18 : 13">
@@ -37,23 +21,13 @@
           @select="select"
         >
           <el-menu-item index="1"
-            ><i
-              class="el-icon-s-home"
-              v-show="$store.state.windowsSize.width <= 1700"
-            ></i
-            ><span v-show="$store.state.windowsSize.width > 1700"
-              >首页</span
-            ></el-menu-item
+            ><i class="el-icon-s-home" v-show="$store.state.windowsSize.width <= 1700"></i
+            ><span v-show="$store.state.windowsSize.width > 1700">首页</span></el-menu-item
           >
           <el-submenu index="2">
             <template slot="title"
-              ><i
-                class="el-icon-s-order"
-                v-show="$store.state.windowsSize.width <= 1700"
-              ></i
-              ><span v-show="$store.state.windowsSize.width > 1700"
-                >疑点筛查</span
-              ></template
+              ><i class="el-icon-s-order" v-show="$store.state.windowsSize.width <= 1700"></i
+              ><span v-show="$store.state.windowsSize.width > 1700">疑点筛查</span></template
             >
             <el-menu-item index="2-1">土地资源</el-menu-item>
             <el-menu-item index="2-2">水资源</el-menu-item>
@@ -62,32 +36,17 @@
             <el-menu-item index="2-5">镇域专题</el-menu-item>
           </el-submenu>
           <el-menu-item index="3"
-            ><i
-              class="el-icon-s-order"
-              v-show="$store.state.windowsSize.width <= 1700"
-            ></i
-            ><span v-show="$store.state.windowsSize.width > 1700"
-              >综合分析</span
-            ></el-menu-item
+            ><i class="el-icon-s-order" v-show="$store.state.windowsSize.width <= 1700"></i
+            ><span v-show="$store.state.windowsSize.width > 1700">综合分析</span></el-menu-item
           >
           <el-menu-item index="4"
-            ><i
-              class="el-icon-s-management"
-              v-show="$store.state.windowsSize.width <= 1700"
-            ></i
-            ><span v-show="$store.state.windowsSize.width > 1700"
-              >全流程管理</span
-            ></el-menu-item
+            ><i class="el-icon-s-management" v-show="$store.state.windowsSize.width <= 1700"></i
+            ><span v-show="$store.state.windowsSize.width > 1700">全流程管理</span></el-menu-item
           >
           <el-submenu index="5">
             <template slot="title"
-              ><i
-                class="el-icon-s-finance"
-                v-show="$store.state.windowsSize.width <= 1700"
-              ></i
-              ><span v-show="$store.state.windowsSize.width > 1700"
-                >智能辅助</span
-              ></template
+              ><i class="el-icon-s-finance" v-show="$store.state.windowsSize.width <= 1700"></i
+              ><span v-show="$store.state.windowsSize.width > 1700">智能辅助</span></template
             >
             <el-menu-item index="5-1">法律法规</el-menu-item>
             <el-menu-item index="5-2">历史问题</el-menu-item>
@@ -100,9 +59,9 @@
         <div class="user">
           <!-- 我的任务快捷菜单 -->
           <div class="manage-icon" @click="goToMyMission()"></div>
-          <div class="alert-icon" v-if="messageLength===0"></div>
-          <div class="alert-icon" v-else-if="messageLength>0" @click="goToMessageList">
-            <div class="alert-info">12</div>
+          <div class="alert-icon" v-if="messageLength === 0"></div>
+          <div class="alert-icon" v-else-if="messageLength > 0" @click="goToMessageList">
+            <div class="alert-info">{{ messageLength }}</div>
           </div>
           <div class="split-line"></div>
           <div class="inner-user">
@@ -118,11 +77,7 @@
                 ></el-avatar>
                 <!-- <div class="inner-user-icon"></div> -->
                 <div class="inner-user-text">
-                  {{
-                    $store.state.userInfo && $store.state.userInfo.username
-                      ? $store.state.userInfo.username
-                      : userName
-                  }}
+                  {{ $store.state.userInfo && $store.state.userInfo.username ? $store.state.userInfo.username : userName }}
                 </div>
               </span>
               <el-dropdown-menu slot="dropdown">
@@ -141,11 +96,11 @@ export default {
   name: "Header",
   data() {
     return {
+      setInterval_: "",
       systemInfo: {},
-      userName: localStorage.getItem("USER_NAME")
-        ? localStorage.getItem("USER_NAME")
-        : "未登录",
+      userName: localStorage.getItem("USER_NAME") ? localStorage.getItem("USER_NAME") : "未登录",
       ActiveIndex: "0",
+      messageLength: 0,
       navData: {
         1: "首页",
         2: "疑点筛查",
@@ -160,89 +115,61 @@ export default {
         "5-2": "历史问题",
         "5-3": "指标体系",
         "5-4": "资金投入",
-        6: "消息提醒",
+        6: "消息提醒"
       },
-      
-      messageData: [
-        {
-          id: publicFun.buildGuid("message"),
-          title: "系统消息",
-          isShow: true,
-          brief:
-            "这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这新消息这里是新消息这里是新消息这里是新消息这里是新消息",
-          time: "12:16",
-          details:
-            "这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息",
-        },
-        {
-          id: publicFun.buildGuid("message"),
-          title: "系统消息",
-          isShow: true,
-          brief:
-            "这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息",
-          time: "13:16",
-          details:
-            "这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容",
-        },
-        {
-          id: publicFun.buildGuid("message"),
-          title: "系统消息",
-          isShow: true,
-          brief:
-            "这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息",
-          time: "14:20",
-          details:
-            "这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容",
-        },
-        {
-          id: publicFun.buildGuid("message"),
-          title: "系统消息",
-          isShow: false,
-          brief:
-            "这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息",
-          time: "12:16",
-          details:
-            "这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容",
-        },
-        {
-          id: publicFun.buildGuid("message"),
-          title: "系统消息",
-          isShow: false,
-          brief:
-            "这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息",
-          time: "12:16",
-          details:
-            "这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容",
-        },
-        {
-          id: publicFun.buildGuid("message"),
-          title: "系统消息",
-          isShow: false,
-          brief:
-            "这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息",
-          time: "12:16",
-          details:
-            "这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容",
-        },
-        {
-          id: publicFun.buildGuid("message"),
-          title: "系统消息",
-          isShow: false,
-          brief:
-            "这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息",
-          time: "12:16",
-          details:
-            "这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容",
-        },
-      ],
+      messageData: []
     };
   },
   mounted() {
     this.getActiveIndex(true);
     // 验证是否存在版本更新
     this.getSystemInfo();
+    this.setInterval_ = setInterval(() => {
+      this.messageLength = 0;
+      this.getMyMarkerListData();
+      this.getMessageData();
+    }, 3000);
+  },
+  destroy() {
+    clearInterval(this.setInterval_);
+    this.setInterval_ = "";
   },
   methods: {
+    // 请求手机端我的标记列表
+    getMyMarkerListData() {
+      let params = new FormData();
+      params.append("columnId", "1538");
+      params.append("states", "0");
+      params.append("pageSize", 10);
+      params.append("page", 0);
+      let sortparam = [{ field: "create_time", orderByType: 2 }];
+      params.append("orderBy", JSON.stringify(sortparam));
+      this.$Post(this.urlsCollection.selectContentList, params).then(
+        res => {
+          if (res.code === 200 && res.content.data.length > 0) {
+            if (res.content.data) {
+              this.messageLength += res.content.count;
+            }
+          }
+        },
+        error => {
+          this.$message.error(error);
+        }
+      );
+    },
+
+    getMessageData() {
+      let params = new FormData();
+      params.append("columnId", 1558);
+      params.append("states", "0");
+      params.append("pageSize", 10);
+      params.append("page", 0);
+      this.$Post(this.urlsCollection.selectContentList, params).then(res => {
+        if (res.code === 200 && res.content.data.length > 0) {
+          this.messageLength += res.content.count;
+        }
+      });
+    },
     // 请求系统信息
     getSystemInfo() {
       let params = new FormData();
@@ -253,7 +180,7 @@ export default {
       let sortparam = [{ field: "c_publish_time", orderByType: 2 }];
       params.append("orderBy", JSON.stringify(sortparam));
       this.$Post(this.urlsCollection.selectContentList, params).then(
-        (res) => {
+        res => {
           if (res.code === 200 && res.content.data.length > 0) {
             let tableData = res.content.data;
             if (tableData.length > 0) {
@@ -267,10 +194,7 @@ export default {
               if (systemVersion) {
                 if (systemVersion != this.systemInfo.version) {
                   this.$message.success("新版本已发布!自动更新中!");
-                  localStorage.setItem(
-                    "SYSTEM_VERSION",
-                    this.systemInfo.version
-                  );
+                  localStorage.setItem("SYSTEM_VERSION", this.systemInfo.version);
                   window.location.reload();
                 }
               } else {
@@ -282,7 +206,7 @@ export default {
             this.$message.error(res.message);
           }
         },
-        (error) => {
+        error => {
           this.systemInfo = {};
           this.$message.error(error);
         }
@@ -293,10 +217,7 @@ export default {
       let _ActiveIndex = "";
       if (this.$store.state.navSelect) {
         if (this.$store.state.navSelect.subIndex) {
-          _ActiveIndex =
-            this.$store.state.navSelect.index +
-            "-" +
-            this.$store.state.navSelect.subIndex;
+          _ActiveIndex = this.$store.state.navSelect.index + "-" + this.$store.state.navSelect.subIndex;
         } else {
           _ActiveIndex = this.$store.state.navSelect.index;
         }
@@ -331,7 +252,7 @@ export default {
       that.$emit("navSelect", {
         index: index[0],
         subIndex: index[1],
-        name: name,
+        name: name
       });
       // let notFound = ["2-2", "2-3", "2-4", "5-3"];
       // let notFoundState = true;
@@ -374,7 +295,7 @@ export default {
         // 我的标记
         myLabels: {},
         overlay: {},
-        analysisGroups: {},
+        analysisGroups: {}
       };
       localStorage.removeItem("TOKEN");
       localStorage.removeItem("USER_ID");
@@ -383,24 +304,18 @@ export default {
       const h = this.$createElement;
       this.$notify({
         title: "登出成功",
-        message: h("i", { style: "color: teal" }, "用户退出!感谢使用!"),
+        message: h("i", { style: "color: teal" }, "用户退出!感谢使用!")
       });
-    },
+    }
   },
   watch: {
     "$store.state.navSelect": {
       handler() {
         this.getActiveIndex(false);
       },
-      deep: true,
-    },
-    messageData: {
-      handler(val) {
-        this.messageLength = val.length;
-      },
-      immediate: true,
-    },
-  },
+      deep: true
+    }
+  }
 };
 </script>
 <style lang="less" scoped>
@@ -501,11 +416,7 @@ export default {
   color: #ffffff !important;
   font-size: 24px !important;
 }
-#layoutHeader
-  /deep/
-  .el-menu--horizontal
-  > .el-submenu
-  .el-submenu__title:hover {
+#layoutHeader /deep/ .el-menu--horizontal > .el-submenu .el-submenu__title:hover {
   background: none;
 }
 #layoutHeader /deep/ .el-submenu__title i {

+ 133 - 87
src/views/MessageList.vue

@@ -33,12 +33,16 @@
             <div class="content">
               <div class="content-text">{{ currentContent }}</div>
               <div class="content-img">
-                <img
-                  :src="currentPicture"
-                  width="500"
-                  height="300"
-                  padding="10px"
-                />
+                <img v-if="currentPicture" :src="currentPicture" width="500" height="300" padding="10px" />
+                <el-image
+                  v-if="currentPictureList.length > 0"
+                  style="width: 500px; height: 300px; padding: 10px"
+                  fit="cover"
+                  :src="currentPictureList[0]"
+                  :preview-src-list="currentPictureList"
+                >
+                </el-image>
+                <span v-if="currentPictureList.length > 0">({{ currentPictureList.length }})</span>
               </div>
             </div>
           </div>
@@ -54,83 +58,12 @@ export default {
   data() {
     return {
       messageData: [],
-      // messageData: [
-      //   {
-      //     id: publicFun.buildGuid("message"),
-      //     title: "系统消息",
-      //     isShow: true,
-      //     brief:
-      //       "这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这新消息这里是新消息这里是新消息这里是新消息这里是新消息",
-      //     time: "12:16",
-      //     details:
-      //       "这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息",
-      //   },
-      //   {
-      //     id: publicFun.buildGuid("message"),
-      //     title: "系统消息",
-      //     isShow: true,
-      //     brief:
-      //       "这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息",
-      //     time: "13:16",
-      //     details:
-      //       "这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容",
-      //   },
-      //   {
-      //     id: publicFun.buildGuid("message"),
-      //     title: "系统消息",
-      //     isShow: true,
-      //     brief:
-      //       "这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息",
-      //     time: "14:20",
-      //     details:
-      //       "这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容",
-      //   },
-      //   {
-      //     id: publicFun.buildGuid("message"),
-      //     title: "系统消息",
-      //     isShow: false,
-      //     brief:
-      //       "这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息",
-      //     time: "12:16",
-      //     details:
-      //       "这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容",
-      //   },
-      //   {
-      //     id: publicFun.buildGuid("message"),
-      //     title: "系统消息",
-      //     isShow: false,
-      //     brief:
-      //       "这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息",
-      //     time: "12:16",
-      //     details:
-      //       "这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容",
-      //   },
-      //   {
-      //     id: publicFun.buildGuid("message"),
-      //     title: "系统消息",
-      //     isShow: false,
-      //     brief:
-      //       "这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息",
-      //     time: "12:16",
-      //     details:
-      //       "这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容",
-      //   },
-      //   {
-      //     id: publicFun.buildGuid("message"),
-      //     title: "系统消息",
-      //     isShow: false,
-      //     brief:
-      //       "这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息这里是新消息",
-      //     time: "12:16",
-      //     details:
-      //       "这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容这里是具体的新消息内容",
-      //   },
-      // ],
       currentDate: "",
       currentContent: "",
       currentPicture: "",
+      currentPictureList: [],
       btnChecked: "",
-      baseUrl: "/dms",
+      baseUrl: "/dms"
     };
   },
   created() {
@@ -146,20 +79,23 @@ export default {
       params.append("states", "0,1,2,3");
       params.append("pageSize", 30);
       params.append("page", 0);
-      this.$Post(this.urlsCollection.selectContentList, params).then((res) => {
+      this.$Post(this.urlsCollection.selectContentList, params).then(res => {
         if (res.code === 200 && res.content.data.length > 0) {
-          this.messageData = res.content.data.map((v) => {
+          console.log("getMessageData", res.content.data);
+          this.messageData = res.content.data.map(v => {
             return {
               id: v.id,
               title: v.title,
-              isShow: v.c_status ? v.c_status == "1" : v.c_status == "0",
+              columnId: v.column_id,
+              isShow: v.state == 0,
               brief: v.c_brief,
               details: v.c_details,
               picture: v.c_picture,
-              time: this.$dayjs(v.c_time).format("YYYY-MM-DD HH:mm:ss"),
+              time: this.$dayjs(v.c_time).format("YYYY-MM-DD HH:mm:ss")
             };
           });
 
+          this.getMyMarkerListData();
           this.btnChecked = this.messageData[0].id;
           this.currentDate = this.messageData[0].time;
           this.currentContent = this.messageData[0].details;
@@ -167,13 +103,124 @@ export default {
         }
       });
     },
+    // 请求手机端我的标记列表
+    getMyMarkerListData() {
+      let params = new FormData();
+      params.append("columnId", "1538");
+      params.append("states", "0,1,2,3");
+      params.append("pageSize", 10);
+      params.append("page", 0);
+      let sortparam = [{ field: "create_time", orderByType: 2 }];
+      params.append("orderBy", JSON.stringify(sortparam));
+      this.$Post(this.urlsCollection.selectContentList, params).then(
+        res => {
+          if (res.code === 200 && res.content.data.length > 0) {
+            console.log("getMyMarkerListData", res.content.data);
+            if (res.content.data) {
+              console.log(res.content.data);
+              res.content.data.forEach(item => {
+                this.messageData.push({
+                  id: item.id,
+                  columnId: item.column_id,
+                  title: item.column_name,
+                  isShow: item.state == 0,
+                  brief: item.title,
+                  content: JSON.parse(item.c_content),
+                  tag: "myMarker",
+                  time: this.$dayjs(item.create_time).format("YYYY-MM-DD HH:mm:ss"),
+                  details: item.title
+                });
+              });
+            }
+          } else {
+            this.$message.error(res.message);
+          }
+        },
+        error => {
+          this.$message.error(error);
+        }
+      );
+    },
+    // 点击自定义标记后的事件
+    updateDMSDatastate(item) {
+      let updateParams = {
+        id: item.id,
+        columnId: item.columnId,
+        state: 1
+      };
+
+      this.$Post(this.urlsCollection.updateAudit, updateParams).then(res => {
+        if (res.code == 200) {
+          item.isShow = false;
+        }
+      });
+    },
     showDetails(data) {
+      // 当消息为我的标记时。
+      if (data.tag && data.tag === "myMarker") {
+        this.currentPictureList = [];
+        this.currentPicture = "";
+        if (data.content.properties.fileList) {
+          // 获取图片列表
+          for (let fileItem in data.content.properties.fileList) {
+            this.getAppTaskImage(data.content.properties.fileList[fileItem]).then(
+              fileUrl => {
+                this.currentPictureList.push(fileUrl);
+              },
+              error => {
+                console.log(error);
+              }
+            );
+          }
+        }
+      } else {
+        this.currentPictureList = [];
+        this.currentPicture = "";
+        // 系统消息图片列表
+        this.currentPicture = this.baseUrl + data.picture;
+      }
+      // 修改消息状态
+      if (data.isShow) {
+        this.updateDMSDatastate(data);
+      }
       this.btnChecked = data.id;
       this.currentDate = data.time;
       this.currentContent = data.details;
-      this.currentPicture = this.baseUrl + data.picture;
     },
-  },
+    getAppTaskImage(title) {
+      return new Promise((resolve, reject) => {
+        let params = new FormData();
+        params.append("columnId", 1793);
+        params.append("states", "0,1,2");
+        params.append("pageSize", 10);
+        params.append("page", 0);
+        let searchParam = [];
+        let paramItem = {
+          field: "title",
+          searchType: "1",
+          content: {
+            value: title
+          }
+        };
+        searchParam.push(paramItem);
+        if (searchParam.length > 0) {
+          params.append("search", JSON.stringify(searchParam));
+        }
+        this.$Post(this.urlsCollection.selectContentList, params).then(
+          res => {
+            if (res.code === 200 && res.content.data.length > 0) {
+              resolve(res.content.data[0].c_file_base64);
+            } else {
+              reject("图片请求失败");
+            }
+          },
+          error => {
+            reject(error);
+          }
+        );
+      });
+    }
+  }
 };
 </script>
 <style lang="less" scoped>
@@ -294,8 +341,7 @@ export default {
             & > div:nth-child(1) {
               width: 26px;
               height: 30px;
-              background: url("../assets/home/header_alert.png") no-repeat
-                center;
+              background: url("../assets/home/header_alert.png") no-repeat center;
             }
             & > div:nth-child(2) {
               width: 200px;