tntd 1.4.5 → 1.4.6

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.
@@ -45,31 +45,21 @@ function (_React$PureComponent) {
45
45
 
46
46
  _this = _possibleConstructorReturn(this, _getPrototypeOf(QueryForm).call(this, props));
47
47
 
48
- _this.onSearch = function _callee() {
49
- var _this$props, onSearch, actions, values, params;
50
-
51
- return regeneratorRuntime.async(function _callee$(_context) {
52
- while (1) {
53
- switch (_context.prev = _context.next) {
54
- case 0:
55
- _this$props = _this.props, onSearch = _this$props.onSearch, actions = _this$props.actions;
56
- values = actions.getFormData();
57
- params = _objectSpread({}, values, {
58
- current: 1
59
- });
60
- _context.next = 5;
61
- return regeneratorRuntime.awrap(actions.setData('formData', values));
62
-
63
- case 5:
64
- // memory 与 url解析setForm时 监听事件异步
65
- onSearch && onSearch(params);
66
- actions.emit('search', params);
67
-
68
- case 7:
69
- case "end":
70
- return _context.stop();
71
- }
72
- }
48
+ _this.onSearch = function () {
49
+ var _this$props = _this.props,
50
+ onSearch = _this$props.onSearch,
51
+ actions = _this$props.actions;
52
+ var values = actions.getFormData();
53
+
54
+ var params = _objectSpread({}, values, {
55
+ current: 1
56
+ }); // memory 与 url解析setForm时 监听事件异步
57
+
58
+
59
+ actions.setData('formData', values);
60
+ Promise.resolve().then(function () {
61
+ onSearch && onSearch(params);
62
+ actions.emit('search', params);
73
63
  });
74
64
  };
75
65
 
@@ -57,31 +57,21 @@ function (_React$PureComponent) {
57
57
 
58
58
  _this = _possibleConstructorReturn(this, _getPrototypeOf(QueryForm).call(this, props));
59
59
 
60
- _this.onSearch = function _callee() {
61
- var _this$props, onSearch, actions, values, params;
62
-
63
- return regeneratorRuntime.async(function _callee$(_context) {
64
- while (1) {
65
- switch (_context.prev = _context.next) {
66
- case 0:
67
- _this$props = _this.props, onSearch = _this$props.onSearch, actions = _this$props.actions;
68
- values = actions.getFormData();
69
- params = _objectSpread({}, values, {
70
- current: 1
71
- });
72
- _context.next = 5;
73
- return regeneratorRuntime.awrap(actions.setData('formData', values));
74
-
75
- case 5:
76
- // memory 与 url解析setForm时 监听事件异步
77
- onSearch && onSearch(params);
78
- actions.emit('search', params);
79
-
80
- case 7:
81
- case "end":
82
- return _context.stop();
83
- }
84
- }
60
+ _this.onSearch = function () {
61
+ var _this$props = _this.props,
62
+ onSearch = _this$props.onSearch,
63
+ actions = _this$props.actions;
64
+ var values = actions.getFormData();
65
+
66
+ var params = _objectSpread({}, values, {
67
+ current: 1
68
+ }); // memory 与 url解析setForm时 监听事件异步
69
+
70
+
71
+ actions.setData('formData', values);
72
+ Promise.resolve().then(function () {
73
+ onSearch && onSearch(params);
74
+ actions.emit('search', params);
85
75
  });
86
76
  };
87
77
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tntd",
3
- "version": "1.4.5",
3
+ "version": "1.4.6",
4
4
  "description": "ued tnt design",
5
5
  "main": "lib/index.js",
6
6
  "module": "es/index.js",