kts-component-invoice-operate 3.2.228-fuling → 3.2.229
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/README.md +4 -0
- package/dist/Invoice/InvoiceController/InvoiceControllerState/GoodsListState/IGood/index.d.ts +1 -0
- package/dist/Invoice/InvoiceController/InvoiceControllerState/GoodsListState/ImportGoods/index.d.ts +2 -0
- package/dist/Invoice/InvoiceController/InvoiceControllerState/GoodsListState/index.d.ts +2 -0
- package/dist/Invoice/ui/default/GoodsList/index.d.ts +1 -0
- package/dist/Invoice/ui/default/GoodsList/ui/AddRowButton/index.d.ts +1 -1
- package/dist/Invoice/ui/digtal/GoodsList/index.d.ts +1 -0
- package/dist/Invoice/ui/digtal/GoodsList/ui/TaxIncludedSwitch/index.d.ts +4 -1
- package/dist/index.esm.js +707 -251
- package/dist/index.js +706 -250
- package/package.json +1 -1
- package/src/Invoice/Invoice-digtal/_test/easiest/index.tsx +1 -1
- package/src/Invoice/Invoice-digtal/_test/realEstateInfo/index.tsx +69 -7
- package/src/Invoice/Invoice-digtal/index.md +2 -9
- package/src/Invoice/InvoiceController/InvoiceControllerState/GoodsListState/IGood/index.ts +2 -0
- package/src/Invoice/InvoiceController/InvoiceControllerState/GoodsListState/ImportGoods/index.ts +3 -0
- package/src/Invoice/InvoiceController/InvoiceControllerState/GoodsListState/index.ts +3 -0
- package/src/Invoice/InvoiceController/fns/saveEditGood.ts +2 -2
- package/src/Invoice/_test/deduction/index.tsx +28 -6
- package/src/Invoice/index.md +4 -4
- package/src/Invoice/ui/default/GoodsList/index.tsx +3 -1
- package/src/Invoice/ui/default/GoodsList/ui/AddRowButton/index.tsx +8 -1
- package/src/Invoice/ui/default/ImportGoodsDrawer/index.tsx +4 -1
- package/src/Invoice/ui/digtal/Architecture/index.tsx +1 -1
- package/src/Invoice/ui/digtal/FreightList/index.tsx +1 -1
- package/src/Invoice/ui/digtal/GoodsList/hook/useColumns/index.tsx +37 -23
- package/src/Invoice/ui/digtal/GoodsList/index.tsx +3 -1
- package/src/Invoice/ui/digtal/GoodsList/ui/AddRowButton/index.tsx +20 -10
- package/src/Invoice/ui/digtal/GoodsList/ui/TableVirtual/index.tsx +11 -6
- package/src/Invoice/ui/digtal/GoodsList/ui/TaxIncludedSwitch/index.tsx +5 -2
- package/src/Invoice/ui/digtal/RealEstateInfo/index.less +7 -0
- package/src/Invoice/ui/digtal/RealEstateInfo/index.tsx +363 -104
- package/src/Invoice/ui/digtal/StakeFarmerholder/index.tsx +7 -6
- package/src/Invoice/ui/digtal/Stakeholder/index.tsx +22 -4
package/dist/index.esm.js
CHANGED
|
@@ -8,7 +8,7 @@ import { message as message$1, TableManual, Switch, AutoComplete as AutoComplete
|
|
|
8
8
|
import classnames from 'classnames';
|
|
9
9
|
import { Table } from 'kts-components-antd-x4-v4';
|
|
10
10
|
import { render } from 'react-dom';
|
|
11
|
-
import { DatePicker, Row as Row$1, Col as Col$1,
|
|
11
|
+
import { DatePicker, Row as Row$1, Col as Col$1, Input as Input$2, Cascader, Select as Select$2 } from 'kts-components-antd-x4';
|
|
12
12
|
import { Input as Input$3, NumberPicker } from '@formily/antd-components';
|
|
13
13
|
import { createAsyncFormActions, FormEffectHooks, SchemaForm, FormButtonGroup, SchemaMarkupField } from '@formily/antd';
|
|
14
14
|
|
|
@@ -981,6 +981,7 @@ var ImportGoods = /*#__PURE__*/_createClass(function ImportGoods() {
|
|
|
981
981
|
this.dataSource = [];
|
|
982
982
|
this.pagination = {};
|
|
983
983
|
this.isVisibleDrawer = false;
|
|
984
|
+
this.filter = {};
|
|
984
985
|
this.topExpand = void 0;
|
|
985
986
|
|
|
986
987
|
this.verifyFn = /*#__PURE__*/function () {
|
|
@@ -1174,6 +1175,7 @@ var GoodsListState = /*#__PURE__*/_createClass(function GoodsListState() {
|
|
|
1174
1175
|
this.isSalesGifts = false;
|
|
1175
1176
|
this.addComparisonIndex = void 0;
|
|
1176
1177
|
this.drag = new Drag();
|
|
1178
|
+
this.isValidateGood = true;
|
|
1177
1179
|
});
|
|
1178
1180
|
|
|
1179
1181
|
var FreightListState = /*#__PURE__*/_createClass(function FreightListState() {
|
|
@@ -2217,7 +2219,7 @@ var saveEditGood = /*#__PURE__*/(function () {
|
|
|
2217
2219
|
switch (_context.prev = _context.next) {
|
|
2218
2220
|
case 0:
|
|
2219
2221
|
editGood = state.goodsListState.editGood;
|
|
2220
|
-
form = state.goodsListState.form;
|
|
2222
|
+
form = state.goodsListState.form; // const isValidateGood = state.goodsListState.isValidateGood
|
|
2221
2223
|
|
|
2222
2224
|
if (!(!editGood || !form || state.goodsListState.importGoods.isVisibleDrawer || state.calculatingField)) {
|
|
2223
2225
|
_context.next = 4;
|
|
@@ -10967,7 +10969,7 @@ var Statistics = (function () {
|
|
|
10967
10969
|
}, /*#__PURE__*/React.createElement("label", null, "\uFF08\u5C0F\u5199\uFF09 ", lineAmountIncludeTax === '' ? '' : parseFloat(lineAmountIncludeTax).toFixed(2)))));
|
|
10968
10970
|
});
|
|
10969
10971
|
|
|
10970
|
-
var AddRowButton = (function () {
|
|
10972
|
+
var AddRowButton = (function (props) {
|
|
10971
10973
|
var controller = Invoice.useInvoiceController();
|
|
10972
10974
|
var model = controller.useMemo(function (s) {
|
|
10973
10975
|
return s.model;
|
|
@@ -11000,24 +11002,54 @@ var AddRowButton = (function () {
|
|
|
11000
11002
|
var disabled = React.useMemo(function () {
|
|
11001
11003
|
return typeof goodMax === 'number' ? goodsNum >= goodMax : !!searchValue;
|
|
11002
11004
|
}, [goodMax, goodsNum, searchValue]);
|
|
11003
|
-
var onClick = React.useCallback( /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function
|
|
11004
|
-
return _regeneratorRuntime().wrap(function
|
|
11005
|
+
var onClick = React.useCallback( /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2() {
|
|
11006
|
+
return _regeneratorRuntime().wrap(function _callee2$(_context2) {
|
|
11005
11007
|
while (1) {
|
|
11006
|
-
switch (
|
|
11008
|
+
switch (_context2.prev = _context2.next) {
|
|
11007
11009
|
case 0:
|
|
11008
|
-
|
|
11009
|
-
return
|
|
11010
|
+
_context2.next = 2;
|
|
11011
|
+
return controller.run( /*#__PURE__*/function () {
|
|
11012
|
+
var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(s) {
|
|
11013
|
+
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
11014
|
+
while (1) {
|
|
11015
|
+
switch (_context.prev = _context.next) {
|
|
11016
|
+
case 0:
|
|
11017
|
+
if (!s.addGoodsCheck) {
|
|
11018
|
+
_context.next = 3;
|
|
11019
|
+
break;
|
|
11020
|
+
}
|
|
11021
|
+
|
|
11022
|
+
_context.next = 3;
|
|
11023
|
+
return s.addGoodsCheck();
|
|
11024
|
+
|
|
11025
|
+
case 3:
|
|
11026
|
+
case "end":
|
|
11027
|
+
return _context.stop();
|
|
11028
|
+
}
|
|
11029
|
+
}
|
|
11030
|
+
}, _callee);
|
|
11031
|
+
}));
|
|
11032
|
+
|
|
11033
|
+
return function (_x) {
|
|
11034
|
+
return _ref2.apply(this, arguments);
|
|
11035
|
+
};
|
|
11036
|
+
}());
|
|
11010
11037
|
|
|
11011
11038
|
case 2:
|
|
11012
|
-
|
|
11039
|
+
console.log('continue');
|
|
11040
|
+
_context2.next = 5;
|
|
11041
|
+
return addGood$1(controller);
|
|
11042
|
+
|
|
11043
|
+
case 5:
|
|
11044
|
+
_context2.next = 7;
|
|
11013
11045
|
return rollBottom(controller, rootElement);
|
|
11014
11046
|
|
|
11015
|
-
case
|
|
11047
|
+
case 7:
|
|
11016
11048
|
case "end":
|
|
11017
|
-
return
|
|
11049
|
+
return _context2.stop();
|
|
11018
11050
|
}
|
|
11019
11051
|
}
|
|
11020
|
-
},
|
|
11052
|
+
}, _callee2);
|
|
11021
11053
|
})), [controller, rootElement]);
|
|
11022
11054
|
if (isAddRow === false) return /*#__PURE__*/React.createElement(React.Fragment, null);
|
|
11023
11055
|
if (model === 'prefab') return /*#__PURE__*/React.createElement(React.Fragment, null);
|
|
@@ -11029,35 +11061,35 @@ var AddRowButton = (function () {
|
|
|
11029
11061
|
});
|
|
11030
11062
|
/** 添加一个空货物 */
|
|
11031
11063
|
|
|
11032
|
-
function addGood$1(
|
|
11064
|
+
function addGood$1(_x2) {
|
|
11033
11065
|
return _addGood.apply(this, arguments);
|
|
11034
11066
|
}
|
|
11035
11067
|
/** 货物列表,滚动到底部 */
|
|
11036
11068
|
|
|
11037
11069
|
|
|
11038
11070
|
function _addGood() {
|
|
11039
|
-
_addGood = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function
|
|
11040
|
-
return _regeneratorRuntime().wrap(function
|
|
11071
|
+
_addGood = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee4(controller) {
|
|
11072
|
+
return _regeneratorRuntime().wrap(function _callee4$(_context4) {
|
|
11041
11073
|
while (1) {
|
|
11042
|
-
switch (
|
|
11074
|
+
switch (_context4.prev = _context4.next) {
|
|
11043
11075
|
case 0:
|
|
11044
|
-
|
|
11076
|
+
_context4.next = 2;
|
|
11045
11077
|
return controller.saveEditGood();
|
|
11046
11078
|
|
|
11047
11079
|
case 2:
|
|
11048
|
-
|
|
11080
|
+
_context4.next = 4;
|
|
11049
11081
|
return controller.wait();
|
|
11050
11082
|
|
|
11051
11083
|
case 4:
|
|
11052
|
-
|
|
11084
|
+
_context4.next = 6;
|
|
11053
11085
|
return controller.run( /*#__PURE__*/function () {
|
|
11054
|
-
var
|
|
11055
|
-
return _regeneratorRuntime().wrap(function
|
|
11086
|
+
var _ref3 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee3(s) {
|
|
11087
|
+
return _regeneratorRuntime().wrap(function _callee3$(_context3) {
|
|
11056
11088
|
while (1) {
|
|
11057
|
-
switch (
|
|
11089
|
+
switch (_context3.prev = _context3.next) {
|
|
11058
11090
|
case 0:
|
|
11059
11091
|
if (!s.goodsListState.editGood) {
|
|
11060
|
-
|
|
11092
|
+
_context3.next = 3;
|
|
11061
11093
|
break;
|
|
11062
11094
|
}
|
|
11063
11095
|
|
|
@@ -11065,74 +11097,74 @@ function _addGood() {
|
|
|
11065
11097
|
content: '你正在编辑一个货物',
|
|
11066
11098
|
key: '你正在编辑一个货物'
|
|
11067
11099
|
});
|
|
11068
|
-
return
|
|
11100
|
+
return _context3.abrupt("return");
|
|
11069
11101
|
|
|
11070
11102
|
case 3:
|
|
11071
|
-
|
|
11103
|
+
_context3.next = 5;
|
|
11072
11104
|
return controller.addGood({
|
|
11073
11105
|
taxRate: s.goodsListState.defaultRate,
|
|
11074
11106
|
lineAttribute: LineAttributeType$1.正常
|
|
11075
11107
|
});
|
|
11076
11108
|
|
|
11077
11109
|
case 5:
|
|
11078
|
-
s.goodsListState.editGood =
|
|
11110
|
+
s.goodsListState.editGood = _context3.sent;
|
|
11079
11111
|
|
|
11080
11112
|
case 6:
|
|
11081
11113
|
case "end":
|
|
11082
|
-
return
|
|
11114
|
+
return _context3.stop();
|
|
11083
11115
|
}
|
|
11084
11116
|
}
|
|
11085
|
-
},
|
|
11117
|
+
}, _callee3);
|
|
11086
11118
|
}));
|
|
11087
11119
|
|
|
11088
|
-
return function (
|
|
11089
|
-
return
|
|
11120
|
+
return function (_x5) {
|
|
11121
|
+
return _ref3.apply(this, arguments);
|
|
11090
11122
|
};
|
|
11091
11123
|
}());
|
|
11092
11124
|
|
|
11093
11125
|
case 6:
|
|
11094
11126
|
case "end":
|
|
11095
|
-
return
|
|
11127
|
+
return _context4.stop();
|
|
11096
11128
|
}
|
|
11097
11129
|
}
|
|
11098
|
-
},
|
|
11130
|
+
}, _callee4);
|
|
11099
11131
|
}));
|
|
11100
11132
|
return _addGood.apply(this, arguments);
|
|
11101
11133
|
}
|
|
11102
11134
|
|
|
11103
|
-
function rollBottom(
|
|
11135
|
+
function rollBottom(_x3, _x4) {
|
|
11104
11136
|
return _rollBottom.apply(this, arguments);
|
|
11105
11137
|
}
|
|
11106
11138
|
|
|
11107
11139
|
function _rollBottom() {
|
|
11108
|
-
_rollBottom = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function
|
|
11140
|
+
_rollBottom = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee5(controller, rootElement) {
|
|
11109
11141
|
var cont;
|
|
11110
|
-
return _regeneratorRuntime().wrap(function
|
|
11142
|
+
return _regeneratorRuntime().wrap(function _callee5$(_context5) {
|
|
11111
11143
|
while (1) {
|
|
11112
|
-
switch (
|
|
11144
|
+
switch (_context5.prev = _context5.next) {
|
|
11113
11145
|
case 0:
|
|
11114
|
-
|
|
11146
|
+
_context5.next = 2;
|
|
11115
11147
|
return controller.wait();
|
|
11116
11148
|
|
|
11117
11149
|
case 2:
|
|
11118
11150
|
cont = rootElement === null || rootElement === void 0 ? void 0 : rootElement.querySelector('.ktsAntX-table-body');
|
|
11119
11151
|
|
|
11120
11152
|
if (cont) {
|
|
11121
|
-
|
|
11153
|
+
_context5.next = 5;
|
|
11122
11154
|
break;
|
|
11123
11155
|
}
|
|
11124
11156
|
|
|
11125
|
-
return
|
|
11157
|
+
return _context5.abrupt("return");
|
|
11126
11158
|
|
|
11127
11159
|
case 5:
|
|
11128
11160
|
cont.scrollTop = cont.scrollHeight;
|
|
11129
11161
|
|
|
11130
11162
|
case 6:
|
|
11131
11163
|
case "end":
|
|
11132
|
-
return
|
|
11164
|
+
return _context5.stop();
|
|
11133
11165
|
}
|
|
11134
11166
|
}
|
|
11135
|
-
},
|
|
11167
|
+
}, _callee5);
|
|
11136
11168
|
}));
|
|
11137
11169
|
return _rollBottom.apply(this, arguments);
|
|
11138
11170
|
}
|
|
@@ -16918,7 +16950,9 @@ var Main = decorator(Form.create())(function (props) {
|
|
|
16918
16950
|
className: "kts-invoice-operate-goods-list-able"
|
|
16919
16951
|
}, /*#__PURE__*/React.createElement("div", {
|
|
16920
16952
|
className: "kts-invoice-operate-goods-list-able-list"
|
|
16921
|
-
}, /*#__PURE__*/React.createElement(AddRowButton,
|
|
16953
|
+
}, /*#__PURE__*/React.createElement(AddRowButton, {
|
|
16954
|
+
addGoodsCheck: props.addGoodsCheck
|
|
16955
|
+
}), endowCodeButton.button, delRowButton.button, mergeDetails.button, mergeDiscount.button, addDiscountRowButton.drawer, salesDiscount.button, salesGifts.button, /*#__PURE__*/React.createElement(Search, null)), /*#__PURE__*/React.createElement("div", {
|
|
16922
16956
|
className: "kts-invoice-operate-goods-list-able-extend"
|
|
16923
16957
|
}, props.menuExpansion, /*#__PURE__*/React.createElement(DescribeSwitch, null), /*#__PURE__*/React.createElement(TaxIncludedSwitch, null))), /*#__PURE__*/React.createElement("div", {
|
|
16924
16958
|
className: classnames('kts-invoice-operate-goods-list-table', {
|
|
@@ -17922,7 +17956,7 @@ var Stakeholder$1 = decorator(Form.create())(function (props) {
|
|
|
17922
17956
|
placeholder: "\u8BF7\u8F93\u5165\u7EDF\u4E00\u793E\u4F1A\u4FE1\u7528\u4EE3\u7801/\u7EB3\u7A0E\u4EBA\u8BC6\u522B\u53F7",
|
|
17923
17957
|
autoComplete: "off"
|
|
17924
17958
|
})))), /*#__PURE__*/React.createElement(Col, {
|
|
17925
|
-
span: 10 +
|
|
17959
|
+
span: 10 + leqispanW,
|
|
17926
17960
|
style: {
|
|
17927
17961
|
display: isExpand ? undefined : 'none'
|
|
17928
17962
|
}
|
|
@@ -17939,7 +17973,7 @@ var Stakeholder$1 = decorator(Form.create())(function (props) {
|
|
|
17939
17973
|
placeholder: "\u8BF7\u8F93\u5165\u8D2D\u4E70\u65B9\u5730\u5740",
|
|
17940
17974
|
autoComplete: "off"
|
|
17941
17975
|
})))), /*#__PURE__*/React.createElement(Col, {
|
|
17942
|
-
span: 10 +
|
|
17976
|
+
span: 10 + leqispanW,
|
|
17943
17977
|
style: {
|
|
17944
17978
|
display: isExpand ? undefined : 'none'
|
|
17945
17979
|
}
|
|
@@ -17953,7 +17987,22 @@ var Stakeholder$1 = decorator(Form.create())(function (props) {
|
|
|
17953
17987
|
readOnly: isReadOnly('buyerPhone'),
|
|
17954
17988
|
placeholder: "\u8BF7\u8F93\u5165\u7535\u8BDD",
|
|
17955
17989
|
autoComplete: "off"
|
|
17956
|
-
})))), /*#__PURE__*/React.createElement(Col, {
|
|
17990
|
+
})))), props.leqi && /*#__PURE__*/React.createElement(Col, {
|
|
17991
|
+
span: 4,
|
|
17992
|
+
style: {
|
|
17993
|
+
display: isExpand ? undefined : 'none'
|
|
17994
|
+
}
|
|
17995
|
+
}, /*#__PURE__*/React.createElement(Form.Item, {
|
|
17996
|
+
colon: false
|
|
17997
|
+
}, getFieldDecorator('buyerAddressPhoneFlag', {
|
|
17998
|
+
valuePropName: 'checked'
|
|
17999
|
+
})( /*#__PURE__*/React.createElement(Checkbox$1, {
|
|
18000
|
+
onChange: props === null || props === void 0 ? void 0 : props.invoiceMarkCallback,
|
|
18001
|
+
disabled: isReadOnly('buyerAddressPhoneFlag'),
|
|
18002
|
+
style: {
|
|
18003
|
+
whiteSpace: 'nowrap'
|
|
18004
|
+
}
|
|
18005
|
+
}, "\u662F\u5426\u5C55\u793A")))), /*#__PURE__*/React.createElement(Col, {
|
|
17957
18006
|
span: 10 + leqispanW,
|
|
17958
18007
|
style: {
|
|
17959
18008
|
display: isExpand ? undefined : 'none'
|
|
@@ -18045,7 +18094,7 @@ var Stakeholder$1 = decorator(Form.create())(function (props) {
|
|
|
18045
18094
|
placeholder: "\u8BF7\u8F93\u5165\u7EDF\u4E00\u793E\u4F1A\u4FE1\u7528\u4EE3\u7801/\u7EB3\u7A0E\u4EBA\u8BC6\u522B\u53F7",
|
|
18046
18095
|
autoComplete: "off"
|
|
18047
18096
|
})))), /*#__PURE__*/React.createElement(Col, {
|
|
18048
|
-
span: 10 +
|
|
18097
|
+
span: 10 + leqispanW,
|
|
18049
18098
|
style: {
|
|
18050
18099
|
display: isExpand ? undefined : 'none'
|
|
18051
18100
|
}
|
|
@@ -18062,7 +18111,7 @@ var Stakeholder$1 = decorator(Form.create())(function (props) {
|
|
|
18062
18111
|
placeholder: "\u8BF7\u8F93\u5165\u9500\u552E\u65B9\u5730\u5740",
|
|
18063
18112
|
autoComplete: "off"
|
|
18064
18113
|
})))), /*#__PURE__*/React.createElement(Col, {
|
|
18065
|
-
span: 10 +
|
|
18114
|
+
span: 10 + leqispanW,
|
|
18066
18115
|
style: {
|
|
18067
18116
|
display: isExpand ? undefined : 'none'
|
|
18068
18117
|
}
|
|
@@ -18076,7 +18125,22 @@ var Stakeholder$1 = decorator(Form.create())(function (props) {
|
|
|
18076
18125
|
readOnly: isReadOnly('sellerPhone'),
|
|
18077
18126
|
placeholder: "\u8BF7\u8F93\u5165\u7535\u8BDD",
|
|
18078
18127
|
autoComplete: "off"
|
|
18079
|
-
})))), /*#__PURE__*/React.createElement(Col, {
|
|
18128
|
+
})))), props.leqi && /*#__PURE__*/React.createElement(Col, {
|
|
18129
|
+
span: 4,
|
|
18130
|
+
style: {
|
|
18131
|
+
display: isExpand ? undefined : 'none'
|
|
18132
|
+
}
|
|
18133
|
+
}, /*#__PURE__*/React.createElement(Form.Item, {
|
|
18134
|
+
colon: false
|
|
18135
|
+
}, getFieldDecorator('sellerAddressPhoneFlag', {
|
|
18136
|
+
valuePropName: 'checked'
|
|
18137
|
+
})( /*#__PURE__*/React.createElement(Checkbox$1, {
|
|
18138
|
+
onChange: props === null || props === void 0 ? void 0 : props.invoiceMarkCallback,
|
|
18139
|
+
disabled: isReadOnly('sellerAddressPhoneFlag'),
|
|
18140
|
+
style: {
|
|
18141
|
+
whiteSpace: 'nowrap'
|
|
18142
|
+
}
|
|
18143
|
+
}, "\u662F\u5426\u5C55\u793A")))), /*#__PURE__*/React.createElement(Col, {
|
|
18080
18144
|
span: 10 + leqispanW,
|
|
18081
18145
|
style: {
|
|
18082
18146
|
display: isExpand ? undefined : 'none'
|
|
@@ -19166,6 +19230,9 @@ var NationalSelect = /*#__PURE__*/function (_React$Component3) {
|
|
|
19166
19230
|
value: function render() {
|
|
19167
19231
|
var props = this.props;
|
|
19168
19232
|
var option = [{
|
|
19233
|
+
value: "156",
|
|
19234
|
+
label: "中国"
|
|
19235
|
+
}, {
|
|
19169
19236
|
value: "004",
|
|
19170
19237
|
label: "阿富汗"
|
|
19171
19238
|
}, {
|
|
@@ -19294,9 +19361,6 @@ var NationalSelect = /*#__PURE__*/function (_React$Component3) {
|
|
|
19294
19361
|
}, {
|
|
19295
19362
|
value: "152",
|
|
19296
19363
|
label: "智利"
|
|
19297
|
-
}, {
|
|
19298
|
-
value: "156",
|
|
19299
|
-
label: "中国"
|
|
19300
19364
|
}, {
|
|
19301
19365
|
value: "158",
|
|
19302
19366
|
label: "中国台湾"
|
|
@@ -20047,7 +20111,7 @@ var css_248z$j = ".kts-invoice-operate-goods-table-virtual .ktsAntX-table-body {
|
|
|
20047
20111
|
styleInject(css_248z$j);
|
|
20048
20112
|
|
|
20049
20113
|
function TableVirtual$1 (props) {
|
|
20050
|
-
var _props$
|
|
20114
|
+
var _props$dataSource4, _props$dataSource5;
|
|
20051
20115
|
|
|
20052
20116
|
var _React$useState = React.useState(null),
|
|
20053
20117
|
_React$useState2 = _slicedToArray(_React$useState, 2),
|
|
@@ -20089,8 +20153,10 @@ function TableVirtual$1 (props) {
|
|
|
20089
20153
|
}, [self, tableBody]); // 设置占位dom的搞
|
|
20090
20154
|
|
|
20091
20155
|
var placeholderHeight = React.useMemo(function () {
|
|
20092
|
-
|
|
20093
|
-
|
|
20156
|
+
var _props$dataSource = props.dataSource,
|
|
20157
|
+
dataSource = _props$dataSource === void 0 ? [] : _props$dataSource;
|
|
20158
|
+
if (!self || !rowHeight || !dataSource || !placeholder) return;
|
|
20159
|
+
var placeholderHeight = rowHeight * dataSource.length;
|
|
20094
20160
|
placeholder.style.height = "".concat(placeholderHeight, "px");
|
|
20095
20161
|
return placeholderHeight;
|
|
20096
20162
|
}, [self, rowHeight, props.dataSource, placeholder]);
|
|
@@ -20102,12 +20168,12 @@ function TableVirtual$1 (props) {
|
|
|
20102
20168
|
}, [tableBody, rowHeight, placeholderHeight]); // 计算渲染的行
|
|
20103
20169
|
|
|
20104
20170
|
var dataSource = React.useMemo(function () {
|
|
20105
|
-
var _props$
|
|
20171
|
+
var _props$dataSource2;
|
|
20106
20172
|
|
|
20107
20173
|
if (!props.dataSource) return [];
|
|
20108
20174
|
if (props.dataSource.length < 10) return props.dataSource;
|
|
20109
20175
|
if (!rowSize) return [props.dataSource[0]];
|
|
20110
|
-
return (_props$
|
|
20176
|
+
return (_props$dataSource2 = props.dataSource) === null || _props$dataSource2 === void 0 ? void 0 : _props$dataSource2.slice(pointer, pointer + 2 * rowSize);
|
|
20111
20177
|
}, [props.dataSource, pointer, rowSize]); // 监听滚动
|
|
20112
20178
|
|
|
20113
20179
|
React.useEffect(function () {
|
|
@@ -20126,17 +20192,24 @@ function TableVirtual$1 (props) {
|
|
|
20126
20192
|
}, [self, placeholder, props.dataSource, rowHeight, rowSize]); // 移动列表
|
|
20127
20193
|
|
|
20128
20194
|
React.useEffect(function () {
|
|
20195
|
+
var _props$dataSource3;
|
|
20196
|
+
|
|
20129
20197
|
if (!self) return;
|
|
20130
20198
|
var table = self.querySelector('.ktsAntX-table .ktsAntX-table-body>table');
|
|
20131
20199
|
if (!table) return;
|
|
20132
|
-
|
|
20133
|
-
|
|
20200
|
+
|
|
20201
|
+
if ((((_props$dataSource3 = props.dataSource) === null || _props$dataSource3 === void 0 ? void 0 : _props$dataSource3.length) || 0) < 10) {
|
|
20202
|
+
table.style.top = '0px';
|
|
20203
|
+
} else {
|
|
20204
|
+
table.style.top = "".concat(pointer * rowHeight, "px");
|
|
20205
|
+
}
|
|
20206
|
+
}, [pointer, self, rowHeight, (_props$dataSource4 = props.dataSource) === null || _props$dataSource4 === void 0 ? void 0 : _props$dataSource4.length]);
|
|
20134
20207
|
React.useEffect(function () {
|
|
20135
20208
|
if (!self) return;
|
|
20136
20209
|
var cont = self.querySelector('.kts-invoice-operate-goods-table-virtual .ktsAntX-table-body');
|
|
20137
20210
|
if (!cont) return;
|
|
20138
20211
|
cont.scrollTop = 0;
|
|
20139
|
-
}, [(_props$
|
|
20212
|
+
}, [(_props$dataSource5 = props.dataSource) === null || _props$dataSource5 === void 0 ? void 0 : _props$dataSource5.length]);
|
|
20140
20213
|
return /*#__PURE__*/React.createElement("span", {
|
|
20141
20214
|
className: "kts-invoice-operate-goods-table-virtual",
|
|
20142
20215
|
ref: function ref(e) {
|
|
@@ -20379,43 +20452,86 @@ function addGood$2(_x) {
|
|
|
20379
20452
|
|
|
20380
20453
|
|
|
20381
20454
|
function _addGood$1() {
|
|
20382
|
-
_addGood$1 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function
|
|
20383
|
-
|
|
20455
|
+
_addGood$1 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee5(controller) {
|
|
20456
|
+
var _controller$formList$;
|
|
20457
|
+
|
|
20458
|
+
return _regeneratorRuntime().wrap(function _callee5$(_context5) {
|
|
20384
20459
|
while (1) {
|
|
20385
|
-
switch (
|
|
20460
|
+
switch (_context5.prev = _context5.next) {
|
|
20386
20461
|
case 0:
|
|
20387
|
-
|
|
20388
|
-
return controller.
|
|
20462
|
+
_context5.next = 2;
|
|
20463
|
+
return (_controller$formList$ = controller.formList.get('realEstateInfo')) === null || _controller$formList$ === void 0 ? void 0 : _controller$formList$.validateFields( /*#__PURE__*/function () {
|
|
20464
|
+
var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(err, values) {
|
|
20465
|
+
return _regeneratorRuntime().wrap(function _callee2$(_context2) {
|
|
20466
|
+
while (1) {
|
|
20467
|
+
switch (_context2.prev = _context2.next) {
|
|
20468
|
+
case 0:
|
|
20469
|
+
if (!err) {
|
|
20470
|
+
_context2.next = 3;
|
|
20471
|
+
break;
|
|
20472
|
+
}
|
|
20473
|
+
|
|
20474
|
+
message$1.error('请先填写发票行信息,再添加新的行');
|
|
20475
|
+
return _context2.abrupt("return");
|
|
20476
|
+
|
|
20477
|
+
case 3:
|
|
20478
|
+
case "end":
|
|
20479
|
+
return _context2.stop();
|
|
20480
|
+
}
|
|
20481
|
+
}
|
|
20482
|
+
}, _callee2);
|
|
20483
|
+
}));
|
|
20484
|
+
|
|
20485
|
+
return function (_x4, _x5) {
|
|
20486
|
+
return _ref2.apply(this, arguments);
|
|
20487
|
+
};
|
|
20488
|
+
}());
|
|
20389
20489
|
|
|
20390
20490
|
case 2:
|
|
20391
|
-
|
|
20392
|
-
return controller.
|
|
20491
|
+
_context5.next = 4;
|
|
20492
|
+
return controller.saveEditGood();
|
|
20393
20493
|
|
|
20394
20494
|
case 4:
|
|
20395
|
-
|
|
20495
|
+
_context5.next = 6;
|
|
20496
|
+
return controller.wait();
|
|
20497
|
+
|
|
20498
|
+
case 6:
|
|
20499
|
+
_context5.next = 8;
|
|
20396
20500
|
return controller.run( /*#__PURE__*/function () {
|
|
20397
|
-
var
|
|
20398
|
-
var _controller$state$goo;
|
|
20501
|
+
var _ref3 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee4(s) {
|
|
20502
|
+
var isValidateGood, _controller$state$goo;
|
|
20399
20503
|
|
|
20400
|
-
return _regeneratorRuntime().wrap(function
|
|
20504
|
+
return _regeneratorRuntime().wrap(function _callee4$(_context4) {
|
|
20401
20505
|
while (1) {
|
|
20402
|
-
switch (
|
|
20506
|
+
switch (_context4.prev = _context4.next) {
|
|
20403
20507
|
case 0:
|
|
20404
20508
|
if (!s.goodsListState.editGood) {
|
|
20405
|
-
|
|
20509
|
+
_context4.next = 5;
|
|
20406
20510
|
break;
|
|
20407
20511
|
}
|
|
20408
20512
|
|
|
20409
|
-
|
|
20513
|
+
// message.error({
|
|
20514
|
+
// content: '你正在编辑一个货物',
|
|
20515
|
+
// key: '你正在编辑一个货物',
|
|
20516
|
+
// });
|
|
20517
|
+
// return;
|
|
20518
|
+
isValidateGood = controller.state.goodsListState.isValidateGood;
|
|
20519
|
+
|
|
20520
|
+
if (!isValidateGood) {
|
|
20521
|
+
_context4.next = 5;
|
|
20522
|
+
break;
|
|
20523
|
+
}
|
|
20524
|
+
|
|
20525
|
+
_context4.next = 5;
|
|
20410
20526
|
return (_controller$state$goo = controller.state.goodsListState.form) === null || _controller$state$goo === void 0 ? void 0 : _controller$state$goo.validateFields( /*#__PURE__*/function () {
|
|
20411
|
-
var
|
|
20527
|
+
var _ref4 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee3(err, values) {
|
|
20412
20528
|
var firstError;
|
|
20413
|
-
return _regeneratorRuntime().wrap(function
|
|
20529
|
+
return _regeneratorRuntime().wrap(function _callee3$(_context3) {
|
|
20414
20530
|
while (1) {
|
|
20415
|
-
switch (
|
|
20531
|
+
switch (_context3.prev = _context3.next) {
|
|
20416
20532
|
case 0:
|
|
20417
20533
|
if (!err) {
|
|
20418
|
-
|
|
20534
|
+
_context3.next = 4;
|
|
20419
20535
|
break;
|
|
20420
20536
|
}
|
|
20421
20537
|
|
|
@@ -20424,50 +20540,50 @@ function _addGood$1() {
|
|
|
20424
20540
|
content: firstError.errors[0].message,
|
|
20425
20541
|
key: '你正在编辑一个货物'
|
|
20426
20542
|
});
|
|
20427
|
-
return
|
|
20543
|
+
return _context3.abrupt("return");
|
|
20428
20544
|
|
|
20429
20545
|
case 4:
|
|
20430
20546
|
case "end":
|
|
20431
|
-
return
|
|
20547
|
+
return _context3.stop();
|
|
20432
20548
|
}
|
|
20433
20549
|
}
|
|
20434
|
-
},
|
|
20550
|
+
}, _callee3);
|
|
20435
20551
|
}));
|
|
20436
20552
|
|
|
20437
|
-
return function (
|
|
20438
|
-
return
|
|
20553
|
+
return function (_x7, _x8) {
|
|
20554
|
+
return _ref4.apply(this, arguments);
|
|
20439
20555
|
};
|
|
20440
20556
|
}());
|
|
20441
20557
|
|
|
20442
|
-
case
|
|
20443
|
-
|
|
20558
|
+
case 5:
|
|
20559
|
+
_context4.next = 7;
|
|
20444
20560
|
return controller.addGood({
|
|
20445
20561
|
taxRate: s.goodsListState.defaultRate,
|
|
20446
20562
|
lineAttribute: LineAttributeType$1.正常
|
|
20447
20563
|
});
|
|
20448
20564
|
|
|
20449
|
-
case
|
|
20450
|
-
s.goodsListState.editGood =
|
|
20565
|
+
case 7:
|
|
20566
|
+
s.goodsListState.editGood = _context4.sent;
|
|
20451
20567
|
|
|
20452
|
-
case
|
|
20568
|
+
case 8:
|
|
20453
20569
|
case "end":
|
|
20454
|
-
return
|
|
20570
|
+
return _context4.stop();
|
|
20455
20571
|
}
|
|
20456
20572
|
}
|
|
20457
|
-
},
|
|
20573
|
+
}, _callee4);
|
|
20458
20574
|
}));
|
|
20459
20575
|
|
|
20460
|
-
return function (
|
|
20461
|
-
return
|
|
20576
|
+
return function (_x6) {
|
|
20577
|
+
return _ref3.apply(this, arguments);
|
|
20462
20578
|
};
|
|
20463
20579
|
}());
|
|
20464
20580
|
|
|
20465
|
-
case
|
|
20581
|
+
case 8:
|
|
20466
20582
|
case "end":
|
|
20467
|
-
return
|
|
20583
|
+
return _context5.stop();
|
|
20468
20584
|
}
|
|
20469
20585
|
}
|
|
20470
|
-
},
|
|
20586
|
+
}, _callee5);
|
|
20471
20587
|
}));
|
|
20472
20588
|
return _addGood$1.apply(this, arguments);
|
|
20473
20589
|
}
|
|
@@ -20477,34 +20593,34 @@ function rollBottom$1(_x2, _x3) {
|
|
|
20477
20593
|
}
|
|
20478
20594
|
|
|
20479
20595
|
function _rollBottom$1() {
|
|
20480
|
-
_rollBottom$1 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function
|
|
20596
|
+
_rollBottom$1 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee6(controller, rootElement) {
|
|
20481
20597
|
var cont;
|
|
20482
|
-
return _regeneratorRuntime().wrap(function
|
|
20598
|
+
return _regeneratorRuntime().wrap(function _callee6$(_context6) {
|
|
20483
20599
|
while (1) {
|
|
20484
|
-
switch (
|
|
20600
|
+
switch (_context6.prev = _context6.next) {
|
|
20485
20601
|
case 0:
|
|
20486
|
-
|
|
20602
|
+
_context6.next = 2;
|
|
20487
20603
|
return controller.wait();
|
|
20488
20604
|
|
|
20489
20605
|
case 2:
|
|
20490
20606
|
cont = rootElement === null || rootElement === void 0 ? void 0 : rootElement.querySelector('.ktsAntX-table-body');
|
|
20491
20607
|
|
|
20492
20608
|
if (cont) {
|
|
20493
|
-
|
|
20609
|
+
_context6.next = 5;
|
|
20494
20610
|
break;
|
|
20495
20611
|
}
|
|
20496
20612
|
|
|
20497
|
-
return
|
|
20613
|
+
return _context6.abrupt("return");
|
|
20498
20614
|
|
|
20499
20615
|
case 5:
|
|
20500
20616
|
cont.scrollTop = cont.scrollHeight;
|
|
20501
20617
|
|
|
20502
20618
|
case 6:
|
|
20503
20619
|
case "end":
|
|
20504
|
-
return
|
|
20620
|
+
return _context6.stop();
|
|
20505
20621
|
}
|
|
20506
20622
|
}
|
|
20507
|
-
},
|
|
20623
|
+
}, _callee6);
|
|
20508
20624
|
}));
|
|
20509
20625
|
return _rollBottom$1.apply(this, arguments);
|
|
20510
20626
|
}
|
|
@@ -21831,7 +21947,7 @@ var onChangeSwitchTax$1 = /*#__PURE__*/function () {
|
|
|
21831
21947
|
};
|
|
21832
21948
|
}();
|
|
21833
21949
|
|
|
21834
|
-
var TaxIncludedSwitch$1 = (function () {
|
|
21950
|
+
var TaxIncludedSwitch$1 = (function (props) {
|
|
21835
21951
|
var controller = Invoice.useInvoiceController();
|
|
21836
21952
|
/** 是否含税 */
|
|
21837
21953
|
|
|
@@ -21850,8 +21966,9 @@ var TaxIncludedSwitch$1 = (function () {
|
|
|
21850
21966
|
switch (_context.prev = _context.next) {
|
|
21851
21967
|
case 0:
|
|
21852
21968
|
onChangeSwitchTax$1(controller, e);
|
|
21969
|
+
props.onChange && props.onChange(e);
|
|
21853
21970
|
|
|
21854
|
-
case
|
|
21971
|
+
case 2:
|
|
21855
21972
|
case "end":
|
|
21856
21973
|
return _context.stop();
|
|
21857
21974
|
}
|
|
@@ -22756,6 +22873,9 @@ var useColumns$1 = (function (form) {
|
|
|
22756
22873
|
var changeField = controller.useMemo(function (e) {
|
|
22757
22874
|
return e.calculatingField;
|
|
22758
22875
|
}, []);
|
|
22876
|
+
var isValidateGood = controller.useMemo(function (s) {
|
|
22877
|
+
return s.goodsListState.isValidateGood;
|
|
22878
|
+
}, []);
|
|
22759
22879
|
/** 计算中启动字段 */
|
|
22760
22880
|
|
|
22761
22881
|
var setChangeField = React.useCallback(function (value) {
|
|
@@ -22850,25 +22970,37 @@ var useColumns$1 = (function (form) {
|
|
|
22850
22970
|
while (1) {
|
|
22851
22971
|
switch (_context2.prev = _context2.next) {
|
|
22852
22972
|
case 0:
|
|
22853
|
-
|
|
22973
|
+
if (!isValidateGood) {
|
|
22974
|
+
_context2.next = 11;
|
|
22975
|
+
break;
|
|
22976
|
+
}
|
|
22977
|
+
|
|
22978
|
+
_context2.next = 3;
|
|
22854
22979
|
return controller.wait();
|
|
22855
22980
|
|
|
22856
|
-
case
|
|
22981
|
+
case 3:
|
|
22857
22982
|
value = controller.state.goodsListState.editGood;
|
|
22858
22983
|
|
|
22859
22984
|
if (!(!(value === null || value === void 0 ? void 0 : value.itemName) && !(value === null || value === void 0 ? void 0 : value.itemNameSelf))) {
|
|
22860
|
-
_context2.next =
|
|
22985
|
+
_context2.next = 8;
|
|
22861
22986
|
break;
|
|
22862
22987
|
}
|
|
22863
22988
|
|
|
22864
22989
|
callback('项目名称不能为空');
|
|
22865
|
-
_context2.next =
|
|
22990
|
+
_context2.next = 9;
|
|
22866
22991
|
break;
|
|
22867
22992
|
|
|
22868
|
-
case
|
|
22993
|
+
case 8:
|
|
22869
22994
|
return _context2.abrupt("return");
|
|
22870
22995
|
|
|
22871
|
-
case
|
|
22996
|
+
case 9:
|
|
22997
|
+
_context2.next = 12;
|
|
22998
|
+
break;
|
|
22999
|
+
|
|
23000
|
+
case 11:
|
|
23001
|
+
callback();
|
|
23002
|
+
|
|
23003
|
+
case 12:
|
|
22872
23004
|
case "end":
|
|
22873
23005
|
return _context2.stop();
|
|
22874
23006
|
}
|
|
@@ -23069,24 +23201,34 @@ var useColumns$1 = (function (form) {
|
|
|
23069
23201
|
while (1) {
|
|
23070
23202
|
switch (_context6.prev = _context6.next) {
|
|
23071
23203
|
case 0:
|
|
23072
|
-
|
|
23204
|
+
if (!isValidateGood) {
|
|
23205
|
+
_context6.next = 10;
|
|
23206
|
+
break;
|
|
23207
|
+
}
|
|
23208
|
+
|
|
23209
|
+
_context6.next = 3;
|
|
23073
23210
|
return controller.wait();
|
|
23074
23211
|
|
|
23075
|
-
case
|
|
23212
|
+
case 3:
|
|
23076
23213
|
isvalue = !!value || value === 0;
|
|
23077
23214
|
isPrice = !!getFieldValue(isTaxIncluded ? 'priceIncludeTax' : 'priceExcludeTax') || getFieldValue(isTaxIncluded ? 'priceIncludeTax' : 'priceExcludeTax') === 0;
|
|
23078
23215
|
|
|
23079
23216
|
if (!(isvalue || isPrice === isvalue)) {
|
|
23080
|
-
_context6.next =
|
|
23217
|
+
_context6.next = 7;
|
|
23081
23218
|
break;
|
|
23082
23219
|
}
|
|
23083
23220
|
|
|
23084
23221
|
return _context6.abrupt("return");
|
|
23085
23222
|
|
|
23086
|
-
case
|
|
23223
|
+
case 7:
|
|
23087
23224
|
callback('请输入数量');
|
|
23225
|
+
_context6.next = 11;
|
|
23226
|
+
break;
|
|
23088
23227
|
|
|
23089
|
-
case
|
|
23228
|
+
case 10:
|
|
23229
|
+
callback();
|
|
23230
|
+
|
|
23231
|
+
case 11:
|
|
23090
23232
|
case "end":
|
|
23091
23233
|
return _context6.stop();
|
|
23092
23234
|
}
|
|
@@ -23304,7 +23446,7 @@ var useColumns$1 = (function (form) {
|
|
|
23304
23446
|
initialValue: editGood.lineAmountIncludeTax,
|
|
23305
23447
|
getValueFromEvent: onNumberValueChange,
|
|
23306
23448
|
rules: [].concat(_toConsumableArray(getReplenishRules('lineAmountIncludeTax')), [{
|
|
23307
|
-
required:
|
|
23449
|
+
required: isValidateGood,
|
|
23308
23450
|
message: '金额不能为空'
|
|
23309
23451
|
}, {
|
|
23310
23452
|
pattern: /^[+-]?(0|([1-9]\d*))(\.\d+)?$/,
|
|
@@ -23375,7 +23517,7 @@ var useColumns$1 = (function (form) {
|
|
|
23375
23517
|
style: {
|
|
23376
23518
|
padding: '0 10px'
|
|
23377
23519
|
}
|
|
23378
|
-
}, formatSearch$1(parseFloat(value).toFixed(2), searchValue));
|
|
23520
|
+
}, value && formatSearch$1(parseFloat(value).toFixed(2), searchValue));
|
|
23379
23521
|
}
|
|
23380
23522
|
}
|
|
23381
23523
|
}, {
|
|
@@ -23392,7 +23534,7 @@ var useColumns$1 = (function (form) {
|
|
|
23392
23534
|
initialValue: editGood.lineAmountExcludeTax,
|
|
23393
23535
|
getValueFromEvent: onNumberValueChange,
|
|
23394
23536
|
rules: [].concat(_toConsumableArray(getReplenishRules('lineAmountExcludeTax')), [{
|
|
23395
|
-
required:
|
|
23537
|
+
required: isValidateGood,
|
|
23396
23538
|
message: '金额不能为空'
|
|
23397
23539
|
}, {
|
|
23398
23540
|
pattern: /^[+-]?(0|([1-9]\d*))(\.\d+)?$/,
|
|
@@ -23438,7 +23580,7 @@ var useColumns$1 = (function (form) {
|
|
|
23438
23580
|
style: {
|
|
23439
23581
|
padding: '0 10px'
|
|
23440
23582
|
}
|
|
23441
|
-
}, formatSearch$1(parseFloat(value).toFixed(2), searchValue));
|
|
23583
|
+
}, value && formatSearch$1(parseFloat(value).toFixed(2), searchValue));
|
|
23442
23584
|
}
|
|
23443
23585
|
}
|
|
23444
23586
|
}, {
|
|
@@ -23454,7 +23596,7 @@ var useColumns$1 = (function (form) {
|
|
|
23454
23596
|
return /*#__PURE__*/React.createElement(Form.Item, null, getFieldDecorator('taxRate', {
|
|
23455
23597
|
initialValue: editGood.taxRate,
|
|
23456
23598
|
rules: [].concat(_toConsumableArray(getReplenishRules('taxRate')), [{
|
|
23457
|
-
required:
|
|
23599
|
+
required: isValidateGood,
|
|
23458
23600
|
message: '请选择税率'
|
|
23459
23601
|
}, {
|
|
23460
23602
|
pattern: /^[+-]?(0|([1-9]\d*))(\.\d+)?$/,
|
|
@@ -23481,11 +23623,15 @@ var useColumns$1 = (function (form) {
|
|
|
23481
23623
|
}, e, "%");
|
|
23482
23624
|
}))));
|
|
23483
23625
|
} else {
|
|
23484
|
-
|
|
23485
|
-
|
|
23486
|
-
|
|
23487
|
-
|
|
23488
|
-
|
|
23626
|
+
if (value || value === '0' || value === 0) {
|
|
23627
|
+
return /*#__PURE__*/React.createElement("span", {
|
|
23628
|
+
style: {
|
|
23629
|
+
padding: '0 10px'
|
|
23630
|
+
}
|
|
23631
|
+
}, isDutyFree$1(record) ? '免税' : "".concat(value, "%"));
|
|
23632
|
+
} else {
|
|
23633
|
+
return '';
|
|
23634
|
+
}
|
|
23489
23635
|
}
|
|
23490
23636
|
}
|
|
23491
23637
|
}, {
|
|
@@ -23501,7 +23647,7 @@ var useColumns$1 = (function (form) {
|
|
|
23501
23647
|
return /*#__PURE__*/React.createElement(Form.Item, null, getFieldDecorator('taxAmount', {
|
|
23502
23648
|
initialValue: editGood.taxAmount,
|
|
23503
23649
|
rules: [].concat(_toConsumableArray(getReplenishRules('taxAmount')), [{
|
|
23504
|
-
required:
|
|
23650
|
+
required: isValidateGood,
|
|
23505
23651
|
message: '税额不能为空'
|
|
23506
23652
|
}, {
|
|
23507
23653
|
validator: function validator(rule, value, callback) {
|
|
@@ -23546,7 +23692,7 @@ var useColumns$1 = (function (form) {
|
|
|
23546
23692
|
style: {
|
|
23547
23693
|
padding: '0 10px'
|
|
23548
23694
|
}
|
|
23549
|
-
}, isDutyFree$1(record) ? '***' : parseFloat(value).toFixed(2));
|
|
23695
|
+
}, isDutyFree$1(record) ? '***' : value && parseFloat(value).toFixed(2));
|
|
23550
23696
|
}
|
|
23551
23697
|
}
|
|
23552
23698
|
}] // 含税不含税
|
|
@@ -25491,7 +25637,9 @@ var Main$3 = decorator(Form.create())(function (props) {
|
|
|
25491
25637
|
}
|
|
25492
25638
|
}, /*#__PURE__*/React.createElement("div", {
|
|
25493
25639
|
className: "kts-invoice-operate-goods-list-able"
|
|
25494
|
-
}, /*#__PURE__*/React.createElement(AddRowButton$1, null), delRowButton.button, addDiscountRowButton.button, endowCodeButton.button, /*#__PURE__*/React.createElement(TaxIncludedSwitch$1,
|
|
25640
|
+
}, /*#__PURE__*/React.createElement(AddRowButton$1, null), delRowButton.button, addDiscountRowButton.button, endowCodeButton.button, /*#__PURE__*/React.createElement(TaxIncludedSwitch$1, {
|
|
25641
|
+
onChange: props.onTaxSwitchChange
|
|
25642
|
+
}), /*#__PURE__*/React.createElement(Search$1, null), /*#__PURE__*/React.createElement("div", {
|
|
25495
25643
|
style: {
|
|
25496
25644
|
flex: 1
|
|
25497
25645
|
}
|
|
@@ -25522,7 +25670,7 @@ var Main$3 = decorator(Form.create())(function (props) {
|
|
|
25522
25670
|
})), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(Statistics$1, null)));
|
|
25523
25671
|
});
|
|
25524
25672
|
|
|
25525
|
-
var css_248z$r = ".kts-invoice-operate-real-estate-info-digtal {\n padding: 20px;\n border-bottom: 2px solid #9F613E;\n border-left: 2px solid #9F613E;\n border-right: 2px solid #9F613E;\n}\n.kts-invoice-operate-real-estate-info-digtal .real-estate-info-digtal-label {\n color: #9F613E;\n font-weight: bold;\n}\n.kts-invoice-operate-real-estate-info-digtal .ktsAnt3x-row.ktsAnt3x-form-item {\n margin-bottom: 0;\n}\n";
|
|
25673
|
+
var css_248z$r = ".kts-invoice-operate-real-estate-info-digtal {\n padding: 20px;\n border-bottom: 2px solid #9F613E;\n border-left: 2px solid #9F613E;\n border-right: 2px solid #9F613E;\n}\n.kts-invoice-operate-real-estate-info-digtal .real-estate-info-digtal-label {\n color: #9F613E;\n font-weight: bold;\n}\n.kts-invoice-operate-real-estate-info-digtal .ktsAnt3x-row.ktsAnt3x-form-item {\n margin-bottom: 0;\n}\n.kts-invoice-operate-real-estate-info-digtal .ktsAntX-row {\n border-bottom: 1px dashed #9F613E;\n}\n.kts-invoice-operate-real-estate-info-digtal .ktsAntX-row:last-child {\n border-bottom: none;\n}\n";
|
|
25526
25674
|
styleInject(css_248z$r);
|
|
25527
25675
|
|
|
25528
25676
|
var RangePicker = DatePicker.RangePicker;
|
|
@@ -25538,126 +25686,272 @@ var RealEstateInfo = decorator(Form.create())(function (props) {
|
|
|
25538
25686
|
}, []);
|
|
25539
25687
|
var readOnly = React.useMemo(function () {
|
|
25540
25688
|
return model === 'readOnly';
|
|
25541
|
-
}, [model]);
|
|
25689
|
+
}, [model]);
|
|
25690
|
+
var goodsList = controller.useMemo(function (s) {
|
|
25691
|
+
return s.goodsListState.goodsList;
|
|
25692
|
+
}, []); //outcome-104 任务 https://wiki.dev.kingxunlian.com/pages/viewpage.action?pageId=180355189
|
|
25693
|
+
//商品和服务税收分类合并编码为“3040502020200000000”时,视为停车费业务,针对停车费业务,蓝字发票增加以下判断:
|
|
25694
|
+
// 单位必须为“平方米”;
|
|
25695
|
+
// 项目名称必须为“车辆停放服务”;
|
|
25696
|
+
// 车牌号必填,最多支持填写3个车牌号;除该场景车牌号必须为空;
|
|
25697
|
+
// 租赁期起止格式必须为“yyyy-MM-dd HH:mm(租赁期起)”+“空格”+“yyyy-MM-dd HH:mm(租赁期止)。
|
|
25698
|
+
|
|
25699
|
+
var isParkFee = React.useCallback(function (taxClassificationCode) {
|
|
25700
|
+
if (taxClassificationCode === '3040502020200000000') {
|
|
25701
|
+
return true;
|
|
25702
|
+
} else {
|
|
25703
|
+
return false;
|
|
25704
|
+
}
|
|
25705
|
+
}, []);
|
|
25706
|
+
var indexRef = React.useRef([]);
|
|
25707
|
+
useEffect(function () {
|
|
25708
|
+
var dd = goodsList === null || goodsList === void 0 ? void 0 : goodsList.reduce(function (acc, cur) {
|
|
25709
|
+
if (cur.lineAttribute !== 1) {
|
|
25710
|
+
acc.push(cur.$index);
|
|
25711
|
+
}
|
|
25712
|
+
|
|
25713
|
+
return acc;
|
|
25714
|
+
}, []);
|
|
25715
|
+
indexRef.current = dd;
|
|
25716
|
+
}, [goodsList, indexRef]); // 注册 form
|
|
25542
25717
|
|
|
25543
25718
|
controller.useForm('realEstateInfo', form);
|
|
25719
|
+
|
|
25720
|
+
var getList = function getList() {
|
|
25721
|
+
var decrease = indexRef.current.length > goodsList.length;
|
|
25722
|
+
|
|
25723
|
+
if (decrease) {
|
|
25724
|
+
//已删行列表
|
|
25725
|
+
var diff = indexRef.current.filter(function (item) {
|
|
25726
|
+
return !goodsList.find(function (i) {
|
|
25727
|
+
return i.$index === item;
|
|
25728
|
+
});
|
|
25729
|
+
});
|
|
25730
|
+
var formData = form.getFieldValue('realEstateDataDto');
|
|
25731
|
+
|
|
25732
|
+
if (Array.isArray(formData) && diff.length > 0) {
|
|
25733
|
+
var newForm = formData === null || formData === void 0 ? void 0 : formData.filter(function (item) {
|
|
25734
|
+
return !diff.find(function (i) {
|
|
25735
|
+
return i === item.$index;
|
|
25736
|
+
});
|
|
25737
|
+
});
|
|
25738
|
+
form.setFieldsValue({
|
|
25739
|
+
realEstateDataDto: newForm
|
|
25740
|
+
});
|
|
25741
|
+
} else {
|
|
25742
|
+
form.setFieldsValue({
|
|
25743
|
+
realEstateDataDto: undefined
|
|
25744
|
+
});
|
|
25745
|
+
}
|
|
25746
|
+
}
|
|
25747
|
+
|
|
25748
|
+
return goodsList.filter(function (item) {
|
|
25749
|
+
return item.lineAttribute !== 1;
|
|
25750
|
+
}).map(function (item, index) {
|
|
25751
|
+
if (item.lineAttribute !== 1) {
|
|
25752
|
+
var isParkFeeItem = isParkFee(item.taxClassificationCode);
|
|
25753
|
+
return /*#__PURE__*/React.createElement(Row$1, {
|
|
25754
|
+
gutter: [17, 0]
|
|
25755
|
+
}, /*#__PURE__*/React.createElement(Col$1, {
|
|
25756
|
+
span: 6
|
|
25757
|
+
}, /*#__PURE__*/React.createElement(Form.Item, {
|
|
25758
|
+
style: {
|
|
25759
|
+
display: 'none'
|
|
25760
|
+
}
|
|
25761
|
+
}, getFieldDecorator("realEstateDataDto[".concat(index, "].$index"), {
|
|
25762
|
+
initialValue: item.$index
|
|
25763
|
+
})( /*#__PURE__*/React.createElement(Input$2, null))), /*#__PURE__*/React.createElement(Form.Item, {
|
|
25764
|
+
label: "\u4E0D\u52A8\u4EA7\u5730\u5740"
|
|
25765
|
+
}, getFieldDecorator("realEstateDataDto[".concat(index, "].realEstateAddress"), {
|
|
25766
|
+
rules: readOnly ? [] : [{
|
|
25767
|
+
required: true,
|
|
25768
|
+
message: '请选择不动产地址'
|
|
25769
|
+
}]
|
|
25770
|
+
})(readOnly ? /*#__PURE__*/React.createElement(MyArrString, null) : /*#__PURE__*/React.createElement(Cascader, {
|
|
25771
|
+
style: {
|
|
25772
|
+
width: '100%'
|
|
25773
|
+
},
|
|
25774
|
+
options: props.realEstateAddressOptions,
|
|
25775
|
+
fieldNames: props.realEstateAddressFieldNames,
|
|
25776
|
+
placeholder: "\u8BF7\u9009\u62E9\u7701\u5E02\u533A\u53BF"
|
|
25777
|
+
})))), /*#__PURE__*/React.createElement(Col$1, {
|
|
25778
|
+
span: 6
|
|
25779
|
+
}, /*#__PURE__*/React.createElement(Form.Item, {
|
|
25780
|
+
label: "\u8BE6\u7EC6\u5730\u5740"
|
|
25781
|
+
}, getFieldDecorator("realEstateDataDto[".concat(index, "].realEstateDetailedAddress"), {
|
|
25782
|
+
rules: readOnly ? [] : [{
|
|
25783
|
+
required: true,
|
|
25784
|
+
message: '请输入详细地址'
|
|
25785
|
+
}, {
|
|
25786
|
+
max: 120,
|
|
25787
|
+
message: '详细地址最多120个字符'
|
|
25788
|
+
}, {
|
|
25789
|
+
validator: function () {
|
|
25790
|
+
var _validator = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(_, value, callback) {
|
|
25791
|
+
var pattern;
|
|
25792
|
+
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
25793
|
+
while (1) {
|
|
25794
|
+
switch (_context.prev = _context.next) {
|
|
25795
|
+
case 0:
|
|
25796
|
+
pattern = /街|路|村|乡|镇|道|巷|号/;
|
|
25797
|
+
|
|
25798
|
+
if (pattern.test(value)) {
|
|
25799
|
+
callback();
|
|
25800
|
+
} else {
|
|
25801
|
+
callback('地址必须包含“街”、“路”、“村”、“乡”、“镇”、“道”、“巷”、“号”等任意一个关键词');
|
|
25802
|
+
}
|
|
25803
|
+
|
|
25804
|
+
case 2:
|
|
25805
|
+
case "end":
|
|
25806
|
+
return _context.stop();
|
|
25807
|
+
}
|
|
25808
|
+
}
|
|
25809
|
+
}, _callee);
|
|
25810
|
+
}));
|
|
25811
|
+
|
|
25812
|
+
function validator(_x, _x2, _x3) {
|
|
25813
|
+
return _validator.apply(this, arguments);
|
|
25814
|
+
}
|
|
25815
|
+
|
|
25816
|
+
return validator;
|
|
25817
|
+
}()
|
|
25818
|
+
}]
|
|
25819
|
+
})(readOnly ? /*#__PURE__*/React.createElement(MyDiv$3, null) : /*#__PURE__*/React.createElement(Input$2, {
|
|
25820
|
+
autoComplete: 'off',
|
|
25821
|
+
placeholder: "\u8BF7\u8F93\u5165\u8BE6\u7EC6\u5730\u5740"
|
|
25822
|
+
})))), !isParkFeeItem && /*#__PURE__*/React.createElement(Col$1, {
|
|
25823
|
+
span: 6
|
|
25824
|
+
}, /*#__PURE__*/React.createElement(Form.Item, {
|
|
25825
|
+
label: "\u79DF\u8D41\u671F\u8D77\u6B62"
|
|
25826
|
+
}, getFieldDecorator("realEstateDataDto[".concat(index, "].leaseTerm"), {
|
|
25827
|
+
rules: readOnly ? [] : [{
|
|
25828
|
+
required: true,
|
|
25829
|
+
message: '请输入租赁期'
|
|
25830
|
+
}]
|
|
25831
|
+
})(readOnly ? /*#__PURE__*/React.createElement(MyArrMoment, null) : /*#__PURE__*/React.createElement(RangePicker, {
|
|
25832
|
+
style: {
|
|
25833
|
+
width: '100%'
|
|
25834
|
+
}
|
|
25835
|
+
})))), isParkFeeItem && /*#__PURE__*/React.createElement(Col$1, {
|
|
25836
|
+
span: 6
|
|
25837
|
+
}, /*#__PURE__*/React.createElement(Form.Item, {
|
|
25838
|
+
label: "\u79DF\u8D41\u671F\u8D77\u6B62"
|
|
25839
|
+
}, getFieldDecorator("realEstateDataDto[".concat(index, "].leaseTerm"), {
|
|
25840
|
+
rules: readOnly ? [] : [{
|
|
25841
|
+
required: true,
|
|
25842
|
+
message: '请输入租赁期'
|
|
25843
|
+
}]
|
|
25844
|
+
})(readOnly ? /*#__PURE__*/React.createElement(MyArrMomentTime, null) : /*#__PURE__*/React.createElement(RangePicker, {
|
|
25845
|
+
style: {
|
|
25846
|
+
width: '100%'
|
|
25847
|
+
},
|
|
25848
|
+
showTime: {
|
|
25849
|
+
format: 'HH:mm'
|
|
25850
|
+
},
|
|
25851
|
+
format: "YYYY-MM-DD HH:mm"
|
|
25852
|
+
})))), /*#__PURE__*/React.createElement(Col$1, {
|
|
25853
|
+
span: 6
|
|
25854
|
+
}, /*#__PURE__*/React.createElement(Form.Item, {
|
|
25855
|
+
label: "\u8DE8\u5730\uFF08\u5E02\uFF09\u6807\u5FD7"
|
|
25856
|
+
}, getFieldDecorator("realEstateDataDto[".concat(index, "].crossCitiesSign"), {
|
|
25857
|
+
rules: readOnly ? [] : [{
|
|
25858
|
+
required: true,
|
|
25859
|
+
message: '请选择跨地(市)标志'
|
|
25860
|
+
}]
|
|
25861
|
+
})(readOnly ? /*#__PURE__*/React.createElement(MyNY, null) : /*#__PURE__*/React.createElement(Select$2, {
|
|
25862
|
+
placeholder: "\u8BF7\u9009\u62E9",
|
|
25863
|
+
style: {
|
|
25864
|
+
width: '100%'
|
|
25865
|
+
}
|
|
25866
|
+
}, /*#__PURE__*/React.createElement(Select$2.Option, {
|
|
25867
|
+
value: 'Y'
|
|
25868
|
+
}, "\u662F"), /*#__PURE__*/React.createElement(Select$2.Option, {
|
|
25869
|
+
value: 'N'
|
|
25870
|
+
}, "\u5426"))))), /*#__PURE__*/React.createElement(Col$1, {
|
|
25871
|
+
span: 6
|
|
25872
|
+
}, /*#__PURE__*/React.createElement(Form.Item, {
|
|
25873
|
+
label: "\u4EA7\u6743\u8BC1\u4E66/\u4E0D\u52A8\u4EA7\u6743\u8BC1\u53F7"
|
|
25874
|
+
}, getFieldDecorator("realEstateDataDto[".concat(index, "].realEstateNumber"), {
|
|
25875
|
+
rules: readOnly ? [] : [{
|
|
25876
|
+
required: true,
|
|
25877
|
+
message: '请输入证书编号,若没有证书填写“无”'
|
|
25878
|
+
}, {
|
|
25879
|
+
max: 40,
|
|
25880
|
+
message: '证书编号最多40个字符'
|
|
25881
|
+
}]
|
|
25882
|
+
})(readOnly ? /*#__PURE__*/React.createElement(MyDiv$3, null) : /*#__PURE__*/React.createElement(Input$2, {
|
|
25883
|
+
autoComplete: 'off',
|
|
25884
|
+
placeholder: "\u8BF7\u8F93\u5165\u8BC1\u4E66\u7F16\u53F7\uFF0C\u82E5\u6CA1\u6709\u8BC1\u4E66\u586B\u5199\u201C\u65E0\u201D"
|
|
25885
|
+
})))), !isParkFeeItem && /*#__PURE__*/React.createElement(Col$1, {
|
|
25886
|
+
span: 6
|
|
25887
|
+
}, /*#__PURE__*/React.createElement(Form.Item, {
|
|
25888
|
+
label: "\u9762\u79EF\u5355\u4F4D"
|
|
25889
|
+
}, getFieldDecorator("realEstateDataDto[".concat(index, "].realEstateUnit"), {
|
|
25890
|
+
rules: readOnly ? [] : [{
|
|
25891
|
+
required: true,
|
|
25892
|
+
message: '请选择面积单位'
|
|
25893
|
+
}]
|
|
25894
|
+
})(readOnly ? /*#__PURE__*/React.createElement(MyDiv$3, null) : /*#__PURE__*/React.createElement(Select$2, {
|
|
25895
|
+
placeholder: "\u8BF7\u9009\u62E9",
|
|
25896
|
+
style: {
|
|
25897
|
+
width: '100%'
|
|
25898
|
+
}
|
|
25899
|
+
}, /*#__PURE__*/React.createElement(Select$2.Option, {
|
|
25900
|
+
value: "\u5E73\u65B9\u5343\u7C73"
|
|
25901
|
+
}, "\u5E73\u65B9\u5343\u7C73"), /*#__PURE__*/React.createElement(Select$2.Option, {
|
|
25902
|
+
value: "\u5E73\u65B9\u7C73"
|
|
25903
|
+
}, "\u5E73\u65B9\u7C73"), /*#__PURE__*/React.createElement(Select$2.Option, {
|
|
25904
|
+
value: "\u516C\u9877"
|
|
25905
|
+
}, "\u516C\u9877"), /*#__PURE__*/React.createElement(Select$2.Option, {
|
|
25906
|
+
value: "\u4EA9"
|
|
25907
|
+
}, "\u4EA9"), /*#__PURE__*/React.createElement(Select$2.Option, {
|
|
25908
|
+
value: "h\u33A1"
|
|
25909
|
+
}, "h\u33A1"), /*#__PURE__*/React.createElement(Select$2.Option, {
|
|
25910
|
+
value: "k\u33A1"
|
|
25911
|
+
}, "k\u33A1"), /*#__PURE__*/React.createElement(Select$2.Option, {
|
|
25912
|
+
value: "\u33A1"
|
|
25913
|
+
}, "\u33A1"))))), isParkFeeItem && /*#__PURE__*/React.createElement(Col$1, {
|
|
25914
|
+
span: 6
|
|
25915
|
+
}, /*#__PURE__*/React.createElement(Form.Item, {
|
|
25916
|
+
label: "\u9762\u79EF\u5355\u4F4D"
|
|
25917
|
+
}, getFieldDecorator("realEstateDataDto[".concat(index, "].realEstateUnit"), {
|
|
25918
|
+
rules: readOnly ? [] : [{
|
|
25919
|
+
required: true,
|
|
25920
|
+
message: '请选择面积单位'
|
|
25921
|
+
}]
|
|
25922
|
+
})(readOnly ? /*#__PURE__*/React.createElement(MyDiv$3, null) : /*#__PURE__*/React.createElement(Select$2, {
|
|
25923
|
+
placeholder: "\u8BF7\u9009\u62E9",
|
|
25924
|
+
style: {
|
|
25925
|
+
width: '100%'
|
|
25926
|
+
}
|
|
25927
|
+
}, /*#__PURE__*/React.createElement(Select$2.Option, {
|
|
25928
|
+
value: "\u5E73\u65B9\u7C73"
|
|
25929
|
+
}, "\u5E73\u65B9\u7C73"))))), isParkFeeItem && /*#__PURE__*/React.createElement(LicensePlateNumber, {
|
|
25930
|
+
form: form,
|
|
25931
|
+
index: index,
|
|
25932
|
+
cd: item.cd,
|
|
25933
|
+
readOnly: readOnly
|
|
25934
|
+
}) // <Col span={6} >
|
|
25935
|
+
// <Form.Item label='车牌号' >
|
|
25936
|
+
// {getFieldDecorator(`realEstateDataDto[${index}].licensePlateNumber`, {
|
|
25937
|
+
// rules: readOnly ? [] : [{ required: true, message: '请选择面积单位' }]
|
|
25938
|
+
// })(
|
|
25939
|
+
// readOnly
|
|
25940
|
+
// ? <MyDiv />
|
|
25941
|
+
// : <LicensePlateNumber form={form}/>
|
|
25942
|
+
// )}
|
|
25943
|
+
// </Form.Item>
|
|
25944
|
+
// </Col>
|
|
25945
|
+
);
|
|
25946
|
+
}
|
|
25947
|
+
});
|
|
25948
|
+
};
|
|
25949
|
+
|
|
25544
25950
|
return /*#__PURE__*/React.createElement("div", {
|
|
25545
25951
|
className: "kts-invoice-operate-real-estate-info-digtal"
|
|
25546
25952
|
}, /*#__PURE__*/React.createElement("div", {
|
|
25547
25953
|
className: 'real-estate-info-digtal-label'
|
|
25548
|
-
}, "\u7279\
|
|
25549
|
-
gutter: [17, 0]
|
|
25550
|
-
}, /*#__PURE__*/React.createElement(Col$1, {
|
|
25551
|
-
span: 6
|
|
25552
|
-
}, /*#__PURE__*/React.createElement(Form.Item, {
|
|
25553
|
-
label: "\u4E0D\u52A8\u4EA7\u5730\u5740"
|
|
25554
|
-
}, getFieldDecorator('realEstateAddress', {
|
|
25555
|
-
rules: readOnly ? [] : [{
|
|
25556
|
-
required: true,
|
|
25557
|
-
message: '请选择不动产地址'
|
|
25558
|
-
}]
|
|
25559
|
-
})(readOnly ? /*#__PURE__*/React.createElement(MyArrString, null) : /*#__PURE__*/React.createElement(Cascader, {
|
|
25560
|
-
style: {
|
|
25561
|
-
width: '100%'
|
|
25562
|
-
},
|
|
25563
|
-
options: props.realEstateAddressOptions,
|
|
25564
|
-
fieldNames: props.realEstateAddressFieldNames,
|
|
25565
|
-
placeholder: "\u8BF7\u9009\u62E9\u7701\u5E02\u533A\u53BF"
|
|
25566
|
-
})))), /*#__PURE__*/React.createElement(Col$1, {
|
|
25567
|
-
span: 6
|
|
25568
|
-
}, /*#__PURE__*/React.createElement(Form.Item, {
|
|
25569
|
-
label: "\u8BE6\u7EC6\u5730\u5740"
|
|
25570
|
-
}, getFieldDecorator('realEstateDetailedAddress', {
|
|
25571
|
-
rules: readOnly ? [] : [{
|
|
25572
|
-
required: true,
|
|
25573
|
-
message: '请输入详细地址'
|
|
25574
|
-
}, {
|
|
25575
|
-
max: 120,
|
|
25576
|
-
message: '详细地址最多120个字符'
|
|
25577
|
-
}, {
|
|
25578
|
-
validator: function validator(_, value) {
|
|
25579
|
-
var pattern = /街|路|村|乡|镇|道|巷|号/;
|
|
25580
|
-
return pattern.test(value) ? Promise.resolve() : Promise.reject('地址必须包含“街”、“路”、“村”、“乡”、“镇”、“道”、“巷”、“号”等任意一个关键词');
|
|
25581
|
-
}
|
|
25582
|
-
}]
|
|
25583
|
-
})(readOnly ? /*#__PURE__*/React.createElement(MyDiv$3, null) : /*#__PURE__*/React.createElement(Input$2, {
|
|
25584
|
-
autoComplete: 'off',
|
|
25585
|
-
placeholder: "\u8BF7\u8F93\u5165\u8BE6\u7EC6\u5730\u5740"
|
|
25586
|
-
})))), /*#__PURE__*/React.createElement(Col$1, {
|
|
25587
|
-
span: 6
|
|
25588
|
-
}, /*#__PURE__*/React.createElement(Form.Item, {
|
|
25589
|
-
label: "\u79DF\u8D41\u671F\u8D77\u6B62"
|
|
25590
|
-
}, getFieldDecorator('leaseTerm', {
|
|
25591
|
-
rules: readOnly ? [] : [{
|
|
25592
|
-
required: true,
|
|
25593
|
-
message: '请输入租赁期'
|
|
25594
|
-
}]
|
|
25595
|
-
})(readOnly ? /*#__PURE__*/React.createElement(MyArrMoment, null) : /*#__PURE__*/React.createElement(RangePicker, {
|
|
25596
|
-
style: {
|
|
25597
|
-
width: '100%'
|
|
25598
|
-
}
|
|
25599
|
-
})))), /*#__PURE__*/React.createElement(Col$1, {
|
|
25600
|
-
span: 6
|
|
25601
|
-
}, /*#__PURE__*/React.createElement(Form.Item, {
|
|
25602
|
-
label: "\u8DE8\u5730\uFF08\u5E02\uFF09\u6807\u5FD7"
|
|
25603
|
-
}, getFieldDecorator('crossCitiesSign', {
|
|
25604
|
-
rules: readOnly ? [] : [{
|
|
25605
|
-
required: true,
|
|
25606
|
-
message: '请选择跨地(市)标志'
|
|
25607
|
-
}]
|
|
25608
|
-
})(readOnly ? /*#__PURE__*/React.createElement(MyNY, null) : /*#__PURE__*/React.createElement(Select$2, {
|
|
25609
|
-
placeholder: "\u8BF7\u9009\u62E9",
|
|
25610
|
-
style: {
|
|
25611
|
-
width: '100%'
|
|
25612
|
-
}
|
|
25613
|
-
}, /*#__PURE__*/React.createElement(Select$2.Option, {
|
|
25614
|
-
value: 'Y'
|
|
25615
|
-
}, "\u662F"), /*#__PURE__*/React.createElement(Select$2.Option, {
|
|
25616
|
-
value: 'N'
|
|
25617
|
-
}, "\u5426"))))), /*#__PURE__*/React.createElement(Col$1, {
|
|
25618
|
-
span: 6
|
|
25619
|
-
}, /*#__PURE__*/React.createElement(Form.Item, {
|
|
25620
|
-
label: "\u4EA7\u6743\u8BC1\u4E66/\u4E0D\u52A8\u4EA7\u6743\u8BC1\u53F7"
|
|
25621
|
-
}, getFieldDecorator('realEstateNumber', {
|
|
25622
|
-
rules: readOnly ? [] : [{
|
|
25623
|
-
required: true,
|
|
25624
|
-
message: '请输入证书编号,若没有证书填写“无”'
|
|
25625
|
-
}, {
|
|
25626
|
-
max: 40,
|
|
25627
|
-
message: '证书编号最多40个字符'
|
|
25628
|
-
}]
|
|
25629
|
-
})(readOnly ? /*#__PURE__*/React.createElement(MyDiv$3, null) : /*#__PURE__*/React.createElement(Input$2, {
|
|
25630
|
-
autoComplete: 'off',
|
|
25631
|
-
placeholder: "\u8BF7\u8F93\u5165\u8BC1\u4E66\u7F16\u53F7\uFF0C\u82E5\u6CA1\u6709\u8BC1\u4E66\u586B\u5199\u201C\u65E0\u201D"
|
|
25632
|
-
})))), /*#__PURE__*/React.createElement(Col$1, {
|
|
25633
|
-
span: 6
|
|
25634
|
-
}, /*#__PURE__*/React.createElement(Form.Item, {
|
|
25635
|
-
label: "\u9762\u79EF\u5355\u4F4D"
|
|
25636
|
-
}, getFieldDecorator('realEstateUnit', {
|
|
25637
|
-
rules: readOnly ? [] : [{
|
|
25638
|
-
required: true,
|
|
25639
|
-
message: '请选择面积单位'
|
|
25640
|
-
}]
|
|
25641
|
-
})(readOnly ? /*#__PURE__*/React.createElement(MyDiv$3, null) : /*#__PURE__*/React.createElement(Select$2, {
|
|
25642
|
-
placeholder: "\u8BF7\u9009\u62E9",
|
|
25643
|
-
style: {
|
|
25644
|
-
width: '100%'
|
|
25645
|
-
}
|
|
25646
|
-
}, /*#__PURE__*/React.createElement(Select$2.Option, {
|
|
25647
|
-
value: "\u5E73\u65B9\u5343\u7C73"
|
|
25648
|
-
}, "\u5E73\u65B9\u5343\u7C73"), /*#__PURE__*/React.createElement(Select$2.Option, {
|
|
25649
|
-
value: "\u5E73\u65B9\u7C73"
|
|
25650
|
-
}, "\u5E73\u65B9\u7C73"), /*#__PURE__*/React.createElement(Select$2.Option, {
|
|
25651
|
-
value: "\u516C\u9877"
|
|
25652
|
-
}, "\u516C\u9877"), /*#__PURE__*/React.createElement(Select$2.Option, {
|
|
25653
|
-
value: "\u4EA9"
|
|
25654
|
-
}, "\u4EA9"), /*#__PURE__*/React.createElement(Select$2.Option, {
|
|
25655
|
-
value: "h\u33A1"
|
|
25656
|
-
}, "h\u33A1"), /*#__PURE__*/React.createElement(Select$2.Option, {
|
|
25657
|
-
value: "k\u33A1"
|
|
25658
|
-
}, "k\u33A1"), /*#__PURE__*/React.createElement(Select$2.Option, {
|
|
25659
|
-
value: "\u33A1"
|
|
25660
|
-
}, "\u33A1")))))));
|
|
25954
|
+
}, "\u7279\u5B9A\u4FE1\u606F-\u4E0D\u52A8\u4EA7\u7ECF\u8425\u79DF\u8D41\u670D\u52A1"), getList());
|
|
25661
25955
|
});
|
|
25662
25956
|
|
|
25663
25957
|
var MyDiv$3 = /*#__PURE__*/function (_React$Component) {
|
|
@@ -25733,22 +26027,52 @@ var MyArrMoment = /*#__PURE__*/function (_React$Component3) {
|
|
|
25733
26027
|
color: '#9F603D',
|
|
25734
26028
|
fontWeight: 600
|
|
25735
26029
|
}
|
|
25736
|
-
}, " - "), /*#__PURE__*/React.createElement("span", null, hooks.isMoment(value[1]) && value[
|
|
26030
|
+
}, " - "), /*#__PURE__*/React.createElement("span", null, hooks.isMoment(value[1]) && value[1].format('YYYY-MM-DD')));
|
|
25737
26031
|
}
|
|
25738
26032
|
}]);
|
|
25739
26033
|
|
|
25740
26034
|
return MyArrMoment;
|
|
25741
26035
|
}(React.Component);
|
|
25742
26036
|
|
|
25743
|
-
var
|
|
25744
|
-
_inherits(
|
|
26037
|
+
var MyArrMomentTime = /*#__PURE__*/function (_React$Component4) {
|
|
26038
|
+
_inherits(MyArrMomentTime, _React$Component4);
|
|
25745
26039
|
|
|
25746
|
-
var _super4 = _createSuper(
|
|
26040
|
+
var _super4 = _createSuper(MyArrMomentTime);
|
|
26041
|
+
|
|
26042
|
+
function MyArrMomentTime() {
|
|
26043
|
+
_classCallCheck(this, MyArrMomentTime);
|
|
26044
|
+
|
|
26045
|
+
return _super4.apply(this, arguments);
|
|
26046
|
+
}
|
|
26047
|
+
|
|
26048
|
+
_createClass(MyArrMomentTime, [{
|
|
26049
|
+
key: "render",
|
|
26050
|
+
value: function render() {
|
|
26051
|
+
var _this$props$value3 = this.props.value,
|
|
26052
|
+
value = _this$props$value3 === void 0 ? [] : _this$props$value3;
|
|
26053
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
26054
|
+
style: this.props.style
|
|
26055
|
+
}, /*#__PURE__*/React.createElement("span", null, hooks.isMoment(value[0]) && value[0].format('YYYY-MM-DD HH:mm')), /*#__PURE__*/React.createElement("span", {
|
|
26056
|
+
style: {
|
|
26057
|
+
color: '#9F603D',
|
|
26058
|
+
fontWeight: 600
|
|
26059
|
+
}
|
|
26060
|
+
}, " - "), /*#__PURE__*/React.createElement("span", null, hooks.isMoment(value[1]) && value[1].format('YYYY-MM-DD HH:mm')));
|
|
26061
|
+
}
|
|
26062
|
+
}]);
|
|
26063
|
+
|
|
26064
|
+
return MyArrMomentTime;
|
|
26065
|
+
}(React.Component);
|
|
26066
|
+
|
|
26067
|
+
var MyNY = /*#__PURE__*/function (_React$Component5) {
|
|
26068
|
+
_inherits(MyNY, _React$Component5);
|
|
26069
|
+
|
|
26070
|
+
var _super5 = _createSuper(MyNY);
|
|
25747
26071
|
|
|
25748
26072
|
function MyNY() {
|
|
25749
26073
|
_classCallCheck(this, MyNY);
|
|
25750
26074
|
|
|
25751
|
-
return
|
|
26075
|
+
return _super5.apply(this, arguments);
|
|
25752
26076
|
}
|
|
25753
26077
|
|
|
25754
26078
|
_createClass(MyNY, [{
|
|
@@ -25763,6 +26087,137 @@ var MyNY = /*#__PURE__*/function (_React$Component4) {
|
|
|
25763
26087
|
return MyNY;
|
|
25764
26088
|
}(React.Component);
|
|
25765
26089
|
|
|
26090
|
+
var LicensePlateNumber = function LicensePlateNumber(props) {
|
|
26091
|
+
var _formData$props$index2;
|
|
26092
|
+
|
|
26093
|
+
var form = props.form,
|
|
26094
|
+
readOnly = props.readOnly;
|
|
26095
|
+
var getFieldDecorator = form.getFieldDecorator;
|
|
26096
|
+
var licenceLimit = 3; // 最多支持填写3个车牌号
|
|
26097
|
+
|
|
26098
|
+
var formData = form.getFieldValue('realEstateDataDto');
|
|
26099
|
+
|
|
26100
|
+
var _React$useState = React.useState(new Array(props.cd || 1).fill('')),
|
|
26101
|
+
_React$useState2 = _slicedToArray(_React$useState, 2),
|
|
26102
|
+
value = _React$useState2[0],
|
|
26103
|
+
setVal = _React$useState2[1];
|
|
26104
|
+
|
|
26105
|
+
var cd = React.useMemo(function () {
|
|
26106
|
+
var _formData$props$index;
|
|
26107
|
+
|
|
26108
|
+
return (_formData$props$index = formData[props.index]) === null || _formData$props$index === void 0 ? void 0 : _formData$props$index.cd;
|
|
26109
|
+
}, [(_formData$props$index2 = formData[props.index]) === null || _formData$props$index2 === void 0 ? void 0 : _formData$props$index2.cd]); // useEffect(() => {
|
|
26110
|
+
// if (cd) {
|
|
26111
|
+
// const dd = value.concat(new Array(cd.length-1).fill(''))
|
|
26112
|
+
// setVal(dd);
|
|
26113
|
+
// }
|
|
26114
|
+
// }, [cd])
|
|
26115
|
+
|
|
26116
|
+
var onAdd = function onAdd() {
|
|
26117
|
+
if (value.length < licenceLimit) {
|
|
26118
|
+
setVal([].concat(_toConsumableArray(value), ['']));
|
|
26119
|
+
} else {
|
|
26120
|
+
message.warn('最多支持填写3个车牌号');
|
|
26121
|
+
}
|
|
26122
|
+
}; // 删除车牌号
|
|
26123
|
+
|
|
26124
|
+
|
|
26125
|
+
var onDelete = function onDelete() {
|
|
26126
|
+
if (value.length > 0) {
|
|
26127
|
+
var dd = value.slice(0, -1);
|
|
26128
|
+
setVal(dd);
|
|
26129
|
+
}
|
|
26130
|
+
};
|
|
26131
|
+
|
|
26132
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, value.length > 0 && value.map(function (item, key) {
|
|
26133
|
+
return /*#__PURE__*/React.createElement(Col$1, {
|
|
26134
|
+
span: 6
|
|
26135
|
+
}, /*#__PURE__*/React.createElement(Form.Item, {
|
|
26136
|
+
label: "\u8F66\u724C\u53F7",
|
|
26137
|
+
key: key
|
|
26138
|
+
}, getFieldDecorator("realEstateDataDto[".concat(props.index, "].cphList[").concat(key, "]"), {
|
|
26139
|
+
rules: readOnly ? [] : [{
|
|
26140
|
+
required: true,
|
|
26141
|
+
message: '请输入车牌号,最多20位'
|
|
26142
|
+
}]
|
|
26143
|
+
})(readOnly ? /*#__PURE__*/React.createElement(MyDiv$3, null) : /*#__PURE__*/React.createElement(Input$2, {
|
|
26144
|
+
style: {
|
|
26145
|
+
width: '100%'
|
|
26146
|
+
},
|
|
26147
|
+
maxLength: 20,
|
|
26148
|
+
autoComplete: 'off',
|
|
26149
|
+
placeholder: "\u8BF7\u8F93\u5165\u8F66\u724C\u53F7"
|
|
26150
|
+
}))));
|
|
26151
|
+
}), !readOnly && /*#__PURE__*/React.createElement(Col$1, {
|
|
26152
|
+
span: 6
|
|
26153
|
+
}, /*#__PURE__*/React.createElement(Form.Item, null, /*#__PURE__*/React.createElement("div", {
|
|
26154
|
+
style: {
|
|
26155
|
+
color: 'white'
|
|
26156
|
+
}
|
|
26157
|
+
}, "1"), /*#__PURE__*/React.createElement("a", {
|
|
26158
|
+
style: {
|
|
26159
|
+
marginRight: 10
|
|
26160
|
+
},
|
|
26161
|
+
onClick: onAdd
|
|
26162
|
+
}, "\u6DFB\u52A0\u8F66\u724C\u53F7"), value.length > 1 && /*#__PURE__*/React.createElement("a", {
|
|
26163
|
+
onClick: onDelete
|
|
26164
|
+
}, "\u5220\u9664"))));
|
|
26165
|
+
}; // const LicensePlateNumber: React.FC<PriceInputProps> = (props) => {
|
|
26166
|
+
// const { form } = props;
|
|
26167
|
+
// const { getFieldDecorator } = form;
|
|
26168
|
+
// const licenceLimit = 3; // 最多支持填写3个车牌号
|
|
26169
|
+
// // const { value = [] } = this.props;
|
|
26170
|
+
// const [value, setVal] = React.useState(props.value || ['']);
|
|
26171
|
+
// // const newArr = value.filter(e => !!e);
|
|
26172
|
+
// const newArrLength = value.length;
|
|
26173
|
+
// console.log(value, newArrLength)
|
|
26174
|
+
// // 新增车牌号
|
|
26175
|
+
// const onAdd = () => {
|
|
26176
|
+
// if (newArrLength < licenceLimit) {
|
|
26177
|
+
// setVal([...value, '']);
|
|
26178
|
+
// props.onChange?.([...value, ''])
|
|
26179
|
+
// }
|
|
26180
|
+
// }
|
|
26181
|
+
// // 删除车牌号
|
|
26182
|
+
// const onDelete = () => {
|
|
26183
|
+
// if (newArrLength > 0) {
|
|
26184
|
+
// const dd = value.slice(0, -1)
|
|
26185
|
+
// setVal(dd);
|
|
26186
|
+
// props.onChange?.(dd)
|
|
26187
|
+
// }
|
|
26188
|
+
// }
|
|
26189
|
+
// const onInputChange = (e: React.ChangeEvent<HTMLInputElement>, index: number) => {
|
|
26190
|
+
// console.log(e.target.value);
|
|
26191
|
+
// const dd = value.map((item, i) => {
|
|
26192
|
+
// if (i === index) {
|
|
26193
|
+
// return e.target.value
|
|
26194
|
+
// }
|
|
26195
|
+
// return item
|
|
26196
|
+
// })
|
|
26197
|
+
// setVal(dd);
|
|
26198
|
+
// props.onChange?.(dd)
|
|
26199
|
+
// }
|
|
26200
|
+
// return (
|
|
26201
|
+
// <>
|
|
26202
|
+
// {newArrLength > 0 && value.map((item, index) => {
|
|
26203
|
+
// return
|
|
26204
|
+
// <Form.Item label='车牌号' >
|
|
26205
|
+
// {getFieldDecorator(`realEstateDataDto[${index}].licensePlateNumber`, {
|
|
26206
|
+
// rules: [{ required: true, }]
|
|
26207
|
+
// })(
|
|
26208
|
+
// <Input onChange={(e) => { onInputChange(e, index) }} key={index} style={{ width: '100%' }} autoComplete='off' placeholder="请输入车牌号" />
|
|
26209
|
+
// )}
|
|
26210
|
+
// </Form.Item>
|
|
26211
|
+
// // <Col span={6} >
|
|
26212
|
+
// // <Input onChange={(e) => { onInputChange(e, index) }} key={index} style={{ width: '100%' }} autoComplete='off' placeholder="请输入车牌号" />
|
|
26213
|
+
// // </Col>
|
|
26214
|
+
// })}
|
|
26215
|
+
// <Button type="link" onClick={onAdd}>添加车牌号</Button>
|
|
26216
|
+
// {newArrLength > 1 && <Button type="link" onClick={onDelete}>删除</Button>}
|
|
26217
|
+
// </>
|
|
26218
|
+
// )
|
|
26219
|
+
// }
|
|
26220
|
+
|
|
25766
26221
|
var css_248z$s = ".kts-invoice-operate-real-estate-info-digtal {\n padding: 20px;\n border-bottom: 2px solid #9F613E;\n border-left: 2px solid #9F613E;\n border-right: 2px solid #9F613E;\n}\n.kts-invoice-operate-real-estate-info-digtal .real-estate-info-digtal-label {\n color: #9F613E;\n font-weight: bold;\n}\n.kts-invoice-operate-real-estate-info-digtal .ktsAnt3x-row.ktsAnt3x-form-item {\n margin-bottom: 0;\n}\n.kts-invoice-operate-real-estate-info-digtal .break-word {\n word-break: break-word;\n}\n";
|
|
25767
26222
|
styleInject(css_248z$s);
|
|
25768
26223
|
|
|
@@ -25785,7 +26240,7 @@ var Architecture = decorator(Form.create())(function (props) {
|
|
|
25785
26240
|
className: "kts-invoice-operate-real-estate-info-digtal"
|
|
25786
26241
|
}, /*#__PURE__*/React.createElement("div", {
|
|
25787
26242
|
className: 'real-estate-info-digtal-label'
|
|
25788
|
-
}, "\u7279\
|
|
26243
|
+
}, "\u7279\u5B9A\u4FE1\u606F-\u5EFA\u7B51\u670D\u52A1"), /*#__PURE__*/React.createElement(Row$1, {
|
|
25789
26244
|
gutter: [17, 0]
|
|
25790
26245
|
}, /*#__PURE__*/React.createElement(Col$1, {
|
|
25791
26246
|
span: 6
|
|
@@ -27391,7 +27846,7 @@ var Main$4 = decorator(Form.create())(function (props) {
|
|
|
27391
27846
|
className: "kts-invoice-operate-freight"
|
|
27392
27847
|
}, /*#__PURE__*/React.createElement("div", {
|
|
27393
27848
|
className: 'real-estate-info-digtal-label'
|
|
27394
|
-
}, "\u7279\
|
|
27849
|
+
}, "\u7279\u5B9A\u4FE1\u606F-\u8D27\u7269\u8FD0\u8F93"), /*#__PURE__*/React.createElement("div", {
|
|
27395
27850
|
className: "kts-invoice-operate-goods-list-digtal",
|
|
27396
27851
|
onClick: function onClick(e) {
|
|
27397
27852
|
e.stopPropagation();
|
|
@@ -28854,9 +29309,10 @@ var ImportGoodsDrawer = (function () {
|
|
|
28854
29309
|
while (1) {
|
|
28855
29310
|
switch (_context.prev = _context.next) {
|
|
28856
29311
|
case 0:
|
|
29312
|
+
s.goodsListState.importGoods.filter = {};
|
|
28857
29313
|
s.goodsListState.importGoods.isVisibleDrawer = false;
|
|
28858
29314
|
|
|
28859
|
-
case
|
|
29315
|
+
case 2:
|
|
28860
29316
|
case "end":
|
|
28861
29317
|
return _context.stop();
|
|
28862
29318
|
}
|