kts-component-invoice-operate 3.2.156-1 → 3.2.156-2
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/Invoice/InvoiceController/InvoiceControllerState/GoodsListState/IGood/index.d.ts +1 -0
- package/dist/index.esm.js +6 -0
- package/dist/index.js +6 -0
- package/package.json +1 -1
- package/src/Invoice/InvoiceController/InvoiceControllerState/GoodsListState/IGood/index.ts +2 -0
- package/src/Invoice/ui/default/GoodsList/hook/useColumns/ui/RowMenu/hook/useDelItem/index.tsx +3 -1
package/dist/index.esm.js
CHANGED
|
@@ -10768,6 +10768,8 @@ function SvgSpot(props) {
|
|
|
10768
10768
|
}
|
|
10769
10769
|
|
|
10770
10770
|
var useDelItem = (function (goods) {
|
|
10771
|
+
var _goods$referenceLines;
|
|
10772
|
+
|
|
10771
10773
|
var controller = Invoice.useInvoiceController();
|
|
10772
10774
|
var model = controller.useMemo(function (s) {
|
|
10773
10775
|
return s.model;
|
|
@@ -10779,6 +10781,10 @@ var useDelItem = (function (goods) {
|
|
|
10779
10781
|
controller.delGood(goods.$index);
|
|
10780
10782
|
}, [controller, goods.$index]);
|
|
10781
10783
|
|
|
10784
|
+
if (goods.lineAttribute === LineAttributeType$1.正常 && (goods === null || goods === void 0 ? void 0 : goods.referenceLines) && (goods === null || goods === void 0 ? void 0 : (_goods$referenceLines = goods.referenceLines) === null || _goods$referenceLines === void 0 ? void 0 : _goods$referenceLines.length) > 0) {
|
|
10785
|
+
return undefined;
|
|
10786
|
+
}
|
|
10787
|
+
|
|
10782
10788
|
if (goods.lineAttribute === LineAttributeType$1.被折扣行) {
|
|
10783
10789
|
return undefined;
|
|
10784
10790
|
}
|
package/dist/index.js
CHANGED
|
@@ -10778,6 +10778,8 @@ function SvgSpot(props) {
|
|
|
10778
10778
|
}
|
|
10779
10779
|
|
|
10780
10780
|
var useDelItem = (function (goods) {
|
|
10781
|
+
var _goods$referenceLines;
|
|
10782
|
+
|
|
10781
10783
|
var controller = Invoice.useInvoiceController();
|
|
10782
10784
|
var model = controller.useMemo(function (s) {
|
|
10783
10785
|
return s.model;
|
|
@@ -10789,6 +10791,10 @@ var useDelItem = (function (goods) {
|
|
|
10789
10791
|
controller.delGood(goods.$index);
|
|
10790
10792
|
}, [controller, goods.$index]);
|
|
10791
10793
|
|
|
10794
|
+
if (goods.lineAttribute === LineAttributeType$1.正常 && (goods === null || goods === void 0 ? void 0 : goods.referenceLines) && (goods === null || goods === void 0 ? void 0 : (_goods$referenceLines = goods.referenceLines) === null || _goods$referenceLines === void 0 ? void 0 : _goods$referenceLines.length) > 0) {
|
|
10795
|
+
return undefined;
|
|
10796
|
+
}
|
|
10797
|
+
|
|
10792
10798
|
if (goods.lineAttribute === LineAttributeType$1.被折扣行) {
|
|
10793
10799
|
return undefined;
|
|
10794
10800
|
}
|
package/package.json
CHANGED
package/src/Invoice/ui/default/GoodsList/hook/useColumns/ui/RowMenu/hook/useDelItem/index.tsx
CHANGED
|
@@ -16,7 +16,9 @@ export default (goods: IGood) => {
|
|
|
16
16
|
const onClick = React.useCallback(() => {
|
|
17
17
|
controller.delGood(goods.$index);
|
|
18
18
|
}, [controller, goods.$index]);
|
|
19
|
-
|
|
19
|
+
if (goods.lineAttribute === LineAttributeType.正常 && goods?.referenceLines && goods?.referenceLines?.length > 0 ) {
|
|
20
|
+
return undefined;
|
|
21
|
+
}
|
|
20
22
|
if (goods.lineAttribute === LineAttributeType.被折扣行) {
|
|
21
23
|
return undefined;
|
|
22
24
|
}
|