This commit is contained in:
@@ -591,7 +591,7 @@ namespace AyaNova.Api.Controllers
|
|||||||
return StatusCode(503, new ApiErrorResponse(serverState.ApiErrorCode, null, serverState.Reason));
|
return StatusCode(503, new ApiErrorResponse(serverState.ApiErrorCode, null, serverState.Reason));
|
||||||
if (!Authorized.HasModifyRole(HttpContext.Items, AyaType.FileAttachment))
|
if (!Authorized.HasModifyRole(HttpContext.Items, AyaType.FileAttachment))
|
||||||
return StatusCode(403, new ApiNotAuthorizedResponse());
|
return StatusCode(403, new ApiNotAuthorizedResponse());
|
||||||
var JobName = $"Attachment maintenance (demand)";
|
var JobName = $"Attachment maintenance (demand) LT:User {UserNameFromContext.Name(HttpContext.Items)}";
|
||||||
OpsJob j = new OpsJob();
|
OpsJob j = new OpsJob();
|
||||||
j.Name = JobName;
|
j.Name = JobName;
|
||||||
j.ObjectType = AyaType.FileAttachment;
|
j.ObjectType = AyaType.FileAttachment;
|
||||||
|
|||||||
@@ -63,7 +63,7 @@ namespace AyaNova.Api.Controllers
|
|||||||
return StatusCode(503, new ApiErrorResponse(serverState.ApiErrorCode, null, serverState.Reason));
|
return StatusCode(503, new ApiErrorResponse(serverState.ApiErrorCode, null, serverState.Reason));
|
||||||
if (!Authorized.HasModifyRole(HttpContext.Items, AyaType.Backup))//technically maybe this could be wider open, but for now keeping as locked down
|
if (!Authorized.HasModifyRole(HttpContext.Items, AyaType.Backup))//technically maybe this could be wider open, but for now keeping as locked down
|
||||||
return StatusCode(403, new ApiNotAuthorizedResponse());
|
return StatusCode(403, new ApiNotAuthorizedResponse());
|
||||||
var JobName = $"Backup (on demand)";
|
var JobName = $"LT:BackupNow LT:User {UserNameFromContext.Name(HttpContext.Items)}";
|
||||||
OpsJob j = new OpsJob();
|
OpsJob j = new OpsJob();
|
||||||
j.Name = JobName;
|
j.Name = JobName;
|
||||||
j.ObjectType = AyaType.NoType;
|
j.ObjectType = AyaType.NoType;
|
||||||
|
|||||||
@@ -107,7 +107,7 @@ namespace AyaNova.Api.Controllers
|
|||||||
if (dataListSelection.SelectedRowIds.Length == 0)
|
if (dataListSelection.SelectedRowIds.Length == 0)
|
||||||
return BadRequest(new ApiErrorResponse(ApiErrorCode.VALIDATION_REQUIRED, null, "List of ids"));
|
return BadRequest(new ApiErrorResponse(ApiErrorCode.VALIDATION_REQUIRED, null, "List of ids"));
|
||||||
|
|
||||||
var JobName = $"Batch job: Add tag \"{tag}\" on {dataListSelection.ObjectType} ({dataListSelection.SelectedRowIds.LongLength} specified)";
|
var JobName = $"LT:BatchJob LT:Add LT:Tag \"{tag}\" LT:{dataListSelection.ObjectType} ({dataListSelection.SelectedRowIds.LongLength}) LT:User {UserNameFromContext.Name(HttpContext.Items)}";
|
||||||
JObject o = JObject.FromObject(new
|
JObject o = JObject.FromObject(new
|
||||||
{
|
{
|
||||||
idList = dataListSelection.SelectedRowIds,
|
idList = dataListSelection.SelectedRowIds,
|
||||||
@@ -148,7 +148,7 @@ namespace AyaNova.Api.Controllers
|
|||||||
if (string.IsNullOrWhiteSpace(tag))
|
if (string.IsNullOrWhiteSpace(tag))
|
||||||
return BadRequest(new ApiErrorResponse(ApiErrorCode.VALIDATION_REQUIRED, null, "tag"));
|
return BadRequest(new ApiErrorResponse(ApiErrorCode.VALIDATION_REQUIRED, null, "tag"));
|
||||||
|
|
||||||
var JobName = $"Batch job: Add tag \"{tag}\" on any {ayaType}";
|
var JobName = $"LT:BatchJob LT:Add LT:Tag \"{tag}\" LT:{ayaType.ToString()} (LT:GridRowFilterDropDownAllItem) LT:User {UserNameFromContext.Name(HttpContext.Items)}";
|
||||||
JObject o = JObject.FromObject(new
|
JObject o = JObject.FromObject(new
|
||||||
{
|
{
|
||||||
tag = tag
|
tag = tag
|
||||||
@@ -197,7 +197,7 @@ namespace AyaNova.Api.Controllers
|
|||||||
return BadRequest(new ApiErrorResponse(ApiErrorCode.VALIDATION_REQUIRED, null, "List of ids"));
|
return BadRequest(new ApiErrorResponse(ApiErrorCode.VALIDATION_REQUIRED, null, "List of ids"));
|
||||||
|
|
||||||
|
|
||||||
var JobName = $"Batch job: Remove tag \"{tag}\" from {dataListSelection.ObjectType} ({dataListSelection.SelectedRowIds.LongLength} specified)";
|
var JobName = $"LT:BatchJob LT:Remove LT:Tag \"{tag}\" LT:{dataListSelection.ObjectType} ({dataListSelection.SelectedRowIds.LongLength}) LT:User {UserNameFromContext.Name(HttpContext.Items)}";
|
||||||
JObject o = JObject.FromObject(new
|
JObject o = JObject.FromObject(new
|
||||||
{
|
{
|
||||||
idList = dataListSelection.SelectedRowIds,
|
idList = dataListSelection.SelectedRowIds,
|
||||||
@@ -239,7 +239,7 @@ namespace AyaNova.Api.Controllers
|
|||||||
if (string.IsNullOrWhiteSpace(tag))
|
if (string.IsNullOrWhiteSpace(tag))
|
||||||
return BadRequest(new ApiErrorResponse(ApiErrorCode.VALIDATION_REQUIRED, null, "tag"));
|
return BadRequest(new ApiErrorResponse(ApiErrorCode.VALIDATION_REQUIRED, null, "tag"));
|
||||||
|
|
||||||
var JobName = $"Batch job: Remove tag \"{tag}\" from any {ayaType}";
|
var JobName = $"LT:BatchJob LT:Remove LT:Tag \"{tag}\" LT:{ayaType.ToString()} (LT:GridRowFilterDropDownAllItem) LT:User {UserNameFromContext.Name(HttpContext.Items)}";
|
||||||
JObject o = JObject.FromObject(new
|
JObject o = JObject.FromObject(new
|
||||||
{
|
{
|
||||||
tag = tag
|
tag = tag
|
||||||
@@ -288,7 +288,7 @@ namespace AyaNova.Api.Controllers
|
|||||||
if (dataListSelection.SelectedRowIds.Length == 0)
|
if (dataListSelection.SelectedRowIds.Length == 0)
|
||||||
return BadRequest(new ApiErrorResponse(ApiErrorCode.VALIDATION_REQUIRED, null, "List of ids"));
|
return BadRequest(new ApiErrorResponse(ApiErrorCode.VALIDATION_REQUIRED, null, "List of ids"));
|
||||||
|
|
||||||
var JobName = $"Batch job: Replace tag \"{fromTag}\" with tag \"{toTag}\" on {dataListSelection.ObjectType} ({dataListSelection.SelectedRowIds.LongLength} specified)";
|
var JobName = $"LT:BatchJob LT:Replace LT:Tag \"{fromTag}\" -> LT:Tag \"{toTag}\" LT:{dataListSelection.ObjectType} ({dataListSelection.SelectedRowIds.LongLength}) LT:User {UserNameFromContext.Name(HttpContext.Items)}";
|
||||||
JObject o = JObject.FromObject(new
|
JObject o = JObject.FromObject(new
|
||||||
{
|
{
|
||||||
idList = dataListSelection.SelectedRowIds,
|
idList = dataListSelection.SelectedRowIds,
|
||||||
@@ -335,7 +335,7 @@ namespace AyaNova.Api.Controllers
|
|||||||
if (string.IsNullOrWhiteSpace(toTag))
|
if (string.IsNullOrWhiteSpace(toTag))
|
||||||
return BadRequest(new ApiErrorResponse(ApiErrorCode.VALIDATION_REQUIRED, null, "toTag"));
|
return BadRequest(new ApiErrorResponse(ApiErrorCode.VALIDATION_REQUIRED, null, "toTag"));
|
||||||
|
|
||||||
var JobName = $"Batch job: Replace tag \"{fromTag}\" with tag \"{toTag}\" on any {ayaType}";
|
var JobName = $"LT:BatchJob LT:Replace LT:Tag \"{fromTag}\" -> LT:Tag \"{toTag}\" LT:{ayaType.ToString()} (LT:GridRowFilterDropDownAllItem) LT:User {UserNameFromContext.Name(HttpContext.Items)}";
|
||||||
JObject o = JObject.FromObject(new
|
JObject o = JObject.FromObject(new
|
||||||
{
|
{
|
||||||
tag = fromTag,
|
tag = fromTag,
|
||||||
|
|||||||
Reference in New Issue
Block a user