Skip to content

Commit

Permalink
No commit message
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] authored May 14, 2024
2 parents 5005ca3 + 6c56be3 commit 5c7ec0e
Show file tree
Hide file tree
Showing 17 changed files with 95 additions and 37 deletions.
2 changes: 1 addition & 1 deletion apps/experience/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@steedos/ee_experience",
"version": "3.6.13",
"version": "3.6.14",
"main": "package.service.js",
"private": true,
"publishConfig": {
Expand Down
2 changes: 1 addition & 1 deletion apps/storybook/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "storybook",
"version": "3.6.13",
"version": "3.6.14",
"main": "index.js",
"private": true,
"license": "MIT",
Expand Down
2 changes: 1 addition & 1 deletion lerna.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,5 +21,5 @@
"registry": "https://registry.npmjs.org/"
}
},
"version": "3.6.13"
"version": "3.6.14"
}
4 changes: 2 additions & 2 deletions packages/@steedos-widgets/ag-grid/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@steedos-widgets/ag-grid",
"private": false,
"version": "3.6.13",
"version": "3.6.14",
"main": "dist/ag-grid.cjs.js",
"module": "dist/ag-grid.esm.js",
"unpkg": "dist/ag-grid.umd.js",
Expand Down Expand Up @@ -49,7 +49,7 @@
},
"dependencies": {
"@rollup/plugin-replace": "^5.0.2",
"@steedos-widgets/amis-lib": "3.6.13",
"@steedos-widgets/amis-lib": "3.6.14",
"ag-grid-community": "~31.0.2",
"ag-grid-enterprise": "~31.0.2",
"ag-grid-react": "~31.0.2"
Expand Down
2 changes: 1 addition & 1 deletion packages/@steedos-widgets/amis-lib/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@steedos-widgets/amis-lib",
"private": false,
"version": "3.6.13",
"version": "3.6.14",
"unpkg": "./dist/index.umd.js",
"main": "./dist/index.cjs.js",
"module": "./dist/index.esm.js",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -342,6 +342,6 @@ export function getApi (isMobile){
//TODO 返回 绝对路径
}else{
// return __meteor_runtime_config__.ROOT_URL_PATH_PREFIX + "/graphql"
return `\${context.rootUrl}/graphql?reload=\${additionalFilters}`
return `\${context.rootUrl}/graphql?reload=\${additionalFilters|join}`
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,10 @@ function getObjectHeaderQuickSearchBox(mainObject, fields, formFactor, { isLooku
// const scope = event.context.scoped;
// 如果点击过顶部搜索栏表单的取消按钮,会把此处event.data.__super.__super.__super中的搜索表单项的所有字段设置为null
// 点击取消按钮后继续在表单项中输入过滤条件且最后没有点击回车按键或点击表单项搜索按钮的话,在快速搜索中点击回车按钮提交搜索会所顶部搜索表单中的字段值清空
let filterForm = SteedosUI.getClosestAmisComponentByType(scope, "form");
if(!filterForm){
return;
}
let isLookup = event.data.isLookup;
let __lookupField = event.data.__lookupField;
let __changedFilterFormValuesKey = "__changedFilterFormValues";
Expand All @@ -143,9 +147,8 @@ function getObjectHeaderQuickSearchBox(mainObject, fields, formFactor, { isLooku
}
__changedFilterFormValuesKey += lookupTag;
}
let filterForm = SteedosUI.getClosestAmisComponentByType(scope, "form");
setTimeout(function(){
filterForm.setValues(event.data[__changedFilterFormValuesKey]);
filterForm && filterForm.setValues(event.data[__changedFilterFormValuesKey]);
}, 500);
`;

Expand Down
4 changes: 2 additions & 2 deletions packages/@steedos-widgets/amis-object/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@steedos-widgets/amis-object",
"private": false,
"version": "3.6.13",
"version": "3.6.14",
"main": "dist/amis-object.cjs.js",
"module": "dist/amis-object.esm.js",
"unpkg": "dist/amis-object.umd.js",
Expand Down Expand Up @@ -61,7 +61,7 @@
"uglify-js": "^3.17.0"
},
"dependencies": {
"@steedos-widgets/amis-lib": "3.6.13",
"@steedos-widgets/amis-lib": "3.6.14",
"autoprefixer": "^10.4.13",
"postcss": "^8.4.19",
"tailwindcss": "^3.2.4"
Expand Down
65 changes: 57 additions & 8 deletions packages/@steedos-widgets/amis-object/src/amis/AmisAppLauncher.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
/*
* @Author: [email protected]
* @Date: 2022-09-01 14:44:57
* @LastEditors: baozhoutao@steedos.com
* @LastEditTime: 2024-03-30 10:06:03
* @LastEditors: 殷亮辉 yinlianghui@hotoa.com
* @LastEditTime: 2024-05-14 13:30:24
* @Description:
*/

Expand All @@ -25,14 +25,61 @@ export const AmisAppLauncher = async (props) => {
console.error("catch some error when eval the on_click script for app link:");
console.error(e.message + "\\r\\n" + e.stack);
}
`
`;
const mobile_blank_script = `
if(event.data.path[0] == "/"){
Steedos.openWindow(event.data.context.rootUrl + event.data.path)
}else{
Steedos.openWindow(event.data.path)
}
`
`;

const convertAppVisibleOnScript = `
var currentAmis = amisRequire('amis');
app_items.forEach((item) => {
let visible_on = item.visible_on && item.visible_on.trim();
if(visible_on){
// amis visibleOn属性中的表达式来自作用域中变量时,amis不认,所以这里把公式表达式提前运行下
try{
visible_on = currentAmis.evaluate(visible_on, BuilderAmisObject.AmisLib.createObject(context, item));
item.visible_on = visible_on;
}
catch(ex){
console.error("运行应用“" + item.name + "”的显示公式表达式时出现错误:",ex);
item.visible_on = false;
}
}
});
`;

const pcInitApiAdaptorScript = `
let app_items = payload;
let object_items = [];
let objects = [];
app_items.forEach((item) => {
item.children.forEach((i) => {
if (objects.indexOf(i.id) < 0) {
objects.push(i.id);
if(i.type != 'url' && i.type != 'page'){object_items.push(i);}
}
})
})
${convertAppVisibleOnScript}
payload = {
app_items,
object_items
}
return payload;
`;
const mobileInitApiAdaptorScript = `
let app_items = payload;
${convertAppVisibleOnScript}
payload = {
app_items
}
return payload;
`;

let dialogSchema = {}
const badgeText = "${IF(${id} == 'approve_workflow',${ss:keyvalues.badge.value|pick:'workflow'},${ss:keyvalues.badge.value|pick:${id}}) | toInt}";
if(isMobile){
Expand Down Expand Up @@ -93,6 +140,7 @@ export const AmisAppLauncher = async (props) => {
]
}
},
"visibleOn": "${visible_on}",
"className": "block w-1/3 py-4",
"style": {
"display": "inline-flex",
Expand All @@ -113,7 +161,7 @@ export const AmisAppLauncher = async (props) => {
"headers": {
"Authorization": "Bearer ${context.tenantId},${context.authToken}"
},
"adaptor": "\nlet app_items = payload;\npayload = {\n app_items\n}\nreturn payload;",
"adaptor": mobileInitApiAdaptorScript,
"messages": {
}
},
Expand Down Expand Up @@ -162,7 +210,7 @@ export const AmisAppLauncher = async (props) => {
{
"type": "each",
"name": "app_items",
"items": {
"items": [{
"type": "button",
"level": "link",
"body": [{
Expand Down Expand Up @@ -218,8 +266,9 @@ export const AmisAppLauncher = async (props) => {
"inline": true,
"style": {
},
"visibleOn": "${visible_on}",
"className": "slds-p-horizontal_small slds-size_1-of-1 slds-medium-size_1-of-3"
},
}],
"className": "slds-grid slds-wrap slds-grid_pull-padded"
}
]
Expand Down Expand Up @@ -311,7 +360,7 @@ export const AmisAppLauncher = async (props) => {
"headers": {
"Authorization": "Bearer ${context.tenantId},${context.authToken}"
},
"adaptor": "\nlet app_items = payload;\nlet object_items = [];\nlet objects = [];\napp_items.forEach((item) => {\n item.children.forEach((i) => {\n if (objects.indexOf(i.id) < 0) {\n objects.push(i.id);\n if(i.type != 'url' && i.type != 'page'){object_items.push(i);}\n }\n })\n})\npayload = {\n app_items,\n object_items\n}\nreturn payload;"
"adaptor": pcInitApiAdaptorScript
}
}
}
Expand Down
18 changes: 12 additions & 6 deletions packages/@steedos-widgets/amis-object/src/amis/AmisObjectForm.less
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,6 @@
}
}

.antd-Collapse {
.antd-Collapse-header.hidden {
display: none !important;
}
}

.antd-Tabs-pane.is-active {
display: grid;
grid-template-columns: repeat(2, minmax(0, 1fr));
Expand Down Expand Up @@ -75,6 +69,15 @@

}

.steedos-object-form {
.antd-Collapse {
//只有一个分组时隐藏分组名称
.antd-Collapse-header.hidden {
display: none !important;
}
}
}

// html 控件只读状态下不要显示边框 https://github.com/steedos/steedos-widgets/issues/488
.steedos-object-form .steedos-input-rich-text-readonly .antd-RichTextControl{
border: 0;
Expand All @@ -85,5 +88,8 @@
.antd-Form-item .antd-Form-label + .antd-Form-item-controlBox{
max-width: unset;
}
.antd-Collapse::before{
content: unset;
}
}
}
4 changes: 2 additions & 2 deletions packages/@steedos-widgets/ckeditor/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@steedos-widgets/ckeditor",
"private": false,
"version": "3.6.13",
"version": "3.6.14",
"main": "dist/ckeditor.cjs.js",
"module": "dist/ckeditor.esm.js",
"unpkg": "dist/ckeditor.umd.js",
Expand Down Expand Up @@ -55,7 +55,7 @@
"@ckeditor/ckeditor5-react": "~6.2.0",
"@ckeditor/ckeditor5-theme-lark": "^41.2.1",
"@rollup/plugin-replace": "^5.0.2",
"@steedos-widgets/amis-lib": "3.6.13",
"@steedos-widgets/amis-lib": "3.6.14",
"rollup-plugin-string": "^3.0.0"
},
"gitHead": "ffb730e16642eb8e7a7ae5d98d0773c42482e7d2"
Expand Down
4 changes: 2 additions & 2 deletions packages/@steedos-widgets/devextreme/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@steedos-widgets/devextreme",
"private": false,
"version": "3.6.13",
"version": "3.6.14",
"main": "dist/devextreme.cjs.js",
"module": "dist/devextreme.esm.js",
"unpkg": "dist/devextreme.umd.js",
Expand Down Expand Up @@ -49,7 +49,7 @@
},
"dependencies": {
"@rollup/plugin-replace": "^5.0.2",
"@steedos-widgets/amis-lib": "3.6.13",
"@steedos-widgets/amis-lib": "3.6.14",
"devextreme": "^23.2.3",
"devextreme-react": "^23.2.3",
"rollup-plugin-copy": "^3.5.0"
Expand Down
2 changes: 1 addition & 1 deletion packages/@steedos-widgets/example/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@steedos-widgets/example",
"private": true,
"version": "3.6.13",
"version": "3.6.14",
"main": "dist/meta.js",
"module": "dist/meta.js",
"unpkg": "dist/meta.js",
Expand Down
4 changes: 2 additions & 2 deletions packages/@steedos-widgets/fullcalendar/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@steedos-widgets/fullcalendar",
"private": false,
"version": "3.6.13",
"version": "3.6.14",
"main": "dist/fullcalendar.cjs.js",
"module": "dist/fullcalendar.esm.js",
"unpkg": "dist/fullcalendar.umd.js",
Expand Down Expand Up @@ -54,7 +54,7 @@
"@fullcalendar/list": "5.11.4",
"@fullcalendar/react": "5.11.4",
"@fullcalendar/timegrid": "5.11.4",
"@steedos-widgets/amis-lib": "3.6.13"
"@steedos-widgets/amis-lib": "3.6.14"
},
"gitHead": "ffb730e16642eb8e7a7ae5d98d0773c42482e7d2"
}
4 changes: 2 additions & 2 deletions packages/@steedos-widgets/reactflow/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@steedos-widgets/reactflow",
"private": false,
"version": "3.6.13",
"version": "3.6.14",
"main": "dist/reactflow.cjs.js",
"module": "dist/reactflow.esm.js",
"unpkg": "dist/reactflow.umd.js",
Expand Down Expand Up @@ -49,7 +49,7 @@
},
"dependencies": {
"@rollup/plugin-replace": "^5.0.2",
"@steedos-widgets/amis-lib": "3.6.13",
"@steedos-widgets/amis-lib": "3.6.14",
"reactflow": "^11.5.6"
},
"gitHead": "ffb730e16642eb8e7a7ae5d98d0773c42482e7d2"
Expand Down
4 changes: 2 additions & 2 deletions packages/@steedos-widgets/sortable/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@steedos-widgets/sortable",
"version": "3.6.13",
"version": "3.6.14",
"main": "dist/sortable.cjs.js",
"module": "dist/sortable.esm.js",
"unpkg": "dist/sortable.umd.js",
Expand Down Expand Up @@ -45,7 +45,7 @@
"dependencies": {
"@dnd-kit/core": "^6.0.5",
"@dnd-kit/sortable": "^7.0.1",
"@steedos-widgets/amis-lib": "3.6.13"
"@steedos-widgets/amis-lib": "3.6.14"
},
"gitHead": "ffb730e16642eb8e7a7ae5d98d0773c42482e7d2"
}
2 changes: 1 addition & 1 deletion packages/@steedos-widgets/steedos-lib/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@steedos-widgets/steedos-lib",
"private": false,
"version": "3.6.13",
"version": "3.6.14",
"unpkg": "./dist/index.umd.js",
"main": "./dist/index.cjs.js",
"module": "./dist/index.esm.js",
Expand Down

0 comments on commit 5c7ec0e

Please sign in to comment.