@pisell/materials 6.11.54 → 6.11.55

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.
Files changed (122) hide show
  1. package/build/lowcode/assets-daily.json +11 -11
  2. package/build/lowcode/assets-dev.json +2 -2
  3. package/build/lowcode/assets-prod.json +11 -11
  4. package/build/lowcode/meta.js +1 -1
  5. package/build/lowcode/render/default/view.js +4 -4
  6. package/build/lowcode/view.js +4 -4
  7. package/es/components/PisellCards/index.d.ts +0 -1
  8. package/es/components/PisellFields/index.d.ts +0 -1
  9. package/es/components/PisellLayouts/index.d.ts +0 -1
  10. package/es/components/PisellMetrics/index.d.ts +0 -1
  11. package/es/components/dataSourceComponents/dataSourceForm/BaseForm.js +32 -21
  12. package/es/components/dataSourceComponents/dataSourceForm/provider/formSetting/FormSettingContext.d.ts +2 -0
  13. package/es/components/dataSourceComponents/dataSourceForm/provider/formSetting/FormSettingProvider.js +7 -3
  14. package/es/components/dataSourceComponents/dataSourceForm/serve.d.ts +23 -0
  15. package/es/components/dataSourceComponents/dataSourceForm/serve.js +99 -0
  16. package/es/components/dataSourceComponents/dataSourceForm/submitButton/index.js +35 -20
  17. package/es/components/dataSourceComponents/dataSourceForm/type.d.ts +3 -0
  18. package/es/components/dataSourceComponents/dataSourceForm/utils.d.ts +1 -1
  19. package/es/components/dataSourceComponents/dataSourceShow/dataSourceQRCode/index.d.ts +0 -1
  20. package/es/components/dataSourceComponents/dataSourceTable/BaseTable.js +1 -1
  21. package/es/components/dataSourceComponents/dataSourceTable/hooks/useDataSourceKey.d.ts +0 -1
  22. package/es/components/dataSourceComponents/dataSourceTable/hooks/useDrawerState.d.ts +0 -1
  23. package/es/components/dataSourceComponents/dataSourceTable/hooks/useTableQuery.d.ts +0 -1
  24. package/es/components/dataSourceComponents/fields/Input.Subdomain/index.d.ts +1 -1
  25. package/es/components/dataSourceComponents/fields/RecordListWrapper/index.d.ts +1 -1
  26. package/es/components/dataSourceComponents/fields/Select/index.d.ts +1 -1
  27. package/es/components/dataSourceComponents/fields/Tabs/index.d.ts +1 -2
  28. package/es/components/dataSourceComponents/fields/Upload/utils.d.ts +1 -1
  29. package/es/components/dataSourceComponents/fields/index.d.ts +14 -15
  30. package/es/components/dataSourceComponents/hooks/useActions.js +1 -1
  31. package/es/components/dataSourceComponents/provider/dataSource/DataSourceContext.d.ts +1 -0
  32. package/es/components/date-picker/index.d.ts +0 -1
  33. package/es/components/pisellDataSourceContainer/hooks/useDataSourceKey.d.ts +0 -1
  34. package/es/components/pisellDatePicker/index.d.ts +0 -1
  35. package/es/components/pisellFloorMapLayout/PisellFloorMapLayout.js +4 -4
  36. package/es/components/pisellFloorMapLayout/components/ViewControls.js +2 -2
  37. package/es/components/pisellFloorMapLayout/hooks/useFloorMapTransformMetrics.js +3 -3
  38. package/es/components/pisellFloorMapLayout/types.d.ts +1 -1
  39. package/es/components/pisellModal/components/index.d.ts +0 -1
  40. package/es/components/pisellRecordBoard/shellFrame/Calendar/utils/BookingCalendarStyle.d.ts +1 -1
  41. package/es/components/productCard/cartSkuCard/components/packages/utils.d.ts +1 -1
  42. package/es/components/productCard/components/Packages/utils.d.ts +1 -1
  43. package/es/components/table/Table/fields/date/index.d.ts +0 -1
  44. package/es/components/table/Table/fields/image/index.d.ts +0 -1
  45. package/es/components/table/Table/fields/index.d.ts +0 -1
  46. package/es/components/table/Table/fields/link/index.d.ts +0 -1
  47. package/es/components/table/Table/fields/number/index.d.ts +0 -1
  48. package/es/components/table/Table/fields/numberRange/index.d.ts +0 -1
  49. package/es/components/table/Table/fields/oldRangePicker/index.d.ts +0 -1
  50. package/es/components/table/Table/fields/pSwitch/index.d.ts +0 -1
  51. package/es/components/table/Table/fields/rangePicker/index.d.ts +0 -1
  52. package/es/components/table/Table/fields/search/index.d.ts +0 -1
  53. package/es/components/table/Table/fields/select/index.d.ts +0 -1
  54. package/es/components/table/Table/fields/text/index.d.ts +0 -1
  55. package/es/components/table/Table/fields/treeSelect/index.d.ts +0 -1
  56. package/es/components/table/Table/utils.d.ts +1 -1
  57. package/es/locales/en-US.d.ts +1 -0
  58. package/es/locales/en-US.js +1 -0
  59. package/es/locales/zh-CN.d.ts +1 -0
  60. package/es/locales/zh-CN.js +1 -0
  61. package/es/locales/zh-TW.d.ts +1 -0
  62. package/es/locales/zh-TW.js +1 -0
  63. package/lib/components/PisellCards/index.d.ts +0 -1
  64. package/lib/components/PisellFields/index.d.ts +0 -1
  65. package/lib/components/PisellLayouts/index.d.ts +0 -1
  66. package/lib/components/PisellMetrics/index.d.ts +0 -1
  67. package/lib/components/dataSourceComponents/dataSourceForm/BaseForm.js +30 -14
  68. package/lib/components/dataSourceComponents/dataSourceForm/provider/formSetting/FormSettingContext.d.ts +2 -0
  69. package/lib/components/dataSourceComponents/dataSourceForm/provider/formSetting/FormSettingProvider.js +7 -3
  70. package/lib/components/dataSourceComponents/dataSourceForm/serve.d.ts +23 -0
  71. package/lib/components/dataSourceComponents/dataSourceForm/serve.js +69 -1
  72. package/lib/components/dataSourceComponents/dataSourceForm/submitButton/index.js +8 -1
  73. package/lib/components/dataSourceComponents/dataSourceForm/type.d.ts +3 -0
  74. package/lib/components/dataSourceComponents/dataSourceForm/utils.d.ts +1 -1
  75. package/lib/components/dataSourceComponents/dataSourceShow/dataSourceQRCode/index.d.ts +0 -1
  76. package/lib/components/dataSourceComponents/dataSourceTable/BaseTable.js +1 -1
  77. package/lib/components/dataSourceComponents/dataSourceTable/hooks/useDataSourceKey.d.ts +0 -1
  78. package/lib/components/dataSourceComponents/dataSourceTable/hooks/useDrawerState.d.ts +0 -1
  79. package/lib/components/dataSourceComponents/dataSourceTable/hooks/useTableQuery.d.ts +0 -1
  80. package/lib/components/dataSourceComponents/fields/Input.Subdomain/index.d.ts +1 -1
  81. package/lib/components/dataSourceComponents/fields/RecordListWrapper/index.d.ts +1 -1
  82. package/lib/components/dataSourceComponents/fields/Select/index.d.ts +1 -1
  83. package/lib/components/dataSourceComponents/fields/Tabs/index.d.ts +1 -2
  84. package/lib/components/dataSourceComponents/fields/Upload/utils.d.ts +1 -1
  85. package/lib/components/dataSourceComponents/fields/index.d.ts +14 -15
  86. package/lib/components/dataSourceComponents/hooks/useActions.js +1 -1
  87. package/lib/components/dataSourceComponents/provider/dataSource/DataSourceContext.d.ts +1 -0
  88. package/lib/components/date-picker/index.d.ts +0 -1
  89. package/lib/components/pisellDataSourceContainer/hooks/useDataSourceKey.d.ts +0 -1
  90. package/lib/components/pisellDatePicker/index.d.ts +0 -1
  91. package/lib/components/pisellFloorMapLayout/PisellFloorMapLayout.js +3 -3
  92. package/lib/components/pisellFloorMapLayout/components/ViewControls.js +2 -2
  93. package/lib/components/pisellFloorMapLayout/types.d.ts +1 -1
  94. package/lib/components/pisellModal/components/index.d.ts +0 -1
  95. package/lib/components/pisellRecordBoard/shellFrame/Calendar/utils/BookingCalendarStyle.d.ts +1 -1
  96. package/lib/components/productCard/cartSkuCard/components/packages/utils.d.ts +1 -1
  97. package/lib/components/productCard/components/Packages/utils.d.ts +1 -1
  98. package/lib/components/table/Table/fields/date/index.d.ts +0 -1
  99. package/lib/components/table/Table/fields/image/index.d.ts +0 -1
  100. package/lib/components/table/Table/fields/index.d.ts +0 -1
  101. package/lib/components/table/Table/fields/link/index.d.ts +0 -1
  102. package/lib/components/table/Table/fields/number/index.d.ts +0 -1
  103. package/lib/components/table/Table/fields/numberRange/index.d.ts +0 -1
  104. package/lib/components/table/Table/fields/oldRangePicker/index.d.ts +0 -1
  105. package/lib/components/table/Table/fields/pSwitch/index.d.ts +0 -1
  106. package/lib/components/table/Table/fields/rangePicker/index.d.ts +0 -1
  107. package/lib/components/table/Table/fields/search/index.d.ts +0 -1
  108. package/lib/components/table/Table/fields/select/index.d.ts +0 -1
  109. package/lib/components/table/Table/fields/text/index.d.ts +0 -1
  110. package/lib/components/table/Table/fields/treeSelect/index.d.ts +0 -1
  111. package/lib/components/table/Table/utils.d.ts +1 -1
  112. package/lib/locales/en-US.d.ts +1 -0
  113. package/lib/locales/en-US.js +1 -0
  114. package/lib/locales/zh-CN.d.ts +1 -0
  115. package/lib/locales/zh-CN.js +1 -0
  116. package/lib/locales/zh-TW.d.ts +1 -0
  117. package/lib/locales/zh-TW.js +1 -0
  118. package/lowcode/data-source-form/meta.ts +53 -4
  119. package/lowcode/data-source-form/utils.ts +43 -5
  120. package/lowcode/data-source-table/meta.ts +51 -45
  121. package/lowcode/pisell-record-board-calendar-view/meta.ts +1 -1
  122. package/package.json +3 -3
@@ -175,4 +175,27 @@ export declare const updateTenantSetting: (params: {
175
175
  target?: string | undefined;
176
176
  data: Record<string, any>;
177
177
  }) => Promise<any>;
178
+ export declare type DeviceSettingScene = 'template' | 'profile' | 'instance';
179
+ /**
180
+ * 获取设备设置元数据(POST 类型 GET)
181
+ * @param params.scene 场景,默认 template
182
+ * @param params.sceneRequestId URL 中 {id} 占位符的实际取值
183
+ * @param params.items 需要获取的字段列表,例如 ['order.name', 'order.id']
184
+ */
185
+ export declare const getDeviceSettingMetaData: (params: {
186
+ scene?: DeviceSettingScene | undefined;
187
+ sceneRequestId: string;
188
+ items: string[];
189
+ }) => Promise<any>;
190
+ /**
191
+ * 更新设备设置数据
192
+ * @param params.scene 场景,默认 template
193
+ * @param params.sceneRequestId URL 中 {id} 占位符的实际取值
194
+ * @param params.data 需要更新的字段值对象
195
+ */
196
+ export declare const updateDeviceSetting: (params: {
197
+ scene?: DeviceSettingScene | undefined;
198
+ sceneRequestId: string;
199
+ data: Record<string, any>;
200
+ }) => Promise<any>;
178
201
  export {};
@@ -32,12 +32,14 @@ __export(serve_exports, {
32
32
  createNocobaseData: () => createNocobaseData,
33
33
  customApi: () => customApi,
34
34
  deleteNocobaseData: () => deleteNocobaseData,
35
+ getDeviceSettingMetaData: () => getDeviceSettingMetaData,
35
36
  getFormSettingMetaData: () => getFormSettingMetaData,
36
37
  getNocobaseData: () => getNocobaseData,
37
38
  getNocobaseDataList: () => getNocobaseDataList,
38
39
  getNocobaseDataSource: () => getNocobaseDataSource,
39
40
  getNocobaseDataSourceOptions: () => getNocobaseDataSourceOptions,
40
41
  getNocobaseMainDataSource: () => getNocobaseMainDataSource,
42
+ updateDeviceSetting: () => updateDeviceSetting,
41
43
  updateNocobaseData: () => updateNocobaseData,
42
44
  updateTenantSetting: () => updateTenantSetting
43
45
  });
@@ -115,7 +117,14 @@ var formatRequestUrl = (url, baseUrl, queryString) => {
115
117
  return queryString ? `${baseRequestUrl}${baseRequestUrl.includes("?") ? "&" : "?"}${queryString}` : baseRequestUrl;
116
118
  };
117
119
  var customApi = async (url, data, options) => {
118
- const { method, baseUrl, headers = [], params = [], body = {}, dataSourceKey } = options;
120
+ const {
121
+ method,
122
+ baseUrl,
123
+ headers = [],
124
+ params = [],
125
+ body = {},
126
+ dataSourceKey
127
+ } = options;
119
128
  const requestHeaders = formatHeaders(headers);
120
129
  const queryString = formatQueryString(params);
121
130
  const requestUrl = formatRequestUrl(url, baseUrl, queryString);
@@ -194,17 +203,76 @@ var updateTenantSetting = async (params) => {
194
203
  }
195
204
  });
196
205
  };
206
+ var buildDeviceSettingUrl = (scene = "template", id) => {
207
+ switch (scene) {
208
+ case "profile":
209
+ return `/tenant/device/profile/${id}/setting`;
210
+ case "instance":
211
+ return `/tenant/device/${id}/setting`;
212
+ case "template":
213
+ default:
214
+ return `/admin/device/profile/template/${id}/setting`;
215
+ }
216
+ };
217
+ var getDeviceSettingMetaData = async (params) => {
218
+ const { scene, sceneRequestId, items } = params;
219
+ console.log("getDeviceSettingMetaData", params);
220
+ if (!sceneRequestId) {
221
+ (0, import_pisellToast.default)({
222
+ content: (0, import_locales.getText)("pisell-data-source-form-scene-request-id-message")
223
+ });
224
+ return {};
225
+ }
226
+ const url = buildDeviceSettingUrl(scene, sceneRequestId);
227
+ return import_utils.request.getRequest().post(
228
+ url,
229
+ {
230
+ items
231
+ },
232
+ {
233
+ headers: {
234
+ "Content-Type": "application/json"
235
+ },
236
+ isPisell2: true
237
+ }
238
+ );
239
+ };
240
+ var updateDeviceSetting = async (params) => {
241
+ const { scene, sceneRequestId, data } = params;
242
+ console.log("updateDeviceSetting", params);
243
+ if (!sceneRequestId) {
244
+ (0, import_pisellToast.default)({
245
+ content: (0, import_locales.getText)("pisell-data-source-form-scene-request-id-message")
246
+ });
247
+ return {};
248
+ }
249
+ const url = buildDeviceSettingUrl(scene, sceneRequestId);
250
+ return import_utils.request.getRequest().put(
251
+ url,
252
+ {
253
+ items: data
254
+ },
255
+ {
256
+ headers: {
257
+ "Content-Type": "application/json"
258
+ },
259
+ isPisell2: true
260
+ }
261
+ );
262
+ };
197
263
  // Annotate the CommonJS export names for ESM import in node:
198
264
  0 && (module.exports = {
199
265
  createNocobaseData,
200
266
  customApi,
201
267
  deleteNocobaseData,
268
+ getDeviceSettingMetaData,
202
269
  getFormSettingMetaData,
203
270
  getNocobaseData,
204
271
  getNocobaseDataList,
205
272
  getNocobaseDataSource,
206
273
  getNocobaseDataSourceOptions,
207
274
  getNocobaseMainDataSource,
275
+ updateDeviceSetting,
208
276
  updateNocobaseData,
209
277
  updateTenantSetting
210
278
  });
@@ -61,13 +61,20 @@ var SubmitButton = (props) => {
61
61
  const [api, contextHolder] = import_antd.notification.useNotification();
62
62
  const { scope, target } = (0, import_useFormSettingParams.default)();
63
63
  const form = import_antd.Form.useFormInstance();
64
- const { renderMode, onDataSourceFinish, formatSubmitValues, customSubmit, beforeSubmit } = (0, import_useFormSetting.default)();
64
+ const { renderMode, onDataSourceFinish, formatSubmitValues, customSubmit, beforeSubmit, scene, sceneRequestId } = (0, import_useFormSetting.default)();
65
65
  const { setVisible, refreshTableData } = (0, import_useCtxActions.default)();
66
66
  const { create, update, dataSource } = (0, import_useDataSource.default)();
67
67
  const isDisabled = status === "disabled";
68
68
  const onSubmit = async (values) => {
69
69
  setLoading(true);
70
70
  try {
71
+ if (dataSource == null ? void 0 : dataSource.fromDeviceSettingMeta) {
72
+ return await (0, import_serve.updateDeviceSetting)({
73
+ scene,
74
+ sceneRequestId: sceneRequestId || "",
75
+ data: values
76
+ });
77
+ }
71
78
  if (dataSource == null ? void 0 : dataSource.fromSettingMeta) {
72
79
  return await (0, import_serve.updateTenantSetting)({
73
80
  scope,
@@ -12,6 +12,8 @@ export interface DataSourceFormProps {
12
12
  variables: any[];
13
13
  renderMode?: ModeType;
14
14
  currentValue?: 'server' | 'local';
15
+ scene?: 'template' | 'profile' | 'instance';
16
+ sceneRequestId?: string;
15
17
  children: React.ReactNode;
16
18
  className?: string;
17
19
  size?: 'small' | 'middle' | 'large';
@@ -19,6 +21,7 @@ export interface DataSourceFormProps {
19
21
  __designMode?: string;
20
22
  formatSubmitValues?: (values: Record<string, any>) => Record<string, any>;
21
23
  formatInitialValues?: (values: Record<string, any>) => Record<string, any>;
24
+ onDataSourceLoaded?: (values: Record<string, any>, result: any) => void;
22
25
  customSubmit?: (values: Record<string, any>) => Promise<any>;
23
26
  beforeSubmit?: (values: Record<string, any>) => Promise<boolean> | boolean;
24
27
  leaveConfirmConfig?: {
@@ -44,7 +44,7 @@ export declare const withDataSource: <P extends unknown>(WrappedComponent: React
44
44
  }) => React.JSX.Element;
45
45
  export declare const withOptions: <P extends unknown>(WrappedComponent: React.ComponentType<P>) => (props: P & {
46
46
  options?: any;
47
- optionSourceType?: "default" | "api" | "custom" | undefined;
47
+ optionSourceType?: "default" | "custom" | "api" | undefined;
48
48
  labelField: string;
49
49
  valueField: string;
50
50
  extraParams?: Record<string, any> | undefined;
@@ -1,3 +1,2 @@
1
- /// <reference types="react" />
2
1
  declare const DataSourceQRCode: (props: any) => import("react").JSX.Element;
3
2
  export default DataSourceQRCode;
@@ -105,7 +105,7 @@ var BaseTable = (props, ref) => {
105
105
  }, [dataSourceKey]);
106
106
  (0, import_react.useEffect)(() => {
107
107
  if (dataSourceKeyRef.current) {
108
- if (dataSource == null ? void 0 : dataSource.fromSettingMeta) return;
108
+ if ((dataSource == null ? void 0 : dataSource.fromSettingMeta) || (dataSource == null ? void 0 : dataSource.fromDeviceSettingMeta)) return;
109
109
  list == null ? void 0 : list.run(queryPageConfig);
110
110
  } else {
111
111
  list == null ? void 0 : list.mutate([]);
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const useDataSourceKey: () => {
3
2
  dataSourceKey: string | undefined;
4
3
  dataSourceKeyRef: import("react").MutableRefObject<string | undefined>;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const useDrawerState: (operationContent?: {
3
2
  [key: string]: import("react").ReactNode;
4
3
  } | undefined) => any;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { DataSourceTableProps } from '../type';
3
2
  declare type Params = {
4
3
  pagination?: {
@@ -2,7 +2,7 @@ import React from 'react';
2
2
  declare const Subdomain: React.FC<import("antd").InputProps & {
3
3
  onChange: (value: string) => void;
4
4
  onBlur?: ((e: React.FocusEvent<HTMLInputElement, Element>) => void) | undefined;
5
- rootDomain: "saas" | "custom" | "xzero";
5
+ rootDomain: "custom" | "saas" | "xzero";
6
6
  customDomain?: string | undefined;
7
7
  value?: string | undefined;
8
8
  tenantId: string;
@@ -1,7 +1,7 @@
1
1
  import React from 'react';
2
2
  declare const RecordListWrapperWithDataSource: (props: import("./type").RecordListWrapperProps & import("../../dataSourceForm/utils").WithModeProps & import("../../dataSourceForm/utils").WithFormItemProps & {
3
3
  options?: any;
4
- optionSourceType?: "default" | "api" | "custom" | undefined;
4
+ optionSourceType?: "default" | "custom" | "api" | undefined;
5
5
  labelField: string;
6
6
  valueField: string;
7
7
  extraParams?: Record<string, any> | undefined;
@@ -1,7 +1,7 @@
1
1
  import React from 'react';
2
2
  declare const SelectWithDataSource: (props: import("antd").SelectProps<any, import("antd/es/select").DefaultOptionType> & import("../../dataSourceForm/utils").WithModeProps & import("../../dataSourceForm/utils").WithFormItemProps & {
3
3
  options?: any;
4
- optionSourceType?: "default" | "api" | "custom" | undefined;
4
+ optionSourceType?: "default" | "custom" | "api" | undefined;
5
5
  labelField: string;
6
6
  valueField: string;
7
7
  extraParams?: Record<string, any> | undefined;
@@ -1,8 +1,7 @@
1
- /// <reference types="react" />
2
1
  /** 包装 DataSource 层(提供数据源上下文) */
3
2
  declare const FormItemTabs: (props: import("./type").TabsProps & import("../../dataSourceForm/utils").WithModeProps & import("../../dataSourceForm/utils").WithFormItemProps & {
4
3
  options?: any;
5
- optionSourceType?: "default" | "api" | "custom" | undefined;
4
+ optionSourceType?: "default" | "custom" | "api" | undefined;
6
5
  labelField: string;
7
6
  valueField: string;
8
7
  extraParams?: Record<string, any> | undefined;
@@ -15,4 +15,4 @@ export declare const getFileMetadataParams: (file: RcFile & {
15
15
  metadata?: MediaMetadata;
16
16
  }) => Record<string, any>;
17
17
  export declare const isValueEqual: (value: any, fileListValue: any) => boolean;
18
- export declare const getBaseTime: (size: number) => 2000 | 1000 | 4000 | 8000;
18
+ export declare const getBaseTime: (size: number) => 1000 | 2000 | 4000 | 8000;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const formFieldMap: {
3
2
  FormItemCheckbox: import("react").FC<{}> & {
4
3
  Group: import("react").FC<import("./Checkbox/type").CheckboxGroupProps & import("../dataSourceForm/utils").WithModeProps>;
@@ -20,7 +19,7 @@ declare const formFieldMap: {
20
19
  Subdomain: import("react").FC<import("antd").InputProps & {
21
20
  onChange: (value: string) => void;
22
21
  onBlur?: ((e: import("react").FocusEvent<HTMLInputElement, Element>) => void) | undefined;
23
- rootDomain: "saas" | "custom" | "xzero";
22
+ rootDomain: "custom" | "saas" | "xzero";
24
23
  customDomain?: string | undefined;
25
24
  value?: string | undefined;
26
25
  tenantId: string;
@@ -35,7 +34,7 @@ declare const formFieldMap: {
35
34
  };
36
35
  FormItemSelect: (props: import("antd").SelectProps<any, import("antd/es/select").DefaultOptionType> & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps & {
37
36
  options?: any;
38
- optionSourceType?: "default" | "api" | "custom" | undefined;
37
+ optionSourceType?: "default" | "custom" | "api" | undefined;
39
38
  labelField: string;
40
39
  valueField: string;
41
40
  extraParams?: Record<string, any> | undefined;
@@ -62,7 +61,7 @@ declare const formFieldMap: {
62
61
  FormItemIconSelect: import("react").FC<import("./IconSelect/type").IconSelectProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps>;
63
62
  FormItemRecordListWrapper: (props: import("./RecordListWrapper/type").RecordListWrapperProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps & {
64
63
  options?: any;
65
- optionSourceType?: "default" | "api" | "custom" | undefined;
64
+ optionSourceType?: "default" | "custom" | "api" | undefined;
66
65
  labelField: string;
67
66
  valueField: string;
68
67
  extraParams?: Record<string, any> | undefined;
@@ -72,7 +71,7 @@ declare const formFieldMap: {
72
71
  }) => import("react").JSX.Element;
73
72
  FormItemTabs: (props: import("./Tabs/type").TabsProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps & {
74
73
  options?: any;
75
- optionSourceType?: "default" | "api" | "custom" | undefined;
74
+ optionSourceType?: "default" | "custom" | "api" | undefined;
76
75
  labelField: string;
77
76
  valueField: string;
78
77
  extraParams?: Record<string, any> | undefined;
@@ -81,11 +80,13 @@ declare const formFieldMap: {
81
80
  extraParams?: Record<string, any> | undefined;
82
81
  }) => import("react").JSX.Element;
83
82
  };
84
- declare const getFieldComponent: (fieldComponent: string) => import("react").FC<any> | import("react").FC<import("./Upload/type").UploadProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps> | (import("react").FC<{}> & {
83
+ declare const getFieldComponent: (fieldComponent: string) => import("react").FC<any> | import("react").FC<import("./Checkbox/type").CheckboxGroupProps & import("../dataSourceForm/utils").WithModeProps> | (import("react").FC<{}> & {
85
84
  Group: import("react").FC<import("./Checkbox/type").CheckboxGroupProps & import("../dataSourceForm/utils").WithModeProps>;
86
85
  } & {
87
86
  Group: import("react").FC<import("./Checkbox/type").CheckboxGroupProps & import("../dataSourceForm/utils").WithModeProps>;
88
- }) | import("react").FC<import("./ColorPicker/type").ColorPickerProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps> | import("react").FC<(import("antd").DatePickerProps & import("../dataSourceForm/utils").WithModeProps) & import("../dataSourceForm/utils").WithFormItemProps> | (import("react").FC<import("./Input/type").InputProps> & {
87
+ }) | import("react").FC<import("./ColorPicker/type").ColorPickerProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps> | import("react").FC<(import("antd").DatePickerProps & import("../dataSourceForm/utils").WithModeProps) & import("../dataSourceForm/utils").WithFormItemProps> | import("react").FC<import("antd/es/input").PasswordProps & import("react").RefAttributes<import("antd").InputRef> & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps> | import("react").FC<import("antd").InputProps & import("react").RefAttributes<import("antd").InputRef> & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps> | import("react").FC<import("antd").InputProps & {
88
+ onChange: (value: string) => void;
89
+ } & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps> | import("react").FC<import("./Input.Phone/WithMode").PhoneInputProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps> | import("react").FC<import("./Input.Mobile/WithMode").PhoneInputProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps> | (import("react").FC<import("./Input/type").InputProps> & {
89
90
  JSON: import("react").FC<any>;
90
91
  Password: import("react").FC<import("antd/es/input").PasswordProps & import("react").RefAttributes<import("antd").InputRef> & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps>;
91
92
  TextArea: import("react").FC<import("antd/es/input").TextAreaProps & import("react").RefAttributes<import("antd/es/input/TextArea").TextAreaRef> & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps>;
@@ -98,31 +99,29 @@ declare const getFieldComponent: (fieldComponent: string) => import("react").FC<
98
99
  Subdomain: import("react").FC<import("antd").InputProps & {
99
100
  onChange: (value: string) => void;
100
101
  onBlur?: ((e: import("react").FocusEvent<HTMLInputElement, Element>) => void) | undefined;
101
- rootDomain: "saas" | "custom" | "xzero";
102
+ rootDomain: "custom" | "saas" | "xzero";
102
103
  customDomain?: string | undefined;
103
104
  value?: string | undefined;
104
105
  tenantId: string;
105
106
  name?: string | undefined;
106
107
  fieldKey?: string | undefined;
107
108
  } & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps>;
108
- }) | (import("react").FC<{}> & {
109
+ }) | import("react").FC<import("./Radio/type").RadioGroupProps & import("../dataSourceForm/utils").WithModeProps> | (import("react").FC<{}> & {
109
110
  Group: import("react").FC<import("./Radio/type").RadioGroupProps & import("../dataSourceForm/utils").WithModeProps>;
110
111
  } & {
111
112
  Group: import("react").FC<import("./Radio/type").RadioGroupProps & import("../dataSourceForm/utils").WithModeProps>;
112
113
  }) | ((props: import("antd").SelectProps<any, import("antd/es/select").DefaultOptionType> & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps & {
113
114
  options?: any;
114
- optionSourceType?: "default" | "api" | "custom" | undefined;
115
+ optionSourceType?: "default" | "custom" | "api" | undefined;
115
116
  labelField: string;
116
117
  valueField: string;
117
118
  extraParams?: Record<string, any> | undefined;
118
119
  } & {
119
120
  dataSource?: any;
120
121
  extraParams?: Record<string, any> | undefined;
121
- }) => import("react").JSX.Element) | import("react").FC<import("./TimePicker/type").TimePickerProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps> | import("react").FC<import("./Input.Phone/WithMode").PhoneInputProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps> | import("react").FC<import("./Input.Mobile/WithMode").PhoneInputProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps> | import("react").FC<import("antd").InputProps & {
122
- onChange: (value: string) => void;
123
- } & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps> | import("react").FC<import("antd").InputProps & import("react").RefAttributes<import("antd").InputRef> & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps> | import("react").FC<import("antd/es/input").PasswordProps & import("react").RefAttributes<import("antd").InputRef> & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps> | import("react").FC<import("./Radio/type").RadioGroupProps & import("../dataSourceForm/utils").WithModeProps> | import("react").FC<import("./Checkbox/type").CheckboxGroupProps & import("../dataSourceForm/utils").WithModeProps> | import("react").FC<import("./DateRangePicker/type").DateRangePickerProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps> | import("react").FC<import("./Translation/type").TranslationProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps> | import("react").FC<import("./IconSelect/type").IconSelectProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps> | ((props: import("./RecordListWrapper/type").RecordListWrapperProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps & {
122
+ }) => import("react").JSX.Element) | import("react").FC<import("./TimePicker/type").TimePickerProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps> | import("react").FC<import("./DateRangePicker/type").DateRangePickerProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps> | import("react").FC<import("./Upload/type").UploadProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps> | import("react").FC<import("./Translation/type").TranslationProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps> | import("react").FC<import("./IconSelect/type").IconSelectProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps> | ((props: import("./RecordListWrapper/type").RecordListWrapperProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps & {
124
123
  options?: any;
125
- optionSourceType?: "default" | "api" | "custom" | undefined;
124
+ optionSourceType?: "default" | "custom" | "api" | undefined;
126
125
  labelField: string;
127
126
  valueField: string;
128
127
  extraParams?: Record<string, any> | undefined;
@@ -131,7 +130,7 @@ declare const getFieldComponent: (fieldComponent: string) => import("react").FC<
131
130
  extraParams?: Record<string, any> | undefined;
132
131
  }) => import("react").JSX.Element) | ((props: import("./Tabs/type").TabsProps & import("../dataSourceForm/utils").WithModeProps & import("../dataSourceForm/utils").WithFormItemProps & {
133
132
  options?: any;
134
- optionSourceType?: "default" | "api" | "custom" | undefined;
133
+ optionSourceType?: "default" | "custom" | "api" | undefined;
135
134
  labelField: string;
136
135
  valueField: string;
137
136
  extraParams?: Record<string, any> | undefined;
@@ -169,7 +169,7 @@ var useActions = ({
169
169
  designModeToast();
170
170
  return Promise.reject();
171
171
  }
172
- if (currentDataSource == null ? void 0 : currentDataSource.fromSettingMeta) {
172
+ if ((currentDataSource == null ? void 0 : currentDataSource.fromSettingMeta) || (currentDataSource == null ? void 0 : currentDataSource.fromDeviceSettingMeta)) {
173
173
  return Promise.reject();
174
174
  }
175
175
  if (isCustomApi) {
@@ -45,6 +45,7 @@ interface Style {
45
45
  export declare type ActionTypes = 'list' | 'get' | 'update' | 'create' | 'destroy';
46
46
  export declare type DataSourceType = {
47
47
  fromSettingMeta: boolean;
48
+ fromDeviceSettingMeta?: boolean;
48
49
  actions: {
49
50
  get: ActionsItem;
50
51
  update: ActionsItem;
@@ -1,3 +1,2 @@
1
- /// <reference types="react" />
2
1
  declare const DatePicker: (props: any) => import("react").JSX.Element;
3
2
  export default DatePicker;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const useDataSourceKey: () => {
3
2
  dataSourceKey: string | undefined;
4
3
  dataSourceKeyRef: import("react").MutableRefObject<string | undefined>;
@@ -1,3 +1,2 @@
1
- /// <reference types="react" />
2
1
  declare const PisellDatePicker: (props: any) => import("react").JSX.Element;
3
2
  export default PisellDatePicker;
@@ -326,9 +326,9 @@ function PisellFloorMapLayoutInner(props, ref) {
326
326
  return {
327
327
  ...controls,
328
328
  showFullscreen: controls.showFullscreen ?? Boolean(dockToggleFullscreen),
329
- showViewportLock: controls.showViewportLock ?? Boolean(viewportPersistKey)
329
+ showViewportLock: controls.showViewportLock ?? true
330
330
  };
331
- }, [isFloorMapView, controls, dockToggleFullscreen, viewportPersistKey]);
331
+ }, [isFloorMapView, controls, dockToggleFullscreen]);
332
332
  const topBarExtraActions = null;
333
333
  const [mapPaletteDragActive, setMapPaletteDragActive] = (0, import_react.useState)(false);
334
334
  (0, import_react.useEffect)(() => {
@@ -816,7 +816,7 @@ function PisellFloorMapLayoutInner(props, ref) {
816
816
  mapGridVisible: Boolean(effectiveMapLayer == null ? void 0 : effectiveMapLayer.showGrid),
817
817
  onToggleMapGrid: isFloorMapView ? toggleDraftCanvasShowGrid : void 0,
818
818
  viewportLocked,
819
- onToggleViewportLock: isFloorMapView && viewportPersistKey ? toggleViewportLocked : void 0,
819
+ onToggleViewportLock: isFloorMapView ? toggleViewportLocked : void 0,
820
820
  dockChrome: isFloorMapView,
821
821
  dockExpandedTrailing: viewportDockTrailing,
822
822
  autoCollapseDockMs: 1e4
@@ -131,7 +131,7 @@ function ViewControls(props) {
131
131
  {
132
132
  type: "button",
133
133
  className: (0, import_classnames.default)(`${PREFIX}-view-controls-tool-btn`, {
134
- [`${PREFIX}-view-controls-tool-btn--active`]: fitBoundsActive && !viewportLocked
134
+ [`${PREFIX}-view-controls-tool-btn--active`]: fitBoundsActive
135
135
  }),
136
136
  onClick: () => api.fitBounds(),
137
137
  disabled: viewportLocked,
@@ -265,7 +265,7 @@ function ViewControls(props) {
265
265
  `${PREFIX}-view-controls-tool-btn`,
266
266
  `${PREFIX}-view-controls-dock-collapsed-extras-btn`,
267
267
  {
268
- [`${PREFIX}-view-controls-tool-btn--active`]: fitBoundsActive && !viewportLocked
268
+ [`${PREFIX}-view-controls-tool-btn--active`]: fitBoundsActive
269
269
  }
270
270
  ),
271
271
  onClick: () => api.fitBounds(),
@@ -116,7 +116,7 @@ export interface FloorMapControlsConfig {
116
116
  showGridToggle?: boolean;
117
117
  /**
118
118
  * 是否显示「视口锁定」按钮:锁定后画布的位置 / 缩放不允许通过任何用户交互(拖拽、滚轮、触摸缩放、缩放按钮、适配视口)改变,
119
- * 防止误触改变视图。默认 false;平面图模式(启用了视口持久化时)由 PisellFloorMapLayout 默认置 true
119
+ * 防止误触改变视图。默认 false;平面图模式下由 PisellFloorMapLayout 默认置 true(与是否持久化视口到本地无关)。显式传 false 可隐藏。
120
120
  */
121
121
  showViewportLock?: boolean;
122
122
  /**
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import IpadModal from './IpadModal';
3
2
  import MobileModal from './MobileModal';
4
3
  import PcModal from './PcModal';
@@ -1,7 +1,7 @@
1
1
  import { type CalendarBookingSegmentInput } from './bookingCalendarDateUtils';
2
2
  export declare function getDrawerStatusTheme(item: CalendarBookingSegmentInput, dateKey: string): "bg-red-700/88 border-b-4 border-red-300/55" | "bg-zinc-700/88 border-b-4 border-zinc-400/45" | "bg-zinc-700/88 border-b-4 border-red-400/75" | "bg-violet-700/92 border-b-4 border-amber-400/95" | "bg-violet-700/92 border-b-4 border-zinc-300/45" | "bg-violet-700/92 border-b-4 border-violet-300/30";
3
3
  export declare function paymentTagClass(label: string, isLight?: boolean): "theme-success-chip border" | "bg-emerald-500 text-white" | "theme-warning-chip border" | "bg-amber-500 text-white" | "theme-info-chip border" | "bg-sky-500 text-white" | "theme-danger-chip border" | "bg-red-500 text-white";
4
- export declare function fulfillmentTagClass(label: string, isLight?: boolean): "theme-success-chip border" | "theme-warning-chip border" | "bg-amber-500 text-white" | "theme-info-chip border" | "theme-danger-chip border" | "bg-emerald-600 text-white" | "bg-cyan-500 text-white" | "bg-red-600 text-white" | "border border-[var(--border-strong)] bg-[var(--bg-input)] theme-text-soft" | "bg-zinc-600 text-white" | "border border-[var(--brand-light)] bg-[var(--brand-surface)] theme-brand-text" | "bg-violet-600 text-white";
4
+ export declare function fulfillmentTagClass(label: string, isLight?: boolean): "bg-violet-600 text-white" | "theme-success-chip border" | "theme-warning-chip border" | "bg-amber-500 text-white" | "theme-info-chip border" | "theme-danger-chip border" | "bg-emerald-600 text-white" | "bg-cyan-500 text-white" | "bg-red-600 text-white" | "border border-[var(--border-strong)] bg-[var(--bg-input)] theme-text-soft" | "bg-zinc-600 text-white" | "border border-[var(--brand-light)] bg-[var(--brand-surface)] theme-brand-text";
5
5
  export declare function getBookingStateClasses(item: CalendarBookingSegmentInput, dateKey: string): "bg-red-700/70 text-red-100" | "bg-violet-700/90 text-violet-50" | "bg-zinc-700/55 border border-zinc-500/70 text-zinc-100 grayscale-[0.2]" | "bg-zinc-700/55 border border-red-500/70 text-zinc-200 grayscale-[0.15]" | "bg-violet-700/90 border border-amber-400/80 text-violet-50";
6
6
  /**
7
7
  * 月 / 周紧凑格:不按签到/取消/迟到等状态变色,仅区分 booking(默认紫)与 block(红)。
@@ -17,4 +17,4 @@ export declare const minusSign: (item: any, type?: string) => "" | "-";
17
17
  * @Author: WangHan
18
18
  * @Date: 2024-11-22 10:58
19
19
  */
20
- export declare const _formatAmount: (price?: number, amountSymbol?: string, digit?: number) => string | number;
20
+ export declare const _formatAmount: (price?: number, amountSymbol?: string, digit?: number) => any;
@@ -17,4 +17,4 @@ export declare const minusSign: (item: any, type?: string) => "" | "-";
17
17
  * @Author: WangHan
18
18
  * @Date: 2024-11-22 10:58
19
19
  */
20
- export declare const _formatAmount: (price?: number, amountSymbol?: string, digit?: number) => string | number;
20
+ export declare const _formatAmount: (price?: number, amountSymbol?: string, digit?: number) => any;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import filter from "./filterUtil";
3
2
  declare const _default: {
4
3
  field: {
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: {
3
2
  field: {
4
3
  field_icon: string;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  export declare const fieldMaps: {
3
2
  text: {
4
3
  field: {
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: {
3
2
  field: {
4
3
  field_icon: string;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import filter from "./filterUtil";
3
2
  declare const _default: {
4
3
  field: {
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import filter from "./filterUtil";
3
2
  declare const _default: {
4
3
  field: {
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import filter from "./filterUtil";
3
2
  declare const _default: {
4
3
  field: {
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: {
3
2
  field: {
4
3
  field_icon: string;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import filter from "./filterUtil";
3
2
  declare const _default: {
4
3
  field: {
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import filter from "./filterUtil";
3
2
  declare const _default: {
4
3
  field: {
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import filter from "./filterUtil";
3
2
  declare const _default: {
4
3
  field: {
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import filter from "./filterUtil";
3
2
  declare const _default: {
4
3
  field: {
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import filter from "./filterUtil";
3
2
  declare const _default: {
4
3
  field: {
@@ -155,7 +155,7 @@ export declare const getSettingKeyArrByMode: ({ filter, columnSetting, dataSourc
155
155
  sort?: SortType | undefined;
156
156
  mode: "" | "localStorage" | "remote";
157
157
  currentViewMode: ModeType;
158
- }) => ("filters" | "filter_setting" | "view_mode" | "group_by" | "order_by" | "column_setting" | "gallery_setting")[];
158
+ }) => ("column_setting" | "gallery_setting" | "order_by" | "group_by" | "filters" | "view_mode" | "filter_setting")[];
159
159
  export declare const omit: (obj: Record<string, any>, keys: string[]) => Record<string, any>;
160
160
  export declare const stringify: (obj: Record<string, any>) => string;
161
161
  export {};
@@ -385,6 +385,7 @@ declare const _default: {
385
385
  'pisell-record-view-unavailable': string;
386
386
  'pisell-data-source-form-required-message': string;
387
387
  'pisell-data-source-form-scope-message': string;
388
+ 'pisell-data-source-form-scene-request-id-message': string;
388
389
  'pisell-data-source-form-email-message': string;
389
390
  'pisell-data-source-form-domain-message': string;
390
391
  'pisell-data-source-form-url-message': string;
@@ -429,6 +429,7 @@ var en_US_default = {
429
429
  "pisell-record-view-unavailable": "No available",
430
430
  "pisell-data-source-form-required-message": "This field is required",
431
431
  "pisell-data-source-form-scope-message": "Scope not specified for settings in URL params",
432
+ "pisell-data-source-form-scene-request-id-message": "sceneRequestId is required for device settings",
432
433
  "pisell-data-source-form-email-message": "Please enter a valid email address",
433
434
  "pisell-data-source-form-domain-message": "Please enter a valid domain",
434
435
  "pisell-data-source-form-url-message": "Please enter a valid URL",