@steedos-widgets/amis-lib 3.6.2-beta.20 → 3.6.2-beta.21
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/cjs/tsconfig.tsbuildinfo +1 -1
- package/dist/index.cjs.js +42 -13
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +42 -13
- package/dist/index.esm.js.map +1 -1
- package/dist/index.umd.js +12 -10
- package/dist/index.umd.js.map +1 -1
- package/package.json +2 -2
package/dist/index.esm.js
CHANGED
|
@@ -2153,11 +2153,11 @@ async function getTableColumns(fields, options){
|
|
|
2153
2153
|
"expression": "!!!(window && window.nw && window.nw.require)"//浏览器上直接下载
|
|
2154
2154
|
},
|
|
2155
2155
|
{
|
|
2156
|
-
|
|
2157
|
-
|
|
2158
|
-
|
|
2159
|
-
|
|
2160
|
-
|
|
2156
|
+
"args": {},
|
|
2157
|
+
"actionType": "custom",
|
|
2158
|
+
"script": previewFileScript,
|
|
2159
|
+
// "expression": "!!window?.nw?.require" //PC客户端预览附件
|
|
2160
|
+
"expression": "!!(window && window.nw && window.nw.require)"//PC客户端预览附件
|
|
2161
2161
|
}
|
|
2162
2162
|
]
|
|
2163
2163
|
}
|
|
@@ -2437,10 +2437,10 @@ async function getMobileTableColumns(fields, options){
|
|
|
2437
2437
|
if(value.url){
|
|
2438
2438
|
cms_url = value.url;
|
|
2439
2439
|
}else{
|
|
2440
|
-
cms_url = "/api/files/files/"+value+"?download=true"
|
|
2440
|
+
cms_url = Steedos.absoluteUrl("/api/files/files/"+value+"?download=true");
|
|
2441
2441
|
}
|
|
2442
2442
|
}
|
|
2443
|
-
Steedos.cordovaDownload(encodeURI(
|
|
2443
|
+
Steedos.cordovaDownload(encodeURI(cms_url), event.data.name);
|
|
2444
2444
|
`,
|
|
2445
2445
|
"actionType": "custom"
|
|
2446
2446
|
}
|
|
@@ -9238,7 +9238,7 @@ async function getRecordDetailRelatedListSchema(objectName, recordId, relatedObj
|
|
|
9238
9238
|
setDataToComponentId: componentId,
|
|
9239
9239
|
// tableHiddenOn: hiddenEmptyTable ? "this.$count === 0" : null,
|
|
9240
9240
|
appId: appId,
|
|
9241
|
-
crudClassName: 'steedos-record-related-crud
|
|
9241
|
+
crudClassName: 'steedos-record-related-crud hidden',
|
|
9242
9242
|
refField,
|
|
9243
9243
|
...ctx
|
|
9244
9244
|
};
|
|
@@ -11171,13 +11171,15 @@ async function lookupToAmisPicker(field, readonly, ctx){
|
|
|
11171
11171
|
|
|
11172
11172
|
pickerSchema.affixHeader = false;
|
|
11173
11173
|
|
|
11174
|
-
|
|
11174
|
+
|
|
11175
|
+
|
|
11176
|
+
pickerSchema.headerToolbar = getObjectHeaderToolbar(refObjectConfig, fieldsArr, ctx.formFactor, { isLookup: true, keywordsSearchBoxName });
|
|
11177
|
+
|
|
11175
11178
|
if(referenceTo.objectName === "space_users" && field.reference_to_field === "user"){
|
|
11176
|
-
|
|
11179
|
+
pickerSchema.headerToolbar.push(getLookupSapceUserTreeSchema(isMobile));
|
|
11177
11180
|
pickerSchema.className = pickerSchema.className || "" + " steedos-select-user";
|
|
11178
11181
|
}
|
|
11179
|
-
|
|
11180
|
-
pickerSchema.headerToolbar = getObjectHeaderToolbar(refObjectConfig, fieldsArr, ctx.formFactor, { headerToolbarItems, isLookup: true, keywordsSearchBoxName });
|
|
11182
|
+
|
|
11181
11183
|
const isAllowCreate = refObjectConfig.permissions.allowCreate;
|
|
11182
11184
|
const isCreate = _$1.isBoolean(field.create) ? field.create : true;
|
|
11183
11185
|
// lookup字段配置过滤条件就强制不显示新建按钮
|
|
@@ -11290,6 +11292,16 @@ async function lookupToAmisPicker(field, readonly, ctx){
|
|
|
11290
11292
|
pickerSchema.footerToolbar = ["pagination"];
|
|
11291
11293
|
}
|
|
11292
11294
|
|
|
11295
|
+
if(field.inlineHelpText){
|
|
11296
|
+
pickerSchema.toolbarClassName = "hasHelpText";
|
|
11297
|
+
pickerSchema.headerToolbar = [{
|
|
11298
|
+
"type": "tpl",
|
|
11299
|
+
"tpl": field.inlineHelpText,
|
|
11300
|
+
"className": "text-secondary"
|
|
11301
|
+
}, ...pickerSchema.headerToolbar];
|
|
11302
|
+
}
|
|
11303
|
+
pickerSchema.className = (pickerSchema.className || "") + " steedos-lookup-crud";
|
|
11304
|
+
|
|
11293
11305
|
const data = {
|
|
11294
11306
|
type: getAmisStaticFieldType('picker', readonly),
|
|
11295
11307
|
modalTitle: i18next.t('frontend_form_please_select') + " " + refObjectConfig.label,
|
|
@@ -13368,7 +13380,23 @@ async function getInputTableColumns(props) {
|
|
|
13368
13380
|
let mode = typeof extendColumnProps.inlineEditMode === "boolean" ?
|
|
13369
13381
|
extendColumnProps.inlineEditMode : showAsInlineEditMode;
|
|
13370
13382
|
let tableCell = getInputTableCell(field, mode);
|
|
13371
|
-
|
|
13383
|
+
let className = "";
|
|
13384
|
+
//判断是否换行,目前规则默认换行
|
|
13385
|
+
if(extendColumnProps.wrap != true){
|
|
13386
|
+
className += " whitespace-nowrap ";
|
|
13387
|
+
}else {
|
|
13388
|
+
className += " break-words ";
|
|
13389
|
+
}
|
|
13390
|
+
//合并classname
|
|
13391
|
+
if (typeof extendColumnProps.className == "object") {
|
|
13392
|
+
className = {
|
|
13393
|
+
[className]: "true",
|
|
13394
|
+
...extendColumnProps.className
|
|
13395
|
+
};
|
|
13396
|
+
} else if (typeof extendColumnProps.className == "string") {
|
|
13397
|
+
className = `${className} ${extendColumnProps.className} `;
|
|
13398
|
+
}
|
|
13399
|
+
return Object.assign({}, tableCell, extendColumnProps, {className});
|
|
13372
13400
|
}
|
|
13373
13401
|
else {
|
|
13374
13402
|
return column;
|
|
@@ -13378,6 +13406,7 @@ async function getInputTableColumns(props) {
|
|
|
13378
13406
|
else {
|
|
13379
13407
|
return fields.map(function (field) {
|
|
13380
13408
|
let tableCell = getInputTableCell(field, showAsInlineEditMode);
|
|
13409
|
+
tableCell.className = " whitespace-nowrap ";
|
|
13381
13410
|
return tableCell;
|
|
13382
13411
|
}) || [];
|
|
13383
13412
|
}
|