mirror of
https://github.com/retailcrm/NelmioApiDocBundle.git
synced 2025-02-09 02:59:27 +03:00
Merge pull request #989 from lsmith77/submit-boolean-as-json-boolean
ensure that boolean fields are submited as boolean values when using json
This commit is contained in:
commit
ae18441763
@ -517,6 +517,11 @@
|
|||||||
value = $('.value', $(this)).val();
|
value = $('.value', $(this)).val();
|
||||||
|
|
||||||
if (value) {
|
if (value) {
|
||||||
|
// convert boolean values to boolean
|
||||||
|
if ('json' === bodyFormat && 'boolean' === $('.tuple_type', $(this)).val()) {
|
||||||
|
value = '1' === value;
|
||||||
|
}
|
||||||
|
|
||||||
// temporary save all additional/doubled parameters
|
// temporary save all additional/doubled parameters
|
||||||
if (key in params) {
|
if (key in params) {
|
||||||
doubledParams[key] = value;
|
doubledParams[key] = value;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user