瀏覽代碼

Merge branch 'master' of http://132.232.92.186:3000/XinXiBu/oa-system

yuanrf 1 年之前
父節點
當前提交
41e1cda03a

+ 1 - 1
src/components/Finance/Currency.vue

@@ -99,7 +99,7 @@
                             </div>
                         </div>
                     </el-tab-pane>
-                    <el-tab-pane label="团组增减款项" name="payments">
+                    <el-tab-pane label="其他款项" name="payments">
                         <div class="ipt-inif">
                             <div class="ipt" v-for="(item,index) in paymentsCurrencyArr" :key="index">
                                 <label>{{item.currencyName}}({{item.currencyCode}}):</label>

+ 0 - 11
src/components/Finance/GroupStatus.vue

@@ -98,17 +98,6 @@
                             type="primary"
                             size="mini"
                            >已完成</el-button>
-                          <!-- <el-button
-                            size="mini"
-                            title="删除"
-                            type="danger"
-                            @click="handleDelete(scope.$index, scope.row,groupDatas)"><i class="el-icon-delete"></i></el-button>
-                            <el-button v-if="scope.row.tourCode==''" size="mini" title="确认出团" type="primary" @click="confirmDeparture(scope.$index, scope.row)"><i class="el-icon-check"></i></el-button>
-                            <el-button
-                            v-if="scope.row.tourCode!=''"
-                            size="mini"
-                            title="已出团"
-                            ><i class="el-icon-check"></i></el-button> -->
                         </template>
                       </el-table-column>
                 </el-table>

+ 549 - 0
src/components/Finance/Sendack.vue

@@ -0,0 +1,549 @@
+<template>
+    <div>
+        <div class="sendack-all">
+            <div class="sendack-head">
+                <div class="sendack-head-li">
+                    <label>团组名称:</label>
+                    <el-select @change="changediid()" v-model="value" filterable placeholder="请选择">
+                        <el-option
+                        v-for="item in options"
+                        :key="item.id"
+                        :label="item.groupName"
+                        :value="item.id">
+                        </el-option>
+                    </el-select>
+                </div>
+                <div class="sendack-head-li">
+                    <el-button @click="dialogFormVisible=true;" type="primary">新增数据</el-button>
+                </div>
+            </div>
+            <div class="sendack-info">
+                <div class="sendack-info-li">
+                    <label>团 号:</label>
+                    <span v-if="this.groupInfo.tourCode!=''">{{groupInfo=={}?'暂无':groupInfo.tourCode==""?'暂无':groupInfo.tourCode}}</span>
+                    <!-- <span>{{groupInfo?'暂无':groupInfo.tourCode}}</span> -->
+                </div>
+                <div class="sendack-info-li">
+                    <label>客 户:</label>
+                    <span>{{groupInfo=={}?'暂无':groupInfo.clientName==""?'暂无':groupInfo.clientName}}</span>
+                </div>
+                <div class="sendack-info-li">
+                    <label>出访国家:</label>
+                    <span>{{groupInfo=={}?'暂无':groupInfo.visitCountry==""?'暂无':groupInfo.visitCountry}}</span>
+                </div>
+                <div class="sendack-info-li">
+                    <label>起止日期:</label>
+                    <span>{{groupInfo.visitStartDate|filter_time}}~{{groupInfo.visitEndDate|filter_time}}</span>
+                </div>
+                <div class="sendack-info-li">
+                    <label>天数/人数:</label>
+                    <span>{{groupInfo=={}?'暂无':groupInfo.visitDays+'天/'+groupInfo.visitPNumber+'人'}}</span>
+                </div>
+            </div>
+            <template>
+                <el-table
+                :data="groupsendData"
+                border
+                style="width: 100%">
+                    <el-table-column
+                        type="index"
+                        label="序 号"
+                        width="55">
+                    </el-table-column>
+                    <el-table-column
+                        prop="priceName"
+                        label="费用名称">
+                    </el-table-column>
+                    <el-table-column
+                        width="120" 
+                        prop="price"
+                        label="费用">
+                    </el-table-column>
+                    <el-table-column
+                        prop="createUserName"
+                        label="操作人"
+                        width="80">
+                    </el-table-column>
+                    <el-table-column
+                        prop="createTime"
+                        label="操作时间"
+                        width="160">
+                    </el-table-column>
+                    <el-table-column
+                        prop="remark"
+                        label="备注"
+                        width="600">
+                    </el-table-column>
+                    <el-table-column label="操作" width="110">
+                        <template slot-scope="scope">
+                          <el-button
+                            type="text"
+                            size="mini"
+                            @click="Complete(scope.$index, scope.row)">编辑</el-button>
+                            <el-button
+                            type="text"
+                            size="mini"
+                            @click="Delete(scope.$index, scope.row)"
+                           >删除</el-button>
+                        </template>
+                      </el-table-column>
+                </el-table>
+            </template>
+            <el-dialog width="900px" title="新增数据" :visible.sync="dialogFormVisible">
+                <el-form :model="form" :rules="rules" ref="form">
+                    <div style="display: flex;flex-wrap:wrap;">
+                        <el-form-item label="费用名称" prop="priceName" :label-width="formLabelWidth">
+                            <el-input v-model="form.priceName" autocomplete="off"></el-input>
+                        </el-form-item>
+                        <el-form-item label="费用金额" prop="price" :label-width="formLabelWidth">
+                            <el-input-number class="fyjeinput" :controls="false" :precision="2" v-model="form.price"></el-input-number>
+                            <el-select filterable class="fyjeselect" v-model="form.currencyId" placeholder="请选择币种">
+                                <el-option v-for="(item,index) in currencyDatas" :key="index" :label="item.name" :value="item.id"></el-option>
+                            </el-select>
+                        </el-form-item>
+                        <el-form-item label="收款方" prop="payee" :label-width="formLabelWidth">
+                            <el-input v-model="form.payee" autocomplete="off"></el-input>
+                        </el-form-item>
+                        <el-form-item label="支付方式" prop="payDId" :label-width="formLabelWidth">
+                            <el-select v-model="form.payDId" placeholder="请选择活动区域">
+                                <el-option v-for="(item,index) in payTypeDatas" :key="index" :label="item.name" :value="item.id"></el-option>
+                            </el-select>
+                        </el-form-item>
+                        <el-form-item label="费用标识" prop="orbitalPrivateTransfer" :label-width="formLabelWidth">
+                            <el-select v-model="form.orbitalPrivateTransfer" placeholder="请选择活动区域">
+                                <el-option v-for="(item,index) in orbitalPrivateTransferDatas" :key="index" :label="item.name" :value="item.id"></el-option>
+                            </el-select>
+                        </el-form-item>
+                        <el-form-item label="消费方式" prop="consumptionPatterns" :label-width="formLabelWidth">
+                            <el-input v-model="form.consumptionPatterns" autocomplete="off"></el-input>
+                        </el-form-item>
+                        <el-form-item label="费用类型" prop="payType" :label-width="formLabelWidth">
+                            <el-select v-model="form.payType" placeholder="请选择活动区域">
+                                <el-option v-for="(item,index) in priceTypeDatas" :key="index" :label="item.name" :value="item.id"></el-option>
+                            </el-select>
+                        </el-form-item>
+                    </div>
+                    <el-form-item style="width:97%" label="备 注" :label-width="formLabelWidth">
+                        <el-input style="width:100%" :rows="4" type="textarea" v-model="form.remark" autocomplete="off"></el-input>
+                    </el-form-item>
+                    </el-form>
+                    <div slot="footer" class="dialog-footer">
+                    <el-button @click="dialogFormVisible = false">取 消</el-button>
+                    <el-button type="primary" @click="submitForm('form','保存')">确 定</el-button>
+                    <el-button type="primary" @click="submitForm('form','修改')">修 改</el-button>
+                    </div>
+              </el-dialog>
+        </div>
+    </div>
+</template>
+<script>
+export default {
+    data() {
+        return {
+            userid:'',
+            value:'',
+            options:[],
+            groupInfo:{},
+            groupsendData:[],
+            pageId:0,
+            dialogFormVisible:false,
+            form:{
+                id:0,
+                ccpId:0,
+                priceName:'',//费用名称
+                price:0,//费用
+                currencyId:807,//币种Id
+                currencyCode:'',//币种Code
+                payee:'',//收款方
+                payDId:72,//支付方式Id
+                orbitalPrivateTransfer:0,//费用标识
+                consumptionPatterns:'',//消费方式
+                payType:0,//费用类型 0 其他 1 退多付款
+                remark:'',//备注
+            },
+            rules: {
+                priceName: [
+                    { required: true, message: '请输入费用名称', trigger: 'blur' },
+                ],
+                price: [
+                    { required: true, message: '请填写完此项', trigger: 'blur' }
+                ],
+                payee: [
+                    { required: true, message: '请填写完此项', trigger: 'blur' }
+                ],
+                payDId: [
+                    { required: true, message: '请选择', trigger: 'change' }
+                ],
+                orbitalPrivateTransfer: [
+                    {  required: true, message: '请选择', trigger: 'change' }
+                ],
+                consumptionPatterns: [
+                    { required: true, message: '请填写完此项', trigger: 'blur' }
+                ],
+                payType: [
+                    { required: true, message: '请选择', trigger: 'change' }
+                ]
+            },
+            formLabelWidth:'100px',
+            currencyDatas:[],
+            payTypeDatas:[],
+            priceTypeDatas:[],
+            orbitalPrivateTransferDatas:[],
+        }
+    },
+    methods:{
+        filteryear(val){
+            let gstime=val.visitDate.split(' ')[0]
+            return gstime;
+        },
+        //获取团组
+        GetForeignReceivablesDataSources(){
+            var url = "/api/Financial/GetForeignReceivablesDataSources"
+            var that = this
+            this.$axios({
+                method: 'post',
+                url: url,
+                headers: {
+                    Authorization: 'Bearer ' + that.userid
+                },
+            }).then(function (res) {
+                console.log(res)
+                if(res.data.code==200){
+                    that.options=res.data.data.groupNameData;
+                    that.value=res.data.data.groupNameData[0].id;
+                    that.PostShareGroupInfo();
+                    that.PostPaymentRefundAndOtherMoneyItemByDiId();
+                }else{
+                    that.$message.error('获取数据源失败!');
+                }
+            })
+        },
+        //获取数据源
+        PostPaymentRefundAndOtherMoneyInfoDataSource(){
+            var url = "/api/Financial/PostPaymentRefundAndOtherMoneyInfoDataSource"
+            var that = this
+            this.$axios({
+                method: 'post',
+                url: url,
+                headers: {
+                    Authorization: 'Bearer ' + that.userid
+                },
+                data:{
+                    portType: 1
+                }
+            }).then(function (res) {
+                console.log(res)
+                if(res.data.code==200){
+                    that.currencyDatas=res.data.data.currencyDatas;
+                    that.payTypeDatas=res.data.data.payTypeDatas;
+                    that.priceTypeDatas=res.data.data.priceTypeDatas;
+                    that.orbitalPrivateTransferDatas=res.data.data.orbitalPrivateTransferDatas;
+                }else{
+                    that.$message.error('获取数据源失败!');
+                }
+            })
+        },
+        //获取团组详情
+        PostShareGroupInfo(){
+            var url = "/api/Business/PostShareGroupInfo"
+            var that = this
+            this.$axios({
+                method: 'post',
+                url: url,
+                headers: {
+                    Authorization: 'Bearer ' + that.userid
+                },
+                data:{
+                    portType:1,
+                    id: that.value
+                }
+            }).then(function (res) {
+                console.log(res)
+                if(res.data.code==200){
+                    that.groupInfo=res.data.data;
+                }else{
+                    that.$message.error('获取数据源失败!');
+                }
+            })
+        },
+        //获取团组收款退还与其他款项
+        PostPaymentRefundAndOtherMoneyItemByDiId(){
+            var url = "/api/Financial/PostPaymentRefundAndOtherMoneyItemByDiId"
+            var that = this
+            this.$axios({
+                method: 'post',
+                url: url,
+                headers: {
+                    Authorization: 'Bearer ' + that.userid
+                },
+                data:{
+                    portType:1,
+                    userId:that.userid,
+                    pageId:that.pageId,
+                    diId: that.value
+                }
+            }).then(function (res) {
+                console.log(res)
+                if(res.data.code==200){
+                    that.groupsendData=res.data.data.data
+                }else{
+                    that.$message.error('获取数据源失败!');
+                }
+            })
+        },
+        //保存修改
+        submitForm(formName,text) {
+            this.$refs[formName].validate((valid) => {
+            if (valid) {
+                var status
+                var id
+                var ccpId
+                for(var i=0;i<this.currencyDatas.length;i++){
+                    if(this.currencyDatas[i].id==this.form.currencyId){
+                        this.form.currencyCode=this.currencyDatas[i].name
+                    }
+                }
+                if(text=='保存'){
+                    status=1
+                    this.PostPaymentRefundAndOtherMoneyAddOrEdit(status)
+                }
+                if(text=='修改'){
+                    status=2
+                    this.PostPaymentRefundAndOtherMoneyAddOrEdit(status)
+                }
+                console.log(this.form)
+            } else {
+                console.log('error submit!!');
+                return false;
+            }
+            });
+        },
+        //保存修改api
+        PostPaymentRefundAndOtherMoneyAddOrEdit(status){
+            var url = "/api/Financial/PostPaymentRefundAndOtherMoneyAddOrEdit"
+            var that = this
+            var data={
+                    portType:1,
+                    userId:that.userid,
+                    status:status,//1 添加 2 修改
+                    diId:that.value,
+                    id:that.form.id,
+                    ccpId:that.form.ccpId,
+                    priceName:that.form.priceName,
+                    price:that.form.price,
+                    currencyId:that.form.price,
+                    currencyCode:that.form.currencyCode,
+                    payee:that.form.payee,
+                    payDId:that.form.payDId,
+                    orbitalPrivateTransfer:that.form.orbitalPrivateTransfer,
+                    consumptionPatterns:that.form.consumptionPatterns,
+                    payType:that.form.payType,
+                    remark:that.form.remark,
+                }
+                console.log(JSON.stringify(data))
+            this.$axios({
+                method: 'post',
+                url: url,
+                headers: {
+                    Authorization: 'Bearer ' + that.userid
+                },
+                data:{
+                    portType:1,
+                    userId:that.userid,
+                    status:status,//1 添加 2 修改
+                    diId:that.value,
+                    id:that.form.id,
+                    ccpId:that.form.ccpId,
+                    priceName:that.form.priceName,
+                    price:that.form.price,
+                    currencyId:that.form.currencyId,
+                    currencyCode:that.form.currencyCode,
+                    payee:that.form.payee,
+                    payDId:that.form.payDId,
+                    orbitalPrivateTransfer:that.form.orbitalPrivateTransfer,
+                    consumptionPatterns:that.form.consumptionPatterns,
+                    payType:that.form.payType,
+                    remark:that.form.remark,
+                }
+            }).then(function (res) {
+                console.log(res)
+                if(res.data.code==200){
+                    that.$message({
+                        message: res.data.msg,
+                        type: 'success'
+                    });
+                }else{
+                    that.$message.error(res.data.msg);
+                }
+            })
+        },
+        //编辑
+        Complete(index,row){
+            if (this.$refs.form){
+                this.$nextTick(() => {
+                    this.$refs['form'].clearValidate();
+                })
+            }
+            //弹框
+            this.dialogFormVisible=true;
+            //初始化数据
+            this.form={
+                id:0,
+                ccpId:0,
+                priceName:'',//费用名称
+                price:0,//费用
+                currencyId:807,//币种Id
+                currencyCode:'',//币种Code
+                payee:'',//收款方
+                payDId:72,//支付方式Id
+                orbitalPrivateTransfer:0,//费用标识
+                consumptionPatterns:'',//消费方式
+                payType:0,//费用类型 0 其他 1 退多付款
+                remark:'',//备注
+            }
+            var formobject={}
+            var url = "/api/Financial/PostPaymentRefundAndOtherMoneyInfo"
+            var that = this
+            this.$axios({
+                method: 'post',
+                url: url,
+                headers: {
+                    Authorization: 'Bearer ' + that.userid
+                },
+                data:{
+                    portType:1,
+                    id: row.id,
+                }
+            }).then(function (res) {
+                console.log(res)
+                if(res.data.code==200){
+                    formobject=res.data.data[0];
+                    that.form.id=formobject.id;
+                    that.form.ccpId=formobject.ccpId;
+                    that.form.priceName=formobject.priceName;
+                    that.form.price=formobject.price;
+                    that.form.currencyId=formobject.currencyId;
+                    that.form.payee=formobject.payee;
+                    that.form.payDId=formobject.payDId;
+                    that.form.orbitalPrivateTransfer=formobject.orbitalPrivateTransfer;
+                    that.form.consumptionPatterns=formobject.consumptionPatterns;
+                    that.form.payType=formobject.payType;
+                    that.form.remark=formobject.remark;
+                }else{
+                    that.$message.error('获取数据源失败!');
+                }
+            })
+        },
+        //删除
+        Delete(index,row){
+            this.$confirm('此操作将删除此条数据,是否确认删除?', '提示', {
+                confirmButtonText: '确定',
+                cancelButtonText: '取消',
+                type: 'warning'
+            }).then(() => {
+                var url = "/api/Financial/PostPaymentRefundAndOtherMoneyItemByDiId"
+                var that = this
+                this.$axios({
+                    method: 'post',
+                    url: url,
+                    headers: {
+                        Authorization: 'Bearer ' + that.userid
+                    },
+                    data:{
+                        portType:1,
+                        id: row.id
+                    }
+                }).then(function (res) {
+                    console.log(res)
+                    if(res.data.code==200){
+                        that.$message({
+                            message: res.data.msg,
+                            type: 'success'
+                        });
+                        that.PostPaymentRefundAndOtherMoneyItemByDiId()
+                    }else{
+                        that.$message.error('获取数据源失败!');
+                    }
+                })
+            })
+        },
+        changediid(){
+            this.PostShareGroupInfo();
+            this.PostPaymentRefundAndOtherMoneyItemByDiId();
+        }
+    },
+    filters:{
+        filter_time(value){
+            if(value){
+                return value.split(' ')[0];
+            }
+            return value
+            
+        },
+        filter_city(value){
+            return value
+        }
+    },
+    mounted(){
+        this.userid=JSON.parse(localStorage.getItem('userinif')).userInfo.userId;
+        this.pageId=localStorage.getItem('indexs').split('-')[1];//页面id
+        console.log(this.pageId)
+        this.GetForeignReceivablesDataSources();
+        this.PostPaymentRefundAndOtherMoneyInfoDataSource();
+    }
+}
+</script>
+<style>
+.sendack-all{
+    background-color: #fff;
+    padding: 10px;
+    box-shadow: 0 0 5px #0005;
+    border-radius: 10px;
+    height: 100%;
+    min-height: 840px;
+}
+.sendack-head-li label{
+    color: #606266;
+    font-size: 15px;
+    font-weight: 600;
+}
+.sendack-head{
+    display: flex;
+    justify-content: space-between;
+}
+.sendack-info{
+    display: flex;
+    margin-top: 10px;
+    margin-bottom: 10px;
+}
+.sendack-info-li{
+    margin-right: 30px;
+}
+.sendack-info-li label{
+    color: #606266;
+    font-size: 15px;
+    font-weight: 600;
+}
+.sendack-info-li span{
+    color: #606266;
+    font-size: 14px;
+}
+.sendack-all .el-form-item{
+    width: 50%;
+}
+.sendack-all .el-form-item input{
+    width: 300px;
+}
+.sendack-all .fyjeinput{
+    width: 148px;
+}
+.sendack-all .fyjeinput input{
+    width: 100%;
+}
+.sendack-all .fyjeselect{
+    width: 148px;
+}
+.sendack-all .fyjeselect input{
+    width: 100%;
+}
+</style>

+ 313 - 0
src/components/OP/Customers.vue

@@ -0,0 +1,313 @@
+<template>
+    <div>
+        <div class="communal-list">
+            <div>
+
+                <div class="communal-title">
+                    <div>保险费用录入</div>
+                </div>
+                <div style="display: flex;justify-content: space-between;">
+
+                    <div style="width: 80%;display: flex;">
+                        <div style="width: 25%;">
+                            <el-select v-model="DiId" placeholder="团组选择" clearable filterable @change="VisaSelectChange"
+                                style="width: 100%;">
+                                <el-option v-for="item in delegationInfoList" :key="item.id" :label="item.teamName"
+                                    :value="item.id">
+                                </el-option>
+                            </el-select>
+                        </div>
+                        <div style="width: 25%;"><el-input v-model="VisaClient" placeholder="请输入客户名称" clearable></el-input>
+                        </div>
+                        <div style="width: 25%;margin-left: 10px;"><el-button type="primary"
+                                @click="QueryByVisaClient">查询</el-button>
+                        </div>
+                    </div>
+                    <div style="width: 20%">
+                        <el-button type="primary" style="" @click="addIf">新增</el-button>
+                    </div>
+                </div>
+            </div>
+            <div style="margin:10px 0;color:#606266;">
+                <span style="font-weight: bold;font-size:17px;">团队名称:</span>
+                <span style="color:#606266;">{{ delegationInfo.teamName }}&nbsp;&nbsp;&nbsp;</span>
+                <span style="font-weight: bold;font-size:17px;">客户:</span>
+                <span style="color:#606266;">{{ delegationInfo.clientName }}&nbsp;&nbsp;&nbsp; {{
+}}&nbsp;&nbsp;&nbsp;</span>
+                <span style="font-weight: bold;font-size:17px;">出访国家:</span>
+                <span style="color:#606266;">{{ delegationInfo.visitCountry }}&nbsp;&nbsp;&nbsp;</span>
+                <span style="font-weight: bold;font-size:17px;">起止日期:</span>
+                <span style="color:#606266;">{{ delegationInfo.visitStartDate }}—{{ delegationInfo.visitEndDate
+                }}&nbsp;&nbsp;&nbsp;</span>
+                <span style="font-weight: bold;font-size:17px;">天数/人数:</span>
+                <span style="color:#606266;">{{ delegationInfo.visitDays }}天/{{ delegationInfo.visitPNumber }}人</span>
+            </div>
+
+            <template>
+                <el-table :data="tableDatas.slice((currentPage - 1) * pageSize, currentPage * pageSize)" border
+                    style="width: 100%" v-loading="loading" element-loading-text="拼命加载中...">
+                    <el-table-column prop="num" label="序 号" width="55">
+                        <template slot-scope="scope">
+                            {{ (currentPage - 1) * pageSize + scope.$index + 1 }}
+                        </template>
+                    </el-table-column>
+                    <el-table-column prop="clientName" label="客户名称">
+                    </el-table-column>
+                    <el-table-column prop="insuranceCosts,currencyStr" label="保险费用">
+                        <template slot-scope="scope">
+                            {{ scope.row.insuranceCosts }}({{ scope.row.currencyStr }})
+                        </template>
+                    </el-table-column>
+                    <el-table-column prop="isAuditGMStr" label="是否审核">
+                    </el-table-column>
+                    <el-table-column prop="attachment" label="附 件">
+                        <template slot-scope="scope">
+
+                            <a @click="download(scope.$index, scope.row)">{{ scope.row.attachment }}</a>
+                        </template>
+                    </el-table-column>
+                    <el-table-column label="操作">
+                        <template slot-scope="scope">
+                            <el-button-group>
+                                <el-button type="primary" size="mini" icon="el-icon-edit"
+                                    @click="upDate(scope.$index, scope.row)"></el-button>
+                                <el-button type="danger" size="mini" icon="el-icon-delete"
+                                    @click="del(scope.$index, scope.row)"></el-button>
+                            </el-button-group>
+                        </template>
+                    </el-table-column>
+                </el-table>
+            </template>
+            <div class="block">
+                <el-pagination align='center' @size-change="handleSizeChange" @current-change="handleCurrentChange"
+                    :current-page="currentPage" :page-sizes="[5, 10, 12, 15, 20]" :page-size="pageSize"
+                    layout="total, sizes, prev, pager, next" :total="tableDatas.length">
+                </el-pagination>
+            </div>
+        </div>
+    </div>
+</template>
+<script>
+import { el } from '@fullcalendar/core/internal-common';
+export default {
+    data() {
+        return {
+            loading: false,
+            tableDatas: [],
+            tableData: [],
+            currentPage: 1, // 当前页码
+            pageSize: 12,// 每页的数据条数
+            input: '',
+            token: '',
+            userId: 0,
+            DiId: '',
+            VisaSelectList: [],
+            VisaClient: '',
+            delegationInfoList: [],
+            delegationInfo: {},
+        }
+    },
+    methods: {
+        //每页条数改变时触发 选择一页显示多少行
+        handleSizeChange(val) {
+            this.currentPage = 1;
+            this.pageSize = val;
+        },
+        //当前页改变时触发 跳转其他页
+        handleCurrentChange(val) {
+            this.currentPage = val;
+        },
+        //团组下拉框
+        visaSelect() {
+            var url = "/api/Groups/DecreasePaymentsSelect"
+            var that = this
+            this.$axios({
+                method: 'post',
+                url: url,
+                headers: {
+                    Authorization: 'Bearer ' + this.token
+                },
+                data: {
+                    UserId: that.userId,
+                    CTId: 82,
+                }
+            }).then(function (res) {
+                if (res.data.code == 200) {
+                    debugger
+                    that.delegationInfoList = res.data.data.groupName;
+                    that.DiId = that.$route.query.diId
+                    if (that.DiId == undefined) {
+                        that.delegationInfo = that.delegationInfoList[0]
+                        that.DiId = that.delegationInfoList[0].id;
+                    } else {
+                        for (let index = 0; index < that.delegationInfoList.length; index++) {
+                            debugger
+                            if (that.delegationInfoList[index].id == that.DiId) {
+                                that.delegationInfo = that.delegationInfoList[index];
+                                that.DiId = that.delegationInfoList[index].id;
+                                break;
+                            }
+                        }
+                    }
+
+                    that.PostVisaByDiId()
+                }
+            })
+        },
+        VisaSelectChange() {
+            if (this.DiId != "") {
+                this.PostVisaByDiId();
+            } else {
+                this.tableDatas = [];
+                this.tableData = [];
+            }
+        },
+        //团组信息绑定
+        PostVisaByDiId() {
+            var url = "/api/Groups/CustomersByDiId"
+            var that = this
+            this.$axios({
+                method: 'post',
+                url: url,
+                headers: {
+                    Authorization: 'Bearer ' + this.token
+                },
+                data: {
+                    pageIndex: 0,
+                    pageSize: 0,
+                    portType: 1,
+                    diID: that.DiId,
+                    ClientName: that.VisaClient
+                }
+            }).then(function (res) {
+                if (res.data.code == 200) {
+                    debugger
+                    that.tableDatas = res.data.data;
+                    that.tableData = that.tableDatas
+                    if (that.tableDatas.length != 0) {
+                        if (that.tableDatas.slice((that.currentPage - 1) * that.pageSize, that.currentPage * that.pageSize).length == 0) {
+                            if (that.currentPage > 1) {
+                                that.currentPage = that.currentPage - 1;
+                            }
+                        }
+                    }
+
+                }
+
+            })
+        },
+        QueryByVisaClient() {
+            this.PostVisaByDiId()
+        },
+        upDate(index, row) {
+            this.$router.push({
+                path: "/home/OpCustomers",
+                query: {
+                    DiId: this.DiId,
+                    id: row.id
+                }
+            })
+
+        },
+        addIf() {
+            debugger
+            if (this.DiId != 0 && this.DiId != '' && this.DiId != undefined) {
+                this.$router.push({
+                    path: "/home/OpCustomers",
+                    query: {
+                        DiId: this.DiId,
+                    }
+                })
+
+            } else {
+                this.$message('请选择团组在进行添加');
+            }
+        },
+        del(index, row) {
+            this.$confirm('此操作将删除该数据, 是否继续?', '提示', {
+                confirmButtonText: '确定',
+                cancelButtonText: '取消',
+                type: 'warning'
+            }).then(() => {
+                var url = "/api/Groups/DelCustomers"
+                var that = this
+                this.$axios({
+                    method: 'post',
+                    url: url,
+                    headers: {
+                        Authorization: 'Bearer ' + this.token
+                    },
+                    data: {
+                        Id: row.id,
+                        DeleteUserId: this.userId
+                    }
+                }).then(function (res) {
+                    console.log(res)
+
+                    if (res.data.code == 200) {
+
+                        that.$message({
+                            message: '删除成功',
+                            type: 'success'
+                        });
+                        that.PostVisaByDiId();
+                    } else {
+                        that.$message.error('删除失败!');
+                    }
+                    that.loading = false
+                }).catch(function (error) {
+                    that.loading = false
+                    that.$message.error("网络错误,请稍后重试");
+                });
+            }).catch(() => {
+                this.$message({
+                    type: 'info',
+                    message: '操作已取消!'
+                });
+            });
+        },
+        download(index, row) {
+            if (row.attachment != "") {
+                window.location.href = "http://132.232.92.186:24/Office/GrpFile/保险费用文件上传/" + row.attachment
+            } else {
+                this.$message.error("暂未上传附件");
+            }
+
+        },
+    },
+    mounted() {
+        this.token = JSON.parse(localStorage.getItem('userinif')).token;
+        this.userId = JSON.parse(localStorage.getItem('userinif')).userInfo.userId
+        this.visaSelect();
+        //this.AirTicketResList()
+    }
+}
+</script>
+<style>
+.communal-list {
+    background-color: #fff;
+    padding: 10px;
+    box-shadow: 0 0 5px #0005;
+    border-radius: 10px;
+}
+
+.communal-title {
+    display: flex;
+    font-size: 17px;
+    font-weight: 600;
+    color: #555;
+    margin-top: 8px;
+    margin-bottom: 10px;
+    justify-content: space-between;
+    align-items: center;
+}
+
+.communal-box {
+    display: flex;
+}
+
+.communal-box>button {
+    margin-left: 10px;
+    padding: 8px 20px;
+}
+</style>

+ 166 - 33
src/components/OP/HotelReservations.vue

@@ -220,7 +220,7 @@
                                     </el-option>
                                 </el-select>
                             </el-form-item>
-                            <el-form-item style="width:25% ;" label="酒店双间" prop="desc">
+                            <el-form-item style="width:25% ;" label="酒店双间" prop="doubleRoomCount">
                                 <el-input style="width:50px ;" size="medium"
                                     v-model="OpHotelReservationsData.doubleRoomCount"></el-input>
                                 <span>间</span>
@@ -269,9 +269,9 @@
                                     style="width: 100;" @change="bankCardPriceChange"></el-input>
 
                             </el-form-item>
-                            <el-form-item label-width="10px" prop="ctdId">
-                                <el-select size="medium" v-model="OpHotelReservationsData.ctdId" placeholder="请选择信用卡"
-                                    @change="bankCardChage">
+                            <el-form-item label-width="10px" prop="cardPriceCurrency">
+                                <el-select size="medium" v-model="OpHotelReservationsData.cardPriceCurrency"
+                                    placeholder="请选择信用卡" @change="bankCardChage">
                                     <el-option v-for="item in bankCard" :key="item.id" :label="item.name" :value="item.id">
                                     </el-option>
                                 </el-select>
@@ -375,9 +375,9 @@
                         <div v-if="OpHotelReservationsData.payDId == 72">
                             <div style="display: flex;">
                                 <div style="width: 25%;">
-                                    <el-form-item label="卡类型:" prop="ctdIdPay" label-width="160px">
-                                        <el-select v-model="ctdIdPay" placeholder="卡类型" style="width: 100%;"
-                                            @change="ctdChange">
+                                    <el-form-item label="卡类型:" prop="ctdId" label-width="160px">
+                                        <el-select v-model="OpHotelReservationsData.ctdId" placeholder="卡类型"
+                                            style="width: 100%;" @change="ctdChange">
                                             <el-option v-for="item in bankCard" :key="item.id" :label="item.name"
                                                 :value="item.id">
                                             </el-option>
@@ -501,10 +501,10 @@ export default {
             DelfileName: "",
             headers: {
                 Authorization: JSON.parse(localStorage.getItem('userinif')).token,
-                TypeName: "B"
             },
             Rate: '1',
             loading: false,
+            isAuditGM: 0,
             delegationInfoList: [],
             delegationInfo: {},
             guestType: [],//客人类型
@@ -532,7 +532,6 @@ export default {
             ],
             CardCurrency: '',
             currencySingle: { id: 836, name: 'CNY', remark: '人民币' },
-            ctdIdPay: '',
             OpHotelReservationsData: {
                 status: 1,
                 id: 0,
@@ -561,6 +560,7 @@ export default {
                 roomExplanation: '',
                 attachment: '',
                 cardPrice: 0.00,
+                cardPriceCurrency: '',
                 isCardPrice: 0,
                 predictSingleRoom: 0,
                 predictDoubleRoom: 0,
@@ -615,8 +615,76 @@ export default {
                     { required: true, message: '请选择入住时间', trigger: ['blur', 'change'] }
                 ],
                 checkOutDate: [
+                    { required: true, message: '请输入办理人数', trigger: ['blur', 'change'] },
                     { required: true, message: '请选择离店时间', trigger: ['blur', 'change'] }
                 ],
+                predictSingleRoom: [
+                    { required: true, message: '请输入单间预定间数,没有则填0', trigger: ['blur', 'change'] },
+                    { pattern: /^[0-9]\d*$/, message: '请输入正确的数字', trigger: ['blur', 'change'] },
+                ],
+                predictDoubleRoom: [
+                    { required: true, message: '请输入双间预定间数,没有则填0', trigger: ['blur', 'change'] },
+                    { pattern: /^[0-9]\d*$/, message: '请输入正确的数字', trigger: ['blur', 'change'] },
+                ],
+                predictSuiteRoom: [
+                    { required: true, message: '请输入套房间预定间数,没有则填0', trigger: ['blur', 'change'] },
+                    { pattern: /^[0-9]\d*$/, message: '请输入正确的数字', trigger: ['blur', 'change'] },
+                ],
+                predictOtherRoom: [
+                    { required: true, message: '请输入其他间预定间数,没有则填0', trigger: ['blur', 'change'] },
+                    { pattern: /^[0-9]\d*$/, message: '请输入正确的数字', trigger: ['blur', 'change'] },
+                ],
+                singleRoomCount: [
+                    { required: true, message: '请输入单间数量,没有则填0', trigger: ['blur', 'change'] },
+                    { pattern: /^[0-9]\d*$/, message: '请输入正确的数字', trigger: ['blur', 'change'] },
+                ],
+                singleRoomPrice: [
+                    { required: true, message: '请输入单价,没有则填0.00', trigger: ['blur', 'change'] },
+                    { pattern: /^(([1-9]?\d{0,8}(\.\d{1,2})?)|999999999|999999999\.(0){1,2})$/, message: '请输入正确的金额(最多2位小数)' }
+                ],
+                doubleRoomCount: [
+                    { required: true, message: '请输入双间数量,没有则填0.00', trigger: ['blur', 'change'] },
+                    { pattern: /^[0-9]\d*$/, message: '请输入正确的数字', trigger: ['blur', 'change'] },
+                ],
+                doubleRoomPrice: [
+                    { required: true, message: '请输入单价,没有则填0.00', trigger: ['blur', 'change'] },
+                    { pattern: /^(([1-9]?\d{0,8}(\.\d{1,2})?)|999999999|999999999\.(0){1,2})$/, message: '请输入正确的金额(最多2位小数)' }
+                ],
+                suiteRoomCount: [
+                    { required: true, message: '请输入其他房间间数,没有则填0', trigger: ['blur', 'change'] },
+                    { pattern: /^[0-9]\d*$/, message: '请输入正确的数字', trigger: ['blur', 'change'] },
+                ],
+                suiteRoomPrice: [
+                    { required: true, message: '请输入单价,没有则填0.00', trigger: ['blur', 'change'] },
+                    { pattern: /^(([1-9]?\d{0,8}(\.\d{1,2})?)|999999999|999999999\.(0){1,2})$/, message: '请输入正确的金额(最多2位小数)' }
+                ],
+                otherRoomCount: [
+                    { required: true, message: '请输入其他间预定间数,没有则填0', trigger: ['blur', 'change'] },
+                    { pattern: /^[0-9]\d*$/, message: '请输入正确的数字', trigger: ['blur', 'change'] },
+                ],
+                otherRoomPrice: [
+                    { required: true, message: '请输入单价,没有则填0.00', trigger: ['blur', 'change'] },
+                    { pattern: /^(([1-9]?\d{0,8}(\.\d{1,2})?)|999999999|999999999\.(0){1,2})$/, message: '请输入正确的金额(最多2位小数)' }
+                ],
+                governmentRent: [
+                    { required: true, message: '请输入地税,没有则填0.00', trigger: ['blur', 'change'] },
+                    { pattern: /^(([1-9]?\d{0,8}(\.\d{1,2})?)|999999999|999999999\.(0){1,2})$/, message: '请输入正确的金额(最多2位小数)' }
+                ],
+                cityTax: [
+                    { required: true, message: '请输入城市税,没有则填0.00', trigger: ['blur', 'change'] },
+                    { pattern: /^(([1-9]?\d{0,8}(\.\d{1,2})?)|999999999|999999999\.(0){1,2})$/, message: '请输入正确的金额(最多2位小数)' }
+                ],
+                cardPrice: [
+                    { required: true, message: '请输入信用卡金额,没有则填0.00', trigger: ['blur', 'change'] },
+                    { pattern: /^(([1-9]?\d{0,8}(\.\d{1,2})?)|999999999|999999999\.(0){1,2})$/, message: '请输入正确的金额(最多2位小数)' }
+                ],
+                // ctdIdPay: [
+                //     { required: true },
+                // ],
+                companyBankNo: [{ required: true, message: '公司银行账号', trigger: ['blur', 'change'] },],
+                otherBankName: [{ required: true, message: '对方开户行', trigger: ['blur', 'change'] },],
+                otherSideNo: [{ required: true, message: '对方银行卡号', trigger: ['blur', 'change'] },],
+                otherSideName: [{ required: true, message: '对方姓名', trigger: ['blur', 'change'] },],
             },
         }
     },
@@ -641,6 +709,8 @@ export default {
                 },
                 data: {
                     UserId: that.userId,
+                    PortType: 1,
+                    diid: 0
                 }
             }).then(function (res) {
                 if (res.data.code == 200) {
@@ -683,6 +753,7 @@ export default {
                     break;
                 }
             }
+
             this.HotelReservationsByDiId();
 
             this.OpHotelReservationsData.status = 1;
@@ -737,8 +808,12 @@ export default {
             this.OpHotelReservationsData.payee = '';
             this.OpHotelReservationsData.orbitalPrivateTransfer = 0;
             this.OpHotelReservationsData.cRemark = ''
+            this.$nextTick(() => {
+                this.$refs.OpHotelReservationsData.clearValidate();
+            })
         },
         HotelReservationsByDiId() {
+
             var url = "/api/Groups/HotelReservationsByDiId"
             var that = this
             this.$axios({
@@ -829,11 +904,25 @@ export default {
                     if (creditCardPayment.paymentCurrency == 0) {
                         that.OpHotelReservationsData.paymentCurrency = ''
                     }
+
+                    if (that.OpHotelReservationsData.governmentRentCurrency == 0) {
+                        that.OpHotelReservationsData.governmentRentCurrency = '';
+                    }
+                    if (that.OpHotelReservationsData.cityTaxCurrency == 0) {
+                        that.OpHotelReservationsData.cityTaxCurrency = '';
+                    }
                     that.OpHotelReservationsData.paymentCurrency = creditCardPayment.paymentCurrency;
                     that.OpHotelReservationsData.payDId = creditCardPayment.payDId;
+                    if (that.OpHotelReservationsData.payDId == 0) {
+                        that.OpHotelReservationsData.payDId == ''
+                    }
                     that.OpHotelReservationsData.consumptionPatterns = creditCardPayment.consumptionPatterns;
                     that.OpHotelReservationsData.consumptionDate = creditCardPayment.consumptionDate;
+                    debugger
                     that.OpHotelReservationsData.ctdId = creditCardPayment.ctdId;
+                    if (that.OpHotelReservationsData.ctdId == 0) {
+                        that.OpHotelReservationsData.ctdId = '';
+                    }
                     that.OpHotelReservationsData.companyBankNo = creditCardPayment.companyBankNo;
                     that.OpHotelReservationsData.otherBankName = creditCardPayment.otherBankName;
                     that.OpHotelReservationsData.otherSideNo = creditCardPayment.otherSideNo;
@@ -852,16 +941,19 @@ export default {
                         })
                     }
                     that.PostCurrencyByDiid(that.OpHotelReservationsData.diId, 76, that.OpHotelReservationsData.budgetCurrency)
-                    var s = that.currencyList.filter(x => x.id == that.OpHotelReservationsData.paymentCurrency);
-                    if (s.length > 0) {
-                        that.currencySingle.id = s[0].id;
-                        that.currencySingle.name = s[0].name;
-                        that.currencySingle.remark = s[0].remark;
-                        that.CardCurrency = that.currencySingle.name + '(' + that.currencySingle.remark + ')'
-                    }
-                    if (that.OpHotelReservationsData.ctdId == '74') {
+                    // var s = that.currencyList.filter(x => x.id == that.OpHotelReservationsData.paymentCurrency);
+                    // if (s.length > 0) {
+                    //     that.currencySingle.id = s[0].id;
+                    //     that.currencySingle.name = s[0].name;OpHotelReservationsDataRules
+                    //     that.currencySingle.remark = s[0].remark;
+                    //     that.CardCurrency = that.currencySingle.name + '(' + that.currencySingle.remark + ')'
+                    // }
+                    debugger
+                    that.isAuditGM = creditCardPayment.isAuditGM;
+                    that.OpHotelReservationsData.cardPriceCurrency = hotelReservations.cardPriceCurrency
+                    if (that.OpHotelReservationsData.cardPriceCurrency == '74') {
                         that.CardCurrency = "USD(美元)"
-                    } else if (that.OpHotelReservationsData.ctdId == '75') {
+                    } else if (that.OpHotelReservationsData.cardPriceCurrency == '75') {
                         that.CardCurrency = "EUR(欧元)"
                     } else {
                         that.CardCurrency = "CNY(人民币)"
@@ -874,6 +966,7 @@ export default {
             });
         },
         payChange() {
+            debugger
             this.OpHotelReservationsData.ctdId = '';
             this.OpHotelReservationsData.bankNo = '';
             this.OpHotelReservationsData.cardholderName = '';
@@ -895,6 +988,7 @@ export default {
                 this.OpHotelReservationsDataRules.otherSideNo = []
                 this.OpHotelReservationsDataRules.otherSideName = []
             } else if (this.OpHotelReservationsData.payDId == 83) {
+                debugger
                 this.OpHotelReservationsDataRules.companyBankNo = []
                 this.OpHotelReservationsDataRules.otherBankName = [{ required: true, message: '对方开户行', trigger: ['blur', 'change'] },]
                 this.OpHotelReservationsDataRules.otherSideNo = [{ required: true, message: '对方银行卡号', trigger: ['blur', 'change'] },]
@@ -915,6 +1009,45 @@ export default {
                     this.OpHotelReservationsData.bankNo = this.bankCard[i].remark
                 }
             }
+            var that = this
+            var cardPriceCurrency = 0;
+            if (that.OpHotelReservationsData.ctdId == '74') {
+                cardPriceCurrency = 950
+            } else if (that.OpHotelReservationsData.ctdId == '75') {
+                cardPriceCurrency = 849
+            } else {
+                cardPriceCurrency = 836
+            }
+
+            var url = "/api/Groups/HotelConversionAmounts"
+            this.$axios({
+                method: 'post',
+                url: url,
+                headers: {
+                    Authorization: 'Bearer ' + this.token
+                },
+                data: {
+                    cTable: 76,
+                    diId: that.OpHotelReservationsData.diId,
+                    cardPrice: that.OpHotelReservationsData.cardPrice,
+                    cardPriceCurrency: cardPriceCurrency,
+                    governmentRent: that.OpHotelReservationsData.governmentRent,
+                    governmentRentCurrency: that.OpHotelReservationsData.governmentRentCurrency,
+                    cityTax: that.OpHotelReservationsData.cityTax,
+                    cityTaxCurrency: that.OpHotelReservationsData.cityTaxCurrency
+                }
+            }).then(function (res) {
+
+                if (res.data.code == 200) {
+                    var CurrencyBy = res.data.data;
+                    that.OpHotelReservationsData.payMoney = CurrencyBy.price;
+                    that.OpHotelReservationsData.paymentCurrency = CurrencyBy.currencyId
+                } else {
+                    that.$message.error('暂未查到该币种团组汇率,请手动填写付款金额');
+                }
+            }).catch(function (error) {
+                //that.$message.error("网络错误,请稍后重试");
+            });
         },
         budgetCurrencyChange(Id) {
 
@@ -954,9 +1087,7 @@ export default {
                     }
 
                 }
-            }).catch(function (error) {
-                that.$message.error("网络错误,请稍后重试");
-            });
+            })
         },
         bankCardChage(id) {
 
@@ -987,13 +1118,13 @@ export default {
                     this.OpHotelReservationsData.paymentCurrency = 836
                 }
             }
-            this.ctdIdPay = id
+            this.OpHotelReservationsData.cardPriceCurrency = id
 
             var cId = 0;
-            if (this.OpHotelReservationsData.ctdId == '74') {
+            if (this.OpHotelReservationsData.cardPriceCurrency == '74') {
                 this.CardCurrency = "USD(美元)"
                 cId = 950
-            } else if (this.OpHotelReservationsData.ctdId == '75') {
+            } else if (this.OpHotelReservationsData.cardPriceCurrency == '75') {
                 this.CardCurrency = "EUR(欧元)"
                 cId = 849
             } else {
@@ -1011,16 +1142,16 @@ export default {
             this.HotelConversionAmounts();
         },
         bankCardPriceChange() {
-            if (this.OpHotelReservationsData.ctdId != 0 && this.OpHotelReservationsData.ctdId != '' && this.OpHotelReservationsData.ctdId != undefined && (this.OpHotelReservationsData.governmentRent != 0 || this.OpHotelReservationsData.cityTax != 0)) {
+            if (this.OpHotelReservationsData.ctdId != 0 || this.OpHotelReservationsData.ctdId != '' || this.OpHotelReservationsData.ctdId != undefined || this.OpHotelReservationsData.governmentRent != 0 || this.OpHotelReservationsData.cityTax != 0) {
                 this.HotelConversionAmounts();
             }
         },
         HotelConversionAmounts() {
             var that = this
             var cardPriceCurrency = 0;
-            if (that.OpHotelReservationsData.ctdId == '74') {
+            if (that.OpHotelReservationsData.cardPriceCurrency == '74') {
                 cardPriceCurrency = 950
-            } else if (that.OpHotelReservationsData.ctdId == '75') {
+            } else if (that.OpHotelReservationsData.cardPriceCurrency == '75') {
                 cardPriceCurrency = 849
             } else {
                 cardPriceCurrency = 836
@@ -1058,15 +1189,18 @@ export default {
         },
         AddBtn() {
             var that = this
-            debugger
+            if (that.IsAuditGM == 1) {
+                that.$message.error('已通过审核,不可修改!');
+                return;
+            }
             that.$refs.OpHotelReservationsData.validate((valid) => {
                 if (valid) {
                     if (that.OpHotelReservationsData.paymentCurrency == '') {
                         that.OpHotelReservationsData.paymentCurrency = 0;
                     }
                     debugger
-                    if (that.ctdIdPay == '') {
-                        that.ctdIdPay = 0;
+                    if (that.OpHotelReservationsData.payDId == '') {
+                        that.OpHotelReservationsData.payDId = 72
                     }
                     if (that.OpHotelReservationsData.governmentRentCurrency == '') {
                         that.OpHotelReservationsData.governmentRentCurrency = 0;
@@ -1096,7 +1230,7 @@ export default {
                             })
                         }
 
-                        that.OpHotelReservationsData.ctdId = that.ctdIdPay;
+                        //that.OpHotelReservationsData.ctdId = that.ctdIdPay;
                         that.OpHotelReservationsData.createUserId = that.userId
                         var url = "/api/Groups/OpHotelReservations"
                         this.$axios({
@@ -1213,7 +1347,7 @@ export default {
                         }
                     })
                 }
-                that.ctdId = that.ctdIdPay;
+                //that.ctdId = that.ctdIdPay;
                 that.OpHotelReservationsData.createUserId = that.userId
                 that.OpHotelReservationsData.attachment = response.data
                 var url = "/api/Groups/OpHotelReservations"
@@ -1256,7 +1390,6 @@ export default {
                         }
                     })
                 }
-                that.ctdId = that.ctdIdPay;
                 that.OpHotelReservationsData.createUserId = that.userId
                 that.OpHotelReservationsData.attachment = ''
                 var url = "/api/Groups/OpHotelReservations"

+ 881 - 0
src/components/OP/OpCustomers.vue

@@ -0,0 +1,881 @@
+<template>
+    <div class="car_add">
+        <div>
+            <div class="communal-title">
+                <div>{{ title }}</div>
+            </div>
+        </div>
+        <hr style='background-color:#5555; height:1px; border:none;' />
+        <div>
+            <el-form :model="delegationInfo" label-width="100px" class="demo-ruleForm">
+                <div style="display: flex;">
+                    <div style="width: 25%;">
+                        <el-form-item label="团组名称:" label-width="160px">
+                            <el-select v-model="OpCustomersData.diId" clearable filterable placeholder="团组选择"
+                                :disabled="isShow" style="width: 220px;" @change="DiIdSelectChange">
+                                <el-option v-for="item in delegationInfoList" :key="item.id" :label="item.teamName"
+                                    :value="item.id">
+                                </el-option>
+                            </el-select>
+                        </el-form-item>
+                    </div>
+                    <div style="width: 25%;">
+                        <el-form-item label="团 号:" prop="tourCode" label-width="160px">
+                            <el-input placeholder="团号" v-model="delegationInfo.tourCode" :disabled="true">
+                            </el-input>
+                        </el-form-item>
+                    </div>
+                    <div style="width: 25%;">
+                        <el-form-item label="客户:" prop="clientName" label-width="160px">
+                            <el-input placeholder="客户" v-model="delegationInfo.clientName" :disabled="true">
+                            </el-input>
+                        </el-form-item>
+                    </div>
+                    <div style="width: 25%;">
+                        <el-form-item label="出访国家:" prop="visitCountry" label-width="160px">
+                            <el-input placeholder="出访国家" v-model="delegationInfo.visitCountry" :disabled="true">
+                            </el-input>
+                        </el-form-item>
+                    </div>
+                </div>
+                <div style="display: flex;">
+                    <div style="width: 25%;">
+                        <el-form-item label="出访时间:" label-width="160px">
+                            <el-input placeholder="出访时间" v-model="VisitDate" :disabled="true">
+                            </el-input>
+                        </el-form-item>
+                    </div>
+                    <div style="width: 25%;">
+                        <el-form-item label="出访人数:" label-width="160px">
+                            <el-input placeholder="出访人数" v-model="delegationInfo.visitPNumber" :disabled="true">
+                            </el-input>
+                        </el-form-item>
+                    </div>
+                    <div style="width: 25%;">
+                        <el-form-item label="出访天数:" label-width="160px">
+                            <el-input placeholder="出访天数" v-model="delegationInfo.visitDays" :disabled="true">
+                            </el-input>
+                        </el-form-item>
+                    </div>
+                </div>
+            </el-form>
+            <el-form :model="OpCustomersData" ref="OpCustomersData" :rules="OpCustomersDataRules" label-width="100px"
+                class="demo-ruleForm">
+                <div style="display: flex;">
+                    <div style="width: 25%;">
+                        <el-form-item label="保险名称:" prop="iid" label-width="160px">
+                            <el-select v-model="OpCustomersData.iid" filterable placeholder="保险名称" @change="iidChane">
+                                <el-option v-for="item in insuranceCostList" :key="item.id" :label="item.gName"
+                                    :value="item.id">
+                                </el-option>
+                            </el-select>
+                        </el-form-item>
+                    </div>
+                    <div style="width: 25%;">
+                        <el-form-item label="保险余额:" label-width="160px">
+                            <el-input placeholder="保险余额" v-model="Balance" :disabled="true">
+                            </el-input>
+                        </el-form-item>
+                    </div>
+                    <div style="width: 25%;">
+                        <el-form-item label="客户名称:" prop="clientName" label-width="160px">
+                            <el-input placeholder="客户名称" v-model="OpCustomersData.clientName">
+                            </el-input>
+                        </el-form-item>
+                    </div>
+                    <div style="width: 25%;">
+                        <el-form-item label="保险费用:" prop="insuranceCosts" label-width="160px">
+                            <el-input placeholder="保险费用" v-model="OpCustomersData.insuranceCosts" style="width: 50%;">
+                            </el-input>
+                            <el-select v-model="OpCustomersData.currency" filterable placeholder="币种" style="width: 40%;">
+                                <el-option v-for="item in currencyList" :key="item.currencyId" :label="item.currencyCode"
+                                    :value="item.currencyId">
+                                </el-option>
+                            </el-select>
+                        </el-form-item>
+                    </div>
+                </div>
+                <div style="display: flex;">
+                    <div style="width: 25%;">
+                        <el-form-item label="附件" prop="attachment" label-width="160px">
+
+                            <el-upload :file-list="uploadFiles" ref="upload" :on-success="upLoadSuccess"
+                                style="width: 200px;" :before-remove="beforeRemove" :limit="1" :on-exceed="exceed"
+                                :action="uploadURL" :headers="headers" :auto-upload="false" :on-change="onChange">
+                                <el-button slot="trigger" size="small" type="primary">选取文件</el-button>
+                                <!-- <el-button style="margin-left: 10px;" size="small" type="success"
+                                    @click="submitUpload">上传到服务器</el-button> -->
+                            </el-upload>
+
+                        </el-form-item>
+                    </div>
+                </div>
+                <div style="display: flex;">
+                    <div style="width: 81%;">
+                        <el-form-item label="备 注:" prop="Remark" label-width="160px">
+                            <el-input type="textarea" :rows="5" placeholder="备注"
+                                v-model="OpCustomersData.remark"></el-input>
+                        </el-form-item>
+                    </div>
+                </div>
+                <hr style='background-color:#5555; height:1px; border:none;margin-top: 10px;' />
+                <div style="display: flex;">
+                    <div style="width: 25%;">
+                        <el-form-item label="支付方式:" prop="payDId" label-width="160px">
+                            <el-select v-model="OpCustomersData.payDId" placeholder="支付方式" style="width: 100%;"
+                                @change="payChange">
+                                <el-option v-for="item in payment" :key="item.id" :label="item.name" :value="item.id">
+                                </el-option>
+                            </el-select>
+                        </el-form-item>
+                    </div>
+                    <div style="width: 25%;">
+                        <el-form-item label="消费方式:" prop="consumptionPatterns" label-width="160px">
+                            <el-input placeholder="消费方式" v-model="OpCustomersData.consumptionPatterns">
+                            </el-input>
+                        </el-form-item>
+                    </div>
+                    <div style="width: 25%;">
+                        <el-form-item label="消费日期:" prop="consumptionDate" label-width="160px">
+                            <el-date-picker v-model="OpCustomersData.consumptionDate" placeholder="消费日期" type="date">
+                            </el-date-picker>
+
+                        </el-form-item>
+                    </div>
+                    <div style="width: 25%;">
+                        <el-form-item label="付款金额:" prop="payMoney" label-width="160px">
+                            <el-input placeholder="付款金额" v-model="OpCustomersData.insuranceCosts" style="width: 52%;"
+                                :disabled="true">
+                            </el-input>
+                            <el-select v-model="OpCustomersData.currency" style="width: 45%;" :disabled="true">
+                                <el-option v-for="item in currencyList" :key="item.currencyId" :label="item.currencyCode"
+                                    :value="item.currencyId">
+                                </el-option>
+                            </el-select>
+                        </el-form-item>
+                    </div>
+                </div>
+                <div v-if="OpCustomersData.payDId == 72">
+                    <div style="display: flex;">
+                        <div style="width: 25%;">
+                            <el-form-item label="卡类型:" prop="ctdId" label-width="160px">
+                                <el-select v-model="OpCustomersData.ctdId" placeholder="卡类型" style="width: 100%;"
+                                    @change="ctdChange">
+                                    <el-option v-for="item in bankCard" :key="item.id" :label="item.name" :value="item.id">
+                                    </el-option>
+                                </el-select>
+                            </el-form-item>
+                        </div>
+                        <div style="width: 25%;">
+                            <el-form-item label="银行卡号:" prop="bankNo" label-width="160px">
+                                <el-input placeholder="银行卡号" v-model="OpCustomersData.bankNo" :disabled="true">
+                                </el-input>
+                            </el-form-item>
+                        </div>
+                        <div style="width: 25%;">
+                            <el-form-item label="持卡人姓名:" prop="cardholderName" label-width="160px">
+                                <el-input placeholder="持卡人姓名" v-model="OpCustomersData.cardholderName" :disabled="true">
+                                </el-input>
+                            </el-form-item>
+                        </div>
+                    </div>
+                </div>
+                <div v-else-if="OpCustomersData.payDId == 73">
+                    <div style="display: flex;">
+                        <div style="width: 25%;">
+                            <el-form-item label="公司银行账号:" label-width="160px" prop="companyBankNo">
+                                <el-input placeholder="公司银行账号" v-model="OpCustomersData.companyBankNo">
+                                </el-input>
+
+                            </el-form-item>
+                        </div>
+                        <div style="width: 25%;">
+                            <el-form-item label="对方开户行:" prop="otherBankName" label-width="160px">
+                                <el-input placeholder="对方开户行:" v-model="OpCustomersData.otherBankName">
+                                </el-input>
+                            </el-form-item>
+                        </div>
+                        <div style="width: 25%;">
+                            <el-form-item label="对方银行卡号:" prop="otherSideNo" label-width="160px">
+                                <el-input placeholder="对方银行卡号" v-model="OpCustomersData.otherSideNo">
+                                </el-input>
+                            </el-form-item>
+                        </div>
+                        <div style="width: 25%;">
+                            <el-form-item label="对方姓名:" prop="otherSideName" label-width="160px">
+                                <el-input placeholder="对方姓名" v-model="OpCustomersData.otherSideName">
+                                </el-input>
+                            </el-form-item>
+                        </div>
+                    </div>
+                </div>
+                <div v-else-if="OpCustomersData.payDId == 83">
+                    <div style="display: flex;">
+                        <div style="width: 25%;">
+                            <el-form-item label="对方开户行:" prop="otherBankName" label-width="160px">
+                                <el-input placeholder="对方开户行" v-model="OpCustomersData.otherBankName">
+                                </el-input>
+                            </el-form-item>
+                        </div>
+                        <div style="width: 25%;">
+                            <el-form-item label="对方银行卡号:" prop="otherSideNo" label-width="160px">
+                                <el-input placeholder="对方银行卡号" v-model="OpCustomersData.otherSideNo">
+                                </el-input>
+                            </el-form-item>
+                        </div>
+                        <div style="width: 25%;">
+                            <el-form-item label="对方姓名:" prop="otherSideName" label-width="160px">
+                                <el-input placeholder="对方姓名" v-model="OpCustomersData.otherSideName">
+                                </el-input>
+                            </el-form-item>
+                        </div>
+                    </div>
+                </div>
+                <div v-else></div>
+                <div style="display:flex;">
+                    <div style="width: 25%;">
+                        <el-form-item label="收款方:" prop="payee" label-width="160px">
+                            <el-input placeholder="对方姓名:" v-model="OpCustomersData.payee">
+                            </el-input>
+                        </el-form-item>
+                    </div>
+                    <div style="width: 25%;">
+                        <el-form-item label="费用标识:" prop="orbitalPrivateTransfer" label-width="160px">
+                            <el-select v-model="OpCustomersData.orbitalPrivateTransfer" placeholder="费用标识"
+                                style="width: 100%;">
+                                <el-option key="0" label="公转" :value=0>
+                                </el-option>
+                                <el-option key="1" label="私转" :value=1>
+                                </el-option>
+                            </el-select>
+                        </el-form-item>
+                    </div>
+                </div>
+                <div style="display: flex;">
+                    <div style="width: 100%;">
+                        <el-form-item label="备 注:" prop="Remark" label-width="160px">
+                            <el-input type="textarea" :rows="5" placeholder="备注"
+                                v-model="OpCustomersData.cRemark"></el-input>
+                        </el-form-item>
+                    </div>
+                </div>
+                <el-form-item>
+                    <div style="margin-left: 60%;">
+                        <el-button type="primary" @click="addBtn">保存</el-button>
+
+                        <el-button @click="EscAdd">取消</el-button>
+                    </div>
+                </el-form-item>
+            </el-form>
+        </div>
+    </div>
+</template>
+<script>
+import { dE } from '@fullcalendar/core/internal-common';
+export default {
+    data() {
+        return {
+            title: "新增保险费用",
+            token: '',
+            userId: 0,
+            id: '',
+            isShow: false,
+            uploadURL: "http://132.232.92.186:8888/api/Groups/UploadCus",
+            headers: {
+                Authorization: JSON.parse(localStorage.getItem('userinif')).token,
+            },
+            projectName: "",
+            uploadFiles: [],//上传的文件列表
+            DelfileName: "",
+            delegationInfo: {},
+            delegationInfoList: [],//团组下拉框
+            insuranceCostList: [],//保险类型下拉框
+            Balance: 0,//保险余额
+            currencyList: [],//币种下拉框
+            bankCard: [],//卡类型下拉框
+            payment: [],//支付方式下拉框
+            OpCustomersData: {
+                status: 0,
+                id: 0,
+                diId: 0,
+                iid: 2,
+                clientName: '',
+                insuranceCosts: 0,
+                currency: '',
+                attachment: '',
+                createUserId: 0,
+                remark: '',
+                payDId: 72,
+                consumptionPatterns: '',
+                consumptionDate: '',
+                ctdId: '',
+                companyBankNo: '',
+                otherBankName: '',
+                otherSideNo: '',
+                otherSideName: '',
+                bankNo: '',
+                cardholderName: '',
+                payee: '',
+                orbitalPrivateTransfer: 0,
+                cRemark: '',
+            },
+            IsAuditGM: 0,
+            VisitDate: '',
+            passengerTypeSelect: [],
+            dateFormat: function (value) {
+
+                // 将value转换为Date对象
+                var date = new Date(value);
+                // 获取年、月、日
+                var year = date.getFullYear();
+                var month = date.getMonth() + 1;
+                var day = date.getDate();
+                // 将月份和日期转换为两位数的格式
+
+                if (month < 10) {
+                    month = '0' + month;
+                }
+                if (day < 10) {
+                    day = '0' + day;
+                }
+                // 返回格式化后的日期字符串
+                return year + '-' + month + '-' + day;
+            },
+            OpCustomersDataRules: {
+                iid: [
+                    { required: true, message: '请选择保险名称', trigger: ['blur', 'change'] },
+                ],
+                clientName: [
+                    { required: true, message: '请输入客户名称', trigger: ['blur', 'change'] },
+                ],
+                insuranceCosts: [
+                    { required: true, message: '请输入费用金额', trigger: ['blur', 'change'] },
+                    { pattern: /^(([1-9]?\d{0,8}(\.\d{1,2})?)|999999999|999999999\.(0){1,2})$/, message: '请输入正确的金额(最多2位小数)' }
+                ],
+                currency: [
+                    { required: true, message: '请选择支付币种', trigger: ['blur', 'change'] },
+                ],
+                payDId: [
+                    { required: true, message: '请选择支付方式', trigger: ['blur', 'change'] },
+                ],
+                consumptionPatterns: [
+                    { required: true, message: '请输入消费方式', trigger: ['blur', 'change'] },
+                ],
+                consumptionDate: [
+                    { required: true, message: '请选择消费日期', trigger: ['blur', 'change'] },
+                ],
+                payee: [
+                    { required: true, message: '请输入收款方', trigger: ['blur', 'change'] },
+                ],
+                ctdId: [
+                    { required: true, message: '请选择卡类型', trigger: ['blur', 'change'] },
+                ],
+                companyBankNo: [{ required: true, message: '公司银行账号', trigger: ['blur', 'change'] },],
+                otherBankName: [{ required: true, message: '对方开户行', trigger: ['blur', 'change'] },],
+                otherSideNo: [{ required: true, message: '对方银行卡号', trigger: ['blur', 'change'] },],
+                totherSideName: [{ required: true, message: '对方姓名', trigger: ['blur', 'change'] },],
+            }
+        }
+    },
+    methods: {
+        //初始化下拉框
+        initializeSelect() {
+            //团组下拉框绑定
+            var url = "/api/Groups/DecreasePaymentsSelect"
+            var that = this
+            this.$axios({
+                method: 'post',
+                url: url,
+                headers: {
+                    Authorization: 'Bearer ' + this.token
+                },
+                data: {
+                    userId: that.userId,
+                    ctId: 82
+                }
+            }).then(function (res) {
+                if (res.data.code == 200) {
+                    debugger
+                    that.delegationInfoList = res.data.data.groupName
+                    that.payment = res.data.data.payment
+                    for (let index = 0; index < that.delegationInfoList.length; index++) {
+
+                        if (that.delegationInfoList[index].id == that.OpCustomersData.diId) {
+                            that.delegationInfo = that.delegationInfoList[index];
+                            that.OpCustomersData.diId = that.delegationInfo.id
+                            that.VisitDate = that.dateFormat(that.delegationInfo.visitStartDate) + '至' + that.dateFormat(that.delegationInfo.visitEndDate);
+                            var url = "/api/Groups/CustomersInitialize"
+                            that.$axios({
+                                method: 'post',
+                                url: url,
+                                headers: {
+                                    Authorization: 'Bearer ' + that.token
+                                },
+                                data: {
+                                    portType: 1,
+                                    diId: that.OpCustomersData.diId
+                                }
+                            }).then(function (res) {
+                                if (res.data.code == 200) {
+                                    that.insuranceCostList = res.data.data.insuranceCost;//保险类型下拉框
+                                    that.OpCustomersData.iid = that.insuranceCostList[0].id;
+                                    that.Balance = that.insuranceCostList[0].balance;
+                                    that.currencyList = res.data.data.currencyList;//币种下拉框
+                                    if (that.currencyList.length != 0) {
+                                        that.OpCustomersData.currency = that.currencyList[0].currencyId
+                                    }
+
+                                    that.bankCard = res.data.data.bankCard;//卡类型下拉框
+                                    that.payment = res.data.data.payment;//支付方式下拉框
+                                }
+                            })
+                            break;
+                        }
+                    }
+
+                }
+            })
+
+        },
+        DiIdSelectChange() {
+            var that = this;
+            for (let index = 0; index < that.delegationInfoList.length; index++) {
+                if (that.delegationInfoList[index].id == that.OpCustomersData.diId) {
+                    that.delegationInfo = that.delegationInfoList[index];
+
+                    that.VisitDate = that.dateFormat(that.delegationInfo.visitStartDate) + '至' + that.dateFormat(that.delegationInfo.visitEndDate);
+                    var url = "/api/Groups/CustomersInitialize"
+                    that.$axios({
+                        method: 'post',
+                        url: url,
+                        headers: {
+                            Authorization: 'Bearer ' + that.token
+                        },
+                        data: {
+                            portType: 1,
+                            diId: that.OpCustomersData.diId
+                        }
+                    }).then(function (res) {
+                        debugger
+                        if (res.data.code == 200) {
+                            that.insuranceCostList = res.data.data.insuranceCost;//保险类型下拉框
+                            that.OpCustomersData.iid = that.insuranceCostList[0].id;
+                            that.Balance = that.insuranceCostList[0].balance;
+                            that.currencyList = res.data.data.currencyList;//币种下拉框
+                            if (that.currencyList.length != 0) {
+                                debugger
+                                that.OpCustomersData.currency = that.currencyList[0].currencyId
+                            }
+                            that.bankCard = res.data.data.bankCard;//卡类型下拉框
+                            that.payment = res.data.data.payment;//支付方式下拉框
+                        }
+                    })
+                    break;
+                }
+            }
+            that.$nextTick(() => {
+                that.$refs.OpCustomersData.clearValidate();
+            })
+        },
+        iidChane(row) {
+            debugger
+            for (let index = 0; index < this.insuranceCostList.length; index++) {
+                if (this.insuranceCostList[index].id == row) {
+                    this.Balance = this.insuranceCostList[index].balance;
+                    break;
+                }
+            }
+
+        },
+        payChange() {
+            this.OpCustomersData.ctdId = '';
+            this.OpCustomersData.bankNo = '';
+            this.OpCustomersData.cardholderName = '';
+            this.OpCustomersData.companyBankNo = '';
+            this.OpCustomersData.otherBankName = '';
+            this.OpCustomersData.otherSideNo = '';
+            this.OpCustomersData.otherSideName = '';
+            this.OpCustomersData.cRemark = '';
+            if (this.OpCustomersData.payDId == 73) {
+                this.OpCustomersDataRules.companyBankNo = [{ required: true, message: '公司银行账号', trigger: ['blur', 'change'] },]
+                this.OpCustomersDataRules.otherBankName = [{ required: true, message: '对方开户行', trigger: ['blur', 'change'] },]
+                this.OpCustomersDataRules.otherSideNo = [{ required: true, message: '对方银行卡号', trigger: ['blur', 'change'] },]
+                this.OpCustomersDataRules.otherSideName = [{ required: true, message: '对方姓名', trigger: ['blur', 'change'] },]
+                this.OpCustomersDataRules.ctdId = []
+            } else if (this.OpCustomersData.payDId == 72) {
+                this.OpCustomersDataRules.ctdId = [{ required: true, message: '请选择卡类型', trigger: ['blur', 'change'] },]
+                this.OpCustomersDataRules.companyBankNo = []
+                this.OpCustomersDataRules.otherBankName = []
+                this.OpCustomersDataRules.otherSideNo = []
+                this.OpCustomersDataRules.otherSideName = []
+            } else if (this.OpCustomersData.payDId == 83) {
+                this.OpCustomersDataRules.companyBankNo = []
+                this.OpCustomersDataRules.otherBankName = [{ required: true, message: '对方开户行', trigger: ['blur', 'change'] },]
+                this.OpCustomersDataRules.otherSideNo = [{ required: true, message: '对方银行卡号', trigger: ['blur', 'change'] },]
+                this.OpCustomersDataRules.otherSideName = [{ required: true, message: '对方姓名', trigger: ['blur', 'change'] },]
+                this.OpCustomersDataRules.ctdId = []
+            } else {
+                this.OpCustomersDataRules.companyBankNo = []
+                this.OpCustomersDataRules.otherBankName = []
+                this.OpCustomersDataRules.otherSideNo = []
+                this.OpCustomersDataRules.otherSideName = []
+                this.OpCustomersDataRules.ctdId = []
+            }
+            this.$nextTick(() => {
+                this.$refs.OpCustomersData.clearValidate();
+            })
+        },
+        ctdChange(id) {
+            this.OpCustomersData.cardholderName = 'Zhang Hailin';
+            for (var i = 0; i < this.bankCard.length; i++) {
+                if (this.bankCard[i].id == parseInt(id)) {
+                    this.OpCustomersData.bankNo = this.bankCard[i].remark
+                }
+            }
+        },
+        //根据Id获取单挑数据及C表数据
+        QueryCustomersById() {
+            var url = "/api/Groups/CustomersById"
+            var that = this
+            this.$axios({
+                method: 'post',
+                url: url,
+                headers: {
+                    Authorization: 'Bearer ' + this.token
+                },
+                data: {
+                    id: that.OpCustomersData.id
+                }
+            }).then(function (res) {
+                if (res.data.code == 200) {
+                    debugger
+                    var CreditCardPayment = res.data.data.creditCard;
+                    var Customers = res.data.data.customers;
+                    that.IsAuditGM = CreditCardPayment.isAuditGM;
+                    that.OpCustomersData.iid = Customers.iid
+                    for (let index = 0; index < that.insuranceCostList.length; index++) {
+                        if (that.insuranceCostList[index].id == that.OpCustomersData.iid) {
+                            that.Balance = that.insuranceCostList[index].balance;
+                            break;
+                        }
+                    }
+                    that.OpCustomersData.clientName = Customers.clientName
+                    that.OpCustomersData.insuranceCosts = Customers.insuranceCosts
+                    that.OpCustomersData.currency = Customers.currency
+                    that.OpCustomersData.attachment = Customers.attachment
+                    that.uploadFiles = []
+                    if (that.OpCustomersData.attachment != null && that.OpCustomersData.attachment != undefined && that.OpCustomersData.attachment != "") {
+                        that.uploadFiles.push({
+                            name: that.OpCustomersData.attachment,
+                            url: 'http://132.232.92.186:24/Office/GrpFile/保险费用文件上传/',
+                        })
+                    }
+                    that.OpCustomersData.remark = Customers.remark
+                    that.OpCustomersData.payDId = CreditCardPayment.payDId;
+                    that.OpCustomersData.consumptionPatterns = CreditCardPayment.consumptionPatterns;
+                    that.OpCustomersData.consumptionDate = CreditCardPayment.consumptionDate;
+                    that.OpCustomersData.ctdId = CreditCardPayment.ctdId;
+                    that.OpCustomersData.bankNo = CreditCardPayment.bankNo;
+                    that.OpCustomersData.cardholderName = CreditCardPayment.cardholderName;
+                    that.OpCustomersData.companyBankNo = CreditCardPayment.companyBankNo
+                    that.OpCustomersData.otherBankName = CreditCardPayment.otherBankName
+                    that.OpCustomersData.otherSideNo = CreditCardPayment.otherSideNo
+                    that.OpCustomersData.otherSideName = CreditCardPayment.otherSideName
+                    that.OpCustomersData.payee = CreditCardPayment.payee;
+                    that.OpCustomersData.orbitalPrivateTransfer = CreditCardPayment.orbitalPrivateTransfer;
+                    that.OpCustomersData.cRemark = CreditCardPayment.remark;
+                }
+            })
+        },
+        addBtn() {
+            if (this.IsAuditGM == 1) {
+                this.$message.error('已通过审核,不可修改!');
+            } else {
+                if (this.OpCustomersData.diId == null && this.OpCustomersData.diId == undefined && this.OpCustomersData.diId == "") {
+                    this.$message.error("请选择团组名称");
+                    return;
+                } else {
+                    const that = this;
+                    that.$refs.OpCustomersData.validate((valid) => {
+                        if (valid) {
+                            if (that.projectName != "" && that.projectName != null && that.projectName != undefined) {
+                                that.$refs.upload.submit();//上传文件到服务器
+                            } else {
+                                if (that.DelfileName != null && that.DelfileName != "" && that.DelfileName != undefined) {
+                                    that.$axios({
+                                        method: 'post',
+                                        url: "/api/Groups/DelFileCus",
+                                        headers: {
+                                            Authorization: 'Bearer ' + that.token
+                                        },
+                                        data: {
+                                            fileName: that.DelfileName,
+                                            id: that.OpCustomersData.id
+                                        }
+                                    }).then(function (res) {
+                                    })
+                                }
+
+                                debugger
+                                that.OpCustomersData.createUserId = that.userId;
+                                if (that.OpCustomersData.ctdId == '') {
+                                    that.OpCustomersData.ctdId = 0
+                                }
+
+                                var url = "/api/Groups/OpCustomers"
+                                that.$axios({
+                                    method: 'post',
+                                    url: url,
+                                    headers: {
+                                        Authorization: 'Bearer ' + that.token
+                                    },
+                                    data: that.OpCustomersData
+                                }).then(function (res) {
+                                    if (res.data.code == 200) {
+                                        that.$message({
+                                            message: res.data.msg,
+                                            type: 'success'
+                                        });
+                                        that.loading = true;
+                                        setTimeout(() => {
+                                            that.$router.push({
+                                                path: "/home/Customers",
+                                                query: {
+                                                    diId: that.OpCustomersData.diId
+                                                }
+                                            })
+                                        }, 3000);
+                                    } else {
+                                        that.$message.error(res.data.msg);
+                                    }
+                                })
+                            }
+
+                        } else {
+                            this.$message.error('请完善信息在保存!');
+                            return false;
+                        }
+                    })
+                }
+            }
+        },
+        //上传
+        // 文件超出限制
+        exceed(files, fileList) {
+            this.$message.warning(
+                `当前限制选择 1个文件,本次选择了 ${files.length} 个文件,共选择了 ${files.length + fileList.length
+                } 个文件,请取消要替换的文件`
+            );
+        },
+        //文件上传成功时的钩子
+        upLoadSuccess(response, file, fileList) {
+            var that = this;
+            if (response.code == 200) {
+                if (that.DelfileName != null && that.DelfileName != "" && that.DelfileName != undefined) {
+                    that.$axios({
+                        method: 'post',
+                        url: "/api/Groups/DelFileCus",
+                        headers: {
+                            Authorization: 'Bearer ' + that.token
+                        },
+                        data: {
+                            fileName: that.DelfileName,
+                            id: that.id
+                        }
+                    }).then(function (res) {
+                        if (res.data.code == 200) {
+
+                        }
+                    })
+                }
+                //that.ctdId = that.ctdIdPay;
+                that.OpCustomersData.createUserId = that.userId;
+                that.OpCustomersData.attachment = that.projectName;
+                if (that.OpCustomersData.ctdId == '') {
+                    that.OpCustomersData.ctdId = 0
+                }
+
+                var url = "/api/Groups/OpCustomers"
+                that.$axios({
+                    method: 'post',
+                    url: url,
+                    headers: {
+                        Authorization: 'Bearer ' + that.token
+                    },
+                    data: that.OpCustomersData
+                }).then(function (res) {
+                    if (res.data.code == 200) {
+                        that.$message({
+                            message: res.data.msg,
+                            type: 'success'
+                        });
+                        that.loading = true;
+                        setTimeout(() => {
+                            that.$router.push({
+                                path: "/home/Customers",
+                                query: {
+                                    diId: that.OpCustomersData.diId
+                                }
+                            })
+                        }, 3000);
+                    } else {
+                        that.$message.error(res.data.msg);
+                    }
+                })
+
+            } else {
+                if (that.DelfileName != null && that.DelfileName != "" && that.DelfileName != undefined) {
+                    that.$axios({
+                        method: 'post',
+                        url: "/api/Groups/DelFile",
+                        headers: {
+                            Authorization: 'Bearer ' + that.token
+                        },
+                        data: {
+                            fileName: that.DelfileName,
+                            id: that.OpCustomersData.id
+                        }
+                    }).then(function (res) {
+                        if (res.data.code == 200) {
+
+                        }
+                    })
+                }
+                that.OpCustomersData.createUserId = that.userId;
+                if (that.OpCustomersData.ctdId == '') {
+                    that.OpCustomersData.ctdId = 0
+                }
+
+                var url = "/api/Groups/OpCustomers"
+                that.$axios({
+                    method: 'post',
+                    url: url,
+                    headers: {
+                        Authorization: 'Bearer ' + that.token
+                    },
+                    data: that.OpCustomersData
+                }).then(function (res) {
+                    if (res.data.code == 200) {
+                        that.$message({
+                            message: res.data.msg,
+                            type: 'success'
+                        });
+                        that.loading = true;
+                        setTimeout(() => {
+                            that.$router.push({
+                                path: "/home/Customers",
+                                query: {
+                                    diId: that.OpCustomersData.diId
+                                }
+                            })
+                        }, 3000);
+                    } else {
+                        that.$message.error(res.data.msg);
+                    }
+                })
+            }
+
+        },
+
+        beforeRemove(file, fileList) {
+
+            console.log(file.name)
+            let id1 = this.uploadFiles.findIndex(item => {
+                if (item.name == file.name) {
+                    return true
+                }
+            })
+            this.uploadFiles.splice(id1, 1)
+            this.projectName = ""
+            this.DelfileName = file.name
+        },
+        onChange(file, fileList) {
+
+            this.projectName = file.name
+        },
+        EscAdd() {
+            this.$router.push({
+                path: "/home/Customers",
+                query: {
+                    diId: this.OpCustomersData.diId
+                }
+            })
+        }
+    },
+
+    mounted() {
+        this.token = JSON.parse(localStorage.getItem('userinif')).token;
+        this.userId = JSON.parse(localStorage.getItem('userinif')).userInfo.userId
+        this.initializeSelect();
+        this.OpCustomersData.diId = parseInt(this.$route.query.DiId)
+        this.OpCustomersData.id = this.$route.query.id
+        debugger
+        if (this.OpCustomersData.id != null && this.OpCustomersData.id != undefined && this.OpCustomersData.id != 0) {
+            this.QueryCustomersById();
+            this.title = "修改保险费用";
+            this.OpCustomersData.status = 2
+            this.isShow = true
+        } else {
+            this.OpCustomersData.status = 1
+            this.title = "新增保险费用"
+            this.isShow = false
+        }
+
+    }
+}
+</script>
+<style>
+.communal-list {
+    background-color: #fff;
+    padding: 10px;
+    box-shadow: 0 0 5px #0005;
+    border-radius: 10px;
+}
+
+.car_add .communal-title {
+    display: flex;
+    font-size: 17px;
+    font-weight: 600;
+    color: #555;
+    margin-bottom: 20px;
+    justify-content: space-between;
+    align-items: center;
+}
+
+.appraise-box {
+    display: flex;
+    flex-wrap: wrap;
+    justify-content: space-between;
+    margin: 50px 0;
+}
+
+.appraise-box>div {
+    width: 30%;
+}
+
+.communal-box {
+    display: flex;
+}
+
+.communal-box>button {
+    margin-left: 10px;
+    padding: 8px 20px;
+}
+
+.car_add {
+    background-color: #fff;
+    padding: 20px;
+    box-shadow: 0 0 5px #0005;
+    border-radius: 10px;
+}
+
+@media screen and (max-width: 1700px) {
+    .appraise-box>div {
+        width: 48%;
+    }
+
+    .appraise-box>div el-form-item__content {
+        width: 260px !important;
+    }
+}
+</style>

+ 2 - 2
src/components/OP/OpVisaPriec.vue

@@ -500,8 +500,8 @@ export default {
                 }
             }).then(function (res) {
                 if (res.data.code == 200) {
-                    var CreditCardPayment = res.data.data._CreditCardPayment;
-                    var VisaInfo = res.data.data._VisaInfo;
+                    var CreditCardPayment = res.data.data.creditCardPayment;
+                    var VisaInfo = res.data.data.visaInfo;
                     that.IsAuditGM = CreditCardPayment.isAuditGM;
                     that.OpVisaPriceData.visaClient = VisaInfo.visaClient;
                     that.OpVisaPriceData.visaPrice = VisaInfo.visaPrice;

+ 2 - 0
src/components/home.vue

@@ -218,6 +218,7 @@ export default {
     },
     toURLs(val, item) {
       console.log(val)
+      // localStorage.setItem('userinif', JSON.stringify(res.data.data));
       console.log(item)
       localStorage.setItem("indexs", val);
       localStorage.setItem("innhtml", item.pageList[0].pageName);
@@ -226,6 +227,7 @@ export default {
     },
     toURL(val, item) {
       console.log(val)
+      console.log(item)
       localStorage.setItem("indexs", val);
       localStorage.setItem("innhtml", item.pageName);
       this.$router.push({ path: "/home" + item.webUrl });

+ 1 - 1
src/main.js

@@ -20,7 +20,7 @@ Vue.use(VueQuillEditor);
 Vue.use(VueTypedJs)
 import axios from 'axios';
 axios.defaults.baseURL = 'http://132.232.92.186:8888';
-// axios.defaults.baseURL = 'http://localhost:5256/';
+//axios.defaults.baseURL = 'http://localhost:5256/';
 import { Message } from "element-ui";
 
 import common from './assets/js/common'//全局

+ 20 - 1
src/router/index.js

@@ -88,6 +88,9 @@ import CarTouristGuideGrounContent from '@/components/OP/CarTouristGuideGrounCon
 import PayReceived from '@/components/Finance/PayReceived';
 import LncomingBills from '@/components/Finance/LncomingBills';
 import GroupStatus from '@/components/Finance/GroupStatus';
+import Sendack from '@/components/Finance/Sendack';
+import Customers from '@/components/OP/Customers';
+import OpCustomers from '@/components/OP/OpCustomers';
 
 
 Vue.use(Router)
@@ -516,7 +519,23 @@ export default new Router({
           path: '/home/GroupStatus',
           name: 'GroupStatus',
           component: GroupStatus
-        }
+        },
+        {
+          path: '/home/Sendack',
+          name: 'Sendack',
+          component: Sendack
+        },
+        {
+          path: '/home/Customers',
+          name: 'Customers',
+          component: Customers
+        },
+        {
+          path: '/home/OpCustomers',
+          name: 'OpCustomers',
+          component: OpCustomers
+        },
+
       ]
     },
     {