cz 1 жил өмнө
parent
commit
9aeaf7dda5

Файлын зөрүү хэтэрхий том тул дарагдсан байна
+ 15483 - 5101
src/assets/icons/iconfont/demo_index.html


Файлын зөрүү хэтэрхий том тул дарагдсан байна
+ 1819 - 3
src/assets/icons/iconfont/iconfont.css


Файлын зөрүү хэтэрхий том тул дарагдсан байна
+ 0 - 0
src/assets/icons/iconfont/iconfont.js


Файлын зөрүү хэтэрхий том тул дарагдсан байна
+ 3178 - 0
src/assets/icons/iconfont/iconfont.json


BIN
src/assets/icons/iconfont/iconfont.ttf


BIN
src/assets/icons/iconfont/iconfont.woff


BIN
src/assets/icons/iconfont/iconfont.woff2


+ 1 - 1
src/components/PDF/purchasePDFOneNew.vue

@@ -50,7 +50,7 @@
             电话:{{ pdfData.buyContactNumber }}
           </td>
           <td colspan="3">
-            <div style="float: right">
+            <div style="float: right; text-align: left">
               乙方: <br />
               公司名称:{{ pdfData.sellCorporationName }} <br />
               联系人:{{ pdfData.sellContactName }}<br />

+ 9 - 2
src/views/EHSD/saleContract/contractEHSD/index.vue

@@ -774,13 +774,20 @@ const openDetails = (row) => {
   // currentContractId.value = row.id;
   // openDetailsDialog.value = true;
   // 新页面打开方式
-  const page = proxy.$router.resolve({
+  // const page = proxy.$router.resolve({
+  //   name: "contractDetails",
+  //   query: {
+  //     currentContractId: row.id,
+  //   },
+  // });
+  // window.open(page.href, "_blank");
+
+  proxy.$router.push({
     name: "contractDetails",
     query: {
       currentContractId: row.id,
     },
   });
-  window.open(page.href, "_blank");
 };
 
 const computeScale = (item) => {

+ 544 - 122
src/views/EHSD/saleContract/exportTracking/index.vue

@@ -91,7 +91,7 @@
         <div style="width: 100%">
           <div v-if="item.purchaseList && item.purchaseList.length > 0">
             <div v-for="(purchase, index) in item.purchaseList" :key="index">
-              {{ purchase.createTime }}
+              {{ purchase.createTime.slice(0, 11) }}
             </div>
           </div>
         </div>
@@ -109,7 +109,10 @@
 
       <template #remarks="{ item }">
         <div style="width: 100%">
-          <el-button type="primary" text @click="handleClickLookRemarks(item)"
+          <el-button
+            type="primary"
+            text
+            @click="handleClickLookRemarksRecords(item)"
             >查看</el-button
           >
         </div>
@@ -143,25 +146,203 @@
         </div>
       </template>
 
-      <!-- 动态插槽 -->
+      <!-- 动态头部插槽 -->
       <template
-        v-for="(documentary, index) in contractDocumentary"
+        v-for="(documentary, index) in headerList"
         v-slot:[documentary.value]="{ item }"
-        :key="index"
+        :key="documentary.value"
+      >
+        <div style="width: 100%">
+          {{ documentary.label }}
+          <span
+            style="color: #8400ff; cursor: pointer"
+            @click="handleClickHeader(documentary.value)"
+            >({{ headerData[documentary.value] }})
+            <span v-if="documentary.value == currentHeader && clickNum == 1">
+              <span
+                class="iconfont icon-iconm_shanchu"
+                style="color: #d81e06; font-size: 20px"
+              ></span>
+            </span>
+            <span v-if="documentary.value == currentHeader && clickNum == 2">
+              <span
+                class="iconfont icon-iconm_quertj"
+                style="color: #16c4af; font-size: 20px"
+              ></span>
+            </span>
+          </span>
+        </div>
+      </template>
+
+      <!-- 动态内容插槽 -->
+      <template
+        v-for="(documentary, index) in headerList"
+        v-slot:[documentary.slot]="{ item }"
+        :key="documentary.slot"
       >
         <div style="width: 100%">
+          <div v-if="documentary.value == '1'">
+            <div v-if="item.purchaseList && item.purchaseList.length > 0">
+              <div
+                v-for="(purchase, index) in item.purchaseList"
+                :key="purchase.id"
+              >
+                <el-button
+                  type="primary"
+                  text
+                  @click="handleClickLook(item, purchase, documentary)"
+                  v-if="judgeHaveData(purchase, documentary.value)"
+                  >已提交</el-button
+                >
+                <el-button
+                  type="primary"
+                  text
+                  @click="handleClickLook(item, purchase, documentary)"
+                  style="color: F59A23"
+                  v-else
+                  >未提交</el-button
+                >
+              </div>
+            </div>
+          </div>
+          <div
+            v-else-if="
+              ['2', '3', '4', '5', '7', '9'].includes(documentary.value)
+            "
+          >
+            <div v-if="item.purchaseList && item.purchaseList.length > 0">
+              <div
+                v-for="(purchase, index) in item.purchaseList"
+                :key="purchase.id"
+              >
+                <el-button
+                  type="primary"
+                  text
+                  @click="handleClickLook(item, purchase, documentary)"
+                  v-if="judgeHaveData(purchase, documentary.value)"
+                  >查看</el-button
+                >
+                <el-button
+                  type="primary"
+                  text
+                  @click="handleClickLook(item, purchase, documentary)"
+                  style="color: F59A23"
+                  v-else
+                  >添加</el-button
+                >
+              </div>
+            </div>
+          </div>
+
+          <div v-else-if="documentary.value == '6'">
+            <div v-if="item.purchaseList && item.purchaseList.length > 0">
+              <div
+                v-for="(purchase, index) in item.purchaseList"
+                :key="purchase.id"
+              >
+                <el-button
+                  type="primary"
+                  text
+                  @click="handleClickLook(item, purchase, documentary)"
+                  v-if="!judgeHaveData(purchase, documentary.value)"
+                  style="color: F59A23"
+                  >待验货</el-button
+                >
+                <el-button
+                  type="primary"
+                  text
+                  @click="handleClickLook(item, purchase, documentary)"
+                  v-else-if="judgeHaveDataOne(purchase, documentary.value)"
+                  >通过</el-button
+                >
+                <el-button
+                  type="primary"
+                  text
+                  @click="handleClickLook(item, purchase, documentary)"
+                  v-else
+                  style="color: red"
+                  >未通过</el-button
+                >
+              </div>
+            </div>
+          </div>
+
+          <div v-else-if="documentary.value == '8'">
+            <div v-if="item.purchaseList && item.purchaseList.length > 0">
+              <div
+                v-for="(purchase, index) in item.purchaseList"
+                :key="purchase.id"
+              >
+                <el-button
+                  type="primary"
+                  text
+                  @click="handleClickLook(item, purchase, documentary)"
+                  v-if="!judgeHaveData(purchase, documentary.value)"
+                  style="color: F59A23"
+                  >添加</el-button
+                >
+                <el-button
+                  type="primary"
+                  text
+                  @click="handleClickLook(item, purchase, documentary)"
+                  v-else-if="judgeHaveDataOne(purchase, documentary.value)"
+                  >已收到</el-button
+                >
+                <el-button
+                  type="primary"
+                  text
+                  @click="handleClickLook(item, purchase, documentary)"
+                  style="color: red"
+                  v-else
+                  >未收到</el-button
+                >
+              </div>
+            </div>
+          </div>
+          <div v-else-if="['10', '11', '12'].includes(documentary.value)">
+            <div v-if="item.purchaseList && item.purchaseList.length > 0">
+              <div
+                v-for="(purchase, index) in item.purchaseList"
+                :key="purchase.id"
+              >
+                <el-button
+                  type="primary"
+                  text
+                  @click="handleClickLook(item, purchase, documentary)"
+                  v-if="judgeHaveData(purchase, documentary.value)"
+                  >{{
+                    judgeHaveDataOne(purchase, documentary.value)
+                  }}</el-button
+                >
+                <el-button
+                  type="primary"
+                  text
+                  @click="handleClickLook(item, purchase, documentary)"
+                  style="color: F59A23"
+                  v-else
+                  >添加</el-button
+                >
+              </div>
+            </div>
+          </div>
+          <div v-else>暂无</div>
+        </div>
+      </template>
+
+      <!-- <template #slot1="{ item }">
+        <div style="width: 100%">
           <div v-if="item.purchaseList && item.purchaseList.length > 0">
             <div v-for="(purchase, index) in item.purchaseList" :key="index">
               <el-button
                 type="primary"
                 text
-                @click="handleClickLook(item, purchase, documentary)"
+                @click="handleClickLook(item, purchase, '1')"
                 >查看</el-button
               >
             </div>
           </div>
         </div>
-      </template>
+      </template> -->
     </byTable>
     <!-- 备注弹窗 -->
     <el-dialog
@@ -181,7 +362,7 @@
         <template #file>
           <div style="width: 100%">
             <el-upload
-              v-model:fileList="formData.remarksFormData.remarkFileList"
+              v-model:fileList="formData.remarksFormData.fileList"
               action="https://winfaster.obs.cn-south-1.myhuaweicloud.com"
               :data="uploadData"
               multiple
@@ -202,6 +383,60 @@
       </template>
     </el-dialog>
 
+    <!-- 记录弹窗 -->
+    <el-dialog
+      :title="`备注记录`"
+      v-if="openRemarkRecords"
+      v-model="openRemarkRecords"
+      width="600"
+    >
+      <div style="padding-left: 50px; margin-bottom: 20px">
+        <el-button type="primary" @click="handleClickLookRemarks()"
+          >添加备注</el-button
+        >
+      </div>
+      <el-timeline>
+        <el-timeline-item
+          v-for="(activity, index) in remarkRecordsData"
+          :key="index"
+        >
+          <div
+            style="
+              width: 100%;
+              display: flex;
+              justify-content: space-between;
+              color: #bfb9b9;
+            "
+          >
+            <div>{{ activity.createTime }}</div>
+            <div>{{ activity.userName }}</div>
+          </div>
+          <div style="width: 100%; margin-top: 8px">
+            {{ activity.documentaryRemark }}
+          </div>
+          <div
+            style="width: 100%; margin-top: 8px"
+            v-if="activity.fileList && activity.fileList.length > 0"
+          >
+            <div v-for="(item, index) in activity.fileList" :key="index">
+              <div
+                style="cursor: pointer; color: #409eff"
+                @click="openFile(item)"
+              >
+                {{ item.fileName }}
+              </div>
+            </div>
+          </div>
+        </el-timeline-item>
+      </el-timeline>
+
+      <template #footer>
+        <el-button @click="openRemarkRecords = false" size="large"
+          >关 闭</el-button
+        >
+      </template>
+    </el-dialog>
+
     <!-- 交接单、包装指示弹窗 -->
     <el-dialog
       :title="fileTitle"
@@ -225,7 +460,7 @@
               :on-success="handleSuccess"
               :on-preview="onPreviewFile"
             >
-              <!-- <el-button type="primary" plain disabled>选择</el-button> -->
+              <el-button type="primary" plain disabled>选择</el-button>
             </el-upload>
           </div>
         </template>
@@ -299,6 +534,36 @@
         ref="recordsForm"
         v-loading="formLoading"
       >
+        <template #typeSlot>
+          <div style="width: 100%">
+            <el-select
+              v-model="formData.recordsFormData.content"
+              class="m-2"
+              placeholder="请选择"
+              v-if="selectNode.value == '6'"
+            >
+              <el-option label="通过" value="1" />
+              <el-option label="未通过" value="0" />
+            </el-select>
+            <el-select
+              v-model="formData.recordsFormData.content"
+              class="m-2"
+              placeholder="请选择"
+              v-if="selectNode.value == '8'"
+            >
+              <el-option label="收到" value="1" />
+              <el-option label="未收到" value="0" />
+            </el-select>
+            <el-date-picker
+              v-if="['10', '11', '12'].includes(selectNode.value)"
+              v-model="formData.recordsFormData.content"
+              type="date"
+              placeholder="请选择"
+              format="YYYY-MM-DD"
+              value-format="YYYY-MM-DD"
+            />
+          </div>
+        </template>
         <template #file>
           <div style="width: 100%">
             <el-upload
@@ -346,24 +611,20 @@ const tradeMethods = ref([]);
 const contractDocumentary = ref([]);
 const status = ref([
   {
-    label: "待采购",
+    label: "待采购待收款",
     value: 10,
   },
   {
-    label: "待出货",
+    label: "待采购已收款",
     value: 20,
   },
   {
-    label: "已出货待收款",
+    label: "已采购待收款",
     value: 30,
   },
   {
-    label: "已收款待出货",
-    value: 40,
-  },
-  {
     label: "已完成",
-    value: 50,
+    value: 40,
   },
 ]);
 const sourceList = ref({
@@ -374,6 +635,8 @@ const sourceList = ref({
     pageSize: 10,
     keyword: "",
     orderStatus: "",
+    documentaryType: "",
+    documentarySearch: "0",
   },
 });
 const loading = ref(false);
@@ -452,7 +715,12 @@ const config = computed(() => {
       attrs: {
         label: "定金到账时间",
         prop: "claimTime",
-        width: 160,
+        width: 110,
+      },
+      render(time) {
+        if (time) {
+          return time.slice(0, 11);
+        }
       },
     },
     {
@@ -487,7 +755,7 @@ const config = computed(() => {
       attrs: {
         label: "下单时间",
         slot: "purchaseCreateTime",
-        width: 160,
+        width: 110,
       },
     },
     {
@@ -505,60 +773,6 @@ const getDict = () => {
       label: x.dictValue,
       value: x.dictKey,
     }));
-
-    if (res["contract_documentary"] && res["contract_documentary"].length > 0) {
-      contractDocumentary.value = res["contract_documentary"].map((x) => ({
-        label: x.dictValue,
-        value: x.dictKey,
-      }));
-
-      for (let i = 0; i < contractDocumentary.value.length; i++) {
-        const element = contractDocumentary.value[i];
-        let width = 100;
-        if (element.label.length > 5) {
-          width = 180;
-        }
-        let attrs = {
-          label: element.label,
-          slot: element.value,
-          isNeedHeaderSlot: false,
-          headerSlot: element.value,
-          "min-width": width,
-        };
-
-        config.value.push({
-          attrs,
-          // renderHTML(row) {
-          //   if (row.purchaseList && row.purchaseList.length > 0) {
-          //     return row.purchaseList.map((x) => {
-          //       return {
-          //         attrs: {
-          //           label: "查看",
-          //           type: "primary",
-          //           text: true,
-          //         },
-          //         el: "button",
-          //         click() {
-          //           handleClickLook(row, x, element);
-          //         },
-          //       };
-          //     });
-          //   } else {
-          //     return [];
-          //   }
-          // },
-        });
-      }
-    }
-    let attrs = {
-      label: "尾款金额",
-      slot: "balanceMoney",
-      isNeedHeaderSlot: false,
-      width: 120,
-    };
-    config.value.push({
-      attrs,
-    });
   });
 };
 const getList = async (req) => {
@@ -588,9 +802,108 @@ const getList = async (req) => {
       }, 200);
     });
 };
+const headerList = ref([
+  {
+    label: "签样",
+    value: "1",
+    slot: "slot1",
+  },
+  {
+    label: "LOGO",
+    value: "2",
+    slot: "slot2",
+  },
+  {
+    label: "包材稿件",
+    value: "3",
+    slot: "slot3",
+  },
+  {
+    label: "箱唛",
+    value: "4",
+    slot: "slot4",
+  },
+  {
+    label: "标签(内盒标/FBA 标)",
+    value: "5",
+    slot: "slot5",
+  },
+  {
+    label: "验货",
+    value: "6",
+    slot: "slot6",
+  },
+  {
+    label: "出货通知",
+    value: "7",
+    slot: "slot7",
+  },
+  {
+    label: "大货样",
+    value: "8",
+    slot: "slot8",
+  },
+  {
+    label: "订舱(BL info 给 ADA)",
+    value: "9",
+    slot: "slot9",
+  },
+  {
+    label: "发货/装柜日期",
+    value: "10",
+    slot: "slot10",
+  },
+  {
+    label: "ETD",
+    value: "11",
+    slot: "slot11",
+  },
+  {
+    label: "ETA",
+    value: "12",
+    slot: "slot12",
+  },
+]);
+const arrangeInit = () => {
+  for (let i = 0; i < headerList.value.length; i++) {
+    const element = headerList.value[i];
+    let width = 150;
+    if (element.label.length > 5) {
+      width = 250;
+    }
+    let attrs = {
+      label: element.label,
+      slot: element.slot,
+      isNeedHeaderSlot: true,
+      headerSlot: element.value,
+      "min-width": width,
+    };
+    config.value.push({
+      attrs,
+    });
+  }
+  let attrs = {
+    label: "尾款金额",
+    slot: "balanceMoney",
+    isNeedHeaderSlot: false,
+    width: 120,
+  };
+  config.value.push({
+    attrs,
+  });
+};
+arrangeInit();
+const headerData = ref({});
+const getHeaderData = () => {
+  proxy
+    .post("/contractDocumentary/getSumCount", sourceList.value.pagination)
+    .then((res) => {
+      headerData.value = res;
+    });
+};
 getDict();
-
 getList();
+getHeaderData();
 const formData = reactive({
   remarksFormData: {},
   recordsFormData: {},
@@ -626,51 +939,80 @@ const remarksRules = ref({
 const formLoading = ref(false);
 const openRemarks = ref(false);
 const remarksForm = ref(null);
-const handleClickLookRemarks = (row) => {
-  let id = row.id;
+const handleClickLookRemarks = () => {
   formData.remarksFormData = {
-    id: row.id,
-    remarkFileList: [],
-    documentaryRemark: row.documentaryRemark,
+    businessId: contractData.value.id,
+    content: "",
+    businessType: "0",
+    documentaryRemark: "",
+    documentaryType: "0",
+    fileList: [],
   };
-  proxy
-    .post("/fileInfo/getList", {
-      businessIdList: [id],
-    })
-    .then((fileObj) => {
-      if (fileObj[id] && fileObj[id].length > 0) {
-        formData.remarksFormData.remarkFileList = fileObj[id]
-          .filter((x) => x.businessType === "30")
-          .map((x) => ({ raw: x, name: x.fileName, url: x.fileUrl }));
-      }
-    });
   openRemarks.value = true;
 };
 const submitRemarks = () => {
   remarksForm.value.handleSubmit(() => {
     formLoading.value = true;
-    formData.remarksFormData.remarkFileList =
-      formData.remarksFormData.remarkFileList.map((item) => {
+    formData.remarksFormData.fileList = formData.remarksFormData.fileList.map(
+      (item) => {
         return {
           id: item.raw.id,
           fileName: item.raw.fileName,
           fileUrl: item.raw.fileUrl,
           uploadState: item.raw.uploadState,
         };
-      });
+      }
+    );
     proxy
-      .post("/contract/editContractRemark", formData.remarksFormData)
+      .post("/contractDocumentary/add", formData.remarksFormData)
       .then((res) => {
         ElMessage({
           message: "操作成功",
           type: "success",
         });
-        getList();
+        getRemarkRecordsData();
         formLoading.value = false;
         openRemarks.value = false;
       });
   });
 };
+const openRemarkRecords = ref(false);
+const remarkRecordsData = ref([]);
+const getRemarkRecordsData = () => {
+  proxy
+    .post("/contractDocumentary/page", {
+      businessId: contractData.value.id,
+      documentaryType: "0",
+    })
+    .then((res) => {
+      remarkRecordsData.value = res.rows;
+      const idList = remarkRecordsData.value.map((x) => x.id);
+      // 请求文件数据并回显
+      if (idList.length > 0) {
+        proxy
+          .post("/fileInfo/getList", {
+            businessIdList: idList,
+          })
+          .then((fileObj) => {
+            if (fileObj) {
+              for (let i = 0; i < remarkRecordsData.value.length; i++) {
+                const e = remarkRecordsData.value[i];
+                for (const key in fileObj) {
+                  if (e.id === key) {
+                    e.fileList = fileObj[key];
+                  }
+                }
+              }
+            }
+          });
+      }
+    });
+};
+const handleClickLookRemarksRecords = (row) => {
+  contractData.value = row;
+  openRemarkRecords.value = true;
+  getRemarkRecordsData();
+};
 // 上传文件
 const uploadFile = async (file) => {
   const res = await proxy.post("/fileInfo/getSing", { fileName: file.name });
@@ -696,29 +1038,7 @@ const openAddRecords = ref(false);
 const recordsLoading = ref(false);
 const recordsData = ref([]);
 const recordsForm = ref(null);
-const recordsFormConfig = computed(() => {
-  return [
-    {
-      type: "date",
-      itemType: "datetime",
-      prop: "documentaryTime",
-      label: "跟单时间",
-      disabled: false,
-    },
-    {
-      type: "input",
-      prop: "documentaryRemark",
-      label: "跟单记录",
-      itemType: "textarea",
-      disabled: false,
-    },
-    {
-      type: "slot",
-      slotName: "file",
-      label: "上传附件",
-    },
-  ];
-});
+const recordsFormConfig = ref([]);
 const recordsRules = ref({
   documentaryTime: [
     { required: true, message: "请选择跟单时间", trigger: "change" },
@@ -726,11 +1046,12 @@ const recordsRules = ref({
   documentaryRemark: [
     { required: true, message: "请输入跟单记录", trigger: "blur" },
   ],
+  content: [{ required: true, message: "请选择", trigger: "change" }],
 });
 const getRecordsData = () => {
   proxy
     .post("/contractDocumentary/page", {
-      purchaseId: purchaseData.value.id,
+      businessId: purchaseData.value.id,
       documentaryType: selectNode.value.value,
     })
     .then((res) => {
@@ -768,11 +1089,55 @@ const handleClickLook = (row, purchase, node) => {
   getRecordsData();
 };
 const handleClickAddRecord = () => {
+  let type = selectNode.value.value;
+  let label = "";
+  if (type == "6") {
+    label = "验货结论";
+  } else if (type == "8") {
+    label = "是否收到";
+  } else if (type == "10") {
+    label = "发货/装柜日期";
+  } else if (type == "11") {
+    label = "ETD日期";
+  } else if (type == "12") {
+    label = "ETA日期";
+  }
+  recordsFormConfig.value = [
+    {
+      type: "date",
+      itemType: "datetime",
+      prop: "documentaryTime",
+      label: "跟单时间",
+      disabled: false,
+    },
+    ["6", "8", "10", "11", "12"].includes(type)
+      ? {
+          type: "slot",
+          slotName: "typeSlot",
+          prop: "content",
+          label: label,
+        }
+      : {},
+    {
+      type: "input",
+      prop: "documentaryRemark",
+      label: "跟单记录",
+      itemType: "textarea",
+      disabled: false,
+    },
+    {
+      type: "slot",
+      slotName: "file",
+      label: "上传附件",
+    },
+  ];
   formData.recordsFormData = {
-    purchaseId: purchaseData.value.id,
+    businessId: purchaseData.value.id,
+    businessType: "1",
     documentaryType: selectNode.value.value,
     documentaryTime: "",
     documentaryRemark: "",
+    content: "",
     fileList: [],
   };
   openAddRecords.value = true;
@@ -799,6 +1164,7 @@ const submitRecords = () => {
           type: "success",
         });
         getRecordsData();
+        getList();
         formLoading.value = false;
         openAddRecords.value = false;
       });
@@ -846,13 +1212,19 @@ const openDetails = (row) => {
   // currentContractId.value = row.id;
   // openDetailsDialog.value = true;
   // 新页面打开方式
-  const page = proxy.$router.resolve({
+  // const page = proxy.$router.resolve({
+  //   name: "contractDetails",
+  //   query: {
+  //     currentContractId: row.id,
+  //   },
+  // });
+  // window.open(page.href, "_blank");
+  proxy.$router.push({
     name: "contractDetails",
     query: {
       currentContractId: row.id,
     },
   });
-  window.open(page.href, "_blank");
 };
 
 const clickCorporationName = (row) => {
@@ -863,6 +1235,56 @@ const clickCorporationName = (row) => {
     },
   });
 };
+
+const judgeHaveData = (purchase, documentaryType) => {
+  if (purchase.purchaseDocumentary && purchase.purchaseDocumentary.length > 0) {
+    const list = purchase.purchaseDocumentary.filter(
+      (x) => x.documentaryType == documentaryType
+    );
+    return list.length ? true : false;
+  } else {
+    return false;
+  }
+};
+
+const judgeHaveDataOne = (purchase, documentaryType) => {
+  if (purchase.purchaseDocumentary && purchase.purchaseDocumentary.length > 0) {
+    const list = purchase.purchaseDocumentary.filter(
+      (x) => x.documentaryType == documentaryType
+    );
+    if (list && list.length > 0) {
+      list.sort((a, b) => {
+        return (
+          new Date(b.documentaryTime).getTime() -
+          new Date(a.documentaryTime).getTime()
+        );
+      });
+      if (["6", "8"].includes(documentaryType)) {
+        return Number(list[0].content);
+      } else {
+        return list[0].content;
+      }
+    }
+  }
+};
+
+const currentHeader = ref("");
+const clickNum = ref(0);
+const handleClickHeader = (type) => {
+  if (currentHeader.value && currentHeader.value != type) {
+    clickNum.value = 0;
+    clickNum.value++;
+  } else {
+    clickNum.value++;
+    if (clickNum.value > 2) {
+      clickNum.value = 0;
+    }
+  }
+  currentHeader.value = type;
+  sourceList.value.pagination.documentaryType = type;
+  sourceList.value.pagination.documentarySearch = clickNum.value;
+  getList();
+};
 </script>
 
 <style lang="scss" scoped>

+ 9 - 2
src/views/EHSD/saleContract/sampleEHSD/index.vue

@@ -763,13 +763,20 @@ const openDetails = (row) => {
   // openDetailsDialog.value = true;
 
   // 新页面打开方式
-  const page = proxy.$router.resolve({
+  // const page = proxy.$router.resolve({
+  //   name: "sampleDetails",
+  //   query: {
+  //     currentSampleId: row.id,
+  //   },
+  // });
+  // window.open(page.href, "_blank");
+
+  proxy.$router.push({
     name: "sampleDetails",
     query: {
       currentSampleId: row.id,
     },
   });
-  window.open(page.href, "_blank");
 };
 
 const showSelect = (item) => {

+ 37 - 25
src/views/finance/fundManage/accountPayment/index.vue

@@ -331,10 +331,7 @@ const sourceList = ref({
 });
 let dialogVisible = ref(false);
 let rules = ref({
-  productClassifyId: [
-    { required: true, message: "请选择物料分类", trigger: "change" },
-  ],
-  type: [{ required: true, message: "请选择物料类型", trigger: "change" }],
+  amount: [{ required: true, message: "请输入付款金额", trigger: "blur" }],
 });
 const submitType = ref("add");
 const accountCurrency = ref([]);
@@ -447,7 +444,7 @@ const config = computed(() => {
       },
       renderHTML(row) {
         return [
-          row.status == "20"
+          row.status != "10"
             ? {
                 attrs: {
                   label: "打款",
@@ -539,7 +536,7 @@ const formOptionTwo = reactive({
   disabled: false,
 });
 const byform = ref(null);
-const treeListData = ref([]);
+
 const formConfig = computed(() => {
   return [
     {
@@ -606,24 +603,41 @@ const formConfig = computed(() => {
       label: "付款账户",
       required: true,
       data: accountList.value,
+      itemWidth: 50.1,
+      style: {
+        width: "100%",
+      },
     },
     {
-      type: "selectInput",
+      type: "select",
       label: "付款金额",
-      itemWidth: 60,
-      prop: "amount",
+      prop: "currency",
       data: accountCurrency.value,
-      placeholder: "请输入",
-      selectPlaceholder: "币种",
-      selectProp: "currency",
+      itemWidth: 50,
       disabled: true,
     },
     {
+      type: "number",
+      prop: "amount",
+      label: " ",
+      itemWidth: 50,
+      precision: 2,
+      min: 0,
+      controls: false,
+      style: {
+        width: "100%",
+      },
+    },
+    {
       type: "date",
       itemType: "datetime",
       prop: "expensesTime",
       label: "打款时间",
       format: "YYYY-MM-DD HH:mm:ss",
+      itemWidth: 50,
+      style: {
+        width: "100%",
+      },
     },
     {
       type: "input",
@@ -766,6 +780,10 @@ const paymentType = ref([
     value: 10,
   },
   {
+    label: "部分打款",
+    value: 15,
+  },
+  {
     label: "未打款",
     value: 20,
   },
@@ -806,24 +824,18 @@ const submitForm = () => {
     );
   });
 };
-const getTreeList = () => {
-  proxy
-    .post("/productClassify/tree", {
-      parentId: "",
-      name: "",
-      definition: "2",
-    })
-    .then((message) => {
-      treeListData.value = message;
-      formConfig.value[0].data = message;
-    });
-};
+
 const getDtl = (row) => {
   proxy.post("/accountPayment/detail", { id: row.id }).then((res) => {
     formData.data = res;
     if (submitType.value === "add") {
       formData.data.expensesTime = moment().format("yyyy-MM-DD HH:mm:ss");
       formData.data.currency = row.currency;
+      formData.data.amount = Number(
+        parseFloat(res.incomeAmount - res.amount).toFixed(2)
+      );
+    } else {
+      formData.data.expensesTime = formData.data.updateTime;
     }
     proxy
       .post("/fileInfo/getList", { businessIdList: [row.id] })
@@ -844,7 +856,7 @@ const getDtl = (row) => {
     dialogVisible.value = true;
   });
 };
-getTreeList();
+
 getList();
 const openSearch = ref(false);
 const formSearchConfig = computed(() => {

Энэ ялгаанд хэт олон файл өөрчлөгдсөн тул зарим файлыг харуулаагүй болно