Compare commits

..

No commits in common. "692b1bfef33c7978be96a8918592992f60f850e4" and "ff9c7c94345b9c905622e5b334af18bddd5a1a22" have entirely different histories.

7 changed files with 3 additions and 3441 deletions

View File

@ -1,41 +0,0 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace Marco.Pms.DataAccess.Migrations
{
/// <inheritdoc />
public partial class EnhancedWorkItemForParentId_Description : Migration
{
/// <inheritdoc />
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.AddColumn<string>(
name: "Description",
table: "WorkItems",
type: "longtext",
nullable: true)
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<Guid>(
name: "ParentTaskId",
table: "WorkItems",
type: "char(36)",
nullable: true,
collation: "ascii_general_ci");
}
/// <inheritdoc />
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropColumn(
name: "Description",
table: "WorkItems");
migrationBuilder.DropColumn(
name: "ParentTaskId",
table: "WorkItems");
}
}
}

View File

@ -2176,12 +2176,6 @@ namespace Marco.Pms.DataAccess.Migrations
b.Property<double>("CompletedWork")
.HasColumnType("double");
b.Property<string>("Description")
.HasColumnType("longtext");
b.Property<Guid?>("ParentTaskId")
.HasColumnType("char(36)");
b.Property<double>("PlannedWork")
.HasColumnType("double");

View File

@ -11,7 +11,5 @@ namespace Marco.Pms.Model.Dtos.Project
public Guid ActivityID { get; set; }
public int PlannedWork { get; set; }
public int CompletedWork { get; set; }
public Guid? ParentTaskId { get; set; }
public string? Comment { get; set; }
}
}

View File

@ -59,9 +59,7 @@ namespace Marco.Pms.Model.Mapper
WorkCategoryId = model.WorkCategoryId,
TaskDate = DateTime.Now,
TenantId = tenantId,
WorkAreaId = model.WorkAreaID,
ParentTaskId = model.ParentTaskId,
Description = model.Comment
WorkAreaId = model.WorkAreaID
};
}

View File

@ -20,17 +20,11 @@ namespace Marco.Pms.Model.Projects
[ValidateNever]
public ActivityMaster? ActivityMaster { get; set; }
[ForeignKey("WorkCategoryId")]
[ValidateNever]
public WorkCategoryMaster? WorkCategoryMaster { get; set; }
public Guid? ParentTaskId { get; set; }
public double PlannedWork { get; set; }
public double CompletedWork { get; set; }
public string? Description { get; set; }
public DateTime TaskDate { get; set; }
}
}

View File

@ -903,11 +903,11 @@ namespace Marco.Pms.Services.Helpers
List<ContactNote> notes = new List<ContactNote>();
if (active)
{
notes = await _context.ContactNotes.Include(n => n.Createdby).Where(n => n.ContactId == contact.Id && n.IsActive && n.TenantId == tenantId).ToListAsync();
notes = await _context.ContactNotes.Where(n => n.ContactId == contact.Id && n.IsActive && n.TenantId == tenantId).ToListAsync();
}
else
{
notes = await _context.ContactNotes.Include(n => n.Createdby).Where(n => n.ContactId == contact.Id && n.TenantId == tenantId).ToListAsync();
notes = await _context.ContactNotes.Where(n => n.ContactId == contact.Id && n.TenantId == tenantId).ToListAsync();
}
var noteIds = notes.Select(n => n.Id).ToList();
List<DirectoryUpdateLog>? updateLogs = await _context.DirectoryUpdateLogs.Include(l => l.Employee).Where(l => noteIds.Contains(l.RefereanceId)).ToListAsync();