Skip to content

Commit

Permalink
chore: Send applicationDetail in create application payload (appsmi…
Browse files Browse the repository at this point in the history
…thorg#28272)

## Description
- Add the `applicationDetail` payload to the create application request.
- This allows instances which have Anvil enabled, to default to Anvil
when an application is created.

#### PR fixes following issue(s)
Fixes appsmithorg#28237 

#### Type of change
- Chore (housekeeping or task changes that don't impact user perception)

#### How Has This Been Tested?
- [x] Manual
- [ ] JUnit
- [ ] Jest
- [ ] Cypress - If all existing tests pass, we're good to merge

## Checklist:
#### Dev activity
- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [ ] My changes generate no new warnings
- [ ] I have added tests that prove my fix is effective or that my
feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] PR is being merged under a feature flag


#### QA activity:
- [ ] [Speedbreak
features](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans#speedbreakers-)
have been covered
- [ ] Test plan covers all impacted features and [areas of
interest](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans#areas-of-interest-)
- [ ] Test plan has been peer reviewed by project stakeholders and other
QA members
- [ ] Manually tested functionality on DP
- [ ] We had an implementation alignment call with stakeholders post QA
Round 2
- [ ] Cypress test cases have been added and approved by SDET/manual QA
- [ ] Added `Test Plan Approved` label after Cypress tests were reviewed
- [ ] Added `Test Plan Approved` label after JUnit tests were reviewed

---------

Co-authored-by: nilansh <[email protected]>
  • Loading branch information
riodeuno and NilanshBansal authored Oct 24, 2023
1 parent 8eea001 commit 651f944
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
5 changes: 5 additions & 0 deletions app/client/src/ce/api/ApplicationApi.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -307,6 +307,11 @@ export class ApplicationApi extends Api {
name: request.name,
color: request.color,
icon: request.icon,
applicationDetail: {
appPositioning: {
type: request.layoutSystemType,
},
},
},
);
}
Expand Down
4 changes: 0 additions & 4 deletions app/client/src/selectors/layoutSystemSelectors.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,6 @@ import { LayoutSystemTypes } from "layoutSystems/types";
* selector to fetch the application's layout type
*/
export const getLayoutSystemType = (state: AppState) => {
const featureFlag = state.ui.users.featureFlag.data;
if (featureFlag && featureFlag.release_anvil_enabled === true) {
return LayoutSystemTypes.ANVIL;
}
if (
state.ui.applications?.currentApplication?.applicationDetail?.appPositioning
?.type
Expand Down

0 comments on commit 651f944

Please sign in to comment.