This commit is contained in:
2020-01-14 19:17:26 +00:00
parent 9e3b449e14
commit d4324949b2
7 changed files with 43 additions and 184 deletions

View File

@@ -84,32 +84,6 @@ namespace AyaNova.Api.Controllers
}
/// <summary>
/// Get filter and sort options
///
/// Required roles:
/// BizAdminFull, InventoryFull, BizAdminLimited, InventoryLimited
///
/// </summary>
/// <returns>Filter options</returns>
[HttpGet("FilterOptions")]
public ActionResult FilterOptions()
{
if (serverState.IsClosed)
return StatusCode(503, new ApiErrorResponse(ApiErrorCode.API_CLOSED, null, serverState.Reason));
//Instantiate the business object handler
WidgetBiz biz = WidgetBiz.GetBiz(ct, HttpContext);
if (!Authorized.HasReadFullRole(HttpContext.Items, biz.BizType))
return StatusCode(403, new ApiNotAuthorizedResponse());
return Ok(new
{
data = WidgetBiz.FilterOptions(biz.UserLocaleId)
});
}
/// <summary>
/// Get list for selection / viewing
///