mirror of
https://github.com/devcode-it/openstamanager.git
synced 2025-02-23 23:07:46 +01:00
fix: 🐛 submit del form non triggerata
This commit is contained in:
parent
39c3a0d152
commit
49d83a672f
@ -166,7 +166,7 @@ export default class RecordsPage extends Page {
|
|||||||
})()}
|
})()}
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
<mwc-button slot="primaryAction" dialogAction="discard">
|
<mwc-button slot="primaryAction" dialogAction="confirm">
|
||||||
{this.__('Conferma')}
|
{this.__('Conferma')}
|
||||||
</mwc-button>
|
</mwc-button>
|
||||||
<mwc-button slot="secondaryAction" dialogAction="cancel">
|
<mwc-button slot="secondaryAction" dialogAction="cancel">
|
||||||
@ -207,9 +207,14 @@ export default class RecordsPage extends Page {
|
|||||||
.on('click', (clickEvent) => {
|
.on('click', (clickEvent) => {
|
||||||
const dialog = $(clickEvent.delegateTarget)
|
const dialog = $(clickEvent.delegateTarget)
|
||||||
.next('mwc-dialog#add-record-dialog');
|
.next('mwc-dialog#add-record-dialog');
|
||||||
|
const form = dialog.find('form');
|
||||||
|
|
||||||
dialog.find('form')
|
dialog.find('mwc-button[dialogAction="confirm"]')
|
||||||
.attr('method', 'PUT')
|
.on('click', () => {
|
||||||
|
form.trigger('submit');
|
||||||
|
});
|
||||||
|
|
||||||
|
form.attr('method', 'PUT')
|
||||||
.off()
|
.off()
|
||||||
.on('submit', async (event) => {
|
.on('submit', async (event) => {
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user