浏览代码

feat:国内刷单列表修改以及国内机票管理订单界面添加

yangchengxiu 3 月之前
父节点
当前提交
5e006da258

+ 51 - 16
src/layout/components/Sidebar/Logo.vue

@@ -1,45 +1,80 @@
 <template>
-  <div class="sidebar-logo-container" :class="{'collapse':collapse}" :style="{ backgroundColor: sideTheme === 'theme-dark' ? variables.menuBackground : variables.menuLightBackground }">
+  <div
+    class="sidebar-logo-container"
+    :class="{ collapse: collapse }"
+    :style="{
+      backgroundColor:
+        sideTheme === 'theme-dark'
+          ? variables.menuBackground
+          : variables.menuLightBackground,
+    }"
+  >
     <transition name="sidebarLogoFade">
-      <router-link v-if="collapse" key="collapse" class="sidebar-logo-link" to="/">
+      <router-link
+        v-if="collapse"
+        key="collapse"
+        class="sidebar-logo-link"
+        to="/"
+      >
         <img v-if="logo" :src="logo" class="sidebar-logo" />
-        <h1 v-else class="sidebar-title" :style="{ color: sideTheme === 'theme-dark' ? variables.logoTitleColor : variables.logoLightTitleColor }">{{ title }} </h1>
+        <h1
+          v-else
+          class="sidebar-title"
+          :style="{
+            color:
+              sideTheme === 'theme-dark'
+                ? variables.logoTitleColor
+                : variables.logoLightTitleColor,
+          }"
+        >
+          {{ title }}
+        </h1>
       </router-link>
       <router-link v-else key="expand" class="sidebar-logo-link" to="/">
-        <img v-if="logo" :src="logo" class="sidebar-logo" />
-        <h1 class="sidebar-title" :style="{ color: sideTheme === 'theme-dark' ? variables.logoTitleColor : variables.logoLightTitleColor }">{{ title }} </h1>
+        <!-- <img v-if="logo" :src="logo" class="sidebar-logo" /> -->
+        <h1
+          class="sidebar-title"
+          :style="{
+            color:
+              sideTheme === 'theme-dark'
+                ? variables.logoTitleColor
+                : variables.logoLightTitleColor,
+          }"
+        >
+          {{ title }}
+        </h1>
       </router-link>
     </transition>
   </div>
 </template>
 
 <script>
-import logoImg from '@/assets/logo/logo.png'
-import variables from '@/assets/styles/variables.scss'
+import logoImg from "@/assets/logo/logo.png";
+import variables from "@/assets/styles/variables.scss";
 
 export default {
-  name: 'SidebarLogo',
+  name: "SidebarLogo",
   props: {
     collapse: {
       type: Boolean,
-      required: true
-    }
+      required: true,
+    },
   },
   computed: {
     variables() {
       return variables;
     },
     sideTheme() {
-      return this.$store.state.settings.sideTheme
-    }
+      return this.$store.state.settings.sideTheme;
+    },
   },
   data() {
     return {
       title: process.env.VUE_APP_TITLE,
-      logo: logoImg
-    }
-  }
-}
+      logo: logoImg,
+    };
+  },
+};
 </script>
 
 <style lang="scss" scoped>

+ 18 - 24
src/views/brushBill/internalBill/index.vue

@@ -262,13 +262,13 @@
           <div class="bolder">{{ scope.row.arrport }}</div>
         </template>
       </el-table-column>
-      <el-table-column label="航班号" width="80px">
+      <el-table-column label="航班号">
         <template slot-scope="scope">
           {{ scope.row.flightNo }}
           <div class="bolder">{{ scope.row.flightNoGongxiang }}</div>
         </template>
       </el-table-column>
-      <el-table-column label="起飞时间" width="85px">
+      <el-table-column label="起飞时间">
         <template slot-scope="scope">
           <span class="bolder">{{ scope.row.takeOffTime }}</span>
         </template>
@@ -282,33 +282,27 @@
       <el-table-column
         prop="orderStatusDesc"
         label="订单状态"
-        width="80px"
-      ></el-table-column>
-      <el-table-column
-        prop="orderSource"
-        label="订单源"
-        width="60px"
-      ></el-table-column>
-      <el-table-column
-        prop="agentName"
-        label="拉单账号"
-        width="80px"
-      ></el-table-column>
-      <el-table-column
-        prop="policeTypeDesc"
-        label="订单政策"
-        width="200px"
       ></el-table-column>
       <el-table-column
         prop="lastTicketTime"
         label="最晚出票时间"
-        width="155px"
+        width="120px"
+      ></el-table-column>
+      <el-table-column
+        prop="pnrExpirationDate"
+        label="pnr过期时间"
+        width="120px"
       ></el-table-column>
       <el-table-column
-        prop="operator"
-        label="出票人"
-        width="80px"
+        prop="pnrUpdateTime"
+        label="pnr更新时间"
+        width="120px"
       ></el-table-column>
+      <el-table-column prop="note" label="提示"></el-table-column>
+      <el-table-column prop="orderSource" label="订单源"></el-table-column>
+      <el-table-column prop="agentName" label="拉单账号"></el-table-column>
+      <el-table-column prop="policeTypeDesc" label="订单政策"></el-table-column>
+      <el-table-column prop="operator" label="出票人"></el-table-column>
       <el-table-column prop="allPrice" label="订单总价">
         <template slot-scope="scope">
           {{ Utils.fixFloat(scope.row.allPrice, 2, true) }}
@@ -322,9 +316,9 @@
       <el-table-column
         prop="orderCreateTime"
         label="订单创建时间"
-        width="155px"
+        width="120px"
       ></el-table-column>
-      <el-table-column prop="flightStatus" label="核验信息" width="155px">
+      <el-table-column prop="flightStatus" label="核验信息">
         <template slot-scope="{ row }">
           {{ autoCheckTypeArr[row.flightStatus] }}
         </template>

+ 571 - 0
src/views/internalAirTicket/orderList/index.vue

@@ -0,0 +1,571 @@
+<template>
+  <div class="orderlist">
+    <!-- 搜索条件 -->
+    <div class="filter-container">
+      <el-row :gutter="10">
+        <el-col class="filter-item" :xs="12" :sm="12" :md="4" :lg="4" :xl="4">
+          <el-input
+            v-model.trim="search.orderid"
+            clearable
+            size="small"
+            placeholder="订单号"
+            @keyup.enter.native="getOrders"
+          ></el-input>
+        </el-col>
+        <el-col class="filter-item" :xs="12" :sm="12" :md="4" :lg="4" :xl="4">
+          <el-select
+            v-model="search.orderstatus"
+            size="small"
+            placeholder="订单状态"
+            clearable
+            @change="getOrders"
+          >
+            <el-option
+              v-for="(option, key) in orderStatusList"
+              :key="key"
+              :label="option"
+              :value="key"
+            />
+          </el-select>
+        </el-col>
+        <el-col class="filter-item" :xs="12" :sm="12" :md="4" :lg="4" :xl="4">
+          <el-date-picker
+            v-model="search.orderdatestart"
+            value-format="yyyy-MM-dd"
+            size="small"
+            type="date"
+            placeholder="开始订单日期"
+          ></el-date-picker>
+        </el-col>
+        <el-col class="filter-item" :xs="12" :sm="12" :md="4" :lg="4" :xl="4">
+          <el-date-picker
+            v-model="search.orderdateend"
+            value-format="yyyy-MM-dd"
+            size="small"
+            type="date"
+            placeholder="结束订单日期"
+          ></el-date-picker>
+        </el-col>
+        <el-col class="filter-item" :xs="12" :sm="12" :md="4" :lg="4" :xl="4">
+          <el-select
+            v-model="search.ticketsource"
+            size="small"
+            placeholder="订单渠道"
+            clearable
+            @change="getOrders"
+          >
+            <el-option
+              v-for="(option, key) in ticketsourceArr"
+              :key="key"
+              :label="option"
+              :value="key"
+            />
+          </el-select>
+        </el-col>
+        <el-col class="filter-item" :xs="12" :sm="12" :md="4" :lg="4" :xl="4">
+          <el-select
+            v-model="search.ticketchannel"
+            size="small"
+            placeholder="出票渠道"
+            clearable
+            @change="getOrders"
+          >
+            <el-option
+              v-for="(option, key) in ticketChannelArr"
+              :key="key"
+              :label="option"
+              :value="key"
+            />
+          </el-select>
+        </el-col>
+      </el-row>
+      <el-row :gutter="10">
+        <el-col class="filter-item" :xs="12" :sm="12" :md="4" :lg="4" :xl="4">
+          <el-date-picker
+            v-model="search.takeofftime"
+            value-format="yyyy-MM-dd"
+            size="small"
+            type="datetime"
+            placeholder="起飞时间"
+          ></el-date-picker>
+        </el-col>
+        <el-col class="filter-item" :xs="12" :sm="12" :md="4" :lg="4" :xl="4">
+          <el-date-picker
+            v-model="search.arrivaltime"
+            value-format="yyyy-MM-dd"
+            size="small"
+            type="datetime"
+            placeholder="到达时间"
+          ></el-date-picker>
+        </el-col>
+        <el-col class="filter-item" :xs="12" :sm="12" :md="4" :lg="4" :xl="4">
+          <el-input
+            v-model="search.depport"
+            clearable
+            size="small"
+            placeholder="起飞机场"
+            @keyup.enter.native="getOrders"
+          ></el-input>
+        </el-col>
+        <el-col class="filter-item" :xs="12" :sm="12" :md="4" :lg="4" :xl="4">
+          <el-input
+            v-model="search.arrport"
+            clearable
+            size="small"
+            placeholder="到达机场"
+            @keyup.enter.native="getOrders"
+          ></el-input>
+        </el-col>
+        <el-col class="filter-item" :xs="12" :sm="12" :md="4" :lg="4" :xl="4">
+          <el-input
+            v-model="search.aircompanyname"
+            clearable
+            size="small"
+            placeholder="承运航司"
+            @keyup.enter.native="getOrders"
+          ></el-input>
+        </el-col>
+        <el-col class="filter-item" :xs="12" :sm="12" :md="4" :lg="4" :xl="4">
+          <el-input
+            v-model="search.gongxiangaircompanyname"
+            clearable
+            size="small"
+            placeholder="共享航司"
+            @keyup.enter.native="getOrders"
+          ></el-input>
+        </el-col>
+      </el-row>
+      <el-row :gutter="10">
+        <el-col class="filter-item" :xs="12" :sm="12" :md="4" :lg="4" :xl="4">
+          <el-input
+            v-model="search.flightno"
+            clearable
+            size="small"
+            placeholder="航班号"
+            @keyup.enter.native="getOrders"
+          ></el-input>
+        </el-col>
+        <el-col class="filter-item" :xs="12" :sm="12" :md="4" :lg="4" :xl="4">
+          <el-input
+            v-model="search.pnr"
+            clearable
+            size="small"
+            placeholder="PNR"
+            @keyup.enter.native="getOrders"
+          ></el-input>
+        </el-col>
+        <el-col class="filter-item" :xs="12" :sm="12" :md="4" :lg="4" :xl="4">
+          <el-input
+            v-model="search.eticketno"
+            clearable
+            size="small"
+            placeholder="票号"
+            @keyup.enter.native="getOrders"
+          ></el-input>
+        </el-col>
+        <el-col class="filter-item" :xs="12" :sm="12" :md="4" :lg="4" :xl="4">
+          <el-input
+            v-model="search.passenger"
+            clearable
+            size="small"
+            placeholder="乘客姓名"
+            @keyup.enter.native="getOrders"
+          ></el-input>
+        </el-col>
+        <el-col class="filter-item" :xs="12" :sm="12" :md="4" :lg="4" :xl="4">
+          <el-select
+            v-model="search.companyId"
+            size="small"
+            placeholder="所属公司"
+            clearable
+            collapse-tags
+            @change="getAgentInfoList"
+          >
+            <el-option
+              v-for="(option, key) in companyList"
+              :key="key"
+              :label="option"
+              :value="key"
+            />
+          </el-select>
+        </el-col>
+        <el-col class="filter-item" :xs="12" :sm="12" :md="4" :lg="4" :xl="4">
+          <el-select
+            v-model="search.agentid"
+            size="small"
+            placeholder="代理人ID"
+            clearable
+            collapse-tags
+            @change="getOrders"
+          >
+            <el-option
+              v-for="(option, key) in agentInfoList"
+              :key="key"
+              :label="option"
+              :value="key"
+            />
+          </el-select>
+        </el-col>
+        <el-col class="filter-item" :xs="12" :sm="12" :md="4" :lg="4" :xl="4">
+          <el-input
+            v-model="search.policetypedesc"
+            clearable
+            size="small"
+            placeholder="政策类型"
+            @keyup.enter.native="getOrders"
+          ></el-input>
+        </el-col>
+      </el-row>
+      <div class="search-btn">
+        <el-button
+          type="primary"
+          icon="el-icon-search"
+          size="small"
+          @click="getOrders"
+          >查询</el-button
+        >
+        <!-- <el-button type="primary" icon="el-icon-attract" plain size="small" @click="getOrdersManual">手动拉单</el-button> -->
+      </div>
+    </div>
+    <!-- 订单列表 -->
+    <el-table
+      v-loading="loading"
+      tooltip-effect="dark"
+      :data="orders"
+      stripe
+      size="mini"
+      style="width: 100%"
+    >
+      <el-table-column label="订单号" width="90px">
+        <template slot-scope="scope">
+          <div class="blue" @click="handleEdit(scope.row)">
+            <span>{{ scope.row.orderId }}</span>
+            <span v-if="scope.row.cancelIssueStatus === 1" style="color: red"
+              >申请取消</span
+            >
+          </div>
+        </template>
+      </el-table-column>
+      <el-table-column label="起飞机场" width="70px">
+        <template slot-scope="scope">
+          {{ scope.row.depPortDesc }}
+          <div class="bolder">{{ scope.row.depPort }}</div>
+        </template>
+      </el-table-column>
+      <el-table-column label="到达机场">
+        <template slot-scope="scope">
+          {{ scope.row.arrPortDesc }}
+          <div class="bolder">{{ scope.row.arrPort }}</div>
+        </template>
+      </el-table-column>
+      <el-table-column label="航班号" width="80px">
+        <template slot-scope="scope"
+          >{{ scope.row.flightNo }}
+          <div class="bolder">{{ scope.row.flightNoGongxiang }}承</div>
+        </template>
+      </el-table-column>
+      <el-table-column label="起飞时间" width="85px">
+        <template slot-scope="scope">
+          <span class="bolder">{{ scope.row.takeoffTime }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column
+        prop="passengers"
+        label="乘客姓名"
+        width="120px"
+      ></el-table-column>
+
+      <el-table-column
+        prop="orderStatusDesc"
+        label="订单状态"
+        width="80px"
+      ></el-table-column>
+      <el-table-column
+        prop="orderSource"
+        label="订单源"
+        width="60px"
+      ></el-table-column>
+      <el-table-column
+        prop="agentName"
+        label="拉单账号"
+        width="80px"
+      ></el-table-column>
+      <el-table-column
+        prop="policeTypeDesc"
+        label="订单政策"
+        width="200px"
+      ></el-table-column>
+      <el-table-column
+        prop="lastTicketTime"
+        label="最晚出票时间"
+        width="155px"
+      ></el-table-column>
+      <el-table-column
+        prop="operator"
+        label="出票人"
+        width="80px"
+      ></el-table-column>
+      <el-table-column prop="allPrice" label="订单总价">
+        <template slot-scope="scope">{{
+          Utils.fixFloat(scope.row.allPrice, 2, true)
+        }}</template>
+      </el-table-column>
+      <el-table-column prop="benefit" label="利润(元)">
+        <template slot-scope="scope">{{
+          Utils.fixFloat(scope.row.orderProfit, 2, true)
+        }}</template>
+      </el-table-column>
+      <el-table-column
+        prop="orderCreateTime"
+        label="订单创建时间"
+        width="155px"
+      ></el-table-column>
+      <el-table-column
+        prop="flightStatus"
+        label="核验信息"
+        width="155px"
+      ></el-table-column>
+      <el-table-column label="操作" fixed="right" prop="orderId" width="80px">
+        <template slot-scope="scope">
+          <el-button
+            size="mini"
+            plain
+            type="primary"
+            @click="handleEdit(scope.row)"
+            >编辑</el-button
+          >
+        </template>
+      </el-table-column>
+    </el-table>
+    <el-pagination
+      background
+      :page-sizes="[10, 20, 30, 50]"
+      :page-size.sync="pageInfo.size"
+      :current-page.sync="pageInfo.page"
+      layout="total, sizes, prev, pager, next, jumper"
+      :total="pageInfo.total"
+      @size-change="getOrders"
+      @current-change="getOrders"
+    ></el-pagination>
+    <!-- 编辑订单 弹窗 -->
+    <orderEdit
+      :editVisible="editVisible"
+      :data="orderVo"
+      :orderStatusList="orderStatusList"
+      @close="closeEditDialog"
+    ></orderEdit>
+  </div>
+</template>
+
+<script>
+// import api from "../../common/apis";
+import orderEdit from "./orderEdit";
+import store from "@/store";
+export default {
+  name: "orderlist",
+  components: {
+    orderEdit,
+  },
+  data() {
+    return {
+      search: {
+        //agentid: [],
+        orderdatestart: this.Utils.formatDate(new Date()),
+        orderdateend: this.Utils.formatDate(new Date()),
+      },
+      user: JSON.parse(sessionStorage.getItem("user")),
+      orderStatusList: {},
+      agentInfoList: {},
+      companyList: {},
+      ticketsourceArr: { 1: "订单渠道1" },
+      ticketChannelArr: { 1: "出票渠道1" },
+      flightStatusArr: {
+        0: "未使用",
+        1: "已使用",
+        2: "未知",
+        3: "已退票",
+        4: "核验失败",
+      },
+      cancelIssueStatusArr: { 0: "", 1: "申请取消", 2: "确认取消" },
+      orders: [],
+      pageInfo: {
+        total: 0,
+        size: 20,
+        page: 1,
+      },
+      loading: false,
+      editVisible: false,
+      orderVo: {},
+    };
+  },
+  mounted() {
+    this.getOrders();
+    this.getOrderStatusList();
+    this.getAgentInfoList();
+    this.getCompanyList();
+  },
+  methods: {
+    //刷新用户token
+    //手动拉单
+    getOrdersManual() {},
+    //获取订单列表
+    getOrders() {
+      const params = {
+        ...this.search,
+        page: this.pageInfo.page,
+        size: this.pageInfo.size,
+        username: encodeURI(store.getters.name),
+        userid: store.getters.id,
+      };
+      // if (params.agentid.length) {
+      //   params.agentid = params.agentid.join(",");
+      // }
+      if (
+        !(
+          (params.orderdatestart && params.orderdateend) ||
+          (!params.orderdatestart && !params.orderdateend)
+        )
+      ) {
+        this.$message.error("开始/结束订单日期 需 都填 或 都不填");
+        return false;
+      }
+      // this.loading = true;
+      // this.$http
+      //   .get(api.search_order, { params })
+      //   .then((res) => {
+      //     if (res && res.data && res.data.status === 200) {
+      //       this.orders = res.data.result.data;
+      //       this.pageInfo.total = res.data.result.total;
+      //     }
+      //     this.loading = false;
+      //   })
+      //   .catch(() => {
+      //     this.$message.error("加载数据失败");
+      //     this.loading = false;
+      //   });
+    },
+    //获取订单状态列表
+    getOrderStatusList() {
+      const params = {
+        userid: store.getters.id,
+        username: encodeURI(store.getters.name),
+      };
+      // this.$http
+      //   .get(api.orderstatus_list, { params })
+      //   .then((res) => {
+      //     if (res && res.data && res.data.status === 200) {
+      //       const orderStatusList = {};
+      //       res.data.result.data.forEach((v) => {
+      //         orderStatusList[v.orderStatus] = v.orderStatusDesc;
+      //       });
+      //       this.orderStatusList = orderStatusList;
+      //     } else {
+      //       this.$message.error(res.data.message);
+      //     }
+      //   })
+      //   .catch(() => {
+      //     this.$message.error("加载订单状态失败");
+      //   });
+    },
+    //获取 出票渠道列表
+    getAgentInfoList() {
+      const params = {
+        ...this.search,
+        userid: store.getters.id,
+        username: encodeURI(store.getters.name),
+        page: this.pageInfo.page,
+        size: this.pageInfo.size,
+      };
+      // this.$http
+      //   .get(api.agentinfo_getbyuserid, { params: params })
+      //   .then((res) => {
+      //     if (res && res.data && res.data.status === 200) {
+      //       const agentInfoList = {};
+      //       res.data.result.data.forEach((v) => {
+      //         agentInfoList[v.id] = v.agentNameDesc;
+      //       });
+      //       this.agentInfoList = agentInfoList;
+      //       this.getOrders();
+      //     } else {
+      //       this.$message.error(res.data.message);
+      //     }
+      //   })
+      //   .catch(() => {
+      //     this.$message.error("加载代理人ID数据失败");
+      //   });
+    },
+    //获取公司下拉列表
+    getCompanyList() {
+      const params = {
+        userid: store.getters.id,
+        username: encodeURI(store.getters.name),
+        companyid: store.getters.companyId,
+      };
+      // this.$http
+      //   .get(api.company_list, { params })
+      //   .then((res) => {
+      //     if (res && res.data && res.data.status === 200) {
+      //       const companyList = {};
+      //       res.data.result.data.forEach((v) => {
+      //         companyList[v.id] = v.companyName;
+      //       });
+      //       this.companyList = companyList;
+      //     } else {
+      //       this.$message.error(res.data.message);
+      //     }
+      //   })
+      //   .catch(() => {
+      //     this.$message.error("加载公司列表失败");
+      //   });
+    },
+
+    //点击 编辑订单
+    handleEdit(row) {
+      this.$router.push("/flightorder/orderEdit?orderId=" + row.orderId);
+      let data = this.$store.state["tags-view"].visitedViews;
+      data &&
+        data.forEach((item) => {
+          if (item.name == "orderEditPage") {
+            item.title = "订单" + "-" + row.orderId;
+          }
+        });
+      this.$store.dispatch("tags-view/changeVisitedView", data);
+      // const params = {
+      //   orderId: row.orderId,
+      //   username: encodeURI(store.getters.name),
+      //   userid: store.getters.id,
+      // };
+      // this.$http
+      //   .post(api.get_order_vo, params)
+      //   .then((res) => {
+      //     if (res && res.data && res.data.status === 200) {
+      //       this.orderVo = res.data.result;
+      //       this.editVisible = true;
+      //     }
+      //   })
+      //   .catch(() => {
+      //     this.$message.error("订单加载失败");
+      //     this.getOrders();
+      //   });
+    },
+    //关闭编辑弹窗
+    closeEditDialog(isSave) {
+      this.editVisible = false;
+      isSave && this.getOrders();
+    },
+  },
+};
+</script>
+
+<style lang="scss" scoped>
+.orderlist {
+  .blue {
+    color: #409eff;
+    cursor: pointer;
+  }
+}
+.bolder {
+  color: #000;
+  font-weight: bold;
+}
+</style>

文件差异内容过多而无法显示
+ 1388 - 0
src/views/internalAirTicket/orderList/orderEdit.vue