@ibiz-template/runtime 0.7.28 → 0.7.29-alpha.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.esm.js CHANGED
@@ -25959,7 +25959,7 @@ var CustomDashboardController = class {
25959
25959
  */
25960
25960
  this.portletConfig = {};
25961
25961
  /**
25962
- * 自定义定制范围类型(public:公开,personal:个人,data:数据,dynamic: 自定义动态,默认是按照个人区分,配置了应用功能组件才生效)
25962
+ * 自定义定制范围类型(public:公开,personal:个人,data:数据,默认是按照个人区分,配置了应用功能组件才生效)
25963
25963
  *
25964
25964
  * @author tony001
25965
25965
  * @date 2024-04-24 19:04:47
@@ -25982,6 +25982,22 @@ var CustomDashboardController = class {
25982
25982
  * @type {string}
25983
25983
  */
25984
25984
  this.ownerId = "";
25985
+ /**
25986
+ * 多数据模式,启用时请求参数从上下文中获取srfdynadashboardid的值
25987
+ *
25988
+ * @author tony001
25989
+ * @date 2024-07-08 14:07:51
25990
+ * @type {boolean}
25991
+ */
25992
+ this.multiMode = false;
25993
+ /**
25994
+ * 展示设计按钮,启用定制默认会展示
25995
+ *
25996
+ * @author tony001
25997
+ * @date 2024-07-08 14:07:15
25998
+ * @type {boolean}
25999
+ */
26000
+ this.showDesignBtn = true;
25985
26001
  this.context = dashboard.context;
25986
26002
  this.params = dashboard.params;
25987
26003
  this.init(dashboard.controlParams);
@@ -26007,7 +26023,10 @@ var CustomDashboardController = class {
26007
26023
  this.ownerId = this.context[controlParams.owner_id];
26008
26024
  }
26009
26025
  if (controlParams.multimode === "true") {
26010
- this.type = "dynamic";
26026
+ this.multiMode = true;
26027
+ }
26028
+ if (controlParams.showdesignbtn === "false") {
26029
+ this.showDesignBtn = false;
26011
26030
  }
26012
26031
  if (this.model.appDynaDashboardUtilId) {
26013
26032
  const app = ibiz.hub.getApp(this.context.srfappid);
@@ -26032,14 +26051,15 @@ var CustomDashboardController = class {
26032
26051
  */
26033
26052
  getResourceTag() {
26034
26053
  var _a, _b;
26054
+ if (this.multiMode) {
26055
+ return this.context.srfdynadashboardid;
26056
+ }
26035
26057
  const base = "".concat(this.context.srfappid, "_dashboard_").concat(((_a = this.model.appDataEntityId) == null ? void 0 : _a.toLowerCase()) || "app", "_").concat((_b = this.model.codeName) == null ? void 0 : _b.toLowerCase());
26036
26058
  switch (this.type) {
26037
26059
  case "personal":
26038
26060
  return "".concat(base, "_").concat(this.context.srfpersonid);
26039
26061
  case "data":
26040
26062
  return "".concat(base, "_").concat(this.ownerType, "_").concat(this.ownerId);
26041
- case "dynamic":
26042
- return "".concat(this.context.srfdynadashboardid);
26043
26063
  default:
26044
26064
  return base;
26045
26065
  }
@@ -26051,6 +26071,9 @@ var CustomDashboardController = class {
26051
26071
  * @Date: 2023-09-20 16:22:49
26052
26072
  */
26053
26073
  async loadCustomModelData() {
26074
+ if (this.multiMode && !this.context.srfdynadashboardid) {
26075
+ return { model: this.customModelData, config: this.portletConfig };
26076
+ }
26054
26077
  let res;
26055
26078
  if (this.util) {
26056
26079
  res = await this.util.load(