import request from '../utils/request.js'

class invoice extends request {

//获取发票列表
  static getinvoicelist(params) {
    return this.postRequest(`${this.BASE_GROUP_URL}open/user/get-invoice-list`, {
      mobile:params.mobile,
    });
  }


  //删除发票
  static delinvoicebyid(params) {
    return this.postRequest(`${this.BASE_GROUP_URL}open/user/delete-invoice`, {
      mobile:params.mobile,
      invoiceId:params.invoiceId,
    });
  }
  

    //获取发票详情
    static getinvoicebyid(params) {
      return this.postRequest(`${this.BASE_GROUP_URL}open/user/get-invoice`, {
        mobile:params.mobile,
        invoiceId:params.invoiceId,
      });
    }

  //添加编辑发票
  static addoreditinvoice(params) {
    return this.postRequest(`${this.BASE_GROUP_URL}open/user/add-edit-invoice`, {
        mobile:params.mobile,
        invoiceId:params.invoiceId,
        invoiceTitle:params.invoiceTitle,
        invoiceNo:params.invoiceNo,
        companyAddress:params.companyAddress,
        companyPhone:params.companyPhone,
        bankName:params.bankName,
        bankAccount:params.bankAccount,
    });
  }

}

export default invoice