// Copyright (c) 2025, JINGROW
// For license information, please see license.txt

jingrow.ui.form.on('NFS Volume Detachment', {
	refresh(frm) {
		if (frm.pg.status === 'Failure') {
			frm.add_custom_button('Force Continue', () => {
				frm.call('force_continue').then((r) => {
					if (r.message) {
						jingrow.msgprint(r.message);
					} else {
						frm.refresh();
					}
				});
			});
		}
	},
});
