@pisell/private-materials 3.3.7 → 3.3.8

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.
@@ -125,9 +125,16 @@ var TicketBooking = function TicketBooking() {
125
125
  * 设置弹窗内的状态
126
126
  */
127
127
  var _setModalState = function _setModalState(props) {
128
+ var _newVal$service2;
128
129
  console.log('同步state到外层', props);
130
+ var newVal = _objectSpread({}, props);
131
+ if (newVal.service) {
132
+ var _newVal$service;
133
+ newVal.service.value = (newVal === null || newVal === void 0 || (_newVal$service = newVal.service) === null || _newVal$service === void 0 ? void 0 : _newVal$service.value) || [];
134
+ }
135
+ console.log(newVal === null || newVal === void 0 || (_newVal$service2 = newVal.service) === null || _newVal$service2 === void 0 ? void 0 : _newVal$service2.value, 'newVal.service.value');
129
136
  setState({
130
- modalState: _objectSpread(_objectSpread({}, state.modalState), props)
137
+ modalState: _objectSpread(_objectSpread({}, state.modalState), newVal)
131
138
  });
132
139
  };
133
140
  var _setDataChange = function _setDataChange(date, dateString, isTimeChange) {
@@ -133,11 +133,17 @@ var TicketBooking = () => {
133
133
  });
134
134
  };
135
135
  const _setModalState = (props) => {
136
+ var _a2, _b;
136
137
  console.log("同步state到外层", props);
138
+ let newVal = { ...props };
139
+ if (newVal.service) {
140
+ newVal.service.value = ((_a2 = newVal == null ? void 0 : newVal.service) == null ? void 0 : _a2.value) || [];
141
+ }
142
+ console.log((_b = newVal == null ? void 0 : newVal.service) == null ? void 0 : _b.value, "newVal.service.value");
137
143
  setState({
138
144
  modalState: {
139
145
  ...state.modalState,
140
- ...props
146
+ ...newVal
141
147
  }
142
148
  });
143
149
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pisell/private-materials",
3
- "version": "3.3.7",
3
+ "version": "3.3.8",
4
4
  "main": "./lib/index.js",
5
5
  "module": "./es/index.js",
6
6
  "types": "./lib/index.d.ts",
@@ -60,9 +60,9 @@
60
60
  "rc-virtual-list": "^3.11.3",
61
61
  "decimal.js": "^10.4.3",
62
62
  "@pisell/utils": "1.0.42",
63
+ "@pisell/date-picker": "3.0.2",
63
64
  "@pisell/materials": "3.3.5",
64
- "@pisell/icon": "0.0.11",
65
- "@pisell/date-picker": "3.0.2"
65
+ "@pisell/icon": "0.0.11"
66
66
  },
67
67
  "peerDependencies": {
68
68
  "react": "^18.0.0",