cz před 1 rokem
rodič
revize
f8d20a198c

+ 3 - 3
src/components/byTable/index.vue

@@ -17,7 +17,7 @@
   <div
     class="stat-warp"
     v-if="statConfig.length != 0"
-    :class="statWarpHeight > 200 && isMore ? 'show-more' : ''"
+    :class="statWarpHeight > 116 && isMore ? 'show-more' : ''"
   >
     <div class="title">
       <select
@@ -32,7 +32,7 @@
       <div v-if="statConfig.length === 1">{{ statConfig[0].label }}</div>
     </div>
     <div class="more-btn">
-      <span @click="isMore = !isMore" v-if="statWarpHeight > 200">
+      <span @click="isMore = !isMore" v-if="statWarpHeight > 116">
         {{ isMore ? "收起" : "展开" }}
         <i
           class="el-icon-arrow-down"
@@ -369,7 +369,7 @@ export default defineComponent({
         return item;
       });
     });
-    let isMore = ref(true);
+    let isMore = ref(false);
     const changeStatData = () => {
       nextTick(() => {
         statWarpHeight.value = document.getElementById("statWarp").offsetHeight;

+ 2 - 2
src/views/customer/file/index.vue

@@ -135,7 +135,7 @@
                         {{ dictValueLabel(record.createUser, userList) }}
                       </div>
                       <div style="margin-top: 8px">
-                        跟进内容: {{ record.date.content }}
+                        跟进内容: {{ record.content }}
                       </div>
 
                       <div v-if="record.type == '30'">
@@ -1336,7 +1336,7 @@ getDict();
 getList();
 const handleClickName = (row) => {
   proxy.$router.push({
-    path: "/ERP/customer/portrait",
+    name: "Portrait",
     query: {
       id: row.id,
     },

+ 40 - 13
src/views/customer/portrait/com/LatestProgress.vue

@@ -1,7 +1,13 @@
 <template>
   <div v-loading="loading" class="progress">
     <el-timeline reverse>
-      <el-timeline-item v-for="(item, index) in progressList" :key="index" color="#0084FF" placement="top" hide-timestamp>
+      <el-timeline-item
+        v-for="(item, index) in progressList"
+        :key="index"
+        color="#0084FF"
+        placement="top"
+        hide-timestamp
+      >
         <div class="details" :style="getColor(item.type)">
           <div class="t">{{ getTitle(item.type) }}</div>
           <div class="content11" v-if="item.type != 30">
@@ -12,11 +18,18 @@
             <span class="gray">跟进记录: </span>
             <span class="val"> {{ item.remark }} </span>
           </div>
-          <div style="margin: 8px 0; display: flex" v-if="item.fileList && item.fileList.length > 0">
+          <div
+            style="margin: 8px 0; display: flex"
+            v-if="item.fileList && item.fileList.length > 0"
+          >
             <div style="width: 36px; color: #999999">附件:</div>
             <div style="width: calc(100% - 36px)">
               <div v-for="(file, index) in item.fileList" :key="index">
-                <a style="color: #409eff; cursor: pointer" @click="openFile(file.fileUrl)">{{ file.fileName }}</a>
+                <a
+                  style="color: #409eff; cursor: pointer"
+                  @click="openFile(file.fileUrl)"
+                  >{{ file.fileName }}</a
+                >
               </div>
             </div>
           </div>
@@ -38,17 +51,27 @@ const loading = ref(false);
 const progressList = ref([]);
 const getData = () => {
   loading.value = true;
-  proxy.post("/saleQuotation/latestFollowUp", { id: props.customerId }).then((res) => {
-    progressList.value = res.rows;
-    proxy.post("/fileInfo/getList", { businessIdList: res.rows.map((rows) => rows.id) }).then((fileObj) => {
-      for (let i = 0; i < res.rows.length; i++) {
-        progressList.value[i].fileList = fileObj[progressList.value[i].id] || [];
+  proxy
+    .post("/saleQuotation/latestFollowUp", { id: props.customerId })
+    .then((res) => {
+      progressList.value = res.rows;
+      if (res.rows && res.rows.length) {
+        proxy
+          .post("/fileInfo/getList", {
+            businessIdList: res.rows.map((rows) => rows.id),
+          })
+          .then((fileObj) => {
+            for (let i = 0; i < res.rows.length; i++) {
+              progressList.value[i].fileList =
+                fileObj[progressList.value[i].id] || [];
+            }
+          });
       }
+
+      setTimeout(() => {
+        loading.value = false;
+      }, 200);
     });
-    setTimeout(() => {
-      loading.value = false;
-    }, 200);
-  });
 };
 onMounted(() => {
   if (props.customerId) {
@@ -72,7 +95,11 @@ const getContent = (item) => {
   if (item.type === 10) {
     return "报价单总金额 " + proxy.moneyFormat(item.amount, 2);
   } else if (item.type === 20) {
-    return "合同总金额 " + proxy.moneyFormat(item.amount, 2) + ` (${item.contractCode}) `;
+    return (
+      "合同总金额 " +
+      proxy.moneyFormat(item.amount, 2) +
+      ` (${item.contractCode}) `
+    );
   }
 };
 const openFile = (path) => {