Commit Graph

829 Commits

Author SHA1 Message Date
Trisha Anand
4337e88934 Application and page can only be deleted if you have manage application/page permissions respectively. 2020-06-18 15:35:30 +05:30
Arpit Mohan
69dd082cf6 Merge branch 'bug/acl-invite-not-null-assertion' into 'release'
Invite User to Organisation : Throw a bad request error in case all the invite dto fields are not set.

See merge request theappsmith/internal-tools-server!393
2020-06-18 08:45:51 +00:00
Trisha Anand
ec8c63bfee For invitation, throw a bad request error in case all the invite dto fields are not set. 2020-06-18 14:05:48 +05:30
Arpit Mohan
f44c979e49 Merge branch 'bug/page-edit-without-perm' into 'release'
In case a page is opened in edit mode, it should open with permission of MANAGE_PAGE. In case the user is a viewer, the page must not open.

See merge request theappsmith/internal-tools-server!392
2020-06-17 12:11:32 +00:00
Trisha Anand
e5282dac11 In case a page is opened in edit mode, it should open with permission of MANAGE_PAGE. In case the user is a viewer, the page must not open. 2020-06-17 17:34:26 +05:30
Trisha Anand
e9086c15b5 Merge branch 'feature/acl-spring-object' into 'release'
ACL

See merge request theappsmith/internal-tools-server!383
2020-06-17 09:51:57 +00:00
Trisha Anand
893698f09e Merge branch 'release' into feature/acl-spring-object
# Conflicts:
#	appsmith-server/src/main/java/com/appsmith/server/constants/FieldName.java
2020-06-17 15:10:23 +05:30
Arpit Mohan
decdde179c Merge branch 'bug/acl-invite-admin-admin' into 'feature/acl-spring-object'
In case a user is invited to an organization as developer, correct top...

See merge request theappsmith/internal-tools-server!391
2020-06-17 09:33:01 +00:00
Trisha Anand
8fc99cf0bd In case a user is invited to an organization as developer, correct top permissions are being assigned via Appsmith role. 2020-06-17 09:33:00 +00:00
Arpit Mohan
c6af229a97 Merge branch 'bug/default-page-action-refactor' into 'release'
Adding the widget names set to the default layout for a page

During action name refactor, we require the widget names to exist in the layout. Hence all default layouts must have the widgetName set.

See merge request theappsmith/internal-tools-server!387
2020-06-16 05:25:54 +00:00
Arpit Mohan
e27af0f525 Merge branch 'bug/curl-import-with-url-argument' into 'release'
Fix cURL import when using `--url` argument

See merge request theappsmith/internal-tools-server!386
2020-06-16 05:21:43 +00:00
Arpit Mohan
a4132d5845 Adding the widget names set to the default layout for a page 2020-06-16 10:50:07 +05:30
Shrikant Kandula
dd0ba857c2 Fix cURL import when using --url argument
Also fixes cases where there's a space between `-X` and `POST` and
similar cases.
2020-06-16 09:59:43 +05:30
Trisha Anand
9dfb72720e Fixed the broken test cases. 2020-06-12 19:35:01 +05:30
Trisha Anand
bb6dc61015 Build fix 2020-06-12 19:16:31 +05:30
Trisha Anand
73757c3425 Merge branch 'release' into feature/acl-spring-object
# Conflicts:
#	.gitignore
#	appsmith-plugins/mongoPlugin/plugin.properties
#	appsmith-plugins/postgresPlugin/plugin.properties
#	appsmith-plugins/rapidApiPlugin/plugin.properties
#	appsmith-plugins/restApiPlugin/plugin.properties
#	appsmith-plugins/restApiPlugin/src/main/java/com/external/plugins/RestApiPlugin.java
#	appsmith-server/src/main/java/com/appsmith/server/constants/FieldName.java
#	appsmith-server/src/main/java/com/appsmith/server/repositories/ActionRepository.java
#	appsmith-server/src/main/java/com/appsmith/server/services/ActionServiceImpl.java
#	appsmith-server/src/main/java/com/appsmith/server/services/DatasourceContextServiceImpl.java
#	appsmith-server/src/main/java/com/appsmith/server/services/DatasourceServiceImpl.java
#	appsmith-server/src/test/java/com/appsmith/server/services/ActionServiceTest.java
#	appsmith-server/src/test/java/com/appsmith/server/services/ApplicationServiceTest.java
#	appsmith-server/src/test/java/com/appsmith/server/services/LayoutServiceTest.java
#	appsmith-server/src/test/java/com/appsmith/server/services/PageServiceTest.java
#	build.sh
2020-06-12 19:14:31 +05:30
Trisha Anand
55837b4cc7 Merge branch 'bug/dont-invite-developer-role-users' into 'feature/acl-spring-object'
Don't invite users if they have any access in an org, not just admin.

See merge request theappsmith/internal-tools-server!382
2020-06-12 12:57:18 +00:00
Shrikant Kandula
18476432ac Don't invite users if they have any access in an org, not just admin. 2020-06-12 17:48:35 +05:30
Trisha Anand
cd26555861 Merge branch 'feature/acl-migration-script' into 'feature/acl-spring-object'
ACL Migration Script

See merge request theappsmith/internal-tools-server!371
2020-06-12 11:54:21 +00:00
Shrikant Kandula
b391f46e2c ACL Migration Script 2020-06-12 11:54:21 +00:00
Trisha Anand
d3e60953b9 Merge branch 'bug/acl-forgot-password' into 'feature/acl-spring-object'
Bug fix for forgot password error "user not found". During reset password, the user is not logged in and hence the permissions can not be applied during repository findByEmail

See merge request theappsmith/internal-tools-server!381
2020-06-12 08:33:30 +00:00
Trisha Anand
4eab663c8e Bug fix for forgot password error "user not found". During reset password, the user is not logged in and hence the permissions can not be applied during repository findByEmail 2020-06-12 13:57:57 +05:30
Trisha Anand
da8185f650 Merge branch 'bug/acl-invite-email-link-missing' into 'feature/acl-spring-object'
In case of sending email for an existing user, fixed the URL.

See merge request theappsmith/internal-tools-server!380
2020-06-12 08:06:51 +00:00
Trisha Anand
3dafccba2e In case of sending email for an existing user, fixed the URL. 2020-06-12 13:30:53 +05:30
Shrikant Kandula
c1a5f768c6 Merge branch 'bug/applications-not-invited-to' into 'feature/acl-spring-object'
Fix problem where not all apps were getting policies when invited.

See merge request theappsmith/internal-tools-server!379
2020-06-11 15:32:26 +00:00
Shrikant Kandula
ab83bc0223 Fix problem where not all apps were getting policies when invited. 2020-06-11 20:56:52 +05:30
Trisha Anand
dde850e367 Merge branch 'bug/acl-update-layout' into 'feature/acl-spring-object'
Fixed the repository function which was failing for fetching actions during updateLayout.

See merge request theappsmith/internal-tools-server!378
2020-06-11 07:22:16 +00:00
Trisha Anand
e7e008dcd2 Fixed the repository function which was failing for fetching actions during updateLayout. 2020-06-11 07:22:16 +00:00
Arpit Mohan
a2a4cbb2d7 Merge branch 'hotfix/plugin-fat-jar' into 'release'
Creating a fat jar for plugins

The plugins should be completely independent of the appsmith-server. Earlier, the plugins were picking their dependencies from the main appsmith-server maven module. 

Now using the maven-shade-plugin, they are an independent entity and completely self sufficient. The only exception is restapi-plugin & rapidapi-plugin because they inherit from spring-boot-starter which is not compatible with the maven-shade-plugin.

See merge request theappsmith/internal-tools-server!377
2020-06-10 11:11:23 +00:00
Arpit Mohan
01737b9599 Experimenting with maven-shade-plugin to create a fat-jar of the postgres dependency.
Will have to do this for all plugins. Currently, it's not registering the plugin with the SpringPluginManager
2020-06-10 11:11:23 +00:00
Trisha Anand
f00c9c23c8 Merge branch 'bug/mark-2xx-as-success-restapi-plugin' into 'release'
Mark any 2xx status code in REST API plugin as successful execution.

See merge request theappsmith/internal-tools-server!372
2020-06-10 10:51:07 +00:00
Shrikant Kandula
1ce336257c Mark any 2xx status code in REST API plugin as successful execution. 2020-06-10 10:51:07 +00:00
Trisha Anand
e3b6129d77 Merge branch 'bug/acl-app-viewer-org' into 'feature/acl-spring-object'
App viewer user in an organization should have read:organizations permission.

See merge request theappsmith/internal-tools-server!376
2020-06-10 10:34:26 +00:00
Trisha Anand
7a658ce5ea App viewer user in an organization should have read:organizations permission. 2020-06-10 15:55:29 +05:30
Trisha Anand
84b74813a5 Merge branch 'bug/acl-create-query' into 'feature/acl-spring-object'
In case of global datasource, no need to check for organizationId during action create.

See merge request theappsmith/internal-tools-server!375
2020-06-10 09:08:01 +00:00
Trisha Anand
491afc3599 In case of global datasource, no need to check for organizationId during action create. 2020-06-10 09:08:01 +00:00
Trisha Anand
ee1889da14 Merge branch 'bug/acl-app-datasource-permissions' into 'feature/acl-spring-object'
Fixes bugs : 1. read:datasource permission should not be applied to application; 2. A user shouldn't be added to an organization if the user already exists in the organization. 3. Save action was failing .

See merge request theappsmith/internal-tools-server!374
2020-06-10 06:22:16 +00:00
Trisha Anand
a89355a5ec Fixes bugs : 1. read:datasource permission should not be applied to application; 2. A user shouldn't be added to an organization if the user already exists in the organization. 2020-06-10 06:22:16 +00:00
Arpit Mohan
3cf8ff008f Hacky fix for the postgres plugin to work. Including the dependency in the appsmith-server/pom.xml file instead of the plugin 2020-06-10 10:46:09 +05:30
Trisha Anand
27fcb2dff8 Merge branch 'feature/acl-datasource-crud-policies' into 'feature/acl-spring-object'
Bug Fix : 1. user permissions during create/update of actions and datasources would now be set. 2. During update, policies are set to null in the update object to ensure that the policies are not overwritten to empty set.

See merge request theappsmith/internal-tools-server!373
2020-06-09 15:01:59 +00:00
Trisha Anand
ac06cc9668 1. user permissions during create/update of actions and datasources would now be set.
2. During update, policies are set to null in the update object to ensure that the policies are not overwritten to empty set.
2020-06-09 20:25:13 +05:30
Arpit Mohan
f74e8a45be Merge branch 'feature/query-action-configuration' into 'release'
Remove the query field in ActionConfiguration and use body instead

The client code is getting complicated because of the difference in SQL and non-SQL handling of the query field in actionConfiguration. If we expect the request to be sent in the `body` field, the plugin can parse the String body however it feels like.

See merge request theappsmith/internal-tools-server!340
2020-06-09 12:12:27 +00:00
Arpit Mohan
bbd33c2968 Removing the query field in ActionConfiguration and using String body as the field to store the query
This is to simplify the query pane on the frontend client. The client doesn't need to have separate interfaces for sql and non-sql plugins. All queries will be sent to the server in the form of a String that is parsed in different formats based on the plugin.

Also adding test cases for PostgresPlugin. Used TestContainers to simulate the postgres db in Docker inside the Java test itself. Very useful.
2020-06-09 12:12:27 +00:00
Trisha Anand
8ff7c56e64 Merge branch 'feature/rest-form-data' into 'release'
Handling form data via the field bodyFormData in ActionConfiguration

This is because the client sends us the data for form-data in the form of a list of Property fields with keys and values. This is consistent with how the client stores & renders headers & query parameters as well.
For MediaType application/x-www-form-urlencoded we will use the bodyFormData field.

See merge request theappsmith/internal-tools-server!370
2020-06-09 05:48:16 +00:00
Arpit Mohan
99e7519550 Handling form data via the field bodyFormData in ActionConfiguration
This is because the client sends us the data for form-data in the form of a list of Property fields with keys and values. This is consistent with how the client stores & renders headers & query parameters as well.
For MediaType application/x-www-form-urlencoded we will use the bodyFormData field.
2020-06-09 05:48:16 +00:00
Trisha Anand
7d83cfdae9 Merge branch 'bug/acl-empty-role-name' into 'feature/acl-spring-object'
Bug : When the user tries to invite without selecting the role user, this leads to null pointer exception. Fix : A user CAN NOT be invited to an organization without specifying the role.

See merge request theappsmith/internal-tools-server!369
2020-06-08 14:56:12 +00:00
Trisha Anand
061577d2c9 Bug : When the user tries to invite without selecting the role user, this leads to null pointer exception.
Fix : A user CAN NOT be invited to an organization without specifying the role.
2020-06-08 14:56:12 +00:00
Trisha Anand
a3af1384d1 Merge branch 'bug/acl-get-all-actions' into 'feature/acl-spring-object'
Bug Fix : Get all actions by application ID returning empty result : Changed the get all actions function to fix the bug where find by Example is not working. Instead the same has now been implemented using criteria.

See merge request theappsmith/internal-tools-server!368
2020-06-08 12:05:49 +00:00
Trisha Anand
a888d54059 Changed the get all actions function to fix the bug where find by Example is not working. Instead the same has now been implemented using criteria. 2020-06-08 12:05:49 +00:00
Trisha Anand
9ac7e817cc Merge branch 'feature/acl-remove-getCurrentOrganization' into 'feature/acl-spring-object'
Removed the usage of get current organization id. Added organization id to a few api calls.

See merge request theappsmith/internal-tools-server!367
2020-06-08 06:45:04 +00:00