how to move Hr Case to draft state
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-17-2023 06:51 AM
i have build a custom table "hr_case" with some custom fields.in state filed i have "draft" state.
once i click "submit" button with mandatory fields in the form it will move me to "draft" state.
How can i achieve this please suggest.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-17-2023 07:25 AM
Hello @showsid02
Can you check your question once again, you mention it is draft stat, you need to move it to draft.
Quite Confusing.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-17-2023 08:38 AM
state is a choice field having 1,draft 2.ready 3 work in progress and so on.
So once i submit the form with clicking submit button it set state to "draft".
this is my requirement.
Please suggest
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-17-2023 08:44 AM
Hello @showsid02
You need to write a onSubmit() Client Script :-
function onSubmit(){
g_form.setValue('state', 'backend_value_of_draft');
}
Plz Mark my Solution as Accept and Give me thumbs up, if you find it helpful.
Regards,
Samaksh