@fctc/widget-logic 2.0.10 → 2.1.0

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/index.js CHANGED
@@ -5750,7 +5750,7 @@ var durationController = (props) => {
5750
5750
  // src/widget/basic/priority-field/controller.ts
5751
5751
  var import_utils10 = require("@fctc/interface-logic/utils");
5752
5752
  var priorityFieldController = (props) => {
5753
- const { name, model, id, actionData, context, onChange } = props;
5753
+ const { name, model, id, actionData, context, onChange, specification } = props;
5754
5754
  const _context = { ...(0, import_utils10.evalJSONContext)(actionData?.context) };
5755
5755
  const contextObject = { ...context, ..._context };
5756
5756
  const { useSave: useSave2 } = (0, provider_exports.useService)();
@@ -5763,12 +5763,13 @@ var priorityFieldController = (props) => {
5763
5763
  try {
5764
5764
  fetchSave({
5765
5765
  ids: id ? [id] : [],
5766
- data: { [name ?? ""]: String(priorityValue) },
5767
- model: model ?? "",
5768
- context: contextObject
5766
+ data: { [String(name)]: String(priorityValue) },
5767
+ model: String(model),
5768
+ context: contextObject,
5769
+ specification
5769
5770
  });
5770
5771
  if (typeof onChange === "function") {
5771
- onChange(name ?? "", String(priorityValue));
5772
+ onChange(String(name), String(priorityValue));
5772
5773
  }
5773
5774
  } catch (error) {
5774
5775
  if (resetPriority) {
package/dist/index.mjs CHANGED
@@ -5784,7 +5784,7 @@ var durationController = (props) => {
5784
5784
  // src/widget/basic/priority-field/controller.ts
5785
5785
  import { evalJSONContext as evalJSONContext6 } from "@fctc/interface-logic/utils";
5786
5786
  var priorityFieldController = (props) => {
5787
- const { name, model, id, actionData, context, onChange } = props;
5787
+ const { name, model, id, actionData, context, onChange, specification } = props;
5788
5788
  const _context = { ...evalJSONContext6(actionData?.context) };
5789
5789
  const contextObject = { ...context, ..._context };
5790
5790
  const { useSave: useSave2 } = (0, provider_exports.useService)();
@@ -5797,12 +5797,13 @@ var priorityFieldController = (props) => {
5797
5797
  try {
5798
5798
  fetchSave({
5799
5799
  ids: id ? [id] : [],
5800
- data: { [name ?? ""]: String(priorityValue) },
5801
- model: model ?? "",
5802
- context: contextObject
5800
+ data: { [String(name)]: String(priorityValue) },
5801
+ model: String(model),
5802
+ context: contextObject,
5803
+ specification
5803
5804
  });
5804
5805
  if (typeof onChange === "function") {
5805
- onChange(name ?? "", String(priorityValue));
5806
+ onChange(String(name), String(priorityValue));
5806
5807
  }
5807
5808
  } catch (error) {
5808
5809
  if (resetPriority) {
package/dist/widget.d.mts CHANGED
@@ -132,6 +132,7 @@ interface IPriorityFieldProps extends IInputFieldProps {
132
132
  id: any;
133
133
  actionData: any;
134
134
  context: any;
135
+ specification?: any;
135
136
  }
136
137
 
137
138
  declare const priorityFieldController: (props: IPriorityFieldProps) => {
package/dist/widget.d.ts CHANGED
@@ -132,6 +132,7 @@ interface IPriorityFieldProps extends IInputFieldProps {
132
132
  id: any;
133
133
  actionData: any;
134
134
  context: any;
135
+ specification?: any;
135
136
  }
136
137
 
137
138
  declare const priorityFieldController: (props: IPriorityFieldProps) => {
package/dist/widget.js CHANGED
@@ -5475,7 +5475,7 @@ var durationController = (props) => {
5475
5475
  // src/widget/basic/priority-field/controller.ts
5476
5476
  var import_utils10 = require("@fctc/interface-logic/utils");
5477
5477
  var priorityFieldController = (props) => {
5478
- const { name, model, id, actionData, context, onChange } = props;
5478
+ const { name, model, id, actionData, context, onChange, specification } = props;
5479
5479
  const _context = { ...(0, import_utils10.evalJSONContext)(actionData?.context) };
5480
5480
  const contextObject = { ...context, ..._context };
5481
5481
  const { useSave: useSave2 } = (0, provider_exports.useService)();
@@ -5488,12 +5488,13 @@ var priorityFieldController = (props) => {
5488
5488
  try {
5489
5489
  fetchSave({
5490
5490
  ids: id ? [id] : [],
5491
- data: { [name ?? ""]: String(priorityValue) },
5492
- model: model ?? "",
5493
- context: contextObject
5491
+ data: { [String(name)]: String(priorityValue) },
5492
+ model: String(model),
5493
+ context: contextObject,
5494
+ specification
5494
5495
  });
5495
5496
  if (typeof onChange === "function") {
5496
- onChange(name ?? "", String(priorityValue));
5497
+ onChange(String(name), String(priorityValue));
5497
5498
  }
5498
5499
  } catch (error) {
5499
5500
  if (resetPriority) {
package/dist/widget.mjs CHANGED
@@ -5486,7 +5486,7 @@ var durationController = (props) => {
5486
5486
  // src/widget/basic/priority-field/controller.ts
5487
5487
  import { evalJSONContext as evalJSONContext6 } from "@fctc/interface-logic/utils";
5488
5488
  var priorityFieldController = (props) => {
5489
- const { name, model, id, actionData, context, onChange } = props;
5489
+ const { name, model, id, actionData, context, onChange, specification } = props;
5490
5490
  const _context = { ...evalJSONContext6(actionData?.context) };
5491
5491
  const contextObject = { ...context, ..._context };
5492
5492
  const { useSave: useSave2 } = (0, provider_exports.useService)();
@@ -5499,12 +5499,13 @@ var priorityFieldController = (props) => {
5499
5499
  try {
5500
5500
  fetchSave({
5501
5501
  ids: id ? [id] : [],
5502
- data: { [name ?? ""]: String(priorityValue) },
5503
- model: model ?? "",
5504
- context: contextObject
5502
+ data: { [String(name)]: String(priorityValue) },
5503
+ model: String(model),
5504
+ context: contextObject,
5505
+ specification
5505
5506
  });
5506
5507
  if (typeof onChange === "function") {
5507
- onChange(name ?? "", String(priorityValue));
5508
+ onChange(String(name), String(priorityValue));
5508
5509
  }
5509
5510
  } catch (error) {
5510
5511
  if (resetPriority) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fctc/widget-logic",
3
- "version": "2.0.10",
3
+ "version": "2.1.0",
4
4
  "types": "dist/index.d.ts",
5
5
  "main": "dist/index.cjs",
6
6
  "module": "dist/index.mjs",