kts-component-invoice-operate 3.2.264 → 3.2.266
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/DifferenceInputModal/demo.d.ts +4 -0
- package/dist/DifferenceInputModal/index.d.ts +73 -0
- package/dist/Invoice/Invoice-digtal/_test/differenceInput/index.d.ts +4 -0
- package/dist/Invoice/InvoiceController/InvoiceControllerState/DifferenceInputState/index.d.ts +11 -0
- package/dist/Invoice/InvoiceController/InvoiceControllerState/GoodsListState/index.d.ts +2 -0
- package/dist/Invoice/InvoiceController/InvoiceControllerState/index.d.ts +3 -0
- package/dist/Invoice/InvoiceController/hooks/index.d.ts +3 -0
- package/dist/Invoice/_test/differenceInput/index.d.ts +4 -0
- package/dist/Invoice/tools/calculate/index.d.ts +1 -1
- package/dist/Invoice/ui/digtal/DifferenceInput/index.d.ts +3 -0
- package/dist/Invoice/ui/digtal/GoodsList/hook/useColumns/ui/ItemNameInput/index.d.ts +1 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.esm.js +1481 -319
- package/dist/index.js +1478 -315
- package/package.json +1 -1
- package/src/DifferenceInputModal/demo.tsx +22 -0
- package/src/DifferenceInputModal/index.less +102 -0
- package/src/DifferenceInputModal/index.md +5 -0
- package/src/DifferenceInputModal/index.tsx +520 -0
- package/src/Invoice/Invoice-digtal/_test/differenceInput/index.tsx +31 -0
- package/src/Invoice/Invoice-digtal/index.md +12 -9
- package/src/Invoice/InvoiceController/InvoiceControllerForm/index.ts +9 -2
- package/src/Invoice/InvoiceController/InvoiceControllerState/DifferenceInputState/index.ts +16 -0
- package/src/Invoice/InvoiceController/InvoiceControllerState/GoodsListState/index.ts +3 -0
- package/src/Invoice/InvoiceController/InvoiceControllerState/index.ts +4 -0
- package/src/Invoice/InvoiceController/fns/saveEditGood.ts +1 -0
- package/src/Invoice/InvoiceController/hooks/index.ts +63 -0
- package/src/Invoice/_test/differenceInput/index.tsx +25 -0
- package/src/Invoice/index.md +3 -0
- package/src/Invoice/index.tsx +21 -6
- package/src/Invoice/tools/calculate/index.ts +2 -3
- package/src/Invoice/ui/default/GoodsList/hook/useColumns/autoFillFn/index.ts +2 -1
- package/src/Invoice/ui/default/GoodsList/hook/useColumns/index.tsx +19 -6
- package/src/Invoice/ui/default/GoodsList/hook/useColumns/ui/ItemNameInput/index.tsx +8 -2
- package/src/Invoice/ui/default/GoodsList/hook/useWindowClick/index.tsx +4 -1
- package/src/Invoice/ui/default/GoodsList/index.tsx +1 -1
- package/src/Invoice/ui/default/GoodsList/ui/AddRowButton/index.tsx +4 -0
- package/src/Invoice/ui/digtal/DifferenceInput/index.tsx +69 -0
- package/src/Invoice/ui/digtal/GoodsList/hook/useColumns/autoFillFn/index.ts +2 -2
- package/src/Invoice/ui/digtal/GoodsList/hook/useColumns/index.tsx +34 -21
- package/src/Invoice/ui/digtal/GoodsList/hook/useColumns/ui/ItemNameInput/index.tsx +15 -4
- package/src/Invoice/ui/digtal/GoodsList/hook/useWindowClick/index.tsx +4 -1
- package/src/Invoice/ui/digtal/GoodsList/ui/AddRowButton/index.tsx +7 -7
- package/src/TaxClassificationCodeModal/index.tsx +2 -0
- package/src/index.ts +3 -0
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import './index.less';
|
|
3
|
+
/** 合计行 */
|
|
4
|
+
export interface IDifferenceTotal {
|
|
5
|
+
/** 凭证合计金额总计 */
|
|
6
|
+
voucherTotal: number;
|
|
7
|
+
/** 本次扣除金额总计 */
|
|
8
|
+
deductTotal: number;
|
|
9
|
+
}
|
|
10
|
+
/** 明细行 */
|
|
11
|
+
export interface IDifferenceRow {
|
|
12
|
+
/** 唯一标识 */
|
|
13
|
+
$index?: string;
|
|
14
|
+
/** 合计金额 */
|
|
15
|
+
voucherTotalAmt?: number;
|
|
16
|
+
/** 本次扣除金额 */
|
|
17
|
+
currentDeductAmt?: number;
|
|
18
|
+
/** 凭证类型 */
|
|
19
|
+
voucherType?: string;
|
|
20
|
+
/** 凭证号码 */
|
|
21
|
+
deductVoucherNo?: string;
|
|
22
|
+
/** 开具日期 */
|
|
23
|
+
issueDate?: string;
|
|
24
|
+
/** 备注 */
|
|
25
|
+
remark?: string;
|
|
26
|
+
/** 来源 */
|
|
27
|
+
source?: string;
|
|
28
|
+
}
|
|
29
|
+
export interface IData {
|
|
30
|
+
/** 申报项目代码 */
|
|
31
|
+
projectCode?: string;
|
|
32
|
+
/** 含税销售额 */
|
|
33
|
+
amountIncludeTax?: number;
|
|
34
|
+
/** 本次扣除金额总计 */
|
|
35
|
+
deductTotal: number;
|
|
36
|
+
/** 明细数据 */
|
|
37
|
+
rows?: IDifferenceRow[];
|
|
38
|
+
}
|
|
39
|
+
export interface IDifferenceInputModalProps {
|
|
40
|
+
/** 是否可见 */
|
|
41
|
+
open?: boolean;
|
|
42
|
+
/** 合计 */
|
|
43
|
+
total?: IDifferenceTotal;
|
|
44
|
+
/** 点击取消 */
|
|
45
|
+
onCancel?: () => void;
|
|
46
|
+
value?: IData;
|
|
47
|
+
/** 点击确定 */
|
|
48
|
+
onOk?: (data: IData) => void;
|
|
49
|
+
}
|
|
50
|
+
/** 数据来源枚举 */
|
|
51
|
+
export declare enum DataSrcEnum {
|
|
52
|
+
/** 手工录入 */
|
|
53
|
+
MANUAL = 1,
|
|
54
|
+
/** 勾选录入 */
|
|
55
|
+
CHECK = 2,
|
|
56
|
+
/** 模板录入 */
|
|
57
|
+
TEMPLATE = 3
|
|
58
|
+
}
|
|
59
|
+
export declare const dataSrcOptions: {
|
|
60
|
+
value: DataSrcEnum;
|
|
61
|
+
label: string;
|
|
62
|
+
}[];
|
|
63
|
+
/** 最多只允许输入两位小数的校验器 */
|
|
64
|
+
export declare const maxTwoDecimalsValidator: (_rule: any, value: any) => Promise<void>;
|
|
65
|
+
/**
|
|
66
|
+
* 本次扣除金额不能大于凭证合计金额的校验器
|
|
67
|
+
*/
|
|
68
|
+
export declare const deductAmtNotExceedVoucherTotalValidator: (_rule: any, value: any) => Promise<void>;
|
|
69
|
+
/**
|
|
70
|
+
* 差额录入弹窗(静态)
|
|
71
|
+
*/
|
|
72
|
+
export declare function DifferenceInputModal(props: IDifferenceInputModalProps): JSX.Element;
|
|
73
|
+
export default DifferenceInputModal;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { IData } from '../../../../DifferenceInputModal';
|
|
2
|
+
export default class DifferenceInputState {
|
|
3
|
+
/** 是否启用差额开票 */
|
|
4
|
+
enabled: boolean;
|
|
5
|
+
/** 差额开票弹框是否打开 */
|
|
6
|
+
open: boolean;
|
|
7
|
+
/** 差额开票数据 */
|
|
8
|
+
data?: IData;
|
|
9
|
+
/** 含税销售额 */
|
|
10
|
+
amountIncludeTax?: number;
|
|
11
|
+
}
|
|
@@ -7,6 +7,7 @@ import { IInvoiceTypeModalProps } from '../../../InvoiceTypeModal';
|
|
|
7
7
|
import { TaxClassificationProps } from '../../../TaxClassificationCodeModal';
|
|
8
8
|
import AutoComplete from './AutoComplete';
|
|
9
9
|
import PassengerListState from './PassengerListState';
|
|
10
|
+
import DifferenceInputState from './DifferenceInputState';
|
|
10
11
|
export default class InvoiceControllerState {
|
|
11
12
|
/**
|
|
12
13
|
* 组件模式
|
|
@@ -61,5 +62,7 @@ export default class InvoiceControllerState {
|
|
|
61
62
|
* 旅客运输列表
|
|
62
63
|
*/
|
|
63
64
|
passengerListState: PassengerListState;
|
|
65
|
+
/** 差额开票 */
|
|
66
|
+
differenceInputState: DifferenceInputState;
|
|
64
67
|
addGoodsCheck?: any;
|
|
65
68
|
}
|
|
@@ -10,7 +10,7 @@ export declare const format15: (value: number | string, defaultFractionDigits?:
|
|
|
10
10
|
*/
|
|
11
11
|
export declare function countAmountIncludeTax(quantity?: number | string, priceIncludeTax?: number | string, calculatingDigits?: number): number | undefined;
|
|
12
12
|
/**
|
|
13
|
-
* 不含税金额 =
|
|
13
|
+
* 不含税金额 = 含税金额 - 税额
|
|
14
14
|
* @param amountIncludeTax 含税金额
|
|
15
15
|
* @param taxAmount 税额
|
|
16
16
|
* @returns 不含税金额
|
package/dist/index.d.ts
CHANGED
|
@@ -6,3 +6,6 @@ export { default as InvoiceTypeModal } from './InvoiceTypeModal';
|
|
|
6
6
|
export type { IInvoiceTypeModalProps } from './InvoiceTypeModal';
|
|
7
7
|
export { default as TaxClassificationModal } from './TaxClassificationCodeModal';
|
|
8
8
|
export type { TaxClassificationProps } from './TaxClassificationCodeModal';
|
|
9
|
+
/** */
|
|
10
|
+
export { DifferenceInputModal } from './DifferenceInputModal';
|
|
11
|
+
export type { IDifferenceInputModalProps } from './DifferenceInputModal';
|