-
Notifications
You must be signed in to change notification settings - Fork 642
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
27 changed files
with
293 additions
and
424 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
/// <reference types="cypress" /> | ||
/// <reference types="../../support" /> | ||
|
||
context('resources/Tool/actions/edit', () => { | ||
before(() => { | ||
cy.login() | ||
}) | ||
|
||
beforeEach(() => { | ||
Cypress.Cookies.preserveOnce(Cypress.env('COOKIE_NAME')) | ||
cy.visit('resources/Tool') | ||
}) | ||
|
||
it('leaves null value in description when it was not alter', () => { | ||
cy.get('[data-testid="property-list-name"]').last().click() | ||
cy.get('[data-testid="action-edit"]').click() | ||
|
||
cy.server() | ||
cy.route({ method: 'POST', url: 'admin/api/resources/Tool/records/*/edit' }) | ||
.as('apiEdit') | ||
cy.get('button[type="submit"]').click() | ||
|
||
cy.wait('@apiEdit').then((xhr) => { | ||
const { record } = xhr.response.body | ||
expect(record.params.description).to.eq(null) | ||
}) | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
const { Nested } = require('./nested.entity') | ||
|
||
/** @type {import('admin-bro').ResourceOptions} */ | ||
const options = { | ||
|
||
} | ||
|
||
module.exports = { | ||
options, | ||
resource: Nested, | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
const mongoose = require('mongoose') | ||
|
||
const InnerElement = new mongoose.Schema({ | ||
name: { | ||
type: String, | ||
required: true, | ||
}, | ||
}) | ||
|
||
const TopArrayElement = new mongoose.Schema({ | ||
innerObjects: { | ||
type: [InnerElement], | ||
required: true, | ||
}, | ||
}) | ||
|
||
const NestedSchema = new mongoose.Schema({ | ||
name: { | ||
type: String, | ||
}, | ||
topObjects: [TopArrayElement], | ||
}) | ||
|
||
const Nested = mongoose.model('Nested', NestedSchema) | ||
|
||
module.exports = { ToolSchema: NestedSchema, Nested } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
27 changes: 0 additions & 27 deletions
27
src/frontend/components/actions/record-to-form-data.spec.ts
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.