[module.ue] POST now default value for 'defaultFormation' is int = -1 (type is INT btw)
This commit is contained in:
parent
1aab7b61bd
commit
6601880436
|
@ -64,7 +64,7 @@ class ueController{
|
||||||
$volumeTD = 0;
|
$volumeTD = 0;
|
||||||
$volumeTP = 0;
|
$volumeTP = 0;
|
||||||
$disabled = true;
|
$disabled = true;
|
||||||
$defaultFormation = null;
|
$defaultFormation = -1;
|
||||||
extract($args);
|
extract($args);
|
||||||
|
|
||||||
/* Get the ue repo */
|
/* Get the ue repo */
|
||||||
|
@ -87,7 +87,7 @@ class ueController{
|
||||||
$volumeTD,
|
$volumeTD,
|
||||||
$volumeTP,
|
$volumeTP,
|
||||||
$disabled,
|
$disabled,
|
||||||
$defaultFormation
|
is_int($defaultFormation) && $defaultFormation < 0 ? null : $defaultFormation
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
|
@ -145,7 +145,7 @@ class ueController{
|
||||||
$volumeTD = 0;
|
$volumeTD = 0;
|
||||||
$volumeTP = 0;
|
$volumeTP = 0;
|
||||||
$disabled = true;
|
$disabled = true;
|
||||||
$defaultFormation = null;
|
$defaultFormation = -1;
|
||||||
extract($args);
|
extract($args);
|
||||||
|
|
||||||
/* Get the ue repo */
|
/* Get the ue repo */
|
||||||
|
@ -161,7 +161,7 @@ class ueController{
|
||||||
$volumeTD,
|
$volumeTD,
|
||||||
$volumeTP,
|
$volumeTP,
|
||||||
$disabled,
|
$disabled,
|
||||||
$defaultFormation < 0 ? null : $defaultFormation
|
is_int($defaultFormation) && $defaultFormation < 0 ? null : $defaultFormation
|
||||||
)];
|
)];
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -185,14 +185,14 @@
|
||||||
"des": "Creates a new UE",
|
"des": "Creates a new UE",
|
||||||
"per": [],
|
"per": [],
|
||||||
"par": {
|
"par": {
|
||||||
"code": { "des": "UE code.", "typ": "varchar(4,20,alphanumeric)" },
|
"code": { "des": "UE code.", "typ": "varchar(4,20,alphanumeric)" },
|
||||||
"label": { "des": "UE label", "typ": "varchar(4,30,alphanumeric)" },
|
"label": { "des": "UE label", "typ": "varchar(4,30,alphanumeric)" },
|
||||||
"required": { "des": "If UE is required", "typ": "bool" },
|
"required": { "des": "If UE is required", "typ": "bool" },
|
||||||
"volumeCours": { "des": "Number of course hours for UE", "typ": "float" },
|
"volumeCours": { "des": "Number of course hours for UE", "typ": "float" },
|
||||||
"volumeTD": { "des": "Number of TD hours for UE", "typ": "float" },
|
"volumeTD": { "des": "Number of TD hours for UE", "typ": "float" },
|
||||||
"volumeTP": { "des": "Number of TP hours for UE", "typ": "float" },
|
"volumeTP": { "des": "Number of TP hours for UE", "typ": "float" },
|
||||||
"disabled": { "des": "Whether UE is disabled", "typ": "boolean" },
|
"disabled": { "des": "Whether UE is disabled", "typ": "boolean" },
|
||||||
"defaultFormation": { "des": "UID for optional default formation", "typ": "id", "opt": true }
|
"defaultFormation": { "des": "UID for optional default formation (-1 if none)", "typ": "int", "opt": true, "def": -1 }
|
||||||
},
|
},
|
||||||
"out": {
|
"out": {
|
||||||
"created_code": { "des": "Created UE code", "typ": "varchar(4,20,alphanumeric)" }
|
"created_code": { "des": "Created UE code", "typ": "varchar(4,20,alphanumeric)" }
|
||||||
|
|
Loading…
Reference in New Issue