import './index.less'; import React from 'react'; import InvoiceController from './InvoiceController'; import * as calculator from './tools/calculate'; import * as utils from './tools/utils'; import GoodsList from './ui/default/GoodsList'; import Seller from './ui/default/Seller'; import Buyer from './ui/default/Buyer'; import GoodsListDigtal from './ui/digtal/GoodsList'; import FreightList from './ui/digtal/FreightList'; /** 发票组件的上下文 */ export declare const InvoiceContext: React.Context; export interface IInvoiceProps { /** 发票数据控制器 */ controller?: InvoiceController; /** 发票头UI */ invoiceHeader?: React.ReactNode; /** 货物列表UI */ goodsList?: React.ReactNode; /** 购买方UI (invoiceType为default时生效) */ buyer?: React.ReactNode; /** 销售方UI (invoiceType为default时生效)*/ seller?: React.ReactNode; /** 干系人(购买方&销售方) (invoiceType为digtal时生效) */ stakeholder?: React.ReactNode; /** 落款UI */ sign?: React.ReactNode; /** 特殊信息 */ specialInfor?: React.ReactNode; /** 底部扩展UI */ footExpand?: React.ReactNode; /** 发票种类: default-默认,digtal-数电 */ invoiceType?: 'default' | 'digtal'; /** 编辑中的商品行变化时触发(数量/单价/税率等字段变更时) */ onEditGoodChange?: (editGood: any) => void; /** 商品列表变化时触发(新增/删除行时) */ onGoodsListChange?: (goodsList: any[]) => void; } export default class Invoice extends React.PureComponent { /** 控制器 */ static readonly InvoiceController: typeof InvoiceController; /** 发票头(默认) */ static readonly InvoiceHeader: React.FunctionComponent; /** 货物列表(默认) */ static readonly GoodsList: typeof GoodsList; /** 销售方(默认) */ static readonly Seller: typeof Seller; /** 落款(默认) */ static readonly Sign: React.FunctionComponent; /** 购买方(默认) */ static readonly Buyer: typeof Buyer; /** 发票头(数电) */ static readonly InvoiceHeaderDigtal: React.FunctionComponent; /** 干系人(数电) */ static readonly Stakeholder: React.FunctionComponent; /** 农产品干系人(数电) */ static readonly StakeFarmerholder: React.FunctionComponent; /** 落款(数电) */ static readonly SignDigtal: React.FunctionComponent; /** 特殊信息-不动产经营租赁服务(数电) */ static readonly RealEstateInfo: React.FunctionComponent; /** 特殊信息-建筑服务(数电) */ static readonly Architecture: React.FunctionComponent; static readonly FreightList: typeof FreightList; /** 货物列表(数电) */ static readonly GoodsListDigtal: typeof GoodsListDigtal; /** 货物索引生成器 */ static idGenerator: () => string; /** 金额计算方法 */ static calculator: typeof calculator; /** 工具方法 */ static utils: typeof utils; /** 获取控制器钩子 */ static useInvoiceController: () => InvoiceController; render(): JSX.Element; }