import InvoiceControllerForm from './InvoiceControllerForm'; import InvoiceControllerState from './InvoiceControllerState'; import { IGetBuyerListOption } from './InvoiceControllerState/BuyerState'; import { IGetGoodsListOption } from './InvoiceControllerState/GoodsListState/ImportGoods'; // import updateInvoiceNo from './fns/updateInvoiceNo'; import setEditGood from './fns/setEditGood'; import setEditFreight from './fns/setEditFreight'; import setGoods from './fns/setGoods'; import setFreight from './fns/setFreight'; import delGood from './fns/delGood'; import delFreight from './fns/delFreight'; import addGoodDiscount from './fns/addGoodDiscount'; import addGoodDiscountV2 from './fns/addGoodDiscountV2'; import addGood from './fns/addGood'; import addFreight from './fns/addFreight'; import saveEditGood from './fns/saveEditGood'; import saveEditFreight from './fns/saveEditFreight'; import getGoodsSearch from './fns/getGoodsSearch'; import mergeDetails from './fns/mergeDetails'; import mergeDiscount from './fns/mergeDiscount'; import importGoodsDrawer from './fns/importGoodsDrawer'; import itemBlur from './fns/itemBlur'; export { default as InvoiceControllerState } from './InvoiceControllerState'; export { default as IGood } from './InvoiceControllerState/GoodsListState/IGood'; export { default as LineAttributeType } from './InvoiceControllerState/GoodsListState/LineAttributeType'; export { default as IGood2 } from './InvoiceControllerState/FreightListState/IGood'; export default class InvoiceController extends InvoiceControllerForm { constructor(state = new InvoiceControllerState()) { super(state); } // ----------------- 发票头 模块相关 ----------------- /** 更新发票单据编号 */ updateInvoiceNo?: (option?: undefined) => Promise //= this.pipeline(updateInvoiceNo); // ----------------- 购买方 模块相关 ----------------- /** 获取 购买方 列表 */ getBuyerList?: (option?: IGetBuyerListOption | undefined) => Promise; // ----------------- 货物 模块相关 ----------------- /** 设置单个货物属性 */ setGoods = this.pipeline(setGoods); /** 设置货物运输属性 */ setFreight = this.pipeline(setFreight); setEditFreight = this.pipeline(setEditFreight); /** 设置当前的编辑货物 */ setEditGood = this.pipeline(setEditGood); /** 保存正在编辑的货物 */ saveEditGood = this.pipeline(saveEditGood); /** 保存正在编辑的货物运输 */ saveEditFreight = this.pipeline(saveEditFreight); /** 删除一个货物 */ delGood = this.pipeline(delGood); /** 删除一个货物运输 */ delFreight = this.pipeline(delFreight); /** 添加一个货物 */ addGood = this.pipeline(addGood); /** 添加一个货物运输 */ addFreight = this.pipeline(addFreight); /** 全单合并明细 */ mergeDetails = this.pipeline(mergeDetails); /** 全单合并折扣 */ mergeDiscount = this.pipeline(mergeDiscount); /** 给一组货物添加折扣行 */ addGoodDiscount = this.pipeline(addGoodDiscount); /** 给一组货物添加折扣行 */ addGoodDiscountV2 = this.pipeline(addGoodDiscountV2); /** 导入商品 */ importGoodsDrawer = this.pipeline(importGoodsDrawer); /** 项目名称智能赋码 */ itemNameBlur = this.pipeline(itemBlur); /** 获取 商品 列表 */ getGoodsList?: (option?: IGetGoodsListOption | undefined) => Promise; /** 税收分类编码列表 */ getTaxCategoryCodeList?: () => Promise; /** 获取筛选后的列表 */ getGoodsSearch = getGoodsSearch; /** 获取货物的税率可选列表, 如果没传taxClassificationCode,返回undefined */ getGoodsTaxRateList?: (taxClassificationCode: string) => Promise; /** 商品列表配置器 */ setColumnsConfig?: (columns: any[]) => any[]; addProductionByTax?: (params: any) => Promise; /** 下载申请单明细模版 */ downloadApplicationTempalte?: () => Promise; /** 上传申请单明细 */ importdApplicationLines?: (e: any, type: string) => Promise; /** 下载发票明细模版 */ downloadInvoiceTempalte?: () => Promise; /** 上传发票明细 */ importInvoiceLines?: (e: any, type: string) => Promise; }