Bladeren bron

币别及汇率

wangzhuo 1 jaar geleden
bovenliggende
commit
da8ef3b541

+ 42 - 0
src/api/iosBasicData/rateManagement.js

@@ -0,0 +1,42 @@
+import request from '@/router/axios';
+//列表查询
+export function getRateList(params) {
+  return request({
+    url: '/api/blade-los/bcurrency/page',
+    method: 'get',
+    params
+  })
+}
+//修改和保存
+export function typeSave(data) {
+  return request({
+    url: '/api/blade-los/bcurrency/submit',
+    method: 'post',
+    data
+  })
+}
+//查看详情
+export function dataDetail(data) {
+  return request({
+    url: '/api/blade-los/bcurrency/detail?id='+data,
+    method: 'get'
+  })
+}
+//列表删除
+export function deleteDetails(data) {
+  return request({
+    url: '/api/blade-los/bcurrency/remove',
+    method: 'post',
+    params: {
+      ids: data
+    }
+  })
+}
+//列表删除
+export function delItem(data) {
+  return request({
+    url: '/api/blade-los/bcurrency/submit',
+    method: 'post',
+    data: data
+  })
+}

+ 723 - 0
src/views/iosBasicData/rateManagement/detailsPage.vue

@@ -0,0 +1,723 @@
+<template>
+  <div class="borderless" v-loading="allloading">
+    <div class="customer-head">
+      <div class="customer-back">
+        <el-button
+          type="danger"
+          style="border: none;background: none;color: red"
+          icon="el-icon-arrow-left"
+          @click="backToList"
+          >返回列表
+        </el-button>
+      </div>
+      <div class="add-customer-btn">
+        <el-button
+          type="primary"
+          size="small"
+          v-if="detailData.status == 1"
+          class="el-button--small-yh "
+          :disabled="form.status > 0"
+          @click.stop="openEdit"
+          >编辑
+        </el-button>
+        <el-button
+          class="el-button--small-yh"
+          type="primary"
+          :disabled="loadingBtn || detailData.status == 1"
+          size="small"
+          @click="editCustomer"
+          >保存数据
+        </el-button>
+      </div>
+    </div>
+    <div class="customer-main">
+      <containerTitle title="基础资料"></containerTitle>
+      <basic-container>
+        <avue-form
+          class="trading-form"
+          ref="form"
+          v-model="form"
+          :option="option"
+        >
+          <template slot="parities">
+            <el-input-number
+              v-model="form.parities"
+              size="small"
+              :controls="false"
+              style="width: 100%"
+              placeholder="请输入 默认汇率"
+              :disabled="detailData.status == 1"
+            ></el-input-number>
+          </template>
+          <template slot="standardMoney">
+            <el-switch
+              v-model="form.standardMoney"
+              :active-value="1"
+              :inactive-value="0"
+              :disabled="detailData.status == 1"
+            >
+            </el-switch>
+          </template>
+          <template slot="button">
+            <el-button
+              size="small"
+              type="primary"
+              @click="createExRate"
+              :disabled="detailData.status == 1"
+              >产生汇率项目</el-button
+            >
+          </template>
+        </avue-form>
+      </basic-container>
+      <containerTitle title="基础明细"></containerTitle>
+      <basic-container>
+        <avue-crud
+          ref="crud"
+          v-model="crudForm"
+          :option="optionList"
+          id="out-table"
+          :header-cell-class-name="headerClassName"
+          :data="dataList"
+          :table-loading="loading"
+          :cell-style="cellStyle"
+        >
+        </avue-crud>
+      </basic-container>
+    </div>
+  </div>
+</template>
+
+<script>
+import { typeSave, dataDetail, delItem } from "@/api/iosBasicData/rateManagement";
+import { optionList } from "./js/optionList";
+import reportDialog from "@/components/report-dialog/main";
+export default {
+  name: "detailsPage",
+  data() {
+    return {
+      time: "",
+      crudForm: {},
+      loading: false,
+      allloading: false,
+      loadingBtn: false,
+      form: {},
+      dataList: [],
+      drawer: false,
+      tableHeight: 0,
+      option: {
+        menuBtn: false,
+        labelWidth: 100,
+        // column: [
+        //   {
+        //     label: "货币币别",
+        //     prop: "code",
+        //     span: 6,
+        //     rules: [
+        //       {
+        //         required: true,
+        //         message: " ",
+        //         trigger: "blur"
+        //       }
+        //     ]
+        //   },
+        //   {
+        //     label: "货币名称",
+        //     prop: "cname",
+        //     span: 6,
+        //     rules: [
+        //       {
+        //         required: true,
+        //         message: " ",
+        //         trigger: "blur"
+        //       }
+        //     ]
+        //   },
+        //   {
+        //     label: "默认汇率",
+        //     prop: "parities",
+        //     span: 6,
+        //     rules: [
+        //       {
+        //         required: true,
+        //         message: " ",
+        //         trigger: "blur"
+        //       }
+        //     ]
+        //   },
+        //   {
+        //     label: "本位币",
+        //     prop: "standardMoney",
+        //     span: 6,
+        //     rules: [
+        //       {
+        //         required: true,
+        //         message: " ",
+        //         trigger: "blur"
+        //       }
+        //     ]
+        //   },
+        //   {
+        //     label: "符号",
+        //     prop: "symbol",
+        //     span: 6,
+        //     rules: [
+        //       {
+        //         required: false,
+        //         message: " ",
+        //         trigger: "blur"
+        //       }
+        //     ]
+        //   },
+        //   {
+        //     label: "汇率类型",
+        //     prop: "paritiesType",
+        //     type: "select",
+        //     filterable: true,
+        //     clearable: false,
+        //     props: {
+        //       label: "dictValue",
+        //       value: "dictValue"
+        //     },
+        //     dicData: [
+        //       {
+        //         dictValue: "年汇率",
+        //         dictKey: 0
+        //       },
+        //       {
+        //         dictValue: "月汇率",
+        //         dictKey: 1
+        //       },
+        //       {
+        //         dictValue: "日汇率",
+        //         dictKey: 2
+        //       }
+        //     ],
+        //     span: 6,
+        //     rules: [
+        //       {
+        //         required: true,
+        //         message: " ",
+        //         trigger: "change"
+        //       }
+        //     ]
+        //   },
+        //   {
+        //     label: "汇率年度",
+        //     prop: "annual",
+        //     type: "year",
+        //     valueFormat: "yyyy",
+        //     span: 6,
+        //     rules: [
+        //       {
+        //         required: true,
+        //         message: " ",
+        //         trigger: "blur"
+        //       }
+        //     ]
+        //   },
+        //   {
+        //     label: "月份",
+        //     prop: "moon",
+        //     type: "select",
+        //     filterable: true,
+        //     dicUrl: "/api/blade-system/dict-biz/dictionary?code=month",
+        //     props: {
+        //       label: "dictValue",
+        //       value: "dictKey"
+        //     },
+        //     span: 6,
+        //     display: false,
+        //     rules: [
+        //       {
+        //         required: true,
+        //         message: " ",
+        //         trigger: "change"
+        //       }
+        //     ]
+        //   },
+        //   {
+        //     prop: "button",
+        //     span: 6
+        //   }
+        // ]
+        column: [
+        {
+              label: "货币代码",
+              prop: "code",
+              span: 6,
+              rules: [{
+                required: true,
+                message: "请输入代码",
+                trigger: "blur"
+              }]
+            },
+            {
+              label: "国际三字码",
+              prop: "unCode",
+              span: 6,
+              rules: [{
+                required: true,
+                message: "请输入国际三字码",
+                trigger: "blur"
+              }]
+            }, 
+            {
+              label: "中文名称",
+              prop: "cnName",
+              span: 6,
+              rules: [{
+                required: true,
+                message: "请输入中文名称",
+                trigger: "blur"
+              }]
+            }, 
+            {
+              label: "英文名称",
+              prop: "enName",
+              span: 6,
+              rules: [{
+                required: true,
+                message: "请输入英文名称",
+                trigger: "blur"
+              }]
+            },
+            {
+              label: "货币符号",
+              prop: "symbol",
+              span: 6,
+              rules: [{
+                required: true,
+                message: "请输入货币符号",
+                trigger: "blur"
+              }]
+            },
+            {
+              label: "是否本币",
+              prop: "isLocal",
+              type: "select",
+              span: 6,
+              rules: [{
+                required: true,
+                message: "请选择是否本币",
+                trigger: "blur"
+              }],
+              dicData:[{
+                label:'非本币',
+                value:0
+              },{
+                label:'本币',
+                value:1
+              }],
+              value: 0
+            },
+            {
+              label: "对本币汇率",
+              prop: "exrate",
+              span: 6,
+              rules: [{
+                required: true,
+                message: "请输入对本币汇率",
+                trigger: "blur"
+              }]
+            },
+            {
+              label: "国家代码",
+              prop: "cntyCode",
+              span: 6
+            },
+            {
+              label: "国家名称",
+              prop: "cntyName",
+              span: 6
+            },
+            {
+              label: "汇率类型",
+              prop: "paritiesType",
+              type: "select",
+              filterable: true,
+              clearable: false,
+              props: {
+                label: "dictValue",
+                value: "dictValue"
+              },
+              dicData: [
+                {
+                  dictValue: "年汇率",
+                  dictKey: 0
+                },
+                {
+                  dictValue: "月汇率",
+                  dictKey: 1
+                },
+                {
+                  dictValue: "日汇率",
+                  dictKey: 2
+                }
+              ],
+              span: 6,
+              rules: [
+                {
+                  required: true,
+                  message: " ",
+                  trigger: "change"
+                }
+              ]
+            },
+            {
+              label: "汇率年度",
+              prop: "annual",
+              type: "year",
+              valueFormat: "yyyy",
+              span: 6,
+              rules: [
+                {
+                  required: true,
+                  message: " ",
+                  trigger: "blur"
+                }
+              ]
+            },
+            {
+              label: "月份",
+              prop: "moon",
+              type: "select",
+              filterable: true,
+              props: {
+                label: "dictValue",
+                value: "dictKey"
+              },
+              dicData: [
+                {
+                  dictValue: "一月",
+                  dictKey: 1
+                },
+                {
+                  dictValue: "二月",
+                  dictKey: 2
+                },
+                {
+                  dictValue: "三月",
+                  dictKey: 3
+                },
+                {
+                  dictValue: "四月",
+                  dictKey: 4
+                },
+                {
+                  dictValue: "五月",
+                  dictKey: 5
+                },
+                {
+                  dictValue: "六月",
+                  dictKey: 6
+                },
+                {
+                  dictValue: "七月",
+                  dictKey: 7
+                },
+                {
+                  dictValue: "八月",
+                  dictKey: 8
+                },
+                {
+                  dictValue: "九月",
+                  dictKey: 9
+                },
+                {
+                  dictValue: "十月",
+                  dictKey: 10
+                },
+                {
+                  dictValue: "十一月",
+                  dictKey: 11
+                },
+                {
+                  dictValue: "十二月",
+                  dictKey: 12
+                },
+              ],
+              span: 6,
+              display: false,
+              rules: [
+                {
+                  required: true,
+                  message: " ",
+                  trigger: "change"
+                }
+              ]
+            },
+            {
+              label: "状态",
+              prop: "status",
+              span: 6,
+              type: "select",
+              dicData:[{
+                label:'启用',
+                value:0
+              },{
+                label:'停用',
+                value:1
+              }],
+              value: 0
+            },
+            {
+              label: "备注",
+              prop: "remarks",
+              type: 'textarea',
+              width: "180",
+              span: 24,
+              minRows: 3,
+              slot: true
+            },
+            {
+              prop: "button",
+              span: 6
+            }
+            
+        ]
+      },
+      optionList: optionList
+    };
+  },
+  props: {
+    detailData: {
+      type: Object
+    }
+  },
+  components: {
+    reportDialog
+  },
+  created() {
+    this.$set(this.form, "standardMoney", 0);
+    if (this.detailData.id) {
+      this.getDetail(this.detailData.id);
+    }
+    if (this.detailData.status == 1) {
+      this.option.disabled = true;
+    }
+    this.optionList.height = 450;
+  },
+  methods: {
+    cellStyle() {
+      return "padding:0;height:40px;";
+    },
+    getDetail(id) {
+      dataDetail(id)
+        .then(res => {
+          this.form = res.data.data;
+          this.dataList = res.data.data.curExrateList
+            ? res.data.data.curExrateList
+            : [];
+        })
+        .finally(() => {
+          this.allloading = false;
+        });
+    },
+    //修改提交触发
+    editCustomer() {
+      this.$refs["form"].validate((valid, done) => {
+        console.log(this.dataList);
+        done();
+        if (valid) {
+          this.loadingBtn = true;
+          if (this.form.id) {
+            delItem({ id: this.form.id }).then(res => {
+              if (res.data.code == 200) {
+                typeSave({
+                  ...this.form,
+                  curExrateList: this.dataList
+                })
+                  .then(res => {
+                    this.$message.success("保存成功");
+                    this.getDetail(res.data.data.id);
+                  })
+                  .finally(() => {
+                    this.loadingBtn = false;
+                  });
+              }
+            });
+          } else {
+            typeSave({
+              ...this.form,
+              curExrateList: this.dataList
+            })
+              .then(res => {
+                this.$message.success("保存成功");
+                this.getDetail(res.data.data.id);
+              })
+              .finally(() => {
+                this.loadingBtn = false;
+              });
+          }
+        } else {
+          return false;
+        }
+      });
+    },
+    openEdit() {
+      const data = {
+        moduleName: "xxb",
+        tableName: "primary_school",
+        billId: this.form.id,
+        no: localStorage.getItem("browserID"),
+        billNo: this.form.exrateYear + "-" + this.form.moon
+      };
+      this.checkLock(data).then(res => {
+        if (res.data.code == 200) {
+          this.onLock(data).then(res => {
+            if (res.data.code == 200) {
+              this.detailData.status = 2;
+              this.option = this.$options.data().option;
+            }
+          });
+        }
+      });
+    },
+    //返回列表
+    backToList() {
+      if (this.form.id) {
+        this.unLock({
+          moduleName: "xxb",
+          tableName: "primary_school",
+          billId: this.form.id,
+          billNo: this.form.exrateYear + "-" + this.form.moon
+        });
+      }
+      this.$emit("goBack");
+      this.leaveDetailsKey(this.$route.name);
+    },
+    // 产生汇率项目
+    createExRate() {
+      this.$refs["form"].validate((valid, done) => {
+        done();
+        if (valid) {
+          this.toggleForm();
+          this.dataList = [];
+          if (this.form.paritiesType == "年汇率") {
+            this.form.exrateMonth = "";
+            const data = {
+              exrateYear: this.form.annual,
+              exrateReceivable: this.form.exrate,
+              exratePayable: this.form.exrate,
+              exrateReceipts: this.form.exrate,
+              exratePayment: this.form.exrate,
+              code: this.form.code,
+              cnName: this.form.cnName,
+              enName: this.form.enName,
+            };
+            this.dataList.push(data);
+          } else if (this.form.paritiesType == "月汇率") {
+            this.form.exrateMonth = "";
+            for (let i = 1; i <= 12; i++) {
+              const data = {
+                exrateYear: this.form.annual,
+                // exrateMonth: i + "月",
+                exrateMonth: i,
+                exrateReceivable: this.form.exrate,
+                exratePayable: this.form.exrate,
+                exrateReceipts: this.form.exrate,
+                exratePayment: this.form.exrate,
+                code: this.form.code,
+                cnName: this.form.cnName,
+                enName: this.form.enName,
+              };
+              this.dataList.push(data);
+            }
+          } else if (this.form.paritiesType == "日汇率") {
+            const days = this.getCountDays(this.form.annual, this.form.moon);
+            for (let i = 1; i <= days; i++) {
+              const data = {
+                exrateYear: this.form.annual,
+                // exrateMonth: this.form.moon + "月",
+                exrateMonth: this.form.moon,
+                // exrateDay: i + "号",
+                exrateDay: i,
+                exrateReceivable: this.form.exrate,
+                exratePayable: this.form.exrate,
+                exrateReceipts: this.form.exrate,
+                exratePayment: this.form.exrate,
+                code: this.form.code,
+                cnName: this.form.cnName,
+                enName: this.form.enName,
+              };
+              this.dataList.push(data);
+            }
+          }
+        }
+      });
+    },
+    // 获取一个月的天数
+    getCountDays(curDate, month) {
+      let date = new Date(curDate);
+      date.setMonth(month);
+      date.setDate(0);
+      return date.getDate();
+    },
+    toggleForm() {
+      if (this.form.paritiesType == "日汇率") {
+        this.findObject(this.optionList.column, "exrateDay").hide = false;
+        this.findObject(this.optionList.column, "exrateMonth").hide = false;
+      } else if (this.form.paritiesType == "月汇率") {
+        this.findObject(this.optionList.column, "exrateDay").hide = true;
+        this.findObject(this.optionList.column, "exrateMonth").hide = false;
+      } else {
+        this.findObject(this.optionList.column, "exrateDay").hide = true;
+        this.findObject(this.optionList.column, "exrateMonth").hide = true;
+      }
+    },
+    
+        // 更改表格颜色
+        headerClassName(tab){
+            //颜色间隔
+            let back = ""
+            if (tab.columnIndex >= 0 && tab.column.level === 1) {
+                if (tab.columnIndex % 2 === 0) {
+                    back = "back-one"
+                } else if (tab.columnIndex % 2 === 1) {
+                    back = "back-two"
+                }
+            }
+            return back;
+        },
+  },
+  watch: {
+    "form.paritiesType": function(row) {
+      if (row == "日汇率") {
+        this.findObject(this.option.column, "moon").display = true;
+      } else if (row == "月汇率") {
+        this.findObject(this.option.column, "moon").display = false;
+      } else {
+        this.findObject(this.option.column, "moon").display = false;
+      }
+    }
+  }
+};
+</script>
+
+
+<style lang="scss" scoped>
+.trading-form ::v-deep .el-form-item {
+  margin-bottom: 4px !important;
+}
+::v-deep .el-form-item__error {
+  display: none !important;
+}
+.schoolupload ::v-deep .el-upload-list {
+  display: none;
+}
+.abnormal ::v-deep .el-dialog__body {
+  padding: 10px 20px;
+}
+
+::v-deep#out-table .back-one {
+        background: #ecf5ff !important;
+    }
+    ::v-deep#out-table .back-two {
+        background: #ecf5ff !important;
+    }
+
+.headerCellClass {
+  color: #fff !important;
+  background: #a4cf57 !important;
+}
+</style>

+ 299 - 0
src/views/iosBasicData/rateManagement/index.vue

@@ -0,0 +1,299 @@
+<!-- 币别及汇率 -->
+<template>
+  <div>
+    <basic-container v-show="isShow" class="page-crad">
+      <avue-crud
+        ref="crud"
+        :option="option"
+        :data="dataList"
+        :before-open="beforeOpen"
+        id="out-table"
+        :header-cell-class-name="headerClassName"
+        :page.sync="page"
+        :search.sync="search"
+        @search-change="searchChange"
+        @current-change="currentChange"
+        @size-change="sizeChange"
+        @refresh-change="refreshChange"
+        @on-load="onLoad"
+        :table-loading="loading"
+        @saveColumn="saveColumn"
+        @resetColumn="resetColumn"
+        @selection-change="selectionChange"
+        :cell-style="cellStyle"
+        @search-criteria-switch="searchCriteriaSwitch"
+      >
+        <template slot-scope="{ row }" slot="updateUser">
+          <span>{{ row.updateUserName }}</span>
+        </template>
+        <template slot-scope="{ row, index }" slot="menu">
+          <el-button type="text" size="small" @click.stop="editOpen(row, 1)">
+            查看
+          </el-button>
+          <!-- <el-button type="text" size="small" @click.stop="editOpen(row, 1)">
+            编辑
+          </el-button> -->
+          <el-button
+            type="text"
+            size="small"
+            @click.stop="rowDel(row, index)"
+            :disabled="row.status > 0"
+          >
+            删除
+          </el-button>
+        </template>
+      </avue-crud>
+    </basic-container>
+    <detailPage
+      v-if="!isShow"
+      ref="detail"
+      @goBack="goBack"
+      @copyOrder="copyOrder"
+      :detailData="detailData"
+    ></detailPage>
+  </div>
+</template>
+
+<script>
+import detailPage from "./detailsPage";
+import { getRateList, deleteDetails } from "@/api/iosBasicData/rateManagement";
+
+export default {
+  name: "index",
+  components: {
+    detailPage
+  },
+  data() {
+    return {
+      selectionList: [],
+      form: {},
+      dataList: [],
+      loading: false,
+      isShow: true,
+      detailData: {},
+      search: {},
+      page: {
+        pageSize: 10,
+        currentPage: 1
+      },
+      option: {
+        searchShow: true,
+        searchMenuSpan: 6,
+        align: "center",
+        border: true,
+        index: true,
+        viewBtn: false,
+        editBtn: false,
+        delBtn: false,
+        menuWidth: 120,
+        tip: false,
+        selection: true,
+        searchIcon: true,
+          searchIndex: 3,
+          calcHeight: 30,
+        addBtnText: "新单",
+        stripe: true,
+        column: [
+          {
+            label: "代码",
+            prop: "code",
+            overHidden: true,
+            search: true
+          },
+          {
+            label: "国际三字码",
+            prop: "unCode",
+            overHidden: true,
+            search: true
+          },
+          {
+            label: "中文名称",
+            prop: "cnName",
+            overHidden: true,
+            search: true
+          },
+          {
+            label: "英文名称",
+            prop: "enName",
+            overHidden: true,
+            search: true
+          },
+          {
+            label: "货币符号",
+            prop: "symbol",
+            overHidden: true
+          },
+          {
+            label: "是否本币",
+            prop: "isLocal",
+              dicData:[{
+                label:'非本币',
+                value:0
+              },{
+                label:'本币',
+                value:1
+              }],
+            overHidden: true
+          },
+          {
+            label: "对本币汇率",
+            prop: "exrate",
+            overHidden: true
+          },
+          {
+            label: "国家代码",
+            prop: "cntyCode",
+            overHidden: true
+          },
+          {
+            label: "国家名称",
+            prop: "cntyName",
+            overHidden: true
+          },
+          {
+            label: "状态",
+            prop: "status",
+              type: "select",
+              dicData:[{
+                label:'启用',
+                value:0
+              },{
+                label:'停用',
+                value:1
+              }],
+              value: 0,
+            overHidden: true
+          }
+        ]
+      }
+    };
+  },
+  created() {
+    this.option.height = window.innerHeight - 210;
+  },
+  activated() {
+    if (this.$route.query.check) {
+      this.isShow = true;
+      setTimeout(() => {
+        this.editOpen({ id: this.$route.query.check.billId }, 1);
+      }, 100);
+    }
+  },
+  methods: {
+    searchCriteriaSwitch(type) {
+      if (type) {
+        this.option.height = this.option.height - 46;
+      } else {
+        this.option.height = this.option.height + 46;
+      }
+      this.$refs.crud.getTableHeight();
+    },
+    cellStyle() {
+      return "padding:0;height:40px;";
+    },
+    selectionChange(list) {
+      this.selectionList = list;
+    },
+    //点击搜索按钮触发
+    searchChange(params, done) {
+      this.page.currentPage = 1;
+      this.onLoad(this.page, params);
+      done();
+    },
+    refreshChange() {
+      this.onLoad(this.page, this.search);
+    },
+    currentChange(val) {
+      this.page.currentPage = val;
+    },
+    sizeChange(val) {
+      this.page.currentPage = 1;
+      this.page.pageSize = val;
+    },
+    onLoad(page, params = {}) {
+      this.loading = true;
+      let queryParams = {
+        ...params,
+        ...this.search,
+        size: page.pageSize,
+        current: page.currentPage
+      };
+      getRateList(queryParams)
+        .then(res => {
+          this.dataList = res.data.data.records ? res.data.data.records : [];
+          this.page.total = res.data.data.total;
+        })
+        .finally(() => {
+          this.loading = false;
+        });
+    },
+    //新增跳转页面
+    beforeOpen() {
+      this.isShow = false;
+    },
+    editOpen(row, status) {
+      this.detailData = {
+        id: row.id,
+        status: status
+      };
+      this.isShow = false;
+    },
+    rowDel(row, index, done) {
+      this.$confirm("确定删除数据?", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning"
+      }).then(() => {
+        deleteDetails(row.id).then(res => {
+          if (res.data.code == 200) {
+            this.$message({
+              type: "success",
+              message: "删除成功!"
+            });
+            this.onLoad(this.page, this.search);
+          }
+        });
+      });
+    },
+    goBack() {
+      if (this.$route.query.check) {
+        this.$router.$avueRouter.closeTag(this.$route.fullPath);
+        this.$router.push({
+          path: "/salaryManagement/primarySchool/index"
+        });
+      }
+      this.detailData = this.$options.data().detailData;
+      this.onLoad(this.page, this.search);
+      this.isShow = true;
+    },
+        // 更改表格颜色
+        headerClassName(tab){
+            //颜色间隔
+            let back = ""
+            if (tab.columnIndex >= 0 && tab.column.level === 1) {
+                if (tab.columnIndex % 2 === 0) {
+                    back = "back-one"
+                } else if (tab.columnIndex % 2 === 1) {
+                    back = "back-two"
+                }
+            }
+            return back;
+        },
+  }
+};
+</script>
+
+<style lang="scss" scoped>
+.page-crad ::v-deep .basic-container__card {
+  height: 94.2vh;
+}
+::v-deep#out-table .back-one {
+        background: #ecf5ff !important;
+    }
+    ::v-deep#out-table .back-two {
+        background: #ecf5ff !important;
+    }
+/deep/ .el-col-md-8 {
+  width: 24.33333%;
+}
+</style>

+ 133 - 0
src/views/iosBasicData/rateManagement/js/optionList.js

@@ -0,0 +1,133 @@
+import {
+  validatenumord,
+  cardid
+} from "@/util/validate";
+const validateDecimal = (rule, value, callback) => {
+  if (value != "") {
+    if (validatenumord(value, 1)) {
+      callback(new Error("请输入数字"));
+    } else {
+      callback();
+    }
+  } else {
+    callback();
+  }
+};
+const validateNumber = (rule, value, callback) => {
+  if (value != "") {
+    if (cardid(value)[0]) {
+      callback(new Error(cardid(value)[1]));
+    } else {
+      callback();
+    }
+  } else {
+    callback();
+  }
+};
+export const optionList = {
+  searchMenuSpan: 18,
+  addBtn: false,
+  border: true,
+  align: "center",
+  index: true,
+  viewBtn: false,
+  editBtn: false,
+  delBtn: false,
+  menu: false,
+  stripe: true,
+  dialogFullscreen: true,
+  // column: [{
+  //   label: "年",
+  //   prop: "annual",
+  //   width: 150,
+  //   overHidden: true,
+  // }, {
+  //   label: "月",
+  //   prop: "moon",
+  //   width: 150,
+  //   hide:true,
+  //   overHidden: true,
+  // },{
+  //   label: "日",
+  //   prop: "national",
+  //   width: 150,
+  //   overHidden: true,
+  //   hide:true,
+  //   showColumn:false,
+  // }, {
+  //   label: "应收汇率",
+  //   prop: "receivableParities",
+  //   width: 150,
+  //   overHidden: true,
+  // }, {
+  //   label: "应付汇率",
+  //   prop: "handleParities",
+  //   width: 150,
+  //   overHidden: true,
+  // }, {
+  //   label: "实收汇率",
+  //   prop: "receiptsParities",
+  //   width: 150,
+  //   overHidden: true,
+  // }, {
+  //   label: "实付汇率",
+  //   prop: "actuallyParities",
+  //   width: 150,
+  //   overHidden: true,
+  // }]
+  column: [{
+    label: "币种代码",
+    prop: "code",
+    width: 150,
+    overHidden: true,
+  }, {
+    label: "中文名称",
+    prop: "cnName",
+    width: 150,
+    overHidden: true,
+  }, {
+    label: "英文名称",
+    prop: "enName",
+    width: 150,
+    overHidden: true,
+    showColumn: false,
+  }, {
+    label: "年",
+    prop: "exrateYear",
+    width: 150,
+    overHidden: true,
+    showColumn: false,
+  }, {
+    label: "月",
+    prop: "exrateMonth",
+    width: 150,
+    overHidden: true,
+    showColumn: false,
+  }, {
+    label: "日",
+    prop: "exrateDay",
+    width: 150,
+    overHidden: true,
+    showColumn: false,
+  }, {
+    label: "应收汇率",
+    prop: "exrateReceivable",
+    width: 150,
+    overHidden: true,
+  }, {
+    label: "应付汇率",
+    prop: "exratePayable",
+    width: 150,
+    overHidden: true,
+  }, {
+    label: "实收汇率",
+    prop: "exrateReceipts",
+    width: 150,
+    overHidden: true,
+  }, {
+    label: "实付汇率",
+    prop: "exratePayment",
+    width: 150,
+    overHidden: true,
+  }]
+}