This commit is contained in:
@@ -227,9 +227,10 @@ namespace AyaNova.Api.Controllers
|
||||
/// Required roles: BizAdminFull
|
||||
/// </summary>
|
||||
/// <param name="inObj"></param>
|
||||
/// <param name="apiVersion">Automatically filled from route path, no need to specify in body</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost]
|
||||
public async Task<IActionResult> PostFormCustom([FromBody] FormCustom inObj)
|
||||
public async Task<IActionResult> PostFormCustom([FromBody] FormCustom inObj, ApiVersion apiVersion)
|
||||
{
|
||||
if (!serverState.IsOpen)
|
||||
return StatusCode(503, new ApiErrorResponse(ApiErrorCode.API_CLOSED, null, serverState.Reason));
|
||||
@@ -249,7 +250,7 @@ namespace AyaNova.Api.Controllers
|
||||
if (o == null)
|
||||
return BadRequest(new ApiErrorResponse(biz.Errors));
|
||||
else
|
||||
return CreatedAtAction("GetFormCustom", new { formkey = o.FormKey }, new ApiCreatedResponse(o));
|
||||
return CreatedAtAction(nameof(FormCustomController.GetFormCustom), new { formkey = o.FormKey, version = apiVersion.ToString() }, new ApiCreatedResponse(o));
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user