Loading button not stop when i call success or error
i notify to formio submit success or error but loading button not stop. my code bellow
export class FormioViewComponent implements OnInit {
@Input() formDescription;
@Input() submission:any;
private fireSubmitSuccess: EventEmitter<String > = new EventEmitter();
private fireSubmitFailed: EventEmitter<String > = new EventEmitter();
@Output() submit :EventEmitter<any> = new EventEmitter();
constructor() { }
submitDone()
{
this.fireSubmitFailed.next("Thanh cong");
console.log("submit done");
}
ngOnInit() {
}
}
<formio [success]="fireSubmitSuccess" [error]="fireSubmitFailed"[form]="formDescription" (submit)="submit.emit($event) ; submitDone();" [submission]="submission"></formio>
This is a known issue that we are looking into.
I am having the same issue but Im just using the default submit event. It says submission complete but the submit loading icon doesn't go away. In the component.ts file, i just have a console.log for (submit)=onSubmit($event}.

@travist - Facing same issue. Any solution on this issue would be helpful!!
Hi guys, we're facing this same issue almost 4 years later, do you have any update about this topic??????
Not sure when this was introduced, but now we have submitDone directive to notify the formIO that the submission is done.
<formio [form]="formIoObj"
[submitDone]="submissionDone" <<<-----<<<<
[options]="formioOptions"
(submit)="submit($event)" ></formio>
@Component(...)
export class PreviewComponent {
@Output()
submissionDone = new EventEmitter<Boolean>();
async submit(formSubmission?: FormioSubmission) {
console.log(object);
// Submit to your backend
this.submissionDone.emit(true). // Set to true to notify submission is complete.
}
https://github.com/formio/angular/assets/17984781/768a0532-93ff-4931-bd95-22da85627430
P.S you should use the error directive when there are errors.
Thanks for the contribution @dinbtechit I'm going to go ahead and close this as resolved.
For me, at Angular 17, EventEmitter needs to be any as type. Boolean has crashed.
@Output() submissionDone = new EventEmitter<any>();
Thanks for the contribution @dinbtechit I'm going to go ahead and close this as resolved.
Please, update wiki at https://github.com/formio/angular/wiki/Form-Renderer with this parameter.
A ticket has been created to get this updated. Internal reference: FID-220