touchstudy-core 0.1.135 → 0.1.136

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.
@@ -29965,7 +29965,7 @@ var useSelect = function useSelect(_ref) {
29965
29965
  };
29966
29966
 
29967
29967
  var OwnerSelector = function OwnerSelector(_ref) {
29968
- var _errors$textbookOwner, _errors$textbookOwner2, _errors$textbookOwner3, _errors$textbookOwner4, _errors$textbookOwner5, _errors$textbookOwner6, _values$textbookOwner, _errors$textbookOwner7, _errors$textbookOwner8, _values$textbookOwner2, _errors$textbookOwner9, _errors$textbookOwner10;
29968
+ var _values$textbookOwner, _errors$textbookOwner, _errors$textbookOwner2, _values$textbookOwner2, _errors$textbookOwner3, _errors$textbookOwner4;
29969
29969
  var values = _ref.values,
29970
29970
  errors = _ref.errors,
29971
29971
  index = _ref.index,
@@ -29979,30 +29979,10 @@ var OwnerSelector = function OwnerSelector(_ref) {
29979
29979
  handleChangeEmail: handleChangeEmail
29980
29980
  }),
29981
29981
  t = _useSelect.t,
29982
- loadData = _useSelect.loadData,
29983
29982
  isLoading = _useSelect.isLoading,
29984
29983
  academyOptions = _useSelect.academyOptions,
29985
29984
  courseOptions = _useSelect.courseOptions;
29986
- return React__default.createElement(React__default.Fragment, null, React__default.createElement(Stack, {
29987
- flexDirection: "column",
29988
- gap: 1,
29989
- width: 1
29990
- }, React__default.createElement("label", {
29991
- htmlFor: "email"
29992
- }, t("email")), React__default.createElement(Field, {
29993
- name: "textbookOwners[" + index + "].email",
29994
- render: function render() {
29995
- return React__default.createElement(TextField, {
29996
- fullWidth: true,
29997
- onChange: loadData
29998
- });
29999
- }
30000
- }), !!(errors !== null && errors !== void 0 && (_errors$textbookOwner = errors.textbookOwners) !== null && _errors$textbookOwner !== void 0 && (_errors$textbookOwner2 = _errors$textbookOwner[index]) !== null && _errors$textbookOwner2 !== void 0 && _errors$textbookOwner2.email) && React__default.createElement(Typography, {
30001
- fontWeight: 500,
30002
- fontSize: "10px",
30003
- lineHeight: "11.93px",
30004
- color: !(errors !== null && errors !== void 0 && (_errors$textbookOwner3 = errors.textbookOwners) !== null && _errors$textbookOwner3 !== void 0 && (_errors$textbookOwner4 = _errors$textbookOwner3[index]) !== null && _errors$textbookOwner4 !== void 0 && _errors$textbookOwner4.email) ? "#97A1AF" : "#F34B4B"
30005
- }, errors === null || errors === void 0 ? void 0 : (_errors$textbookOwner5 = errors.textbookOwners) === null || _errors$textbookOwner5 === void 0 ? void 0 : (_errors$textbookOwner6 = _errors$textbookOwner5[index]) === null || _errors$textbookOwner6 === void 0 ? void 0 : _errors$textbookOwner6.email)), (values === null || values === void 0 ? void 0 : (_values$textbookOwner = values.textbookOwners) === null || _values$textbookOwner === void 0 ? void 0 : _values$textbookOwner[index].email) && React__default.createElement(Stack, {
29985
+ return React__default.createElement(React__default.Fragment, null, (values === null || values === void 0 ? void 0 : (_values$textbookOwner = values.textbookOwners) === null || _values$textbookOwner === void 0 ? void 0 : _values$textbookOwner[index].email) && React__default.createElement(Stack, {
30006
29986
  flexDirection: "column",
30007
29987
  gap: 1,
30008
29988
  width: 1
@@ -30021,7 +30001,7 @@ var OwnerSelector = function OwnerSelector(_ref) {
30021
30001
  }
30022
30002
  }));
30023
30003
  }
30024
- }), !!(errors !== null && errors !== void 0 && (_errors$textbookOwner7 = errors.textbookOwners) !== null && _errors$textbookOwner7 !== void 0 && (_errors$textbookOwner8 = _errors$textbookOwner7[index]) !== null && _errors$textbookOwner8 !== void 0 && _errors$textbookOwner8.academyId) && React__default.createElement(Typography, {
30004
+ }), !!(errors !== null && errors !== void 0 && (_errors$textbookOwner = errors.textbookOwners) !== null && _errors$textbookOwner !== void 0 && (_errors$textbookOwner2 = _errors$textbookOwner[index]) !== null && _errors$textbookOwner2 !== void 0 && _errors$textbookOwner2.academyId) && React__default.createElement(Typography, {
30025
30005
  fontWeight: 500,
30026
30006
  fontSize: "10px",
30027
30007
  lineHeight: "11.93px",
@@ -30045,7 +30025,7 @@ var OwnerSelector = function OwnerSelector(_ref) {
30045
30025
  }
30046
30026
  }));
30047
30027
  }
30048
- }), !!(errors !== null && errors !== void 0 && (_errors$textbookOwner9 = errors.textbookOwners) !== null && _errors$textbookOwner9 !== void 0 && (_errors$textbookOwner10 = _errors$textbookOwner9[index]) !== null && _errors$textbookOwner10 !== void 0 && _errors$textbookOwner10.courseId) && React__default.createElement(Typography, {
30028
+ }), !!(errors !== null && errors !== void 0 && (_errors$textbookOwner3 = errors.textbookOwners) !== null && _errors$textbookOwner3 !== void 0 && (_errors$textbookOwner4 = _errors$textbookOwner3[index]) !== null && _errors$textbookOwner4 !== void 0 && _errors$textbookOwner4.courseId) && React__default.createElement(Typography, {
30049
30029
  fontWeight: 500,
30050
30030
  fontSize: "10px",
30051
30031
  lineHeight: "11.93px",
@@ -30223,7 +30203,7 @@ var convertResponseToRequest = function convertResponseToRequest(selectedTextboo
30223
30203
  questions: g.questions.map(function (q) {
30224
30204
  var _q$questionType;
30225
30205
  return _extends({}, q, {
30226
- questionTypeId: q.questionTypeId,
30206
+ questionTypeId: q.questionTypeId || q.questionType.id,
30227
30207
  questionType: (_q$questionType = q.questionType) !== null && _q$questionType !== void 0 && _q$questionType.id ? {
30228
30208
  label: q.questionType.name,
30229
30209
  value: q.questionType.id