lihongxiao 2 лет назад
Родитель
Сommit
1f60951bb6

+ 3 - 3
config/dev.env.js

@@ -12,12 +12,12 @@ module.exports = merge(prodEnv, {
   // BASE_URL:'"https://sxzgkj.baoxianzhanggui.com/web-api"'//正式服务器
   // BASE_URL: '"http://192.168.0.115:8080/"' //凯森
   // BASE_URL: '"http:///192.168.0.106:8080/"',//屈晨
-  // BASE_URL: '"http:///192.168.0.253:8080/"',//田智
-  BASE_URL: '"http:///192.168.0.42:8080/"',//武鸿鹏
+  // BASE_URL: '"http://192.168.0.253:8080/"',//田智
+  // BASE_URL: '"http:///192.168.0.42:8080/"',//武鸿鹏
   // BASE_URL: '"http:///192.168.0.253:8080/"',//田智
   // BASE_URL: '"http:///192.168.0.42:8080/"',//武鸿鹏
   // BASE_URL: '"http://192.168.1.101:8080/"',
-  // BASE_URL: '"http:///192.168.0.22:8080/"',//郝宇
+  BASE_URL: '"http://192.168.0.250:8080/"',//
   // BASE_URL: '"http:///192.168.0.103:8080/"',//霍续亮
 })
 

+ 13 - 0
src/http/moudules/letter.js

@@ -996,4 +996,17 @@ export const getExternalAgreement = (id) => {
     url: "/tax/manager/getExternalAgreement",
     method: "get",
   })
+}
+export const saveSubOrder = (data) => {
+  return axios({
+    url: "/api/externalOrder/saveSubOrder",
+    method: "post",
+    data
+  })
+}
+export const getPolicyPrintexternalOrder = (id) => {
+  return axios({
+    url: "/api/externalOrder/getPolicyPrint?subOrderNo="+id,
+    method: "get",
+  })
 }

+ 1 - 1
src/views/AgreementManage/CarInsurance/AgreementEntry.vue

@@ -141,7 +141,7 @@
                       @click="underwritingRulesButton(scope.$index, scope.row)" />
                   </el-dropdown-item>
                   <el-dropdown-item>
-                    <kt-button label="非车配置" :size="overSize" type="text" perms="agreement:input:underwritingRules"
+                    <kt-button label="非车配置" :size="overSize" type="text" 
                       @click="nonVehicleConfigButton(scope.$index, scope.row)"/>
                   </el-dropdown-item>
                 </el-dropdown-menu>

+ 2 - 2
src/views/Core/components/detailsDialog.vue

@@ -457,9 +457,9 @@
             <span slot="title">保单信息</span>
             <div slot="boby">
               <el-row class="premium-style " :gutter="20">
-                <el-col :span="12"><span>交强险投保单号:</span>{{ orderInfo.jqapplyno }}</el-col>
+                <!-- <el-col :span="12"><span>交强险投保单号:</span>{{ orderInfo.jqapplyno }}</el-col> -->
                 <el-col :span="12"><span>交强险保单号:</span>{{ orderInfo.jqpolicyno }}</el-col>
-                <el-col v-if="orderInfo.syapplyno" :span="12"><span>商业险投保单号:</span>{{ orderInfo.syapplyno }}</el-col>
+                <!-- <el-col v-if="orderInfo.syapplyno" :span="12"><span>商业险投保单号:</span>{{ orderInfo.syapplyno }}</el-col> -->
                 <el-col v-if="orderInfo.sypolicyno" :span="12"><span>商业险保单号:</span>{{ orderInfo.sypolicyno }}</el-col>
                 <el-col :span="12" v-for="(oldfileItem, oldfileIndex) in warrantObj.oldfileList" :key="oldfileIndex">
                   <span>{{ oldfileItem.fileTitle }} :</span>{{ orderInfo.licenseno }}

+ 2 - 2
src/views/Core/components/detailsDialogPro.vue

@@ -354,9 +354,9 @@
           <span slot="title">保单信息</span>
           <div slot="boby">
             <el-row class="premium-style " :gutter="20">
-              <el-col :span="12"><span>交强险投保单号:</span>{{ orderInfo.jqapplyno }}</el-col>
+              <!-- <el-col :span="12"><span>交强险投保单号:</span>{{ orderInfo.jqapplyno }}</el-col> -->
               <el-col :span="12"><span>交强险保单号:</span>{{ orderInfo.jqpolicyno }}</el-col>
-              <el-col v-if="orderInfo.syapplyno" :span="12"><span>商业险投保单号:</span>{{ orderInfo.syapplyno }}</el-col>
+              <!-- <el-col v-if="orderInfo.syapplyno" :span="12"><span>商业险投保单号:</span>{{ orderInfo.syapplyno }}</el-col> -->
               <el-col v-if="orderInfo.sypolicyno" :span="12"><span>商业险保单号:</span>{{ orderInfo.sypolicyno }}</el-col>
               <el-col :span="12" v-for="(oldfileItem, oldfileIndex) in warrantObj.oldfileList" :key="oldfileIndex">
                 <div>

+ 40 - 0
src/views/FinancialManagement/CarInsurance/Verifytasks/Verifyintasks.vue

@@ -723,6 +723,45 @@ export default {
           let businessList = []
           let accidentList = []
           if (res.data.orderstatus == "3") {
+            if(res.data.isExternal==1){
+              this.$api.letter
+              .getPolicyPrintexternalOrder(res.data.id).then(res1=>{
+                if(res1.code==200){
+                  if (res1.data.jqPolicy) {
+                      this.oldfileList.push({
+                        fileTitle: "交强电子保单",
+                        filename: this.orderInfo.jqpolicyno,
+                        fileurl: res1.data.jqPolicy
+                      });
+                    }
+                    if (res1.data.jqSign) {
+                      this.oldfileList.push({
+                        fileTitle: "交强电子标志",
+                        filename: this.orderInfo.jqpolicyno,
+                        fileurl: res1.data.jqSign
+                      });
+                      }
+                    if (res1.data.jqSign) {
+                      accidentList.push({
+                        fileTitle: "商业电子保单",
+                        filename: this.orderInfo.sypolicyno,
+                        fileurl: res1.data.jqSign
+                      });
+                    }
+                    if (res1.data.noPolicy) {
+                      accidentList.push({
+                        fileTitle: "驾意险保单",
+                        filename: "驾意险保单",
+                        fileurl: res1.data.noPolicy
+                      });
+                    }
+                  }
+                else{
+                  this.$message.error(res1.msg)
+                }
+              })
+            }
+            else{
             switch (res.data.inscompany) {
               case "永安财险":
                 if (this.orderInfo.jqpolicyno) {
@@ -1330,6 +1369,7 @@ export default {
                 break;
               default:
             }
+          }
             let obj = {
               oldfileList: this.oldfileList,
               businessList,

+ 41 - 0
src/views/FinancialManagement/CarInsurance/Verifytasks/Verifyuntasks.vue

@@ -718,6 +718,45 @@ export default {
           let businessList = []
           let accidentList = []
           if (res.data.orderstatus == "3") {
+            if(res.data.isExternal==1){
+              this.$api.letter
+              .getPolicyPrintexternalOrder(res.data.id).then(res1=>{
+                if(res1.code==200){
+                  if (res1.data.jqPolicy) {
+                      this.oldfileList.push({
+                        fileTitle: "交强电子保单",
+                        filename: this.orderInfo.jqpolicyno,
+                        fileurl: res1.data.jqPolicy
+                      });
+                    }
+                    if (res1.data.jqSign) {
+                      this.oldfileList.push({
+                        fileTitle: "交强电子标志",
+                        filename: this.orderInfo.jqpolicyno,
+                        fileurl: res1.data.jqSign
+                      });
+                      }
+                    if (res1.data.jqSign) {
+                      accidentList.push({
+                        fileTitle: "商业电子保单",
+                        filename: this.orderInfo.sypolicyno,
+                        fileurl: res1.data.jqSign
+                      });
+                    }
+                    if (res1.data.noPolicy) {
+                      accidentList.push({
+                        fileTitle: "驾意险保单",
+                        filename: "驾意险保单",
+                        fileurl: res1.data.noPolicy
+                      });
+                    }
+                  }
+                else{
+                  this.$message.error(res1.msg)
+                }
+              })
+            }
+            else{
             switch (res.data.inscompany) {
               case "永安财险":
                 if (this.orderInfo.jqpolicyno) {
@@ -1325,6 +1364,8 @@ export default {
                 break;
               default:
             }
+          }
+
             let obj = {
               oldfileList: this.oldfileList,
               businessList,

+ 1 - 1
src/views/Letter/Letter.vue

@@ -1,5 +1,5 @@
 <template>
-        <Ktletter ref="Ktletter" :isLetter="true"></Ktletter>
+        <Ktletter ref="Ktletter" isLetter="1"></Ktletter>
 </template>
 <script>
 import Ktletter from "../Task/daikeComponents/KtLetter.vue"; 

+ 1 - 1
src/views/Task/AgentPoolChannel/AgentPoolChannel3.vue

@@ -2,7 +2,7 @@
   <div>
     <retrievalForm :fields="retrievalFields" @submit="handleFormSubmit" @toggleCollapse="toggleCollapse"
       @areaSelectChange="areaSelectChange"></retrievalForm>
-    <kt-common-table :data="pageResult" :columns="columns" element-loading-text="加载中..." v-loading="loading"
+    <kt-common-table :data="pageResult" :columns="columns1" element-loading-text="加载中..." v-loading="loading"
       :showBatchDelete="false" @findPage="findPage" button3Name="转发" button3Type="text"
       @handleButton3="transmit" button2Name="报价轨迹" button2Type="text"
       button6Name="批单" button6Type="text" @handleButton6="batchOrder"

+ 1 - 1
src/views/Task/CompanyPoolChannel/CompanyPoolChannel3.vue

@@ -2,7 +2,7 @@
   <div>
     <retrievalForm :fields="retrievalFields" @submit="handleFormSubmit" @toggleCollapse="toggleCollapse"
       @areaSelectChange="areaSelectChange"></retrievalForm>
-    <kt-common-table :data="pageResult" :columns="columns" element-loading-text="加载中..." v-loading="loading"
+    <kt-common-table :data="pageResult" :columns="columns1" element-loading-text="加载中..." v-loading="loading"
       :showBatchDelete="false" @findPage="findPage"
        button3Name="转发" button3Type="text" @handleButton3="transmit"
         button2Name="报价轨迹" button2Type="text" @handleButton2="trajectory"

+ 3 - 3
src/views/Task/DaikeLetter.vue

@@ -67,7 +67,7 @@
       <el-tabs v-model="activeName"  tab-position="left" @tab-click="handleClick">
         <el-tab-pane label="报价" name="999" > 
           <div class="quotation-content">
-            <Ktletter ref="Ktletter" :isdisabled="isdisabled"  :isLetter="false"></Ktletter>
+            <Ktletter ref="Ktletter" :isdisabled="isdisabled"  isLetter="2"></Ktletter>
           </div>
         </el-tab-pane>
         <el-tab-pane label="全部订单" name="888" :disabled="isdisabled">
@@ -182,7 +182,7 @@ export default {
       this.activeName='999'
       this.$refs.Ktletter.add()
       this.$refs.Ktletter.userId=row.userId
-      // this.$refs.Ktletter.obtainProtocol()
+      this.$refs.Ktletter.obtainProtocol()
       this.dialogVisible = false;
       this.isdisabled=false
     },
@@ -225,7 +225,7 @@ export default {
     orderEdit(data){
       this.activeName=data.activeName
       this.$refs.Ktletter.editingWay(data)
-      // this.$refs.Ktletter.obtainProtocol(data)
+      this.$refs.Ktletter.obtainProtocol(data)
     }
   }
 }

+ 134 - 0
src/views/Task/ExternalOrders.vue

@@ -0,0 +1,134 @@
+<template>
+    <div>
+        <div class="flex f-c back">
+            <el-form class="demo-ruleForm" :model="salespersonForm" label-width="100px" size="small"
+                style="margin-top: 15px">
+                <el-row type="flex" justify="space-between">
+                    <el-col :span="5">
+                        <el-form-item label="工号">
+                            <el-input placeholder="请输入工号" v-model="salespersonForm.userId" maxlength="17" type="text"
+                                show-word-limit>
+                                <el-button slot="append" type="primary" icon="el-icon-search" @click="toChooseName()"
+                                    style="color: #fff;background-color:#D42426;border-color:#D42426;"></el-button>
+                            </el-input>
+                        </el-form-item>
+                    </el-col>
+                    <el-col :span="5">
+                        <el-form-item label="业务员" prop="name">
+                            <el-input placeholder="请输入业务员" v-model="salespersonForm.name" type="text" show-word-limit>
+                                <el-button slot="append" type="primary" icon="el-icon-search" @click="toChooseName()"
+                                    style="color: #fff;background-color:#D42426;border-color:#D42426;"></el-button>
+                            </el-input>
+                        </el-form-item>
+                    </el-col>
+
+                    <el-col :span="5">
+                        <el-form-item label="工号类型">
+                            <el-select v-model="salespersonForm.noType" disabled>
+                                <el-option label="业务员" value="A"></el-option>
+                                <el-option label="代理人" value="B"></el-option>
+                            </el-select>
+                        </el-form-item>
+                    </el-col>
+                    <el-col :span="5">
+                        <el-form-item label="归属">
+                            <el-input v-model="salespersonForm.deptName" disabled></el-input>
+                        </el-form-item>
+                    </el-col>
+                </el-row>
+            </el-form>
+        </div>
+        <div class="quotation-content">
+        <Ktletter ref="Ktletter" isLetter="3"></Ktletter>
+            </div>
+        <el-dialog title="业务员信息" :visible.sync="dialogVisible">
+            <el-form :inline="true" class="demo-form-inline" size="small" label-width="80px" :model="salespersonForm">
+                <el-row :gutter="20">
+                    <el-col :span="12">
+                        <el-form-item label="工号">
+                            <el-input v-model="salespersonForm.userId" placeholder="工号" clearable></el-input>
+                        </el-form-item>
+                    </el-col>
+                    <el-col :span="12">
+                        <el-form-item label="业务员">
+                            <el-input v-model="salespersonForm.name" placeholder="业务员" clearable></el-input>
+                        </el-form-item>
+                    </el-col>
+                    <el-col :span="12">
+                        <el-form-item label="手机号">
+                            <el-input v-model="salespersonForm.mobile" placeholder="手机号" clearable></el-input>
+                        </el-form-item>
+                    </el-col>
+                    <el-col :span="9">
+                        <el-form-item label="身份证号">
+                            <el-input v-model="salespersonForm.identity" placeholder="身份证号" clearable></el-input>
+                        </el-form-item>
+                    </el-col>
+                    <el-col :span="2">
+                        <el-form-item>
+                            <el-button type="primary" size="small" @click="toChooseName()">查询</el-button>
+                        </el-form-item>
+                    </el-col>
+                </el-row>
+            </el-form>
+            <el-table size="small" :data="salespersonData" height="690" border style="width: 100%"
+                :header-cell-style="{ background: '#F7F7F9 ', fontWeight: '700', color: '#333333' }" highlight-current-row
+                @row-dblclick="reslistCurrentChange">
+                <el-table-column prop="userId" label="工号" align="center"></el-table-column>
+                <el-table-column prop="name" label="	业务员名称" align="center"></el-table-column>
+                <el-table-column prop="mobile" label="手机号" align="center"></el-table-column>
+                <el-table-column prop="identity" label="身份证号" align="center"></el-table-column>
+            </el-table>
+        </el-dialog>
+    </div>
+</template>
+<script>
+import Ktletter from "./daikeComponents/KtLetter.vue";
+export default {
+    name: 'letter',
+    components: { Ktletter },
+    data() {
+        return {
+            dialogVisible: false,
+            salespersonData: [],
+            salespersonForm: {},
+        }
+    },
+    methods: {
+        //业务列表双击选中事件
+        reslistCurrentChange(row, column, event) {
+            this.salespersonForm = row; //名称
+            this.$refs.Ktletter.add()
+            this.$refs.Ktletter.userId = row.userId
+            this.$refs.Ktletter.obtainProtocol()
+            this.dialogVisible = false;
+        },
+        toChooseName() {
+            const loading = this.$loading({
+                lock: true,
+                text: "Loading",
+                spinner: "el-icon-loading",
+                background: "rgba(0, 0, 0, 0.7)"
+            });
+            this.$api.task.getAllUsersByHospitality({ ... this.salespersonForm }).then(res => {
+                if (res.code == "200") {
+                    this.salespersonData = res.data;
+                    loading.close();
+                    this.dialogVisible = true;
+                } else {
+                    loading.close();
+                    this.$message.error(res.msg);
+                }
+            });
+        },
+
+    }
+}
+</script>
+<style lang="scss" scoped>
+
+.quotation-content{
+  overflow-y: auto;
+  height: 80vh;
+}
+</style>

+ 1 - 1
src/views/Task/TaskPoolChannel/TaskPoolChannel3.vue

@@ -2,7 +2,7 @@
   <div>
     <retrievalForm :fields="retrievalFields" @submit="handleFormSubmit" @toggleCollapse="toggleCollapse"
       @areaSelectChange="areaSelectChange"></retrievalForm>
-    <kt-common-table :data="pageResult" :columns="columns" element-loading-text="加载中..." v-loading="loading"
+    <kt-common-table :data="pageResult" :columns="columns1" element-loading-text="加载中..." v-loading="loading"
       :showBatchDelete="false" @findPage="findPage" 
       button3Name="转发" button3Type="text" @handleButton3="transmit"
       button2Name="报价轨迹" button2Type="text" @handleButton2="trajectory"

+ 555 - 53
src/views/Task/daikeComponents/KtLetter.vue

@@ -1,6 +1,6 @@
 <template>
   <div class="body">
-    <div class="Enclosure flex f-c back" v-if="isLetter">
+    <div class="Enclosure flex f-c back" v-if="isLetter=='1'">
       <div class="home flex j-s a-c">
         <div class="flex j-s a-c">
           <img src="../../../../src/icon/归属信息.png" alt class="icon-img" />
@@ -36,7 +36,7 @@
         </el-row>
       </el-form>
     </div>
-    <div class="Enclosure flex f-c back" v-if="isLetter">
+    <div class="Enclosure flex f-c back" v-if="isLetter=='1'">
       <div class="home flex j-s a-c">
         <div class="flex j-s a-c">
           <img src="../../../../src/icon/快速查询.png" alt class="icon-img" />
@@ -641,6 +641,7 @@
         </el-row>
       </el-form>
     </div>
+    
     <div class="Enclosure flex f-c back">
       <div class="home flex j-s a-c back">
         <div class="flex j-s a-c" id="more">
@@ -693,6 +694,90 @@
         </div>-->
       </div>
     </div>
+    <div class="Enclosure flex f-c back" v-if="isLetter=='3'">
+      <div class="home flex j-s a-c">
+        <div class="flex j-s a-c color" id="Waibu">
+          <img src="../../../../src/icon/车船税.png" alt class="icon-img" />
+          <span style="margin-left:10px;">外部订单</span>
+        </div>
+        <div class="flex j-c a-c">
+            <el-button v-show="policyNumberForm.jqpolicyno || policyNumberForm.sypolicyno" size="small" type="primary" @click="policyUpload()">
+              <i class="el-icon-camera-solid" style="margin-right:4px;"></i>
+              保单上传
+            </el-button>
+          </div>
+      </div>
+      <el-form class="demo-ruleForm" :model="policyNumberForm" ref="policyNumberForm" :rules="rules"
+        label-width="160px" size="small" style="margin-top: 15px" label-position="top">
+        <el-row style="flex-wrap: wrap; display: flex;">
+          <el-col :span="5">
+            <el-form-item label="交强保单号" prop="jqpolicyno">
+              <el-input v-model="policyNumberForm.jqpolicyno" placeholder="请输入交强保单号" type="text"></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col  :span="5" :offset="1">
+            <el-form-item label="商业保单号" prop="sypolicyno">
+              <el-input v-model="policyNumberForm.sypolicyno" placeholder="请输入商业保单号" type="text"></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col  :span="5" :offset="1">
+            <el-form-item label="驾意保单号" prop="jypolicyno">
+              <el-input v-model="policyNumberForm.jypolicyno" placeholder="请输入驾意保单号" type="text"></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col  :span="5" :offset="1">
+            <el-form-item label="交强险费用" prop="jqpremium">
+              <el-input v-model="policyNumberForm.jqpremium" placeholder="请输入交强险费用" type="text"></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col  :span="5" >
+            <el-form-item label="商业险费用" prop="sypremium">
+              <el-input v-model="policyNumberForm.sypremium" placeholder="请输入商业险费用" type="text"></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col  :span="5" :offset="1">
+            <el-form-item label="驾意险费用" prop="jypremium">
+              <el-input v-model="policyNumberForm.jypremium" placeholder="请输入驾意险费用" type="text"></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col  :span="5" :offset="1">
+            <el-form-item label="车船税" prop="taxamount">
+              <el-input v-model="policyNumberForm.taxamount" placeholder="请输入车船税" type="text"></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col  :span="5" :offset="1">
+            <el-form-item label="交强险手续费比例" prop="jqSuperviseCostsProportion">
+              <el-input v-model="policyNumberForm.jqSuperviseCostsProportion" placeholder="请输入交强险手续费比例" type="text"></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col  :span="5" >
+            <el-form-item label="商业险手续费比例" prop="sySuperviseCostsProportion">
+              <el-input v-model="policyNumberForm.sySuperviseCostsProportion" placeholder="请输入商业险手续费比例" type="text"></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col  :span="5" :offset="1">
+            <el-form-item label="非车手续费比例" prop="noSuperviseCostsProportion">
+              <el-input v-model="policyNumberForm.noSuperviseCostsProportion" placeholder="请输入非车手续费比例" type="text"></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col  :span="5" :offset="1">
+            <el-form-item label="交强险其他费用比例" prop="jqOtherCostsProportion">
+              <el-input v-model="policyNumberForm.jqOtherCostsProportion" placeholder="请输入交强险其他费用比例" type="text"></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col  :span="5" :offset="1">
+            <el-form-item label="商业险其他费用比例" prop="syOtherCostsProportion">
+              <el-input v-model="policyNumberForm.syOtherCostsProportion" placeholder="请输入商业险其他费用比例" type="text"></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col  :span="5" >
+            <el-form-item label="非车其他费用比例" prop="noOtherCostsProportion">
+              <el-input v-model="policyNumberForm.noOtherCostsProportion" placeholder="请输入非车其他费用比例" type="text"></el-input>
+            </el-form-item>
+          </el-col>
+        </el-row>
+      </el-form>
+    </div>
     <div class="Enclosure flex f-c back">
       <div class="home flex j-s">
         <div class="flex j-s a-c" id="company">
@@ -726,7 +811,7 @@
         <div class="companyhead">
           <el-row>
             <el-col :span="1">
-              <el-checkbox style="margin:0 10px 0 10px" @change="handleCheckAllChange"></el-checkbox>
+              <el-checkbox  v-if="isLetter!=='3'" style="margin:0 10px 0 10px" @change="handleCheckAllChange"></el-checkbox>
               <span style="font-size:14px;">全选</span>
             </el-col>
             <el-col :span="2" style="margin: 0 42px 0 35px;">
@@ -756,8 +841,8 @@
           <div v-loading.fullscreen.lock="loading" class="hovers" v-for="(reslistitem, reslistindex) in totalCompanyList"
             :key="reslistindex">
             <el-row>
-              <el-col :span="1" style="margin-left: 20px;">
-                <el-checkbox v-model="reslistitem.checked"
+              <el-col  :span="1" style="margin-left: 20px;">
+                <el-checkbox v-model="reslistitem.checked" :disabled="reslistitem.disabled"
                   @change="event => initchange(event, reslistitem.id, reslistitem.cnName, reslistindex)"></el-checkbox>
               </el-col>
               <el-col :span="3">
@@ -1004,7 +1089,7 @@
                 style="margin:20px 20px 0 100px;display: inline-block">{{ reslistitem.underwritingDescription }}</span>
               <!-- </div> -->
             </template>
-            <template v-if="reslistitem.namesimple == '恒邦财险' && reslistitem.checked && reslistitem.agreementId">
+            <template v-if="reslistitem.namesimple == '恒邦财险' && reslistitem.checked && reslistitem.agreementId && isLetter!=='3'">
               <div class="flex f-c Driving-risk">
                 <div class="dis a-c" style="margin:15px 0">
                   <span style="margin-right:15px;font-weight:bold">选择意外险</span>
@@ -1034,7 +1119,7 @@
                 </el-table>
               </div>
             </template>
-            <template v-if="reslistitem.namesimple == '华农财险' && reslistitem.checked && reslistitem.agreementId">
+            <template v-if="reslistitem.namesimple == '华农财险' && reslistitem.checked && reslistitem.agreementId &&isLetter!=='3'">
               <div class="flex f-c Driving-risk">
                 <el-form :inline="true" :model="accidentFormHN" class="demo-form-inline"
                   style="font-weight:bold;margin-top:15px" size="small">
@@ -1063,7 +1148,7 @@
                 </el-table>
               </div>
             </template>
-            <template v-if="reslistitem.namesimple == '太平财险' && reslistitem.checked && reslistitem.agreementId">
+            <template v-if="reslistitem.namesimple == '太平财险' && reslistitem.checked && reslistitem.agreementId &&isLetter!=='3'">
               <div class="flex f-c Driving-risk">
                 <div class="dis a-c" style="margin:15px 0">
                   <span style="margin-right:15px;font-weight:bold">选择意外险</span>
@@ -1083,7 +1168,7 @@
                 </el-table>
               </div>
             </template>
-            <template v-if="reslistitem.namesimple == '安盛天平' && reslistitem.checked && reslistitem.agreementId">
+            <template v-if="reslistitem.namesimple == '安盛天平' && reslistitem.checked && reslistitem.agreementId && isLetter!=='3'">
               <div class="flex f-c Driving-risk">
                 <div class="dis a-c" style="margin-top:15px">
                   <span style="margin-right:15px;font-weight:bold;">意外险类型</span>
@@ -1108,7 +1193,7 @@
                 </el-table>
               </div>
             </template>
-            <template v-if="reslistitem.namesimple == '中国人寿' && reslistitem.checked && reslistitem.agreementId">
+            <template v-if="reslistitem.namesimple == '中国人寿' && reslistitem.checked && reslistitem.agreementId&& isLetter!=='3'">
               <div style="margin:15px 0 15px 100px">
                 <span>商业险折扣:</span>
                 <el-input style="width:220px" :disabled="!lastCompanyId" size="small" v-model="reslistitem.discount"
@@ -1141,7 +1226,7 @@
                 </el-table>
               </div>
             </template>
-            <template v-if="reslistitem.namesimple == '众安财险' && reslistitem.checked && reslistitem.agreementId">
+            <template v-if="reslistitem.namesimple == '众安财险' && reslistitem.checked && reslistitem.agreementId && isLetter!=='3'">
               <div class="flex f-c Driving-risk">
                 <div class="dis a-c" style="margin:15px 0">
                   <span style="margin-right:15px;font-weight:bold">选择意外险</span>
@@ -1160,7 +1245,7 @@
                 </el-table>
               </div>
             </template>
-            <template v-if="reslistitem.namesimple == '紫金财险' && reslistitem.checked && reslistitem.agreementId">
+            <template v-if="reslistitem.namesimple == '紫金财险' && reslistitem.checked && reslistitem.agreementId && isLetter!=='3'">
               <div style="margin:15px 0 15px 100px">
                 <span>自主定价系数:</span>
                 <el-input style="width:220px" size="small" v-model="reslistitem.coefficient"
@@ -1202,7 +1287,7 @@
                 </el-table>
               </div>
             </template>
-            <template v-if="reslistitem.namesimple == '永诚财险' && reslistitem.checked && reslistitem.agreementId">
+            <template v-if="reslistitem.namesimple == '永诚财险' && reslistitem.checked && reslistitem.agreementId && isLetter!=='3'">
               <div class="flex f-c Driving-risk">
                 <el-form :inline="true" :model="accidentForm" class="demo-form-inline" size="small"
                   style="font-weight:bold;margin-top:15px">
@@ -1232,7 +1317,7 @@
                 </el-table>
               </div>
             </template>
-            <template v-if="reslistitem.namesimple == '国任财险' && reslistitem.checked && reslistitem.agreementId">
+            <template v-if="reslistitem.namesimple == '国任财险' && reslistitem.checked && reslistitem.agreementId && isLetter!=='3'">
               <!-- <div style="margin:10px 0 0 100px;">
               <span style="margin-right:20px"> {{reslistitem.underwritingDescription}}</span>-->
               <el-button type="text" style="margin:10px 0 0 100px;"
@@ -1273,7 +1358,7 @@
                 </el-table>
               </div>
             </template>
-            <template v-if="reslistitem.namesimple == '中煤财险' && reslistitem.checked && reslistitem.agreementId">
+            <template v-if="reslistitem.namesimple == '中煤财险' && reslistitem.checked && reslistitem.agreementId && isLetter!=='3'">
               <div class="flex f-c Driving-risk accident-style zmDriving">
                 <el-form :inline="true" :model="accidentFormZM" class="demo-form-inline" size="small"
                   style="font-weight:bold;margin-top:15px">
@@ -1314,7 +1399,7 @@
                 </el-table>
               </div>
             </template>
-            <template v-if="reslistitem.namesimple == '大家财险' && reslistitem.checked && reslistitem.agreementId">
+            <template v-if="reslistitem.namesimple == '大家财险' && reslistitem.checked && reslistitem.agreementId && isLetter!=='3'">
               <div class="flex f-c Driving-risk">
                 <div class="dis a-c" style="margin-top:15px">
                   <span style="margin-right:15px;font-weight:bold">选择意外险</span>
@@ -1334,7 +1419,7 @@
                 </el-table>
               </div>
             </template>
-            <template v-if="reslistitem.namesimple == '渤海财险' && reslistitem.checked && reslistitem.agreementId">
+            <template v-if="reslistitem.namesimple == '渤海财险' && reslistitem.checked && reslistitem.agreementId && isLetter!=='3'">
               <div class="flex f-c Driving-risk" style="margin-top:15px">
                 <el-form :inline="true" :model="boHaiaccidentForm" class="demo-form-inline" size="small">
                   <el-form-item label="意外险类型" style="margin-right:30px;">
@@ -1366,7 +1451,7 @@
         </div>
       </div>
     </div>
-    <div class="Enclosure flex f-c" v-if="isLetter">
+    <div class="Enclosure flex f-c" v-if="isLetter=='1'">
       <div class="home flex j-s a-c back">
         <div class="flex j-s a-c color">
           <img src="../../../../src/icon/报价历史.png" alt class="icon-img" />
@@ -2035,18 +2120,20 @@
         <el-button size="small" type="primary" @click="uploadinformation">上传资料</el-button>
       </span>
     </el-dialog>
-    <div v-if="isLetter" class="flex j-c a-c" :class="{
+    <div v-if="isLetter=='1'" class="flex j-c a-c" :class="{
       'footer': true,
       'shadow': !isBottom
     }">
       <el-button size="small" @click="add()">录下一单</el-button>
       <el-button type="primary" :loading="calculateLoading" size="small" @click="quote()">保费计算</el-button>
     </div>
-    <div v-else style="text-align: center">
+    <div v-if="isLetter=='2'" style="text-align: center">
       <el-button type="primary" :loading="calculateLoading" size="small" @click="quote()">保费计算</el-button>
     </div>
-
-    <div class="Anchor-link flex f-c j-s a-c" v-if="isLetter">
+    <div v-if="isLetter=='3'" style="text-align: center">
+      <el-button type="primary" size="small" @click="preserveQuote()" :loading="preserveQuoteLoading">保存</el-button>
+    </div>
+    <div class="Anchor-link flex f-c j-s a-c" v-if="isLetter=='1'">
       <div>
         <img src="../../../../src/icon/车辆信息.png" alt class="icon-img" @click="handleScroll('Car')" />
       </div>
@@ -2127,6 +2214,71 @@
         <el-table-column prop="opinion" label="备注"></el-table-column>
       </el-table>
     </el-dialog>
+    <!-- 保单上传 -->
+    <el-dialog :visible.sync="policyUploaddialogVisible" width="30%">
+      <div slot="title" class="dialog-title">
+        <span>保单上传</span>
+      </div >
+      <el-form :model="policyNumberForm" :rules="rules" ref="ruleForm" label-width="100px" class="demo-ruleForm">
+        <el-form-item label="交强保单:" prop="jqPolicy">
+          <el-upload
+            class="upload-demo"
+            ref="jqPolicyupload"
+            action="#"
+            :limit="1" 
+            :auto-upload="false"
+            :file-list="fileListjqPolicy"
+            :on-change="file => policydrivingupload(file, 'jqPolicy')" 
+           >
+            <el-button size="small" type="primary">点击上传</el-button>
+          </el-upload>
+        </el-form-item>
+        <el-form-item label="商业保单:" prop="syPolicy">
+          <el-upload
+            class="upload-demo"
+            ref="syPolicyupload"
+            action="#"
+            :limit="1" 
+            :auto-upload="false"
+            :file-list="fileListnoPolicy"
+            :on-change="file => policydrivingupload(file, 'syPolicy')" 
+           >
+            <el-button size="small" type="primary">点击上传</el-button>
+          </el-upload>
+        </el-form-item>
+        <el-form-item label="非车保单:" prop="noPolicy">
+          <el-upload
+            class="upload-demo"
+            ref="noPolicyupload"
+            action="#"
+            :limit="1" 
+            :auto-upload="false"
+            :file-list="fileListnoPolicy"
+            :on-change="file => policydrivingupload(file, 'noPolicy')" 
+           >
+            <el-button size="small" type="primary">点击上传</el-button>
+          </el-upload>
+        </el-form-item>
+        <el-form-item label="交强电子标志:" prop="jqSign">
+          <el-upload
+            class="upload-demo"
+            ref="jqSignupload"
+            action="#"
+            :limit="1" 
+            :auto-upload="false"
+            :file-list="fileListjqSign"
+            :on-change="file => policydrivingupload(file, 'jqSign')" 
+           >
+            <el-button size="small" type="primary">点击上传</el-button>
+          </el-upload>
+        </el-form-item>
+      </el-form>
+         
+      <span slot="footer" class="dialog-footer">
+        <el-button size="small" @click="policyUploaddialogVisible = false">取 消</el-button>
+        <el-button size="small" type="primary" @click="policyUploaddialogVisible = false">确 定</el-button>
+      </span>
+    </el-dialog>
   </div>
 </template>
 <script>
@@ -2185,6 +2337,21 @@ export default {
       }
     };
     return {
+      policyNumberForm:{
+        jqpolicyno: '',
+         sypolicyno: '',
+        jypolicyno: '',
+        jqpremium:'',
+        sypremium: '',
+        jypremium:'',
+        taxamount: '',
+        jqSuperviseCostsProportion: '',
+        sySuperviseCostsProportion: '',
+        noSuperviseCostsProportion: '',
+        jqOtherCostsProportion: '',
+        syOtherCostsProportion: '',
+        noOtherCostsProportion:'',
+      },
       watermarkedImage: '',
       redictInfoMsg: [],
       redictInfodialogVisible: false,
@@ -2270,6 +2437,7 @@ export default {
       taipingaccidentalDrivingVo: {}, //太平驾意险
       licenseplate: true,
       calculateLoading: false, //保费计算按钮 节流
+      preserveQuoteLoading:false,//保存按钮
       accidentForm: {
         quantity: "1",
         sumPremium: 0
@@ -2373,6 +2541,7 @@ export default {
       uploadcardialogVisible: false, //行驶证识别     显示/隐藏
       uploaduserdialogVisible: false, //身份证识别     显示/隐藏
       imageUploaddialogVisible: false, //影像上传     显示/隐藏
+      policyUploaddialogVisible:false,  //保单上传
       underwritingdialogVisible: false, //核保信息   显示/隐藏
       renewalCodedialogVisible: false, //转保确认码输入
       hbsubmitdialogVisible: false, //核保弹框
@@ -2609,6 +2778,19 @@ export default {
           { required: true, message: "请输入整备质量", trigger: "blur" }
         ],
         name: [{ required: true, message: "请填写姓名", trigger: "blur" }],
+        // jqpolicyno: [{ required: true, message: "请填写交强保单号", trigger: "blur" }],
+        // sypolicyno: [{ required: true, message: "请填写商业保单号", trigger: "blur" }],
+        // jypolicyno: [{ required: true, message: "请填写驾意保单号", trigger: "blur" }],
+        // jqpremium: [{ required: true, message: "请填写交强险费用", trigger: "blur" }],
+        // sypremium: [{ required: true, message: "请填写商业险费用", trigger: "blur" }],
+        // jypremium: [{ required: true, message: "请填写驾意险费用", trigger: "blur" }],
+        // taxamount: [{ required: true, message: "请填写车船税", trigger: "blur" }],
+        // jqSuperviseCostsProportion: [{ required: true, message: "请填写交强险手续费比例", trigger: "blur" }],
+        // sySuperviseCostsProportion: [{ required: true, message: "请填写商业险手续费比例", trigger: "blur" }],
+        // noSuperviseCostsProportion: [{ required: true, message: "请填写非车手续费比例", trigger: "blur" }],
+        // jqOtherCostsProportion: [{ required: true, message: "请填写交强险其他费用比例", trigger: "blur" }],
+        // syOtherCostsProportion: [{ required: true, message: "请填写商业险其他费用比例", trigger: "blur" }],
+        // noOtherCostsProportion: [{ required: true, message: "请填写非车其他费用比例", trigger: "blur" }],
 
         // identifyNumber: [
         //   { required: true, message: "请填写证件号", trigger: "blur" },
@@ -3468,7 +3650,13 @@ export default {
       outOfBusinessVehicleUseoptions: [],
       insOrderStatusoptions: [],
       lastCompanyId: "",
-      apiInterfaceName: 'generateOrder'
+      apiInterfaceName: 'generateOrder',
+      isLetter3Arr:[],
+      isLetter3agreementId:'',
+      fileListnoPolicy:[],
+      fileListnoPolicy:[],
+      fileListjqSign:[],
+      fileListjqPolicy:[],
     };
   },
   watch: {
@@ -3559,8 +3747,8 @@ export default {
       default: true
     },
     isLetter: {
-      type: Boolean,
-      default: true
+      type: String,
+      default: '1'
     },
   },
   components: {
@@ -3571,7 +3759,7 @@ export default {
       import("element-ui/packages/image/src/image-viewer")
   },
   created() {
-    if (!this.isLetter) {
+    if (this.isLetter=='2') {
       this.apiInterfaceName = 'ordergenerateOrder'
     }
     // this.commpanyList(); //获取保险公司
@@ -4351,13 +4539,14 @@ export default {
     },
     async obtainProtocol(data) {
       let res = {}
-      if (this.isLetter) {
+      if (this.isLetter=='1') {
         res = await this.$api.letter.getAllAgreement()
       }
-      else {
-        // res = await this.$api.letter.getAllAgreementByUserId({ userId: this.userId })
+      if (this.isLetter=='2') {
+        res = await this.$api.letter.getAllAgreementByUserId({ userId: this.userId })
+      }
+      if (this.isLetter=='3') {
         res = await this.$api.letter.getExternalAgreement()
-        
       }
       if (res.code == 200) {
         res.data.map(ele => {
@@ -4440,6 +4629,10 @@ export default {
     //选择协议  val:协议id  row:协议列表  index:下标  item:保险公司数据集合
     agreementChange(val, row, index, item) {
       this.kindListFun()
+      if(this.isLetter=='3'){
+          this.isLetter3agreementId=''
+          this.isLetter3agreementId=item.agreementId
+      }
       let obj = {};
       obj = row.find(item => {
         return item;
@@ -4718,9 +4911,32 @@ export default {
     hideInput() {
       this.currentCell = null;
     },
+    updateArray(arr, value, condition) {
+      if (condition) {
+        arr.push(value);
+      } else {
+        const index = arr.indexOf(value);
+        if (index !== -1) {
+          arr.splice(index, 1);
+        }
+      }
+      if(arr.length==0){
+        this.totalCompanyList.forEach(e=>{
+          e.disabled=false
+        })
+      }
+      else{
+        this.totalCompanyList.forEach(e=>{
+          e.disabled= e.id==arr[0]?false:true
+        })
+      }
 
+    },
     //勾选保险公司
     initchange(e, code, name, index) {
+      if(this.isLetter=='3'){
+        this.updateArray(this.isLetter3Arr,code,e)
+      }
       if (e) {
         this.kindListFun()
         let ins = this.totalCompanyList[index].namesimple;
@@ -5074,6 +5290,275 @@ export default {
         this.syendDate = "";
       }
     },
+    // 保存
+    preserveQuote(){
+      let starttime = new Date(this.carInfo.registerDate);
+      let endtime = new Date(this.carInfo.issueDate);
+      if (endtime < starttime) {
+        this.$message({ message: "发证日期早于初登日期", type: "error" });
+        return;
+      }
+      this.$refs["carInfo"].validate(valid => {
+        if (valid) {
+          var _this = this;
+          _this.$refs["ownerInfo"].validate(valid1 => {
+            if (valid1) {
+            //   _this.$refs["policyNumberForm"].validate(valid2 => {
+            // if (valid2) {
+              if (_this.tbczcarShow == true) {
+                _this.policyHolderInfo = JSON.parse(
+                  JSON.stringify(_this.ownerInfo)
+                );
+              }
+              if (_this.bbczcarShow == true) {
+                _this.insuredPersonInfo = JSON.parse(
+                  JSON.stringify(_this.ownerInfo)
+                );
+              }
+              if (_this.bbtbcarShow == true) {
+                _this.insuredPersonInfo = JSON.parse(
+                  JSON.stringify(_this.policyHolderInfo)
+                );
+              }
+              _this.carInfo.vinNo = _this.carInfo.frameNo;
+              _this.riskList = []; //险种大类
+              _this.kindList = []; //商业险险别
+              if (
+                (!_this.jqstartDate || !_this.jqendDate) &&
+                (!_this.systartDate || !_this.syendDate)
+              ) {
+                this.$message({ message: "投保日期不能为空", type: "warning" });
+              } else {
+                this.calculateLoading = true;
+                setInterval(() => {
+                  this.calculateLoading = false;
+                }, 3000);
+                if (_this.jqchecked) {
+                  //交强
+                  _this.jqstartDate = this.transformTime(_this.jqstartDate);
+                  _this.jqendDate = this.transformTime(_this.jqendDate);
+                  _this.riskList.push({
+                    amount: "200000",
+                    premium: "0",
+                    riskCode: "0507",
+                    endDate: _this.jqendDate,
+                    startDate: _this.jqstartDate,
+                    instantFlag: "0"
+                  });
+                }
+                if (_this.sychecked) {
+                  _this.systartDate = this.transformTime(_this.systartDate);
+                  _this.syendDate = this.transformTime(_this.syendDate);
+                  //商业
+                  _this.riskList.push({
+                    premium: "0",
+                    riskCode: "0510",
+                    quotePreceptCode: "",
+                    quotePreceptName: "",
+                    endDate: _this.syendDate,
+                    startDate: _this.systartDate,
+                    instantFlag: "0"
+                  });
+                  _this.insureList.map((ele, index) => {
+                    if (
+                      ele.amount != "0" &&
+                      (ele.kindCode == "D4" || ele.kindCode == "SY_FJ_YBW2")
+                    ) {
+                      _this.kindList.push({
+                        unitAmount: _this.insureList[index].amount,
+                        kindCode: _this.insureList[index].kindCode,
+                        kindName: _this.insureList[index].kindName
+                      });
+                    } else if (
+                      ele.amount != "0" &&
+                      (ele.kindCode == "MJ1" ||
+                        ele.kindCode == "MJ2" ||
+                        ele.kindCode == "MJ3" ||
+                        ele.kindCode == "MJ4")
+                    ) {
+                      _this.kindList.push({
+                        deductibleRate: _this.insureList[index].amount,
+                        kindCode: _this.insureList[index].kindCode,
+                        kindName: _this.insureList[index].kindName
+                      });
+                    } else if (
+                      ele.amount != "0" &&
+                      (ele.kindCode == "TY1" ||
+                        ele.kindCode == "TY2" ||
+                        ele.kindCode == "TY3" ||
+                        ele.kindCode == "TY4")
+                    ) {
+                      _this.kindList.push({
+                        serviceTimes: _this.insureList[index].amount,
+                        kindCode: _this.insureList[index].kindCode,
+                        kindName: _this.insureList[index].kindName
+                      });
+                    } else if (ele.amount != "0") {
+                      _this.kindList.push({
+                        amount: _this.insureList[index].amount,
+                        kindCode: _this.insureList[index].kindCode,
+                        kindName: _this.insureList[index].kindName
+                      });
+                    }
+                    return ele;
+                  });
+                } else {
+                  _this.kindList = [];
+                }
+                this.preserveOrderStageProcessing();
+              }
+            //  }
+            //  else {
+            //   document.getElementById("Waibu").scrollIntoView();
+            //   _this.$message({ message: "请检查外部订单信息", type: "warning" });
+            // }
+            // })
+            } else {
+              document.getElementById("CheZhu").scrollIntoView();
+              _this.$message({ message: "请检查人员信息", type: "warning" });
+            }
+          });
+        } else {
+          document.getElementById("Car").scrollIntoView();
+          this.$message({ message: "请检查车辆信息", type: "warning" });
+          return false;
+        }
+      });
+    },
+       //订单生成后保存接口
+       preserveOrderStageProcessing() {
+        this.preserveQuoteLoading=true
+      if (this.tbczcarShow && this.imageList2.length > 0) {
+        //投保人同车主
+        this.imageList3 = JSON.parse(JSON.stringify(this.imageList2));
+        if (this.imageList3.length == 1) {
+          this.imageList3[0].imageType = this.imageList3[0].imageType.includes('C0') ? "C03" : 'D03'
+        }
+        else {
+          this.imageList3.forEach(e => {
+            e.imageType = e.imageType.includes('C0') ? "C03" : 'D03'
+          })
+        }
+      }
+      if (this.bbczcarShow && this.imageList2.length > 0) {
+        //被保人同车主
+        this.imageList4 = JSON.parse(JSON.stringify(this.imageList2));
+        if (this.imageList4.length == 1) {
+          this.imageList4[0].imageType = this.imageList4[0].imageType.includes('C0') ? "C04" : 'D04'
+        }
+        else {
+          this.imageList4.forEach(e => {
+            e.imageType = e.imageType.includes('C0') ? "C04" : 'D04'
+          })
+        }
+       
+      }
+      if (this.bbtbcarShow && this.imageList3.length > 0) {
+        //被保人同投保人
+        this.imageList4 = JSON.parse(JSON.stringify(this.imageList3));
+        if (this.imageList4.length == 1) {
+          this.imageList4[0].imageType = this.imageList4[0].imageType.includes('C0') ? "C04" : 'D04'
+        }
+        else {
+          this.imageList4.forEach(e => {
+            e.imageType = e.imageType.includes('C0') ? "C04" : 'D04'
+          })
+        }
+      }
+
+      //日期长度<10处理
+      const formatDate = date => {
+        if (date.length < 10) {
+          return this.timeformat(date);
+        }
+        return date;
+      };
+      if (this.carInfo.registerDate.length < 10) {
+        this.carInfo.registerDate = formatDate(this.carInfo.registerDate);
+      }
+      if (this.carInfo.issueDate.length < 10) {
+        this.carInfo.issueDate = formatDate(this.carInfo.issueDate);
+      }
+      if (
+        this.carInfo.transferDate &&
+        this.carInfo.transferDate.length < 10 &&
+        this.carInfo.transferDate !== ""
+      ) {
+        this.carInfo.transferDate = formatDate(this.carInfo.transferDate);
+      }
+      //日期长度<10处理
+      //提交身份证/驾驶证  ——————————————————
+      this.policyHolderInfo.owner = this.tbczcarShow;
+      this.insuredPersonInfo.owner = this.bbczcarShow;
+      this.insuredPersonInfo.insuranceHolder = this.bbtbcarShow;
+      if (typeof this.ownerInfo.provinceData == "string") {
+        this.ownerInfo.provinceData = [];
+      }
+      if (typeof this.insuredPersonInfo.provinceData == "string") {
+        this.insuredPersonInfo.provinceData = [];
+      }
+      if (typeof this.policyHolderInfo.provinceData == "string") {
+        this.policyHolderInfo.provinceData = [];
+      }
+      let param = {
+        userId: this.userId,
+        quoteno: this.quoteno,
+        orderNo: this.orderno,
+        carInfo: this.carInfo,
+        insuredPersonInfo: this.insuredPersonInfo,
+        ownerInfo: this.ownerInfo,
+        policyHolderInfo: this.policyHolderInfo,
+        kindList: this.kindList,
+        riskList: this.riskList,
+        isExternal:'1',
+        vehicleAndVesselTax: this.vehicleAndVesselTaxForm
+      };
+      this.$api.letter.generateOrder(param).then(res => {
+        if (res.code == "200") {
+           //上传图片
+           const mergedArray = [
+            ...this.imageList1,
+            ...this.imageList2,
+            ...this.imageList3,
+            ...this.imageList4,
+            ...this.imageList5
+          ];
+          if (mergedArray.length > 0) {
+            let imageparam = {
+              imageList: mergedArray,
+              quoteNo: res.data.quoteno
+            };
+            this.$api.letter.uploadImages(imageparam).then(responses => {
+              this.imageEcho(res.data.quoteno); // 获取图片
+            });
+          }
+        
+          let params = {
+            orderNo: res.data.orderno,
+            ...this.policyNumberForm,
+            agreementId: this.isLetter3agreementId
+          };
+          this.$api.letter.saveSubOrder(params).then(res => {
+            if(res.code == "200"){
+              this.preserveQuoteLoading=false
+              this.$message({
+                message: res.msg,
+                type: 'success'
+              });
+            }else {
+          this.preserveQuoteLoading=false
+          this.$message.error( res.msg);
+        }
+          })
+        } else {
+          this.preserveQuoteLoading=false
+          this.$message.error( res.msg);
+
+        }
+      });
+      document.getElementById("company").scrollIntoView();
+      this.imageUploadShow = true;
+    },
     //报价
     quote() {
       let starttime = new Date(this.carInfo.registerDate);
@@ -6439,6 +6924,9 @@ export default {
     imageUpload() {
       this.imageUploaddialogVisible = true;
     },
+    policyUpload() {
+      this.policyUploaddialogVisible = true;
+    },
     cancelorder(item) {
       this.$api.letter.zijincancelorder({ companyId: item.id }).then(res => {
         if (res.code == 200) {
@@ -7517,6 +8005,21 @@ export default {
         }
       });
     },
+    policydrivingupload(file,val){
+      this['fileList'+val]=[]
+      this.$refs.jqPolicyupload.clearFiles()
+      var file = file.raw;
+      const params = new FormData(); // 声明formData数据类型
+      params.append("multipartFile", file);
+      params.append("type", "file");
+      this.$api.letter.uploadFile(params).then(res => {
+        if (res.code == "200") {
+          res.data.name= res.data.fileName
+          this['fileList'+val].push(res.data)
+          this.policyNumberForm[val]=res.data.url
+        }
+      });
+    },
     handleRemove1(file, imageIdList, imgList) {
       this[imageIdList].map((ele, index) => {
         if (file.imageId === ele.imageId) {
@@ -7961,11 +8464,7 @@ export default {
         default:
       }
     },
-    //预览图片
-    handlePictureCardPreview(img) {
-      this.ProViewImg = img;
-      this.showViewer = true;
-    },
+   
     // 关闭查看器
     closeViewer() {
       this.showViewer = false;
@@ -8276,7 +8775,7 @@ export default {
     },
     add() {
       this.obtainProtocol();
-      if (this.isLetter) {
+      if (this.isLetter=='1') {
         this.$router.push({ path: "/letter/letter" });
       }
       for (let key in this.ownerInfo) {
@@ -8850,7 +9349,8 @@ export default {
   /* W3C, IE 10+/ Edge, Firefox 16+, Chrome 26+, Opera 12+, Safari 7+ */
 }
 
-.aaa /deep/ {
+.aaa{
+  /deep/ {
   margin-bottom: 20px;
   margin-right: 50px;
 
@@ -8874,7 +9374,24 @@ export default {
   .el-upload-list__item:first-child {
     margin-top: 0;
   }
+  .el-upload--picture-card {
+    width: 180px;
+    height: 120px;
+  }
+
+  .el-upload-list__item {
+    width: 180px;
+    height: 120px;
+    margin: 0 !important;
+    display: block !important;
+  }
+
+  .el-upload-list--picture-card .el-upload-list__item-thumbnail {
+    width: 180px;
+    height: 120px;
+  }
 }
+} 
 
 .jyxStyle>span {
   display: inline-block;
@@ -8954,22 +9471,7 @@ export default {
     border: 1px dashed #ced4da;
   }
 
-  .el-upload--picture-card {
-    width: 180px;
-    height: 120px;
-  }
-
-  .el-upload-list__item {
-    width: 180px;
-    height: 120px;
-    margin: 0 !important;
-    display: block !important;
-  }
-
-  .el-upload-list--picture-card .el-upload-list__item-thumbnail {
-    width: 180px;
-    height: 120px;
-  }
+ 
 
   // .el-button--warning {
   //   color: #fff;

+ 42 - 0
src/views/Task/daikeComponents/KtOrder.vue

@@ -1284,6 +1284,45 @@ export default {
           let businessList = [];
           let accidentList = [];
           if (res.data.orderstatus == "3") {
+            if(res.data.isExternal==1){
+              this.$api.letter
+              .getPolicyPrintexternalOrder(res.data.id).then(res1=>{
+                if(res1.code==200){
+                  if (res1.data.jqPolicy) {
+                      this.oldfileList.push({
+                        fileTitle: "交强电子保单",
+                        filename: this.orderInfo.jqpolicyno,
+                        fileurl: res1.data.jqPolicy
+                      });
+                    }
+                    if (res1.data.jqSign) {
+                      this.oldfileList.push({
+                        fileTitle: "交强电子标志",
+                        filename: this.orderInfo.jqpolicyno,
+                        fileurl: res1.data.jqSign
+                      });
+                      }
+                    if (res1.data.jqSign) {
+                      accidentList.push({
+                        fileTitle: "商业电子保单",
+                        filename: this.orderInfo.sypolicyno,
+                        fileurl: res1.data.jqSign
+                      });
+                    }
+                    if (res1.data.noPolicy) {
+                      accidentList.push({
+                        fileTitle: "驾意险保单",
+                        filename: "驾意险保单",
+                        fileurl: res1.data.noPolicy
+                      });
+                    }
+                  }
+                else{
+                  this.$message.error(res1.msg)
+                }
+              })
+            }
+            else{
             switch (res.data.inscompany) {
               case "永安财险":
                 if (this.orderInfo.jqpolicyno) {
@@ -1941,11 +1980,14 @@ export default {
                 break;
               default:
             }
+          }
+
             let obj = {
               oldfileList: this.oldfileList,
               businessList,
               accidentList
             };
+
             this.$refs.detailsDialog.warrantyFun(obj);
           }
 

+ 63 - 0
src/views/Task/mixin.js

@@ -134,6 +134,19 @@ export const mixin = { // 导出混入对象
         { prop: "product", label: "投保险种", minWidth: 100 },
         { prop: "createtime", label: "录单日期", minWidth: 160},
       ],
+      columns1: [
+        { prop: "subOrderId", label: "订单号", minWidth: 180 },
+        { prop: "userid", label: "业务员", minWidth: 160, formatter: this.useridFormatter },
+        { prop: "managementSource", label: "机构来源", minWidth: 160, formatter: this.managementSourceFormatter },
+        { prop: "insCompany", label: "保险公司", minWidth: 120 },
+        { prop: "partnerCompaniesName", label: "合作公司", minWidth: 120 },
+        { prop: "agreementName", label: "协议", minWidth: 160 },
+        { prop: "licenseno", label: "车牌号", minWidth: 160 },
+        { prop: "isExternal", label: "外部订单", formatter: this.isExternalFormatter},
+        { prop: "insuredname", label: "投保人姓名", minWidth: 120 },
+        { prop: "product", label: "投保险种", minWidth: 100 },
+        { prop: "createtime", label: "录单日期", minWidth: 160},
+      ],
       statusoptions: "",
       dialogVisible: false,
       companyList: [], //保险公司
@@ -451,6 +464,45 @@ export const mixin = { // 导出混入对象
         this.oldfileList = [];
         let businessList = []
         let accidentList = []
+        if(this.orderInfo.isExternal==1){
+          this.$api.letter
+          .getPolicyPrintexternalOrder(this.orderInfo.id).then(res1=>{
+            if(res1.code==200){
+              if (res1.data.jqPolicy) {
+                  this.oldfileList.push({
+                    fileTitle: "交强电子保单",
+                    filename: this.orderInfo.jqpolicyno,
+                    fileurl: res1.data.jqPolicy
+                  });
+                }
+                if (res1.data.jqSign) {
+                  this.oldfileList.push({
+                    fileTitle: "交强电子标志",
+                    filename: this.orderInfo.jqpolicyno,
+                    fileurl: res1.data.jqSign
+                  });
+                  }
+                if (res1.data.jqSign) {
+                  accidentList.push({
+                    fileTitle: "商业电子保单",
+                    filename: this.orderInfo.sypolicyno,
+                    fileurl: res1.data.jqSign
+                  });
+                }
+                if (res1.data.noPolicy) {
+                  accidentList.push({
+                    fileTitle: "驾意险保单",
+                    filename: "驾意险保单",
+                    fileurl: res1.data.noPolicy
+                  });
+                }
+              }
+            else{
+              this.$message.error(res1.msg)
+            }
+          })
+        }
+        else{
         switch (this.orderInfo.inscompany) {
           case "永安财险":
             if (this.orderInfo.jqpolicyno) {
@@ -1058,6 +1110,7 @@ export const mixin = { // 导出混入对象
             break;
           default:
         }
+      }
         let obj = {
           oldfileList: this.oldfileList,
           businessList,
@@ -1153,6 +1206,16 @@ export const mixin = { // 导出混入对象
         default:
       }
     },
+    isExternalFormatter(row, column) {
+      let isExternal = row.isExternal;
+      switch (isExternal) {
+        case 1:
+          return  '是'
+        case 0:
+          return  '否'
+        default:
+      }
+    },
     trajectory(row){
       this.$api.letter.queryBySuborder(row.subOrderId).then((res) => {
         if (res.code == 200 && res.data.length > 0) {