spModal Prompt for input with proper label (Not Just red asterisk)
In widget client script, if you are trying to take an input from the user using spModal.Prompt you must have ended with a dialog where there is input box but there is no label along with it but only *, that seems very odd.
you must have also tried below knowledge articles which are near to the solution; but that is not satisfactory.
1) How to use spModal.prompt; Shows no label, but * alone
2) How to put label with prompt; Shows label but not where we exact want.
https://developer.servicenow.com/dev.do#!/reference/api/orlando/client/SPModal-API
3) Working Solution: The label comes as expected
We used the solution (2) but modified the JSON parameter for open method, used the "label" instead of "message", as below...
spModal.open({
title: 'Give me a name',
label: 'Please type name here...',
input: true,
value: c.name
}).then(function(name) {
c.name = name;
})
Regards
Chirag A
https://www.servicenow.com/community/developer-articles/spmodal-prompt-for-input-with-proper-label-not-just-red-asterisk/ta-p/2322212