description editor > added option to skip form-refresh on save
This commit is contained in:
parent
96f160476a
commit
e7bc0406d6
|
@ -627,8 +627,7 @@ export class DescriptionEditorComponent extends BaseEditor<DescriptionEditorMode
|
||||||
}
|
}
|
||||||
|
|
||||||
refreshData(): void {
|
refreshData(): void {
|
||||||
this.getItem(this.editorModel.id, (data: Description) => this.prepareForm(data));
|
this.getItem(this.editorModel.id, (data: Description) => console.log(data));// this.prepareForm(data));
|
||||||
this.tocValidationService.validateForm();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
refreshOnNavigateToData(id?: Guid): void {
|
refreshOnNavigateToData(id?: Guid): void {
|
||||||
|
@ -649,7 +648,8 @@ export class DescriptionEditorComponent extends BaseEditor<DescriptionEditorMode
|
||||||
this.descriptionService.persist(formData)
|
this.descriptionService.persist(formData)
|
||||||
.pipe(takeUntil(this._destroyed)).subscribe(
|
.pipe(takeUntil(this._destroyed)).subscribe(
|
||||||
complete => {
|
complete => {
|
||||||
onSuccess ? onSuccess(complete) : this.onCallbackSuccess(complete);
|
onSuccess ? onSuccess(complete) : this.onCallbackSuccess(complete, !this.isNew);
|
||||||
|
this.tocValidationService.validateForm();
|
||||||
this.descriptionIsOnceSaved = true;
|
this.descriptionIsOnceSaved = true;
|
||||||
if (this.formGroup.get('status').value == DescriptionStatus.Finalized) this.isFinalized = true;
|
if (this.formGroup.get('status').value == DescriptionStatus.Finalized) this.isFinalized = true;
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in New Issue