Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
96a3e98109 | ||
|
|
14f856fdb3 | ||
|
|
155aedeab3 | ||
|
|
7db53c1aba |
@@ -3,10 +3,11 @@
|
||||
"isRoot": true,
|
||||
"tools": {
|
||||
"dotnet-ef": {
|
||||
"version": "7.0.9",
|
||||
"version": "10.0.8",
|
||||
"commands": [
|
||||
"dotnet-ef"
|
||||
]
|
||||
],
|
||||
"rollForward": false
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -20,13 +20,19 @@ namespace Microsoft.SelfService.Portal.Core.API.Context
|
||||
public DbSet<DeploymentModel> Deployments { get; set; }
|
||||
public DbSet<DeploymentGroupModel> DeploymentGroups { get; set; }
|
||||
public DbSet<TemplateModel> Templates { get; set; }
|
||||
public DbSet<DeploymentRuleModel> DeploymentRules { get; set; }
|
||||
public DbSet<DeploymentRuleStepModel> DeploymentRuleSteps { get; set; }
|
||||
public DbSet<TemplateCategoryModel> TemplateCategories { get; set; }
|
||||
public DbSet<ServiceModel> Services { get; set; }
|
||||
public DbSet<ServiceRoleDefinitionModel> ServiceRoleDefinitions { get; set; }
|
||||
public DbSet<TemplateOptionModel> TemplateOptions { get; set; }
|
||||
public DbSet<OptionModel> Options { get; set; }
|
||||
public DbSet<OptionCategoryModel> OptionCategories { get; set; }
|
||||
public DbSet<JobModel> Jobs { get; set; }
|
||||
public DbSet<RunbookModel> Runbooks { get; set; }
|
||||
public DbSet<QueueJobModel> QueueJobs { get; set; }
|
||||
public DbSet<QueueJobTargetModel> QueueJobTargets { get; set; }
|
||||
public DbSet<QueueJobStepModel> QueueJobSteps { get; set; }
|
||||
|
||||
protected override void OnModelCreating(ModelBuilder modelBuilder)
|
||||
{
|
||||
@@ -63,6 +69,41 @@ namespace Microsoft.SelfService.Portal.Core.API.Context
|
||||
.WithMany(s => s.TemplateCategories)
|
||||
.HasForeignKey(tc => tc.ServiceId);
|
||||
|
||||
modelBuilder.Entity<ServiceRoleDefinitionModel>()
|
||||
.HasOne(role => role.Service)
|
||||
.WithMany(service => service.RoleDefinitions)
|
||||
.HasForeignKey(role => role.ServiceId);
|
||||
|
||||
modelBuilder.Entity<DeploymentGroupModel>()
|
||||
.ToTable("DeploymentBatches");
|
||||
|
||||
modelBuilder.Entity<DeploymentModel>()
|
||||
.ToTable("DeploymentExecutions");
|
||||
modelBuilder.Entity<DeploymentModel>()
|
||||
.Property(deployment => deployment.DeploymentGroupId)
|
||||
.HasColumnName("DeploymentBatchId");
|
||||
|
||||
modelBuilder.Entity<QueueJobModel>()
|
||||
.ToTable("DeploymentJobs");
|
||||
|
||||
modelBuilder.Entity<QueueJobTargetModel>()
|
||||
.ToTable("DeploymentJobTargets");
|
||||
modelBuilder.Entity<QueueJobTargetModel>()
|
||||
.Property(target => target.QueueJobId)
|
||||
.HasColumnName("DeploymentJobId");
|
||||
modelBuilder.Entity<QueueJobTargetModel>()
|
||||
.Property(target => target.DeploymentGroupId)
|
||||
.HasColumnName("DeploymentBatchId");
|
||||
|
||||
modelBuilder.Entity<QueueJobStepModel>()
|
||||
.ToTable("DeploymentJobSteps");
|
||||
modelBuilder.Entity<QueueJobStepModel>()
|
||||
.Property(step => step.QueueJobId)
|
||||
.HasColumnName("DeploymentJobId");
|
||||
modelBuilder.Entity<QueueJobStepModel>()
|
||||
.Property(step => step.DependsOnQueueJobStepId)
|
||||
.HasColumnName("DependsOnDeploymentJobStepId");
|
||||
|
||||
modelBuilder.Entity<DeploymentModel>()
|
||||
.HasKey(d => new { d.VirtualMachineId, d.DeploymentGroupId });
|
||||
|
||||
@@ -80,6 +121,32 @@ namespace Microsoft.SelfService.Portal.Core.API.Context
|
||||
.HasOne(dg => dg.Template)
|
||||
.WithMany(t => t.DeploymentGroups)
|
||||
.HasForeignKey(dg => dg.TemplateId);
|
||||
|
||||
modelBuilder.Entity<TemplateModel>()
|
||||
.HasOne(template => template.DeploymentRule)
|
||||
.WithMany()
|
||||
.HasForeignKey(template => template.DeploymentRuleId);
|
||||
|
||||
modelBuilder.Entity<DeploymentRuleStepModel>()
|
||||
.HasOne(step => step.DeploymentRule)
|
||||
.WithMany(rule => rule.Steps)
|
||||
.HasForeignKey(step => step.DeploymentRuleId);
|
||||
|
||||
modelBuilder.Entity<QueueJobTargetModel>()
|
||||
.HasOne(target => target.QueueJob)
|
||||
.WithMany(job => job.Targets)
|
||||
.HasForeignKey(target => target.QueueJobId);
|
||||
|
||||
modelBuilder.Entity<QueueJobStepModel>()
|
||||
.HasOne(step => step.QueueJob)
|
||||
.WithMany(job => job.Steps)
|
||||
.HasForeignKey(step => step.QueueJobId);
|
||||
|
||||
modelBuilder.Entity<QueueJobStepModel>()
|
||||
.HasOne(step => step.DependsOnQueueJobStep)
|
||||
.WithMany()
|
||||
.HasForeignKey(step => step.DependsOnQueueJobStepId)
|
||||
.OnDelete(DeleteBehavior.Restrict);
|
||||
|
||||
modelBuilder.Entity<JobModel>()
|
||||
.HasKey(j => new { j.RunbookId, j.DeploymentId });
|
||||
|
||||
@@ -5,12 +5,14 @@ using Microsoft.SelfService.Portal.Core.API.Dto.Deployment.Get;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.Deployment.Edit;
|
||||
using Microsoft.SelfService.Portal.Core.API.Interfaces;
|
||||
using Microsoft.SelfService.Portal.Core.API.Models;
|
||||
using Microsoft.SelfService.Portal.Core.API.Context;
|
||||
|
||||
using Microsoft.SelfService.Portal.Core.API.Events.Interfaces;
|
||||
using System.Reflection;
|
||||
using System.Collections;
|
||||
using System.Dynamic;
|
||||
using System.Text.Json;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Controllers
|
||||
{
|
||||
@@ -19,12 +21,21 @@ namespace Microsoft.SelfService.Portal.Core.API.Controllers
|
||||
public class DeploymentController : Controller
|
||||
{
|
||||
private readonly IDeploymentInterface _deploymentInterface;
|
||||
private readonly IQueueJobService _queueJobService;
|
||||
private readonly DataContext _context;
|
||||
private readonly IMapper _mapper;
|
||||
private readonly IEventHandlerInterface _eventHandlerInterface;
|
||||
|
||||
public DeploymentController(IDeploymentInterface deploymentInterface, IMapper mapper, IEventHandlerInterface eventHandlerInterface)
|
||||
public DeploymentController(
|
||||
IDeploymentInterface deploymentInterface,
|
||||
IQueueJobService queueJobService,
|
||||
DataContext context,
|
||||
IMapper mapper,
|
||||
IEventHandlerInterface eventHandlerInterface)
|
||||
{
|
||||
_deploymentInterface = deploymentInterface;
|
||||
_queueJobService = queueJobService;
|
||||
_context = context;
|
||||
_mapper = mapper;
|
||||
_eventHandlerInterface = eventHandlerInterface;
|
||||
}
|
||||
@@ -81,6 +92,163 @@ namespace Microsoft.SelfService.Portal.Core.API.Controllers
|
||||
return Ok(deploymentMap.Id);
|
||||
}
|
||||
|
||||
[HttpPost("Request")]
|
||||
[ProducesResponseType(200)]
|
||||
[ProducesResponseType(400)]
|
||||
public IActionResult AddDeploymentRequest([FromBody] AddDeploymentRequestDto request)
|
||||
{
|
||||
if (request == null)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
if (request.VirtualMachineIds == null || request.VirtualMachineIds.Count == 0)
|
||||
{
|
||||
ModelState.AddModelError("", "At least one VirtualMachine must be selected.");
|
||||
return BadRequest(ModelState);
|
||||
}
|
||||
|
||||
if (!ModelState.IsValid)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
try
|
||||
{
|
||||
var queueJobId = _queueJobService.EnqueueDeploymentRequest(
|
||||
request.DeploymentGroupId,
|
||||
request.VirtualMachineIds,
|
||||
request.JsonData);
|
||||
|
||||
return Ok(queueJobId);
|
||||
}
|
||||
catch (InvalidOperationException ex)
|
||||
{
|
||||
ModelState.AddModelError("", ex.Message);
|
||||
return BadRequest(ModelState);
|
||||
}
|
||||
}
|
||||
|
||||
[HttpGet("QueueJobs")]
|
||||
[ProducesResponseType(200, Type = typeof(IEnumerable<GetQueueJobDto>))]
|
||||
public IActionResult GetQueueJobs()
|
||||
{
|
||||
var queueJobs = _context.QueueJobs
|
||||
.AsNoTracking()
|
||||
.Include(job => job.Targets)
|
||||
.Include(job => job.Steps)
|
||||
.OrderByDescending(job => job.Created)
|
||||
.Select(job => new GetQueueJobDto
|
||||
{
|
||||
Id = job.Id,
|
||||
Type = job.Type,
|
||||
Status = job.Status,
|
||||
Attempts = job.Attempts,
|
||||
MaxAttempts = job.MaxAttempts,
|
||||
Started = job.Started,
|
||||
Finished = job.Finished,
|
||||
ErrorMessage = job.ErrorMessage,
|
||||
TargetCount = job.Targets.Count,
|
||||
SucceededTargetCount = job.Targets.Count(target => target.Status == QueueJobStatus.Succeeded),
|
||||
FailedTargetCount = job.Targets.Count(target => target.Status == QueueJobStatus.Failed)
|
||||
})
|
||||
.ToList();
|
||||
|
||||
return Ok(queueJobs);
|
||||
}
|
||||
|
||||
[HttpGet("QueueJobs/{Id}")]
|
||||
[ProducesResponseType(200, Type = typeof(GetQueueJobDetailsDto))]
|
||||
[ProducesResponseType(404)]
|
||||
public IActionResult GetQueueJobById(Guid Id)
|
||||
{
|
||||
var queueJob = _context.QueueJobs
|
||||
.AsNoTracking()
|
||||
.Include(job => job.Targets)
|
||||
.Include(job => job.Steps)
|
||||
.FirstOrDefault(job => job.Id == Id);
|
||||
|
||||
if (queueJob == null)
|
||||
return NotFound();
|
||||
|
||||
var details = new GetQueueJobDetailsDto
|
||||
{
|
||||
Id = queueJob.Id,
|
||||
Type = queueJob.Type,
|
||||
Status = queueJob.Status,
|
||||
PayloadJson = queueJob.PayloadJson,
|
||||
Attempts = queueJob.Attempts,
|
||||
MaxAttempts = queueJob.MaxAttempts,
|
||||
Started = queueJob.Started,
|
||||
Finished = queueJob.Finished,
|
||||
ErrorMessage = queueJob.ErrorMessage,
|
||||
MetadataJson = queueJob.MetadataJson,
|
||||
RuleSnapshotJson = queueJob.RuleSnapshotJson,
|
||||
Created = queueJob.Created,
|
||||
CreatedBy = queueJob.CreatedBy,
|
||||
Modified = queueJob.Modified,
|
||||
ModifiedBy = queueJob.ModifiedBy,
|
||||
Targets = queueJob.Targets.Select(target => new GetQueueJobTargetDto
|
||||
{
|
||||
Id = target.Id,
|
||||
VirtualMachineId = target.VirtualMachineId,
|
||||
DeploymentGroupId = target.DeploymentGroupId,
|
||||
TemplateId = target.TemplateId,
|
||||
Status = target.Status,
|
||||
Attempts = target.Attempts,
|
||||
ErrorMessage = target.ErrorMessage
|
||||
}).ToList(),
|
||||
Steps = queueJob.Steps
|
||||
.OrderBy(step => step.SortOrder)
|
||||
.Select(step => new GetQueueJobStepDto
|
||||
{
|
||||
Id = step.Id,
|
||||
DependsOnQueueJobStepId = step.DependsOnQueueJobStepId,
|
||||
SortOrder = step.SortOrder,
|
||||
Name = step.Name,
|
||||
StepType = step.StepType,
|
||||
Status = step.Status,
|
||||
MetadataJson = step.MetadataJson,
|
||||
ApprovedAt = step.ApprovedAt,
|
||||
ApprovedBy = step.ApprovedBy,
|
||||
ApprovalComment = step.ApprovalComment
|
||||
}).ToList()
|
||||
};
|
||||
|
||||
return Ok(details);
|
||||
}
|
||||
|
||||
[HttpPost("QueueJobs/{Id}/Retry")]
|
||||
[ProducesResponseType(204)]
|
||||
[ProducesResponseType(404)]
|
||||
public IActionResult RetryQueueJob(Guid Id)
|
||||
{
|
||||
if (!_queueJobService.RetryQueueJob(Id))
|
||||
return NotFound();
|
||||
|
||||
return NoContent();
|
||||
}
|
||||
|
||||
[HttpPost("QueueJobs/Steps/{stepId}/Approve")]
|
||||
[ProducesResponseType(204)]
|
||||
[ProducesResponseType(404)]
|
||||
public IActionResult ApproveQueueJobStep(Guid stepId, [FromBody] QueueJobStepApprovalDto? payload)
|
||||
{
|
||||
var approvedBy = payload?.ApprovedBy ?? User?.Identity?.Name ?? "System";
|
||||
if (!_queueJobService.ApproveQueueJobStep(stepId, approvedBy, payload?.Comment))
|
||||
return NotFound();
|
||||
|
||||
return NoContent();
|
||||
}
|
||||
|
||||
[HttpPost("QueueJobs/Steps/{stepId}/Reject")]
|
||||
[ProducesResponseType(204)]
|
||||
[ProducesResponseType(404)]
|
||||
public IActionResult RejectQueueJobStep(Guid stepId, [FromBody] QueueJobStepApprovalDto? payload)
|
||||
{
|
||||
var approvedBy = payload?.ApprovedBy ?? User?.Identity?.Name ?? "System";
|
||||
if (!_queueJobService.RejectQueueJobStep(stepId, approvedBy, payload?.Comment))
|
||||
return NotFound();
|
||||
|
||||
return NoContent();
|
||||
}
|
||||
|
||||
[HttpDelete("{Id}")]
|
||||
[ProducesResponseType(204)]
|
||||
[ProducesResponseType(400)]
|
||||
|
||||
@@ -65,7 +65,7 @@ namespace Microsoft.SelfService.Portal.Core.API.Controllers
|
||||
|
||||
var deploymentgroupMap = _mapper.Map<DeploymentGroupModel>(deploymentgroup);
|
||||
|
||||
if (!_deploymentgroupInterface.AddDeploymentGroupById(deploymentgroupMap))
|
||||
if (!_deploymentgroupInterface.AddDeploymentGroupById(deploymentgroupMap, deploymentgroup.VirtualMachineIds))
|
||||
{
|
||||
ModelState.AddModelError("", "Something went wrong while saving");
|
||||
return StatusCode(500, ModelState);
|
||||
|
||||
@@ -139,7 +139,8 @@ namespace Microsoft.SelfService.Portal.Core.API.Controllers
|
||||
if (!_environmentInterface.CheckEnvironmentById(Id))
|
||||
return NotFound();
|
||||
|
||||
var environment = _mapper.Map<GetEnvironmentDomainDto>(_environmentInterface.GetLinkedDomainsByEnvironmentId(Id));
|
||||
var environment = GetEnvironmentDomainDto.FromModel(
|
||||
_environmentInterface.GetLinkedDomainsByEnvironmentId(Id));
|
||||
|
||||
if (!ModelState.IsValid)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
@@ -1,8 +1,9 @@
|
||||
using AutoMapper;
|
||||
using AutoMapper;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.Service.Add;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.Service.Edit;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.Service.Get;
|
||||
using Microsoft.SelfService.Portal.Core.API.Events;
|
||||
using Microsoft.SelfService.Portal.Core.API.Events.Interfaces;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.Service.RoleDefinition;
|
||||
using Microsoft.SelfService.Portal.Core.API.Interfaces;
|
||||
using Microsoft.SelfService.Portal.Core.API.Models;
|
||||
|
||||
@@ -32,20 +33,210 @@ namespace Microsoft.SelfService.Portal.Core.API.Controllers
|
||||
|
||||
return Ok(services);
|
||||
}
|
||||
|
||||
|
||||
[HttpGet("{Id}")]
|
||||
[ProducesResponseType(200, Type = typeof(ServiceModel))]
|
||||
[ProducesResponseType(404)]
|
||||
public IActionResult GetServiceById(Guid Id)
|
||||
{
|
||||
if(!_serviceInterface.CheckServiceById(Id))
|
||||
if (!_serviceInterface.CheckServiceById(Id))
|
||||
return NotFound();
|
||||
|
||||
var service = _mapper.Map<GetServiceDetailsDto>(_serviceInterface.GetServiceById(Id));
|
||||
|
||||
if(!ModelState.IsValid)
|
||||
|
||||
if (!ModelState.IsValid)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
return Ok(service);
|
||||
}
|
||||
|
||||
[HttpPost]
|
||||
[ProducesResponseType(200)]
|
||||
[ProducesResponseType(400)]
|
||||
public IActionResult AddServiceById([FromBody] AddServiceDto service)
|
||||
{
|
||||
if (service == null)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
if (_serviceInterface.CheckServiceByName(service.Name))
|
||||
{
|
||||
ModelState.AddModelError("", "Service already exists");
|
||||
return StatusCode(422, ModelState);
|
||||
}
|
||||
|
||||
if (!ModelState.IsValid)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
var serviceMap = _mapper.Map<ServiceModel>(service);
|
||||
|
||||
if (!_serviceInterface.AddServiceById(serviceMap))
|
||||
{
|
||||
ModelState.AddModelError("", "Something went wrong while saving");
|
||||
return StatusCode(500, ModelState);
|
||||
}
|
||||
|
||||
return Ok(serviceMap.Id);
|
||||
}
|
||||
|
||||
[HttpPut("{Id}")]
|
||||
[ProducesResponseType(204)]
|
||||
[ProducesResponseType(400)]
|
||||
[ProducesResponseType(404)]
|
||||
public IActionResult EditServiceById(Guid Id, [FromBody] EditServiceDto service)
|
||||
{
|
||||
if (service == null)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
if (!_serviceInterface.CheckServiceById(Id))
|
||||
return NotFound();
|
||||
|
||||
if (!ModelState.IsValid)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
var serviceMap = _mapper.Map<ServiceModel>(service);
|
||||
serviceMap.Id = Id;
|
||||
|
||||
if (!_serviceInterface.EditServiceById(serviceMap))
|
||||
{
|
||||
ModelState.AddModelError("", "Something went wrong");
|
||||
return StatusCode(500, ModelState);
|
||||
}
|
||||
|
||||
return NoContent();
|
||||
}
|
||||
|
||||
[HttpDelete("{Id}")]
|
||||
[ProducesResponseType(204)]
|
||||
[ProducesResponseType(400)]
|
||||
[ProducesResponseType(404)]
|
||||
public IActionResult DeleteServiceById(Guid Id)
|
||||
{
|
||||
if (!_serviceInterface.CheckServiceById(Id))
|
||||
return NotFound();
|
||||
|
||||
if (!ModelState.IsValid)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
var service = _serviceInterface.GetServiceById(Id);
|
||||
|
||||
if (!_serviceInterface.DeleteServiceById(service))
|
||||
{
|
||||
ModelState.AddModelError("", "Something went wrong while deleting");
|
||||
return StatusCode(500, ModelState);
|
||||
}
|
||||
|
||||
return NoContent();
|
||||
}
|
||||
|
||||
[HttpGet("{Id}/RoleDefinitions")]
|
||||
[ProducesResponseType(200, Type = typeof(IEnumerable<ServiceRoleDefinitionModel>))]
|
||||
[ProducesResponseType(404)]
|
||||
public IActionResult GetRoleDefinitionsByServiceId(Guid Id)
|
||||
{
|
||||
if (!_serviceInterface.CheckServiceById(Id))
|
||||
return NotFound();
|
||||
|
||||
var roleDefinitions = _serviceInterface.GetRoleDefinitionsByServiceId(Id);
|
||||
return Ok(roleDefinitions);
|
||||
}
|
||||
|
||||
[HttpPost("{Id}/RoleDefinitions")]
|
||||
[ProducesResponseType(200)]
|
||||
[ProducesResponseType(400)]
|
||||
[ProducesResponseType(404)]
|
||||
public IActionResult AddRoleDefinition(Guid Id, [FromBody] AddServiceRoleDefinitionDto roleDefinition)
|
||||
{
|
||||
if (!_serviceInterface.CheckServiceById(Id))
|
||||
return NotFound();
|
||||
|
||||
if (roleDefinition == null)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
var service = _serviceInterface.GetServiceById(Id);
|
||||
if (service.IsCloudService)
|
||||
return BadRequest("Role definitions are not supported for cloud services.");
|
||||
|
||||
if (_serviceInterface.CheckRoleDefinitionKey(Id, roleDefinition.Key))
|
||||
return Conflict("Role key already exists for this service.");
|
||||
|
||||
var roleDefinitionModel = new ServiceRoleDefinitionModel
|
||||
{
|
||||
ServiceId = Id,
|
||||
Key = roleDefinition.Key,
|
||||
Name = roleDefinition.Name,
|
||||
Description = roleDefinition.Description
|
||||
};
|
||||
|
||||
if (!_serviceInterface.AddRoleDefinition(roleDefinitionModel))
|
||||
{
|
||||
ModelState.AddModelError("", "Something went wrong while saving role definition");
|
||||
return StatusCode(500, ModelState);
|
||||
}
|
||||
|
||||
return Ok(roleDefinitionModel.Id);
|
||||
}
|
||||
|
||||
[HttpPut("{Id}/RoleDefinitions/{RoleDefinitionId}")]
|
||||
[ProducesResponseType(204)]
|
||||
[ProducesResponseType(400)]
|
||||
[ProducesResponseType(404)]
|
||||
public IActionResult EditRoleDefinition(Guid Id, Guid RoleDefinitionId, [FromBody] EditServiceRoleDefinitionDto roleDefinition)
|
||||
{
|
||||
if (!_serviceInterface.CheckServiceById(Id))
|
||||
return NotFound();
|
||||
|
||||
if (!_serviceInterface.CheckRoleDefinitionById(RoleDefinitionId))
|
||||
return NotFound();
|
||||
|
||||
if (roleDefinition == null)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
var service = _serviceInterface.GetServiceById(Id);
|
||||
if (service.IsCloudService)
|
||||
return BadRequest("Role definitions are not supported for cloud services.");
|
||||
|
||||
if (_serviceInterface.CheckRoleDefinitionKey(Id, roleDefinition.Key, RoleDefinitionId))
|
||||
return Conflict("Role key already exists for this service.");
|
||||
|
||||
var roleDefinitionModel = _serviceInterface.GetRoleDefinitionById(RoleDefinitionId);
|
||||
if (roleDefinitionModel.ServiceId != Id)
|
||||
return BadRequest("Role definition does not belong to this service.");
|
||||
|
||||
roleDefinitionModel.Key = roleDefinition.Key;
|
||||
roleDefinitionModel.Name = roleDefinition.Name;
|
||||
roleDefinitionModel.Description = roleDefinition.Description;
|
||||
|
||||
if (!_serviceInterface.EditRoleDefinition(roleDefinitionModel))
|
||||
{
|
||||
ModelState.AddModelError("", "Something went wrong while updating role definition");
|
||||
return StatusCode(500, ModelState);
|
||||
}
|
||||
|
||||
return NoContent();
|
||||
}
|
||||
|
||||
[HttpDelete("{Id}/RoleDefinitions/{RoleDefinitionId}")]
|
||||
[ProducesResponseType(204)]
|
||||
[ProducesResponseType(404)]
|
||||
public IActionResult DeleteRoleDefinition(Guid Id, Guid RoleDefinitionId)
|
||||
{
|
||||
if (!_serviceInterface.CheckServiceById(Id))
|
||||
return NotFound();
|
||||
|
||||
if (!_serviceInterface.CheckRoleDefinitionById(RoleDefinitionId))
|
||||
return NotFound();
|
||||
|
||||
var roleDefinitionModel = _serviceInterface.GetRoleDefinitionById(RoleDefinitionId);
|
||||
if (roleDefinitionModel.ServiceId != Id)
|
||||
return BadRequest("Role definition does not belong to this service.");
|
||||
|
||||
if (!_serviceInterface.DeleteRoleDefinition(roleDefinitionModel))
|
||||
{
|
||||
ModelState.AddModelError("", "Something went wrong while deleting role definition");
|
||||
return StatusCode(500, ModelState);
|
||||
}
|
||||
|
||||
return NoContent();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
130
Controllers/TemplateCategoryController.cs
Normal file
130
Controllers/TemplateCategoryController.cs
Normal file
@@ -0,0 +1,130 @@
|
||||
using AutoMapper;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.TemplateCategory.Add;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.TemplateCategory.Edit;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.TemplateCategory.Get;
|
||||
using Microsoft.SelfService.Portal.Core.API.Interfaces;
|
||||
using Microsoft.SelfService.Portal.Core.API.Models;
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Controllers
|
||||
{
|
||||
[Route("api/[controller]")]
|
||||
[ApiController]
|
||||
public class TemplateCategoryController : Controller
|
||||
{
|
||||
private readonly IMapper _mapper;
|
||||
private readonly ITemplateCategoryInterface _templateCategoryInterface;
|
||||
|
||||
public TemplateCategoryController(IMapper mapper, ITemplateCategoryInterface templateCategoryInterface)
|
||||
{
|
||||
_mapper = mapper;
|
||||
_templateCategoryInterface = templateCategoryInterface;
|
||||
}
|
||||
|
||||
[HttpGet]
|
||||
[ProducesResponseType(200, Type = typeof(IEnumerable<TemplateCategoryModel>))]
|
||||
public IActionResult GetTemplateCategories()
|
||||
{
|
||||
var templateCategories = _mapper.Map<List<GetTemplateCategoryDto>>(_templateCategoryInterface.GetTemplateCategories());
|
||||
|
||||
if (!ModelState.IsValid)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
return Ok(templateCategories);
|
||||
}
|
||||
|
||||
[HttpGet("{Id}")]
|
||||
[ProducesResponseType(200, Type = typeof(TemplateCategoryModel))]
|
||||
[ProducesResponseType(404)]
|
||||
public IActionResult GetTemplateCategoryById(Guid Id)
|
||||
{
|
||||
if (!_templateCategoryInterface.CheckTemplateCategoryById(Id))
|
||||
return NotFound();
|
||||
|
||||
var templateCategory = _mapper.Map<GetTemplateCategoryDetailsDto>(_templateCategoryInterface.GetTemplateCategoryById(Id));
|
||||
|
||||
if (!ModelState.IsValid)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
return Ok(templateCategory);
|
||||
}
|
||||
|
||||
[HttpPost]
|
||||
[ProducesResponseType(200)]
|
||||
[ProducesResponseType(400)]
|
||||
public IActionResult AddTemplateCategoryById([FromBody] AddTemplateCategoryDto templateCategory)
|
||||
{
|
||||
if (templateCategory == null)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
if (_templateCategoryInterface.CheckTemplateCategoryByName(templateCategory.Name))
|
||||
{
|
||||
ModelState.AddModelError("", "TemplateCategory already exists");
|
||||
return StatusCode(422, ModelState);
|
||||
}
|
||||
|
||||
if (!ModelState.IsValid)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
var templateCategoryMap = _mapper.Map<TemplateCategoryModel>(templateCategory);
|
||||
|
||||
if (!_templateCategoryInterface.AddTemplateCategoryById(templateCategoryMap))
|
||||
{
|
||||
ModelState.AddModelError("", "Something went wrong while saving");
|
||||
return StatusCode(500, ModelState);
|
||||
}
|
||||
|
||||
return Ok(templateCategoryMap.Id);
|
||||
}
|
||||
|
||||
[HttpPut("{Id}")]
|
||||
[ProducesResponseType(204)]
|
||||
[ProducesResponseType(400)]
|
||||
[ProducesResponseType(404)]
|
||||
public IActionResult EditTemplateCategoryById(Guid Id, [FromBody] EditTemplateCategoryDto templateCategory)
|
||||
{
|
||||
if (templateCategory == null)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
if (!_templateCategoryInterface.CheckTemplateCategoryById(Id))
|
||||
return NotFound();
|
||||
|
||||
if (!ModelState.IsValid)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
var templateCategoryMap = _mapper.Map<TemplateCategoryModel>(templateCategory);
|
||||
templateCategoryMap.Id = Id;
|
||||
|
||||
if (!_templateCategoryInterface.EditTemplateCategoryById(templateCategoryMap))
|
||||
{
|
||||
ModelState.AddModelError("", "Something went wrong");
|
||||
return StatusCode(500, ModelState);
|
||||
}
|
||||
|
||||
return NoContent();
|
||||
}
|
||||
|
||||
[HttpDelete("{Id}")]
|
||||
[ProducesResponseType(204)]
|
||||
[ProducesResponseType(400)]
|
||||
[ProducesResponseType(404)]
|
||||
public IActionResult DeleteTemplateCategoryById(Guid Id)
|
||||
{
|
||||
if (!_templateCategoryInterface.CheckTemplateCategoryById(Id))
|
||||
return NotFound();
|
||||
|
||||
if (!ModelState.IsValid)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
var templateCategory = _templateCategoryInterface.GetTemplateCategoryById(Id);
|
||||
|
||||
if (!_templateCategoryInterface.DeleteTemplateCategoryById(templateCategory))
|
||||
{
|
||||
ModelState.AddModelError("", "Something went wrong while deleting");
|
||||
return StatusCode(500, ModelState);
|
||||
}
|
||||
|
||||
return NoContent();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,10 +1,10 @@
|
||||
using AutoMapper;
|
||||
using AutoMapper;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.Service.Get;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.Template.Add;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.Template.Edit;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.Template.Get;
|
||||
using Microsoft.SelfService.Portal.Core.API.Interfaces;
|
||||
using Microsoft.SelfService.Portal.Core.API.Models;
|
||||
using System.Reflection;
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Controllers
|
||||
{
|
||||
@@ -13,11 +13,16 @@ namespace Microsoft.SelfService.Portal.Core.API.Controllers
|
||||
public class TemplateController : Controller
|
||||
{
|
||||
private readonly ITemplateInterface _templateInterface;
|
||||
private readonly IQueueJobService _queueJobService;
|
||||
private readonly IMapper _mapper;
|
||||
|
||||
public TemplateController(ITemplateInterface templateInterface, IMapper mapper)
|
||||
public TemplateController(
|
||||
ITemplateInterface templateInterface,
|
||||
IQueueJobService queueJobService,
|
||||
IMapper mapper)
|
||||
{
|
||||
_templateInterface = templateInterface;
|
||||
_queueJobService = queueJobService;
|
||||
_mapper = mapper;
|
||||
}
|
||||
|
||||
@@ -35,6 +40,7 @@ namespace Microsoft.SelfService.Portal.Core.API.Controllers
|
||||
|
||||
[HttpGet("{Id}")]
|
||||
[ProducesResponseType(200, Type = typeof(TemplateModel))]
|
||||
[ProducesResponseType(404)]
|
||||
public IActionResult GetTemplateById(Guid Id)
|
||||
{
|
||||
if (!_templateInterface.CheckTemplateById(Id))
|
||||
@@ -47,5 +53,90 @@ namespace Microsoft.SelfService.Portal.Core.API.Controllers
|
||||
|
||||
return Ok(template);
|
||||
}
|
||||
|
||||
[HttpPost]
|
||||
[ProducesResponseType(200)]
|
||||
[ProducesResponseType(400)]
|
||||
public IActionResult AddTemplateById([FromBody] AddTemplateDto template)
|
||||
{
|
||||
if (template == null)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
if (_templateInterface.CheckTemplateByName(template.Name))
|
||||
{
|
||||
ModelState.AddModelError("", "Template already exists");
|
||||
return StatusCode(422, ModelState);
|
||||
}
|
||||
|
||||
if (!ModelState.IsValid)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
var templateMap = _mapper.Map<TemplateModel>(template);
|
||||
|
||||
if (!_templateInterface.AddTemplateById(templateMap))
|
||||
{
|
||||
ModelState.AddModelError("", "Something went wrong while saving");
|
||||
return StatusCode(500, ModelState);
|
||||
}
|
||||
|
||||
return Ok(templateMap.Id);
|
||||
}
|
||||
|
||||
[HttpPut("{Id}")]
|
||||
[ProducesResponseType(204)]
|
||||
[ProducesResponseType(400)]
|
||||
[ProducesResponseType(404)]
|
||||
public IActionResult EditTemplateById(Guid Id, [FromBody] EditTemplateDto template)
|
||||
{
|
||||
if (template == null)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
if (!_templateInterface.CheckTemplateById(Id))
|
||||
return NotFound();
|
||||
|
||||
var existingTemplate = _templateInterface.GetTemplateById(Id);
|
||||
|
||||
if (!ModelState.IsValid)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
var templateMap = _mapper.Map<TemplateModel>(template);
|
||||
templateMap.Id = Id;
|
||||
|
||||
if (!_templateInterface.EditTemplateById(templateMap))
|
||||
{
|
||||
ModelState.AddModelError("", "Something went wrong");
|
||||
return StatusCode(500, ModelState);
|
||||
}
|
||||
|
||||
if (!string.Equals(existingTemplate.JSONData, template.JSONData, StringComparison.Ordinal))
|
||||
{
|
||||
_queueJobService.EnqueueTemplateJsonChanged(Id, existingTemplate.JSONData, template.JSONData);
|
||||
}
|
||||
|
||||
return NoContent();
|
||||
}
|
||||
|
||||
[HttpDelete("{Id}")]
|
||||
[ProducesResponseType(204)]
|
||||
[ProducesResponseType(400)]
|
||||
[ProducesResponseType(404)]
|
||||
public IActionResult DeleteTemplateById(Guid Id)
|
||||
{
|
||||
if (!_templateInterface.CheckTemplateById(Id))
|
||||
return NotFound();
|
||||
|
||||
if (!ModelState.IsValid)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
var template = _templateInterface.GetTemplateById(Id);
|
||||
|
||||
if (!_templateInterface.DeleteTemplateById(template))
|
||||
{
|
||||
ModelState.AddModelError("", "Something went wrong while deleting");
|
||||
return StatusCode(500, ModelState);
|
||||
}
|
||||
|
||||
return NoContent();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
using AutoMapper;
|
||||
using AutoMapper;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.VirtualMachine.Add;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.VirtualMachine.Edit;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.VirtualMachine.Get;
|
||||
using Microsoft.SelfService.Portal.Core.API.Interfaces;
|
||||
using Microsoft.SelfService.Portal.Core.API.Models;
|
||||
@@ -9,13 +11,15 @@ namespace Microsoft.SelfService.Portal.Core.API.Controllers
|
||||
[Route("api/[controller]")]
|
||||
[ApiController]
|
||||
public class VirtualMachineController : Controller
|
||||
{
|
||||
{
|
||||
private readonly IVirtualMachineInterface _virtualmachineInterface;
|
||||
private readonly IDomainInterface _domainInterface;
|
||||
private readonly IMapper _mapper;
|
||||
|
||||
public VirtualMachineController(IVirtualMachineInterface virtualmachineInterface, IMapper mapper)
|
||||
public VirtualMachineController(IVirtualMachineInterface virtualmachineInterface, IDomainInterface domainInterface, IMapper mapper)
|
||||
{
|
||||
_virtualmachineInterface = virtualmachineInterface;
|
||||
_domainInterface = domainInterface;
|
||||
_mapper = mapper;
|
||||
}
|
||||
|
||||
@@ -23,12 +27,12 @@ namespace Microsoft.SelfService.Portal.Core.API.Controllers
|
||||
[ProducesResponseType(200, Type = typeof(IEnumerable<VirtualMachineModel>))]
|
||||
public IActionResult GetVirtualMachines()
|
||||
{
|
||||
var virtualmachines = _mapper.Map<List<GetVirtualMachineDto>>(_virtualmachineInterface.GetVirtualMachines());
|
||||
var virtualMachines = _mapper.Map<List<GetVirtualMachineDto>>(_virtualmachineInterface.GetVirtualMachines());
|
||||
|
||||
if (!ModelState.IsValid)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
return Ok(virtualmachines);
|
||||
return Ok(virtualMachines);
|
||||
}
|
||||
|
||||
[HttpGet("{Id}")]
|
||||
@@ -36,16 +40,161 @@ namespace Microsoft.SelfService.Portal.Core.API.Controllers
|
||||
[ProducesResponseType(400)]
|
||||
public IActionResult GetVirtualMachineById(Guid Id)
|
||||
{
|
||||
if (!_virtualmachineInterface.CheckVirtualMachineById(Id))
|
||||
return NotFound();
|
||||
|
||||
var virtualMachine = _mapper.Map<GetVirtualMachineDetailsDto>(_virtualmachineInterface.GetVirtualMachineById(Id));
|
||||
|
||||
if (!ModelState.IsValid)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
return Ok(virtualMachine);
|
||||
}
|
||||
|
||||
[HttpPost]
|
||||
[ProducesResponseType(200)]
|
||||
[ProducesResponseType(400)]
|
||||
public IActionResult AddVirtualMachineById([FromBody] AddVirtualMachineDto virtualMachine)
|
||||
{
|
||||
if (virtualMachine == null)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
if (_virtualmachineInterface.CheckVirtualMachineByName(virtualMachine.Name))
|
||||
{
|
||||
ModelState.AddModelError("", "VirtualMachine already exists");
|
||||
return StatusCode(422, ModelState);
|
||||
}
|
||||
|
||||
if (virtualMachine.DomainID.HasValue && !_domainInterface.CheckDomainById(virtualMachine.DomainID.Value))
|
||||
{
|
||||
ModelState.AddModelError("", "Domain does not exist");
|
||||
return BadRequest(ModelState);
|
||||
}
|
||||
|
||||
if (!ModelState.IsValid)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
var virtualMachineMap = _mapper.Map<VirtualMachineModel>(virtualMachine);
|
||||
|
||||
if (!_virtualmachineInterface.AddVirtualMachineById(virtualMachineMap))
|
||||
{
|
||||
ModelState.AddModelError("", "Something went wrong while saving");
|
||||
return StatusCode(500, ModelState);
|
||||
}
|
||||
|
||||
return Ok(virtualMachineMap.Id);
|
||||
}
|
||||
|
||||
[HttpPut("{Id}")]
|
||||
[ProducesResponseType(204)]
|
||||
[ProducesResponseType(400)]
|
||||
[ProducesResponseType(404)]
|
||||
public IActionResult EditVirtualMachineById(Guid Id, [FromBody] EditVirtualMachineDto virtualMachine)
|
||||
{
|
||||
if (virtualMachine == null)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
if (!_virtualmachineInterface.CheckVirtualMachineById(Id))
|
||||
return NotFound();
|
||||
|
||||
var virtualmachines = _mapper.Map<GetVirtualMachineDetailsDto>(_virtualmachineInterface.GetVirtualMachineById(Id));
|
||||
|
||||
if(!ModelState.IsValid)
|
||||
if (!ModelState.IsValid)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
return Ok(virtualmachines);
|
||||
var existingVirtualMachine = _virtualmachineInterface.GetVirtualMachineById(Id);
|
||||
if (existingVirtualMachine == null)
|
||||
return NotFound();
|
||||
|
||||
existingVirtualMachine.Name = virtualMachine.Name;
|
||||
existingVirtualMachine.ExternalId = virtualMachine.ExternalId;
|
||||
existingVirtualMachine.MetadataJson = virtualMachine.MetadataJson;
|
||||
|
||||
if (!_virtualmachineInterface.EditVirtualMachineById(existingVirtualMachine))
|
||||
{
|
||||
ModelState.AddModelError("", "Something went wrong");
|
||||
return StatusCode(500, ModelState);
|
||||
}
|
||||
|
||||
return NoContent();
|
||||
}
|
||||
|
||||
[HttpPost("{Id}/Domain/{domainId}")]
|
||||
[ProducesResponseType(204)]
|
||||
[ProducesResponseType(400)]
|
||||
[ProducesResponseType(404)]
|
||||
[ProducesResponseType(409)]
|
||||
public IActionResult LinkVirtualMachineToDomain(Guid Id, Guid domainId)
|
||||
{
|
||||
if (!_virtualmachineInterface.CheckVirtualMachineById(Id))
|
||||
return NotFound();
|
||||
|
||||
if (!_domainInterface.CheckDomainById(domainId))
|
||||
return NotFound();
|
||||
|
||||
var existingVirtualMachine = _virtualmachineInterface.GetVirtualMachineById(Id);
|
||||
if (existingVirtualMachine == null)
|
||||
return NotFound();
|
||||
|
||||
if (existingVirtualMachine.DomainID.HasValue)
|
||||
return Conflict("VirtualMachine is already linked to a domain. Unlink it first.");
|
||||
|
||||
existingVirtualMachine.DomainID = domainId;
|
||||
|
||||
if (!_virtualmachineInterface.EditVirtualMachineById(existingVirtualMachine))
|
||||
{
|
||||
ModelState.AddModelError("", "Something went wrong");
|
||||
return StatusCode(500, ModelState);
|
||||
}
|
||||
|
||||
return NoContent();
|
||||
}
|
||||
|
||||
[HttpDelete("{Id}/Domain")]
|
||||
[ProducesResponseType(204)]
|
||||
[ProducesResponseType(404)]
|
||||
public IActionResult UnlinkVirtualMachineFromDomain(Guid Id)
|
||||
{
|
||||
if (!_virtualmachineInterface.CheckVirtualMachineById(Id))
|
||||
return NotFound();
|
||||
|
||||
var existingVirtualMachine = _virtualmachineInterface.GetVirtualMachineById(Id);
|
||||
if (existingVirtualMachine == null)
|
||||
return NotFound();
|
||||
|
||||
if (!existingVirtualMachine.DomainID.HasValue)
|
||||
return NoContent();
|
||||
|
||||
existingVirtualMachine.DomainID = null;
|
||||
|
||||
if (!_virtualmachineInterface.EditVirtualMachineById(existingVirtualMachine))
|
||||
{
|
||||
ModelState.AddModelError("", "Something went wrong");
|
||||
return StatusCode(500, ModelState);
|
||||
}
|
||||
|
||||
return NoContent();
|
||||
}
|
||||
|
||||
[HttpDelete("{Id}")]
|
||||
[ProducesResponseType(204)]
|
||||
[ProducesResponseType(400)]
|
||||
[ProducesResponseType(404)]
|
||||
public IActionResult DeleteVirtualMachineById(Guid Id)
|
||||
{
|
||||
if (!_virtualmachineInterface.CheckVirtualMachineById(Id))
|
||||
return NotFound();
|
||||
|
||||
if (!ModelState.IsValid)
|
||||
return BadRequest(ModelState);
|
||||
|
||||
var virtualMachine = _virtualmachineInterface.GetVirtualMachineById(Id);
|
||||
|
||||
if (!_virtualmachineInterface.DeleteVirtualMachineById(virtualMachine))
|
||||
{
|
||||
ModelState.AddModelError("", "Something went wrong while deleting");
|
||||
return StatusCode(500, ModelState);
|
||||
}
|
||||
|
||||
return NoContent();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -14,7 +14,7 @@ namespace Microsoft.SelfService.Portal.Core.API.Dto
|
||||
[Column(Order = 51)]
|
||||
[DefaultValue("CCIS-P01S01-CM\\ASA_SSP_Admin")]
|
||||
//[DatabaseGenerated(DatabaseGeneratedOption.Computed)]
|
||||
public string ModifiedBy { get; set; } = new HttpContextAccessor().HttpContext.User.Identity.Name;
|
||||
public string ModifiedBy { get; set; } = "System";
|
||||
|
||||
[Column(Order = 52)]
|
||||
[DefaultValueSql("GETDATE()")]
|
||||
@@ -24,6 +24,6 @@ namespace Microsoft.SelfService.Portal.Core.API.Dto
|
||||
[Column(Order = 53)]
|
||||
[DefaultValue("CCIS-P01S01-CM\\ASA_SSP_Admin")]
|
||||
//[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
||||
public string CreatedBy { get; set; } = new HttpContextAccessor().HttpContext.User.Identity.Name;
|
||||
public string CreatedBy { get; set; } = "System";
|
||||
}
|
||||
}
|
||||
|
||||
9
Dto/Deployment/Add/AddDeploymentRequestDto.cs
Normal file
9
Dto/Deployment/Add/AddDeploymentRequestDto.cs
Normal file
@@ -0,0 +1,9 @@
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Dto.Deployment.Add
|
||||
{
|
||||
public class AddDeploymentRequestDto
|
||||
{
|
||||
public Guid DeploymentGroupId { get; set; }
|
||||
public ICollection<Guid> VirtualMachineIds { get; set; } = new List<Guid>();
|
||||
public string JsonData { get; set; } = "{}";
|
||||
}
|
||||
}
|
||||
8
Dto/Deployment/Add/QueueJobStepApprovalDto.cs
Normal file
8
Dto/Deployment/Add/QueueJobStepApprovalDto.cs
Normal file
@@ -0,0 +1,8 @@
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Dto.Deployment.Add
|
||||
{
|
||||
public class QueueJobStepApprovalDto
|
||||
{
|
||||
public string? Comment { get; set; }
|
||||
public string? ApprovedBy { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,16 +1,13 @@
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.DeploymentGroup.Get;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.VirtualMachine.Get;
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Dto.Deployment.Get
|
||||
{
|
||||
public class GetDeploymentDetailsDto : BaseDetailsDto
|
||||
{
|
||||
public Guid VirtualMachineId { get; set; }
|
||||
public string Status { get; set; }
|
||||
public string JSONData { get; set; }
|
||||
|
||||
public GetVirtualMachineDetailsDto VirtualMachine { get; set; }
|
||||
|
||||
public GetDeploymentGroupDetailsDto DeploymentGroup { get; set; }
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -4,7 +4,9 @@ namespace Microsoft.SelfService.Portal.Core.API.Dto.Deployment.Get
|
||||
{
|
||||
public class GetDeploymentDto : BaseDto
|
||||
{
|
||||
|
||||
public Guid DeploymentGroupId { get; set; }
|
||||
public Guid VirtualMachineId { get; set; }
|
||||
public string Status { get; set; }
|
||||
public string JSONData { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
18
Dto/Deployment/Get/GetQueueJobDetailsDto.cs
Normal file
18
Dto/Deployment/Get/GetQueueJobDetailsDto.cs
Normal file
@@ -0,0 +1,18 @@
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Dto.Deployment.Get
|
||||
{
|
||||
public class GetQueueJobDetailsDto : BaseDetailsDto
|
||||
{
|
||||
public string Type { get; set; } = string.Empty;
|
||||
public string Status { get; set; } = string.Empty;
|
||||
public string PayloadJson { get; set; } = string.Empty;
|
||||
public int Attempts { get; set; }
|
||||
public int MaxAttempts { get; set; }
|
||||
public DateTime? Started { get; set; }
|
||||
public DateTime? Finished { get; set; }
|
||||
public string? ErrorMessage { get; set; }
|
||||
public string? MetadataJson { get; set; }
|
||||
public string? RuleSnapshotJson { get; set; }
|
||||
public ICollection<GetQueueJobTargetDto> Targets { get; set; } = new List<GetQueueJobTargetDto>();
|
||||
public ICollection<GetQueueJobStepDto> Steps { get; set; } = new List<GetQueueJobStepDto>();
|
||||
}
|
||||
}
|
||||
16
Dto/Deployment/Get/GetQueueJobDto.cs
Normal file
16
Dto/Deployment/Get/GetQueueJobDto.cs
Normal file
@@ -0,0 +1,16 @@
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Dto.Deployment.Get
|
||||
{
|
||||
public class GetQueueJobDto : BaseDto
|
||||
{
|
||||
public string Type { get; set; } = string.Empty;
|
||||
public string Status { get; set; } = string.Empty;
|
||||
public int Attempts { get; set; }
|
||||
public int MaxAttempts { get; set; }
|
||||
public DateTime? Started { get; set; }
|
||||
public DateTime? Finished { get; set; }
|
||||
public string? ErrorMessage { get; set; }
|
||||
public int TargetCount { get; set; }
|
||||
public int SucceededTargetCount { get; set; }
|
||||
public int FailedTargetCount { get; set; }
|
||||
}
|
||||
}
|
||||
15
Dto/Deployment/Get/GetQueueJobStepDto.cs
Normal file
15
Dto/Deployment/Get/GetQueueJobStepDto.cs
Normal file
@@ -0,0 +1,15 @@
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Dto.Deployment.Get
|
||||
{
|
||||
public class GetQueueJobStepDto : BaseDto
|
||||
{
|
||||
public Guid? DependsOnQueueJobStepId { get; set; }
|
||||
public int SortOrder { get; set; }
|
||||
public string Name { get; set; } = string.Empty;
|
||||
public string StepType { get; set; } = string.Empty;
|
||||
public string Status { get; set; } = string.Empty;
|
||||
public string? MetadataJson { get; set; }
|
||||
public DateTime? ApprovedAt { get; set; }
|
||||
public string? ApprovedBy { get; set; }
|
||||
public string? ApprovalComment { get; set; }
|
||||
}
|
||||
}
|
||||
12
Dto/Deployment/Get/GetQueueJobTargetDto.cs
Normal file
12
Dto/Deployment/Get/GetQueueJobTargetDto.cs
Normal file
@@ -0,0 +1,12 @@
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Dto.Deployment.Get
|
||||
{
|
||||
public class GetQueueJobTargetDto : BaseDto
|
||||
{
|
||||
public Guid VirtualMachineId { get; set; }
|
||||
public Guid DeploymentGroupId { get; set; }
|
||||
public Guid TemplateId { get; set; }
|
||||
public string Status { get; set; } = string.Empty;
|
||||
public int Attempts { get; set; }
|
||||
public string? ErrorMessage { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -8,7 +8,8 @@ namespace Microsoft.SelfService.Portal.Core.API.Dto.DeploymentGroup.Add
|
||||
public Guid TemplateId { get; set; }
|
||||
[Column(Order = 2)]
|
||||
public string Status { get; set; }
|
||||
|
||||
[Column(Order = 3)]
|
||||
public ICollection<Guid>? VirtualMachineIds { get; set; }
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -6,5 +6,20 @@ namespace Microsoft.SelfService.Portal.Core.API.Dto.Environment.Add
|
||||
{
|
||||
[Column(Order = 1)]
|
||||
public string Name { get; set; }
|
||||
|
||||
[Column(Order = 2)]
|
||||
public string EnvironmentType { get; set; } = "OnPrem";
|
||||
|
||||
[Column(Order = 3)]
|
||||
public string? ProviderType { get; set; }
|
||||
|
||||
[Column(Order = 4)]
|
||||
public string? TenantId { get; set; }
|
||||
|
||||
[Column(Order = 5)]
|
||||
public string? SubscriptionId { get; set; }
|
||||
|
||||
[Column(Order = 6)]
|
||||
public string? MetadataJson { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -6,5 +6,20 @@ namespace Microsoft.SelfService.Portal.Core.API.Dto.Environment.Edit
|
||||
{
|
||||
[Column(Order = 1)]
|
||||
public string Name { get; set; }
|
||||
|
||||
[Column(Order = 2)]
|
||||
public string EnvironmentType { get; set; } = "OnPrem";
|
||||
|
||||
[Column(Order = 3)]
|
||||
public string? ProviderType { get; set; }
|
||||
|
||||
[Column(Order = 4)]
|
||||
public string? TenantId { get; set; }
|
||||
|
||||
[Column(Order = 5)]
|
||||
public string? SubscriptionId { get; set; }
|
||||
|
||||
[Column(Order = 6)]
|
||||
public string? MetadataJson { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -6,5 +6,20 @@ namespace Microsoft.SelfService.Portal.Core.API.Dto.Environment.Get
|
||||
{
|
||||
[Column(Order = 1)]
|
||||
public string Name { get; set; }
|
||||
|
||||
[Column(Order = 2)]
|
||||
public string EnvironmentType { get; set; }
|
||||
|
||||
[Column(Order = 3)]
|
||||
public string? ProviderType { get; set; }
|
||||
|
||||
[Column(Order = 4)]
|
||||
public string? TenantId { get; set; }
|
||||
|
||||
[Column(Order = 5)]
|
||||
public string? SubscriptionId { get; set; }
|
||||
|
||||
[Column(Order = 6)]
|
||||
public string? MetadataJson { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,11 +1,34 @@
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.Domain.Get;
|
||||
using Microsoft.SelfService.Portal.Core.API.Models;
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Dto.Environment.Get
|
||||
{
|
||||
public class GetEnvironmentDomainDetailsDto : BaseDetailsDto
|
||||
{
|
||||
|
||||
[Column(Order = 1)]
|
||||
public ICollection<GetEnvironmentDetailsDto> Environment { get; set; }
|
||||
public GetDomainDetailsDto Domain { get; set; }
|
||||
|
||||
public static GetEnvironmentDomainDetailsDto FromModel(EnvironmentDomainsModel environmentDomain)
|
||||
{
|
||||
return new GetEnvironmentDomainDetailsDto
|
||||
{
|
||||
Created = environmentDomain.Created,
|
||||
CreatedBy = environmentDomain.CreatedBy,
|
||||
Modified = environmentDomain.Modified,
|
||||
ModifiedBy = environmentDomain.ModifiedBy,
|
||||
Domain = new GetDomainDetailsDto
|
||||
{
|
||||
Id = environmentDomain.Domain.Id,
|
||||
Name = environmentDomain.Domain.Name,
|
||||
FQDN = environmentDomain.Domain.FQDN,
|
||||
NetBIOS = environmentDomain.Domain.NetBIOS,
|
||||
Created = environmentDomain.Domain.Created,
|
||||
CreatedBy = environmentDomain.Domain.CreatedBy,
|
||||
Modified = environmentDomain.Domain.Modified,
|
||||
ModifiedBy = environmentDomain.Domain.ModifiedBy
|
||||
}
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.Domain.Get;
|
||||
using Microsoft.SelfService.Portal.Core.API.Models;
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Dto.Environment.Get
|
||||
@@ -7,8 +7,25 @@ namespace Microsoft.SelfService.Portal.Core.API.Dto.Environment.Get
|
||||
{
|
||||
[Column(Order = 1)]
|
||||
public string Name { get; set; }
|
||||
|
||||
[Column(Order = 2)]
|
||||
public ICollection<GetEnvironmentDomainDetailsDto> EnvironmentDomains { get; set; }
|
||||
}
|
||||
|
||||
public static GetEnvironmentDomainDto FromModel(EnvironmentModel environment)
|
||||
{
|
||||
return new GetEnvironmentDomainDto
|
||||
{
|
||||
Id = environment.Id,
|
||||
Name = environment.Name,
|
||||
Created = environment.Created,
|
||||
CreatedBy = environment.CreatedBy,
|
||||
Modified = environment.Modified,
|
||||
ModifiedBy = environment.ModifiedBy,
|
||||
EnvironmentDomains = environment.EnvironmentDomains?
|
||||
.Where(environmentDomain => environmentDomain.Domain != null)
|
||||
.Select(GetEnvironmentDomainDetailsDto.FromModel)
|
||||
.ToList() ?? new List<GetEnvironmentDomainDetailsDto>()
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -6,5 +6,17 @@ namespace Microsoft.SelfService.Portal.Core.API.Dto.Environment.Get
|
||||
{
|
||||
[Column(Order = 1)]
|
||||
public string Name { get; set; }
|
||||
|
||||
[Column(Order = 2)]
|
||||
public string EnvironmentType { get; set; }
|
||||
|
||||
[Column(Order = 3)]
|
||||
public string? ProviderType { get; set; }
|
||||
|
||||
[Column(Order = 4)]
|
||||
public string? TenantId { get; set; }
|
||||
|
||||
[Column(Order = 5)]
|
||||
public string? SubscriptionId { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
19
Dto/Service/Add/AddServiceDto.cs
Normal file
19
Dto/Service/Add/AddServiceDto.cs
Normal file
@@ -0,0 +1,19 @@
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Dto.Service.Add
|
||||
{
|
||||
public class AddServiceDto
|
||||
{
|
||||
[Column(Order = 1)]
|
||||
public string Name { get; set; }
|
||||
|
||||
[Column(Order = 2)]
|
||||
public string Description { get; set; }
|
||||
|
||||
[Column(Order = 3)]
|
||||
public bool IsCloudService { get; set; }
|
||||
|
||||
[Column(Order = 4)]
|
||||
public string? IconKey { get; set; }
|
||||
}
|
||||
}
|
||||
19
Dto/Service/Edit/EditServiceDto.cs
Normal file
19
Dto/Service/Edit/EditServiceDto.cs
Normal file
@@ -0,0 +1,19 @@
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Dto.Service.Edit
|
||||
{
|
||||
public class EditServiceDto
|
||||
{
|
||||
[Column(Order = 1)]
|
||||
public string Name { get; set; }
|
||||
|
||||
[Column(Order = 2)]
|
||||
public string Description { get; set; }
|
||||
|
||||
[Column(Order = 3)]
|
||||
public bool IsCloudService { get; set; }
|
||||
|
||||
[Column(Order = 4)]
|
||||
public string? IconKey { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -7,6 +7,10 @@ namespace Microsoft.SelfService.Portal.Core.API.Dto.Service.Get
|
||||
[Column(Order = 1)]
|
||||
public string Name { get; set; }
|
||||
[Column(Order = 2)]
|
||||
public string Type { get; set; }
|
||||
public string Description { get; set; }
|
||||
[Column(Order = 3)]
|
||||
public bool IsCloudService { get; set; }
|
||||
[Column(Order = 4)]
|
||||
public string? IconKey { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -6,5 +6,14 @@ namespace Microsoft.SelfService.Portal.Core.API.Dto.Service.Get
|
||||
{
|
||||
[Column(Order = 1)]
|
||||
public string Name { get; set; }
|
||||
|
||||
[Column(Order = 2)]
|
||||
public string Description { get; set; }
|
||||
|
||||
[Column(Order = 3)]
|
||||
public bool IsCloudService { get; set; }
|
||||
|
||||
[Column(Order = 4)]
|
||||
public string? IconKey { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Dto.Service.RoleDefinition
|
||||
{
|
||||
public class AddServiceRoleDefinitionDto
|
||||
{
|
||||
public string Key { get; set; } = string.Empty;
|
||||
public string Name { get; set; } = string.Empty;
|
||||
public string? Description { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Dto.Service.RoleDefinition
|
||||
{
|
||||
public class EditServiceRoleDefinitionDto
|
||||
{
|
||||
public string Key { get; set; } = string.Empty;
|
||||
public string Name { get; set; } = string.Empty;
|
||||
public string? Description { get; set; }
|
||||
}
|
||||
}
|
||||
22
Dto/Template/Add/AddTemplateDto.cs
Normal file
22
Dto/Template/Add/AddTemplateDto.cs
Normal file
@@ -0,0 +1,22 @@
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Dto.Template.Add
|
||||
{
|
||||
public class AddTemplateDto
|
||||
{
|
||||
[Column(Order = 1)]
|
||||
public Guid TemplateCategoryId { get; set; }
|
||||
|
||||
[Column(Order = 2)]
|
||||
public string Name { get; set; }
|
||||
|
||||
[Column(Order = 3)]
|
||||
public string Version { get; set; }
|
||||
|
||||
[Column(Order = 4)]
|
||||
public string Description { get; set; }
|
||||
|
||||
[Column(Order = 5)]
|
||||
public string JSONData { get; set; }
|
||||
}
|
||||
}
|
||||
22
Dto/Template/Edit/EditTemplateDto.cs
Normal file
22
Dto/Template/Edit/EditTemplateDto.cs
Normal file
@@ -0,0 +1,22 @@
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Dto.Template.Edit
|
||||
{
|
||||
public class EditTemplateDto
|
||||
{
|
||||
[Column(Order = 1)]
|
||||
public Guid TemplateCategoryId { get; set; }
|
||||
|
||||
[Column(Order = 2)]
|
||||
public string Name { get; set; }
|
||||
|
||||
[Column(Order = 3)]
|
||||
public string Version { get; set; }
|
||||
|
||||
[Column(Order = 4)]
|
||||
public string Description { get; set; }
|
||||
|
||||
[Column(Order = 5)]
|
||||
public string JSONData { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -3,7 +3,7 @@
|
||||
public class GetTemplateDetailsDto : BaseDetailsDto
|
||||
{
|
||||
public string Name { get; set; }
|
||||
public string CloudTemplate { get; set; }
|
||||
public Guid TemplateCategoryId { get; set; }
|
||||
public string Version { get; set; }
|
||||
public string Description { get; set; }
|
||||
public string JSONData { get; set; }
|
||||
|
||||
@@ -3,6 +3,9 @@
|
||||
public class GetTemplateDto : BaseDto
|
||||
{
|
||||
public string Name { get; set; }
|
||||
|
||||
public Guid TemplateCategoryId { get; set; }
|
||||
public string Version { get; set; }
|
||||
public string Description { get; set; }
|
||||
public string JSONData { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
11
Dto/TemplateCategory/Add/AddTemplateCategoryDto.cs
Normal file
11
Dto/TemplateCategory/Add/AddTemplateCategoryDto.cs
Normal file
@@ -0,0 +1,11 @@
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Dto.TemplateCategory.Add
|
||||
{
|
||||
public class AddTemplateCategoryDto
|
||||
{
|
||||
public Guid ServiceId { get; set; }
|
||||
public string Name { get; set; } = string.Empty;
|
||||
public string? Description { get; set; }
|
||||
public bool IsActive { get; set; } = true;
|
||||
public string? Color { get; set; }
|
||||
}
|
||||
}
|
||||
11
Dto/TemplateCategory/Edit/EditTemplateCategoryDto.cs
Normal file
11
Dto/TemplateCategory/Edit/EditTemplateCategoryDto.cs
Normal file
@@ -0,0 +1,11 @@
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Dto.TemplateCategory.Edit
|
||||
{
|
||||
public class EditTemplateCategoryDto
|
||||
{
|
||||
public Guid ServiceId { get; set; }
|
||||
public string Name { get; set; } = string.Empty;
|
||||
public string? Description { get; set; }
|
||||
public bool IsActive { get; set; } = true;
|
||||
public string? Color { get; set; }
|
||||
}
|
||||
}
|
||||
11
Dto/TemplateCategory/Get/GetTemplateCategoryDetailsDto.cs
Normal file
11
Dto/TemplateCategory/Get/GetTemplateCategoryDetailsDto.cs
Normal file
@@ -0,0 +1,11 @@
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Dto.TemplateCategory.Get
|
||||
{
|
||||
public class GetTemplateCategoryDetailsDto : BaseDetailsDto
|
||||
{
|
||||
public Guid ServiceId { get; set; }
|
||||
public string Name { get; set; } = string.Empty;
|
||||
public string? Description { get; set; }
|
||||
public bool IsActive { get; set; }
|
||||
public string? Color { get; set; }
|
||||
}
|
||||
}
|
||||
11
Dto/TemplateCategory/Get/GetTemplateCategoryDto.cs
Normal file
11
Dto/TemplateCategory/Get/GetTemplateCategoryDto.cs
Normal file
@@ -0,0 +1,11 @@
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Dto.TemplateCategory.Get
|
||||
{
|
||||
public class GetTemplateCategoryDto : BaseDto
|
||||
{
|
||||
public Guid ServiceId { get; set; }
|
||||
public string Name { get; set; } = string.Empty;
|
||||
public string? Description { get; set; }
|
||||
public bool IsActive { get; set; }
|
||||
public string? Color { get; set; }
|
||||
}
|
||||
}
|
||||
10
Dto/VirtualMachine/Add/AddVirtualMachineDto.cs
Normal file
10
Dto/VirtualMachine/Add/AddVirtualMachineDto.cs
Normal file
@@ -0,0 +1,10 @@
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Dto.VirtualMachine.Add
|
||||
{
|
||||
public class AddVirtualMachineDto
|
||||
{
|
||||
public Guid? DomainID { get; set; }
|
||||
public string Name { get; set; }
|
||||
public string? ExternalId { get; set; }
|
||||
public string? MetadataJson { get; set; }
|
||||
}
|
||||
}
|
||||
9
Dto/VirtualMachine/Edit/EditVirtualMachineDto.cs
Normal file
9
Dto/VirtualMachine/Edit/EditVirtualMachineDto.cs
Normal file
@@ -0,0 +1,9 @@
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Dto.VirtualMachine.Edit
|
||||
{
|
||||
public class EditVirtualMachineDto
|
||||
{
|
||||
public string Name { get; set; }
|
||||
public string? ExternalId { get; set; }
|
||||
public string? MetadataJson { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -8,8 +8,17 @@ namespace Microsoft.SelfService.Portal.Core.API.Dto.VirtualMachine.Get
|
||||
{
|
||||
|
||||
[Column(Order = 1)]
|
||||
public Guid? DomainID { get; set; }
|
||||
|
||||
[Column(Order = 2)]
|
||||
public string Name { get; set; }
|
||||
|
||||
public GetDomainDto Domain { get; set; }
|
||||
[Column(Order = 3)]
|
||||
public string? ExternalId { get; set; }
|
||||
|
||||
[Column(Order = 4)]
|
||||
public string? MetadataJson { get; set; }
|
||||
|
||||
public GetDomainDto? Domain { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5,7 +5,13 @@ namespace Microsoft.SelfService.Portal.Core.API.Dto.VirtualMachine.Get
|
||||
public class GetVirtualMachineDto : BaseDto
|
||||
{
|
||||
[Column(Order = 1)]
|
||||
public Guid? DomainID { get; set; }
|
||||
|
||||
[Column(Order = 2)]
|
||||
public string Name { get; set; }
|
||||
|
||||
[Column(Order = 3)]
|
||||
public string? ExternalId { get; set; }
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -7,6 +7,8 @@ using Microsoft.SelfService.Portal.Core.API.Dto.Runbook.Get;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.Runbook.Add;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.Environment.Get;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.VirtualMachine.Get;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.VirtualMachine.Add;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.VirtualMachine.Edit;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.Domain.Edit;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.Environment.Add;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.Environment.Edit;
|
||||
@@ -16,7 +18,14 @@ using Microsoft.SelfService.Portal.Core.API.Dto.Deployment.Edit;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.DeploymentGroup.Get;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.DeploymentGroup.Add;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.Template.Get;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.Template.Add;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.Template.Edit;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.Service.Get;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.Service.Add;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.Service.Edit;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.TemplateCategory.Get;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.TemplateCategory.Add;
|
||||
using Microsoft.SelfService.Portal.Core.API.Dto.TemplateCategory.Edit;
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Helper
|
||||
{
|
||||
@@ -43,8 +52,8 @@ namespace Microsoft.SelfService.Portal.Core.API.Helper
|
||||
CreateMap<GetEnvironmentDto, EnvironmentModel>();
|
||||
CreateMap<EnvironmentModel, GetEnvironmentDetailsDto>();
|
||||
CreateMap<GetEnvironmentDetailsDto, EnvironmentModel>();
|
||||
CreateMap<EnvironmentModel, GetEnvironmentDomainDetailsDto>();
|
||||
CreateMap<GetEnvironmentDomainDetailsDto, EnvironmentModel>();
|
||||
CreateMap<EnvironmentModel, GetEnvironmentDomainDto>();
|
||||
CreateMap<GetEnvironmentDomainDto, EnvironmentModel>();
|
||||
CreateMap<EnvironmentModel, AddEnvironmentDto>();
|
||||
CreateMap<AddEnvironmentDto, EnvironmentModel>();
|
||||
CreateMap<EnvironmentModel, EditEnvironmentDto>();
|
||||
@@ -53,6 +62,8 @@ namespace Microsoft.SelfService.Portal.Core.API.Helper
|
||||
/** Environment Domain Model **/
|
||||
CreateMap<EnvironmentDomainsModel, GetDomainEnvironmentDetailsDto>();
|
||||
CreateMap<GetDomainEnvironmentDetailsDto, EnvironmentDomainsModel>();
|
||||
CreateMap<EnvironmentDomainsModel, GetEnvironmentDomainDetailsDto>();
|
||||
CreateMap<GetEnvironmentDomainDetailsDto, EnvironmentDomainsModel>();
|
||||
CreateMap<EnvironmentDomainsModel, AddEnvironmentDomainDto>();
|
||||
CreateMap<AddEnvironmentDomainDto, EnvironmentDomainsModel>();
|
||||
|
||||
@@ -61,6 +72,10 @@ namespace Microsoft.SelfService.Portal.Core.API.Helper
|
||||
CreateMap<GetVirtualMachineDto, VirtualMachineModel>();
|
||||
CreateMap<VirtualMachineModel, GetVirtualMachineDetailsDto>();
|
||||
CreateMap<GetVirtualMachineDetailsDto, VirtualMachineModel>();
|
||||
CreateMap<VirtualMachineModel, AddVirtualMachineDto>();
|
||||
CreateMap<AddVirtualMachineDto, VirtualMachineModel>();
|
||||
CreateMap<VirtualMachineModel, EditVirtualMachineDto>();
|
||||
CreateMap<EditVirtualMachineDto, VirtualMachineModel>();
|
||||
|
||||
/** Runbook Model **/
|
||||
CreateMap<RunbookModel, GetRunbookDto>();
|
||||
@@ -93,10 +108,30 @@ namespace Microsoft.SelfService.Portal.Core.API.Helper
|
||||
CreateMap<GetTemplateDto, TemplateModel>();
|
||||
CreateMap<TemplateModel, GetTemplateDetailsDto>();
|
||||
CreateMap<GetTemplateDetailsDto, TemplateModel>();
|
||||
CreateMap<TemplateModel, AddTemplateDto>();
|
||||
CreateMap<AddTemplateDto, TemplateModel>();
|
||||
CreateMap<TemplateModel, EditTemplateDto>();
|
||||
CreateMap<EditTemplateDto, TemplateModel>();
|
||||
|
||||
/** Service Model **/
|
||||
CreateMap<ServiceModel, GetServiceDto>();
|
||||
CreateMap<GetServiceDto, ServiceModel>();
|
||||
CreateMap<ServiceModel, GetServiceDetailsDto>();
|
||||
CreateMap<GetServiceDetailsDto, ServiceModel>();
|
||||
CreateMap<ServiceModel, AddServiceDto>();
|
||||
CreateMap<AddServiceDto, ServiceModel>();
|
||||
CreateMap<ServiceModel, EditServiceDto>();
|
||||
CreateMap<EditServiceDto, ServiceModel>();
|
||||
|
||||
/** Template Category Model **/
|
||||
CreateMap<TemplateCategoryModel, GetTemplateCategoryDto>();
|
||||
CreateMap<GetTemplateCategoryDto, TemplateCategoryModel>();
|
||||
CreateMap<TemplateCategoryModel, GetTemplateCategoryDetailsDto>();
|
||||
CreateMap<GetTemplateCategoryDetailsDto, TemplateCategoryModel>();
|
||||
CreateMap<TemplateCategoryModel, AddTemplateCategoryDto>();
|
||||
CreateMap<AddTemplateCategoryDto, TemplateCategoryModel>();
|
||||
CreateMap<TemplateCategoryModel, EditTemplateCategoryDto>();
|
||||
CreateMap<EditTemplateCategoryDto, TemplateCategoryModel>();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -7,7 +7,7 @@ namespace Microsoft.SelfService.Portal.Core.API.Interfaces
|
||||
ICollection<DeploymentGroupModel> GetDeploymentGroups();
|
||||
|
||||
DeploymentGroupModel GetDeploymentGroupById(Guid Id);
|
||||
bool AddDeploymentGroupById(DeploymentGroupModel deploymentgroup);
|
||||
bool AddDeploymentGroupById(DeploymentGroupModel deploymentgroup, ICollection<Guid>? virtualMachineIds);
|
||||
bool DeleteDeploymentGroupById(DeploymentGroupModel deploymentgroup);
|
||||
bool EditDeploymentGroupById(DeploymentGroupModel deploymentgroup);
|
||||
|
||||
|
||||
11
Interfaces/IQueueJobService.cs
Normal file
11
Interfaces/IQueueJobService.cs
Normal file
@@ -0,0 +1,11 @@
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Interfaces
|
||||
{
|
||||
public interface IQueueJobService
|
||||
{
|
||||
Guid EnqueueTemplateJsonChanged(Guid templateId, string oldJsonData, string newJsonData);
|
||||
Guid EnqueueDeploymentRequest(Guid deploymentGroupId, ICollection<Guid> virtualMachineIds, string jsonData);
|
||||
bool RetryQueueJob(Guid queueJobId);
|
||||
bool ApproveQueueJobStep(Guid queueJobStepId, string approvedBy, string? comment);
|
||||
bool RejectQueueJobStep(Guid queueJobStepId, string approvedBy, string? comment);
|
||||
}
|
||||
}
|
||||
@@ -5,12 +5,26 @@ namespace Microsoft.SelfService.Portal.Core.API.Interfaces
|
||||
public interface IServiceInterface
|
||||
{
|
||||
ICollection<ServiceModel> GetServices();
|
||||
|
||||
bool AddServiceById(ServiceModel service);
|
||||
bool EditServiceById(ServiceModel service);
|
||||
bool DeleteServiceById(ServiceModel service);
|
||||
|
||||
ServiceModel GetServiceById(Guid Id);
|
||||
bool CheckServiceById(Guid Id);
|
||||
|
||||
ServiceModel GetServiceByName(string Name);
|
||||
bool CheckServiceByName(string Name);
|
||||
|
||||
ICollection<ServiceRoleDefinitionModel> GetRoleDefinitionsByServiceId(Guid serviceId);
|
||||
ServiceRoleDefinitionModel GetRoleDefinitionById(Guid roleDefinitionId);
|
||||
bool AddRoleDefinition(ServiceRoleDefinitionModel roleDefinition);
|
||||
bool EditRoleDefinition(ServiceRoleDefinitionModel roleDefinition);
|
||||
bool DeleteRoleDefinition(ServiceRoleDefinitionModel roleDefinition);
|
||||
bool CheckRoleDefinitionById(Guid roleDefinitionId);
|
||||
bool CheckRoleDefinitionKey(Guid serviceId, string key, Guid? excludeRoleDefinitionId = null);
|
||||
|
||||
bool SaveChanges();
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
20
Interfaces/ITemplateCategoryInterface.cs
Normal file
20
Interfaces/ITemplateCategoryInterface.cs
Normal file
@@ -0,0 +1,20 @@
|
||||
using Microsoft.SelfService.Portal.Core.API.Models;
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Interfaces
|
||||
{
|
||||
public interface ITemplateCategoryInterface
|
||||
{
|
||||
ICollection<TemplateCategoryModel> GetTemplateCategories();
|
||||
|
||||
bool AddTemplateCategoryById(TemplateCategoryModel templateCategory);
|
||||
bool EditTemplateCategoryById(TemplateCategoryModel templateCategory);
|
||||
bool DeleteTemplateCategoryById(TemplateCategoryModel templateCategory);
|
||||
|
||||
TemplateCategoryModel GetTemplateCategoryById(Guid Id);
|
||||
|
||||
bool CheckTemplateCategoryById(Guid Id);
|
||||
TemplateCategoryModel GetTemplateCategoryByName(string Name);
|
||||
bool CheckTemplateCategoryByName(string Name);
|
||||
bool SaveChanges();
|
||||
}
|
||||
}
|
||||
@@ -6,8 +6,15 @@ namespace Microsoft.SelfService.Portal.Core.API.Interfaces
|
||||
{
|
||||
ICollection<TemplateModel> GetTemplates();
|
||||
|
||||
bool AddTemplateById(TemplateModel template);
|
||||
bool EditTemplateById(TemplateModel template);
|
||||
bool DeleteTemplateById(TemplateModel template);
|
||||
|
||||
TemplateModel GetTemplateById(Guid Id);
|
||||
|
||||
bool CheckTemplateById(Guid Id);
|
||||
TemplateModel GetTemplateByName(string Name);
|
||||
bool CheckTemplateByName(string Name);
|
||||
bool SaveChanges();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -6,10 +6,15 @@ namespace Microsoft.SelfService.Portal.Core.API.Interfaces
|
||||
public interface IVirtualMachineInterface
|
||||
{
|
||||
ICollection<VirtualMachineModel> GetVirtualMachines();
|
||||
bool AddVirtualMachineById(VirtualMachineModel virtualMachine);
|
||||
bool EditVirtualMachineById(VirtualMachineModel virtualMachine);
|
||||
bool DeleteVirtualMachineById(VirtualMachineModel virtualMachine);
|
||||
|
||||
VirtualMachineModel GetVirtualMachineById(Guid Id);
|
||||
VirtualMachineModel GetVirtualMachineByName(string Name);
|
||||
|
||||
bool CheckVirtualMachineById(Guid Id);
|
||||
bool CheckVirtualMachineByName(String Name);
|
||||
bool SaveChanges();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,26 +1,28 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk.Web">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net7.0</TargetFramework>
|
||||
<TargetFramework>net10.0</TargetFramework>
|
||||
<Nullable>enable</Nullable>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<UserSecretsId>9c90fee1-4576-4f20-be83-715728173b96</UserSecretsId>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="AutoMapper" Version="12.0.1" />
|
||||
<PackageReference Include="AutoMapper.Extensions.Microsoft.DependencyInjection" Version="12.0.1" />
|
||||
<PackageReference Include="Microsoft.AspNetCore.Authentication.Negotiate" Version="7.0.9" />
|
||||
<PackageReference Include="Microsoft.AspNetCore.Mvc.NewtonsoftJson" Version="7.0.9" />
|
||||
<PackageReference Include="Microsoft.AspNetCore.OpenApi" Version="7.0.9" />
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore" Version="7.0.9" />
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore.SqlServer" Version="7.0.9" />
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore.Tools" Version="7.0.9">
|
||||
<PackageReference Include="AutoMapper" Version="16.1.1" />
|
||||
<PackageReference Include="Microsoft.AspNetCore.Authentication.Negotiate" Version="10.0.8" />
|
||||
<PackageReference Include="Microsoft.AspNetCore.Mvc.NewtonsoftJson" Version="10.0.8" />
|
||||
<PackageReference Include="Microsoft.AspNetCore.OpenApi" Version="10.0.8" />
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore" Version="10.0.8" />
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore.Design" Version="10.0.8">
|
||||
<PrivateAssets>all</PrivateAssets>
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
</PackageReference>
|
||||
<PackageReference Include="Microsoft.VisualStudio.Web.CodeGeneration.Design" Version="7.0.8" />
|
||||
<PackageReference Include="Swashbuckle.AspNetCore" Version="6.5.0" />
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore.SqlServer" Version="10.0.8" />
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore.Tools" Version="10.0.8">
|
||||
<PrivateAssets>all</PrivateAssets>
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
</PackageReference>
|
||||
<PackageReference Include="Swashbuckle.AspNetCore" Version="10.1.7" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
||||
604
Microsoft.SelfService.Portal.Core.API.csproj.lscache
Normal file
604
Microsoft.SelfService.Portal.Core.API.csproj.lscache
Normal file
@@ -0,0 +1,604 @@
|
||||
version=1
|
||||
|
||||
# This file caches language service data to improve the performance of C# Dev Kit.
|
||||
# It is not intended for manual editing. It can safely be deleted and will be
|
||||
# regenerated automatically. For more information, see https://aka.ms/lscache
|
||||
#
|
||||
# To control where cache files are stored, use the following VS Code setting:
|
||||
# "dotnet.projectsystem.cacheInProjectFolder": true
|
||||
|
||||
[project]
|
||||
language=C#
|
||||
primary
|
||||
lastDtbSucceeded
|
||||
|
||||
[properties]
|
||||
AssemblyName=Microsoft.SelfService.Portal.Core.API
|
||||
CommandLineArgsForDesignTimeEvaluation=-langversion:14.0 -define:TRACE
|
||||
CompilerGeneratedFilesOutputPath=
|
||||
MaxSupportedLangVersion=14.0
|
||||
ProjectAssetsFile=<PATH>obj/project.assets.json
|
||||
RootNamespace=Microsoft.SelfService.Portal.Core.API
|
||||
RunAnalyzers=
|
||||
RunAnalyzersDuringLiveAnalysis=
|
||||
SolutionPath=<PATH>../../Coding.sln
|
||||
TargetFrameworkIdentifier=.NETCoreApp
|
||||
TargetPath=<PATH>bin/Debug/net10.0/Microsoft.SelfService.Portal.Core.API.dll
|
||||
TargetRefPath=<PATH>obj/Debug/net10.0/ref/Microsoft.SelfService.Portal.Core.API.dll
|
||||
TemporaryDependencyNodeTargetIdentifier=net10.0
|
||||
|
||||
[commandLineArguments]
|
||||
/noconfig
|
||||
/unsafe-
|
||||
/checked-
|
||||
/nowarn:1701,1702,1701,1702,8002
|
||||
/fullpaths
|
||||
/nostdlib+
|
||||
/errorreport:prompt
|
||||
/warn:10
|
||||
/define:TRACE;DEBUG;NET;NET10_0;NETCOREAPP;NET5_0_OR_GREATER;NET6_0_OR_GREATER;NET7_0_OR_GREATER;NET8_0_OR_GREATER;NET9_0_OR_GREATER;NET10_0_OR_GREATER;NETCOREAPP1_0_OR_GREATER;NETCOREAPP1_1_OR_GREATER;NETCOREAPP2_0_OR_GREATER;NETCOREAPP2_1_OR_GREATER;NETCOREAPP2_2_OR_GREATER;NETCOREAPP3_0_OR_GREATER;NETCOREAPP3_1_OR_GREATER
|
||||
/highentropyva+
|
||||
/nullable:enable
|
||||
/features:"InterceptorsNamespaces=;Microsoft.AspNetCore.OpenApi.Generated;;Microsoft.Extensions.Validation.Generated"
|
||||
/debug+
|
||||
/debug:portable
|
||||
/filealign:512
|
||||
/optimize-
|
||||
/out:obj\Debug\net10.0\Microsoft.SelfService.Portal.Core.API.dll
|
||||
/refout:obj\Debug\net10.0\refint\Microsoft.SelfService.Portal.Core.API.dll
|
||||
/target:exe
|
||||
/warnaserror-
|
||||
/utf8output
|
||||
/deterministic+
|
||||
/langversion:14.0
|
||||
/features:use-roslyn-tokenizer=true
|
||||
/warnaserror+:NU1605,SYSLIB0011
|
||||
|
||||
[sourceFiles]
|
||||
Context/DataContext.cs
|
||||
Controllers/
|
||||
AbstractController.cs
|
||||
DeploymentController.cs
|
||||
DeploymentGroupController.cs
|
||||
DomainController.cs
|
||||
EnvironmentController.cs
|
||||
RunbookController.cs
|
||||
ServiceController.cs
|
||||
TemplateCategoryController.cs
|
||||
TemplateController.cs
|
||||
VirtualMachineController.cs
|
||||
Dto/
|
||||
AddEnvironmentDomainDto.cs
|
||||
BaseDetailsDto.cs
|
||||
BaseDto.cs
|
||||
Deployment/Add/
|
||||
AddDeploymentDto.cs
|
||||
AddDeploymentRequestDto.cs
|
||||
Deployment/
|
||||
Edit/EditDeploymentDto.cs
|
||||
Get/
|
||||
GetDeploymentDetailsDto.cs
|
||||
GetDeploymentDto.cs
|
||||
GetQueueJobDetailsDto.cs
|
||||
GetQueueJobDto.cs
|
||||
GetQueueJobTargetDto.cs
|
||||
DeploymentGroup/
|
||||
Add/AddDeploymentGroupDto.cs
|
||||
Edit/EditDeploymentGroupDto.cs
|
||||
Get/
|
||||
GetDeploymentGroupDetailsDto.cs
|
||||
GetDeploymentGroupDto.cs
|
||||
Domain/
|
||||
Add/AddDomainDto.cs
|
||||
Edit/EditDomainDto.cs
|
||||
Get/
|
||||
GetDomainDetailsDto.cs
|
||||
GetDomainDto.cs
|
||||
GetDomainEnvironmentDetailsDto.cs
|
||||
GetDomainEnvironmentDto.cs
|
||||
GetDomainVirtualMachineDetailsDto.cs
|
||||
Environment/
|
||||
Add/AddEnvironmentDto.cs
|
||||
Edit/EditEnvironmentDto.cs
|
||||
Get/
|
||||
GetEnvironmentDetailsDto.cs
|
||||
GetEnvironmentDomainDetailsDto.cs
|
||||
GetEnvironmentDomainDto.cs
|
||||
GetEnvironmentDto.cs
|
||||
Runbook/
|
||||
Add/AddRunbookDto.cs
|
||||
Get/
|
||||
GetRunbookDetailsDto.cs
|
||||
GetRunbookDto.cs
|
||||
Service/
|
||||
Add/AddServiceDto.cs
|
||||
Edit/EditServiceDto.cs
|
||||
Get/
|
||||
GetServiceDetailsDto.cs
|
||||
GetServiceDto.cs
|
||||
RoleDefinition/
|
||||
AddServiceRoleDefinitionDto.cs
|
||||
EditServiceRoleDefinitionDto.cs
|
||||
Template/
|
||||
Add/AddTemplateDto.cs
|
||||
Edit/EditTemplateDto.cs
|
||||
Get/
|
||||
GetTemplateDetailsDto.cs
|
||||
GetTemplateDto.cs
|
||||
TemplateCategory/
|
||||
Add/AddTemplateCategoryDto.cs
|
||||
Edit/EditTemplateCategoryDto.cs
|
||||
Get/
|
||||
GetTemplateCategoryDetailsDto.cs
|
||||
GetTemplateCategoryDto.cs
|
||||
VirtualMachine/
|
||||
Add/AddVirtualMachineDto.cs
|
||||
Edit/EditVirtualMachineDto.cs
|
||||
Get/
|
||||
GetVirtualMachineDetailsDto.cs
|
||||
GetVirtualMachineDto.cs
|
||||
Events/
|
||||
AbstractEventHandler.cs
|
||||
Interfaces/IEventHandlerInterface.cs
|
||||
Extensions/Dataannotations/DefaultValueSqlAttribute.cs
|
||||
Handlers/DomainEditedHandler.cs
|
||||
Helper/
|
||||
APIHelper.cs
|
||||
MappingProfilesHelper.cs
|
||||
Interfaces/
|
||||
IAbstractInterface.cs
|
||||
IDeploymentGroupInterface.cs
|
||||
IDeploymentInterface.cs
|
||||
IDomainInterface.cs
|
||||
IEnvironmentInterface.cs
|
||||
IJobInterface.cs
|
||||
IQueueJobService.cs
|
||||
IRunbookInterface.cs
|
||||
IServiceInterface.cs
|
||||
ITemplateCategoryInterface.cs
|
||||
ITemplateInterface.cs
|
||||
IVirtualMachineInterface.cs
|
||||
Migrations/
|
||||
20231020093825_Initial.cs
|
||||
20231020093825_Initial.Designer.cs
|
||||
20260514210821_AddQueueJobs.cs
|
||||
20260514210821_AddQueueJobs.Designer.cs
|
||||
20260514210842_AddQueueJobModelSnapshotFix.cs
|
||||
20260514210842_AddQueueJobModelSnapshotFix.Designer.cs
|
||||
20260515195005_AddEnvironmentAndTargetProviderModel.cs
|
||||
20260515195005_AddEnvironmentAndTargetProviderModel.Designer.cs
|
||||
20260515195742_RemoveCloudEnabledFromEnvironment.cs
|
||||
20260515195742_RemoveCloudEnabledFromEnvironment.Designer.cs
|
||||
20260515204426_RemoveVirtualMachineTargetAndProvider.cs
|
||||
20260515204426_RemoveVirtualMachineTargetAndProvider.Designer.cs
|
||||
20260515205512_MakeVirtualMachineDomainOptionalAndAddLinkUnlinkFlow.cs
|
||||
20260515205512_MakeVirtualMachineDomainOptionalAndAddLinkUnlinkFlow.Designer.cs
|
||||
20260515214839_AddServiceCloudFlagAndRoleDefinitions.cs
|
||||
20260515214839_AddServiceCloudFlagAndRoleDefinitions.Designer.cs
|
||||
DataContextModelSnapshot.cs
|
||||
Models/
|
||||
BaseJunctionModel.cs
|
||||
BaseModel.cs
|
||||
DeploymentGroupModel.cs
|
||||
DeploymentModel.cs
|
||||
DomainModel.cs
|
||||
EnvironmentDomainsModel.cs
|
||||
EnvironmentModel.cs
|
||||
EnvironmentTypes.cs
|
||||
EventModel.cs
|
||||
JobModel.cs
|
||||
OptionCategoryModel.cs
|
||||
OptionModel.cs
|
||||
QueueJobModel.cs
|
||||
QueueJobStatus.cs
|
||||
QueueJobTargetModel.cs
|
||||
QueueJobType.cs
|
||||
RunbookModel.cs
|
||||
ServiceModel.cs
|
||||
ServiceRoleDefinitionModel.cs
|
||||
TemplateCategoryModel.cs
|
||||
TemplateModel.cs
|
||||
TemplateOptionModel.cs
|
||||
VirtualMachineModel.cs
|
||||
obj/Debug/net10.0/
|
||||
.NETCoreApp,Version=v10.0.AssemblyAttributes.cs
|
||||
Microsoft.SelfService.Portal.Core.API.AssemblyInfo.cs
|
||||
Microsoft.SelfService.Portal.Core.API.GlobalUsings.g.cs
|
||||
Program.cs
|
||||
Repository/
|
||||
DeploymentGroupRepository.cs
|
||||
DeploymentRepository.cs
|
||||
DomainRepository.cs
|
||||
EnvironmentRepository.cs
|
||||
JobRepository.cs
|
||||
RunbookRepository.cs
|
||||
ServiceRepository.cs
|
||||
TemplateCategoryRepository.cs
|
||||
TemplateRepository.cs
|
||||
VirtualMachineRepository.cs
|
||||
Services/QueueJobService.cs
|
||||
|
||||
[metadataReferences]
|
||||
<DOTNET>/packs/Microsoft.AspNetCore.App.Ref/10.0.8/ref/net10.0/
|
||||
Microsoft.AspNetCore.Antiforgery.dll
|
||||
Microsoft.AspNetCore.Authentication.Abstractions.dll
|
||||
Microsoft.AspNetCore.Authentication.BearerToken.dll
|
||||
Microsoft.AspNetCore.Authentication.Cookies.dll
|
||||
Microsoft.AspNetCore.Authentication.Core.dll
|
||||
Microsoft.AspNetCore.Authentication.dll
|
||||
Microsoft.AspNetCore.Authentication.OAuth.dll
|
||||
Microsoft.AspNetCore.Authorization.dll
|
||||
Microsoft.AspNetCore.Authorization.Policy.dll
|
||||
Microsoft.AspNetCore.Components.Authorization.dll
|
||||
Microsoft.AspNetCore.Components.dll
|
||||
Microsoft.AspNetCore.Components.Endpoints.dll
|
||||
Microsoft.AspNetCore.Components.Forms.dll
|
||||
Microsoft.AspNetCore.Components.Server.dll
|
||||
Microsoft.AspNetCore.Components.Web.dll
|
||||
Microsoft.AspNetCore.Connections.Abstractions.dll
|
||||
Microsoft.AspNetCore.CookiePolicy.dll
|
||||
Microsoft.AspNetCore.Cors.dll
|
||||
Microsoft.AspNetCore.Cryptography.Internal.dll
|
||||
Microsoft.AspNetCore.Cryptography.KeyDerivation.dll
|
||||
Microsoft.AspNetCore.DataProtection.Abstractions.dll
|
||||
Microsoft.AspNetCore.DataProtection.dll
|
||||
Microsoft.AspNetCore.DataProtection.Extensions.dll
|
||||
Microsoft.AspNetCore.Diagnostics.Abstractions.dll
|
||||
Microsoft.AspNetCore.Diagnostics.dll
|
||||
Microsoft.AspNetCore.Diagnostics.HealthChecks.dll
|
||||
Microsoft.AspNetCore.dll
|
||||
Microsoft.AspNetCore.HostFiltering.dll
|
||||
Microsoft.AspNetCore.Hosting.Abstractions.dll
|
||||
Microsoft.AspNetCore.Hosting.dll
|
||||
Microsoft.AspNetCore.Hosting.Server.Abstractions.dll
|
||||
Microsoft.AspNetCore.Html.Abstractions.dll
|
||||
Microsoft.AspNetCore.Http.Abstractions.dll
|
||||
Microsoft.AspNetCore.Http.Connections.Common.dll
|
||||
Microsoft.AspNetCore.Http.Connections.dll
|
||||
Microsoft.AspNetCore.Http.dll
|
||||
Microsoft.AspNetCore.Http.Extensions.dll
|
||||
Microsoft.AspNetCore.Http.Features.dll
|
||||
Microsoft.AspNetCore.Http.Results.dll
|
||||
Microsoft.AspNetCore.HttpLogging.dll
|
||||
Microsoft.AspNetCore.HttpOverrides.dll
|
||||
Microsoft.AspNetCore.HttpsPolicy.dll
|
||||
Microsoft.AspNetCore.Identity.dll
|
||||
Microsoft.AspNetCore.Localization.dll
|
||||
Microsoft.AspNetCore.Localization.Routing.dll
|
||||
Microsoft.AspNetCore.Metadata.dll
|
||||
Microsoft.AspNetCore.Mvc.Abstractions.dll
|
||||
Microsoft.AspNetCore.Mvc.ApiExplorer.dll
|
||||
Microsoft.AspNetCore.Mvc.Core.dll
|
||||
Microsoft.AspNetCore.Mvc.Cors.dll
|
||||
Microsoft.AspNetCore.Mvc.DataAnnotations.dll
|
||||
Microsoft.AspNetCore.Mvc.dll
|
||||
Microsoft.AspNetCore.Mvc.Formatters.Json.dll
|
||||
Microsoft.AspNetCore.Mvc.Formatters.Xml.dll
|
||||
Microsoft.AspNetCore.Mvc.Localization.dll
|
||||
Microsoft.AspNetCore.Mvc.Razor.dll
|
||||
Microsoft.AspNetCore.Mvc.RazorPages.dll
|
||||
Microsoft.AspNetCore.Mvc.TagHelpers.dll
|
||||
Microsoft.AspNetCore.Mvc.ViewFeatures.dll
|
||||
Microsoft.AspNetCore.OutputCaching.dll
|
||||
Microsoft.AspNetCore.RateLimiting.dll
|
||||
Microsoft.AspNetCore.Razor.dll
|
||||
Microsoft.AspNetCore.Razor.Runtime.dll
|
||||
Microsoft.AspNetCore.RequestDecompression.dll
|
||||
Microsoft.AspNetCore.ResponseCaching.Abstractions.dll
|
||||
Microsoft.AspNetCore.ResponseCaching.dll
|
||||
Microsoft.AspNetCore.ResponseCompression.dll
|
||||
Microsoft.AspNetCore.Rewrite.dll
|
||||
Microsoft.AspNetCore.Routing.Abstractions.dll
|
||||
Microsoft.AspNetCore.Routing.dll
|
||||
Microsoft.AspNetCore.Server.HttpSys.dll
|
||||
Microsoft.AspNetCore.Server.IIS.dll
|
||||
Microsoft.AspNetCore.Server.IISIntegration.dll
|
||||
Microsoft.AspNetCore.Server.Kestrel.Core.dll
|
||||
Microsoft.AspNetCore.Server.Kestrel.dll
|
||||
Microsoft.AspNetCore.Server.Kestrel.Transport.NamedPipes.dll
|
||||
Microsoft.AspNetCore.Server.Kestrel.Transport.Quic.dll
|
||||
Microsoft.AspNetCore.Server.Kestrel.Transport.Sockets.dll
|
||||
Microsoft.AspNetCore.Session.dll
|
||||
Microsoft.AspNetCore.SignalR.Common.dll
|
||||
Microsoft.AspNetCore.SignalR.Core.dll
|
||||
Microsoft.AspNetCore.SignalR.dll
|
||||
Microsoft.AspNetCore.SignalR.Protocols.Json.dll
|
||||
Microsoft.AspNetCore.StaticAssets.dll
|
||||
Microsoft.AspNetCore.StaticFiles.dll
|
||||
Microsoft.AspNetCore.WebSockets.dll
|
||||
Microsoft.AspNetCore.WebUtilities.dll
|
||||
Microsoft.Extensions.Caching.Abstractions.dll
|
||||
Microsoft.Extensions.Caching.Memory.dll
|
||||
Microsoft.Extensions.Configuration.Abstractions.dll
|
||||
Microsoft.Extensions.Configuration.Binder.dll
|
||||
Microsoft.Extensions.Configuration.CommandLine.dll
|
||||
Microsoft.Extensions.Configuration.dll
|
||||
Microsoft.Extensions.Configuration.EnvironmentVariables.dll
|
||||
Microsoft.Extensions.Configuration.FileExtensions.dll
|
||||
Microsoft.Extensions.Configuration.Ini.dll
|
||||
Microsoft.Extensions.Configuration.Json.dll
|
||||
Microsoft.Extensions.Configuration.KeyPerFile.dll
|
||||
Microsoft.Extensions.Configuration.UserSecrets.dll
|
||||
Microsoft.Extensions.Configuration.Xml.dll
|
||||
Microsoft.Extensions.DependencyInjection.Abstractions.dll
|
||||
Microsoft.Extensions.DependencyInjection.dll
|
||||
Microsoft.Extensions.Diagnostics.Abstractions.dll
|
||||
Microsoft.Extensions.Diagnostics.dll
|
||||
Microsoft.Extensions.Diagnostics.HealthChecks.Abstractions.dll
|
||||
Microsoft.Extensions.Diagnostics.HealthChecks.dll
|
||||
Microsoft.Extensions.Features.dll
|
||||
Microsoft.Extensions.FileProviders.Abstractions.dll
|
||||
Microsoft.Extensions.FileProviders.Composite.dll
|
||||
Microsoft.Extensions.FileProviders.Embedded.dll
|
||||
Microsoft.Extensions.FileProviders.Physical.dll
|
||||
Microsoft.Extensions.FileSystemGlobbing.dll
|
||||
Microsoft.Extensions.Hosting.Abstractions.dll
|
||||
Microsoft.Extensions.Hosting.dll
|
||||
Microsoft.Extensions.Http.dll
|
||||
Microsoft.Extensions.Identity.Core.dll
|
||||
Microsoft.Extensions.Identity.Stores.dll
|
||||
Microsoft.Extensions.Localization.Abstractions.dll
|
||||
Microsoft.Extensions.Localization.dll
|
||||
Microsoft.Extensions.Logging.Abstractions.dll
|
||||
Microsoft.Extensions.Logging.Configuration.dll
|
||||
Microsoft.Extensions.Logging.Console.dll
|
||||
Microsoft.Extensions.Logging.Debug.dll
|
||||
Microsoft.Extensions.Logging.dll
|
||||
Microsoft.Extensions.Logging.EventLog.dll
|
||||
Microsoft.Extensions.Logging.EventSource.dll
|
||||
Microsoft.Extensions.Logging.TraceSource.dll
|
||||
Microsoft.Extensions.ObjectPool.dll
|
||||
Microsoft.Extensions.Options.ConfigurationExtensions.dll
|
||||
Microsoft.Extensions.Options.DataAnnotations.dll
|
||||
Microsoft.Extensions.Options.dll
|
||||
Microsoft.Extensions.Primitives.dll
|
||||
Microsoft.Extensions.Validation.dll
|
||||
Microsoft.Extensions.WebEncoders.dll
|
||||
Microsoft.JSInterop.dll
|
||||
Microsoft.Net.Http.Headers.dll
|
||||
System.Diagnostics.EventLog.dll
|
||||
System.Formats.Cbor.dll
|
||||
System.Security.Cryptography.Xml.dll
|
||||
System.Threading.RateLimiting.dll
|
||||
<DOTNET>/packs/Microsoft.NETCore.App.Ref/10.0.8/ref/net10.0/
|
||||
Microsoft.CSharp.dll
|
||||
Microsoft.VisualBasic.Core.dll
|
||||
Microsoft.VisualBasic.dll
|
||||
Microsoft.Win32.Primitives.dll
|
||||
Microsoft.Win32.Registry.dll
|
||||
mscorlib.dll
|
||||
netstandard.dll
|
||||
System.AppContext.dll
|
||||
System.Buffers.dll
|
||||
System.Collections.Concurrent.dll
|
||||
System.Collections.dll
|
||||
System.Collections.Immutable.dll
|
||||
System.Collections.NonGeneric.dll
|
||||
System.Collections.Specialized.dll
|
||||
System.ComponentModel.Annotations.dll
|
||||
System.ComponentModel.DataAnnotations.dll
|
||||
System.ComponentModel.dll
|
||||
System.ComponentModel.EventBasedAsync.dll
|
||||
System.ComponentModel.Primitives.dll
|
||||
System.ComponentModel.TypeConverter.dll
|
||||
System.Configuration.dll
|
||||
System.Console.dll
|
||||
System.Core.dll
|
||||
System.Data.Common.dll
|
||||
System.Data.DataSetExtensions.dll
|
||||
System.Data.dll
|
||||
System.Diagnostics.Contracts.dll
|
||||
System.Diagnostics.Debug.dll
|
||||
System.Diagnostics.DiagnosticSource.dll
|
||||
System.Diagnostics.FileVersionInfo.dll
|
||||
System.Diagnostics.Process.dll
|
||||
System.Diagnostics.StackTrace.dll
|
||||
System.Diagnostics.TextWriterTraceListener.dll
|
||||
System.Diagnostics.Tools.dll
|
||||
System.Diagnostics.TraceSource.dll
|
||||
System.Diagnostics.Tracing.dll
|
||||
System.dll
|
||||
System.Drawing.dll
|
||||
System.Drawing.Primitives.dll
|
||||
System.Dynamic.Runtime.dll
|
||||
System.Formats.Asn1.dll
|
||||
System.Formats.Tar.dll
|
||||
System.Globalization.Calendars.dll
|
||||
System.Globalization.dll
|
||||
System.Globalization.Extensions.dll
|
||||
System.IO.Compression.Brotli.dll
|
||||
System.IO.Compression.dll
|
||||
System.IO.Compression.FileSystem.dll
|
||||
System.IO.Compression.ZipFile.dll
|
||||
System.IO.dll
|
||||
System.IO.FileSystem.AccessControl.dll
|
||||
System.IO.FileSystem.dll
|
||||
System.IO.FileSystem.DriveInfo.dll
|
||||
System.IO.FileSystem.Primitives.dll
|
||||
System.IO.FileSystem.Watcher.dll
|
||||
System.IO.IsolatedStorage.dll
|
||||
System.IO.MemoryMappedFiles.dll
|
||||
System.IO.Pipelines.dll
|
||||
System.IO.Pipes.AccessControl.dll
|
||||
System.IO.Pipes.dll
|
||||
System.IO.UnmanagedMemoryStream.dll
|
||||
System.Linq.AsyncEnumerable.dll
|
||||
System.Linq.dll
|
||||
System.Linq.Expressions.dll
|
||||
System.Linq.Parallel.dll
|
||||
System.Linq.Queryable.dll
|
||||
System.Memory.dll
|
||||
System.Net.dll
|
||||
System.Net.Http.dll
|
||||
System.Net.Http.Json.dll
|
||||
System.Net.HttpListener.dll
|
||||
System.Net.Mail.dll
|
||||
System.Net.NameResolution.dll
|
||||
System.Net.NetworkInformation.dll
|
||||
System.Net.Ping.dll
|
||||
System.Net.Primitives.dll
|
||||
System.Net.Quic.dll
|
||||
System.Net.Requests.dll
|
||||
System.Net.Security.dll
|
||||
System.Net.ServerSentEvents.dll
|
||||
System.Net.ServicePoint.dll
|
||||
System.Net.Sockets.dll
|
||||
System.Net.WebClient.dll
|
||||
System.Net.WebHeaderCollection.dll
|
||||
System.Net.WebProxy.dll
|
||||
System.Net.WebSockets.Client.dll
|
||||
System.Net.WebSockets.dll
|
||||
System.Numerics.dll
|
||||
System.Numerics.Vectors.dll
|
||||
System.ObjectModel.dll
|
||||
System.Reflection.DispatchProxy.dll
|
||||
System.Reflection.dll
|
||||
System.Reflection.Emit.dll
|
||||
System.Reflection.Emit.ILGeneration.dll
|
||||
System.Reflection.Emit.Lightweight.dll
|
||||
System.Reflection.Extensions.dll
|
||||
System.Reflection.Metadata.dll
|
||||
System.Reflection.Primitives.dll
|
||||
System.Reflection.TypeExtensions.dll
|
||||
System.Resources.Reader.dll
|
||||
System.Resources.ResourceManager.dll
|
||||
System.Resources.Writer.dll
|
||||
System.Runtime.CompilerServices.Unsafe.dll
|
||||
System.Runtime.CompilerServices.VisualC.dll
|
||||
System.Runtime.dll
|
||||
System.Runtime.Extensions.dll
|
||||
System.Runtime.Handles.dll
|
||||
System.Runtime.InteropServices.dll
|
||||
System.Runtime.InteropServices.JavaScript.dll
|
||||
System.Runtime.InteropServices.RuntimeInformation.dll
|
||||
System.Runtime.Intrinsics.dll
|
||||
System.Runtime.Loader.dll
|
||||
System.Runtime.Numerics.dll
|
||||
System.Runtime.Serialization.dll
|
||||
System.Runtime.Serialization.Formatters.dll
|
||||
System.Runtime.Serialization.Json.dll
|
||||
System.Runtime.Serialization.Primitives.dll
|
||||
System.Runtime.Serialization.Xml.dll
|
||||
System.Security.AccessControl.dll
|
||||
System.Security.Claims.dll
|
||||
System.Security.Cryptography.Algorithms.dll
|
||||
System.Security.Cryptography.Cng.dll
|
||||
System.Security.Cryptography.Csp.dll
|
||||
System.Security.Cryptography.dll
|
||||
System.Security.Cryptography.Encoding.dll
|
||||
System.Security.Cryptography.OpenSsl.dll
|
||||
System.Security.Cryptography.Primitives.dll
|
||||
System.Security.Cryptography.X509Certificates.dll
|
||||
System.Security.dll
|
||||
System.Security.Principal.dll
|
||||
System.Security.Principal.Windows.dll
|
||||
System.Security.SecureString.dll
|
||||
System.ServiceModel.Web.dll
|
||||
System.ServiceProcess.dll
|
||||
System.Text.Encoding.CodePages.dll
|
||||
System.Text.Encoding.dll
|
||||
System.Text.Encoding.Extensions.dll
|
||||
System.Text.Encodings.Web.dll
|
||||
System.Text.Json.dll
|
||||
System.Text.RegularExpressions.dll
|
||||
System.Threading.AccessControl.dll
|
||||
System.Threading.Channels.dll
|
||||
System.Threading.dll
|
||||
System.Threading.Overlapped.dll
|
||||
System.Threading.Tasks.Dataflow.dll
|
||||
System.Threading.Tasks.dll
|
||||
System.Threading.Tasks.Extensions.dll
|
||||
System.Threading.Tasks.Parallel.dll
|
||||
System.Threading.Thread.dll
|
||||
System.Threading.ThreadPool.dll
|
||||
System.Threading.Timer.dll
|
||||
System.Transactions.dll
|
||||
System.Transactions.Local.dll
|
||||
System.ValueTuple.dll
|
||||
System.Web.dll
|
||||
System.Web.HttpUtility.dll
|
||||
System.Windows.dll
|
||||
System.Xml.dll
|
||||
System.Xml.Linq.dll
|
||||
System.Xml.ReaderWriter.dll
|
||||
System.Xml.Serialization.dll
|
||||
System.Xml.XDocument.dll
|
||||
System.Xml.XmlDocument.dll
|
||||
System.Xml.XmlSerializer.dll
|
||||
System.Xml.XPath.dll
|
||||
System.Xml.XPath.XDocument.dll
|
||||
WindowsBase.dll
|
||||
<NUGET>/
|
||||
automapper/16.1.1/lib/net10.0/AutoMapper.dll
|
||||
azure.core/1.47.1/lib/net8.0/Azure.Core.dll
|
||||
azure.identity/1.14.2/lib/net8.0/Azure.Identity.dll
|
||||
microsoft.aspnetcore.authentication.negotiate/10.0.8/lib/net10.0/Microsoft.AspNetCore.Authentication.Negotiate.dll
|
||||
microsoft.aspnetcore.jsonpatch/10.0.8/lib/net10.0/Microsoft.AspNetCore.JsonPatch.dll
|
||||
microsoft.aspnetcore.mvc.newtonsoftjson/10.0.8/lib/net10.0/Microsoft.AspNetCore.Mvc.NewtonsoftJson.dll
|
||||
microsoft.aspnetcore.openapi/10.0.8/lib/net10.0/Microsoft.AspNetCore.OpenApi.dll
|
||||
microsoft.bcl.asyncinterfaces/8.0.0/lib/netstandard2.1/Microsoft.Bcl.AsyncInterfaces.dll
|
||||
microsoft.bcl.cryptography/9.0.4/lib/net9.0/Microsoft.Bcl.Cryptography.dll
|
||||
microsoft.data.sqlclient/6.1.1/ref/net9.0/Microsoft.Data.SqlClient.dll
|
||||
microsoft.entityframeworkcore.abstractions/10.0.8/lib/net10.0/Microsoft.EntityFrameworkCore.Abstractions.dll
|
||||
microsoft.entityframeworkcore.relational/10.0.8/lib/net10.0/Microsoft.EntityFrameworkCore.Relational.dll
|
||||
microsoft.entityframeworkcore.sqlserver/10.0.8/lib/net10.0/Microsoft.EntityFrameworkCore.SqlServer.dll
|
||||
microsoft.entityframeworkcore/10.0.8/lib/net10.0/Microsoft.EntityFrameworkCore.dll
|
||||
microsoft.identity.client.extensions.msal/4.73.1/lib/net8.0/Microsoft.Identity.Client.Extensions.Msal.dll
|
||||
microsoft.identity.client/4.73.1/lib/net8.0/Microsoft.Identity.Client.dll
|
||||
microsoft.identitymodel.abstractions/8.14.0/lib/net9.0/Microsoft.IdentityModel.Abstractions.dll
|
||||
microsoft.identitymodel.jsonwebtokens/8.14.0/lib/net9.0/Microsoft.IdentityModel.JsonWebTokens.dll
|
||||
microsoft.identitymodel.logging/8.14.0/lib/net9.0/Microsoft.IdentityModel.Logging.dll
|
||||
microsoft.identitymodel.protocols.openidconnect/7.7.1/lib/net8.0/Microsoft.IdentityModel.Protocols.OpenIdConnect.dll
|
||||
microsoft.identitymodel.protocols/7.7.1/lib/net8.0/Microsoft.IdentityModel.Protocols.dll
|
||||
microsoft.identitymodel.tokens/8.14.0/lib/net9.0/Microsoft.IdentityModel.Tokens.dll
|
||||
microsoft.openapi/2.4.1/lib/net8.0/Microsoft.OpenApi.dll
|
||||
microsoft.sqlserver.server/1.0.0/lib/netstandard2.0/Microsoft.SqlServer.Server.dll
|
||||
newtonsoft.json.bson/1.0.2/lib/netstandard2.0/Newtonsoft.Json.Bson.dll
|
||||
newtonsoft.json/13.0.3/lib/net6.0/Newtonsoft.Json.dll
|
||||
swashbuckle.aspnetcore.swagger/10.1.7/lib/net10.0/Swashbuckle.AspNetCore.Swagger.dll
|
||||
swashbuckle.aspnetcore.swaggergen/10.1.7/lib/net10.0/Swashbuckle.AspNetCore.SwaggerGen.dll
|
||||
swashbuckle.aspnetcore.swaggerui/10.1.7/lib/net10.0/Swashbuckle.AspNetCore.SwaggerUI.dll
|
||||
system.clientmodel/1.5.1/lib/net8.0/System.ClientModel.dll
|
||||
system.directoryservices.protocols/10.0.8/lib/net10.0/System.DirectoryServices.Protocols.dll
|
||||
system.identitymodel.tokens.jwt/7.7.1/lib/net8.0/System.IdentityModel.Tokens.Jwt.dll
|
||||
system.memory.data/8.0.1/lib/net8.0/System.Memory.Data.dll
|
||||
system.security.cryptography.pkcs/9.0.4/lib/net9.0/System.Security.Cryptography.Pkcs.dll
|
||||
system.security.cryptography.protecteddata/9.0.4/lib/net9.0/System.Security.Cryptography.ProtectedData.dll
|
||||
|
||||
[analyzerReferences]
|
||||
<DOTNET>/packs/Microsoft.AspNetCore.App.Ref/10.0.8/analyzers/dotnet/cs/
|
||||
Microsoft.AspNetCore.App.Analyzers.dll
|
||||
Microsoft.AspNetCore.App.CodeFixes.dll
|
||||
Microsoft.AspNetCore.App.SourceGenerators.dll
|
||||
Microsoft.AspNetCore.Components.Analyzers.dll
|
||||
Microsoft.Extensions.Logging.Generators.dll
|
||||
Microsoft.Extensions.Options.SourceGeneration.dll
|
||||
Microsoft.Extensions.Validation.ValidationsGenerator.dll
|
||||
<DOTNET>/packs/Microsoft.NETCore.App.Ref/10.0.8/analyzers/dotnet/cs/
|
||||
Microsoft.Interop.ComInterfaceGenerator.dll
|
||||
Microsoft.Interop.JavaScript.JSImportGenerator.dll
|
||||
Microsoft.Interop.LibraryImportGenerator.dll
|
||||
Microsoft.Interop.SourceGeneration.dll
|
||||
System.Text.Json.SourceGeneration.dll
|
||||
System.Text.RegularExpressions.Generator.dll
|
||||
<DOTNET>/sdk/10.0.300/Sdks/Microsoft.NET.Sdk.Razor/source-generators/
|
||||
Microsoft.AspNetCore.Razor.Utilities.Shared.dll
|
||||
Microsoft.CodeAnalysis.Razor.Compiler.dll
|
||||
Microsoft.Extensions.ObjectPool.dll
|
||||
<DOTNET>/sdk/10.0.300/Sdks/Microsoft.NET.Sdk.Web/analyzers/cs/
|
||||
Microsoft.AspNetCore.Analyzers.dll
|
||||
Microsoft.AspNetCore.Mvc.Analyzers.dll
|
||||
<DOTNET>/sdk/10.0.300/Sdks/Microsoft.NET.Sdk/analyzers/
|
||||
Microsoft.CodeAnalysis.CSharp.NetAnalyzers.dll
|
||||
Microsoft.CodeAnalysis.NetAnalyzers.dll
|
||||
<NUGET>/
|
||||
microsoft.aspnetcore.openapi/10.0.8/analyzers/dotnet/cs/Microsoft.AspNetCore.OpenApi.SourceGenerators.dll
|
||||
microsoft.codeanalysis.analyzers/3.11.0/analyzers/dotnet/cs/
|
||||
Microsoft.CodeAnalysis.Analyzers.dll
|
||||
Microsoft.CodeAnalysis.CSharp.Analyzers.dll
|
||||
microsoft.entityframeworkcore.analyzers/10.0.8/analyzers/dotnet/cs/Microsoft.EntityFrameworkCore.Analyzers.dll
|
||||
system.clientmodel/1.5.1/analyzers/dotnet/cs/System.ClientModel.SourceGeneration.dll
|
||||
|
||||
[analyzerConfigFiles]
|
||||
<DOTNET>/sdk/10.0.300/Sdks/Microsoft.NET.Sdk/analyzers/build/config/analysislevel_10_default.globalconfig
|
||||
obj/Debug/net10.0/Microsoft.SelfService.Portal.Core.API.GeneratedMSBuildEditorConfig.editorconfig
|
||||
1132
Migrations/20260514210821_AddQueueJobs.Designer.cs
generated
Normal file
1132
Migrations/20260514210821_AddQueueJobs.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
23
Migrations/20260514210821_AddQueueJobs.cs
Normal file
23
Migrations/20260514210821_AddQueueJobs.cs
Normal file
@@ -0,0 +1,23 @@
|
||||
using System;
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class AddQueueJobs : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
// No-op migration. Queue schema can already exist from a partial/manual run.
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
// No-op migration.
|
||||
}
|
||||
}
|
||||
}
|
||||
1132
Migrations/20260514210842_AddQueueJobModelSnapshotFix.Designer.cs
generated
Normal file
1132
Migrations/20260514210842_AddQueueJobModelSnapshotFix.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
23
Migrations/20260514210842_AddQueueJobModelSnapshotFix.cs
Normal file
23
Migrations/20260514210842_AddQueueJobModelSnapshotFix.cs
Normal file
@@ -0,0 +1,23 @@
|
||||
using System;
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class AddQueueJobModelSnapshotFix : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
// No-op migration. Queue schema is created by AddQueueJobs.
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
// No-op migration. Queue schema rollback is handled by AddQueueJobs.
|
||||
}
|
||||
}
|
||||
}
|
||||
1170
Migrations/20260515195005_AddEnvironmentAndTargetProviderModel.Designer.cs
generated
Normal file
1170
Migrations/20260515195005_AddEnvironmentAndTargetProviderModel.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,119 @@
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class AddEnvironmentAndTargetProviderModel : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "ExternalId",
|
||||
table: "VirtualMachines",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true)
|
||||
.Annotation("Relational:ColumnOrder", 5);
|
||||
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "MetadataJson",
|
||||
table: "VirtualMachines",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true)
|
||||
.Annotation("Relational:ColumnOrder", 6);
|
||||
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "ProviderType",
|
||||
table: "VirtualMachines",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true)
|
||||
.Annotation("Relational:ColumnOrder", 4);
|
||||
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "TargetType",
|
||||
table: "VirtualMachines",
|
||||
type: "nvarchar(max)",
|
||||
nullable: false,
|
||||
defaultValue: "")
|
||||
.Annotation("Relational:ColumnOrder", 3);
|
||||
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "EnvironmentType",
|
||||
table: "Environments",
|
||||
type: "nvarchar(max)",
|
||||
nullable: false,
|
||||
defaultValue: "")
|
||||
.Annotation("Relational:ColumnOrder", 3);
|
||||
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "MetadataJson",
|
||||
table: "Environments",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true)
|
||||
.Annotation("Relational:ColumnOrder", 7);
|
||||
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "ProviderType",
|
||||
table: "Environments",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true)
|
||||
.Annotation("Relational:ColumnOrder", 4);
|
||||
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "SubscriptionId",
|
||||
table: "Environments",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true)
|
||||
.Annotation("Relational:ColumnOrder", 6);
|
||||
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "TenantId",
|
||||
table: "Environments",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true)
|
||||
.Annotation("Relational:ColumnOrder", 5);
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropColumn(
|
||||
name: "ExternalId",
|
||||
table: "VirtualMachines");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "MetadataJson",
|
||||
table: "VirtualMachines");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "ProviderType",
|
||||
table: "VirtualMachines");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "TargetType",
|
||||
table: "VirtualMachines");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "EnvironmentType",
|
||||
table: "Environments");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "MetadataJson",
|
||||
table: "Environments");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "ProviderType",
|
||||
table: "Environments");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "SubscriptionId",
|
||||
table: "Environments");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "TenantId",
|
||||
table: "Environments");
|
||||
}
|
||||
}
|
||||
}
|
||||
1166
Migrations/20260515195742_RemoveCloudEnabledFromEnvironment.Designer.cs
generated
Normal file
1166
Migrations/20260515195742_RemoveCloudEnabledFromEnvironment.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
138
Migrations/20260515195742_RemoveCloudEnabledFromEnvironment.cs
Normal file
138
Migrations/20260515195742_RemoveCloudEnabledFromEnvironment.cs
Normal file
@@ -0,0 +1,138 @@
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class RemoveCloudEnabledFromEnvironment : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropColumn(
|
||||
name: "CloudEnabled",
|
||||
table: "Environments");
|
||||
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "TenantId",
|
||||
table: "Environments",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true,
|
||||
oldClrType: typeof(string),
|
||||
oldType: "nvarchar(max)",
|
||||
oldNullable: true)
|
||||
.Annotation("Relational:ColumnOrder", 4)
|
||||
.OldAnnotation("Relational:ColumnOrder", 5);
|
||||
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "SubscriptionId",
|
||||
table: "Environments",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true,
|
||||
oldClrType: typeof(string),
|
||||
oldType: "nvarchar(max)",
|
||||
oldNullable: true)
|
||||
.Annotation("Relational:ColumnOrder", 5)
|
||||
.OldAnnotation("Relational:ColumnOrder", 6);
|
||||
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "ProviderType",
|
||||
table: "Environments",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true,
|
||||
oldClrType: typeof(string),
|
||||
oldType: "nvarchar(max)",
|
||||
oldNullable: true)
|
||||
.Annotation("Relational:ColumnOrder", 3)
|
||||
.OldAnnotation("Relational:ColumnOrder", 4);
|
||||
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "MetadataJson",
|
||||
table: "Environments",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true,
|
||||
oldClrType: typeof(string),
|
||||
oldType: "nvarchar(max)",
|
||||
oldNullable: true)
|
||||
.Annotation("Relational:ColumnOrder", 6)
|
||||
.OldAnnotation("Relational:ColumnOrder", 7);
|
||||
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "EnvironmentType",
|
||||
table: "Environments",
|
||||
type: "nvarchar(max)",
|
||||
nullable: false,
|
||||
oldClrType: typeof(string),
|
||||
oldType: "nvarchar(max)")
|
||||
.Annotation("Relational:ColumnOrder", 2)
|
||||
.OldAnnotation("Relational:ColumnOrder", 3);
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "TenantId",
|
||||
table: "Environments",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true,
|
||||
oldClrType: typeof(string),
|
||||
oldType: "nvarchar(max)",
|
||||
oldNullable: true)
|
||||
.Annotation("Relational:ColumnOrder", 5)
|
||||
.OldAnnotation("Relational:ColumnOrder", 4);
|
||||
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "SubscriptionId",
|
||||
table: "Environments",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true,
|
||||
oldClrType: typeof(string),
|
||||
oldType: "nvarchar(max)",
|
||||
oldNullable: true)
|
||||
.Annotation("Relational:ColumnOrder", 6)
|
||||
.OldAnnotation("Relational:ColumnOrder", 5);
|
||||
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "ProviderType",
|
||||
table: "Environments",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true,
|
||||
oldClrType: typeof(string),
|
||||
oldType: "nvarchar(max)",
|
||||
oldNullable: true)
|
||||
.Annotation("Relational:ColumnOrder", 4)
|
||||
.OldAnnotation("Relational:ColumnOrder", 3);
|
||||
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "MetadataJson",
|
||||
table: "Environments",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true,
|
||||
oldClrType: typeof(string),
|
||||
oldType: "nvarchar(max)",
|
||||
oldNullable: true)
|
||||
.Annotation("Relational:ColumnOrder", 7)
|
||||
.OldAnnotation("Relational:ColumnOrder", 6);
|
||||
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "EnvironmentType",
|
||||
table: "Environments",
|
||||
type: "nvarchar(max)",
|
||||
nullable: false,
|
||||
oldClrType: typeof(string),
|
||||
oldType: "nvarchar(max)")
|
||||
.Annotation("Relational:ColumnOrder", 3)
|
||||
.OldAnnotation("Relational:ColumnOrder", 2);
|
||||
|
||||
migrationBuilder.AddColumn<bool>(
|
||||
name: "CloudEnabled",
|
||||
table: "Environments",
|
||||
type: "bit",
|
||||
nullable: false,
|
||||
defaultValue: false)
|
||||
.Annotation("Relational:ColumnOrder", 2);
|
||||
}
|
||||
}
|
||||
}
|
||||
1157
Migrations/20260515204426_RemoveVirtualMachineTargetAndProvider.Designer.cs
generated
Normal file
1157
Migrations/20260515204426_RemoveVirtualMachineTargetAndProvider.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,85 @@
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class RemoveVirtualMachineTargetAndProvider : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropColumn(
|
||||
name: "ProviderType",
|
||||
table: "VirtualMachines");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "TargetType",
|
||||
table: "VirtualMachines");
|
||||
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "MetadataJson",
|
||||
table: "VirtualMachines",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true,
|
||||
oldClrType: typeof(string),
|
||||
oldType: "nvarchar(max)",
|
||||
oldNullable: true)
|
||||
.Annotation("Relational:ColumnOrder", 4)
|
||||
.OldAnnotation("Relational:ColumnOrder", 6);
|
||||
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "ExternalId",
|
||||
table: "VirtualMachines",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true,
|
||||
oldClrType: typeof(string),
|
||||
oldType: "nvarchar(max)",
|
||||
oldNullable: true)
|
||||
.Annotation("Relational:ColumnOrder", 3)
|
||||
.OldAnnotation("Relational:ColumnOrder", 5);
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "MetadataJson",
|
||||
table: "VirtualMachines",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true,
|
||||
oldClrType: typeof(string),
|
||||
oldType: "nvarchar(max)",
|
||||
oldNullable: true)
|
||||
.Annotation("Relational:ColumnOrder", 6)
|
||||
.OldAnnotation("Relational:ColumnOrder", 4);
|
||||
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "ExternalId",
|
||||
table: "VirtualMachines",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true,
|
||||
oldClrType: typeof(string),
|
||||
oldType: "nvarchar(max)",
|
||||
oldNullable: true)
|
||||
.Annotation("Relational:ColumnOrder", 5)
|
||||
.OldAnnotation("Relational:ColumnOrder", 3);
|
||||
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "ProviderType",
|
||||
table: "VirtualMachines",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true)
|
||||
.Annotation("Relational:ColumnOrder", 4);
|
||||
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "TargetType",
|
||||
table: "VirtualMachines",
|
||||
type: "nvarchar(max)",
|
||||
nullable: false,
|
||||
defaultValue: "")
|
||||
.Annotation("Relational:ColumnOrder", 3);
|
||||
}
|
||||
}
|
||||
}
|
||||
1155
Migrations/20260515205512_MakeVirtualMachineDomainOptionalAndAddLinkUnlinkFlow.Designer.cs
generated
Normal file
1155
Migrations/20260515205512_MakeVirtualMachineDomainOptionalAndAddLinkUnlinkFlow.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,60 @@
|
||||
using System;
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class MakeVirtualMachineDomainOptionalAndAddLinkUnlinkFlow : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_VirtualMachines_Domains_DomainID",
|
||||
table: "VirtualMachines");
|
||||
|
||||
migrationBuilder.AlterColumn<Guid>(
|
||||
name: "DomainID",
|
||||
table: "VirtualMachines",
|
||||
type: "uniqueidentifier",
|
||||
nullable: true,
|
||||
oldClrType: typeof(Guid),
|
||||
oldType: "uniqueidentifier");
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_VirtualMachines_Domains_DomainID",
|
||||
table: "VirtualMachines",
|
||||
column: "DomainID",
|
||||
principalTable: "Domains",
|
||||
principalColumn: "Id");
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_VirtualMachines_Domains_DomainID",
|
||||
table: "VirtualMachines");
|
||||
|
||||
migrationBuilder.AlterColumn<Guid>(
|
||||
name: "DomainID",
|
||||
table: "VirtualMachines",
|
||||
type: "uniqueidentifier",
|
||||
nullable: false,
|
||||
defaultValue: new Guid("00000000-0000-0000-0000-000000000000"),
|
||||
oldClrType: typeof(Guid),
|
||||
oldType: "uniqueidentifier",
|
||||
oldNullable: true);
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_VirtualMachines_Domains_DomainID",
|
||||
table: "VirtualMachines",
|
||||
column: "DomainID",
|
||||
principalTable: "Domains",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
}
|
||||
}
|
||||
}
|
||||
1239
Migrations/20260515215206_AddServiceCloudFlagAndRoleDefinitionsV2.Designer.cs
generated
Normal file
1239
Migrations/20260515215206_AddServiceCloudFlagAndRoleDefinitionsV2.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,67 @@
|
||||
using System;
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class AddServiceCloudFlagAndRoleDefinitionsV2 : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.AddColumn<bool>(
|
||||
name: "IsCloudService",
|
||||
table: "Services",
|
||||
type: "bit",
|
||||
nullable: false,
|
||||
defaultValue: false)
|
||||
.Annotation("Relational:ColumnOrder", 3);
|
||||
|
||||
migrationBuilder.CreateTable(
|
||||
name: "ServiceRoleDefinitions",
|
||||
columns: table => new
|
||||
{
|
||||
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false, defaultValueSql: "NEWID()"),
|
||||
ServiceId = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
|
||||
Key = table.Column<string>(type: "nvarchar(max)", nullable: false),
|
||||
Name = table.Column<string>(type: "nvarchar(max)", nullable: false),
|
||||
Description = table.Column<string>(type: "nvarchar(max)", nullable: true),
|
||||
MinCount = table.Column<int>(type: "int", nullable: false),
|
||||
MaxCount = table.Column<int>(type: "int", nullable: false),
|
||||
DefaultStageOrder = table.Column<int>(type: "int", nullable: false),
|
||||
Modified = table.Column<DateTime>(type: "datetime2", nullable: false, defaultValueSql: "GETDATE()"),
|
||||
ModifiedBy = table.Column<string>(type: "nvarchar(max)", nullable: false),
|
||||
Created = table.Column<DateTime>(type: "datetime2", nullable: false, defaultValueSql: "GETDATE()"),
|
||||
CreatedBy = table.Column<string>(type: "nvarchar(max)", nullable: false)
|
||||
},
|
||||
constraints: table =>
|
||||
{
|
||||
table.PrimaryKey("PK_ServiceRoleDefinitions", x => x.Id);
|
||||
table.ForeignKey(
|
||||
name: "FK_ServiceRoleDefinitions_Services_ServiceId",
|
||||
column: x => x.ServiceId,
|
||||
principalTable: "Services",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
});
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_ServiceRoleDefinitions_ServiceId",
|
||||
table: "ServiceRoleDefinitions",
|
||||
column: "ServiceId");
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropTable(
|
||||
name: "ServiceRoleDefinitions");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "IsCloudService",
|
||||
table: "Services");
|
||||
}
|
||||
}
|
||||
}
|
||||
1227
Migrations/20260515221746_RemoveRoleDefinitionSizingFields.Designer.cs
generated
Normal file
1227
Migrations/20260515221746_RemoveRoleDefinitionSizingFields.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,51 @@
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class RemoveRoleDefinitionSizingFields : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropColumn(
|
||||
name: "DefaultStageOrder",
|
||||
table: "ServiceRoleDefinitions");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "MaxCount",
|
||||
table: "ServiceRoleDefinitions");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "MinCount",
|
||||
table: "ServiceRoleDefinitions");
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.AddColumn<int>(
|
||||
name: "DefaultStageOrder",
|
||||
table: "ServiceRoleDefinitions",
|
||||
type: "int",
|
||||
nullable: false,
|
||||
defaultValue: 0);
|
||||
|
||||
migrationBuilder.AddColumn<int>(
|
||||
name: "MaxCount",
|
||||
table: "ServiceRoleDefinitions",
|
||||
type: "int",
|
||||
nullable: false,
|
||||
defaultValue: 0);
|
||||
|
||||
migrationBuilder.AddColumn<int>(
|
||||
name: "MinCount",
|
||||
table: "ServiceRoleDefinitions",
|
||||
type: "int",
|
||||
nullable: false,
|
||||
defaultValue: 0);
|
||||
}
|
||||
}
|
||||
}
|
||||
1218
Migrations/20260516113515_RemoveTemplateCategoryLegacyFields.Designer.cs
generated
Normal file
1218
Migrations/20260516113515_RemoveTemplateCategoryLegacyFields.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,40 @@
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class RemoveTemplateCategoryLegacyFields : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropColumn(
|
||||
name: "ParentCategoryName",
|
||||
table: "TemplateCategories");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "showOrder",
|
||||
table: "TemplateCategories");
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "ParentCategoryName",
|
||||
table: "TemplateCategories",
|
||||
type: "nvarchar(max)",
|
||||
nullable: false,
|
||||
defaultValue: "");
|
||||
|
||||
migrationBuilder.AddColumn<int>(
|
||||
name: "showOrder",
|
||||
table: "TemplateCategories",
|
||||
type: "int",
|
||||
nullable: false,
|
||||
defaultValue: 0);
|
||||
}
|
||||
}
|
||||
}
|
||||
1234
Migrations/20260516114627_AddTemplateCategoryMetadataFields.Designer.cs
generated
Normal file
1234
Migrations/20260516114627_AddTemplateCategoryMetadataFields.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,59 @@
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class AddTemplateCategoryMetadataFields : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "Color",
|
||||
table: "TemplateCategories",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true);
|
||||
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "Description",
|
||||
table: "TemplateCategories",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true);
|
||||
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "IconKey",
|
||||
table: "TemplateCategories",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true);
|
||||
|
||||
migrationBuilder.AddColumn<bool>(
|
||||
name: "IsActive",
|
||||
table: "TemplateCategories",
|
||||
type: "bit",
|
||||
nullable: false,
|
||||
defaultValue: true);
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropColumn(
|
||||
name: "Color",
|
||||
table: "TemplateCategories");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "Description",
|
||||
table: "TemplateCategories");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "IconKey",
|
||||
table: "TemplateCategories");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "IsActive",
|
||||
table: "TemplateCategories");
|
||||
}
|
||||
}
|
||||
}
|
||||
1234
Migrations/20260516115934_MoveIconKeyFromTemplateCategoryToService.Designer.cs
generated
Normal file
1234
Migrations/20260516115934_MoveIconKeyFromTemplateCategoryToService.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,38 @@
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class MoveIconKeyFromTemplateCategoryToService : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropColumn(
|
||||
name: "IconKey",
|
||||
table: "TemplateCategories");
|
||||
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "IconKey",
|
||||
table: "Services",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true);
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropColumn(
|
||||
name: "IconKey",
|
||||
table: "Services");
|
||||
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "IconKey",
|
||||
table: "TemplateCategories",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true);
|
||||
}
|
||||
}
|
||||
}
|
||||
1230
Migrations/20260516121222_RemoveTemplateCloudFlag.Designer.cs
generated
Normal file
1230
Migrations/20260516121222_RemoveTemplateCloudFlag.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
29
Migrations/20260516121222_RemoveTemplateCloudFlag.cs
Normal file
29
Migrations/20260516121222_RemoveTemplateCloudFlag.cs
Normal file
@@ -0,0 +1,29 @@
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class RemoveTemplateCloudFlag : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropColumn(
|
||||
name: "CloudTemplate",
|
||||
table: "Templates");
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.AddColumn<bool>(
|
||||
name: "CloudTemplate",
|
||||
table: "Templates",
|
||||
type: "bit",
|
||||
nullable: false,
|
||||
defaultValue: false);
|
||||
}
|
||||
}
|
||||
}
|
||||
1479
Migrations/20260516140554_AddDeploymentRulesAndQueueJobSteps.Designer.cs
generated
Normal file
1479
Migrations/20260516140554_AddDeploymentRulesAndQueueJobSteps.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
178
Migrations/20260516140554_AddDeploymentRulesAndQueueJobSteps.cs
Normal file
178
Migrations/20260516140554_AddDeploymentRulesAndQueueJobSteps.cs
Normal file
@@ -0,0 +1,178 @@
|
||||
using System;
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class AddDeploymentRulesAndQueueJobSteps : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.AddColumn<Guid>(
|
||||
name: "DeploymentRuleId",
|
||||
table: "Templates",
|
||||
type: "uniqueidentifier",
|
||||
nullable: true)
|
||||
.Annotation("Relational:ColumnOrder", 6);
|
||||
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "MetadataJson",
|
||||
table: "QueueJobs",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true)
|
||||
.Annotation("Relational:ColumnOrder", 11);
|
||||
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "RuleSnapshotJson",
|
||||
table: "QueueJobs",
|
||||
type: "nvarchar(max)",
|
||||
nullable: true)
|
||||
.Annotation("Relational:ColumnOrder", 12);
|
||||
|
||||
migrationBuilder.CreateTable(
|
||||
name: "DeploymentRules",
|
||||
columns: table => new
|
||||
{
|
||||
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false, defaultValueSql: "NEWID()"),
|
||||
Name = table.Column<string>(type: "nvarchar(max)", nullable: false),
|
||||
Description = table.Column<string>(type: "nvarchar(max)", nullable: true),
|
||||
IsActive = table.Column<bool>(type: "bit", nullable: false),
|
||||
Modified = table.Column<DateTime>(type: "datetime2", nullable: false, defaultValueSql: "GETDATE()"),
|
||||
ModifiedBy = table.Column<string>(type: "nvarchar(max)", nullable: false),
|
||||
Created = table.Column<DateTime>(type: "datetime2", nullable: false, defaultValueSql: "GETDATE()"),
|
||||
CreatedBy = table.Column<string>(type: "nvarchar(max)", nullable: false)
|
||||
},
|
||||
constraints: table =>
|
||||
{
|
||||
table.PrimaryKey("PK_DeploymentRules", x => x.Id);
|
||||
});
|
||||
|
||||
migrationBuilder.CreateTable(
|
||||
name: "QueueJobSteps",
|
||||
columns: table => new
|
||||
{
|
||||
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false, defaultValueSql: "NEWID()"),
|
||||
QueueJobId = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
|
||||
DependsOnQueueJobStepId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
|
||||
SortOrder = table.Column<int>(type: "int", nullable: false),
|
||||
Name = table.Column<string>(type: "nvarchar(max)", nullable: false),
|
||||
StepType = table.Column<string>(type: "nvarchar(max)", nullable: false),
|
||||
Status = table.Column<string>(type: "nvarchar(max)", nullable: false),
|
||||
MetadataJson = table.Column<string>(type: "nvarchar(max)", nullable: true),
|
||||
ApprovedAt = table.Column<DateTime>(type: "datetime2", nullable: true),
|
||||
ApprovedBy = table.Column<string>(type: "nvarchar(max)", nullable: true),
|
||||
ApprovalComment = table.Column<string>(type: "nvarchar(max)", nullable: true),
|
||||
Modified = table.Column<DateTime>(type: "datetime2", nullable: false, defaultValueSql: "GETDATE()"),
|
||||
ModifiedBy = table.Column<string>(type: "nvarchar(max)", nullable: false),
|
||||
Created = table.Column<DateTime>(type: "datetime2", nullable: false, defaultValueSql: "GETDATE()"),
|
||||
CreatedBy = table.Column<string>(type: "nvarchar(max)", nullable: false)
|
||||
},
|
||||
constraints: table =>
|
||||
{
|
||||
table.PrimaryKey("PK_QueueJobSteps", x => x.Id);
|
||||
table.ForeignKey(
|
||||
name: "FK_QueueJobSteps_QueueJobSteps_DependsOnQueueJobStepId",
|
||||
column: x => x.DependsOnQueueJobStepId,
|
||||
principalTable: "QueueJobSteps",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Restrict);
|
||||
table.ForeignKey(
|
||||
name: "FK_QueueJobSteps_QueueJobs_QueueJobId",
|
||||
column: x => x.QueueJobId,
|
||||
principalTable: "QueueJobs",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
});
|
||||
|
||||
migrationBuilder.CreateTable(
|
||||
name: "DeploymentRuleSteps",
|
||||
columns: table => new
|
||||
{
|
||||
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false, defaultValueSql: "NEWID()"),
|
||||
DeploymentRuleId = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
|
||||
SortOrder = table.Column<int>(type: "int", nullable: false),
|
||||
Name = table.Column<string>(type: "nvarchar(max)", nullable: false),
|
||||
StepType = table.Column<string>(type: "nvarchar(max)", nullable: false),
|
||||
RequiresApproval = table.Column<bool>(type: "bit", nullable: false),
|
||||
MetadataJson = table.Column<string>(type: "nvarchar(max)", nullable: true),
|
||||
Modified = table.Column<DateTime>(type: "datetime2", nullable: false, defaultValueSql: "GETDATE()"),
|
||||
ModifiedBy = table.Column<string>(type: "nvarchar(max)", nullable: false),
|
||||
Created = table.Column<DateTime>(type: "datetime2", nullable: false, defaultValueSql: "GETDATE()"),
|
||||
CreatedBy = table.Column<string>(type: "nvarchar(max)", nullable: false)
|
||||
},
|
||||
constraints: table =>
|
||||
{
|
||||
table.PrimaryKey("PK_DeploymentRuleSteps", x => x.Id);
|
||||
table.ForeignKey(
|
||||
name: "FK_DeploymentRuleSteps_DeploymentRules_DeploymentRuleId",
|
||||
column: x => x.DeploymentRuleId,
|
||||
principalTable: "DeploymentRules",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
});
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_Templates_DeploymentRuleId",
|
||||
table: "Templates",
|
||||
column: "DeploymentRuleId");
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_DeploymentRuleSteps_DeploymentRuleId",
|
||||
table: "DeploymentRuleSteps",
|
||||
column: "DeploymentRuleId");
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_QueueJobSteps_DependsOnQueueJobStepId",
|
||||
table: "QueueJobSteps",
|
||||
column: "DependsOnQueueJobStepId");
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_QueueJobSteps_QueueJobId",
|
||||
table: "QueueJobSteps",
|
||||
column: "QueueJobId");
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_Templates_DeploymentRules_DeploymentRuleId",
|
||||
table: "Templates",
|
||||
column: "DeploymentRuleId",
|
||||
principalTable: "DeploymentRules",
|
||||
principalColumn: "Id");
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_Templates_DeploymentRules_DeploymentRuleId",
|
||||
table: "Templates");
|
||||
|
||||
migrationBuilder.DropTable(
|
||||
name: "DeploymentRuleSteps");
|
||||
|
||||
migrationBuilder.DropTable(
|
||||
name: "QueueJobSteps");
|
||||
|
||||
migrationBuilder.DropTable(
|
||||
name: "DeploymentRules");
|
||||
|
||||
migrationBuilder.DropIndex(
|
||||
name: "IX_Templates_DeploymentRuleId",
|
||||
table: "Templates");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "DeploymentRuleId",
|
||||
table: "Templates");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "MetadataJson",
|
||||
table: "QueueJobs");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "RuleSnapshotJson",
|
||||
table: "QueueJobs");
|
||||
}
|
||||
}
|
||||
}
|
||||
1479
Migrations/20260516141653_RenameDeploymentAndJobTables.Designer.cs
generated
Normal file
1479
Migrations/20260516141653_RenameDeploymentAndJobTables.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
384
Migrations/20260516141653_RenameDeploymentAndJobTables.cs
Normal file
384
Migrations/20260516141653_RenameDeploymentAndJobTables.cs
Normal file
@@ -0,0 +1,384 @@
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class RenameDeploymentAndJobTables : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_DeploymentGroups_Templates_TemplateId",
|
||||
table: "DeploymentGroups");
|
||||
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_Deployments_DeploymentGroups_DeploymentGroupId",
|
||||
table: "Deployments");
|
||||
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_Deployments_VirtualMachines_VirtualMachineId",
|
||||
table: "Deployments");
|
||||
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_Jobs_Deployments_DeploymentId",
|
||||
table: "Jobs");
|
||||
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_QueueJobSteps_QueueJobSteps_DependsOnQueueJobStepId",
|
||||
table: "QueueJobSteps");
|
||||
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_QueueJobSteps_QueueJobs_QueueJobId",
|
||||
table: "QueueJobSteps");
|
||||
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_QueueJobTargets_QueueJobs_QueueJobId",
|
||||
table: "QueueJobTargets");
|
||||
|
||||
migrationBuilder.DropPrimaryKey(
|
||||
name: "PK_QueueJobTargets",
|
||||
table: "QueueJobTargets");
|
||||
|
||||
migrationBuilder.DropPrimaryKey(
|
||||
name: "PK_QueueJobSteps",
|
||||
table: "QueueJobSteps");
|
||||
|
||||
migrationBuilder.DropPrimaryKey(
|
||||
name: "PK_QueueJobs",
|
||||
table: "QueueJobs");
|
||||
|
||||
migrationBuilder.DropUniqueConstraint(
|
||||
name: "AK_Deployments_Id",
|
||||
table: "Deployments");
|
||||
|
||||
migrationBuilder.DropPrimaryKey(
|
||||
name: "PK_Deployments",
|
||||
table: "Deployments");
|
||||
|
||||
migrationBuilder.DropPrimaryKey(
|
||||
name: "PK_DeploymentGroups",
|
||||
table: "DeploymentGroups");
|
||||
|
||||
migrationBuilder.RenameTable(
|
||||
name: "QueueJobTargets",
|
||||
newName: "DeploymentJobTargets");
|
||||
|
||||
migrationBuilder.RenameTable(
|
||||
name: "QueueJobSteps",
|
||||
newName: "DeploymentJobSteps");
|
||||
|
||||
migrationBuilder.RenameTable(
|
||||
name: "QueueJobs",
|
||||
newName: "DeploymentJobs");
|
||||
|
||||
migrationBuilder.RenameTable(
|
||||
name: "Deployments",
|
||||
newName: "DeploymentExecutions");
|
||||
|
||||
migrationBuilder.RenameTable(
|
||||
name: "DeploymentGroups",
|
||||
newName: "DeploymentBatches");
|
||||
|
||||
migrationBuilder.RenameIndex(
|
||||
name: "IX_QueueJobTargets_QueueJobId",
|
||||
table: "DeploymentJobTargets",
|
||||
newName: "IX_DeploymentJobTargets_QueueJobId");
|
||||
|
||||
migrationBuilder.RenameIndex(
|
||||
name: "IX_QueueJobSteps_QueueJobId",
|
||||
table: "DeploymentJobSteps",
|
||||
newName: "IX_DeploymentJobSteps_QueueJobId");
|
||||
|
||||
migrationBuilder.RenameIndex(
|
||||
name: "IX_QueueJobSteps_DependsOnQueueJobStepId",
|
||||
table: "DeploymentJobSteps",
|
||||
newName: "IX_DeploymentJobSteps_DependsOnQueueJobStepId");
|
||||
|
||||
migrationBuilder.RenameIndex(
|
||||
name: "IX_Deployments_DeploymentGroupId",
|
||||
table: "DeploymentExecutions",
|
||||
newName: "IX_DeploymentExecutions_DeploymentGroupId");
|
||||
|
||||
migrationBuilder.RenameIndex(
|
||||
name: "IX_DeploymentGroups_TemplateId",
|
||||
table: "DeploymentBatches",
|
||||
newName: "IX_DeploymentBatches_TemplateId");
|
||||
|
||||
migrationBuilder.AddPrimaryKey(
|
||||
name: "PK_DeploymentJobTargets",
|
||||
table: "DeploymentJobTargets",
|
||||
column: "Id");
|
||||
|
||||
migrationBuilder.AddPrimaryKey(
|
||||
name: "PK_DeploymentJobSteps",
|
||||
table: "DeploymentJobSteps",
|
||||
column: "Id");
|
||||
|
||||
migrationBuilder.AddPrimaryKey(
|
||||
name: "PK_DeploymentJobs",
|
||||
table: "DeploymentJobs",
|
||||
column: "Id");
|
||||
|
||||
migrationBuilder.AddUniqueConstraint(
|
||||
name: "AK_DeploymentExecutions_Id",
|
||||
table: "DeploymentExecutions",
|
||||
column: "Id");
|
||||
|
||||
migrationBuilder.AddPrimaryKey(
|
||||
name: "PK_DeploymentExecutions",
|
||||
table: "DeploymentExecutions",
|
||||
columns: new[] { "VirtualMachineId", "DeploymentGroupId" });
|
||||
|
||||
migrationBuilder.AddPrimaryKey(
|
||||
name: "PK_DeploymentBatches",
|
||||
table: "DeploymentBatches",
|
||||
column: "Id");
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_DeploymentBatches_Templates_TemplateId",
|
||||
table: "DeploymentBatches",
|
||||
column: "TemplateId",
|
||||
principalTable: "Templates",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_DeploymentExecutions_DeploymentBatches_DeploymentGroupId",
|
||||
table: "DeploymentExecutions",
|
||||
column: "DeploymentGroupId",
|
||||
principalTable: "DeploymentBatches",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_DeploymentExecutions_VirtualMachines_VirtualMachineId",
|
||||
table: "DeploymentExecutions",
|
||||
column: "VirtualMachineId",
|
||||
principalTable: "VirtualMachines",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_DeploymentJobSteps_DeploymentJobSteps_DependsOnQueueJobStepId",
|
||||
table: "DeploymentJobSteps",
|
||||
column: "DependsOnQueueJobStepId",
|
||||
principalTable: "DeploymentJobSteps",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Restrict);
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_DeploymentJobSteps_DeploymentJobs_QueueJobId",
|
||||
table: "DeploymentJobSteps",
|
||||
column: "QueueJobId",
|
||||
principalTable: "DeploymentJobs",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_DeploymentJobTargets_DeploymentJobs_QueueJobId",
|
||||
table: "DeploymentJobTargets",
|
||||
column: "QueueJobId",
|
||||
principalTable: "DeploymentJobs",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_Jobs_DeploymentExecutions_DeploymentId",
|
||||
table: "Jobs",
|
||||
column: "DeploymentId",
|
||||
principalTable: "DeploymentExecutions",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_DeploymentBatches_Templates_TemplateId",
|
||||
table: "DeploymentBatches");
|
||||
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_DeploymentExecutions_DeploymentBatches_DeploymentGroupId",
|
||||
table: "DeploymentExecutions");
|
||||
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_DeploymentExecutions_VirtualMachines_VirtualMachineId",
|
||||
table: "DeploymentExecutions");
|
||||
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_DeploymentJobSteps_DeploymentJobSteps_DependsOnQueueJobStepId",
|
||||
table: "DeploymentJobSteps");
|
||||
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_DeploymentJobSteps_DeploymentJobs_QueueJobId",
|
||||
table: "DeploymentJobSteps");
|
||||
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_DeploymentJobTargets_DeploymentJobs_QueueJobId",
|
||||
table: "DeploymentJobTargets");
|
||||
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_Jobs_DeploymentExecutions_DeploymentId",
|
||||
table: "Jobs");
|
||||
|
||||
migrationBuilder.DropPrimaryKey(
|
||||
name: "PK_DeploymentJobTargets",
|
||||
table: "DeploymentJobTargets");
|
||||
|
||||
migrationBuilder.DropPrimaryKey(
|
||||
name: "PK_DeploymentJobSteps",
|
||||
table: "DeploymentJobSteps");
|
||||
|
||||
migrationBuilder.DropPrimaryKey(
|
||||
name: "PK_DeploymentJobs",
|
||||
table: "DeploymentJobs");
|
||||
|
||||
migrationBuilder.DropUniqueConstraint(
|
||||
name: "AK_DeploymentExecutions_Id",
|
||||
table: "DeploymentExecutions");
|
||||
|
||||
migrationBuilder.DropPrimaryKey(
|
||||
name: "PK_DeploymentExecutions",
|
||||
table: "DeploymentExecutions");
|
||||
|
||||
migrationBuilder.DropPrimaryKey(
|
||||
name: "PK_DeploymentBatches",
|
||||
table: "DeploymentBatches");
|
||||
|
||||
migrationBuilder.RenameTable(
|
||||
name: "DeploymentJobTargets",
|
||||
newName: "QueueJobTargets");
|
||||
|
||||
migrationBuilder.RenameTable(
|
||||
name: "DeploymentJobSteps",
|
||||
newName: "QueueJobSteps");
|
||||
|
||||
migrationBuilder.RenameTable(
|
||||
name: "DeploymentJobs",
|
||||
newName: "QueueJobs");
|
||||
|
||||
migrationBuilder.RenameTable(
|
||||
name: "DeploymentExecutions",
|
||||
newName: "Deployments");
|
||||
|
||||
migrationBuilder.RenameTable(
|
||||
name: "DeploymentBatches",
|
||||
newName: "DeploymentGroups");
|
||||
|
||||
migrationBuilder.RenameIndex(
|
||||
name: "IX_DeploymentJobTargets_QueueJobId",
|
||||
table: "QueueJobTargets",
|
||||
newName: "IX_QueueJobTargets_QueueJobId");
|
||||
|
||||
migrationBuilder.RenameIndex(
|
||||
name: "IX_DeploymentJobSteps_QueueJobId",
|
||||
table: "QueueJobSteps",
|
||||
newName: "IX_QueueJobSteps_QueueJobId");
|
||||
|
||||
migrationBuilder.RenameIndex(
|
||||
name: "IX_DeploymentJobSteps_DependsOnQueueJobStepId",
|
||||
table: "QueueJobSteps",
|
||||
newName: "IX_QueueJobSteps_DependsOnQueueJobStepId");
|
||||
|
||||
migrationBuilder.RenameIndex(
|
||||
name: "IX_DeploymentExecutions_DeploymentGroupId",
|
||||
table: "Deployments",
|
||||
newName: "IX_Deployments_DeploymentGroupId");
|
||||
|
||||
migrationBuilder.RenameIndex(
|
||||
name: "IX_DeploymentBatches_TemplateId",
|
||||
table: "DeploymentGroups",
|
||||
newName: "IX_DeploymentGroups_TemplateId");
|
||||
|
||||
migrationBuilder.AddPrimaryKey(
|
||||
name: "PK_QueueJobTargets",
|
||||
table: "QueueJobTargets",
|
||||
column: "Id");
|
||||
|
||||
migrationBuilder.AddPrimaryKey(
|
||||
name: "PK_QueueJobSteps",
|
||||
table: "QueueJobSteps",
|
||||
column: "Id");
|
||||
|
||||
migrationBuilder.AddPrimaryKey(
|
||||
name: "PK_QueueJobs",
|
||||
table: "QueueJobs",
|
||||
column: "Id");
|
||||
|
||||
migrationBuilder.AddUniqueConstraint(
|
||||
name: "AK_Deployments_Id",
|
||||
table: "Deployments",
|
||||
column: "Id");
|
||||
|
||||
migrationBuilder.AddPrimaryKey(
|
||||
name: "PK_Deployments",
|
||||
table: "Deployments",
|
||||
columns: new[] { "VirtualMachineId", "DeploymentGroupId" });
|
||||
|
||||
migrationBuilder.AddPrimaryKey(
|
||||
name: "PK_DeploymentGroups",
|
||||
table: "DeploymentGroups",
|
||||
column: "Id");
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_DeploymentGroups_Templates_TemplateId",
|
||||
table: "DeploymentGroups",
|
||||
column: "TemplateId",
|
||||
principalTable: "Templates",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_Deployments_DeploymentGroups_DeploymentGroupId",
|
||||
table: "Deployments",
|
||||
column: "DeploymentGroupId",
|
||||
principalTable: "DeploymentGroups",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_Deployments_VirtualMachines_VirtualMachineId",
|
||||
table: "Deployments",
|
||||
column: "VirtualMachineId",
|
||||
principalTable: "VirtualMachines",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_Jobs_Deployments_DeploymentId",
|
||||
table: "Jobs",
|
||||
column: "DeploymentId",
|
||||
principalTable: "Deployments",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_QueueJobSteps_QueueJobSteps_DependsOnQueueJobStepId",
|
||||
table: "QueueJobSteps",
|
||||
column: "DependsOnQueueJobStepId",
|
||||
principalTable: "QueueJobSteps",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Restrict);
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_QueueJobSteps_QueueJobs_QueueJobId",
|
||||
table: "QueueJobSteps",
|
||||
column: "QueueJobId",
|
||||
principalTable: "QueueJobs",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_QueueJobTargets_QueueJobs_QueueJobId",
|
||||
table: "QueueJobTargets",
|
||||
column: "QueueJobId",
|
||||
principalTable: "QueueJobs",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
}
|
||||
}
|
||||
}
|
||||
1484
Migrations/20260516141719_RenameDeploymentAndJobColumns.Designer.cs
generated
Normal file
1484
Migrations/20260516141719_RenameDeploymentAndJobColumns.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
204
Migrations/20260516141719_RenameDeploymentAndJobColumns.cs
Normal file
204
Migrations/20260516141719_RenameDeploymentAndJobColumns.cs
Normal file
@@ -0,0 +1,204 @@
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class RenameDeploymentAndJobColumns : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_DeploymentExecutions_DeploymentBatches_DeploymentGroupId",
|
||||
table: "DeploymentExecutions");
|
||||
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_DeploymentJobSteps_DeploymentJobSteps_DependsOnQueueJobStepId",
|
||||
table: "DeploymentJobSteps");
|
||||
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_DeploymentJobSteps_DeploymentJobs_QueueJobId",
|
||||
table: "DeploymentJobSteps");
|
||||
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_DeploymentJobTargets_DeploymentJobs_QueueJobId",
|
||||
table: "DeploymentJobTargets");
|
||||
|
||||
migrationBuilder.RenameColumn(
|
||||
name: "QueueJobId",
|
||||
table: "DeploymentJobTargets",
|
||||
newName: "DeploymentJobId");
|
||||
|
||||
migrationBuilder.RenameColumn(
|
||||
name: "DeploymentGroupId",
|
||||
table: "DeploymentJobTargets",
|
||||
newName: "DeploymentBatchId");
|
||||
|
||||
migrationBuilder.RenameIndex(
|
||||
name: "IX_DeploymentJobTargets_QueueJobId",
|
||||
table: "DeploymentJobTargets",
|
||||
newName: "IX_DeploymentJobTargets_DeploymentJobId");
|
||||
|
||||
migrationBuilder.RenameColumn(
|
||||
name: "QueueJobId",
|
||||
table: "DeploymentJobSteps",
|
||||
newName: "DeploymentJobId");
|
||||
|
||||
migrationBuilder.RenameColumn(
|
||||
name: "DependsOnQueueJobStepId",
|
||||
table: "DeploymentJobSteps",
|
||||
newName: "DependsOnDeploymentJobStepId");
|
||||
|
||||
migrationBuilder.RenameIndex(
|
||||
name: "IX_DeploymentJobSteps_QueueJobId",
|
||||
table: "DeploymentJobSteps",
|
||||
newName: "IX_DeploymentJobSteps_DeploymentJobId");
|
||||
|
||||
migrationBuilder.RenameIndex(
|
||||
name: "IX_DeploymentJobSteps_DependsOnQueueJobStepId",
|
||||
table: "DeploymentJobSteps",
|
||||
newName: "IX_DeploymentJobSteps_DependsOnDeploymentJobStepId");
|
||||
|
||||
migrationBuilder.RenameColumn(
|
||||
name: "DeploymentGroupId",
|
||||
table: "DeploymentExecutions",
|
||||
newName: "DeploymentBatchId");
|
||||
|
||||
migrationBuilder.RenameIndex(
|
||||
name: "IX_DeploymentExecutions_DeploymentGroupId",
|
||||
table: "DeploymentExecutions",
|
||||
newName: "IX_DeploymentExecutions_DeploymentBatchId");
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_DeploymentExecutions_DeploymentBatches_DeploymentBatchId",
|
||||
table: "DeploymentExecutions",
|
||||
column: "DeploymentBatchId",
|
||||
principalTable: "DeploymentBatches",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_DeploymentJobSteps_DeploymentJobSteps_DependsOnDeploymentJobStepId",
|
||||
table: "DeploymentJobSteps",
|
||||
column: "DependsOnDeploymentJobStepId",
|
||||
principalTable: "DeploymentJobSteps",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Restrict);
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_DeploymentJobSteps_DeploymentJobs_DeploymentJobId",
|
||||
table: "DeploymentJobSteps",
|
||||
column: "DeploymentJobId",
|
||||
principalTable: "DeploymentJobs",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_DeploymentJobTargets_DeploymentJobs_DeploymentJobId",
|
||||
table: "DeploymentJobTargets",
|
||||
column: "DeploymentJobId",
|
||||
principalTable: "DeploymentJobs",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_DeploymentExecutions_DeploymentBatches_DeploymentBatchId",
|
||||
table: "DeploymentExecutions");
|
||||
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_DeploymentJobSteps_DeploymentJobSteps_DependsOnDeploymentJobStepId",
|
||||
table: "DeploymentJobSteps");
|
||||
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_DeploymentJobSteps_DeploymentJobs_DeploymentJobId",
|
||||
table: "DeploymentJobSteps");
|
||||
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_DeploymentJobTargets_DeploymentJobs_DeploymentJobId",
|
||||
table: "DeploymentJobTargets");
|
||||
|
||||
migrationBuilder.RenameColumn(
|
||||
name: "DeploymentJobId",
|
||||
table: "DeploymentJobTargets",
|
||||
newName: "QueueJobId");
|
||||
|
||||
migrationBuilder.RenameColumn(
|
||||
name: "DeploymentBatchId",
|
||||
table: "DeploymentJobTargets",
|
||||
newName: "DeploymentGroupId");
|
||||
|
||||
migrationBuilder.RenameIndex(
|
||||
name: "IX_DeploymentJobTargets_DeploymentJobId",
|
||||
table: "DeploymentJobTargets",
|
||||
newName: "IX_DeploymentJobTargets_QueueJobId");
|
||||
|
||||
migrationBuilder.RenameColumn(
|
||||
name: "DeploymentJobId",
|
||||
table: "DeploymentJobSteps",
|
||||
newName: "QueueJobId");
|
||||
|
||||
migrationBuilder.RenameColumn(
|
||||
name: "DependsOnDeploymentJobStepId",
|
||||
table: "DeploymentJobSteps",
|
||||
newName: "DependsOnQueueJobStepId");
|
||||
|
||||
migrationBuilder.RenameIndex(
|
||||
name: "IX_DeploymentJobSteps_DeploymentJobId",
|
||||
table: "DeploymentJobSteps",
|
||||
newName: "IX_DeploymentJobSteps_QueueJobId");
|
||||
|
||||
migrationBuilder.RenameIndex(
|
||||
name: "IX_DeploymentJobSteps_DependsOnDeploymentJobStepId",
|
||||
table: "DeploymentJobSteps",
|
||||
newName: "IX_DeploymentJobSteps_DependsOnQueueJobStepId");
|
||||
|
||||
migrationBuilder.RenameColumn(
|
||||
name: "DeploymentBatchId",
|
||||
table: "DeploymentExecutions",
|
||||
newName: "DeploymentGroupId");
|
||||
|
||||
migrationBuilder.RenameIndex(
|
||||
name: "IX_DeploymentExecutions_DeploymentBatchId",
|
||||
table: "DeploymentExecutions",
|
||||
newName: "IX_DeploymentExecutions_DeploymentGroupId");
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_DeploymentExecutions_DeploymentBatches_DeploymentGroupId",
|
||||
table: "DeploymentExecutions",
|
||||
column: "DeploymentGroupId",
|
||||
principalTable: "DeploymentBatches",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_DeploymentJobSteps_DeploymentJobSteps_DependsOnQueueJobStepId",
|
||||
table: "DeploymentJobSteps",
|
||||
column: "DependsOnQueueJobStepId",
|
||||
principalTable: "DeploymentJobSteps",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Restrict);
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_DeploymentJobSteps_DeploymentJobs_QueueJobId",
|
||||
table: "DeploymentJobSteps",
|
||||
column: "QueueJobId",
|
||||
principalTable: "DeploymentJobs",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_DeploymentJobTargets_DeploymentJobs_QueueJobId",
|
||||
table: "DeploymentJobTargets",
|
||||
column: "QueueJobId",
|
||||
principalTable: "DeploymentJobs",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -17,7 +17,7 @@ namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
{
|
||||
#pragma warning disable 612, 618
|
||||
modelBuilder
|
||||
.HasAnnotation("ProductVersion", "7.0.9")
|
||||
.HasAnnotation("ProductVersion", "10.0.8")
|
||||
.HasAnnotation("Relational:MaxIdentifierLength", 128);
|
||||
|
||||
SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder);
|
||||
@@ -67,7 +67,7 @@ namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
|
||||
b.HasIndex("TemplateId");
|
||||
|
||||
b.ToTable("DeploymentGroups");
|
||||
b.ToTable("DeploymentBatches", (string)null);
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.SelfService.Portal.Core.API.Models.DeploymentModel", b =>
|
||||
@@ -78,6 +78,7 @@ namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
|
||||
b.Property<Guid>("DeploymentGroupId")
|
||||
.HasColumnType("uniqueidentifier")
|
||||
.HasColumnName("DeploymentBatchId")
|
||||
.HasColumnOrder(2);
|
||||
|
||||
b.Property<DateTime>("Created")
|
||||
@@ -122,7 +123,118 @@ namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
|
||||
b.HasIndex("DeploymentGroupId");
|
||||
|
||||
b.ToTable("Deployments");
|
||||
b.ToTable("DeploymentExecutions", (string)null);
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.SelfService.Portal.Core.API.Models.DeploymentRuleModel", b =>
|
||||
{
|
||||
b.Property<Guid>("Id")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("uniqueidentifier")
|
||||
.HasColumnOrder(0)
|
||||
.HasDefaultValueSql("NEWID()");
|
||||
|
||||
b.Property<DateTime>("Created")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("datetime2")
|
||||
.HasColumnOrder(52)
|
||||
.HasDefaultValueSql("GETDATE()");
|
||||
|
||||
b.Property<string>("CreatedBy")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(53);
|
||||
|
||||
b.Property<string>("Description")
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(2);
|
||||
|
||||
b.Property<bool>("IsActive")
|
||||
.HasColumnType("bit")
|
||||
.HasColumnOrder(3);
|
||||
|
||||
b.Property<DateTime>("Modified")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("datetime2")
|
||||
.HasColumnOrder(50)
|
||||
.HasDefaultValueSql("GETDATE()");
|
||||
|
||||
b.Property<string>("ModifiedBy")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(51);
|
||||
|
||||
b.Property<string>("Name")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(1);
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.ToTable("DeploymentRules");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.SelfService.Portal.Core.API.Models.DeploymentRuleStepModel", b =>
|
||||
{
|
||||
b.Property<Guid>("Id")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("uniqueidentifier")
|
||||
.HasColumnOrder(0)
|
||||
.HasDefaultValueSql("NEWID()");
|
||||
|
||||
b.Property<DateTime>("Created")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("datetime2")
|
||||
.HasColumnOrder(52)
|
||||
.HasDefaultValueSql("GETDATE()");
|
||||
|
||||
b.Property<string>("CreatedBy")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(53);
|
||||
|
||||
b.Property<Guid>("DeploymentRuleId")
|
||||
.HasColumnType("uniqueidentifier")
|
||||
.HasColumnOrder(1);
|
||||
|
||||
b.Property<string>("MetadataJson")
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(6);
|
||||
|
||||
b.Property<DateTime>("Modified")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("datetime2")
|
||||
.HasColumnOrder(50)
|
||||
.HasDefaultValueSql("GETDATE()");
|
||||
|
||||
b.Property<string>("ModifiedBy")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(51);
|
||||
|
||||
b.Property<string>("Name")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(3);
|
||||
|
||||
b.Property<bool>("RequiresApproval")
|
||||
.HasColumnType("bit")
|
||||
.HasColumnOrder(5);
|
||||
|
||||
b.Property<int>("SortOrder")
|
||||
.HasColumnType("int")
|
||||
.HasColumnOrder(2);
|
||||
|
||||
b.Property<string>("StepType")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(4);
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.HasIndex("DeploymentRuleId");
|
||||
|
||||
b.ToTable("DeploymentRuleSteps");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.SelfService.Portal.Core.API.Models.DomainModel", b =>
|
||||
@@ -218,10 +330,6 @@ namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
.HasColumnOrder(0)
|
||||
.HasDefaultValueSql("NEWID()");
|
||||
|
||||
b.Property<bool>("CloudEnabled")
|
||||
.HasColumnType("bit")
|
||||
.HasColumnOrder(2);
|
||||
|
||||
b.Property<DateTime>("Created")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("datetime2")
|
||||
@@ -233,6 +341,15 @@ namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(53);
|
||||
|
||||
b.Property<string>("EnvironmentType")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(2);
|
||||
|
||||
b.Property<string>("MetadataJson")
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(6);
|
||||
|
||||
b.Property<DateTime>("Modified")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("datetime2")
|
||||
@@ -249,6 +366,18 @@ namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(1);
|
||||
|
||||
b.Property<string>("ProviderType")
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(3);
|
||||
|
||||
b.Property<string>("SubscriptionId")
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(5);
|
||||
|
||||
b.Property<string>("TenantId")
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(4);
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.ToTable("Environments");
|
||||
@@ -464,6 +593,244 @@ namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
b.ToTable("Options");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.SelfService.Portal.Core.API.Models.QueueJobModel", b =>
|
||||
{
|
||||
b.Property<Guid>("Id")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("uniqueidentifier")
|
||||
.HasColumnOrder(0)
|
||||
.HasDefaultValueSql("NEWID()");
|
||||
|
||||
b.Property<int>("Attempts")
|
||||
.HasColumnType("int")
|
||||
.HasColumnOrder(4);
|
||||
|
||||
b.Property<DateTime>("Created")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("datetime2")
|
||||
.HasColumnOrder(52)
|
||||
.HasDefaultValueSql("GETDATE()");
|
||||
|
||||
b.Property<string>("CreatedBy")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(53);
|
||||
|
||||
b.Property<string>("ErrorMessage")
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(10);
|
||||
|
||||
b.Property<DateTime?>("Finished")
|
||||
.HasColumnType("datetime2")
|
||||
.HasColumnOrder(7);
|
||||
|
||||
b.Property<string>("LockedBy")
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(9);
|
||||
|
||||
b.Property<DateTime?>("LockedUntil")
|
||||
.HasColumnType("datetime2")
|
||||
.HasColumnOrder(8);
|
||||
|
||||
b.Property<int>("MaxAttempts")
|
||||
.HasColumnType("int")
|
||||
.HasColumnOrder(5);
|
||||
|
||||
b.Property<string>("MetadataJson")
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(11);
|
||||
|
||||
b.Property<DateTime>("Modified")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("datetime2")
|
||||
.HasColumnOrder(50)
|
||||
.HasDefaultValueSql("GETDATE()");
|
||||
|
||||
b.Property<string>("ModifiedBy")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(51);
|
||||
|
||||
b.Property<string>("PayloadJson")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(3);
|
||||
|
||||
b.Property<string>("RuleSnapshotJson")
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(12);
|
||||
|
||||
b.Property<DateTime?>("Started")
|
||||
.HasColumnType("datetime2")
|
||||
.HasColumnOrder(6);
|
||||
|
||||
b.Property<string>("Status")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(2);
|
||||
|
||||
b.Property<string>("Type")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(1);
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.ToTable("DeploymentJobs", (string)null);
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.SelfService.Portal.Core.API.Models.QueueJobStepModel", b =>
|
||||
{
|
||||
b.Property<Guid>("Id")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("uniqueidentifier")
|
||||
.HasColumnOrder(0)
|
||||
.HasDefaultValueSql("NEWID()");
|
||||
|
||||
b.Property<string>("ApprovalComment")
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(10);
|
||||
|
||||
b.Property<DateTime?>("ApprovedAt")
|
||||
.HasColumnType("datetime2")
|
||||
.HasColumnOrder(8);
|
||||
|
||||
b.Property<string>("ApprovedBy")
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(9);
|
||||
|
||||
b.Property<DateTime>("Created")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("datetime2")
|
||||
.HasColumnOrder(52)
|
||||
.HasDefaultValueSql("GETDATE()");
|
||||
|
||||
b.Property<string>("CreatedBy")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(53);
|
||||
|
||||
b.Property<Guid?>("DependsOnQueueJobStepId")
|
||||
.HasColumnType("uniqueidentifier")
|
||||
.HasColumnName("DependsOnDeploymentJobStepId")
|
||||
.HasColumnOrder(2);
|
||||
|
||||
b.Property<string>("MetadataJson")
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(7);
|
||||
|
||||
b.Property<DateTime>("Modified")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("datetime2")
|
||||
.HasColumnOrder(50)
|
||||
.HasDefaultValueSql("GETDATE()");
|
||||
|
||||
b.Property<string>("ModifiedBy")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(51);
|
||||
|
||||
b.Property<string>("Name")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(4);
|
||||
|
||||
b.Property<Guid>("QueueJobId")
|
||||
.HasColumnType("uniqueidentifier")
|
||||
.HasColumnName("DeploymentJobId")
|
||||
.HasColumnOrder(1);
|
||||
|
||||
b.Property<int>("SortOrder")
|
||||
.HasColumnType("int")
|
||||
.HasColumnOrder(3);
|
||||
|
||||
b.Property<string>("Status")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(6);
|
||||
|
||||
b.Property<string>("StepType")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(5);
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.HasIndex("DependsOnQueueJobStepId");
|
||||
|
||||
b.HasIndex("QueueJobId");
|
||||
|
||||
b.ToTable("DeploymentJobSteps", (string)null);
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.SelfService.Portal.Core.API.Models.QueueJobTargetModel", b =>
|
||||
{
|
||||
b.Property<Guid>("Id")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("uniqueidentifier")
|
||||
.HasColumnOrder(0)
|
||||
.HasDefaultValueSql("NEWID()");
|
||||
|
||||
b.Property<int>("Attempts")
|
||||
.HasColumnType("int")
|
||||
.HasColumnOrder(6);
|
||||
|
||||
b.Property<DateTime>("Created")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("datetime2")
|
||||
.HasColumnOrder(52)
|
||||
.HasDefaultValueSql("GETDATE()");
|
||||
|
||||
b.Property<string>("CreatedBy")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(53);
|
||||
|
||||
b.Property<Guid>("DeploymentGroupId")
|
||||
.HasColumnType("uniqueidentifier")
|
||||
.HasColumnName("DeploymentBatchId")
|
||||
.HasColumnOrder(3);
|
||||
|
||||
b.Property<string>("ErrorMessage")
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(7);
|
||||
|
||||
b.Property<DateTime>("Modified")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("datetime2")
|
||||
.HasColumnOrder(50)
|
||||
.HasDefaultValueSql("GETDATE()");
|
||||
|
||||
b.Property<string>("ModifiedBy")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(51);
|
||||
|
||||
b.Property<Guid>("QueueJobId")
|
||||
.HasColumnType("uniqueidentifier")
|
||||
.HasColumnName("DeploymentJobId")
|
||||
.HasColumnOrder(1);
|
||||
|
||||
b.Property<string>("Status")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(5);
|
||||
|
||||
b.Property<Guid>("TemplateId")
|
||||
.HasColumnType("uniqueidentifier")
|
||||
.HasColumnOrder(4);
|
||||
|
||||
b.Property<Guid>("VirtualMachineId")
|
||||
.HasColumnType("uniqueidentifier")
|
||||
.HasColumnOrder(2);
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.HasIndex("QueueJobId");
|
||||
|
||||
b.ToTable("DeploymentJobTargets", (string)null);
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.SelfService.Portal.Core.API.Models.RunbookModel", b =>
|
||||
{
|
||||
b.Property<Guid>("Id")
|
||||
@@ -533,6 +900,14 @@ namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(2);
|
||||
|
||||
b.Property<string>("IconKey")
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(4);
|
||||
|
||||
b.Property<bool>("IsCloudService")
|
||||
.HasColumnType("bit")
|
||||
.HasColumnOrder(3);
|
||||
|
||||
b.Property<DateTime>("Modified")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("datetime2")
|
||||
@@ -554,7 +929,7 @@ namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
b.ToTable("Services");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.SelfService.Portal.Core.API.Models.TemplateCategoryModel", b =>
|
||||
modelBuilder.Entity("Microsoft.SelfService.Portal.Core.API.Models.ServiceRoleDefinitionModel", b =>
|
||||
{
|
||||
b.Property<Guid>("Id")
|
||||
.ValueGeneratedOnAdd()
|
||||
@@ -573,6 +948,73 @@ namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(53);
|
||||
|
||||
b.Property<string>("Description")
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(4);
|
||||
|
||||
b.Property<string>("Key")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(2);
|
||||
|
||||
b.Property<DateTime>("Modified")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("datetime2")
|
||||
.HasColumnOrder(50)
|
||||
.HasDefaultValueSql("GETDATE()");
|
||||
|
||||
b.Property<string>("ModifiedBy")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(51);
|
||||
|
||||
b.Property<string>("Name")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(3);
|
||||
|
||||
b.Property<Guid>("ServiceId")
|
||||
.HasColumnType("uniqueidentifier")
|
||||
.HasColumnOrder(1);
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.HasIndex("ServiceId");
|
||||
|
||||
b.ToTable("ServiceRoleDefinitions");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.SelfService.Portal.Core.API.Models.TemplateCategoryModel", b =>
|
||||
{
|
||||
b.Property<Guid>("Id")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("uniqueidentifier")
|
||||
.HasColumnOrder(0)
|
||||
.HasDefaultValueSql("NEWID()");
|
||||
|
||||
b.Property<string>("Color")
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(5);
|
||||
|
||||
b.Property<DateTime>("Created")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("datetime2")
|
||||
.HasColumnOrder(52)
|
||||
.HasDefaultValueSql("GETDATE()");
|
||||
|
||||
b.Property<string>("CreatedBy")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(53);
|
||||
|
||||
b.Property<string>("Description")
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(3);
|
||||
|
||||
b.Property<bool>("IsActive")
|
||||
.HasColumnType("bit")
|
||||
.HasColumnOrder(4);
|
||||
|
||||
b.Property<DateTime>("Modified")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("datetime2")
|
||||
@@ -589,19 +1031,10 @@ namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(2);
|
||||
|
||||
b.Property<string>("ParentCategoryName")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(3);
|
||||
|
||||
b.Property<Guid>("ServiceId")
|
||||
.HasColumnType("uniqueidentifier")
|
||||
.HasColumnOrder(1);
|
||||
|
||||
b.Property<int>("showOrder")
|
||||
.HasColumnType("int")
|
||||
.HasColumnOrder(4);
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.HasIndex("ServiceId");
|
||||
@@ -617,10 +1050,6 @@ namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
.HasColumnOrder(0)
|
||||
.HasDefaultValueSql("NEWID()");
|
||||
|
||||
b.Property<bool>("CloudTemplate")
|
||||
.HasColumnType("bit")
|
||||
.HasColumnOrder(2);
|
||||
|
||||
b.Property<DateTime>("Created")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("datetime2")
|
||||
@@ -632,15 +1061,19 @@ namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(53);
|
||||
|
||||
b.Property<Guid?>("DeploymentRuleId")
|
||||
.HasColumnType("uniqueidentifier")
|
||||
.HasColumnOrder(6);
|
||||
|
||||
b.Property<string>("Description")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(4);
|
||||
.HasColumnOrder(3);
|
||||
|
||||
b.Property<string>("JSONData")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(5);
|
||||
.HasColumnOrder(4);
|
||||
|
||||
b.Property<DateTime>("Modified")
|
||||
.ValueGeneratedOnAdd()
|
||||
@@ -659,15 +1092,18 @@ namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
.HasColumnOrder(1);
|
||||
|
||||
b.Property<Guid>("TemplateCategoryId")
|
||||
.HasColumnType("uniqueidentifier");
|
||||
.HasColumnType("uniqueidentifier")
|
||||
.HasColumnOrder(5);
|
||||
|
||||
b.Property<string>("Version")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(3);
|
||||
.HasColumnOrder(2);
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.HasIndex("DeploymentRuleId");
|
||||
|
||||
b.HasIndex("TemplateCategoryId");
|
||||
|
||||
b.ToTable("Templates");
|
||||
@@ -732,10 +1168,18 @@ namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(53);
|
||||
|
||||
b.Property<Guid>("DomainID")
|
||||
b.Property<Guid?>("DomainID")
|
||||
.HasColumnType("uniqueidentifier")
|
||||
.HasColumnOrder(1);
|
||||
|
||||
b.Property<string>("ExternalId")
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(3);
|
||||
|
||||
b.Property<string>("MetadataJson")
|
||||
.HasColumnType("nvarchar(max)")
|
||||
.HasColumnOrder(4);
|
||||
|
||||
b.Property<DateTime>("Modified")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("datetime2")
|
||||
@@ -789,6 +1233,17 @@ namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
b.Navigation("VirtualMachine");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.SelfService.Portal.Core.API.Models.DeploymentRuleStepModel", b =>
|
||||
{
|
||||
b.HasOne("Microsoft.SelfService.Portal.Core.API.Models.DeploymentRuleModel", "DeploymentRule")
|
||||
.WithMany("Steps")
|
||||
.HasForeignKey("DeploymentRuleId")
|
||||
.OnDelete(DeleteBehavior.Cascade)
|
||||
.IsRequired();
|
||||
|
||||
b.Navigation("DeploymentRule");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.SelfService.Portal.Core.API.Models.EnvironmentDomainsModel", b =>
|
||||
{
|
||||
b.HasOne("Microsoft.SelfService.Portal.Core.API.Models.DomainModel", "Domain")
|
||||
@@ -850,6 +1305,46 @@ namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
b.Navigation("OptionCategory");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.SelfService.Portal.Core.API.Models.QueueJobStepModel", b =>
|
||||
{
|
||||
b.HasOne("Microsoft.SelfService.Portal.Core.API.Models.QueueJobStepModel", "DependsOnQueueJobStep")
|
||||
.WithMany()
|
||||
.HasForeignKey("DependsOnQueueJobStepId")
|
||||
.OnDelete(DeleteBehavior.Restrict);
|
||||
|
||||
b.HasOne("Microsoft.SelfService.Portal.Core.API.Models.QueueJobModel", "QueueJob")
|
||||
.WithMany("Steps")
|
||||
.HasForeignKey("QueueJobId")
|
||||
.OnDelete(DeleteBehavior.Cascade)
|
||||
.IsRequired();
|
||||
|
||||
b.Navigation("DependsOnQueueJobStep");
|
||||
|
||||
b.Navigation("QueueJob");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.SelfService.Portal.Core.API.Models.QueueJobTargetModel", b =>
|
||||
{
|
||||
b.HasOne("Microsoft.SelfService.Portal.Core.API.Models.QueueJobModel", "QueueJob")
|
||||
.WithMany("Targets")
|
||||
.HasForeignKey("QueueJobId")
|
||||
.OnDelete(DeleteBehavior.Cascade)
|
||||
.IsRequired();
|
||||
|
||||
b.Navigation("QueueJob");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.SelfService.Portal.Core.API.Models.ServiceRoleDefinitionModel", b =>
|
||||
{
|
||||
b.HasOne("Microsoft.SelfService.Portal.Core.API.Models.ServiceModel", "Service")
|
||||
.WithMany("RoleDefinitions")
|
||||
.HasForeignKey("ServiceId")
|
||||
.OnDelete(DeleteBehavior.Cascade)
|
||||
.IsRequired();
|
||||
|
||||
b.Navigation("Service");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.SelfService.Portal.Core.API.Models.TemplateCategoryModel", b =>
|
||||
{
|
||||
b.HasOne("Microsoft.SelfService.Portal.Core.API.Models.ServiceModel", "Service")
|
||||
@@ -863,12 +1358,18 @@ namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
|
||||
modelBuilder.Entity("Microsoft.SelfService.Portal.Core.API.Models.TemplateModel", b =>
|
||||
{
|
||||
b.HasOne("Microsoft.SelfService.Portal.Core.API.Models.DeploymentRuleModel", "DeploymentRule")
|
||||
.WithMany()
|
||||
.HasForeignKey("DeploymentRuleId");
|
||||
|
||||
b.HasOne("Microsoft.SelfService.Portal.Core.API.Models.TemplateCategoryModel", "TemplateCategory")
|
||||
.WithMany("Templates")
|
||||
.HasForeignKey("TemplateCategoryId")
|
||||
.OnDelete(DeleteBehavior.Cascade)
|
||||
.IsRequired();
|
||||
|
||||
b.Navigation("DeploymentRule");
|
||||
|
||||
b.Navigation("TemplateCategory");
|
||||
});
|
||||
|
||||
@@ -895,9 +1396,7 @@ namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
{
|
||||
b.HasOne("Microsoft.SelfService.Portal.Core.API.Models.DomainModel", "Domain")
|
||||
.WithMany("VirtualMachines")
|
||||
.HasForeignKey("DomainID")
|
||||
.OnDelete(DeleteBehavior.Cascade)
|
||||
.IsRequired();
|
||||
.HasForeignKey("DomainID");
|
||||
|
||||
b.Navigation("Domain");
|
||||
});
|
||||
@@ -912,6 +1411,11 @@ namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
b.Navigation("Jobs");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.SelfService.Portal.Core.API.Models.DeploymentRuleModel", b =>
|
||||
{
|
||||
b.Navigation("Steps");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.SelfService.Portal.Core.API.Models.DomainModel", b =>
|
||||
{
|
||||
b.Navigation("EnvironmentDomains");
|
||||
@@ -934,6 +1438,13 @@ namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
b.Navigation("TemplateOptions");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.SelfService.Portal.Core.API.Models.QueueJobModel", b =>
|
||||
{
|
||||
b.Navigation("Steps");
|
||||
|
||||
b.Navigation("Targets");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.SelfService.Portal.Core.API.Models.RunbookModel", b =>
|
||||
{
|
||||
b.Navigation("Events");
|
||||
@@ -943,6 +1454,8 @@ namespace Microsoft.SelfService.Portal.Core.API.Migrations
|
||||
|
||||
modelBuilder.Entity("Microsoft.SelfService.Portal.Core.API.Models.ServiceModel", b =>
|
||||
{
|
||||
b.Navigation("RoleDefinitions");
|
||||
|
||||
b.Navigation("TemplateCategories");
|
||||
});
|
||||
|
||||
|
||||
@@ -9,13 +9,13 @@ namespace Microsoft.SelfService.Portal.Core.API.Models
|
||||
public DateTime Modified { get; set; } = DateTime.Now;
|
||||
[Column(Order = 51)]
|
||||
//[DatabaseGenerated(DatabaseGeneratedOption.Computed)]
|
||||
public string ModifiedBy { get; set; } = new HttpContextAccessor().HttpContext.User.Identity.Name;
|
||||
public string ModifiedBy { get; set; } = "System";
|
||||
|
||||
[Column(Order = 52)]
|
||||
//[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
||||
public DateTime Created { get; set; } = DateTime.Now;
|
||||
[Column(Order = 53)]
|
||||
//[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
||||
public string CreatedBy { get; set; } = new HttpContextAccessor().HttpContext.User.Identity.Name;
|
||||
public string CreatedBy { get; set; } = "System";
|
||||
}
|
||||
}
|
||||
|
||||
@@ -22,7 +22,7 @@ namespace Microsoft.SelfService.Portal.Core.API.Models
|
||||
[Column(Order = 51)]
|
||||
[DefaultValue("System")]
|
||||
//[DatabaseGenerated(DatabaseGeneratedOption.Computed)]
|
||||
public string ModifiedBy { get; set; } = new HttpContextAccessor().HttpContext.User.Identity.Name;
|
||||
public string ModifiedBy { get; set; } = "System";
|
||||
|
||||
[Column(Order = 52)]
|
||||
[DefaultValueSql("GETDATE()")]
|
||||
@@ -33,6 +33,6 @@ namespace Microsoft.SelfService.Portal.Core.API.Models
|
||||
[DefaultValue("System")]
|
||||
//[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
||||
//public string CreatedBy { get; set; } = "CCIS-P01S01-CM\\ASA_SSP_Admin";
|
||||
public string CreatedBy { get; set; } = new HttpContextAccessor().HttpContext.User.Identity.Name;
|
||||
public string CreatedBy { get; set; } = "System";
|
||||
}
|
||||
}
|
||||
|
||||
46
Models/DeploymentJobModel.cs
Normal file
46
Models/DeploymentJobModel.cs
Normal file
@@ -0,0 +1,46 @@
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Models
|
||||
{
|
||||
public class QueueJobModel : BaseModel
|
||||
{
|
||||
[Column(Order = 1)]
|
||||
public string Type { get; set; }
|
||||
|
||||
[Column(Order = 2)]
|
||||
public string Status { get; set; } = QueueJobStatus.Pending;
|
||||
|
||||
[Column(Order = 3)]
|
||||
public string PayloadJson { get; set; }
|
||||
|
||||
[Column(Order = 4)]
|
||||
public int Attempts { get; set; }
|
||||
|
||||
[Column(Order = 5)]
|
||||
public int MaxAttempts { get; set; } = 3;
|
||||
|
||||
[Column(Order = 6)]
|
||||
public DateTime? Started { get; set; }
|
||||
|
||||
[Column(Order = 7)]
|
||||
public DateTime? Finished { get; set; }
|
||||
|
||||
[Column(Order = 8)]
|
||||
public DateTime? LockedUntil { get; set; }
|
||||
|
||||
[Column(Order = 9)]
|
||||
public string? LockedBy { get; set; }
|
||||
|
||||
[Column(Order = 10)]
|
||||
public string? ErrorMessage { get; set; }
|
||||
|
||||
[Column(Order = 11)]
|
||||
public string? MetadataJson { get; set; }
|
||||
|
||||
[Column(Order = 12)]
|
||||
public string? RuleSnapshotJson { get; set; }
|
||||
|
||||
public ICollection<QueueJobTargetModel> Targets { get; set; } = new List<QueueJobTargetModel>();
|
||||
public ICollection<QueueJobStepModel> Steps { get; set; } = new List<QueueJobStepModel>();
|
||||
}
|
||||
}
|
||||
40
Models/DeploymentJobStepModel.cs
Normal file
40
Models/DeploymentJobStepModel.cs
Normal file
@@ -0,0 +1,40 @@
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Models
|
||||
{
|
||||
public class QueueJobStepModel : BaseModel
|
||||
{
|
||||
[Column(Order = 1)]
|
||||
public Guid QueueJobId { get; set; }
|
||||
|
||||
[Column(Order = 2)]
|
||||
public Guid? DependsOnQueueJobStepId { get; set; }
|
||||
|
||||
[Column(Order = 3)]
|
||||
public int SortOrder { get; set; }
|
||||
|
||||
[Column(Order = 4)]
|
||||
public string Name { get; set; }
|
||||
|
||||
[Column(Order = 5)]
|
||||
public string StepType { get; set; } = QueueJobStepType.Provision;
|
||||
|
||||
[Column(Order = 6)]
|
||||
public string Status { get; set; } = QueueJobStatus.Pending;
|
||||
|
||||
[Column(Order = 7)]
|
||||
public string? MetadataJson { get; set; }
|
||||
|
||||
[Column(Order = 8)]
|
||||
public DateTime? ApprovedAt { get; set; }
|
||||
|
||||
[Column(Order = 9)]
|
||||
public string? ApprovedBy { get; set; }
|
||||
|
||||
[Column(Order = 10)]
|
||||
public string? ApprovalComment { get; set; }
|
||||
|
||||
public QueueJobModel QueueJob { get; set; }
|
||||
public QueueJobStepModel? DependsOnQueueJobStep { get; set; }
|
||||
}
|
||||
}
|
||||
30
Models/DeploymentJobTargetModel.cs
Normal file
30
Models/DeploymentJobTargetModel.cs
Normal file
@@ -0,0 +1,30 @@
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Models
|
||||
{
|
||||
public class QueueJobTargetModel : BaseModel
|
||||
{
|
||||
[Column(Order = 1)]
|
||||
public Guid QueueJobId { get; set; }
|
||||
|
||||
[Column(Order = 2)]
|
||||
public Guid VirtualMachineId { get; set; }
|
||||
|
||||
[Column(Order = 3)]
|
||||
public Guid DeploymentGroupId { get; set; }
|
||||
|
||||
[Column(Order = 4)]
|
||||
public Guid TemplateId { get; set; }
|
||||
|
||||
[Column(Order = 5)]
|
||||
public string Status { get; set; } = QueueJobStatus.Pending;
|
||||
|
||||
[Column(Order = 6)]
|
||||
public int Attempts { get; set; }
|
||||
|
||||
[Column(Order = 7)]
|
||||
public string? ErrorMessage { get; set; }
|
||||
|
||||
public QueueJobModel QueueJob { get; set; }
|
||||
}
|
||||
}
|
||||
18
Models/DeploymentRuleModel.cs
Normal file
18
Models/DeploymentRuleModel.cs
Normal file
@@ -0,0 +1,18 @@
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Models
|
||||
{
|
||||
public class DeploymentRuleModel : BaseModel
|
||||
{
|
||||
[Column(Order = 1)]
|
||||
public string Name { get; set; }
|
||||
|
||||
[Column(Order = 2)]
|
||||
public string? Description { get; set; }
|
||||
|
||||
[Column(Order = 3)]
|
||||
public bool IsActive { get; set; } = true;
|
||||
|
||||
public ICollection<DeploymentRuleStepModel> Steps { get; set; } = new List<DeploymentRuleStepModel>();
|
||||
}
|
||||
}
|
||||
27
Models/DeploymentRuleStepModel.cs
Normal file
27
Models/DeploymentRuleStepModel.cs
Normal file
@@ -0,0 +1,27 @@
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Models
|
||||
{
|
||||
public class DeploymentRuleStepModel : BaseModel
|
||||
{
|
||||
[Column(Order = 1)]
|
||||
public Guid DeploymentRuleId { get; set; }
|
||||
|
||||
[Column(Order = 2)]
|
||||
public int SortOrder { get; set; }
|
||||
|
||||
[Column(Order = 3)]
|
||||
public string Name { get; set; }
|
||||
|
||||
[Column(Order = 4)]
|
||||
public string StepType { get; set; } = QueueJobStepType.Provision;
|
||||
|
||||
[Column(Order = 5)]
|
||||
public bool RequiresApproval { get; set; }
|
||||
|
||||
[Column(Order = 6)]
|
||||
public string? MetadataJson { get; set; }
|
||||
|
||||
public DeploymentRuleModel DeploymentRule { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -8,7 +8,19 @@ namespace Microsoft.SelfService.Portal.Core.API.Models
|
||||
public string Name { get; set; }
|
||||
|
||||
[Column(Order = 2)]
|
||||
public bool CloudEnabled { get; set; }
|
||||
public string EnvironmentType { get; set; } = EnvironmentTypes.OnPrem;
|
||||
|
||||
[Column(Order = 3)]
|
||||
public string? ProviderType { get; set; }
|
||||
|
||||
[Column(Order = 4)]
|
||||
public string? TenantId { get; set; }
|
||||
|
||||
[Column(Order = 5)]
|
||||
public string? SubscriptionId { get; set; }
|
||||
|
||||
[Column(Order = 6)]
|
||||
public string? MetadataJson { get; set; }
|
||||
|
||||
public ICollection<EnvironmentDomainsModel> EnvironmentDomains { get; set; }
|
||||
}
|
||||
|
||||
9
Models/EnvironmentTypes.cs
Normal file
9
Models/EnvironmentTypes.cs
Normal file
@@ -0,0 +1,9 @@
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Models
|
||||
{
|
||||
public static class EnvironmentTypes
|
||||
{
|
||||
public const string OnPrem = "OnPrem";
|
||||
public const string AzureTenant = "AzureTenant";
|
||||
public const string M365Tenant = "M365Tenant";
|
||||
}
|
||||
}
|
||||
13
Models/QueueJobStatus.cs
Normal file
13
Models/QueueJobStatus.cs
Normal file
@@ -0,0 +1,13 @@
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Models
|
||||
{
|
||||
public static class QueueJobStatus
|
||||
{
|
||||
public const string Pending = "Pending";
|
||||
public const string Running = "Running";
|
||||
public const string WaitingForApproval = "WaitingForApproval";
|
||||
public const string Succeeded = "Succeeded";
|
||||
public const string Failed = "Failed";
|
||||
public const string Rejected = "Rejected";
|
||||
public const string Cancelled = "Cancelled";
|
||||
}
|
||||
}
|
||||
8
Models/QueueJobStepType.cs
Normal file
8
Models/QueueJobStepType.cs
Normal file
@@ -0,0 +1,8 @@
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Models
|
||||
{
|
||||
public static class QueueJobStepType
|
||||
{
|
||||
public const string Provision = "Provision";
|
||||
public const string Approval = "Approval";
|
||||
}
|
||||
}
|
||||
8
Models/QueueJobType.cs
Normal file
8
Models/QueueJobType.cs
Normal file
@@ -0,0 +1,8 @@
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Models
|
||||
{
|
||||
public static class QueueJobType
|
||||
{
|
||||
public const string TemplateJsonChanged = "TemplateJsonChanged";
|
||||
public const string DeploymentRequested = "DeploymentRequested";
|
||||
}
|
||||
}
|
||||
@@ -8,7 +8,13 @@ namespace Microsoft.SelfService.Portal.Core.API.Models
|
||||
public string Name { get; set; }
|
||||
[Column(Order = 2)]
|
||||
public string Description { get; set; }
|
||||
|
||||
[Column(Order = 3)]
|
||||
public bool IsCloudService { get; set; }
|
||||
[Column(Order = 4)]
|
||||
public string? IconKey { get; set; }
|
||||
|
||||
public ICollection<TemplateCategoryModel> TemplateCategories { get; set; }
|
||||
public ICollection<TemplateCategoryModel> TemplateCategories { get; set; } = new List<TemplateCategoryModel>();
|
||||
public ICollection<ServiceRoleDefinitionModel> RoleDefinitions { get; set; } = new List<ServiceRoleDefinitionModel>();
|
||||
}
|
||||
}
|
||||
|
||||
21
Models/ServiceRoleDefinitionModel.cs
Normal file
21
Models/ServiceRoleDefinitionModel.cs
Normal file
@@ -0,0 +1,21 @@
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
|
||||
namespace Microsoft.SelfService.Portal.Core.API.Models
|
||||
{
|
||||
public class ServiceRoleDefinitionModel : BaseModel
|
||||
{
|
||||
[Column(Order = 1)]
|
||||
public Guid ServiceId { get; set; }
|
||||
|
||||
[Column(Order = 2)]
|
||||
public string Key { get; set; } = string.Empty;
|
||||
|
||||
[Column(Order = 3)]
|
||||
public string Name { get; set; } = string.Empty;
|
||||
|
||||
[Column(Order = 4)]
|
||||
public string? Description { get; set; }
|
||||
|
||||
public ServiceModel Service { get; set; } = null!;
|
||||
}
|
||||
}
|
||||
@@ -7,14 +7,16 @@ namespace Microsoft.SelfService.Portal.Core.API.Models
|
||||
[Column(Order = 1)]
|
||||
public Guid ServiceId { get; set; }
|
||||
[Column(Order = 2)]
|
||||
public string Name { get; set; }
|
||||
public string Name { get; set; } = string.Empty;
|
||||
[Column(Order = 3)]
|
||||
public string ParentCategoryName { get; set; }
|
||||
public string? Description { get; set; }
|
||||
[Column(Order = 4)]
|
||||
public int showOrder { get; set; }
|
||||
public bool IsActive { get; set; } = true;
|
||||
[Column(Order = 5)]
|
||||
public string? Color { get; set; }
|
||||
|
||||
public ServiceModel Service { get; set; }
|
||||
public ServiceModel Service { get; set; } = null!;
|
||||
|
||||
public ICollection<TemplateModel> Templates { get; set; }
|
||||
public ICollection<TemplateModel> Templates { get; set; } = new List<TemplateModel>();
|
||||
}
|
||||
}
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user