@dongkboy 3 лет назад
Родитель
Сommit
00c25d0af9

+ 46 - 16
src/http/moudules/insCompany.js

@@ -44,9 +44,9 @@ export const editCompany = (data) => {
         data
     })
 }
-export const  deleteEsmCompany = (id) => {
+export const deleteEsmCompany = (id) => {
     return axios({
-        url: '/esmInsCompany/'+id,
+        url: '/esmInsCompany/' + id,
         method: 'delete',
     })
 }
@@ -62,44 +62,74 @@ export const companyTree = (parentid) => {
 // 删除保险公司
 export const deleteCompany = (data) => {
     return axios({
-        url: '/esmInsCompany/deleteInsCompany?idList='+data,
+        url: '/esmInsCompany/deleteInsCompany?idList=' + data,
         method: 'post'
     })
 }
 // 获取保险公司渠道模板
 export const gainAttributionTemplate = (id) => {
     return axios({
-        url: '/esm/attribution/gainAttributionTemplate/'+id,
+        url: '/esm/attribution/gainAttributionTemplate/' + id,
         method: 'get'
     })
 }
 //保险公司归属信息分页查询
-export const attribution=(pageNum,pageSize)=>{
+export const attribution = (pageNum, pageSize) => {
     return axios({
-        url:"/esm/attribution/findPage?pageNum="+pageNum+'&pageSize='+pageSize,
-        method:"get",
+        url: "/esm/attribution/findPage?pageNum=" + pageNum + '&pageSize=' + pageSize,
+        method: "get",
     })
 }
 //获取保险公司归属信息模板
-export const attributionTemplate=(insCompanyId)=>{
+export const attributionTemplate = (insCompanyId) => {
     return axios({
-        url:"/esm/attribution/gainAttributionTemplate/"+insCompanyId,
-        method:"get",
+        url: "/esm/attribution/gainAttributionTemplate/" + insCompanyId,
+        method: "get",
     })
 }
 //保存归属信息
-export const attributionsave=(data)=>{
+export const attributionsave = (data) => {
     return axios({
-        url:"/esm/attribution/save",
-        method:"post",
+        url: "/esm/attribution/save",
+        method: "post",
         data
     })
 }
 //归属授权
-export const authorize=(data)=>{
+export const authorize = (data) => {
     return axios({
-        url:'/esm/attribution/authorize',
-        method:"post",
+        url: '/esm/attribution/authorize',
+        method: "post",
         data
     })
+}
+//续保分页查询
+export const queryrenewal = (pageNum, pageSize) => {
+    return axios({
+        url: '/order/renewal?pageNum=' + pageNum + '&pageSize=' + pageSize,
+        method: "get",
+    })
+}
+//续保新增
+export const addrenewal = (data) => {
+    return axios({
+        url: '/order/renewal',
+        method: "post",
+        data
+    })
+}
+//续保修改
+export const qudaterenewal = (id, data) => {
+    return axios({
+        url: '/order/renewal/' + id,
+        method: "put",
+        data
+    })
+}
+//续保删除
+export const deleterenewal = (id) => {
+    return axios({
+        url: '/order/renewal/' + id,
+        method: "delete",
+    })
 }

+ 34 - 34
src/http/moudules/letter.js

@@ -34,7 +34,7 @@ export const ModelsQuery = (data) => {
     })
 }
 //生成订单
-export const generateOrder=(data)=>{
+export const generateOrder = (data) => {
     return axios({
         url: '/insurance/order/generateOrder',
         method: 'post',
@@ -42,7 +42,7 @@ export const generateOrder=(data)=>{
     })
 }
 //查询子订单
-export const getByCompanyId=(data)=>{
+export const getByCompanyId = (data) => {
     return axios({
         url: '/insurance/order/getByCompanyId',
         method: 'post',
@@ -109,9 +109,9 @@ export const queryOrder = (data) => {
 
 
 //获取影像
-export const insTaskImagefindById = (type,quoteno) => {
+export const insTaskImagefindById = (type, quoteno) => {
     return axios({
-        url: "/ins/taskImage/findById?imgtype="+type+'&taskid='+quoteno,
+        url: "/ins/taskImage/findById?imgtype=" + type + '&taskid=' + quoteno,
         method: "get",
     })
 }
@@ -196,10 +196,10 @@ export const hengbangaudit = (data) => {
     })
 }
 //查询报价历史
-export const queryQuoteHistory=(data)=>{
+export const queryQuoteHistory = (data) => {
     return axios({
-        url:"/insurance/order/queryQuoteHistory",
-        method:"post",
+        url: "/insurance/order/queryQuoteHistory",
+        method: "post",
         data
     })
 }
@@ -262,7 +262,7 @@ export const yongchenggetPolicyPrint = (data) => {
 //恒邦电子保单
 export const hengbanggetPolicyPrint = (data) => {
     return axios({
-        url: "/ins/hengbang/getPolicyPrint",
+        url: "/order/hengBang/getPolicyPrint",
         method: "post",
         data
     })
@@ -275,32 +275,32 @@ export const getquote = () => {
     })
 }
 //订单列表
-export const queryOrders=(data)=>{
+export const queryOrders = (data) => {
     return axios({
-        url:"/insurance/order/queryOrders",
-        method:"post",
+        url: "/insurance/order/queryOrders",
+        method: "post",
         data
     })
 }
 //订单查询
-export const getByOrderNo=(data)=>{
+export const getByOrderNo = (data) => {
     return axios({
-        url:"/insurance/order/revise",
-        method:"post",
+        url: "/insurance/order/revise",
+        method: "post",
         data
 
     })
 }
 //驾意险
-export const getAccidentalDriving=(data)=>{
+export const getAccidentalDriving = (data) => {
     return axios({
-        url:"/insurance/order/getAccidentalDriving",
-        method:"post",
+        url: "/insurance/order/getAccidentalDriving",
+        method: "post",
         data
     })
 }
 //意外险列表
-export const gainAccidentList= (data) => {
+export const gainAccidentList = (data) => {
     return axios({
         url: "/api/yongCheng/gainAccidentList",
         method: "post",
@@ -309,7 +309,7 @@ export const gainAccidentList= (data) => {
 }
 // 意外险列表-方案
 
-export const gainAccidentSchemeList= (data) => {
+export const gainAccidentSchemeList = (data) => {
     return axios({
         url: "/api/yongCheng/gainAccidentSchemeList",
         method: "post",
@@ -317,10 +317,10 @@ export const gainAccidentSchemeList= (data) => {
     })
 }
 //获取允许报价的保险公司列表
-export const gainAllowQuoteList=()=>{
+export const gainAllowQuoteList = () => {
     return axios({
-        url:"/esmInsCompany/gainAllowQuoteList",
-        method:"get",
+        url: "/esmInsCompany/gainAllowQuoteList",
+        method: "get",
     })
 }
 //保存影像
@@ -332,32 +332,32 @@ export const uploadImages = (data) => {
     })
 }
 // 文件上传
-export  const uploadFile=(data)=>{
+export const uploadFile = (data) => {
     return axios({
-        url:"/ins/taskImage/uploadFile",
-        method:"post",
+        url: "/ins/taskImage/uploadFile",
+        method: "post",
         data
     })
 }
 //根据报价号查询图像
-export  const findByQuoteNo=(data)=>{
+export const findByQuoteNo = (data) => {
     return axios({
-        url:"/ins/taskImage/findByQuoteNo?quoteNo="+data,
-        method:"get",
+        url: "/ins/taskImage/findByQuoteNo?quoteNo=" + data,
+        method: "get",
     })
 }
 //续保查询
-export  const queryRenewal=(data)=>{
+export const queryRenewal = (data) => {
     return axios({
-        url:"/order/renewal/queryRenewal",
-        method:"post",
+        url: "/order/renewal/queryRenewal",
+        method: "post",
         data
     })
 }
 //查询保险公司
-export  const queryCompany=()=>{
+export const queryCompany = () => {
     return axios({
-        url:"/order/renewal/queryCompany",
-        method:"get",
+        url: "/order/renewal/queryCompany",
+        method: "get",
     })
 }

Разница между файлами не показана из-за своего большого размера
+ 166 - 568
src/views/Letter/Letter.vue


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

@@ -1448,7 +1448,7 @@ export default {
                                             fileurl: res.data.jqx_flag_url,
                                         });
                                     }
-                                    if(res.data.syx_policy_url){
+                                    if (res.data.syx_policy_url) {
                                         this.oldfileList.push({
                                             fileTitle: "商业电子保单",
                                             filename: this.orderInfo.sypolicyno,

+ 137 - 79
src/views/Sys/Continuousconfiguration.vue

@@ -33,11 +33,16 @@
         <el-table size="small" :data="pageResult" height="690" border style="width: 100%" v-loading="loading"
             highlight-current-row stripe
             :header-cell-style="{ background: '#F2F7FC', fontWeight: '700', color: '#606266' }">
-            <el-table-column prop="id" label="ID" width="300" align="center"></el-table-column>
-            <el-table-column prop="insCompanyId" label="保险公司" width="100" align="center"></el-table-column>
-            <el-table-column prop="username" label="账号" align="center" width="150"></el-table-column>
-            <el-table-column prop="password" label="密码" align="center" width="200"></el-table-column>
-            <el-table-column prop="userId" label="操作人" align="center" width="200"></el-table-column>
+            <el-table-column prop="companyId" label="ID" width="300" align="center"></el-table-column>
+            <el-table-column prop="namesimple" label="保险公司" width="100" align="center"></el-table-column>
+            <el-table-column prop="url" label="地址" align="center" width="150"></el-table-column>
+            <el-table-column prop="isOpen" label="状态" align="center" width="200">
+                <template slot-scope="scope">
+                    <el-tag v-if="(scope.row.isOpen == '1')">开启</el-tag>
+                    <el-tag v-if="(scope.row.isOpen == '0')">关闭</el-tag>
+                </template>
+            </el-table-column>
+            <el-table-column prop="configure" label="配置参数" align="center" width="200"></el-table-column>
             <el-table-column label="操作" align="center" min-width="300" fixed="right">
                 <template slot-scope="scope">
                     <el-button size="mini" type="text" @click="CloseEdit(scope.$index, scope.row)">编辑</el-button>
@@ -51,43 +56,69 @@
                 :current-page="pageNum" :page-size="pageSize" :page-sizes="[10, 20, 50, 100]"
                 layout="total, sizes, prev, pager, next, jumper" :total="totalSize"></el-pagination>
         </div>
-        <el-dialog title="渠道信息新增" :visible.sync="dialogVisible" width="70vw">
-            <el-form class="demo-ruleForm" :inline="true" :model="attributionform" ref="attributionform" label-width="130px"
-                size="small" style="margin-top:30px;">
+        <el-dialog title="续保配置新增" :visible.sync="dialogVisible" width="1000px">
+            <el-form class="demo-ruleForm" :model="attributionform" ref="attributionform" label-width="130px" size="small"
+                style="margin-top:30px;">
                 <el-row>
-                    <el-col :xs="24" :sm="24" :md="12" :lg="8" :xl="8" :span="8">
+                    <el-col :span="10">
                         <el-form-item label="保险公司:">
-                            <el-select class="widths1" v-model="attributionform.insCompanyId" @change="companyChange">
+                            <el-select class="widths1" v-model="attributionform.companyId" @change="companyChange">
                                 <el-option v-for="(item, index) in companyselect" :key="index.id" :label="item.namesimple"
                                     :value="item.id"></el-option>
                             </el-select>
                         </el-form-item>
                     </el-col>
-                    <el-col :xs="24" :sm="24" :md="12" :lg="8" :xl="8" :span="8">
-                        <el-form-item prop="username" label="用户名:" :rules="[
-                            { required: true, message: '请输入用户名', trigger: 'blur' },
-                        ]">
-                            <el-input v-model="attributionform.username" class="widths1"></el-input>
+                    <el-col :span="10">
+                        <el-form-item label="保险公司简称:">
+                            <el-input v-model="attributionform.namesimple" class="widths1" placeholder="填写公司简称"></el-input>
                         </el-form-item>
                     </el-col>
-                    <el-col :xs="24" :sm="24" :md="12" :lg="8" :xl="8" :span="8">
-                        <el-form-item prop="password" label="密码:" :rules="[
-                            { required: true, message: '请输入密码', trigger: 'blur' },
-                        ]">
-                            <el-input v-model="attributionform.password" class="widths1"></el-input>
+                    <el-col :span="10">
+                        <el-form-item label="续保请求url:">
+                            <el-input v-model="attributionform.url" style="width: 100%;" placeholder="填写续保链接"></el-input>
                         </el-form-item>
                     </el-col>
-                    <el-col :xs="24" :sm="24" :md="12" :lg="8" :xl="8" :span="8"
-                        v-for="(domain, index) in  attributionform.fields" :key="domain.index">
-                        <el-form-item :label="domain.label + ':'" :prop="'fields.' + index + '.value'" :rules="{
-                            required: true, message: domain.label + '不能为空', trigger: 'blur'
-                        }">
-                            <el-input class="widths1" v-model="domain.value" :type="domain.type"></el-input>
+                    <el-col :span="10">
+                        <el-form-item label="是否开启:">
+                            <el-switch v-model="switchvalue" @change="isOpenchange" class="widths1"></el-switch>
                         </el-form-item>
                     </el-col>
+                    <el-col :span="24">
+                        <div>
+                            <h4>配置参数</h4>
+                        </div>
+                    </el-col>
+                    <el-col v-for="(configureitem, configureindex) in attributionform.configure" :key="configureindex">
+                        <el-col :span="10">
+                            <el-form-item label="字段名:">
+                                <el-input v-model="configureitem.field" class="widths1" placeholder="请输入字段名"></el-input>
+                            </el-form-item>
+                            <el-form-item label="标签:">
+                                <el-input v-model="configureitem.label" class="widths1" placeholder="标签名"></el-input>
+                            </el-form-item>
+                        </el-col>
+                        <el-col :span="10">
+                            <el-form-item label="表单类型:">
+                                <!-- <el-input v-model="configureitem.type" class="widths1" placeholder="表单类型"></el-input> -->
+                                <el-radio-group v-model="configureitem.type">
+                                    <el-radio label="input"></el-radio>
+                                    <el-radio label="select"></el-radio>
+                                </el-radio-group>
+                            </el-form-item>
+                            <el-form-item label="是否可修改:">
+                                <el-switch v-model="updatevalue" @change="(event) => isEditchange(event, configureindex)"
+                                    class="widths1"></el-switch>
+                            </el-form-item>
+                        </el-col>
+                        <el-col :span="4" v-show="configureindex != 0">
+                            <el-button @click.prevent="removeDomain(configureitem)" size="small">删除</el-button>
+                        </el-col>
+
+                    </el-col>
                 </el-row>
             </el-form>
             <span slot="footer" class="dialog-footer">
+                <el-button size="small" @click="configuration">新增配置</el-button>
                 <el-button size="small" @click="dialogVisible = false">取 消</el-button>
                 <el-button size="small" type="primary" @click="submitForm('attributionform')">提 交</el-button>
             </span>
@@ -111,6 +142,8 @@
 export default {
     data() {
         return {
+            switchvalue: false,//开启开关
+            updatevalue: false,//修改开关
             filterText: '',
             treedata: [],//树形数据
             defaultProps: {
@@ -131,11 +164,17 @@ export default {
                 monthvalue: "",//日期
             },
             attributionform: {
-                fields: [],
-                insCompanyId: "",
-                password: "",
-                username: "",
-                id: "",
+                configure: [{
+                    field: "",
+                    isEdit: 0,
+                    label: "",
+                    type: "",
+                    value: "",
+                }],
+                insCompanyId: "",//保险公司id
+                isOpen: 0,//是/否开启
+                namesimple: "",//保险公司简称
+                url: "",//续保请求url
             },
             pageRequest: {
                 "pageNum": 1,
@@ -149,7 +188,7 @@ export default {
                 }
             },
             companyselect: [],
-            fieldslist: [],
+            configurelist: [],
             treeparams: {
                 deptIds: [],
                 attributionId: "",
@@ -158,18 +197,17 @@ export default {
         }
     },
     created() {
-        this.$api.insCompany.attribution(this.pageNum, this.pageSize).then((res) => {
-            this.pageResult = res.data.content;
-            this.pageSize=res.data.pageSize;
-            this.pageNum=res.data.pageNum;
-            this.totalSize=res.data.totalSize;
-        })
         this.$api.insCompany.findPage(this.pageRequest).then((res) => {
             this.companyselect = res.data.content;
         })
-        this.$api.dept.findDeptTree().then((res) => {
-            this.treedata = res.data;
+        this.$api.insCompany.queryrenewal(this.pageNum, this.pageSize).then((res) => {
+            console.log(res)
+            if (res.code == '200') {
+                this.pageResult = res.data.content;
+            }
         })
+
+
     },
     watch: {
         filterText(val) {
@@ -177,6 +215,40 @@ export default {
         }
     },
     methods: {
+        //删除事件
+        removeDomain(item) {
+            var index = this.attributionform.configure.indexOf(item)
+            if (index !== -1) {
+                this.attributionform.configure.splice(index, 1)
+            }
+        },
+        //新增配置按钮
+        configuration() {
+            this.attributionform.configure.push({
+                field: "",
+                isEdit: 0,
+                label: "",
+                type: "",
+                value: "",
+            })
+        },
+        //开启开关事件
+        isOpenchange(val) {
+            if (val) {
+                this.attributionform.isOpen = 1;
+            } else {
+                this.attributionform.isOpen = 0;
+            }
+        },
+        //修改开关事件
+        isEditchange(val, id) {
+            if (val) {
+                this.attributionform.configure[id].isEdit = 1;
+            } else {
+                this.attributionform.configure[id].isEdit = 0;
+            }
+
+        },
         //获取选中节点
         treechange(data, node) {
             var treelist = [];
@@ -193,59 +265,45 @@ export default {
         },
         //选择保险公司获取归属模板
         companyChange(e) {
-            this.$api.insCompany.attributionTemplate(e).then((res) => {
-                if (res.data) {
-                    this.fieldslist = JSON.parse(res.data.fields);
-                    this.fieldslist.map((ele, index) => {
-                        this.attributionform.fields.push({
-                            field: ele.field,
-                            isEdit: ele.isEdit,
-                            label: ele.label,
-                            type: ele.type,
-                            value: "",
-                        });
-                    })
-                } else {
-                    this.$message({ message: "暂无信息", type: "warning"});
-                }
-            })
+            console.log(e)
+            // this.$api.insCompany.attributionTemplate(e).then((res) => {
+            //     if (res.data) {
+            //         this.configurelist = JSON.parse(res.data.configure);
+            //         this.configurelist.map((ele, index) => {
+            //             this.attributionform.configure.push({
+            //                 field: ele.field,
+            //                 isEdit: ele.isEdit,
+            //                 label: ele.label,
+            //                 type: ele.type,
+            //                 value: "",
+            //             });
+            //         })
+            //     } else {
+            //         this.$message({ message: "暂无信息", type: "warning" });
+            //     }
+            // })
         },
         //提交授权
         treesubmit() {
             if (this.treeparams.deptIds.length > 0) {
                 this.$api.insCompany.authorize(this.treeparams).then((res) => {
-                    if(res.code=='200'){
+                    if (res.code == '200') {
                         this.$message({ message: "保存成功", type: "success" });
-                        this.empowerdialogVisible=false;
+                        this.empowerdialogVisible = false;
                     }
                 })
             } else {
-                this.$message({ message: "未选择归属机构", type: "warning" });
+                this.$message({ message: "未选择归属机构", type: "warning" }); attribution
             }
         },
         //提交表单
         submitForm(formName) {
             this.$refs[formName].validate((valid) => {
                 if (valid) {
-                    let params = {
-                        fields: JSON.stringify(this.attributionform.fields),
-                        id: this.attributionform.id,
-                        insCompanyId: this.attributionform.insCompanyId,
-                        password: this.attributionform.password,
-                        username: this.attributionform.username,
-                    }
-                    this.$api.insCompany.attributionsave(params).then((res) => {
-                        if (res.code == '200' && !res.msg) {
-                            this.$message({ message: '保存成功', type: "success" });
-                            this.dialogVisible = false;
-                        } else {
-                            this.$message({ message: res.msg, type: "warning" });
-                        }
-                    })
-                } else {
-                    this.$message({ message: "请检查信息", type: "warning" });
-                    return false;
+                    console.log(this.attributionform)
                 }
+
+
             });
         },
         //授权操作
@@ -256,9 +314,9 @@ export default {
         },
         //编辑操作 
         CloseEdit(index, row) {
-            let fileslist = JSON.parse(row.fields);
+            let fileslist = JSON.parse(row.configure);
             this.attributionform = {
-                fields: fileslist,
+                configure: fileslist,
                 id: row.id,
                 insCompanyId: row.insCompanyId,
                 password: row.password,

Некоторые файлы не были показаны из-за большого количества измененных файлов