yuanrf 2 роки тому
батько
коміт
27ea6f5abf

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

@@ -215,8 +215,8 @@ export default {
         }
     },
     methods:{
-         //每页条数改变时触发 选择一页显示多少行
-         handleSizeChange(val) {
+        //每页条数改变时触发 选择一页显示多少行
+        handleSizeChange(val) {
             this.currentPage = 1;
             this.pageSize = val;
         },

+ 224 - 0
src/components/OP/visaEdit.vue

@@ -0,0 +1,224 @@
+<template>
+    <div class="visaedit-box">
+        <div class="visaedit-title">
+            添加团组客户资料
+        </div>
+        <div class="small-title">
+            <span>基础信息</span>
+        </div>
+        <div class="tips">
+            姓名等需要与护照所示一致;曾用姓名包括未婚时称呼、宗教用称呼、工作用称呼、化名
+        </div>
+        <div class="foundation-form">
+            <el-form :model="ruleForm" :rules="rules" ref="ruleForm" label-width="100px" class="demo-ruleForm">
+                <div class="foundation-box">
+                    <el-form-item label="姓:" prop="name">
+                        <el-input v-model="ruleForm.name"></el-input>
+                    </el-form-item>
+                    <el-form-item label="名:" prop="name">
+                        <el-input v-model="ruleForm.name"></el-input>
+                    </el-form-item>
+                    <el-form-item label="曾用姓名:" prop="name">
+                        <el-input v-model="ruleForm.name"></el-input>
+                    </el-form-item>
+                    <el-form-item label="移动电话:" prop="name">
+                        <el-input v-model="ruleForm.name"></el-input>
+                    </el-form-item>
+                    <el-form-item label="身份证号" prop="name">
+                        <el-input v-model="ruleForm.name"></el-input>
+                    </el-form-item>
+                    <el-form-item label="身份证地址" prop="name">
+                        <el-input v-model="ruleForm.name"></el-input>
+                    </el-form-item>
+                    <el-form-item label="护照号:" prop="name">
+                        <el-input v-model="ruleForm.name"></el-input>
+                    </el-form-item>
+                    <el-form-item label="婚姻状况:" prop="name">
+                        <el-input v-model="ruleForm.name" placeholder="(已婚/单身(未婚)/丧偶/离异/分居)"></el-input>
+                    </el-form-item>
+                    <el-form-item label="证件有效期:" prop="name">
+                        <el-input v-model="ruleForm.name" placeholder="身份证有效期"></el-input>
+                    </el-form-item>
+                    <el-form-item label="至:" prop="name">
+                        <el-input v-model="ruleForm.name"></el-input>
+                    </el-form-item>
+                    <el-form-item label="护照号:" prop="name">
+                        <el-input v-model="ruleForm.name"></el-input>
+                    </el-form-item>
+                    <el-form-item label="国籍:" prop="name">
+                        <el-input v-model="ruleForm.name"></el-input>
+                    </el-form-item>
+                    <el-form-item label="性别" prop="resource">
+                        <el-radio-group v-model="ruleForm.resource">
+                            <el-radio label="男"></el-radio>
+                            <el-radio label="女"></el-radio>
+                        </el-radio-group>
+                    </el-form-item>
+                    <el-form-item label="出生地 城市:" prop="name">
+                        <el-input v-model="ruleForm.name"></el-input>
+                    </el-form-item>
+                    <el-form-item label="省份:" prop="name">
+                        <el-input v-model="ruleForm.name"></el-input>
+                    </el-form-item>
+                    <el-form-item label="出生日期:" prop="name">
+                        <el-input v-model="ruleForm.name"></el-input>
+                    </el-form-item>
+                    <el-form-item label="最高学历:" prop="name">
+                        <el-input v-model="ruleForm.name"></el-input>
+                    </el-form-item>
+                    <el-form-item label="家庭电话:" prop="name">
+                        <el-input v-model="ruleForm.name" placeholder="(座机)"></el-input>
+                    </el-form-item>
+                    <el-form-item label="电子信箱:" prop="name">
+                        <el-input v-model="ruleForm.name"></el-input>
+                    </el-form-item>
+                    <el-form-item label="现居地址:" prop="name">
+                        <el-input v-model="ruleForm.name" placeholder="(国家-省-市-街道-单元-门牌号)"></el-input>
+                    </el-form-item>
+                    <el-form-item label="邮编:" prop="name">
+                        <el-input v-model="ruleForm.name"></el-input>
+                    </el-form-item>
+                </div>
+            </el-form>
+        </div>
+        <div class="small-title">
+            现就职单位
+        </div>
+        <div class="flats-form">
+            <el-form :model="ruleForm" :rules="rules" ref="ruleForm" label-width="100px" class="demo-ruleForm">
+                <div class="foundation-box">
+                    <el-form-item label="单位名称:" prop="name">
+                        <el-input v-model="ruleForm.name"></el-input>
+                    </el-form-item>
+                    <el-form-item label="单位地址:" prop="name">
+                        <el-input v-model="ruleForm.name"></el-input>
+                    </el-form-item>
+                    <el-form-item label="单位邮编:" prop="name">
+                        <el-input v-model="ruleForm.name"></el-input>
+                    </el-form-item>
+                    <el-form-item label="职务:" prop="name">
+                        <el-input v-model="ruleForm.name"></el-input>
+                    </el-form-item>
+                    <el-form-item label="入职时间" prop="name">
+                        <el-input v-model="ruleForm.name" placeholder="(注明年月日)"></el-input>
+                    </el-form-item>
+                    <el-form-item label="月薪" prop="name">
+                        <el-input v-model="ruleForm.name" placeholder="(人民币)"></el-input>
+                    </el-form-item>
+                    <el-form-item label="单位电话:" prop="name">
+                        <el-input v-model="ruleForm.name"></el-input>
+                    </el-form-item>
+                    <el-form-item label="单位传真:" prop="name">
+                        <el-input v-model="ruleForm.name"></el-input>
+                    </el-form-item>
+                    <el-form-item label="单位邮箱:" prop="name">
+                        <el-input v-model="ruleForm.name"></el-input>
+                    </el-form-item>
+                    <el-form-item label="单位主管:" prop="name">
+                        <el-input v-model="ruleForm.name" placeholder="姓名:(除本人以外)"></el-input>
+                    </el-form-item>
+                </div>
+            </el-form>
+        </div>
+    </div>
+</template>
+
+<script>
+export default {
+    data() {
+      return {
+        ruleForm: {
+          name: '',
+          region: '',
+          date1: '',
+          date2: '',
+          delivery: false,
+          type: [],
+          resource: '',
+          desc: ''
+        },
+        rules: {
+          name: [
+            { required: true, message: '请输入活动名称', trigger: 'blur' },
+            { min: 3, max: 5, message: '长度在 3 到 5 个字符', trigger: 'blur' }
+          ],
+          region: [
+            { required: true, message: '请选择活动区域', trigger: 'change' }
+          ],
+          date1: [
+            { type: 'date', required: true, message: '请选择日期', trigger: 'change' }
+          ],
+          date2: [
+            { type: 'date', required: true, message: '请选择时间', trigger: 'change' }
+          ],
+          type: [
+            { type: 'array', required: true, message: '请至少选择一个活动性质', trigger: 'change' }
+          ],
+          resource: [
+            { required: true, message: '请选择活动资源', trigger: 'change' }
+          ],
+          desc: [
+            { required: true, message: '请填写活动形式', trigger: 'blur' }
+          ]
+        }
+      };
+    },
+    methods: {
+      submitForm(formName) {
+        this.$refs[formName].validate((valid) => {
+          if (valid) {
+            alert('submit!');
+          } else {
+            console.log('error submit!!');
+            return false;
+          }
+        });
+      },
+      resetForm(formName) {
+        this.$refs[formName].resetFields();
+      }
+    }
+}
+</script>
+<style>
+    .visaedit-box{
+        background-color: #fff;
+        padding: 10px;
+        box-shadow: 0 0 5px #0005;
+        border-radius: 10px;
+    }
+    .visaedit-title{
+        display: flex;
+        font-size: 17px;
+        font-weight:600 ;
+        color: #555;
+        margin-top: 8px;
+        margin-bottom: 2px;
+        justify-content: space-between;
+        align-items: center;
+    }
+    .tips{
+        margin-bottom: 10px;
+        font-size: 12px;
+        color: #555;
+    }
+    .foundation-box{
+        display: flex;
+        flex-wrap: wrap;
+    }
+    .foundation-box .el-form-item{
+        width: 25%;
+    }
+    .small-title{
+        font-size: 14px;
+        font-weight:600 ;
+        color: #555;
+        margin: 10px 0;
+    }
+    .small-title>span{
+        display: inline;
+        padding: 5px 10px;
+        border: 1px solid #606266;
+        border-radius: 5px;
+    }
+</style>

+ 404 - 4
src/components/OP/visaform.vue

@@ -1,14 +1,414 @@
 <template>
-    <div>
-        
+    <div class="visa-box">
+        <div class="search-ul">
+            <div class="search-li">
+                <el-select @change="changeOption()" v-model="gnamevalue" filterable placeholder="请输入团组名称">
+                    <el-option
+                    v-for="item in gnameoption"
+                    :key="item.id"
+                    :label="item.groupName"
+                    :value="item.id">
+                    </el-option>
+                </el-select>
+            </div>
+            <div class="search-li">
+                <div class="country-box">
+                    <label>签证表国别:</label>
+                    <el-select v-model="groupvalues" filterable placeholder="请选择">
+                        <el-option
+                        v-for="item in optionsgroup"
+                        :key="item.id"
+                        :label="item.name"
+                        :value="item.id">
+                        </el-option>
+                    </el-select>
+                </div>
+                <div class="interpret-box">
+                    <label>翻译语种:</label>
+                    <el-select v-model="value" filterable placeholder="请选择">
+                        <el-option
+                        v-for="item in options"
+                        :key="item.value"
+                        :label="item.label"
+                        :value="item.value">
+                        </el-option>
+                    </el-select>
+                </div>
+                <el-button type="primary">新增数据</el-button>
+                <el-button type="primary">新增简单数据</el-button>
+            </div>
+        </div>
+        <el-row>
+            <el-button type="primary">一键导出签证</el-button>
+            <el-button type="primary">一键导省外办</el-button>
+            <el-button type="primary">一键导市外办</el-button>
+            <el-button type="primary">签证事项表</el-button>
+            <el-button type="primary">照 会</el-button>
+            <el-button type="primary">印度名单表</el-button>
+            <el-button type="primary">马来西亚名单表</el-button>
+          </el-row>
+        <div class="form-box">
+            <template>
+                <el-table
+                :data="tableData.slice((currentPage-1)*pageSize,currentPage*pageSize)"
+                border
+                style="width: 100%">
+                    <el-table-column
+                        label="序 号"
+                        width="55">
+                        <template slot-scope="scope">
+                            {{(currentPage - 1) * pageSize + scope.$index + 1}}
+                        </template>
+                    </el-table-column>
+                    <el-table-column
+                        prop="clientName"
+                        width="200"
+                        label="姓 名">
+                    </el-table-column>
+                    <el-table-column
+                        prop="tel"
+                        label="手 机"
+                        width="220">
+                    </el-table-column>
+                    <el-table-column
+                        prop="cerdNo"
+                        label="身份证"
+                        width="200">
+                    </el-table-column>
+                    <el-table-column
+                        prop="ext"
+                        label="签证表"
+                        width="100">
+                        <el-link type="primary">导 出</el-link>
+                    </el-table-column>
+                    <el-table-column
+                        prop="phone"
+                        label="派遣函"
+                        width="200">
+                        <el-link type="primary">市外办</el-link>
+                        <el-link type="primary">省外办</el-link>
+                    </el-table-column>
+                    <el-table-column
+                        prop="urgentPhone"
+                        label="操 作">
+                        <el-link type="primary">检索资料</el-link>
+                        <el-link type="primary">美加表</el-link>
+                        <el-link type="primary">非美加表</el-link>
+                        <el-link type="danger">删除</el-link>
+                    </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,15,20]" 
+                    :page-size="pageSize" 
+                    layout="total, sizes, prev, pager, next" 
+                    :total="tableData.length">
+                </el-pagination>
+            </div>
+        </div>
+        <div class="form-box">
+            <div class="visas-title">
+                <div>历史用户信息处</div>
+                <div class="visas-box">
+                    <el-input
+                        @input="clickUsers()"
+                        placeholder="请输入内容"
+                        v-model="input"
+                        clearable>
+                    </el-input>
+                    <el-button @click="Inquireclick()" type="primary">勾选项入团</el-button>
+                </div>
+            </div>
+            <template>
+                <el-table
+                :data="externalDatas.slice((currentPageUser-1)*pageSizeUser,currentPageUser*pageSizeUser)"
+                border
+                tooltip-effect="dark"
+                ref="multipleTable"
+                :row-key="getRowKeys"
+                @selection-change="handleSelectionChange"
+                style="width: 100%">
+                    <el-table-column
+                    :reserve-selection="true"
+                    type="selection"
+                    width="55">
+                    </el-table-column>
+                    <el-table-column
+                        label="序 号"
+                        width="55">
+                        <template slot-scope="scope">
+                            {{(currentPage - 1) * pageSize + scope.$index + 1}}
+                        </template>
+                    </el-table-column>
+                    <el-table-column
+                        width="100" 
+                        prop="clientName"
+                        label="姓 名">
+                    </el-table-column>
+                    <el-table-column
+                        prop="landlinePhone"
+                        label="手 机"
+                        width="180">
+                    </el-table-column>
+                    <!-- <el-table-column
+                        prop="companyName"
+                        label="地 址"
+                        width="180">
+                    </el-table-column> -->
+                    <el-table-column
+                        prop="idNo"
+                        label="身份证"
+                        width="250">
+                    </el-table-column>
+                    <el-table-column
+                        prop="urgentPhone"
+                        label="操 作">
+                        <el-link type="primary">增加入此团</el-link>
+                        <el-link type="danger">删除</el-link>
+                    </el-table-column>
+                </el-table>
+            </template>
+            <div class="block">
+                <el-pagination align='center' 
+                    @size-change="handleSizeChanges" 
+                    @current-change="handleCurrentChanges"
+                    :current-page="currentPageUser" 
+                    :page-sizes="[5,10,15,20]" 
+                    :page-size="pageSizeUser" 
+                    layout="total, sizes, prev, pager, next" 
+                    :total="externalDatas.length">
+                </el-pagination>
+            </div>
+        </div>
     </div>
 </template>
 
 <script>
 export default {
-    
+    data() {
+        return {
+            input: '',
+            gnameoption:[],
+            gnamevalue:'',
+            externalData:[],
+            externalDatas:[],
+            optionsgroup:[],
+            options: [
+                {
+                    value: '0',
+                    label: '中文'
+                }, 
+                {
+                    value: '1',
+                    label: '英语'
+                }
+            ],
+            groupvalues:'',
+            value: '0',
+            tableData: [],
+            currentPage: 1, // 当前页码
+            pageSize: 5 ,// 每页的数据条数
+            currentPageUser: 1, // 当前页码
+            pageSizeUser: 5 ,// 每页的数据条数
+            multipleTable:[],
+            token:''
+        }
+    },
+    methods:{
+        //每页条数改变时触发 选择一页显示多少行
+        handleSizeChange(val) {
+            this.currentPage = 1;
+            this.pageSize = val;
+        },
+        //当前页改变时触发 跳转其他页
+        handleCurrentChange(val) {
+            this.currentPage = val;
+        },
+        //每页条数改变时触发 选择一页显示多少行
+        handleSizeChanges(val) {
+            this.currentPageUser = 1;
+            this.pageSizeUser = val;
+        },
+        //当前页改变时触发 跳转其他页
+        handleCurrentChanges(val) {
+            this.currentPageUser = val;
+        },
+        handleSelectionChange(val) {
+            this.multipleSelection = val;
+            console.log(this.multipleSelection)
+        },
+        getRowKeys(row) {
+            return row.num
+        },
+        getgroupsname(){
+            var url="/api/Groups/GetGroupNameAndVisaNationality"
+            var that=this
+            this.$axios({
+                method: 'post',
+                url:url,
+                headers:{
+                    Authorization:'Bearer '+this.token
+                },
+                data:{
+                    portType: 1,
+                }
+            }).then(function(res){
+                console.log(res)
+                if(res.data.code==200){
+                    that.gnameoption=res.data.data.groupNameData;
+                    that.gnamevalue=that.gnameoption[0].id;
+                    that.optionsgroup=res.data.data.visaNationalityData;
+                    that.groupvalues=that.optionsgroup[0].id;
+                }
+                that.getCrm()
+            })
+        },
+        getCrm(){
+            this.tableData=[];
+            var url="/api/Groups/GetCrmByGroupId"
+            var that=this
+            this.$axios({
+                method: 'post',
+                url:url,
+                headers:{
+                    Authorization:'Bearer '+this.token
+                },
+                data:{
+                    portType: 1,
+                    groupId:that.gnamevalue
+                }
+            }).then(function(res){
+                console.log(res)
+                if(res.data.code==200){
+                   that.tableData=res.data.data;
+                }
+            })
+        },
+        changeOption(){
+            console.log(this.gnamevalue)
+            this.getCrm()
+        },
+        getExternalusers(){
+            var url="/api/CRM/GetClientList"
+            var that=this
+            this.$axios({
+                method: 'post',
+                url:url,
+                headers:{
+                    Authorization:'Bearer '+this.token
+                },
+                data:{
+                    portType: 1,
+                }
+            }).then(function(res){
+                console.log(res)
+                if(res.data.code==200){
+                   that.externalData=res.data.data;
+                   that.externalDatas = that.externalData;
+                }
+            })
+        },
+        clickUsers() {
+            var newarr = [];
+            if (this.input == "") {
+                newarr = this.externalData;
+            } else {
+                for (var i = 0; i < this.externalData.length; i++) {
+                    if (this.externalData[i].clientName.indexOf(this.input) != -1) {
+                        newarr.push(this.externalData[i]);
+                    }
+                    else if (this.externalData[i].idNo.indexOf(this.input) != -1) {
+                        newarr.push(this.externalData[i]);
+                    }
+                    else if (this.externalData[i].landlinePhone.indexOf(this.input) != -1) {
+                        newarr.push(this.externalData[i]);
+                    }
+                    // else if (this.externalData[i].companyName.indexOf(this.input) != -1) {
+                    //     newarr.push(this.externalData[i]);
+                    // }
+                }
+            }
+            this.externalDatas = newarr;
+            this.currentPageUser = 1;
+        },
+    },
+    mounted(){
+        this.token=JSON.parse(localStorage.getItem('userinif')).token;
+        this.getgroupsname();
+        this.getExternalusers();
+    }
 }
 </script>
 <style>
-    
+    .visa-box{
+        background-color: #fff;
+        padding: 10px;
+        box-shadow: 0 0 5px #0005;
+        border-radius: 10px;
+    }
+    .search-li:nth-child(1){
+        width: 20%;
+    }
+    .search-li:nth-child(1) .el-select{
+        width: 100%;
+        margin: 0;
+    }
+    .search-li:nth-child(2){
+        width: 80%;
+        justify-content: end;
+    }
+    .search-ul{
+        display: flex;
+        justify-content: space-between;
+        margin-bottom: 10px;
+    }
+    .search-li label{
+        color: #606266;
+    }
+    .search-li{
+        display: flex;
+    }
+    .search-li>div{
+        margin-right: 10px;
+    }
+    .form-box .el-table th.el-table__cell>.cell{
+        text-align: center;
+    }
+    .form-box .el-table td.el-table__cell div{
+        text-align: center;
+    }
+    .form-box .block{
+        margin-top: 10px;
+    }
+    .visa-box .el-row{
+        text-align: right;
+        margin-bottom: 5px;
+    }
+    .visas-list{
+        background-color: #fff;
+        padding: 10px;
+        box-shadow: 0 0 5px #0005;
+        border-radius: 10px;
+    }
+    .visas-title{
+        display: flex;
+        font-size: 17px;
+        font-weight:600 ;
+        color: #555;
+        margin-top: 8px;
+        margin-bottom: 2px;
+        justify-content: space-between;
+        align-items: center;
+    }
+    .visas-box{
+        display: flex;
+    }
+    .visas-box>button{
+        margin-left: 10px;
+        padding: 8px 20px;
+    }
 </style>

+ 11 - 0
src/components/Resource/CarData.vue

@@ -106,6 +106,12 @@ export default {
                 },
                 data: {
                     portType: 1,
+                    pageIndex: 0,
+                    pageSize: 0,
+                    unitName: "",
+                    unitArea: "",
+                    contact: "",
+                    contactTel: ""
                 }
             }).then(function (res) {
                 console.log(res)
@@ -119,6 +125,11 @@ export default {
                             value: item.unitArea,
                         });
                     });
+                    if (that.tableDatas.slice((that.currentPage - 1) * that.pageSize, that.currentPage * that.pageSize).length == 0) {
+                        if (that.currentPage > 1) {
+                            that.currentPage = that.currentPage - 1;
+                        }
+                    }
                 }
                 that.loading = false
             }).catch(function (error) {

+ 6 - 0
src/components/Resource/CarDataAdd.vue

@@ -237,6 +237,12 @@ export default {
                 },
                 data: {
                     portType: 1,
+                    pageIndex: 0,
+                    pageSize: 0,
+                    unitName: "",
+                    unitArea: "",
+                    contact: "",
+                    contactTel: ""
                 }
             }).then(function (res) {
                 console.log(res)

+ 6 - 0
src/components/Resource/CarDataEdit.vue

@@ -229,6 +229,12 @@ export default {
                 },
                 data: {
                     portType: 1,
+                    pageIndex: 0,
+                    pageSize: 0,
+                    unitName: "",
+                    unitArea: "",
+                    contact: "",
+                    contactTel: ""
                 }
             }).then(function (res) {
                 console.log(res)

+ 8 - 2
src/components/Resource/HotelData.vue

@@ -7,7 +7,7 @@
                     <el-input @input="Inquireclick()" placeholder="城市/名称/联系人" v-model="input" clearable
                         style="width: 350px;">
                     </el-input>
-                    <router-link to="/home/ThreeCodeOperation">
+                    <router-link to="/home/HotelDataOperation">
                         <el-button type="primary" style="margin-left: 10px;">新增</el-button>
                     </router-link>
 
@@ -94,6 +94,11 @@ export default {
                     debugger
                     that.tableData = res.data.data;
                     that.tableDatas = that.tableData;
+                    if (that.tableDatas.slice((that.currentPage - 1) * that.pageSize, that.currentPage * that.pageSize).length == 0) {
+                        if (that.currentPage > 1) {
+                            that.currentPage = that.currentPage - 1;
+                        }
+                    }
                 }
                 that.loading = false
             }).catch(function (error) {
@@ -125,12 +130,13 @@ export default {
 
         upDate(index, row) {
             this.$router.push({
-                path: "/home/ThreeCodeOperation",
+                path: "/home/HotelDataOperation",
                 query: { id: row.id }
             })
         },
 
         del(index, row) {
+            debugger
             var url = "/api/Resource/DelHotelData"
             var that = this
             this.$axios({

+ 311 - 0
src/components/Resource/HotelDataOperation.vue

@@ -0,0 +1,311 @@
+<template>
+    <div v-loading="loading" element-loading-text="跳转中..." class="car_add">
+        <div class="communal-title">
+            <div>酒店资料数据</div>
+        </div>
+        <div>
+            <el-form :model="addData" :rules="rules" ref="addData" label-width="100px" class="demo-ruleForm">
+                <div style="display: flex;">
+                    <div style="width: 49%;">
+                        <el-form-item label="所在城市" prop="City">
+                            <el-input placeholder="所在城市" v-model="addData.City">
+                            </el-input>
+                        </el-form-item>
+                    </div>
+                    <div style="width: 49%;">
+                        <el-form-item label="酒店名称" prop="Name">
+                            <el-input placeholder="酒店名称" v-model="addData.Name">
+                            </el-input>
+                        </el-form-item>
+                    </div>
+                </div>
+                <div style="display: flex;">
+                    <div style="width: 49%;">
+                        <el-form-item label="酒店电话" prop="Tel">
+                            <el-input placeholder="酒店电话" v-model="addData.Tel">
+                            </el-input>
+                        </el-form-item>
+                    </div>
+
+                    <div style="width: 49%;">
+                        <el-form-item label="酒店传真" prop="Fax">
+                            <el-input placeholder="酒店传真" v-model="addData.Fax">
+                            </el-input>
+                        </el-form-item>
+                    </div>
+                </div>
+                <div style="display: flex;">
+                    <div style="width: 49%;">
+                        <el-form-item label="酒店星级" prop="Level">
+                            <el-select v-model="addData.Level" filterable placeholder="酒店星级" style="width: 100%;">
+                                <el-option key="★" label="★" value="★">
+                                </el-option>
+                                <el-option key="★★" label="★★" value="★★">
+                                </el-option>
+                                <el-option key="★★★" label="★★★" value="★★★">
+                                </el-option>
+                                <el-option key="★★★★" label="★★★★" value="★★★★">
+                                </el-option>
+                                <el-option key="★★★★★" label="★★★★★" value="★★★★★">
+                                </el-option>
+                            </el-select>
+                        </el-form-item>
+                    </div>
+                    <div style="width: 49%;">
+                        <el-form-item label="酒店地址" prop="Address">
+                            <el-input placeholder="酒店地址" v-model="addData.Address">
+                            </el-input>
+                        </el-form-item>
+                    </div>
+                </div>
+                <div style="display :flex;">
+                    <div style="width: 49%;">
+                        <el-form-item label="联系人" prop="Contact">
+                            <el-input placeholder="联系人" v-model="addData.Contact">
+                            </el-input>
+                        </el-form-item>
+                    </div>
+                    <div style="width: 49%;">
+                        <el-form-item label="联系人电话" prop="ContactPhone">
+                            <el-input placeholder="联系人电话" v-model="addData.ContactPhone">
+                            </el-input>
+                        </el-form-item>
+                    </div>
+
+                </div>
+                <div style="display: flex;">
+                    <div style="width: 98%;">
+                        <el-form-item label="备注" prop="Remark">
+                            <el-input type="textarea" :rows="3" placeholder="请输入内容" v-model="addData.Remark"></el-input>
+                        </el-form-item>
+                    </div>
+                </div>
+
+                <el-form-item>
+                    <div style="margin-left: 60%;">
+                        <el-button type="primary" @click="addBtn">保存</el-button>
+                        <router-link to='/home/HotelData'>
+                            <el-button>取消</el-button>
+                        </router-link>
+                    </div>
+                </el-form-item>
+            </el-form>
+        </div>
+    </div>
+</template>
+<script>
+export default {
+    data() {
+        return {
+            rules: {
+                Name: [
+                    { required: true, message: '请输入酒店名称', trigger: 'blur' },
+                ],
+                Tel: [
+                    { required: true, message: '请输入酒店电话', trigger: 'blur' },
+                ],
+                City: [
+                    { required: true, message: '请输入城市', trigger: 'blur' },
+                ],
+                Level: [
+                    { required: true, message: '请选择酒店星级', trigger: 'blur' },
+
+                ],
+                Contact: [
+                    { required: true, message: '请输入酒店联系人', trigger: 'blur' },
+                ],
+                ContactPhone: [
+                    { required: true, message: '请输入联系人的联系方式', trigger: 'blur' },
+                ],
+                Address: [
+                    { required: true, message: '请输入酒店地址', trigger: 'blur' },
+                ]
+            },
+            loading: false,
+            tableData: [],
+            currentPage: 1, // 当前页码
+            pageSize: 15,// 每页的数据条数
+            input: '',
+            token: '',
+            userId: 0,
+            addData: {
+                Statu: '',
+                Id: 0,
+                City: '',
+                Name: '',
+                Level: '',
+                Address: '',
+                Tel: '',
+                Fax: '',
+                Contact: '',
+                ContactPhone: '',
+                OtherInformation: '',
+                CreateUserId: '',
+                Remark: '',
+            },
+            HotelDataData: {}
+
+        }
+    },
+    methods: {
+        HotelData() {
+            this.loading = true
+            var url = "/api/Resource/QueryHotelData"
+            var that = this
+            this.$axios({
+                method: 'post',
+                url: url,
+                headers: {
+                    Authorization: 'Bearer ' + this.token
+                },
+                data: {
+                    portType: 1,
+                }
+            }).then(function (res) {
+                console.log(res)
+                debugger
+                if (res.data.code == 200) {
+                    that.tableData = res.data.data;
+                    that.addData.Id = that.$route.query.id;
+                    if (that.addData.Id == undefined || that.addData.Id == null) {
+                        //添加
+                        that.addData.Status = 1
+                    } else {
+                        //编辑
+                        that.upData();
+                    }
+                }
+                that.loading = false
+            }).catch(function (error) {
+                that.loading = false
+                that.$message.error("网络错误,请稍后重试");
+            });
+        },
+
+        addBtn() {
+            const that = this;
+            debugger
+            that.addData.CreateUserId = that.userId
+            that.$refs.addData.validate((valid) => {
+                if (valid) {
+                    debugger
+                    console.log(that.addData)
+                    var url = "/api/Resource/OperationHotelData"
+                    that.$axios({
+                        method: 'post',
+                        url: url,
+                        headers: {
+                            Authorization: 'Bearer ' + that.token
+                        },
+                        data: that.addData
+                    }).then(function (res) {
+                        console.log(res)
+                        debugger
+                        if (res.data.code == 200) {
+                            that.$message({
+                                message: res.data.msg,
+                                type: 'success'
+                            });
+                            that.loading = true;
+                            setTimeout(() => {
+                                that.$router.push('/home/HotelData')
+                            }, 3000);
+                        } else {
+                            that.$message.error(res.data.msg);
+                        }
+                    })
+                } else {
+                    this.$message.error('请完善信息在保存!');
+                    return false;
+                }
+            })
+        },
+        upData() {
+            debugger
+            for (var i = 0; i < this.tableData.length; i++) {
+                if (this.tableData[i].id == parseInt(this.addData.Id)) {
+                    debugger
+                    this.HotelDataData = this.tableData[i];
+                    break;
+                }
+            }
+            this.addData.Status = 2;
+            this.addData.Id = this.HotelDataData.id;
+            this.addData.City = this.HotelDataData.city;
+            this.addData.Name = this.HotelDataData.name;
+            this.addData.Level = this.HotelDataData.level;
+            this.addData.Address = this.HotelDataData.address;
+            this.addData.Tel = this.HotelDataData.tel;
+            this.addData.Fax = this.HotelDataData.fax;
+            this.addData.Contact = this.HotelDataData.contact;
+            this.addData.ContactPhone = this.HotelDataData.contactPhone;
+            this.addData.OtherInformation = this.HotelDataData.otherInformation;
+            this.addData.CreateUserId = this.HotelDataData.createUserId;
+            this.addData.Remark = this.HotelDataData.remark;
+        },
+    },
+
+    mounted() {
+        debugger
+        this.token = JSON.parse(localStorage.getItem('userinif')).token;
+        this.userId = JSON.parse(localStorage.getItem('userinif')).userInfo.userId
+        this.HotelData();
+
+    }
+}
+</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>

+ 11 - 0
src/components/Resource/LocalGuide.vue

@@ -88,6 +88,12 @@ export default {
                 },
                 data: {
                     portType: 1,
+                    pageIndex: 0,
+                    pageSize: 0,
+                    unitName: "",
+                    unitArea: "",
+                    contact: "",
+                    contactTel: ""
                 }
             }).then(function (res) {
                 console.log(res)
@@ -101,6 +107,11 @@ export default {
                             value: item.unitArea,
                         });
                     });
+                    if (that.tableDatas.slice((that.currentPage - 1) * that.pageSize, that.currentPage * that.pageSize).length == 0) {
+                        if (that.currentPage > 1) {
+                            that.currentPage = that.currentPage - 1;
+                        }
+                    }
                 }
                 that.loading = false
             }).catch(function (error) {

+ 6 - 0
src/components/Resource/LocalGuideOperation.vue

@@ -234,6 +234,12 @@ export default {
                 },
                 data: {
                     portType: 1,
+                    pageIndex: 0,
+                    pageSize: 0,
+                    unitName: "",
+                    unitArea: "",
+                    contact: "",
+                    contactTel: ""
                 }
             }).then(function (res) {
                 if (res.data.code == 200) {

+ 5 - 0
src/components/Resource/ThreeCode.vue

@@ -94,6 +94,11 @@ export default {
                     debugger
                     that.tableData = res.data.data;
                     that.tableDatas = that.tableData;
+                    if (that.tableDatas.slice((that.currentPage - 1) * that.pageSize, that.currentPage * that.pageSize).length == 0) {
+                        if (that.currentPage > 1) {
+                            that.currentPage = that.currentPage - 1;
+                        }
+                    }
                 }
                 that.loading = false
             }).catch(function (error) {

+ 5 - 0
src/components/system/Company.vue

@@ -257,6 +257,11 @@ export default {
                             label: item.companyName
                         });
                     });
+                    if (that.tableDatas.slice((that.currentPage - 1) * that.pageSize, that.currentPage * that.pageSize).length == 0) {
+                        if (that.currentPage > 1) {
+                            that.currentPage = that.currentPage - 1;
+                        }
+                    }
                 }
             }).catch(function (error) {
                 that.$message.error("网络错误,请稍后重试");

+ 5 - 0
src/components/system/Department.vue

@@ -207,6 +207,11 @@ export default {
                             label: item.depName
                         });
                     });
+                    if (that.tableDatas.slice((that.currentPage - 1) * that.pageSize, that.currentPage * that.pageSize).length == 0) {
+                        if (that.currentPage > 1) {
+                            that.currentPage = that.currentPage - 1;
+                        }
+                    }
                 }
             })
         },

+ 5 - 1
src/components/system/JobPost.vue

@@ -229,7 +229,11 @@ export default {
                     debugger
                     that.tableDatas = res.data.data;
                     that.tableData = that.tableDatas
-
+                    if (that.tableDatas.slice((that.currentPage - 1) * that.pageSize, that.currentPage * that.pageSize).length == 0) {
+                        if (that.currentPage > 1) {
+                            that.currentPage = that.currentPage - 1;
+                        }
+                    }
                 }
             })
         },

+ 5 - 0
src/components/system/User.vue

@@ -269,6 +269,11 @@ export default {
                 if (res.data.code == 200) {
                     that.tableDatas = res.data.data;
                     that.tableData = that.tableDatas
+                    if (that.tableDatas.slice((that.currentPage - 1) * that.pageSize, that.currentPage * that.pageSize).length == 0) {
+                        if (that.currentPage > 1) {
+                            that.currentPage = that.currentPage - 1;
+                        }
+                    }
                 }
             })
         },

+ 1 - 1
src/main.js

@@ -9,7 +9,7 @@ import './assets/icon/iconfont.css'
 import store from './store/index.js';
 
 import axios from 'axios';
-//axios.defaults.baseURL = 'http://localhost:5256/'
+axios.defaults.baseURL = 'http://localhost:5256/'
 import { Message } from "element-ui";
 Vue.prototype.$message = Message
 Vue.prototype.$axios = axios;

+ 14 - 1
src/router/index.js

@@ -34,6 +34,9 @@ import ThreeCodeOperation from '@/components/Resource/ThreeCodeOperation'
 import HotelData from '@/components/Resource/HotelData'
 import visaform from '@/components/OP/visaform'
 import PageFun from '@/components/child/PageFunction'
+import HotelDataOperation from '@/components/Resource/HotelDataOperation'
+import visaEdit from '@/components/OP/visaEdit'
+
 Vue.use(Router)
 
 export default new Router({
@@ -186,9 +189,19 @@ export default new Router({
           component: visaform
         },
         {
+
           path: '/home/PageFun',
           name: 'PageFun',
-          component: PageFun
+          component: PageFun},
+        {
+          path: '/home/HotelDataOperation',
+          name: 'HotelDataOperation',
+          component: HotelDataOperation
+        },
+        {
+          path: '/home/visaEdit',
+          name: 'visaEdit',
+          component: visaEdit
         }
       ]
     },