callApiApproval method
Implementation
void callApiApproval(CertificateObj certificate, CallbackData callback) {
showLoading();
Map<String, dynamic> data = <String, dynamic>{};
Map<String, dynamic> info = <String, dynamic>{};
// info['ma_dvi'] = certificate.maDvi;
info['nv'] = certificate.nv;
info['dvi_sl'] = certificate.maDvi;
info['so_id'] = certificate.soId.toString();
info['so_hd'] = certificate.soHd;
data['data'] = json.encode(info);
CertificateAPI.duyetDon(data).then((response) {
printDebug(response);
closeLoading();
if (response.apiCode == APICode.ok) {
showAlertDialogMessage(content: response.message);
callback(response);
} else {
showAlertDialogMessage(content: response.message);
}
});
return;
}