yxh
2023-05-09 1f1d4ef71d7d2290893686e54f54bf7ae0a0b4da
修改了报销单录入
已修改3个文件
709 ■■■■ 文件已修改
src/views/project/travelexpenseslist/index.vue 600 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/project/travelexpenseslistrecord/index.vue 106 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
vue.config.js 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/project/travelexpenseslist/index.vue
@@ -11,8 +11,8 @@
        </el-col>
        <el-col :span="6">
          <el-form-item label="报销人" prop="username">
            <el-input v-model="queryParams.username" placeholder="请输入报销人" clearable size="small"
          <el-form-item label="经办人" prop="username">
            <el-input v-model="queryParams.username" placeholder="请输入经办人" clearable size="small"
              @keyup.enter.native="handleQuery" />
          </el-form-item>
        </el-col>
@@ -95,7 +95,7 @@
      <!-- <el-table-column label="财务审核" width="120" align="center" prop="financechecher" /> -->
      <el-table-column label="捐献者" width="120" align="center" prop="donorname">
      </el-table-column>
      <el-table-column label="操作" align="center" fixed="right" class-name="small-padding fixed-width" width="270">
      <el-table-column label="操作" align="center" fixed="right" class-name="small-padding fixed-width" width="250">
        <template slot-scope="scope">
          <el-button v-if="scope.row.recordstatus == -1 || scope.row.recordstatus == 1" size="mini" type="text"
            icon="el-icon-upload2" @click="handleup(scope.row)">上报</el-button>
@@ -103,9 +103,7 @@
            icon="el-icon-edit" @click="handleUpdate(scope.row)">修改</el-button>
          <el-button size="mini" type="text" icon="el-icon-edit" @click="handleDetail(scope.row)">查看</el-button>
          <!-- v-hasPermi="['project:funddetail:edit']" -->
          <el-button size="mini" type="text" icon="el-icon-download" @click="gettable(scope.row)">
            下载
          </el-button>
          <el-button size="mini" type="text" icon="el-icon-download" @click="gettable(scope.row)"> 下载 </el-button>
          <!-- v-hasPermi="['project:funddetail:edit']" -->
          <el-button v-if="scope.row.recordstatus == -1 || scope.row.recordstatus == 1" size="mini" type="text"
            icon="el-icon-delete" @click="handleDelete(scope.row)">删除</el-button>
@@ -133,7 +131,7 @@
            <el-form-item label="经办人" prop="username">
              <el-select v-model="form.username" clearable filterable allow-create ref="getReportname"
                default-first-option placeholder="请选择">
                <el-option v-for="item in personList" :key="item.reportNo" :label="item.reportName"
                <el-option v-for="item in personsList" :key="item.reportNo" :label="item.reportName"
                  :value="item.reportName">
                </el-option>
              </el-select>
@@ -188,9 +186,9 @@
            </el-form-item>
          </el-col>
          <el-col :span="5">
            <el-form-item label="报销人" prop="travelers">
            <el-form-item label="出差人" prop="travelers">
              <el-select v-model="form.travelers" clearable filterable allow-create ref="getReportname"
                default-first-option placeholder="请选择" @change="selectedTraveler">
                default-first-option placeholder="请选择" @change="getAccountinfo()">
                <el-option v-for="item in travelers" :key="item.reportNo" :label="item.reportName"
                  :value="item.reportName">
                </el-option>
@@ -263,14 +261,17 @@
              plain
              icon="el-icon-plus"
              size="mini"
              @click="addRow"
              @click="adddetailRow"
              >新增一行</el-button
            >
          </el-col>
          </el-row>
                      -->
        <el-row>
          <el-table :data="applicationDetailArr" border highlight-current-row>
          <el-col :span="20">报销明细录入:</el-col>
        </el-row>
        <el-row>
          <el-table :data="rbDetails" border highlight-current-row>
            <el-table-column prop="orderno" slot="" label="序号" align="center" fixed width="65">
              <template slot-scope="scope">
                <el-input v-model="scope.row.orderno" placeholder="序号" />
@@ -291,21 +292,18 @@
            <el-table-column prop="persontype" slot="" label="人员类别" align="center" fixed width="120">
              <template slot-scope="scope">
                <el-select v-model="scope.row.persontype" value-key="value" placeholder="人员类别"
                  @change="getTravelers(scope.row)">
                  @change="getPersons(scope.row)">
                  <el-option v-for="dict in dict.type.sys_travelexpensebelong" :key="dict.value" :label="dict.label"
                    :value="dict.value"></el-option>
                </el-select>
              </template>
            </el-table-column>
            <el-table-column prop="personname2" slot="" label="费用人员" align="center" fixed width="120">
              <!-- <template slot-scope="scope">
                <el-input v-model="scope.row.personname" placeholder="出差人" />
              </template> -->
            <el-table-column prop="personname" slot="" label="费用人员" align="center" fixed width="120">
              <template slot-scope="scope">
                <el-select v-model="scope.row.personname" clearable filterable allow-create default-first-option
                  placeholder="请选择" @focus="filterPersonList(scope.row)">
                  <el-option v-for="item in scope.row.personname2" :key="item.reportNo" :label="item.reportName"
                  placeholder="请选择" @focus1="getPersons(scope.row)">
                  <el-option v-for="item in personsSel" :key="item.reportNo" :label="item.reportName"
                    :value="item.reportName">
                  </el-option>
                </el-select>
@@ -333,12 +331,12 @@
                </el-date-picker>
              </template>
            </el-table-column>
            <el-table-column prop="departure" slot="" label="出发地" align="center" fixed width="100">
            <el-table-column prop="departure" slot="" label="出发地" align="center" width="100">
              <template slot-scope="scope">
                <el-input v-model="scope.row.departure" placeholder="出发地" />
              </template>
            </el-table-column>
            <el-table-column label="到达地" prop="destination2" align="center" fixed width="100">
            <el-table-column label="到达地" prop="destination2" align="center" width="120">
              <template slot-scope="scope">
                <!--  <el-input v-model="scope.row.destination" placeholder="到达地" @blur="getallowance(scope.row)" /> -->
@@ -446,8 +444,8 @@
            </el-table-column>
            <el-table-column fixed="right" label="操作" align="center" width="120" v-if="dialogType == 'edit'">
              <template slot-scope="scope">
                <el-button type="text" size="mini" @click="addRow(scope.$index)">新增</el-button>
                <el-button @click.native.prevent="deleteRow(scope.$index, applicationDetailArr, scope.row)
                <el-button type="text" size="mini" @click="adddetailRow(scope.$index)">新增</el-button>
                <el-button @click.native.prevent="deleteRow(scope.$index, rbDetails, scope.row)
                  " type="text" size="small">
                  删除
                </el-button>
@@ -455,16 +453,18 @@
            </el-table-column>
          </el-table>
        </el-row>
        <el-row>
          <el-col :span="20">报销请款明细:</el-col>
        </el-row>
        <el-row style="margin-top: 30px">
          <el-table :data="applicationDetailArr2" border highlight-current-row>
            <el-table-column prop="col_orderno" slot="" label="序号" align="center" fixed width="65">
          <el-table :data="rbPayees" border highlight-current-row>
            <el-table-column prop="orderno" slot="" label="序号" align="center" fixed width="65">
              <template slot-scope="scope">
                <el-input v-model="scope.row.col_orderno" placeholder="序号" />
                <el-input v-model="scope.row.orderno" placeholder="序号" />
              </template>
            </el-table-column>
            <!--主键、外不展示-->
            <!--主键、外键不展示-->
            <el-table-column prop="id" slot="" label="主键" align="center" fixed width="95" v-if="false">
              <template slot-scope="scope">
                <el-input v-model="scope.row.id" placeholder="id" />
@@ -476,56 +476,55 @@
              </template>
            </el-table-column>
            <el-table-column prop="col_personType" slot="" label="人员类别" align="center" fixed width="120">
            <el-table-column prop="persontype" slot="" label="人员类别" align="center" fixed width="120">
              <template slot-scope="scope">
                <el-select v-model="scope.row.col_personType" value-key="value" placeholder="人员类别"
                  @change="getColTravelers(scope.row, scope.row.col_personType)">
                <el-select v-model="scope.row.persontype" value-key="value" placeholder="人员类别"
                  @change="getPersons(scope.row)">
                  <el-option v-for="dict in dict.type.sys_travelexpensebelong" :key="dict.value" :label="dict.label"
                    :value="dict.value"></el-option>
                </el-select>
              </template>
            </el-table-column>
            <el-table-column prop="col_personname2" slot="" label="收款人" align="center" fixed width="130">
            <el-table-column prop="personname" slot="" label="收款人" align="center" fixed width="130">
              <template slot-scope="scope">
                <el-select v-model="scope.row.col_personname" clearable filterable allow-create ref="getReportname"
                  default-first-option placeholder="请选择" @change="selectedColTraveler(scope.row)">
                  <el-option v-for="item in scope.row.col_personname2" :key="item.reportNo" :label="item.reportName"
                <el-select v-model="scope.row.personname" clearable filterable allow-create ref="getReportname"
                  default-first-option placeholder="请选择" @change="getAccountinfo2(scope.row, scope.row.persontype)">
                  <el-option v-for="item in personsSel" :key="item.reportNo" :label="item.reportName"
                    :value="item.reportName">
                  </el-option>
                </el-select>
              </template>
            </el-table-column>
            <el-table-column prop="col_bank" slot="" label="收款银行" align="center" fixed width="200">
            <el-table-column prop="bankname" slot="" label="银行名称" align="center" fixed width="200">
              <template slot-scope="scope">
                <el-input v-model="scope.row.col_bank" placeholder="收款银行" />
                <el-input v-model="scope.row.bankname" placeholder="银行名称" />
              </template>
            </el-table-column>
            <el-table-column prop="col_accounts" slot="" label="收款帐号" align="center" fixed width="200">
            <el-table-column prop="bankcardno" slot="" label="银行卡号" align="center" fixed width="200">
              <template slot-scope="scope">
                <el-input v-model="scope.row.col_accounts" placeholder="收款帐号" />
                <el-input v-model="scope.row.bankcardno" placeholder="银行卡号" />
              </template>    
            </el-table-column>
            <el-table-column prop="col_money" slot="" label="收款金额" align="center" fixed width="130">
            <el-table-column prop="amount" slot="" label="打款金额" align="center" fixed width="130">
              <template slot-scope="scope">
                <el-input v-model="scope.row.col_money" placeholder="收款金额" />
                <el-input v-model="scope.row.amount" placeholder="打款金额" />
              </template>    
            </el-table-column>
            <el-table-column prop="col_date" slot="" label="付款日期" fixed align="center" width="150">
            <el-table-column prop="remark" slot="" label="请款说明" align="center" fixed width="280">
              <template slot-scope="scope">
                <el-date-picker  clearable size="small" style="width: 100%" v-model="scope.row.col_date" type="date"
                  value-format="yyyy-MM-dd HH:mm:ss" placeholder="付款日期" @blur="getallowance(scope.row)">
                <el-input v-model="scope.row.remark" placeholder="说明" />
              </template>
            </el-table-column><el-table-column prop="paiddate" slot="" label="打款日期" fixed align="center" width="150">
              <template slot-scope="scope">
                <el-date-picker clearable size="small" style="width: 100%" v-model="scope.row.paiddate" type="date"
                  value-format="yyyy-MM-dd HH:mm:ss" placeholder="打款日期" :disabled="true" @blur="getallowance(scope.row)">
                </el-date-picker>
              </template>
            </el-table-column>
            <el-table-column prop="col_illustrate" slot="" label="说明" align="center" fixed width="280">
              <template slot-scope="scope">
                <el-input v-model="scope.row.col_illustrate" placeholder="说明" />
              </template>
            </el-table-column>
            <el-table-column label="操作" align="center" width="100" v-if="dialogType == 'edit'">
              <template slot-scope="scope">
                <el-button type="text" size="mini" @click="col_addRow(scope.$index)">新增</el-button>
                <el-button @click.native.prevent="deleteRow2(scope.$index, applicationDetailArr2, scope.row)
                <el-button type="text" size="mini" @click="addpayeeRow(scope.$index)">新增</el-button>
                <el-button @click.native.prevent="deleteRow2(scope.$index, rbPayees, scope.row)
                  " type="text" size="small">
                  删除
                </el-button>
@@ -607,7 +606,7 @@
<script>
import { listDonatebaseinfo } from "@/api/project/donatebaseinfo";
import { addOrUpdateRBpayee, listReimbursementpayee } from "@/api/project/reimbursementpayee";
import { addOrUpdateRBpayee, listReimbursementpayee, addReimbursementpayee, updateReimbursementpayee } from "@/api/project/reimbursementpayee";
import {
  listReimbursement,
  getReimbursement,
@@ -653,14 +652,24 @@
  ],
  data() {
    return {
      personList: [],
      travelers: [],
      coltravelers: [],
      //OPO协调员
      personsXty: [],
      //OPO专职人员
      personsZzry: [],
      //OPO管理人员
      personsManager: [],
      //OPO专家
      personsExpert: [],
      //全部人员
      personsList: [],
      //下拉可以选择人员列表
      personsSel: [],
      costtypeobj: {
        value: 0,
        label: "",
      },
      userlist: [],
      options: regionDataPlus,
      selectedOptions: [],
      searchAddress: {
@@ -735,11 +744,12 @@
        donorname: null,
        bigstrmoney: null,
      },
      applicationDetailArr: [],
      applicationDetailArr2: [],
      rbDetails: [],
      rbPayees: [],
      arrr2: [],
      baselist: [],
      balist: [],
      donatorList: [],
      standardlevel: 0,
      defaultperson: {},
      fundflowList: [],
@@ -760,42 +770,48 @@
      },
    };
  },
  created() {
    //获取记录列表
    this.getList();
    this.getUserList();
    //获取报销中的人员信息
    this.getPersonList();
  },
  mounted() {
    //获取捐献者姓名
    listDonatebaseinfo().then((res) => {
      // console.log("base基础表数据", res.rows);
      let list = res.rows;
      let baseinfolist = [];
      this.balist = list;
      this.donatorList = list;
      list.forEach((element) => {
        baseinfolist.push({
          infoid: element.id,
          name: element.name,
        });
      });
      // console.log("组合的新数组", baseinfolist);
      if (baseinfolist != 0) {
        this.baselist = baseinfolist;
      }
    });
    //获取登录者信息
    this.getUsermsg();
  },
  methods: {
    alertMessage(row) {
      debugger
    },
  methods: {
    handleUploadError() { },
    remove(file) {
      this.fileList.splice(this.fileList.indexOf(file), 1)
    },
    handleExceed() {
      this.$message.error(`上传文件数量不能超过 ${5} 个!`);
    },
    //文件上传成功回调
    uploadSccess(response, file, fileList) {
      //获取附件信息位置
@@ -809,73 +825,7 @@
      }
    },
    //获取人员列表
    getPersonList() {
      //获取各类别的人员:协调员、专职人员、负责人、专家
      let persontypeArr = ["xty1", "zzry", "fzr", "expert"];
      for (let i = 0; i < persontypeArr.length; i++) {
        this.tempArrr = [];
        listReportname(persontypeArr[i]).then((res) => {
          console.log(res);
          this.tempArrr = res.data;
          this.personList = this.personList.concat(this.tempArrr);
        });
      }
    },
    //获取一个类别的人员列表
    filterPersonList(row) {
      let travelertype = row.persontype;
    },
    //获取出差人列表
    getTravelers(row, val) {
      //专职人员-1,协调员-2,专家-3,家属-4,其他人员-5
      let travelertype = "";
      if (row.persontype == "1") {
        travelertype = "zzry";
      } else if (row.persontype == "2") {
        travelertype = "xty1";
      } else if (row.persontype == "3") {
        travelertype = "expert";
      } else if (row.persontype == "4") {
        travelertype = "jiashu";
      } else if (row.persontype == "5") {
        travelertype = "fzr";
      }
      listReportname(travelertype).then((res) => {
        this.travelers = res.data;
        row.personname2 = res.data;
      });
      this.form.persontype = val;
    },
    //获取收款人列表
    getColTravelers(row, val2) {
      debugger;
      //专职人员-1,协调员-2,专家-3,家属-4,其他人员-5
      let travelertype = "";
      if (val2 == 1) {
        travelertype = "zzry";
      } else if (val2 == 2) {
        travelertype = "xty1";
      } else if (val2 == 3) {
        travelertype = "expert";
      } else if (val2e == 4) {
        travelertype = "jiashu";
      } else if (val2 == 5) {
        travelertype = "fzr";
      }
      listReportname(travelertype).then((res) => {
        this.travelers = res.data;
        row.col_personname2 = res.data;
      });
      this.col_personType = val2;
    },
    selectcosttype() {
      this.form.costtype = this.costtypeobj.value;
      this.form.costtypename = this.costtypeobj.label;
    },
    //获取登录用户信息
    getUsermsg() {
      getUserProfile().then((response) => {
        this.defaultperson = response.data;
@@ -883,15 +833,53 @@
      });
    },
    getUserList() {
      listUser().then((res) => {
        this.userlist = res.data;
    //获取人员列表
    getPersonList() {
      //获取OPO协调员名单
      listReportname("xty1").then((res) => {
        this.personsXty = res.data;
        this.personsList = this.personsXty;
       
        //OPO专职人员名单
        listReportname("zzry").then((res) => {
          this.personsZzry = res.data;
          this.personsList = this.personsList.concat(this.personsZzry);
       
          //OPO管理人员名单
          listReportname("fzr").then((res) => {
            this.personsManager = res.data;
            this.personsList = this.personsList.concat(this.personsManager);
            //OPO专家名单
            listReportname("expert").then((res) => {
              this.personsExpert = res.data;
              this.personsList = this.personsList.concat(this.personsExpert);
            });
          });
        });
      });
    },
    selectedTraveler() {
      this.travelers.map((res) => {
    //获取一个类别的人员列表
    getPersons(row) {
      //专职人员-1,协调员-2,专家-3,家属-4,其他人员-5
      let tmpList = null;
      if (row.persontype == "1") {
        this.personsSel = this.personsZzry;
      } else if (row.persontype == "2") {
        this.personsSel = this.personsXty;
      } else if (row.persontype == "3") {
        this.personsSel = this.personsExpert;
      } else if (row.persontype == "4") {
        this.personsSel = tmpList;
      } else if (row.persontype == "5") {
        this.personsSel = this.personsManager;
      }
    },
    //获取设置人员账号信息
    getAccountinfo() {
      this.coltravelers.map((res) => {
        if (res.reportName == this.form.travelers) {
          getInfoBytheUserNo(res.reportNo).then((res) => {
            this.form.depositbank = res.data.depositbank;
@@ -901,40 +889,28 @@
        }
      });
    },
    //获取收款人银行卡和帐号
    selectedColTraveler(row) {
      let travelertype = "";
      if (row.col_personType == 1) {
        travelertype = "zzry";
      } else if (row.col_personType == 2) {
        travelertype = "xty1";
      } else if (row.col_personType == 3) {
        travelertype = "expert";
      } else if (row.col_personType == 4) {
        travelertype = "jiashu";
      } else if (row.col_personType == 5) {
        travelertype = "fzr";
    //获取设置人员账号信息
    getAccountinfo2(row, personType) {
      let dataArr = [];
      if (personType == 1) {
        dataArr = this.personsZzry;
      } else if (personType == 2) {
        dataArr = this.personsXty;
      } else if (personType == 3) {
        dataArr = this.personsExpert;
      } else if (personType == 5) {
        dataArr = this.personsManager;
      }
      listReportname(travelertype).then((res) => {
        let dataArr = res.data;
        for (let m = 0; m < dataArr.length; m++) {
          if (dataArr[m].reportName == row.col_personname) {
            row.col_bank = dataArr[m].depositbank;
            row.col_accounts = dataArr[m].bankcardno;
        if (dataArr[m].reportName == row.personname) {
          row.bankname = dataArr[m].depositbank;
          row.bankcardno = dataArr[m].bankcardno;
          };
        }
      });
      // this.coltravelers.map((res) => {
      //   console.log("-----------------------------");
      //   if (res.reportName == this.form.travelers) {
      //     getInfoBytheUserNo(res.reportNo).then((res) => {
      //       this.form.depositbank = res.data.depositbank;
      //       this.form.bankcardno = res.data.bankcardno;
      //       this.form.phone = res.data.telephone;
      //     });
      //   }
      // });
    },
    //计算补助
    getallowance(row) {
      if (
@@ -976,20 +952,15 @@
      //计算合计
      this.sumTotalFee();
    },
    getallowance2(row, val2) {
      debugger;
      // this.getallowance(row);
      this.arriveAddr = val2;
      this.queryParams2.arriveAddr;
      this.queryParams2.personType = row;
      console.log(row.persontype);
      console.log(this.arriveAddr);
      if (row.persontype != undefined && row.persontype == "2" || row.persontype == "5") {
        console.log(this.arriveAddr);
        this.loading = true;
        debugger;
        getSubsidy(val2).then((response) => {
          debugger
          this.loading = false;
          row.otherexpense = response.data.others;
          row.foodallowance = response.data.food;
@@ -997,6 +968,7 @@
      }
    },
    getStandard(row) {
      if (
        row.searchAddress.sheng != "" &&
@@ -1030,6 +1002,7 @@
          });
      }
    },
    selcetdestination(row) {
      console.log("目的地选择事件", row, row.searchAddress);
      //row.searchAddress = this.searchAddress;
@@ -1083,8 +1056,9 @@
      return area;
    },
    //获取捐献者基本信息:捐献编号、捐献者姓名
    selectbaseinfo() {
      let list = this.balist;
      let list = this.donatorList;
      list.forEach((item) => {
        if (item.id == this.form.infoid) {
          this.form.donorno = item.donorno;
@@ -1130,7 +1104,6 @@
    getList() {
      this.loading = true;
      listReimbursement(this.queryParams).then((response) => {
        console.log("差旅费数据列表:", response);
        this.reimbursementList = response.rows;
        this.total = response.total;
        this.loading = false;
@@ -1144,7 +1117,6 @@
    },
    // 表单重置
    reset() {
      this.fileList = []
      this.form = {
        ceshi: {},
@@ -1190,14 +1162,15 @@
        costtype: null,
        costtypename: null,
      };
      this.applicationDetailArr = [];
      this.applicationDetailArr2 = [];
      this.rbDetails = [];
      this.rbPayees = [];
      this.resetForm("form");
    },
    //
    handup(e) {
      console.log("上报", e);
    },
    // 下载文件
    downFile(item) {
      const url = process.env.VUE_APP_BASE_API + item.url
@@ -1207,6 +1180,7 @@
      a.href = url;
      a.dispatchEvent(event);
    },
    /** 搜索按钮操作 */
    handleQuery() {
      // console.log('pop',this.value1)
@@ -1221,6 +1195,7 @@
      this.queryParams.pageNum = 1;
      this.getList();
    },
    /** 重置按钮操作 */
    resetQuery() {
      this.resetForm("queryForm");
@@ -1232,6 +1207,7 @@
      this.single = selection.length !== 1;
      this.multiple = !selection.length;
    },
    /** 新增按钮操作 */
    handleAdd() {
      this.reset();
@@ -1239,15 +1215,18 @@
      this.fundflowList = [];
      this.form.username = this.defaultperson.nickName;
      this.form.userno = this.defaultperson.userName;
      this.addRow();
      this.col_addRow();
      this.adddetailRow();
      this.addpayeeRow();
      this.open = true;
      this.title = "添加报销申请";
    },
    /** 修改按钮操作 */
    handleUpdate(row) {
      this.dialogType = "edit";
      this.reset();
      //获取报销主信息
      const id = row.id || this.ids;
      getReimbursement(id).then((response) => {
        this.form = response.data;
@@ -1257,42 +1236,44 @@
        this.title = "修改报销申请";
        let ids = response.data.id;
        //获取报销明细信息
        getReimbursementdetaillist(ids).then((res) => {
          if (res.data.length == 0) {
            return;
          }
          
          this.applicationDetailArr = res.data;
          for (let i = 0; i < this.applicationDetailArr.length; i++) {
            debugger;
            //   this.applicationDetailArr[i].personname2 = res.data[i].personname;
          this.rbDetails = res.data;
          for (let i = 0; i < this.rbDetails.length; i++) {
            //   this.rbDetails[i].personname2 = res.data[i].personname;
          }
          for (let i = 0; i < this.applicationDetailArr.length; i++) {
            debugger;
            this.applicationDetailArr[i].index = i;
            this.applicationDetailArr[i].searchAddress = {
              sheng: this.applicationDetailArr[i].travelprovincename,
              shi: this.applicationDetailArr[i].travelcityname,
              qu: this.applicationDetailArr[i].traveltownname,
          for (let i = 0; i < this.rbDetails.length; i++) {
            this.rbDetails[i].index = i;
            this.rbDetails[i].searchAddress = {
              sheng: this.rbDetails[i].travelprovincename,
              shi: this.rbDetails[i].travelcityname,
              qu: this.rbDetails[i].traveltownname,
            };
          }
          //实时合计金额
          this.sumTotalFee();
        });
          //获取报销打款信息
        let obj = { rbid: ids };
        listReimbursementpayee(obj).then((res) => {
          if (res.rows.length == 0) {
            return;
          }
          this.applicationDetailArr2 = res.rows;
          // this.sumTotalFee();
            this.rbPayees = res.rows;
            console.log("listReimbursementpayee", res.rows);
          });
        });
      });
      //默认存在一行
      this.addRow();
      this.col_addRow();
      this.selectedTraveler();
      this.adddetailRow();
      this.addpayeeRow();
    },
    /** 查看按钮操作 */
    handleDetail(row) {
      this.dialogType = "detail";
@@ -1314,31 +1295,27 @@
          this.fundflowList = res.rows;
        });
        getReimbursementdetaillist(ids).then((res) => {
          this.applicationDetailArr = res.data;
          for (let i = 0; i < this.applicationDetailArr.length; i++) {
            this.applicationDetailArr[i].index = i;
            this.applicationDetailArr[i].searchAddress = {
              sheng: this.applicationDetailArr[i].travelprovincename,
              shi: this.applicationDetailArr[i].travelcityname,
              qu: this.applicationDetailArr[i].traveltownname,
          this.rbDetails = res.data;
          for (let i = 0; i < this.rbDetails.length; i++) {
            this.rbDetails[i].index = i;
            this.rbDetails[i].searchAddress = {
              sheng: this.rbDetails[i].travelprovincename,
              shi: this.rbDetails[i].travelcityname,
              qu: this.rbDetails[i].traveltownname,
            };
          }
          //this.sumTotalFee();
        });
      });
    },
    /** 提交按钮 */
    submitForm() {
      debugger;
      this.$refs["form"].validate((valid) => {
        debugger;
        if (valid) {
          let indexErrTime = this.applicationDetailArr.findIndex((item) => {
          let indexErrTime = this.rbDetails.findIndex((item) => {
            if (item.endtime && item.starttime) {
              let d = this.$moment(item.endtime).diff(
                this.$moment(item.starttime),
                "d"
              );
              let d = this.$moment(item.endtime).diff(this.$moment(item.starttime), "d");
              if (d < 0) {
                return true;
              } else {
@@ -1357,11 +1334,8 @@
            return;
          }
          let emptyStartTimeindex = this.applicationDetailArr.findIndex(
            (item) =>
              item.starttime == null ||
              item.starttime == undefined ||
              item.starttime == ""
          let emptyStartTimeindex = this.rbDetails.findIndex(
            (item) => item.starttime == null || item.starttime == undefined || item.starttime == ""
          );
          if (emptyStartTimeindex > -1) {
@@ -1372,11 +1346,8 @@
            return;
          }
          let emptyEndTimeindex = this.applicationDetailArr.findIndex(
            (item) =>
              item.endtime == null ||
              item.endtime == undefined ||
              item.endtime == ""
          let emptyEndTimeindex = this.rbDetails.findIndex(
            (item) => item.endtime == null || item.endtime == undefined || item.endtime == ""
          );
          if (emptyEndTimeindex > -1) {
@@ -1398,27 +1369,37 @@
          if (costtypeindex > -1) {
            this.form.costtypename = belongArr[costtypeindex].label;
          }
          //校验请款金额合计是否等于报销单金额
          if (this.form.amountrequested != this.rbPayees.reduce((amount, item) => amount + Number(item.amount), 0.0)) {
            this.$message({
              message: "报销请款表中合计金额不等于报销单的报销金额,请更正后再保存!",
              type: "warning",
            });
            return;
          }
          if (this.form.id != null) {
            //rbid主表Id,方便后面关联主表
            let rbid = this.form.id;
            for (let i = 0; i < this.applicationDetailArr.length; i++) {
              this.applicationDetailArr[i].rbid = rbid;
            for (let i = 0; i < this.rbDetails.length; i++) {
              this.rbDetails[i].rbid = rbid;
            }
            updateReimbursement(this.form).then((response) => {
              addOrupdateReimbursementdetaillist(this.applicationDetailArr).then((response) => {
              addOrupdateReimbursementdetaillist(this.rbDetails).then((response) => {
                //更新支付表信息
                for (let i = 0; i < this.applicationDetailArr2.length; i++) {
                  this.applicationDetailArr2[i].rbid = rbid;
                for (let i = 0; i < this.rbPayees.length; i++) {
                  this.rbPayees[i].rbid = rbid;
                }
                addOrUpdateRBpayee(this.applicationDetailArr2);
                // for (let i = 0; i < this.applicationDetailArr.length; i++) {
                //   if (this.applicationDetailArr[i].rbid != null) {
                //     updateReimbursementdetail(this.applicationDetailArr[i]);
                //   } else {
                //     this.applicationDetailArr[i].rbid = this.form.id;
                //     addReimbursementdetail(this.applicationDetailArr[i]);
                //   }
                // }
                //addOrUpdateRBpayee(this.rbPayees);
                for (let i = 0; i < this.rbPayees.length; i++) {
                  if (this.rbPayees[i].rbid != null) {
                    updateReimbursementpayee(this.rbPayees[i]);
                  } else {
                    addReimbursementpayee(this.rbPayees[i]);
                  }
                }
                this.$modal.msgSuccess("修改成功");
                this.open = false;
                this.getList();
@@ -1428,31 +1409,28 @@
            })
          } else {
            this.form.recordstatus = -1;
            const applicationDetailArr = [...this.applicationDetailArr]
            const applicationDetailArr2 = [...this.applicationDetailArr2]
            const rbDetails = [...this.rbDetails]
            const rbPayees = [...this.rbPayees]
            addReimbursement(this.form).then((response) => {
              for (let i = 0; i < applicationDetailArr.length; i++) {
                  applicationDetailArr[i].rbid = response.data;
              for (let i = 0; i < rbDetails.length; i++) {
                rbDetails[i].rbid = response.data;
                }
              addOrupdateReimbursementdetaillist(applicationDetailArr).then((response) => {
              addOrupdateReimbursementdetaillist(rbDetails).then((response) => {
              this.$modal.msgSuccess("新增成功");
              this.open = false;
              this.getList();
              console.log(
                "主表新增成功了:",
                response,
                this.applicationDetailArr
              );
              listReimbursementdetailid().then((res) => {
                let id = res.data;
                for (let i = 0; i < applicationDetailArr.length; i++) {
                  applicationDetailArr[i].rbid = id;
                  addReimbursementdetail(applicationDetailArr[i]);
                  for (let i = 0; i < rbDetails.length; i++) {
                    rbDetails[i].rbid = id;
                    addReimbursementdetail(rbDetails[i]);
                }
                for (let i = 0; i < applicationDetailArr2.length; i++) {
                  applicationDetailArr2[i].rbid = id;
                  for (let i = 0; i < rbPayees.length; i++) {
                    rbPayees[i].rbid = id;
                }
                addOrUpdateRBpayee(applicationDetailArr2);
                  //addOrUpdateRBpayee(rbPayees);
                  addReimbursementpayee(rbPayees);
              })
            })
          })
@@ -1460,6 +1438,7 @@
        }
      });
    },
    /** 删除按钮操作 */
    handleDelete(row) {
      const ids = row.id || this.ids;
@@ -1476,6 +1455,7 @@
        })
        .catch(() => { });
    },
    /** 导出按钮操作 */
    handleExport() {
      const queryParams = this.queryParams;
@@ -1493,9 +1473,9 @@
    },
    //新增一行
    addRow(rowIndex) {
    adddetailRow(rowIndex) {
      let rowData = {
        //index: this.applicationDetailArr.length,
        //index: this.rbDetails.length,
        searchAddress: {
          sheng: "",
          shi: "",
@@ -1534,35 +1514,35 @@
        destination: null,
      };
      if (rowIndex == undefined || rowIndex == null || rowIndex < 0) {
        this.applicationDetailArr.push(rowData);
        this.rbDetails.push(rowData);
      } else {
        this.applicationDetailArr.splice(rowIndex + 1, 0, rowData);
        this.rbDetails.splice(rowIndex + 1, 0, rowData);
      }
      for (let i = 0; i < this.applicationDetailArr.length; i++) {
        this.applicationDetailArr[i].orderno = i + 1;
      for (let i = 0; i < this.rbDetails.length; i++) {
        this.rbDetails[i].orderno = i + 1;
      }
    },
    col_addRow(rowIndex) {
    addpayeeRow(rowIndex) {
      let rowData = {
        id: null,
        col_personType: null,
        col_personname: null,
        col_bank: null,
        col_accounts: null,
        col_date: null,
        col_illustrate: null,
        col_orderno: null,
        col_personname2: null,
        col_money : null,
        personType: null,
        personname: null,
        bankname: null,
        bankcardno: null,
        paiddate: null,
        remark: null,
        orderno: null,
        personname: null,
        amount: null,
      };
      if (rowIndex == undefined || rowIndex == null || rowIndex < 0) {
        this.applicationDetailArr2.push(rowData);
        this.rbPayees.push(rowData);
      } else {
        this.applicationDetailArr2.splice(rowIndex + 1, 0, rowData);
        this.rbPayees.splice(rowIndex + 1, 0, rowData);
      }
      for (let i = 0; i < this.applicationDetailArr2.length; i++) {
        this.applicationDetailArr2[i].col_orderno = i + 1;
      for (let i = 0; i < this.rbPayees.length; i++) {
        this.rbPayees[i].orderno = i + 1;
      }
    },
@@ -1619,14 +1599,16 @@
          //几点取消的提示
        });
    },
    //重新计算排序
    recountOrderNo() {
      for (let i = 0; i < this.applicationDetailArr.length; i++) {
        this.applicationDetailArr[i].orderno = i + 1;
      for (let i = 0; i < this.rbDetails.length; i++) {
        this.rbDetails[i].orderno = i + 1;
      }
    },
    //重新计算排序
    recountOrderNo2() {
      for (let i = 0; i < this.applicationDetailArr2.length; i++) {
        this.applicationDetailArr2[i].orderno = i + 1;
      for (let i = 0; i < this.rbPayees.length; i++) {
        this.rbPayees[i].orderno = i + 1;
      }
    },
@@ -1668,7 +1650,6 @@
    //计算费用合计
    sumTotalFee() {
      // debugger;
      let allSum = 0;
      //捐献者家属费用
      if (!isNaN(parseFloat(this.form.donoramount))) {
@@ -1677,34 +1658,34 @@
      //报销明细费用
      try {
        for (let i = 0; i < this.applicationDetailArr.length; i++) {
        for (let i = 0; i < this.rbDetails.length; i++) {
          let totalFee = 0;
          //计算当前报销内容费用合计
          if (!isNaN(parseFloat(this.applicationDetailArr[i].trafficexpense))) {
            totalFee += parseFloat(this.applicationDetailArr[i].trafficexpense);
          if (!isNaN(parseFloat(this.rbDetails[i].trafficexpense))) {
            totalFee += parseFloat(this.rbDetails[i].trafficexpense);
          }
          if (!isNaN(parseFloat(this.applicationDetailArr[i].cityfee))) {
            totalFee += parseFloat(this.applicationDetailArr[i].cityfee);
          if (!isNaN(parseFloat(this.rbDetails[i].cityfee))) {
            totalFee += parseFloat(this.rbDetails[i].cityfee);
          }
          if (!isNaN(parseFloat(this.applicationDetailArr[i].hotelexpense))) {
            totalFee += parseFloat(this.applicationDetailArr[i].hotelexpense);
          if (!isNaN(parseFloat(this.rbDetails[i].hotelexpense))) {
            totalFee += parseFloat(this.rbDetails[i].hotelexpense);
          }
          if (!isNaN(parseFloat(this.applicationDetailArr[i].otherexpense))) {
            totalFee += parseFloat(this.applicationDetailArr[i].otherexpense);
          if (!isNaN(parseFloat(this.rbDetails[i].otherexpense))) {
            totalFee += parseFloat(this.rbDetails[i].otherexpense);
          }
          if (!isNaN(parseFloat(this.applicationDetailArr[i].foodexpenses))) {
            totalFee += parseFloat(this.applicationDetailArr[i].foodexpenses);
          if (!isNaN(parseFloat(this.rbDetails[i].foodexpenses))) {
            totalFee += parseFloat(this.rbDetails[i].foodexpenses);
          }
          if (!isNaN(parseFloat(this.applicationDetailArr[i].foodallowance))) {
            totalFee += parseFloat(this.applicationDetailArr[i].foodallowance);
          if (!isNaN(parseFloat(this.rbDetails[i].foodallowance))) {
            totalFee += parseFloat(this.rbDetails[i].foodallowance);
          }
          if (!isNaN(parseFloat(this.applicationDetailArr[i].otherfeeamount))) {
            totalFee += parseFloat(this.applicationDetailArr[i].otherfeeamount);
          if (!isNaN(parseFloat(this.rbDetails[i].otherfeeamount))) {
            totalFee += parseFloat(this.rbDetails[i].otherfeeamount);
          }
          this.applicationDetailArr[i].total = parseFloat(totalFee).toFixed(2);
          this.$set(this.applicationDetailArr, i, this.applicationDetailArr[i]);
          if (!isNaN(parseFloat(this.applicationDetailArr[i].total))) {
            allSum += parseFloat(this.applicationDetailArr[i].total);
          this.rbDetails[i].total = parseFloat(totalFee).toFixed(2);
          this.$set(this.rbDetails, i, this.rbDetails[i]);
          if (!isNaN(parseFloat(this.rbDetails[i].total))) {
            allSum += parseFloat(this.rbDetails[i].total);
          }
        }
@@ -1715,34 +1696,23 @@
    getDetailArr(rbid) {
      getReimbursementdetaillist(rbid).then((res) => {
        this.applicationDetailArr = res.data;
        for (let i = 0; i < this.applicationDetailArr.length; i++) {
          this.applicationDetailArr[i].index = i;
          this.applicationDetailArr[i].searchAddress = {
            sheng: this.applicationDetailArr[i].travelprovincename,
            shi: this.applicationDetailArr[i].travelcityname,
            qu: this.applicationDetailArr[i].traveltownname,
        this.rbDetails = res.data;
        for (let i = 0; i < this.rbDetails.length; i++) {
          this.rbDetails[i].index = i;
          this.rbDetails[i].searchAddress = {
            sheng: this.rbDetails[i].travelprovincename,
            shi: this.rbDetails[i].travelcityname,
            qu: this.rbDetails[i].traveltownname,
          };
        }
        this.sumTotalFee();
      });
    },
    //金额大写
    //金额数字转换成大写
    convertCurrency(money) {
      //汉字的数字
      var cnNums = new Array(
        "零",
        "壹",
        "贰",
        "叁",
        "肆",
        "伍",
        "陆",
        "柒",
        "捌",
        "玖"
      );
      var cnNums = new Array("零", "壹", "贰", "叁", "肆", "伍", "陆", "柒", "捌", "玖");
      //基本单位
      var cnIntRadice = new Array("", "拾", "佰", "仟");
      //对应整数部分扩展单位
src/views/project/travelexpenseslistrecord/index.vue
@@ -194,7 +194,7 @@
          </el-col>
        </el-row>
        <el-row>
          <el-table :data="applicationDetailArr" border highlight-current-row>
          <el-table :data="rbDetails" border highlight-current-row>
            <el-table-column prop="starttime" slot="" label="出发日期" align="center" width="150">
              <template slot-scope="scope">
                <el-date-picker clearable size="small" style="width: 100%" v-model="scope.row.starttime" type="date"
@@ -310,11 +310,11 @@
              </template>
            </el-table-column>
            <el-table-column fixed="right" label="操作" align="center" width="120">
              <!-- deleteRow(scope.$index, applicationDetailArr) -->
              <!-- deleteRow(scope.$index, rbDetails) -->
              <template slot-scope="scope">
                <el-button @click.native.prevent="
                  deleteRow(scope.$index, applicationDetailArr, scope.row)
                  deleteRow(scope.$index, rbDetails, scope.row)
                  " type="text" size="small" disabled>
                  删除
                </el-button>
@@ -544,7 +544,7 @@
        donorname: null,
        bigstrmoney: null,
      },
      applicationDetailArr: [],
      rbDetails: [],
      baselist: [],
      balist: [],
      standardlevel: 0,
@@ -783,7 +783,7 @@
        uploadflag: null,
        uploadtime: null,
      };
      this.applicationDetailArr = [
      this.rbDetails = [
        {
          index: 0,
          searchAddress: {
@@ -889,13 +889,13 @@
        let ids = response1.data.id;
        getReimbursementdetaillist(ids).then((res2) => {
          console.log("修改的details数据", res2);
          this.applicationDetailArr = res2.data;
          for (let i = 0; i < this.applicationDetailArr.length; i++) {
            this.applicationDetailArr[i].index = i;
            this.applicationDetailArr[i].searchAddress = {
              sheng: this.applicationDetailArr[i].travelprovincename,
              shi: this.applicationDetailArr[i].travelcityname,
              qu: this.applicationDetailArr[i].traveltownname,
          this.rbDetails = res2.data;
          for (let i = 0; i < this.rbDetails.length; i++) {
            this.rbDetails[i].index = i;
            this.rbDetails[i].searchAddress = {
              sheng: this.rbDetails[i].travelprovincename,
              shi: this.rbDetails[i].travelcityname,
              qu: this.rbDetails[i].traveltownname,
            };
          }
          //this.sumTotalFee();
@@ -919,13 +919,13 @@
        this.title = "查看报销申请";
        let ids = response.data.id;
        getReimbursementdetaillist(ids).then((res) => {
          this.applicationDetailArr = res.data;
          for (let i = 0; i < this.applicationDetailArr.length; i++) {
            this.applicationDetailArr[i].index = i;
            this.applicationDetailArr[i].searchAddress = {
              sheng: this.applicationDetailArr[i].travelprovincename,
              shi: this.applicationDetailArr[i].travelcityname,
              qu: this.applicationDetailArr[i].traveltownname,
          this.rbDetails = res.data;
          for (let i = 0; i < this.rbDetails.length; i++) {
            this.rbDetails[i].index = i;
            this.rbDetails[i].searchAddress = {
              sheng: this.rbDetails[i].travelprovincename,
              shi: this.rbDetails[i].travelcityname,
              qu: this.rbDetails[i].traveltownname,
            };
          }
          this.sumTotalFee();
@@ -936,7 +936,7 @@
    submitForm() {
      this.$refs["form"].validate((valid) => {
        if (valid) {
          //  this.applicationDetailArr.forEach(item=>{
          //  this.rbDetails.forEach(item=>{
          //    item.destination = this.searchAddress.sheng
          //  })
@@ -944,14 +944,14 @@
            console.log("大写", this.form.bigstrmoney);
            updateReimbursement(this.form).then((response) => {
              // console.log('更新主表的信息',response);
              for (let i = 0; i < this.applicationDetailArr.length; i++) {
                console.log("你好", this.applicationDetailArr[i].rbid);
                if (this.applicationDetailArr[i].rbid != null) {
                  updateReimbursementdetail(this.applicationDetailArr[i]);
              for (let i = 0; i < this.rbDetails.length; i++) {
                console.log("你好", this.rbDetails[i].rbid);
                if (this.rbDetails[i].rbid != null) {
                  updateReimbursementdetail(this.rbDetails[i]);
                } else {
                  console.log("修改时新增的id", this.form.id);
                  this.applicationDetailArr[i].rbid = this.form.id;
                  addReimbursementdetail(this.applicationDetailArr[i]);
                  this.rbDetails[i].rbid = this.form.id;
                  addReimbursementdetail(this.rbDetails[i]);
                }
              }
              this.$modal.msgSuccess("修改成功");
@@ -966,19 +966,19 @@
              console.log(
                "主表新增成功了:",
                response,
                this.applicationDetailArr
                this.rbDetails
              );
              listReimbursementdetailid().then((res) => {
                let id = res.data;
                for (let i = 0; i < this.applicationDetailArr.length; i++) {
                  this.applicationDetailArr[i].rbid = id;
                  addReimbursementdetail(this.applicationDetailArr[i]);
                for (let i = 0; i < this.rbDetails.length; i++) {
                  this.rbDetails[i].rbid = id;
                  addReimbursementdetail(this.rbDetails[i]);
                }
                console.log("idaaaaaa:", res);
              });
              //details新增
              // applicationDetailArr
              // rbDetails
            });
          }
        }
@@ -1019,7 +1019,7 @@
    //新增一行
    addRow() {
      let rowData = {
        index: this.applicationDetailArr.length,
        index: this.rbDetails.length,
        searchAddress: {
          sheng: "",
          shi: "",
@@ -1052,7 +1052,7 @@
        uploadTime: null,
        total: 0,
      };
      this.applicationDetailArr.push(rowData);
      this.rbDetails.push(rowData);
    },
    deleteRow(index, rows, row) {
@@ -1077,38 +1077,38 @@
      // debugger;
      let allSum = 0;
      try {
        for (let i = 0; i < this.applicationDetailArr.length; i++) {
        for (let i = 0; i < this.rbDetails.length; i++) {
          let totalFee = 0;
          //计算当前报销内容费用合计
          if (!isNaN(parseFloat(this.applicationDetailArr[i].trafficexpense))) {
            totalFee += parseFloat(this.applicationDetailArr[i].trafficexpense);
          if (!isNaN(parseFloat(this.rbDetails[i].trafficexpense))) {
            totalFee += parseFloat(this.rbDetails[i].trafficexpense);
          }
          if (!isNaN(parseFloat(this.applicationDetailArr[i].cityfee))) {
            totalFee += parseFloat(this.applicationDetailArr[i].cityfee);
          if (!isNaN(parseFloat(this.rbDetails[i].cityfee))) {
            totalFee += parseFloat(this.rbDetails[i].cityfee);
          }
          if (!isNaN(parseFloat(this.applicationDetailArr[i].hotelexpense))) {
            totalFee += parseFloat(this.applicationDetailArr[i].hotelexpense);
          if (!isNaN(parseFloat(this.rbDetails[i].hotelexpense))) {
            totalFee += parseFloat(this.rbDetails[i].hotelexpense);
          }
          if (!isNaN(parseFloat(this.applicationDetailArr[i].otherexpense))) {
            totalFee += parseFloat(this.applicationDetailArr[i].otherexpense);
          if (!isNaN(parseFloat(this.rbDetails[i].otherexpense))) {
            totalFee += parseFloat(this.rbDetails[i].otherexpense);
          }
          if (!isNaN(parseFloat(this.applicationDetailArr[i].foodexpenses))) {
            totalFee += parseFloat(this.applicationDetailArr[i].foodexpenses);
          if (!isNaN(parseFloat(this.rbDetails[i].foodexpenses))) {
            totalFee += parseFloat(this.rbDetails[i].foodexpenses);
          }
          if (!isNaN(parseFloat(this.applicationDetailArr[i].foodallowance))) {
            totalFee += parseFloat(this.applicationDetailArr[i].foodallowance);
          if (!isNaN(parseFloat(this.rbDetails[i].foodallowance))) {
            totalFee += parseFloat(this.rbDetails[i].foodallowance);
          }
          if (!isNaN(parseFloat(this.applicationDetailArr[i].otherfeeamount))) {
            totalFee += parseFloat(this.applicationDetailArr[i].otherfeeamount);
          if (!isNaN(parseFloat(this.rbDetails[i].otherfeeamount))) {
            totalFee += parseFloat(this.rbDetails[i].otherfeeamount);
          }
          this.applicationDetailArr[i].total = parseFloat(totalFee).toFixed(2);
          this.rbDetails[i].total = parseFloat(totalFee).toFixed(2);
          this.$set(
            this.applicationDetailArr,
            this.rbDetails,
            scope.$index,
            this.applicationDetailArr[i]
            this.rbDetails[i]
          );
          if (!isNaN(parseFloat(this.applicationDetailArr[i].total))) {
            allSum += parseFloat(this.applicationDetailArr[i].total);
          if (!isNaN(parseFloat(this.rbDetails[i].total))) {
            allSum += parseFloat(this.rbDetails[i].total);
          }
        }
        this.form.amountrequested = allSum.toFixed(2);
vue.config.js
@@ -33,9 +33,10 @@
    proxy: {
      // detail: https://cli.vuejs.org/config/#devserver-proxy
      [process.env.VUE_APP_BASE_API]: {
        target:`http://localhost:8080`,
        //target: `http://192.168.2.3:8080`,
        //target:`http://116.62.18.175:8080`,
        //target: `https://slb.hospitalstar.com:9093`,
        target:`http://116.62.18.175:8080`,
        changeOrigin: true,
        pathRewrite: {
          ['^' + process.env.VUE_APP_BASE_API]: ''