@steedos-widgets/amis-lib 6.10.28 → 6.10.30

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
@@ -2412,7 +2412,7 @@ async function getMobileTableColumns(fields, options){
2412
2412
  link: url,
2413
2413
  innerClassName: {
2414
2414
  "steedos-listview-item block text-gray-500":"true",
2415
- "max-w-[360px]": "${display == 'split'}",
2415
+ "w-full": "${display == 'split'}",
2416
2416
  },
2417
2417
  body: {
2418
2418
  "type": "wrapper",
@@ -6609,7 +6609,7 @@ async function getObjectFieldsFilterBarSchema(objectSchema, ctx) {
6609
6609
  "className": "slds-filters__footer slds-grid slds-shrink-none flex justify-between p-0"
6610
6610
  }],
6611
6611
  "size": "xs",
6612
- "className": "slds-filters px-0"
6612
+ "className": "slds-filters px-3"
6613
6613
  },
6614
6614
  "size": "xs",
6615
6615
  "className": `p-0`,
@@ -9109,12 +9109,12 @@ function getObjectHeaderToolbar(mainObject, fields, formFactor, {
9109
9109
  // if(toolbarCount){
9110
9110
  // toolbars.push(toolbarCount);
9111
9111
  // }
9112
- toolbars.push(toolbarReloadButton);
9113
- toolbars.push(toolbarDQuickSearchBox);
9114
9112
  if(toolbarFilter){
9115
9113
  toolbars.push(toolbarFilter);
9116
9114
  }
9115
+ toolbars.push(toolbarReloadButton);
9117
9116
  toolbars.push(toolbarDisplayAsButton);
9117
+ toolbars.push(toolbarDQuickSearchBox);
9118
9118
  return [
9119
9119
  // "bulkActions",
9120
9120
  ...(headerToolbarItems || []),
@@ -9429,7 +9429,7 @@ async function getObjectCRUD(objectSchema, fields, options){
9429
9429
  const bodyProps = {
9430
9430
  // toolbar: getToolbar(),
9431
9431
  // headerToolbar: getObjectHeaderToolbar(objectSchema, options.formFactor, {showDisplayAs}),
9432
- headerToolbarClassName: "px-0 py-2 border-b",
9432
+ headerToolbarClassName: "px-3 py-2 border-b",
9433
9433
  footerToolbar: getObjectFooterToolbar(objectSchema, options.formFactor, {
9434
9434
  ...options,
9435
9435
  disableStatistics: options.queryCount === false
@@ -10421,7 +10421,7 @@ async function getObjectRelatedListsMiniSchema(objectApiName){
10421
10421
  * @Author: baozhoutao@steedos.com
10422
10422
  * @Date: 2022-07-05 15:55:39
10423
10423
  * @LastEditors: 殷亮辉 yinlianghui@hotoa.com
10424
- * @LastEditTime: 2025-12-04 14:03:00
10424
+ * @LastEditTime: 2025-12-04 23:20:29
10425
10425
  * @Description:
10426
10426
  */
10427
10427
 
@@ -10707,6 +10707,10 @@ async function getViewSchema(objectName, recordId, ctx) {
10707
10707
 
10708
10708
  function isListViewSupported(listView) {
10709
10709
  if(listView.type === "calendar" || listView.type === "timeline"){
10710
+ var isEnterprise = window.Builder?.settings.platform && ["platform-standard", "platform-enterprise", "platform-professional"].includes(window.Builder.settings.platform.product);
10711
+ if (!isEnterprise) {
10712
+ return false;
10713
+ }
10710
10714
  return listView.type === "timeline" ? (!!window.BuilderFullCalendarScheduler) : (!!window.BuilderFullCalendar || !!window.BuilderFullCalendarScheduler);
10711
10715
  }
10712
10716
  return true;
@@ -14553,7 +14557,7 @@ function uuidv4() {
14553
14557
  * @Author: 殷亮辉 yinlianghui@hotoa.com
14554
14558
  * @Date: 2023-11-15 09:50:22
14555
14559
  * @LastEditors: 殷亮辉 yinlianghui@hotoa.com
14556
- * @LastEditTime: 2025-09-01 15:40:28
14560
+ * @LastEditTime: 2025-12-04 22:52:15
14557
14561
  */
14558
14562
 
14559
14563
  /**
@@ -16154,10 +16158,11 @@ const getAmisInputTableSchema = async (props) => {
16154
16158
  "visible": props.$schema.visible,
16155
16159
  "hiddenOn": props.$schema.hiddenOn,
16156
16160
  "hidden": props.$schema.hidden,
16161
+ "requiredOn": props.$schema.requiredOn,
16157
16162
  "required": props.required,
16158
16163
  className,
16159
16164
  };
16160
- // console.log("===schema===", schema);
16165
+ // console.log("=inputtable==schema===", schema);
16161
16166
  return schema;
16162
16167
  };
16163
16168
 
@@ -17595,7 +17600,7 @@ const getApprovalDrawerSchema = async (instance, events) => {
17595
17600
  bodyClassName: 'p-2',
17596
17601
  footerClassName: 'p-2 pt-0',
17597
17602
  drawerContainer: ()=>{
17598
- return document.body;
17603
+ return document.querySelector(".steedos-amis-instance-view");//document.body;
17599
17604
  },
17600
17605
  body: [
17601
17606
  {
@@ -17693,6 +17698,21 @@ const getApprovalDrawerSchema = async (instance, events) => {
17693
17698
  ],
17694
17699
  id: "u:approve_8861156e0b23",
17695
17700
  position: "bottom",
17701
+ "onEvent": {
17702
+ "cancel": {
17703
+ "actions": [
17704
+ {
17705
+ "actionType": "custom",
17706
+ "script": (context, doAction, event)=>{
17707
+ var instancePageContent = document.querySelector(".steedos-amis-instance-view .antd-Page-content");
17708
+ if (instancePageContent){
17709
+ $(instancePageContent).css("paddingBottom", "0px");
17710
+ }
17711
+ }
17712
+ }
17713
+ ]
17714
+ }
17715
+ },
17696
17716
  actions: [
17697
17717
  {
17698
17718
  type: "button",
@@ -17963,8 +17983,8 @@ const getInstanceApprovalHistory = async ()=>{
17963
17983
  /*
17964
17984
  * @Author: baozhoutao@steedos.com
17965
17985
  * @Date: 2022-09-07 16:20:45
17966
- * @LastEditors: 殷亮辉 yinlianghui@hotoa.com
17967
- * @LastEditTime: 2025-12-04 13:47:10
17986
+ * @LastEditors: yinlianghui yinlianghui@hotoa.com
17987
+ * @LastEditTime: 2025-12-09 15:28:25
17968
17988
  * @Description:
17969
17989
  */
17970
17990
 
@@ -18900,6 +18920,23 @@ const getApproveButton = async (instance, events)=>{
18900
18920
  actionType: "drawer",
18901
18921
  drawer: await getApprovalDrawerSchema(instance, events),
18902
18922
  },
18923
+ {
18924
+ "actionType": "wait",
18925
+ "args": {
18926
+ "time": 1000 //延时等底部签批栏drawer弹出再执行下面的添加审批单内部底边距脚本,不等的话拿不到drawer高度
18927
+ }
18928
+ },
18929
+ {
18930
+ "actionType": "custom",
18931
+ "script": (context, doAction, event) => {
18932
+ // 每次点开底部签批栏添加审批单内部底边距以解决签批栏会挡住申请单内容的问题
18933
+ var instancePageContent = document.querySelector(".steedos-amis-instance-view .antd-Page-content");
18934
+ var approvalDrawerContent = document.querySelector(".approval-drawer .antd-Drawer-content");
18935
+ if (instancePageContent && approvalDrawerContent) {
18936
+ $(instancePageContent).css("paddingBottom", `${approvalDrawerContent.clientHeight + 10}px`);
18937
+ }
18938
+ }
18939
+ }
18903
18940
  ],
18904
18941
  },
18905
18942
  },
@@ -19008,7 +19045,7 @@ const getFlowFormSchema = async (instance, box) => {
19008
19045
  "recordId": instance._id,
19009
19046
  "id": "u:e6b2adbe0e21",
19010
19047
  "showRecordTitle": false,
19011
- "className": "p-0 m-0 p0 m0 bg-gray-50 sm:rounded-tl sm:rounded-tr"
19048
+ "className": "sm:rounded-tl sm:rounded-tr"
19012
19049
  },
19013
19050
  "css": {
19014
19051
  ".steedos-amis-instance-view-body": {
@@ -19026,8 +19063,8 @@ const getFlowFormSchema = async (instance, box) => {
19026
19063
  "font-size": "14px",
19027
19064
  "font-weight": "500"
19028
19065
  },
19029
- ".steedos-object-record-detail-header .antd-Grid-col--mdAuto": {
19030
- "padding": "0px !important"
19066
+ ".steedos-amis-instance-view.steedos-instance-style-table .antd-Page-body": {
19067
+ "width": "1024px"
19031
19068
  },
19032
19069
  ".antd-List-placeholder": {
19033
19070
  "display": "none"