Browse Source

销售合同pdf样式

cz 1 year ago
parent
commit
4b2bf05d39

+ 308 - 0
src/components/PDF/contractPDFOne.vue

@@ -0,0 +1,308 @@
+<template>
+  <div>
+    <div id="pdfDom" ref="pdfDom">
+      <table border="1" style="width: 100%" class="table">
+        <tr>
+          <td style="width: 150px">图片</td>
+          <td>
+            <div style="font-size: 18px" class="color-class">
+              {{ printDetails.sellCorporationNameEn }}
+            </div>
+            <div style="font-size: 14px; color: #000">
+              Address: {{ printDetails.sellDetailedAddress }}
+            </div>
+            <div style="font-size: 14px; color: #000; margin-top: 5px">
+              {{ printDetails.sellCityName }},{{
+                printDetails.sellProvinceName
+              }},{{ printDetails.sellCountryName }}
+            </div>
+            <div style="margin: 8px 0; color: black">
+              Tel: <span>{{ printDetails.sellContactNumber }}</span> Fax:
+              <span></span> Website: <span></span>
+            </div>
+          </td>
+        </tr>
+        <tr>
+          <td colspan="2">
+            <div
+              class="color-class"
+              style="text-align: center; font-size: 18px"
+            >
+              Proforma Invoice
+            </div>
+          </td>
+        </tr>
+      </table>
+      <div style="height: 15px; background: #7f197f"></div>
+      <table border="1" style="width: 100%" class="table">
+        <tr>
+          <td style="width: 50%; text-align: left">
+            Buyer: {{ printDetails.buyCorporationName }}
+          </td>
+          <td style="width: 50%; text-align: left">
+            Seller: {{ printDetails.sellCorporationNameEn }}
+          </td>
+        </tr>
+      </table>
+      <table border="1" style="width: 100%; border-top: none" class="table">
+        <tr>
+          <td style="width: 15%">PI No.</td>
+          <td style="width: 35%">{{ printDetails.contractCode }}</td>
+          <td style="width: 15%">Date:</td>
+          <td style="width: 35%">{{ printDetails.createTimeEn }}</td>
+        </tr>
+        <tr>
+          <td style="width: 15%">PO No.</td>
+          <td style="width: 35%">客户PO</td>
+          <td style="width: 15%">Price Term:</td>
+          <td style="width: 35%" rowspan="2">
+            {{ dictValueLabel(printDetails.transportMethod, shippingMethod) }}
+          </td>
+        </tr>
+        <tr>
+          <td style="width: 15%">Final Destination:</td>
+          <td style="width: 35%"></td>
+          <td style="width: 15%">Loading Port:</td>
+          <!-- <td style="width: 35%">{{ printDetails.createTimeEn }}</td> -->
+        </tr>
+      </table>
+      <div style="height: 15px; background: #7f197f"></div>
+      <table border="1" style="width: 100%" class="table">
+        <tr>
+          <td style="width: 15%">Image</td>
+          <td style="width: 20%">Description</td>
+          <td style="width: 15%">Size</td>
+          <td style="width: 10%">Packaging</td>
+          <td style="width: 10%">
+            Order <br />
+            Quantity
+          </td>
+          <td style="width: 10%">Carton <br />Quantity</td>
+          <td style="width: 10%">Unit <br />Price</td>
+          <td style="width: 10%">Total <br />Amount</td>
+        </tr>
+
+        <tr
+          v-if="
+            printDetails.productInfoList &&
+            printDetails.productInfoList.length > 0
+          "
+          v-for="(item, index) in printDetails.productInfoList"
+          :key="item.productId"
+        >
+          <td style="width: 15%">图片</td>
+          <td style="width: 20%">{{ item.productName }}</td>
+          <td style="width: 15%">{{ item.spec }}</td>
+          <td style="width: 10%">包装方式</td>
+          <td style="width: 10%">
+            {{ item.productQuantity }}
+          </td>
+          <td style="width: 10%">总箱数</td>
+          <td style="width: 10%">
+            {{ printDetails.currency }} {{ moneyFormat(item.productPrice, 2) }}
+          </td>
+          <td style="width: 10%">
+            {{ printDetails.currency }} {{ moneyFormat(item.amount, 2) }}
+          </td>
+        </tr>
+        <tr>
+          <td colspan="7" style="text-align: right">Total Amount:</td>
+          <td style="width: 10%">
+            {{ printDetails.currency }}
+            {{ moneyFormat(printDetails.totalAmount, 2) }}
+          </td>
+        </tr>
+        <tr>
+          <td colspan="7" style="text-align: right">Deposit(30.00%):</td>
+          <td style="width: 10%">{{ printDetails.advanceRatio }}%</td>
+        </tr>
+        <tr>
+          <td colspan="7" style="text-align: right">Balance(70.00%):</td>
+          <td style="width: 10%">
+            剩余比例:剩余比例 = 最终价格 * (100% - 预付比例)
+          </td>
+        </tr>
+      </table>
+      <div style="height: 15px; background: #7f197f"></div>
+      <table border="1" style="width: 100%" class="table">
+        <tr>
+          <td class="width-one" style="text-align: left">1.Lead Time:</td>
+          <td style="text-align: left">{{ printDetails.deliveryTime }} Days</td>
+        </tr>
+        <tr>
+          <td class="width-one" style="text-align: left">2.Payment Term:</td>
+          <td style="text-align: left">{{ printDetails.remark }}</td>
+        </tr>
+        <tr>
+          <td class="width-one" style="text-align: left">3.Shipping Mode</td>
+          <td style="text-align: left">
+            {{ dictValueLabel(printDetails.transportMethod, shippingMethod) }}
+          </td>
+        </tr>
+        <tr>
+          <td class="width-one" style="text-align: left">4.Insurance</td>
+          <td style="text-align: left">By Buyer</td>
+        </tr>
+
+        <tr>
+          <td class="width-one" style="text-align: left">5.Banking Info</td>
+          <td style="text-align: left">
+            <div>Beneficiary Name: {{ printDetails.beneficiaryName }}</div>
+            <div>Beneficiary Bank: {{ printDetails.beneficiaryBank }}</div>
+            <div>
+              Beneficiary Bank Address:
+              {{ printDetails.beneficiaryBankAddress }}
+            </div>
+            <div>
+              Beneficiary Account Number:
+              {{ printDetails.beneficiaryAccountNumber }}
+            </div>
+            <div>Swift Code: {{ printDetails.swiftCode }}</div>
+            <div>
+              Beneficiary Address: {{ printDetails.beneficiaryAddress }}
+            </div>
+          </td>
+        </tr>
+        <tr>
+          <td class="width-one" style="text-align: left">
+            6.Important Clauses:
+          </td>
+          <td style="text-align: left">
+            A:Making payment will be considered as confirmation and
+            countersignature of this order. Order can not be canceled after
+            confirmation and countersignature except acceptance by the seller.
+            The Buyer has obligation to make full payment of order including
+            canceled orders.
+            <br />
+            B:The seller should not be responsible for the delay cause by the
+            buyer and force majeure.
+            <br />
+            C:Modification of products will not be allowed after the deposit has
+            been arranged unless acceptance by the seller. All costs and
+            <br />consequences arising from modifying the product or other
+            things will be borne by the buyer.
+            <br />
+            D:Packging details including shipping marks, barcodes, artworks,etc
+            .should be provided 30 days before cargo readty agreed by both
+            <br />parties.The delay caused by the buyer's failure to submit the
+            packaging materials on time will be borne the buyer.
+            <br />
+            E: Shipping information including consignee and notify party,
+            discharge port, loading port ects should be provided 20 before
+            cargo<br />
+            ready date. The delay caused by the buyer's failure to provide
+            shipping information on time will be borne by the buyer.
+            <br />
+            F:Please notify the seller of the special requirements of shipping
+            documents and certificates when placing an order.
+          </td>
+        </tr>
+      </table>
+      <table border="1" style="width: 100%; border-top: none" class="table">
+        <tr>
+          <td style="width: 50%; text-align: left">The Buyer's Signature</td>
+          <td style="width: 50%; text-align: left">The Seller's Signature</td>
+        </tr>
+      </table>
+    </div>
+  </div>
+</template>
+
+<script setup>
+import { NumberToChinese } from "@/utils/util.js";
+import { watch } from "vue";
+const { proxy } = getCurrentInstance();
+const printDetails = ref({});
+const props = defineProps({
+  rowData: Object,
+});
+const getPdfData = (query) => {
+  proxy.post("/contract/getContractPdfInfo", query).then((res) => {
+    printDetails.value = res;
+  });
+};
+const statistics = (label, index) => {
+  let num = 0;
+  if (
+    printDetails.value.productInfoList &&
+    printDetails.value.productInfoList.length > 0
+  ) {
+    printDetails.value.productInfoList.map((item) => {
+      if (item[label]) {
+        num = parseFloat(Number(num) + Number(item[label])).toFixed(index);
+      }
+    });
+  }
+  return num;
+};
+const statisticsTwo = (label, index) => {
+  let num = 0;
+  if (
+    printDetails.value.contractProjectList &&
+    printDetails.value.contractProjectList.length > 0
+  ) {
+    printDetails.value.contractProjectList.map((item) => {
+      if (item[label]) {
+        num = parseFloat(Number(num) + Number(item[label])).toFixed(index);
+      }
+    });
+  }
+  return num;
+};
+const productUnit = ref([]);
+const tradeMethods = ref([]);
+const shippingMethod = ref([]);
+const getDict = () => {
+  proxy.getDictOne(["trade_mode", "shipping_method", "unit"]).then((res) => {
+    tradeMethods.value = res["trade_mode"].map((x) => ({
+      label: x.dictValue,
+      value: x.dictKey,
+    }));
+    shippingMethod.value = res["shipping_method"].map((x) => ({
+      label: x.dictValue,
+      value: x.dictKey,
+    }));
+    productUnit.value = res["unit"].map((x) => ({
+      label: x.dictValue,
+      value: x.dictKey,
+    }));
+  });
+};
+getDict();
+watch(
+  props.rowData,
+  () => {
+    if (props.rowData.id) {
+      getPdfData({ id: props.rowData.id });
+    } else if (props.rowData.code) {
+      getPdfData({ code: props.rowData.code });
+    }
+  },
+  {
+    immediate: true,
+    deep: true,
+  }
+);
+</script>
+
+<style lang="scss" scoped>
+.color-class {
+  color: #7f197f;
+}
+.bck {
+  background: #7f197f;
+}
+.width-one {
+  width: 140px;
+}
+.table {
+  border-collapse: collapse;
+  border-spacing: 0;
+
+  td {
+    text-align: center;
+    padding: 2px 4px;
+    // padding: 5px 10px;
+  }
+}
+</style>

+ 234 - 0
src/components/PDF/samplePDF.vue

@@ -0,0 +1,234 @@
+<template>
+  <div>
+    <div id="pdfDom" ref="pdfDom">
+      <table border="1" style="width: 100%" class="table">
+        <tr>
+          <td style="width: 150px">图片</td>
+          <td>
+            <div style="font-size: 18px" class="color-class">
+              {{ printDetails.sellCorporationNameEn }}
+            </div>
+            <div style="font-size: 14px; color: #000">
+              Address: {{ printDetails.sellDetailedAddress }}
+            </div>
+            <div style="font-size: 14px; color: #000; margin-top: 5px">
+              {{ printDetails.sellCityName }},{{
+                printDetails.sellProvinceName
+              }},{{ printDetails.sellCountryName }}
+            </div>
+            <div style="margin: 8px 0; color: black">
+              Tel: <span>{{ printDetails.sellContactNumber }}</span> Fax:
+              <span></span> Website: <span></span>
+            </div>
+          </td>
+        </tr>
+        <tr>
+          <td colspan="2">
+            <div
+              class="color-class"
+              style="text-align: center; font-size: 18px"
+            >
+              Sample Proforma Invoice
+            </div>
+          </td>
+        </tr>
+      </table>
+      <div style="height: 15px; background: #7f197f"></div>
+      <table border="1" style="width: 100%" class="table">
+        <tr>
+          <td style="width: 50%; text-align: left">
+            Buyer: {{ printDetails.buyCorporationName }}
+          </td>
+          <td style="width: 50%; text-align: left">
+            Seller: {{ printDetails.sellCorporationNameEn }}
+          </td>
+        </tr>
+      </table>
+      <table border="1" style="width: 100%; border-top: none" class="table">
+        <tr>
+          <td style="width: 15%">Sample PI No.</td>
+          <td style="width: 35%">{{ printDetails.contractCode }}</td>
+          <td style="width: 15%">Date:</td>
+          <td style="width: 35%">{{ printDetails.createTimeEn }}</td>
+        </tr>
+        <tr>
+          <td style="width: 15%">Contact Person:</td>
+          <td style="width: 35%"></td>
+          <td style="width: 15%">Email:</td>
+          <td style="width: 35%"></td>
+        </tr>
+        <tr>
+          <td style="width: 15%">Payment Teams:</td>
+          <td style="width: 35%"></td>
+          <td style="width: 15%">Lead Time:</td>
+          <td style="width: 35%"></td>
+        </tr>
+      </table>
+      <div style="height: 15px; background: #7f197f"></div>
+      <table border="1" style="width: 100%" class="table">
+        <tr>
+          <td style="width: 15%">Image</td>
+          <td style="width: 20%">Description</td>
+          <td style="width: 15%">Size</td>
+          <td style="width: 10%">Material</td>
+          <td style="width: 10%">Logo</td>
+          <td style="width: 10%">Quantity</td>
+          <td style="width: 10%">Sample <br />Fee</td>
+          <td style="width: 10%">Total <br />Amount</td>
+        </tr>
+
+        <tr
+          v-if="
+            printDetails.productInfoList &&
+            printDetails.productInfoList.length > 0
+          "
+          v-for="(item, index) in printDetails.productInfoList"
+          :key="item.productId"
+        >
+          <td style="width: 15%">图片</td>
+          <td style="width: 20%">{{ item.productName }}</td>
+          <td style="width: 15%">{{ item.spec }}</td>
+          <td style="width: 10%">包装方式</td>
+          <td style="width: 10%">
+            {{ item.productQuantity }}
+          </td>
+          <td style="width: 10%">总箱数</td>
+          <td style="width: 10%">
+            {{ printDetails.currency }} {{ moneyFormat(item.productPrice, 2) }}
+          </td>
+          <td style="width: 10%">
+            {{ printDetails.currency }} {{ moneyFormat(item.amount, 2) }}
+          </td>
+        </tr>
+        <tr>
+          <td colspan="7" style="text-align: right">Total Amount:</td>
+          <td style="width: 10%">
+            {{ printDetails.currency }}
+            {{ moneyFormat(printDetails.totalAmount, 2) }}
+          </td>
+        </tr>
+      </table>
+      <div style="height: 15px; background: #7f197f"></div>
+      <table border="1" style="width: 100%" class="table">
+        <tr>
+          <td style="width: 200px; text-align: left">5.Banking Info</td>
+          <td style="text-align: left">
+            <div>Beneficiary Name: {{ printDetails.beneficiaryName }}</div>
+            <div>Beneficiary Bank: {{ printDetails.beneficiaryBank }}</div>
+            <div>
+              Beneficiary Bank Address:
+              {{ printDetails.beneficiaryBankAddress }}
+            </div>
+            <div>
+              Beneficiary Account Number:
+              {{ printDetails.beneficiaryAccountNumber }}
+            </div>
+            <div>Swift Code: {{ printDetails.swiftCode }}</div>
+            <div>
+              Beneficiary Address: {{ printDetails.beneficiaryAddress }}
+            </div>
+          </td>
+        </tr>
+      </table>
+    </div>
+  </div>
+</template>
+
+<script setup>
+import { NumberToChinese } from "@/utils/util.js";
+import { watch } from "vue";
+const { proxy } = getCurrentInstance();
+const printDetails = ref({});
+const props = defineProps({
+  rowData: Object,
+});
+const getPdfData = (query) => {
+  proxy.post("/contract/getContractPdfInfo", query).then((res) => {
+    printDetails.value = res;
+  });
+};
+const statistics = (label, index) => {
+  let num = 0;
+  if (
+    printDetails.value.productInfoList &&
+    printDetails.value.productInfoList.length > 0
+  ) {
+    printDetails.value.productInfoList.map((item) => {
+      if (item[label]) {
+        num = parseFloat(Number(num) + Number(item[label])).toFixed(index);
+      }
+    });
+  }
+  return num;
+};
+const statisticsTwo = (label, index) => {
+  let num = 0;
+  if (
+    printDetails.value.contractProjectList &&
+    printDetails.value.contractProjectList.length > 0
+  ) {
+    printDetails.value.contractProjectList.map((item) => {
+      if (item[label]) {
+        num = parseFloat(Number(num) + Number(item[label])).toFixed(index);
+      }
+    });
+  }
+  return num;
+};
+const productUnit = ref([]);
+const tradeMethods = ref([]);
+const shippingMethod = ref([]);
+const getDict = () => {
+  proxy.getDictOne(["trade_mode", "shipping_method", "unit"]).then((res) => {
+    tradeMethods.value = res["trade_mode"].map((x) => ({
+      label: x.dictValue,
+      value: x.dictKey,
+    }));
+    shippingMethod.value = res["shipping_method"].map((x) => ({
+      label: x.dictValue,
+      value: x.dictKey,
+    }));
+    productUnit.value = res["unit"].map((x) => ({
+      label: x.dictValue,
+      value: x.dictKey,
+    }));
+  });
+};
+getDict();
+watch(
+  props.rowData,
+  () => {
+    if (props.rowData.id) {
+      getPdfData({ id: props.rowData.id });
+    } else if (props.rowData.code) {
+      getPdfData({ code: props.rowData.code });
+    }
+  },
+  {
+    immediate: true,
+    deep: true,
+  }
+);
+</script>
+
+<style lang="scss" scoped>
+.color-class {
+  color: #7f197f;
+}
+.bck {
+  background: #7f197f;
+}
+.width-one {
+  width: 140px;
+}
+.table {
+  border-collapse: collapse;
+  border-spacing: 0;
+
+  td {
+    text-align: center;
+    padding: 2px 4px;
+    // padding: 5px 10px;
+  }
+}
+</style>

+ 8 - 2
src/components/contractCom/contractDetails.vue

@@ -28,13 +28,17 @@
       </div>
       </div>
       <div class="right">
       <div class="right">
         <div v-if="leftList && leftList.length > 0">
         <div v-if="leftList && leftList.length > 0">
-          <div style="text-align: right" v-if="activeName === 'first'">
+          <div
+            style="text-align: right; margin-bottom: 20px"
+            v-if="activeName === 'first'"
+          >
             <el-button type="primary" @click="pushProcessApproval(currentItem)"
             <el-button type="primary" @click="pushProcessApproval(currentItem)"
               >查看详情</el-button
               >查看详情</el-button
             >
             >
           </div>
           </div>
           <div v-if="activeName === 'first'">
           <div v-if="activeName === 'first'">
-            <ContractPDF :rowData="rowData"></ContractPDF>
+            <!-- <ContractPDF :rowData="rowData"></ContractPDF> -->
+            <ContractPDFOne :rowData="rowData"></ContractPDFOne>
           </div>
           </div>
           <div v-if="activeName === 'second'">
           <div v-if="activeName === 'second'">
             <PurchasePDF :rowData="rowDataOne"></PurchasePDF>
             <PurchasePDF :rowData="rowDataOne"></PurchasePDF>
@@ -70,6 +74,8 @@
 <script setup>
 <script setup>
 import PurchasePDF from "@/components/PDF/purchasePDF.vue";
 import PurchasePDF from "@/components/PDF/purchasePDF.vue";
 import ContractPDF from "@/components/PDF/contractPDF.vue";
 import ContractPDF from "@/components/PDF/contractPDF.vue";
+import ContractPDFOne from "@/components/PDF/contractPDFOne.vue";
+
 import byTable from "@/components/byTable/index";
 import byTable from "@/components/byTable/index";
 const { proxy } = getCurrentInstance();
 const { proxy } = getCurrentInstance();
 const props = defineProps({
 const props = defineProps({

File diff suppressed because it is too large
+ 496 - 135
src/components/process/EHSD/Purchase.vue


File diff suppressed because it is too large
+ 696 - 103
src/components/process/SendFunds.vue


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

@@ -310,7 +310,7 @@ const config = computed(() => {
         align: "right",
         align: "right",
       },
       },
       render(amountCNY) {
       render(amountCNY) {
-        // return proxy.moneyFormat(amountCNY, 2);
+        return proxy.moneyFormat(amountCNY, 2);
       },
       },
     },
     },
     {
     {
@@ -321,7 +321,7 @@ const config = computed(() => {
         align: "right",
         align: "right",
       },
       },
       render(sumClaimMoney) {
       render(sumClaimMoney) {
-        // return proxy.moneyFormat(sumClaimMoney, 2);
+        return proxy.moneyFormat(sumClaimMoney, 2);
       },
       },
     },
     },
     {
     {

+ 2 - 1
src/views/process/processApproval/index.vue

@@ -79,6 +79,7 @@
           <PurchaseEHSD
           <PurchaseEHSD
             ref="makeDom"
             ref="makeDom"
             :queryData="queryData.data"
             :queryData="queryData.data"
+            @auxiliaryChange="(e) => getAuxiliaryData(e)"
           ></PurchaseEHSD>
           ></PurchaseEHSD>
         </template>
         </template>
 
 
@@ -609,7 +610,7 @@ const skipPage = () => {
       });
       });
     } else if (flowForm.flowKey == "ehsd_purchase_flow") {
     } else if (flowForm.flowKey == "ehsd_purchase_flow") {
       router.replace({
       router.replace({
-        path: "/EHSD/procurement/purchasedEHSD",
+        path: "/ehsd/procurement/purchased",
       });
       });
     } else if (flowForm.flowKey == "service_contract_flow") {
     } else if (flowForm.flowKey == "service_contract_flow") {
       router.replace({
       router.replace({

+ 109 - 27
src/views/salesMange/saleContract/claim/index.vue

@@ -8,34 +8,76 @@
       highlight-current-row
       highlight-current-row
       :selectConfig="selectConfig"
       :selectConfig="selectConfig"
       :action-list="[]"
       :action-list="[]"
-      @get-list="getList">
-      <template #money="{ item }"> {{ item.currency }} {{ moneyFormat(item.amount) }} </template>
+      @get-list="getList"
+    >
+      <template #money="{ item }">
+        {{ item.currency }} {{ moneyFormat(item.amount) }}
+      </template>
       <template #isClaim="{ item }">
       <template #isClaim="{ item }">
         <div style="width: 100%">
         <div style="width: 100%">
           <span v-if="item.isClaim == 0">未认领</span>
           <span v-if="item.isClaim == 0">未认领</span>
-          <a style="color: #409eff; cursor: pointer" @click="clickRecord(item)" v-else-if="item.isClaim == 1">已认领</a>
-          <a style="color: #409eff; cursor: pointer" @click="clickRecord(item)" v-else>部分认领</a>
+          <a
+            style="color: #409eff; cursor: pointer"
+            @click="clickRecord(item)"
+            v-else-if="item.isClaim == 1"
+            >已认领</a
+          >
+          <a
+            style="color: #409eff; cursor: pointer"
+            @click="clickRecord(item)"
+            v-else
+            >部分认领</a
+          >
         </div>
         </div>
       </template>
       </template>
     </byTable>
     </byTable>
 
 
-    <el-dialog title="认领" v-if="dialogVisible" v-model="dialogVisible" width="500" v-loading="loading">
-      <byForm :formConfig="formConfig" :formOption="formOption" v-model="formData.data" :rules="rules" ref="byform">
+    <el-dialog
+      title="认领"
+      v-if="dialogVisible"
+      v-model="dialogVisible"
+      width="500"
+      v-loading="loading"
+    >
+      <byForm
+        :formConfig="formConfig"
+        :formOption="formOption"
+        v-model="formData.data"
+        :rules="rules"
+        ref="byform"
+      >
         <template #detail>
         <template #detail>
           <div style="width: 100%">
           <div style="width: 100%">
-            <el-button type="primary" style="margin-bottom: 10px" @click="dialogVisibleOne = true">选择合同</el-button>
+            <el-button
+              type="primary"
+              style="margin-bottom: 10px"
+              @click="dialogVisibleOne = true"
+              >选择合同</el-button
+            >
             <el-table :data="formData.data.claimContractList">
             <el-table :data="formData.data.claimContractList">
               <el-table-column prop="contractCode" label="合同编码" />
               <el-table-column prop="contractCode" label="合同编码" />
               <el-table-column prop="money" label="关联金额" min-width="150">
               <el-table-column prop="money" label="关联金额" min-width="150">
                 <template #default="{ row, $index }">
                 <template #default="{ row, $index }">
-                  <el-form-item :prop="'claimContractList.' + $index + '.money'" :rules="rules.money" :inline-message="true">
-                    <el-input-number v-model="row.money" :precision="2" :controls="false" :min="0" onmousewheel="return false;" />
+                  <el-form-item
+                    :prop="'claimContractList.' + $index + '.money'"
+                    :rules="rules.money"
+                    :inline-message="true"
+                  >
+                    <el-input-number
+                      v-model="row.money"
+                      :precision="2"
+                      :controls="false"
+                      :min="0"
+                      onmousewheel="return false;"
+                    />
                   </el-form-item>
                   </el-form-item>
                 </template>
                 </template>
               </el-table-column>
               </el-table-column>
               <el-table-column prop="zip" label="操作" width="100">
               <el-table-column prop="zip" label="操作" width="100">
                 <template #default="{ $index }">
                 <template #default="{ $index }">
-                  <el-button type="primary" link @click="handleRemove($index)">删除</el-button>
+                  <el-button type="primary" link @click="handleRemove($index)"
+                    >删除</el-button
+                  >
                 </template>
                 </template>
               </el-table-column>
               </el-table-column>
             </el-table>
             </el-table>
@@ -52,7 +94,8 @@
               :on-preview="handlePreview"
               :on-preview="handlePreview"
               :on-remove="handleRemove"
               :on-remove="handleRemove"
               :on-success="handleSuccess"
               :on-success="handleSuccess"
-              :before-upload="handleBeforeUpload">
+              :before-upload="handleBeforeUpload"
+            >
               <el-button type="primary">选择</el-button>
               <el-button type="primary">选择</el-button>
             </el-upload>
             </el-upload>
             <div>
             <div>
@@ -64,7 +107,8 @@
                   v-for="(item, index) in fileListCopy"
                   v-for="(item, index) in fileListCopy"
                   :key="index"
                   :key="index"
                   closable
                   closable
-                  @close="handleClose(index)">
+                  @close="handleClose(index)"
+                >
                   {{ item.fileName }}
                   {{ item.fileName }}
                 </el-tag>
                 </el-tag>
               </div>
               </div>
@@ -74,20 +118,53 @@
       </byForm>
       </byForm>
       <template #footer>
       <template #footer>
         <el-button @click="dialogVisible = false" size="large">取 消</el-button>
         <el-button @click="dialogVisible = false" size="large">取 消</el-button>
-        <el-button type="primary" @click="submitForm('byform')" size="large" :loading="submitLoading"> 确 定 </el-button>
+        <el-button
+          type="primary"
+          @click="submitForm('byform')"
+          size="large"
+          :loading="submitLoading"
+        >
+          确 定
+        </el-button>
       </template>
       </template>
     </el-dialog>
     </el-dialog>
 
 
-    <el-dialog title="合同选择" v-if="dialogVisibleOne" v-model="dialogVisibleOne" width="80%" v-loading="loading" destroy-on-close>
-      <ContractSelect @handleSelectContrct="handleSelectContrct"></ContractSelect>
+    <el-dialog
+      title="合同选择"
+      v-if="dialogVisibleOne"
+      v-model="dialogVisibleOne"
+      width="80%"
+      v-loading="loading"
+      destroy-on-close
+    >
+      <ContractSelect
+        @handleSelectContrct="handleSelectContrct"
+      ></ContractSelect>
     </el-dialog>
     </el-dialog>
 
 
-    <el-dialog title="认领记录" v-if="openRecord" v-model="openRecord" width="500">
-      <byForm :formConfig="formRecordConfig" :formOption="formOption" v-model="rowData.data">
+    <el-dialog
+      title="认领记录"
+      v-if="openRecord"
+      v-model="openRecord"
+      width="500"
+    >
+      <byForm
+        :formConfig="formRecordConfig"
+        :formOption="formOption"
+        v-model="rowData.data"
+      >
         <template #recordList>
         <template #recordList>
           <div>
           <div>
-            <div style="width: 100%" v-if="rowData.data.recordList && rowData.data.recordList.length > 0">
-              <div v-for="(item, index) in rowData.data.recordList" :key="index">
+            <div
+              style="width: 100%"
+              v-if="
+                rowData.data.recordList && rowData.data.recordList.length > 0
+              "
+            >
+              <div
+                v-for="(item, index) in rowData.data.recordList"
+                :key="index"
+              >
                 <div style="color: #ccc">{{ item.createTime }}</div>
                 <div style="color: #ccc">{{ item.createTime }}</div>
                 <div>认领人: {{ item.claimUserName }}</div>
                 <div>认领人: {{ item.claimUserName }}</div>
                 <div>合同编号: {{ item.contractCode }}</div>
                 <div>合同编号: {{ item.contractCode }}</div>
@@ -350,13 +427,15 @@ const formConfig = reactive([
 const getList = async (req) => {
 const getList = async (req) => {
   sourceList.value.pagination = { ...sourceList.value.pagination, ...req };
   sourceList.value.pagination = { ...sourceList.value.pagination, ...req };
   loading.value = true;
   loading.value = true;
-  proxy.post("/accountRunningWater/page", sourceList.value.pagination).then((message) => {
-    sourceList.value.data = message.rows;
-    sourceList.value.pagination.total = message.total;
-    setTimeout(() => {
-      loading.value = false;
-    }, 200);
-  });
+  proxy
+    .post("/accountRunningWater/page", sourceList.value.pagination)
+    .then((message) => {
+      sourceList.value.data = message.rows;
+      sourceList.value.pagination.total = message.total;
+      setTimeout(() => {
+        loading.value = false;
+      }, 200);
+    });
 };
 };
 const submitForm = () => {
 const submitForm = () => {
   byform.value.handleSubmit((valid) => {
   byform.value.handleSubmit((valid) => {
@@ -470,13 +549,16 @@ const handleRemove = (index) => {
   });
   });
 };
 };
 const handleSelectContrct = (row) => {
 const handleSelectContrct = (row) => {
-  const flag = formData.data.claimContractList.some((x) => x.contractId === row.id);
+  const flag = formData.data.claimContractList.some(
+    (x) => x.contractId === row.id
+  );
   if (flag)
   if (flag)
     return ElMessage({
     return ElMessage({
       message: "该合同已选择",
       message: "该合同已选择",
       type: "info",
       type: "info",
     });
     });
   formData.data.claimContractList.push({
   formData.data.claimContractList.push({
+    dataType: row.dataType,
     contractId: row.id,
     contractId: row.id,
     contractCode: row.code,
     contractCode: row.code,
     money: 0,
     money: 0,

+ 1 - 1
src/views/salesMange/saleContract/contractSelect/index.vue

@@ -282,7 +282,7 @@ const getDict = () => {
 const getList = async (req) => {
 const getList = async (req) => {
   sourceList.value.pagination = { ...sourceList.value.pagination, ...req };
   sourceList.value.pagination = { ...sourceList.value.pagination, ...req };
   loading.value = true;
   loading.value = true;
-  proxy.post("/contract/page", sourceList.value.pagination).then((res) => {
+  proxy.post("/contract/contractAndSamplePage", sourceList.value.pagination).then((res) => {
     sourceList.value.data = res.rows;
     sourceList.value.data = res.rows;
     sourceList.value.pagination.total = res.total;
     sourceList.value.pagination.total = res.total;
     setTimeout(() => {
     setTimeout(() => {

Some files were not shown because too many files changed in this diff