Code sütunları kaldırıldı

This commit is contained in:
Sedat ÖZTÜRK 2025-12-12 14:33:52 +03:00
parent 9a6f1b3a01
commit 77b040e528
47 changed files with 438 additions and 1510 deletions

View file

@ -7,7 +7,6 @@ namespace Erp.Platform.Intranet;
public class DepartmentDto : FullAuditedEntityDto<Guid>
{
public Guid? TenantId { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public Guid? ParentDepartmentId { get; set; }

View file

@ -6,11 +6,13 @@ namespace Erp.Platform.Intranet;
public class JobPositionDto : FullAuditedEntityDto<Guid>
{
public Guid? TenantId { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public Guid? DepartmentId { get; set; }
public string DepartmentName { get; set; }
public string Level { get; set; }
public decimal MinSalary { get; set; }
public decimal MaxSalary { get; set; }

View file

@ -7853,12 +7853,6 @@
"PlateCode": "AKH",
"Country": "SA"
},
{
"Name": "Al Khobar",
"Code": "AQK",
"PlateCode": "AQK",
"Country": "SA"
},
{
"Name": "Al Khobar",
"Code": "ALK",
@ -7943,12 +7937,6 @@
"PlateCode": "BRU",
"Country": "SA"
},
{
"Name": "Buraydah",
"Code": "BUR",
"PlateCode": "BUR",
"Country": "SA"
},
{
"Name": "Dhahran",
"Code": "DHA",

View file

@ -268,7 +268,7 @@ public class HostDataSeeder : IDataSeedContributor, ITransientDependency
// DB’de mevcut kodları set olarak al
var existingCodes = (await dbCtx.Set<Country>()
.Select(c => c.Code)
.Select(c => c.Name)
.ToListAsync())
.ToHashSet();
@ -289,7 +289,6 @@ public class HostDataSeeder : IDataSeedContributor, ITransientDependency
continue;
buffer.Add(new Country(
item.Code,
item.Code,
item.Name,
item.GroupName,
@ -326,11 +325,11 @@ public class HostDataSeeder : IDataSeedContributor, ITransientDependency
// 1. Mevcut kayıtları çek (tek sorguda)
var existingCities = await dbCtx.Set<City>()
.Select(d => new { d.Code })
.Select(d => new { d.Name })
.ToListAsync();
var existingSet = existingCities
.Select(d => d.Code)
.Select(d => d.Name)
.ToHashSet();
var options = new JsonSerializerOptions
@ -346,14 +345,13 @@ public class HostDataSeeder : IDataSeedContributor, ITransientDependency
{
if (item == null) continue;
var key = $"{item.Country}.{item.Code}";
var key = $"{item.Country}.{item.Name}";
if (existingSet.Contains(key)) continue; // duplicate kontrolü
buffer.Add(new City(
Guid.NewGuid(),
item.Country,
item.Name,
key,
item.PlateCode
));

View file

@ -84,22 +84,21 @@ public class ListFormSeeder_Accounting : IDataSeedContributor, ITransientDepende
DeleteCommand = DefaultDeleteCommand(nameof(TableNameEnum.Bank)),
DeleteFieldsDefaultValueJson = DefaultDeleteFieldsDefaultValueJson(),
PagerOptionJson = DefaultPagerOptionJson,
EditingOptionJson = DefaultEditingOptionJson(listFormName, 600, 400, true, true, true, true, false),
EditingOptionJson = DefaultEditingOptionJson(listFormName, 600, 500, true, true, true, true, false),
EditingFormJson = JsonSerializer.Serialize(new List<EditingFormDto>() {
new() {
Order=1, ColCount=1, ColSpan=1, ItemType="group", Items =
[
new EditingFormItemDto { Order = 1, DataField = "BranchId", ColSpan = 1, EditorType2 = EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
new EditingFormItemDto { Order = 2, DataField = "Code", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox},
new EditingFormItemDto { Order = 3, DataField = "Name", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 5, DataField = "Address1", ColSpan = 1, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 6, DataField = "Address2", ColSpan = 1, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 7, DataField = "Country", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
new EditingFormItemDto { Order = 8, DataField = "City", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
new EditingFormItemDto { Order = 9, DataField = "District", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
new EditingFormItemDto { Order = 10, DataField = "PostalCode", ColSpan = 1, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 11, DataField = "PhoneNumber", ColSpan = 1, EditorType2=EditorTypes.dxTextBox, EditorOptions=EditorOptionValues.PhoneEditorOptions },
new EditingFormItemDto { Order = 12, DataField = "Email", ColSpan = 1, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 4, DataField = "Country", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
new EditingFormItemDto { Order = 5, DataField = "City", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
new EditingFormItemDto { Order = 6, DataField = "District", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
new EditingFormItemDto { Order = 7, DataField = "PostalCode", ColSpan = 1, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 8, DataField = "Address1", ColSpan = 1, EditorType2=EditorTypes.dxTextArea },
new EditingFormItemDto { Order = 9, DataField = "Address2", ColSpan = 1, EditorType2=EditorTypes.dxTextArea },
new EditingFormItemDto { Order = 10, DataField = "PhoneNumber", ColSpan = 1, EditorType2=EditorTypes.dxTextBox, EditorOptions=EditorOptionValues.PhoneEditorOptions },
new EditingFormItemDto { Order = 11, DataField = "Email", ColSpan = 1, EditorType2=EditorTypes.dxTextBox },
]}
}),
InsertFieldsDefaultValueJson = DefaultInsertFieldsDefaultValueJson(),
@ -157,22 +156,6 @@ public class ListFormSeeder_Accounting : IDataSeedContributor, ITransientDepende
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 200,
ListOrderNo = 3,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
@ -551,17 +534,16 @@ public class ListFormSeeder_Accounting : IDataSeedContributor, ITransientDepende
DeleteCommand = DefaultDeleteCommand(nameof(TableNameEnum.Cash)),
DeleteFieldsDefaultValueJson = DefaultDeleteFieldsDefaultValueJson(),
PagerOptionJson = DefaultPagerOptionJson,
EditingOptionJson = DefaultEditingOptionJson(listFormName, 600, 300, true, true, true, true, false),
EditingOptionJson = DefaultEditingOptionJson(listFormName, 600, 350, true, true, true, true, false),
EditingFormJson = JsonSerializer.Serialize(new List<EditingFormDto>() {
new() {
Order=1, ColCount=1, ColSpan=1, ItemType="group", Items =
[
new EditingFormItemDto { Order = 1, DataField = "BranchId", ColSpan = 1, EditorType2 = EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
new EditingFormItemDto { Order = 2, DataField = "Code", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 3, DataField = "Name", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 4, DataField = "Description", ColSpan = 1, EditorType2=EditorTypes.dxTextArea },
new EditingFormItemDto { Order = 5, DataField = "Currency", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxNumberBox, EditorOptions=EditorOptionValues.NumberStandartFormat },
new EditingFormItemDto { Order = 6, DataField = "IsActive", ColSpan = 1, EditorType2=EditorTypes.dxCheckBox },
new EditingFormItemDto { Order = 2, DataField = "Name", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 3, DataField = "Description", ColSpan = 1, EditorType2=EditorTypes.dxTextArea },
new EditingFormItemDto { Order = 4, DataField = "Currency", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.NumberStandartFormat },
new EditingFormItemDto { Order = 5, DataField = "IsActive", ColSpan = 1, EditorType2=EditorTypes.dxCheckBox },
]}
}),
InsertFieldsDefaultValueJson = DefaultInsertFieldsDefaultValueJson(),
@ -612,22 +594,6 @@ public class ListFormSeeder_Accounting : IDataSeedContributor, ITransientDepende
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 150,
ListOrderNo = 3,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
@ -760,7 +726,6 @@ public class ListFormSeeder_Accounting : IDataSeedContributor, ITransientDepende
[
new EditingFormItemDto { Order = 1, DataField = "BranchId", ColSpan = 1, EditorType2 = EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
new EditingFormItemDto { Order = 2, DataField = "PartnerId", ColSpan = 1, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
new EditingFormItemDto { Order = 3, DataField = "Code", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 4, DataField = "Name", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 5, DataField = "Description", ColSpan = 1, EditorType2=EditorTypes.dxTextArea },
new EditingFormItemDto { Order = 6, DataField = "TaxNumber", ColSpan = 1, EditorType2=EditorTypes.dxNumberBox },
@ -838,22 +803,6 @@ public class ListFormSeeder_Accounting : IDataSeedContributor, ITransientDepende
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 150,
ListOrderNo = 4,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,

View file

@ -977,7 +977,7 @@ public class ListFormSeeder_Crm : IDataSeedContributor, ITransientDependency
SelectCommandType = SelectCommandTypeEnum.Table,
SelectCommand = TableNameResolver.GetFullTableName(nameof(TableNameEnum.LossReason)),
KeyFieldName = "Id",
KeyFieldDbSourceType = DbType.Guid,
KeyFieldDbSourceType = DbType.String,
DefaultFilter = DefaultFilterJson,
SortMode = GridOptions.SortModeSingle,
FilterRowJson = DefaultFilterRowJson,
@ -988,15 +988,14 @@ public class ListFormSeeder_Crm : IDataSeedContributor, ITransientDependency
ColumnOptionJson = DefaultColumnOptionJson,
PermissionJson = DefaultPermissionJson(listFormName),
DeleteCommand = DefaultDeleteCommand(nameof(TableNameEnum.LossReason)),
DeleteFieldsDefaultValueJson = DefaultDeleteFieldsDefaultValueJson(),
DeleteFieldsDefaultValueJson = DefaultDeleteFieldsDefaultValueJson(DbType.String),
PagerOptionJson = DefaultPagerOptionJson,
EditingOptionJson = DefaultEditingOptionJson(listFormName, 500, 350, true, true, true, true, false),
InsertFieldsDefaultValueJson = DefaultInsertFieldsDefaultValueJson(),
InsertFieldsDefaultValueJson = DefaultInsertFieldsDefaultValueJson(DbType.String),
EditingFormJson = JsonSerializer.Serialize(new List<EditingFormDto>()
{
new() {
Order=1, ColCount=1, ColSpan=1, ItemType="group", Items =[
new EditingFormItemDto { Order = 1, DataField="Code", ColSpan = 1, IsRequired =true, EditorType2 = EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 2, DataField="Name", ColSpan = 1, IsRequired =true, EditorType2 = EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 3, DataField="Description", ColSpan = 1, EditorType2 = EditorTypes.dxTextArea },
new EditingFormItemDto { Order = 4, DataField="Category", ColSpan = 1, IsRequired =true, EditorType2 = EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
@ -1027,22 +1026,6 @@ public class ListFormSeeder_Crm : IDataSeedContributor, ITransientDependency
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 100,
ListOrderNo = 2,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,

View file

@ -162,7 +162,7 @@ public class ListFormSeeder_Hr : IDataSeedContributor, ITransientDependency
SelectCommandType = SelectCommandTypeEnum.Table,
SelectCommand = TableNameResolver.GetFullTableName(nameof(TableNameEnum.JobPosition)),
KeyFieldName = "Id",
KeyFieldDbSourceType = DbType.Guid,
KeyFieldDbSourceType = DbType.String,
DefaultFilter = DefaultFilterJson,
SortMode = GridOptions.SortModeSingle,
FilterRowJson = DefaultFilterRowJson,
@ -173,15 +173,14 @@ public class ListFormSeeder_Hr : IDataSeedContributor, ITransientDependency
ColumnOptionJson = DefaultColumnOptionJson,
PermissionJson = DefaultPermissionJson(listFormName),
DeleteCommand = DefaultDeleteCommand(nameof(TableNameEnum.JobPosition)),
DeleteFieldsDefaultValueJson = DefaultDeleteFieldsDefaultValueJson(),
DeleteFieldsDefaultValueJson = DefaultDeleteFieldsDefaultValueJson(DbType.String),
PagerOptionJson = DefaultPagerOptionJson,
EditingOptionJson = DefaultEditingOptionJson(listFormName, 500, 600, true, true, true, true, false),
InsertFieldsDefaultValueJson = DefaultInsertFieldsDefaultValueJson(),
InsertFieldsDefaultValueJson = DefaultInsertFieldsDefaultValueJson(DbType.String),
EditingFormJson = JsonSerializer.Serialize(new List<EditingFormDto>()
{
new() {
Order=1, ColCount=1, ColSpan=1, ItemType="group", Items =[
new EditingFormItemDto { Order = 1, DataField="Code", ColSpan = 1, IsRequired = true, EditorType2 = EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 2, DataField="Name", ColSpan = 1, IsRequired =true, EditorType2 = EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 3, DataField="Description", ColSpan = 1, EditorType2 = EditorTypes.dxTextArea },
new EditingFormItemDto { Order = 4, DataField="DepartmentId", ColSpan = 1, IsRequired = true, EditorType2 = EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
@ -219,22 +218,6 @@ public class ListFormSeeder_Hr : IDataSeedContributor, ITransientDependency
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 100,
ListOrderNo = 2,
Visible = true,
IsActive = true,
IsDeleted = false,
SortIndex = 0,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
@ -474,7 +457,6 @@ public class ListFormSeeder_Hr : IDataSeedContributor, ITransientDependency
{
new() {
Order=1, ColCount=1, ColSpan=1, ItemType="group", Items =[
new EditingFormItemDto { Order = 1, DataField="Code", ColSpan = 1, IsRequired = true, EditorType2 = EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 2, DataField="Name", ColSpan = 1, IsRequired =true, EditorType2 = EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 3, DataField="Description", ColSpan = 1, EditorType2 = EditorTypes.dxTextArea },
new EditingFormItemDto { Order = 4, DataField="ParentDepartmentId", ColSpan = 1, EditorType2 = EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
@ -508,22 +490,6 @@ public class ListFormSeeder_Hr : IDataSeedContributor, ITransientDependency
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 100,
ListOrderNo = 2,
Visible = true,
IsActive = true,
IsDeleted = false,
SortIndex = 0,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
@ -684,7 +650,6 @@ public class ListFormSeeder_Hr : IDataSeedContributor, ITransientDependency
{
new() {
Order=1, ColCount=1, ColSpan=1, ItemType="group", Items = [
new EditingFormItemDto { Order = 1, DataField="Code", ColSpan = 1, IsRequired =true, EditorType2 = EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 2, DataField="Name", ColSpan = 1, IsRequired =true, EditorType2 = EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 3, DataField="Description", ColSpan = 1, EditorType2 = EditorTypes.dxTextArea },
new EditingFormItemDto { Order = 4, DataField="Icon", ColSpan = 1, EditorType2 = EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
@ -721,22 +686,6 @@ public class ListFormSeeder_Hr : IDataSeedContributor, ITransientDependency
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 200,
ListOrderNo = 3,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
@ -994,7 +943,6 @@ public class ListFormSeeder_Hr : IDataSeedContributor, ITransientDependency
{
new() {
Order=1, ColCount=1, ColSpan=1, ItemType="group", Items =[
new EditingFormItemDto { Order = 1, DataField="Code", ColSpan = 1, IsRequired = true, EditorType2 = EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 2, DataField="Name", ColSpan = 1, IsRequired =true, EditorType2 = EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 3, DataField="Description", ColSpan = 1, EditorType2 = EditorTypes.dxTextArea },
new EditingFormItemDto { Order = 4, DataField="ParentCostCenterId", ColSpan = 1, EditorType2 = EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
@ -1033,22 +981,6 @@ public class ListFormSeeder_Hr : IDataSeedContributor, ITransientDependency
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 100,
ListOrderNo = 2,
Visible = true,
IsActive = true,
IsDeleted = false,
SortIndex = 0,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,

View file

@ -334,7 +334,6 @@ public class ListFormSeeder_Maintenance : IDataSeedContributor, ITransientDepend
EditingFormJson = JsonSerializer.Serialize(new List<EditingFormDto>() {
new() {
Order=1, ColCount=2, ColSpan=1, ItemType="group", Items= [
new EditingFormItemDto { Order = 1, DataField = "Code", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 2, DataField = "Name", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 3, DataField = "Description", ColSpan = 1, EditorType2=EditorTypes.dxTextArea },
new EditingFormItemDto { Order = 4, DataField = "WorkcenterTypeId", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
@ -380,22 +379,6 @@ public class ListFormSeeder_Maintenance : IDataSeedContributor, ITransientDepend
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 100,
ListOrderNo = 2,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
@ -1335,8 +1318,7 @@ public class ListFormSeeder_Maintenance : IDataSeedContributor, ITransientDepend
EditingFormJson = JsonSerializer.Serialize(new List<EditingFormDto>() {
new() {
Order=1, ColCount=1, ColSpan=1, ItemType="group", Items= [
new EditingFormItemDto { Order = 1, DataField = "Code", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 2, DataField = "Title", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 2, DataField = "Name", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 3, DataField = "Description", ColSpan = 1, EditorType2=EditorTypes.dxTextArea },
new EditingFormItemDto { Order = 4, DataField = "WorkcenterId", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
new EditingFormItemDto { Order = 5, DataField = "Location", ColSpan = 1, EditorType2=EditorTypes.dxTextBox },
@ -1380,25 +1362,7 @@ public class ListFormSeeder_Maintenance : IDataSeedContributor, ITransientDepend
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 100,
ListOrderNo = 2,
Visible = true,
IsActive = true,
IsDeleted = false,
SortIndex = 1,
SortDirection = GridColumnOptions.SortOrderAsc,
AllowSearch = true,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Title",
FieldName = "Name",
Width = 180,
ListOrderNo = 3,
Visible = true,

View file

@ -211,7 +211,6 @@ public class ListFormSeeder_Mrp : IDataSeedContributor, ITransientDependency
EditingFormJson = JsonSerializer.Serialize(new List<EditingFormDto>() {
new() {
Order=1, ColCount=2, ColSpan=1, ItemType="group", Items= [
new EditingFormItemDto { Order = 1, DataField = "Code", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 2, DataField = "Name", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 3, DataField = "Description", ColSpan = 2, EditorType2=EditorTypes.dxTextArea },
new EditingFormItemDto { Order = 4, DataField = "CategoryId", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
@ -250,24 +249,6 @@ public class ListFormSeeder_Mrp : IDataSeedContributor, ITransientDependency
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 150,
ListOrderNo = 2,
Visible = true,
IsActive = true,
IsDeleted = false,
SortIndex = 1,
SortDirection = GridColumnOptions.SortOrderAsc,
AllowSearch = true,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
@ -441,7 +422,6 @@ public class ListFormSeeder_Mrp : IDataSeedContributor, ITransientDependency
EditingFormJson = JsonSerializer.Serialize(new List<EditingFormDto>() {
new() {
Order=1, ColCount=2, ColSpan=1, ItemType="group", Items= [
new EditingFormItemDto { Order = 1, DataField = "Code", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 2, DataField = "Name", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 3, DataField = "Description", ColSpan = 2, EditorType2=EditorTypes.dxTextArea },
new EditingFormItemDto { Order = 4, DataField = "OperationTypeId", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
@ -485,24 +465,6 @@ public class ListFormSeeder_Mrp : IDataSeedContributor, ITransientDependency
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 100,
ListOrderNo = 2,
Visible = true,
IsActive = true,
IsDeleted = false,
SortIndex = 1,
SortDirection = GridColumnOptions.SortOrderAsc,
AllowSearch = true,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,

View file

@ -3956,7 +3956,6 @@ public class ListFormSeeder_Saas : IDataSeedContributor, ITransientDependency
new() {
Order = 1, ColCount = 1, ColSpan = 1, ItemType = "group", Items =
[
new EditingFormItemDto { Order = 1, DataField = "Code", ColSpan = 1, IsRequired = true, EditorType2 = EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 2, DataField = "Symbol", ColSpan = 1, IsRequired = true, EditorType2 = EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 3, DataField = "Name", ColSpan = 1, IsRequired = true, EditorType2 = EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 4, DataField = "Rate", ColSpan = 1, IsRequired = true, EditorType2 = EditorTypes.dxNumberBox },
@ -3984,22 +3983,6 @@ public class ListFormSeeder_Saas : IDataSeedContributor, ITransientDependency
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
},
new()
{
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 150,
ListOrderNo = 2,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
},
new()
{
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
@ -4200,7 +4183,6 @@ public class ListFormSeeder_Saas : IDataSeedContributor, ITransientDependency
new() {
Order = 1, ColCount = 1, ColSpan = 1, ItemType = "group", Items =
[
new EditingFormItemDto { Order = 1, DataField = "Code", ColSpan = 1, IsRequired = true, EditorType2 = EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 2, DataField = "Name", ColSpan = 1, IsRequired = true, EditorType2 = EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 3, DataField = "GroupName", ColSpan = 1, EditorType2 = EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
new EditingFormItemDto { Order = 4, DataField = "Currency", ColSpan = 1, EditorType2 = EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
@ -4234,22 +4216,6 @@ public class ListFormSeeder_Saas : IDataSeedContributor, ITransientDependency
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
},
new()
{
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 100,
ListOrderNo = 2,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
},
new()
{
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
@ -4406,7 +4372,6 @@ public class ListFormSeeder_Saas : IDataSeedContributor, ITransientDependency
[
new EditingFormItemDto { Order = 1, DataField = "Country", ColSpan = 1, IsRequired = true, EditorType2 = EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
new EditingFormItemDto { Order = 2, DataField = "Name", ColSpan = 1, IsRequired = true, EditorType2 = EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 3, DataField = "Code", ColSpan = 1, IsRequired = true, EditorType2 = EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 4, DataField = "PlateCode", ColSpan = 1, IsRequired = true, EditorType2 = EditorTypes.dxTextBox }
]
}
@ -4473,22 +4438,6 @@ public class ListFormSeeder_Saas : IDataSeedContributor, ITransientDependency
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
},
new()
{
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 120,
ListOrderNo = 4,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
},
new()
{
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,

View file

@ -88,7 +88,6 @@ public class ListFormSeeder_Warehouse : IDataSeedContributor, ITransientDependen
EditingFormJson = JsonSerializer.Serialize(new List<EditingFormDto>() {
new() {
Order=1, ColCount=1, ColSpan=1, ItemType="group", Items= [
new EditingFormItemDto { Order = 1, DataField = "Code", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 2, DataField = "Name", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 3, DataField = "Description", ColSpan = 1, EditorType2=EditorTypes.dxTextArea },
new EditingFormItemDto { Order = 4, DataField = "IsActive", ColSpan = 1, EditorType2=EditorTypes.dxCheckBox },
@ -117,22 +116,6 @@ public class ListFormSeeder_Warehouse : IDataSeedContributor, ITransientDependen
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 150,
ListOrderNo = 2,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
@ -229,7 +212,6 @@ public class ListFormSeeder_Warehouse : IDataSeedContributor, ITransientDependen
EditingFormJson = JsonSerializer.Serialize(new List<EditingFormDto>() {
new() {
Order=1, ColCount=1, ColSpan=1, ItemType="group", Items= [
new EditingFormItemDto { Order = 1, DataField = "Code", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 2, DataField = "Name", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 3, DataField = "Description", ColSpan = 1, EditorType2=EditorTypes.dxTextArea },
new EditingFormItemDto { Order = 4, DataField = "IsActive", ColSpan = 1, EditorType2=EditorTypes.dxCheckBox },
@ -258,22 +240,6 @@ public class ListFormSeeder_Warehouse : IDataSeedContributor, ITransientDependen
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 150,
ListOrderNo = 2,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
@ -370,7 +336,6 @@ public class ListFormSeeder_Warehouse : IDataSeedContributor, ITransientDependen
EditingFormJson = JsonSerializer.Serialize(new List<EditingFormDto>() {
new() {
Order=1, ColCount=1, ColSpan=1, ItemType="group", Items= [
new EditingFormItemDto { Order = 1, DataField = "Code", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 2, DataField = "Name", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 3, DataField = "Description", ColSpan = 1, EditorType2=EditorTypes.dxTextArea },
new EditingFormItemDto { Order = 4, DataField = "IsActive", ColSpan = 1, EditorType2=EditorTypes.dxCheckBox },
@ -399,22 +364,6 @@ public class ListFormSeeder_Warehouse : IDataSeedContributor, ITransientDependen
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 150,
ListOrderNo = 2,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
@ -511,7 +460,6 @@ public class ListFormSeeder_Warehouse : IDataSeedContributor, ITransientDependen
EditingFormJson = JsonSerializer.Serialize(new List<EditingFormDto>() {
new() {
Order=1, ColCount=1, ColSpan=1, ItemType="group", Items= [
new EditingFormItemDto { Order = 1, DataField = "Code", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 2, DataField = "Name", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 3, DataField = "Description", ColSpan = 1, EditorType2=EditorTypes.dxTextArea },
new EditingFormItemDto { Order = 4, DataField = "EmployeeId", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
@ -556,22 +504,6 @@ public class ListFormSeeder_Warehouse : IDataSeedContributor, ITransientDependen
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 100,
ListOrderNo = 2,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
@ -891,7 +823,6 @@ public class ListFormSeeder_Warehouse : IDataSeedContributor, ITransientDependen
EditingFormJson = JsonSerializer.Serialize(new List<EditingFormDto>() {
new() {
Order=1, ColCount=1, ColSpan=1, ItemType="group", Items= [
new EditingFormItemDto { Order = 1, DataField = "Code", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 2, DataField = "Name", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 3, DataField = "Description", ColSpan = 1, EditorType2=EditorTypes.dxTextArea },
new EditingFormItemDto { Order = 4, DataField = "WarehouseId", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
@ -926,22 +857,6 @@ public class ListFormSeeder_Warehouse : IDataSeedContributor, ITransientDependen
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 100,
ListOrderNo = 2,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
@ -1107,7 +1022,6 @@ public class ListFormSeeder_Warehouse : IDataSeedContributor, ITransientDependen
EditingFormJson = JsonSerializer.Serialize(new List<EditingFormDto>() {
new() {
Order=1, ColCount=1, ColSpan=1, ItemType="group", Items= [
new EditingFormItemDto { Order = 1, DataField = "Code", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 2, DataField = "Name", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 3, DataField = "Description", ColSpan = 1, EditorType2=EditorTypes.dxTextArea },
new EditingFormItemDto { Order = 4, DataField = "WarehouseId", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
@ -1141,22 +1055,6 @@ public class ListFormSeeder_Warehouse : IDataSeedContributor, ITransientDependen
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 100,
ListOrderNo = 2,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
@ -1382,10 +1280,10 @@ public class ListFormSeeder_Warehouse : IDataSeedContributor, ITransientDependen
EditingFormJson = JsonSerializer.Serialize(new List<EditingFormDto>() {
new() {
Order=1, ColCount=2, ColSpan=1, Caption="General", ItemType="group", Items= [
new EditingFormItemDto { Order = 1, DataField = "Code", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 2, DataField = "Name", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 3, DataField = "Priority", ColSpan = 1, EditorType2=EditorTypes.dxNumberBox },
new EditingFormItemDto { Order = 4, DataField = "Strategy", ColSpan = 1, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
new EditingFormItemDto { Order = 1, DataField = "Name", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 2, DataField = "Priority", ColSpan = 1, EditorType2=EditorTypes.dxNumberBox },
new EditingFormItemDto { Order = 3, DataField = "Strategy", ColSpan = 1, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
new EditingFormItemDto { Order = 4, DataField = "IsActive", ColSpan = 1, EditorType2=EditorTypes.dxCheckBox },
new EditingFormItemDto { Order = 5, DataField = "Description", ColSpan = 2, EditorType2=EditorTypes.dxTextArea },
]},
new() {
@ -1393,9 +1291,8 @@ public class ListFormSeeder_Warehouse : IDataSeedContributor, ITransientDependen
new EditingFormItemDto { Order = 1, DataField = "WarehouseId", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
new EditingFormItemDto { Order = 2, DataField = "MaterialTypeId", ColSpan = 1, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
new EditingFormItemDto { Order = 3, DataField = "MaterialGroupId", ColSpan = 1, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
new EditingFormItemDto { Order = 4, DataField = "IsActive", ColSpan = 1, EditorType2=EditorTypes.dxCheckBox },
new EditingFormItemDto { Order = 5, DataField = "TargetZoneId", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
new EditingFormItemDto { Order = 6, DataField = "TargetLocationId", ColSpan = 1, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
new EditingFormItemDto { Order = 4, DataField = "TargetZoneId", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
new EditingFormItemDto { Order = 5, DataField = "TargetLocationId", ColSpan = 1, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
]},
}),
FormFieldsDefaultValueJson = JsonSerializer.Serialize(new FieldsDefaultValue[] {
@ -1433,22 +1330,6 @@ public class ListFormSeeder_Warehouse : IDataSeedContributor, ITransientDependen
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 150,
ListOrderNo = 2,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,

View file

@ -88,7 +88,6 @@ public class ListFormSeeder_SupplyChain : IDataSeedContributor, ITransientDepend
EditingFormJson = JsonSerializer.Serialize(new List<EditingFormDto>() {
new() {
Order=1, ColCount=1, ColSpan=1, ItemType="group", Items= [
new EditingFormItemDto { Order = 1, DataField = "Code", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 2, DataField = "Name", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 3, DataField = "Description", ColSpan = 1, EditorType2=EditorTypes.dxTextArea },
new EditingFormItemDto { Order = 4, DataField = "IsActive", ColSpan = 1, EditorType2=EditorTypes.dxCheckBox },
@ -117,22 +116,6 @@ public class ListFormSeeder_SupplyChain : IDataSeedContributor, ITransientDepend
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 150,
ListOrderNo = 2,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
@ -227,11 +210,10 @@ public class ListFormSeeder_SupplyChain : IDataSeedContributor, ITransientDepend
EditingOptionJson = DefaultEditingOptionJson(listFormName, 500, 350, true, true, true, true, false),
EditingFormJson = JsonSerializer.Serialize(new List<EditingFormDto>() {
new() { Order=1, ColCount=1, ColSpan=2, ItemType="group", Items=[
new EditingFormItemDto { Order = 1, DataField = "Code", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 2, DataField = "Name", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 3, DataField = "Description", ColSpan = 1, EditorType2=EditorTypes.dxTextArea },
new EditingFormItemDto { Order = 4, DataField = "IsActive", ColSpan = 1, EditorType2=EditorTypes.dxCheckBox },
new EditingFormItemDto { Order = 5, DataField = "ParentGroupId", ColSpan = 1, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
new EditingFormItemDto { Order = 1, DataField = "Name", ColSpan = 1, IsRequired = true, EditorType2=EditorTypes.dxTextBox },
new EditingFormItemDto { Order = 2, DataField = "Description", ColSpan = 1, EditorType2=EditorTypes.dxTextArea },
new EditingFormItemDto { Order = 3, DataField = "IsActive", ColSpan = 1, EditorType2=EditorTypes.dxCheckBox },
new EditingFormItemDto { Order = 4, DataField = "ParentGroupId", ColSpan = 1, EditorType2=EditorTypes.dxSelectBox, EditorOptions=EditorOptionValues.ShowClearButton },
]}
}),
InsertFieldsDefaultValueJson = DefaultInsertFieldsDefaultValueJson(),
@ -258,22 +240,6 @@ public class ListFormSeeder_SupplyChain : IDataSeedContributor, ITransientDepend
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.String,
FieldName = "Code",
Width = 200,
ListOrderNo = 2,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,

View file

@ -394,7 +394,7 @@ public class BranchSeedManager : DomainService
var bankLog = CreateLog(nameof(Bank));
foreach (var item in items.Banks)
{
var exists = await _bankRepository.AnyAsync(x => x.Code == item.Code && x.BranchId == branchId);
var exists = await _bankRepository.AnyAsync(x => x.Name == item.Name && x.BranchId == branchId);
if (!exists)
{
@ -402,7 +402,6 @@ public class BranchSeedManager : DomainService
{
TenantId = tenantId,
BranchId = branchId,
Code = item.Code,
Name = item.Name,
Address1 = item.Address1,
Address2 = item.Address2,
@ -431,7 +430,7 @@ public class BranchSeedManager : DomainService
var cashLog = CreateLog(nameof(Cash));
foreach (var item in items.Cashes)
{
var exists = await _cashRepository.AnyAsync(x => x.Code == item.Code && x.BranchId == branchId);
var exists = await _cashRepository.AnyAsync(x => x.Name == item.Name && x.BranchId == branchId);
if (!exists)
{
@ -439,7 +438,6 @@ public class BranchSeedManager : DomainService
{
TenantId = tenantId,
BranchId = branchId,
Code = item.Code,
Name = item.Name,
Description = item.Description,
Currency = item.Currency,
@ -464,7 +462,7 @@ public class BranchSeedManager : DomainService
var currentAccountLog = CreateLog(nameof(CurrentAccount));
foreach (var item in items.CurrentAccounts)
{
var exists = await _currentAccountRepository.AnyAsync(x => x.Code == item.Code && x.BranchId == branchId);
var exists = await _currentAccountRepository.AnyAsync(x => x.Name == item.Name && x.BranchId == branchId);
if (!exists)
{
@ -472,7 +470,6 @@ public class BranchSeedManager : DomainService
{
TenantId = tenantId,
BranchId = branchId,
Code = item.Code,
Name = item.Name,
Description = item.Description,
TaxNumber = item.TaxNumber,

View file

@ -9,7 +9,6 @@ public class Bank : FullAuditedEntity<Guid>, IMultiTenant
public Guid? TenantId { get; set; }
public Guid? BranchId { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public string Address1 { get; set; }
public string Address2 { get; set; }

View file

@ -9,7 +9,6 @@ public class Cash : FullAuditedEntity<Guid>, IMultiTenant
public Guid? TenantId { get; set; }
public Guid? BranchId { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }

View file

@ -14,7 +14,6 @@ public class CurrentAccount : FullAuditedEntity<Guid>, IMultiTenant
public Guid? PartnerId { get; set; }
public Partner? Partner { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }

View file

@ -8,19 +8,17 @@ public class City : FullAuditedEntity<Guid>
{
public string Country { get; set; }
public string Name { get; set; }
public string Code { get; set; }
public string PlateCode { get; set; }
public ICollection<District> Districts { get; set; }
protected City() { }
public City(Guid id, string country, string name, string code, string plateCode)
public City(Guid id, string country, string name, string plateCode)
: base(id)
{
Country = country;
Name = name;
Code = code;
PlateCode = plateCode;
}
}

View file

@ -1,12 +1,10 @@
using System;
using System.Collections.Generic;
using System.Collections.Generic;
using Volo.Abp.Domain.Entities.Auditing;
namespace Erp.Platform.Entities;
public class Country : FullAuditedEntity<string>
{
public string Code { get; set; } // TR, US
public string Name { get; set; }
public string GroupName { get; set; }
public string Currency { get; set; }
@ -21,7 +19,6 @@ public class Country : FullAuditedEntity<string>
public Country(
string id,
string code,
string name,
string groupName,
string currency,
@ -31,7 +28,6 @@ public class Country : FullAuditedEntity<string>
bool stateRequired = false)
: base(id)
{
Code = code;
Name = name;
GroupName = groupName;
Currency = currency;

View file

@ -5,15 +5,19 @@ using Volo.Abp.MultiTenancy;
namespace Erp.Platform.Entities;
public class LossReason : FullAuditedEntity<Guid>, IMultiTenant
public class LossReason : FullAuditedEntity<string>, IMultiTenant
{
public Guid? TenantId { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public string Category { get; set; }
public bool IsActive { get; set; }
public ICollection<Opportunity> Opportunities { get; set; }
public LossReason(string id)
{
Id = id;
}
}

View file

@ -33,7 +33,7 @@ public class Opportunity : FullAuditedEntity<Guid>, IMultiTenant
public Guid SourceId { get; set; }
public Source Source { get; set; }
public Guid? LossReasonId { get; set; } // Kaybetme Nedeni
public string? LossReasonId { get; set; } // Kaybetme Nedeni
public LossReason LossReason { get; set; }
public string Status { get; set; } // Durum

View file

@ -8,7 +8,6 @@ public class Badge : FullAuditedEntity<Guid>, IMultiTenant
{
public Guid? TenantId { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public string Icon { get; set; }

View file

@ -9,7 +9,6 @@ public class CostCenter : FullAuditedEntity<Guid>, IMultiTenant
{
public Guid? TenantId { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }

View file

@ -10,7 +10,6 @@ public class Department : FullAuditedEntity<Guid>, IMultiTenant
{
public Guid? TenantId { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }

View file

@ -40,7 +40,7 @@ public class Employee : FullAuditedEntity<Guid>, IMultiTenant
public Guid? EmploymentTypeId { get; set; }
public EmploymentType EmploymentType { get; set; }
public Guid? JobPositionId { get; set; }
public string? JobPositionId { get; set; }
public JobPosition JobPosition { get; set; }
public Guid? DepartmentId { get; set; }

View file

@ -4,15 +4,16 @@ using Volo.Abp.MultiTenancy;
namespace Erp.Platform.Entities;
public class JobPosition : FullAuditedEntity<Guid>, IMultiTenant
public class JobPosition : FullAuditedEntity<string>, IMultiTenant
{
public Guid? TenantId { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public Guid? DepartmentId { get; set; }
public Department Department { get; set; }
public string Level { get; set; }
public decimal MinSalary { get; set; }
public decimal MaxSalary { get; set; }
@ -21,5 +22,10 @@ public class JobPosition : FullAuditedEntity<Guid>, IMultiTenant
public string Responsibilities { get; set; }
public string Qualifications { get; set; }
public bool IsActive { get; set; }
public JobPosition(string id)
{
Id = id;
}
}

View file

@ -8,8 +8,7 @@ public class Fault : FullAuditedEntity<Guid>, IMultiTenant
{
public Guid? TenantId { get; set; }
public string Code { get; set; }
public string Title { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public string? WorkcenterId { get; set; }
public Workcenter? Workcenter { get; set; }

View file

@ -11,7 +11,6 @@ public class Workcenter : FullAuditedEntity<string>, IMultiTenant
public Guid? TenantId { get; set; }
// İş Merkezi / Ekipman Bilgileri
public string Code { get; set; }
public string Name { get; set; }
public string? Description { get; set; }

View file

@ -9,7 +9,6 @@ public class Operation : FullAuditedEntity<Guid>, IMultiTenant
{
public Guid? TenantId { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }

View file

@ -9,7 +9,6 @@ public class OperationType : FullAuditedEntity<Guid>, IMultiTenant
{
public Guid? TenantId { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }

View file

@ -18,7 +18,6 @@ public class Location : FullAuditedEntity<string>, IMultiTenant
public string? LocationTypeId { get; set; }
public LocationType? LocationType { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }

View file

@ -9,7 +9,6 @@ public class LocationType : FullAuditedEntity<string>, IMultiTenant
{
public Guid? TenantId { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public bool IsActive { get; set; }

View file

@ -9,7 +9,6 @@ public class Putaway : FullAuditedEntity<Guid>, IMultiTenant
{
public Guid? TenantId { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public int Priority { get; set; }

View file

@ -9,7 +9,6 @@ public class Warehouse : FullAuditedEntity<string>, IMultiTenant
{
public Guid? TenantId { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }

View file

@ -9,7 +9,6 @@ public class WarehouseType : FullAuditedEntity<string>, IMultiTenant
{
public Guid? TenantId { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public bool IsActive { get; set; }

View file

@ -15,7 +15,6 @@ public class Zone : FullAuditedEntity<string>, IMultiTenant
public string? ZoneTypeId { get; set; }
public ZoneType? ZoneType { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }

View file

@ -9,7 +9,6 @@ public class ZoneType : FullAuditedEntity<string>, IMultiTenant
{
public Guid? TenantId { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public bool IsActive { get; set; }

View file

@ -9,7 +9,6 @@ public class MaterialGroup : FullAuditedEntity<Guid>, IMultiTenant
{
public Guid? TenantId { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public Guid? ParentGroupId { get; set; }

View file

@ -9,7 +9,6 @@ public class MaterialType : FullAuditedEntity<Guid>, IMultiTenant
{
public Guid? TenantId { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public bool IsActive { get; set; }

View file

@ -949,13 +949,12 @@ public class PlatformDbContext :
b.ConfigureByConvention();
b.Property(x => x.Id).HasMaxLength(8);
b.Property(x => x.Code).IsRequired().HasMaxLength(8);
b.Property(x => x.Name).IsRequired().HasMaxLength(128);
b.Property(x => x.GroupName).HasMaxLength(128);
b.Property(x => x.TaxLabel).HasMaxLength(64);
b.Property(x => x.Currency).IsRequired().HasMaxLength(8);
b.HasIndex(x => x.Code).IsUnique();
b.HasIndex(x => x.Name).IsUnique();
b.HasIndex(x => x.GroupName);
b.HasOne<CountryGroup>()
@ -972,10 +971,9 @@ public class PlatformDbContext :
b.Property(x => x.Country).HasMaxLength(128);
b.Property(x => x.Name).IsRequired().HasMaxLength(128);
b.Property(x => x.Code).IsRequired().HasMaxLength(16);
b.Property(x => x.PlateCode).HasMaxLength(20);
b.HasIndex(x => new { x.Country, x.Code }).IsUnique();
b.HasIndex(x => new { x.Country, x.Name }).IsUnique();
});
builder.Entity<District>(b =>
@ -1805,7 +1803,6 @@ public class PlatformDbContext :
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.Bank)), Prefix.DbSchema);
b.ConfigureByConvention();
b.Property(x => x.Code).HasMaxLength(64);
b.Property(x => x.Name).IsRequired().HasMaxLength(128);
b.Property(x => x.Address1).HasMaxLength(256);
b.Property(x => x.Address2).HasMaxLength(256);
@ -1841,7 +1838,6 @@ public class PlatformDbContext :
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.Cash)), Prefix.DbSchema);
b.ConfigureByConvention();
b.Property(x => x.Code).IsRequired().HasMaxLength(64);
b.Property(x => x.Name).IsRequired().HasMaxLength(128);
b.Property(x => x.Description).HasMaxLength(512);
b.Property(x => x.Currency).IsRequired().HasMaxLength(8);
@ -1854,7 +1850,6 @@ public class PlatformDbContext :
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.CurrentAccount)), Prefix.DbSchema);
b.ConfigureByConvention();
b.Property(p => p.Code).IsRequired().HasMaxLength(64);
b.Property(p => p.Name).IsRequired().HasMaxLength(128);
b.Property(p => p.Description).HasMaxLength(512);
b.Property(p => p.TaxOffice).HasMaxLength(128);
@ -1878,7 +1873,6 @@ public class PlatformDbContext :
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.JobPosition)), Prefix.DbSchema);
b.ConfigureByConvention();
b.Property(x => x.Code).IsRequired().HasMaxLength(64);
b.Property(x => x.Name).IsRequired().HasMaxLength(150);
b.Property(x => x.Description).HasMaxLength(512);
b.Property(x => x.Level).HasMaxLength(64);
@ -1901,7 +1895,6 @@ public class PlatformDbContext :
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.Badge)), Prefix.DbSchema);
b.ConfigureByConvention();
b.Property(x => x.Code).IsRequired().HasMaxLength(64);
b.Property(x => x.Name).IsRequired().HasMaxLength(150);
b.Property(x => x.Description).HasMaxLength(512);
b.Property(x => x.Icon).HasMaxLength(10);
@ -1918,7 +1911,6 @@ public class PlatformDbContext :
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.Department)), Prefix.DbSchema);
b.ConfigureByConvention();
b.Property(x => x.Code).IsRequired().HasMaxLength(20);
b.Property(x => x.Name).IsRequired().HasMaxLength(128);
b.Property(x => x.Description).HasMaxLength(512);
b.Property(x => x.Budget).HasDefaultValue(0);
@ -1946,7 +1938,6 @@ public class PlatformDbContext :
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.CostCenter)), Prefix.DbSchema);
b.ConfigureByConvention();
b.Property(x => x.Code).IsRequired().HasMaxLength(64);
b.Property(x => x.Name).IsRequired().HasMaxLength(256);
b.Property(x => x.Description).HasMaxLength(512);
b.Property(x => x.FiscalYear).HasMaxLength(10);
@ -2455,7 +2446,6 @@ public class PlatformDbContext :
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.MaterialType)), Prefix.DbSchema);
b.ConfigureByConvention();
b.Property(x => x.Code).IsRequired().HasMaxLength(64);
b.Property(x => x.Name).IsRequired().HasMaxLength(128);
b.Property(x => x.Description).HasMaxLength(512);
b.Property(x => x.IsActive).HasDefaultValue(true);
@ -2466,7 +2456,6 @@ public class PlatformDbContext :
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.MaterialGroup)), Prefix.DbSchema);
b.ConfigureByConvention();
b.Property(x => x.Code).IsRequired().HasMaxLength(64);
b.Property(x => x.Name).IsRequired().HasMaxLength(128);
b.Property(x => x.Description).HasMaxLength(512);
b.Property(x => x.IsActive).HasDefaultValue(true);
@ -2792,7 +2781,6 @@ public class PlatformDbContext :
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.LossReason)), Prefix.DbSchema);
b.ConfigureByConvention();
b.Property(x => x.Code).IsRequired().HasMaxLength(128);
b.Property(x => x.Name).IsRequired().HasMaxLength(256);
b.Property(x => x.Description).HasMaxLength(512);
b.Property(x => x.Category).HasMaxLength(64).IsRequired();
@ -2933,8 +2921,7 @@ public class PlatformDbContext :
b.ConfigureByConvention();
b.Property(x => x.Id).HasMaxLength(128);
b.Property(x => x.Code).IsRequired().HasMaxLength(128);
b.Property(x => x.Name).IsRequired().HasMaxLength(256);
b.Property(x => x.Name).IsRequired().HasMaxLength(128);
b.Property(x => x.Description).HasMaxLength(512);
b.Property(x => x.WorkcenterTypeId).IsRequired().HasMaxLength(64);
b.Property(x => x.Manufacturer).HasMaxLength(256);
@ -3044,13 +3031,12 @@ public class PlatformDbContext :
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.Fault)), Prefix.DbSchema);
b.ConfigureByConvention();
b.Property(x => x.Code).IsRequired().HasMaxLength(128);
b.Property(x => x.Name).HasMaxLength(128);
b.Property(x => x.WorkcenterId).IsRequired().HasMaxLength(128);
b.Property(x => x.Location).HasMaxLength(256);
b.Property(x => x.FaultTypeId).IsRequired().HasMaxLength(64);
b.Property(x => x.Priority).HasMaxLength(64);
b.Property(x => x.Severity).HasMaxLength(64);
b.Property(x => x.Title).HasMaxLength(256);
b.Property(x => x.Description).HasMaxLength(1024);
b.Property(x => x.AssignedTo).HasMaxLength(128);
b.Property(x => x.Status).IsRequired().HasMaxLength(20);
@ -3114,7 +3100,6 @@ public class PlatformDbContext :
b.ConfigureByConvention();
b.Property(x => x.Id).HasMaxLength(64);
b.Property(x => x.Code).IsRequired().HasMaxLength(64);
b.Property(x => x.Name).IsRequired().HasMaxLength(64);
b.Property(x => x.Description).HasMaxLength(512);
b.Property(x => x.IsActive).HasDefaultValue(true);
@ -3126,7 +3111,6 @@ public class PlatformDbContext :
b.ConfigureByConvention();
b.Property(x => x.Id).HasMaxLength(64);
b.Property(x => x.Code).IsRequired().HasMaxLength(64);
b.Property(x => x.Name).IsRequired().HasMaxLength(256);
b.Property(x => x.Description).HasMaxLength(512);
b.Property(x => x.EmployeeId).IsRequired();
@ -3161,7 +3145,6 @@ public class PlatformDbContext :
b.ConfigureByConvention();
b.Property(x => x.Id).HasMaxLength(64);
b.Property(x => x.Code).IsRequired().HasMaxLength(64);
b.Property(x => x.Name).IsRequired().HasMaxLength(64);
b.Property(x => x.Description).HasMaxLength(512);
b.Property(x => x.IsActive).HasDefaultValue(true);
@ -3172,10 +3155,9 @@ public class PlatformDbContext :
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.Zone)), Prefix.DbSchema);
b.ConfigureByConvention();
b.Property(x => x.WarehouseId).IsRequired().HasMaxLength(64);
b.Property(x => x.Code).IsRequired().HasMaxLength(64);
b.Property(x => x.Id).HasMaxLength(64);
b.Property(x => x.Name).IsRequired().HasMaxLength(64);
b.Property(x => x.WarehouseId).IsRequired().HasMaxLength(64);
b.Property(x => x.Description).HasMaxLength(512);
b.Property(x => x.ZoneTypeId).IsRequired().HasMaxLength(64);
b.Property(x => x.Temperature).HasPrecision(18, 2).HasDefaultValue(0);
@ -3198,7 +3180,6 @@ public class PlatformDbContext :
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.LocationType)), Prefix.DbSchema);
b.ConfigureByConvention();
b.Property(x => x.Code).IsRequired().HasMaxLength(64);
b.Property(x => x.Id).HasMaxLength(64);
b.Property(x => x.Name).IsRequired().HasMaxLength(64);
b.Property(x => x.Description).HasMaxLength(512);
@ -3210,10 +3191,9 @@ public class PlatformDbContext :
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.Location)), Prefix.DbSchema);
b.ConfigureByConvention();
b.Property(x => x.Id).HasMaxLength(64);
b.Property(x => x.WarehouseId).IsRequired().HasMaxLength(64);
b.Property(x => x.ZoneId).IsRequired().HasMaxLength(64);
b.Property(x => x.Code).IsRequired().HasMaxLength(64);
b.Property(x => x.Id).HasMaxLength(64);
b.Property(x => x.Name).IsRequired().HasMaxLength(64);
b.Property(x => x.Description).HasMaxLength(512);
b.Property(x => x.LocationTypeId).IsRequired().HasMaxLength(64);
@ -3247,8 +3227,7 @@ public class PlatformDbContext :
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.Putaway)), Prefix.DbSchema);
b.ConfigureByConvention();
b.Property(x => x.Code).IsRequired().HasMaxLength(128);
b.Property(x => x.Name).IsRequired().HasMaxLength(256);
b.Property(x => x.Name).IsRequired().HasMaxLength(128);
b.Property(x => x.Description).HasMaxLength(512);
b.Property(x => x.WarehouseId).IsRequired().HasMaxLength(64);
b.Property(x => x.Priority).IsRequired().HasDefaultValue(1);
@ -3289,8 +3268,7 @@ public class PlatformDbContext :
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.OperationType)), Prefix.DbSchema);
b.ConfigureByConvention();
b.Property(x => x.Code).IsRequired().HasMaxLength(128);
b.Property(x => x.Name).IsRequired().HasMaxLength(256);
b.Property(x => x.Name).IsRequired().HasMaxLength(128);
b.Property(x => x.Description).HasMaxLength(512);
b.Property(x => x.CategoryId).IsRequired();
b.Property(x => x.DefaultDuration).HasDefaultValue(0);
@ -3310,8 +3288,7 @@ public class PlatformDbContext :
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.Operation)), Prefix.DbSchema);
b.ConfigureByConvention();
b.Property(x => x.Code).IsRequired().HasMaxLength(128);
b.Property(x => x.Name).IsRequired().HasMaxLength(256);
b.Property(x => x.Name).IsRequired().HasMaxLength(128);
b.Property(x => x.Description).HasMaxLength(512);
b.Property(x => x.OperationTypeId).IsRequired();
b.Property(x => x.WorkcenterId).IsRequired().HasMaxLength(128);

View file

@ -13,7 +13,7 @@ using Volo.Abp.EntityFrameworkCore;
namespace Erp.Platform.Migrations
{
[DbContext(typeof(PlatformDbContext))]
[Migration("20251211210045_Initial")]
[Migration("20251212092917_Initial")]
partial class Initial
{
/// <inheritdoc />
@ -1063,11 +1063,6 @@ namespace Erp.Platform.Migrations
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<string>("Color")
.HasMaxLength(10)
.HasColumnType("nvarchar(10)");
@ -1160,10 +1155,6 @@ namespace Erp.Platform.Migrations
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<string>("Code")
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<string>("Country")
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
@ -2028,11 +2019,6 @@ namespace Erp.Platform.Migrations
b.Property<Guid?>("BranchId")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -2462,11 +2448,6 @@ namespace Erp.Platform.Migrations
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(16)
.HasColumnType("nvarchar(16)");
b.Property<string>("Country")
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
@ -2517,7 +2498,7 @@ namespace Erp.Platform.Migrations
b.HasIndex("CountryId");
b.HasIndex("Country", "Code")
b.HasIndex("Country", "Name")
.IsUnique()
.HasFilter("[Country] IS NOT NULL");
@ -3311,11 +3292,6 @@ namespace Erp.Platform.Migrations
.HasPrecision(18, 4)
.HasColumnType("decimal(18,4)");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<string>("CostCenterType")
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
@ -3403,11 +3379,6 @@ namespace Erp.Platform.Migrations
.HasMaxLength(8)
.HasColumnType("nvarchar(8)");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(8)
.HasColumnType("nvarchar(8)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -3467,11 +3438,11 @@ namespace Erp.Platform.Migrations
b.HasKey("Id");
b.HasIndex("Code")
.IsUnique();
b.HasIndex("GroupName");
b.HasIndex("Name")
.IsUnique();
b.ToTable("Sas_H_Country", (string)null);
});
@ -3736,11 +3707,6 @@ namespace Erp.Platform.Migrations
b.Property<Guid?>("BranchId")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -4457,11 +4423,6 @@ namespace Erp.Platform.Migrations
.HasColumnType("decimal(18,4)")
.HasDefaultValue(0m);
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(20)
.HasColumnType("nvarchar(20)");
b.Property<Guid?>("CostCenterId")
.HasColumnType("uniqueidentifier");
@ -4960,8 +4921,8 @@ namespace Erp.Platform.Migrations
.HasDefaultValue(false)
.HasColumnName("IsDeleted");
b.Property<Guid?>("JobPositionId")
.HasColumnType("uniqueidentifier");
b.Property<string>("JobPositionId")
.HasColumnType("nvarchar(450)");
b.Property<DateTime?>("LastModificationTime")
.HasColumnType("datetime2")
@ -5500,11 +5461,6 @@ namespace Erp.Platform.Migrations
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -5560,6 +5516,10 @@ namespace Erp.Platform.Migrations
.HasMaxLength(256)
.HasColumnType("nvarchar(256)");
b.Property<string>("Name")
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<string>("Priority")
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
@ -5581,10 +5541,6 @@ namespace Erp.Platform.Migrations
.HasColumnType("uniqueidentifier")
.HasColumnName("TenantId");
b.Property<string>("Title")
.HasMaxLength(256)
.HasColumnType("nvarchar(256)");
b.Property<string>("WorkcenterId")
.IsRequired()
.HasMaxLength(128)
@ -6394,13 +6350,8 @@ namespace Erp.Platform.Migrations
modelBuilder.Entity("Erp.Platform.Entities.JobPosition", b =>
{
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<string>("Id")
.HasColumnType("nvarchar(450)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
@ -7516,11 +7467,6 @@ namespace Erp.Platform.Migrations
.HasColumnType("decimal(18,2)")
.HasDefaultValue(0m);
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -7615,11 +7561,6 @@ namespace Erp.Platform.Migrations
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -7703,19 +7644,14 @@ namespace Erp.Platform.Migrations
modelBuilder.Entity("Erp.Platform.Entities.LossReason", b =>
{
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<string>("Id")
.HasColumnType("nvarchar(450)");
b.Property<string>("Category")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -7881,11 +7817,6 @@ namespace Erp.Platform.Migrations
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -8018,11 +7949,6 @@ namespace Erp.Platform.Migrations
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -8712,11 +8638,6 @@ namespace Erp.Platform.Migrations
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -8774,8 +8695,8 @@ namespace Erp.Platform.Migrations
b.Property<string>("Name")
.IsRequired()
.HasMaxLength(256)
.HasColumnType("nvarchar(256)");
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<Guid>("OperationTypeId")
.HasColumnType("uniqueidentifier");
@ -8890,11 +8811,6 @@ namespace Erp.Platform.Migrations
b.Property<Guid>("CategoryId")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -8941,8 +8857,8 @@ namespace Erp.Platform.Migrations
b.Property<string>("Name")
.IsRequired()
.HasMaxLength(256)
.HasColumnType("nvarchar(256)");
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<bool>("QualityCheckRequired")
.ValueGeneratedOnAdd()
@ -9027,8 +8943,8 @@ namespace Erp.Platform.Migrations
.HasColumnType("uniqueidentifier")
.HasColumnName("LastModifierId");
b.Property<Guid?>("LossReasonId")
.HasColumnType("uniqueidentifier");
b.Property<string>("LossReasonId")
.HasColumnType("nvarchar(450)");
b.Property<Guid>("PartnerId")
.HasColumnType("uniqueidentifier");
@ -12009,11 +11925,6 @@ namespace Erp.Platform.Migrations
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -12061,8 +11972,8 @@ namespace Erp.Platform.Migrations
b.Property<string>("Name")
.IsRequired()
.HasMaxLength(256)
.HasColumnType("nvarchar(256)");
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<int>("Priority")
.ValueGeneratedOnAdd()
@ -16110,11 +16021,6 @@ namespace Erp.Platform.Migrations
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<string>("Country")
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
@ -16216,11 +16122,6 @@ namespace Erp.Platform.Migrations
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -16791,11 +16692,6 @@ namespace Erp.Platform.Migrations
.HasColumnType("int")
.HasDefaultValue(0);
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<decimal>("CostPerHour")
.ValueGeneratedOnAdd()
.HasPrecision(18, 2)
@ -16865,8 +16761,8 @@ namespace Erp.Platform.Migrations
b.Property<string>("Name")
.IsRequired()
.HasMaxLength(256)
.HasColumnType("nvarchar(256)");
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<string>("SerialNumber")
.HasMaxLength(128)
@ -17476,11 +17372,6 @@ namespace Erp.Platform.Migrations
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -17566,11 +17457,6 @@ namespace Erp.Platform.Migrations
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");

View file

@ -441,7 +441,6 @@ namespace Erp.Platform.Migrations
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
BranchId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Code = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: true),
Name = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: false),
Address1 = table.Column<string>(type: "nvarchar(256)", maxLength: 256, nullable: true),
Address2 = table.Column<string>(type: "nvarchar(256)", maxLength: 256, nullable: true),
@ -471,7 +470,6 @@ namespace Erp.Platform.Migrations
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
BranchId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Code = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Name = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: false),
Description = table.Column<string>(type: "nvarchar(512)", maxLength: 512, nullable: true),
Currency = table.Column<string>(type: "nvarchar(8)", maxLength: 8, nullable: false),
@ -1306,9 +1304,8 @@ namespace Erp.Platform.Migrations
name: "Crm_T_LossReason",
columns: table => new
{
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
Id = table.Column<string>(type: "nvarchar(450)", nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Code = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: false),
Name = table.Column<string>(type: "nvarchar(256)", maxLength: 256, nullable: false),
Description = table.Column<string>(type: "nvarchar(512)", maxLength: 512, nullable: true),
Category = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
@ -1354,7 +1351,6 @@ namespace Erp.Platform.Migrations
{
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Code = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Name = table.Column<string>(type: "nvarchar(150)", maxLength: 150, nullable: false),
Description = table.Column<string>(type: "nvarchar(512)", maxLength: 512, nullable: true),
Icon = table.Column<string>(type: "nvarchar(10)", maxLength: 10, nullable: true),
@ -2887,7 +2883,6 @@ namespace Erp.Platform.Migrations
{
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Code = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Name = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: false),
ParentGroupId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Description = table.Column<string>(type: "nvarchar(512)", maxLength: 512, nullable: true),
@ -2917,7 +2912,6 @@ namespace Erp.Platform.Migrations
{
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Code = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Name = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: false),
Description = table.Column<string>(type: "nvarchar(512)", maxLength: 512, nullable: true),
IsActive = table.Column<bool>(type: "bit", nullable: false, defaultValue: true),
@ -3195,7 +3189,6 @@ namespace Erp.Platform.Migrations
{
Id = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Code = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Name = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Description = table.Column<string>(type: "nvarchar(512)", maxLength: 512, nullable: true),
IsActive = table.Column<bool>(type: "bit", nullable: false, defaultValue: true),
@ -3240,8 +3233,7 @@ namespace Erp.Platform.Migrations
{
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Code = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: false),
Name = table.Column<string>(type: "nvarchar(256)", maxLength: 256, nullable: false),
Name = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: false),
Description = table.Column<string>(type: "nvarchar(512)", maxLength: 512, nullable: true),
Priority = table.Column<int>(type: "int", nullable: false, defaultValue: 1),
Strategy = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
@ -3293,7 +3285,6 @@ namespace Erp.Platform.Migrations
{
Id = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Code = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Name = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Description = table.Column<string>(type: "nvarchar(512)", maxLength: 512, nullable: true),
IsActive = table.Column<bool>(type: "bit", nullable: false, defaultValue: true),
@ -3316,7 +3307,6 @@ namespace Erp.Platform.Migrations
{
Id = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Code = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Name = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Description = table.Column<string>(type: "nvarchar(512)", maxLength: 512, nullable: true),
IsActive = table.Column<bool>(type: "bit", nullable: false, defaultValue: true),
@ -3889,8 +3879,7 @@ namespace Erp.Platform.Migrations
{
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Code = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: false),
Name = table.Column<string>(type: "nvarchar(256)", maxLength: 256, nullable: false),
Name = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: false),
Description = table.Column<string>(type: "nvarchar(512)", maxLength: 512, nullable: true),
CategoryId = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
DefaultDuration = table.Column<int>(type: "int", nullable: false, defaultValue: 0),
@ -4051,7 +4040,6 @@ namespace Erp.Platform.Migrations
columns: table => new
{
Id = table.Column<string>(type: "nvarchar(8)", maxLength: 8, nullable: false),
Code = table.Column<string>(type: "nvarchar(8)", maxLength: 8, nullable: false),
Name = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: false),
GroupName = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: true),
Currency = table.Column<string>(type: "nvarchar(8)", maxLength: 8, nullable: false),
@ -4689,7 +4677,6 @@ namespace Erp.Platform.Migrations
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
Country = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: true),
Name = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: false),
Code = table.Column<string>(type: "nvarchar(16)", maxLength: 16, nullable: false),
PlateCode = table.Column<string>(type: "nvarchar(20)", maxLength: 20, nullable: true),
CountryId = table.Column<string>(type: "nvarchar(8)", nullable: true),
CreationTime = table.Column<DateTime>(type: "datetime2", nullable: false),
@ -5106,7 +5093,6 @@ namespace Erp.Platform.Migrations
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
BranchId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
PartnerId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Code = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Name = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: false),
Description = table.Column<string>(type: "nvarchar(512)", maxLength: 512, nullable: true),
TaxNumber = table.Column<long>(type: "bigint", nullable: true),
@ -6089,7 +6075,7 @@ namespace Erp.Platform.Migrations
EmployeeId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
TeamCode = table.Column<string>(type: "nvarchar(95)", maxLength: 95, nullable: true),
SourceId = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
LossReasonId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
LossReasonId = table.Column<string>(type: "nvarchar(450)", nullable: true),
Status = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
CreationTime = table.Column<DateTime>(type: "datetime2", nullable: false),
CreatorId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
@ -6121,7 +6107,6 @@ namespace Erp.Platform.Migrations
{
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Code = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Name = table.Column<string>(type: "nvarchar(256)", maxLength: 256, nullable: false),
Description = table.Column<string>(type: "nvarchar(512)", maxLength: 512, nullable: true),
ParentCostCenterId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
@ -6157,7 +6142,6 @@ namespace Erp.Platform.Migrations
{
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Code = table.Column<string>(type: "nvarchar(20)", maxLength: 20, nullable: false),
Name = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: false),
Description = table.Column<string>(type: "nvarchar(512)", maxLength: 512, nullable: true),
ParentDepartmentId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
@ -6194,9 +6178,8 @@ namespace Erp.Platform.Migrations
name: "Hr_T_JobPosition",
columns: table => new
{
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
Id = table.Column<string>(type: "nvarchar(450)", nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Code = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Name = table.Column<string>(type: "nvarchar(150)", maxLength: 150, nullable: false),
Description = table.Column<string>(type: "nvarchar(512)", maxLength: 512, nullable: true),
DepartmentId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
@ -6272,8 +6255,7 @@ namespace Erp.Platform.Migrations
{
Id = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Code = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: false),
Name = table.Column<string>(type: "nvarchar(256)", maxLength: 256, nullable: false),
Name = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: false),
Description = table.Column<string>(type: "nvarchar(512)", maxLength: 512, nullable: true),
WorkcenterTypeId = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Manufacturer = table.Column<string>(type: "nvarchar(256)", maxLength: 256, nullable: true),
@ -6385,7 +6367,7 @@ namespace Erp.Platform.Migrations
HireDate = table.Column<DateTime>(type: "datetime2", nullable: false),
TerminationDate = table.Column<DateTime>(type: "datetime2", nullable: true),
EmploymentTypeId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
JobPositionId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
JobPositionId = table.Column<string>(type: "nvarchar(450)", nullable: true),
DepartmentId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
WorkLocation = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: true),
ManagerId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
@ -6448,8 +6430,7 @@ namespace Erp.Platform.Migrations
{
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Code = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: false),
Title = table.Column<string>(type: "nvarchar(256)", maxLength: 256, nullable: true),
Name = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: true),
Description = table.Column<string>(type: "nvarchar(1024)", maxLength: 1024, nullable: true),
WorkcenterId = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: false),
Location = table.Column<string>(type: "nvarchar(256)", maxLength: 256, nullable: true),
@ -6577,8 +6558,7 @@ namespace Erp.Platform.Migrations
{
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Code = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: false),
Name = table.Column<string>(type: "nvarchar(256)", maxLength: 256, nullable: false),
Name = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: false),
Description = table.Column<string>(type: "nvarchar(512)", maxLength: 512, nullable: true),
OperationTypeId = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
WorkcenterId = table.Column<string>(type: "nvarchar(128)", maxLength: 128, nullable: false),
@ -7072,7 +7052,6 @@ namespace Erp.Platform.Migrations
{
Id = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Code = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Name = table.Column<string>(type: "nvarchar(256)", maxLength: 256, nullable: false),
Description = table.Column<string>(type: "nvarchar(512)", maxLength: 512, nullable: true),
EmployeeId = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
@ -7769,7 +7748,6 @@ namespace Erp.Platform.Migrations
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
WarehouseId = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
ZoneTypeId = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Code = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Name = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Description = table.Column<string>(type: "nvarchar(512)", maxLength: 512, nullable: true),
Temperature = table.Column<decimal>(type: "decimal(18,2)", precision: 18, scale: 2, nullable: false, defaultValue: 0m),
@ -8011,7 +7989,6 @@ namespace Erp.Platform.Migrations
WarehouseId = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
ZoneId = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
LocationTypeId = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Code = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Name = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Description = table.Column<string>(type: "nvarchar(512)", maxLength: 512, nullable: true),
Capacity = table.Column<decimal>(type: "decimal(18,2)", precision: 18, scale: 2, nullable: false, defaultValue: 0m),
@ -9720,9 +9697,9 @@ namespace Erp.Platform.Migrations
column: "ProjectId");
migrationBuilder.CreateIndex(
name: "IX_Sas_H_City_Country_Code",
name: "IX_Sas_H_City_Country_Name",
table: "Sas_H_City",
columns: new[] { "Country", "Code" },
columns: new[] { "Country", "Name" },
unique: true,
filter: "[Country] IS NOT NULL");
@ -9731,17 +9708,17 @@ namespace Erp.Platform.Migrations
table: "Sas_H_City",
column: "CountryId");
migrationBuilder.CreateIndex(
name: "IX_Sas_H_Country_Code",
table: "Sas_H_Country",
column: "Code",
unique: true);
migrationBuilder.CreateIndex(
name: "IX_Sas_H_Country_GroupName",
table: "Sas_H_Country",
column: "GroupName");
migrationBuilder.CreateIndex(
name: "IX_Sas_H_Country_Name",
table: "Sas_H_Country",
column: "Name",
unique: true);
migrationBuilder.CreateIndex(
name: "IX_Sas_H_CountryGroup_Name",
table: "Sas_H_CountryGroup",

View file

@ -1060,11 +1060,6 @@ namespace Erp.Platform.Migrations
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<string>("Color")
.HasMaxLength(10)
.HasColumnType("nvarchar(10)");
@ -1157,10 +1152,6 @@ namespace Erp.Platform.Migrations
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<string>("Code")
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<string>("Country")
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
@ -2025,11 +2016,6 @@ namespace Erp.Platform.Migrations
b.Property<Guid?>("BranchId")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -2459,11 +2445,6 @@ namespace Erp.Platform.Migrations
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(16)
.HasColumnType("nvarchar(16)");
b.Property<string>("Country")
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
@ -2514,7 +2495,7 @@ namespace Erp.Platform.Migrations
b.HasIndex("CountryId");
b.HasIndex("Country", "Code")
b.HasIndex("Country", "Name")
.IsUnique()
.HasFilter("[Country] IS NOT NULL");
@ -3308,11 +3289,6 @@ namespace Erp.Platform.Migrations
.HasPrecision(18, 4)
.HasColumnType("decimal(18,4)");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<string>("CostCenterType")
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
@ -3400,11 +3376,6 @@ namespace Erp.Platform.Migrations
.HasMaxLength(8)
.HasColumnType("nvarchar(8)");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(8)
.HasColumnType("nvarchar(8)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -3464,11 +3435,11 @@ namespace Erp.Platform.Migrations
b.HasKey("Id");
b.HasIndex("Code")
.IsUnique();
b.HasIndex("GroupName");
b.HasIndex("Name")
.IsUnique();
b.ToTable("Sas_H_Country", (string)null);
});
@ -3733,11 +3704,6 @@ namespace Erp.Platform.Migrations
b.Property<Guid?>("BranchId")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -4454,11 +4420,6 @@ namespace Erp.Platform.Migrations
.HasColumnType("decimal(18,4)")
.HasDefaultValue(0m);
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(20)
.HasColumnType("nvarchar(20)");
b.Property<Guid?>("CostCenterId")
.HasColumnType("uniqueidentifier");
@ -4957,8 +4918,8 @@ namespace Erp.Platform.Migrations
.HasDefaultValue(false)
.HasColumnName("IsDeleted");
b.Property<Guid?>("JobPositionId")
.HasColumnType("uniqueidentifier");
b.Property<string>("JobPositionId")
.HasColumnType("nvarchar(450)");
b.Property<DateTime?>("LastModificationTime")
.HasColumnType("datetime2")
@ -5497,11 +5458,6 @@ namespace Erp.Platform.Migrations
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -5557,6 +5513,10 @@ namespace Erp.Platform.Migrations
.HasMaxLength(256)
.HasColumnType("nvarchar(256)");
b.Property<string>("Name")
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<string>("Priority")
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
@ -5578,10 +5538,6 @@ namespace Erp.Platform.Migrations
.HasColumnType("uniqueidentifier")
.HasColumnName("TenantId");
b.Property<string>("Title")
.HasMaxLength(256)
.HasColumnType("nvarchar(256)");
b.Property<string>("WorkcenterId")
.IsRequired()
.HasMaxLength(128)
@ -6391,13 +6347,8 @@ namespace Erp.Platform.Migrations
modelBuilder.Entity("Erp.Platform.Entities.JobPosition", b =>
{
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<string>("Id")
.HasColumnType("nvarchar(450)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
@ -7513,11 +7464,6 @@ namespace Erp.Platform.Migrations
.HasColumnType("decimal(18,2)")
.HasDefaultValue(0m);
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -7612,11 +7558,6 @@ namespace Erp.Platform.Migrations
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -7700,19 +7641,14 @@ namespace Erp.Platform.Migrations
modelBuilder.Entity("Erp.Platform.Entities.LossReason", b =>
{
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<string>("Id")
.HasColumnType("nvarchar(450)");
b.Property<string>("Category")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -7878,11 +7814,6 @@ namespace Erp.Platform.Migrations
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -8015,11 +7946,6 @@ namespace Erp.Platform.Migrations
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -8709,11 +8635,6 @@ namespace Erp.Platform.Migrations
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -8771,8 +8692,8 @@ namespace Erp.Platform.Migrations
b.Property<string>("Name")
.IsRequired()
.HasMaxLength(256)
.HasColumnType("nvarchar(256)");
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<Guid>("OperationTypeId")
.HasColumnType("uniqueidentifier");
@ -8887,11 +8808,6 @@ namespace Erp.Platform.Migrations
b.Property<Guid>("CategoryId")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -8938,8 +8854,8 @@ namespace Erp.Platform.Migrations
b.Property<string>("Name")
.IsRequired()
.HasMaxLength(256)
.HasColumnType("nvarchar(256)");
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<bool>("QualityCheckRequired")
.ValueGeneratedOnAdd()
@ -9024,8 +8940,8 @@ namespace Erp.Platform.Migrations
.HasColumnType("uniqueidentifier")
.HasColumnName("LastModifierId");
b.Property<Guid?>("LossReasonId")
.HasColumnType("uniqueidentifier");
b.Property<string>("LossReasonId")
.HasColumnType("nvarchar(450)");
b.Property<Guid>("PartnerId")
.HasColumnType("uniqueidentifier");
@ -12006,11 +11922,6 @@ namespace Erp.Platform.Migrations
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -12058,8 +11969,8 @@ namespace Erp.Platform.Migrations
b.Property<string>("Name")
.IsRequired()
.HasMaxLength(256)
.HasColumnType("nvarchar(256)");
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<int>("Priority")
.ValueGeneratedOnAdd()
@ -16107,11 +16018,6 @@ namespace Erp.Platform.Migrations
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<string>("Country")
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
@ -16213,11 +16119,6 @@ namespace Erp.Platform.Migrations
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -16788,11 +16689,6 @@ namespace Erp.Platform.Migrations
.HasColumnType("int")
.HasDefaultValue(0);
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<decimal>("CostPerHour")
.ValueGeneratedOnAdd()
.HasPrecision(18, 2)
@ -16862,8 +16758,8 @@ namespace Erp.Platform.Migrations
b.Property<string>("Name")
.IsRequired()
.HasMaxLength(256)
.HasColumnType("nvarchar(256)");
.HasMaxLength(128)
.HasColumnType("nvarchar(128)");
b.Property<string>("SerialNumber")
.HasMaxLength(128)
@ -17473,11 +17369,6 @@ namespace Erp.Platform.Migrations
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
@ -17563,11 +17454,6 @@ namespace Erp.Platform.Migrations
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("nvarchar(64)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");

View file

@ -65,7 +65,7 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
private readonly IRepository<QuestionPool, Guid> _questionPoolRepository;
private readonly IRepository<Question, Guid> _questionRepository;
private readonly IRepository<EmploymentType, Guid> _employeeTypeRepository;
private readonly IRepository<JobPosition, Guid> _jobPositionRepository;
private readonly IRepository<JobPosition, string> _jobPositionRepository;
private readonly IRepository<Currency, string> _currencyRepository;
private readonly IRepository<Department, Guid> _departmentRepository;
private readonly IRepository<Badge, Guid> _badgeRepository;
@ -101,7 +101,7 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
private readonly IRepository<CustomerType, string> _customerTypeRepository;
private readonly IRepository<CustomerSegment, string> _customerSegmentRepository;
private readonly IRepository<Partner, Guid> _partnerRepository;
private readonly IRepository<LossReason, Guid> _lossReasonRepository;
private readonly IRepository<LossReason, string> _lossReasonRepository;
private readonly IRepository<OrganizationUnit, Guid> _organizationUnitRepository;
private readonly OrganizationUnitManager _organizationUnitManager;
private readonly IRepository<RequestType, string> _requestTypeRepository;
@ -203,7 +203,7 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
IRepository<QuestionPool, Guid> questionPoolRepository,
IRepository<Question, Guid> questionRepository,
IRepository<EmploymentType, Guid> employeeTypeRepository,
IRepository<JobPosition, Guid> jobPositionRepository,
IRepository<JobPosition, string> jobPositionRepository,
IRepository<Currency, string> currencyRepository,
IRepository<Department, Guid> departmentRepository,
IRepository<CostCenter, Guid> costCenterRepository,
@ -239,7 +239,7 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
IRepository<CustomerType, string> customerTypeRepository,
IRepository<CustomerSegment, string> customerSegmentRepository,
IRepository<Partner, Guid> partnerRepository,
IRepository<LossReason, Guid> lossReasonRepository,
IRepository<LossReason, string> lossReasonRepository,
IRepository<OrganizationUnit, Guid> organizationUnitRepository,
OrganizationUnitManager organizationUnitManager,
IRepository<RequestType, string> requestTypeRepository,
@ -1037,16 +1037,15 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
//Hr
foreach (var item in items.Badges)
{
if (string.IsNullOrWhiteSpace(item.Code) || string.IsNullOrWhiteSpace(item.Name))
if (string.IsNullOrWhiteSpace(item.Name))
continue;
var exists = await _badgeRepository.AnyAsync(x => x.Code == item.Code);
var exists = await _badgeRepository.AnyAsync(x => x.Name == item.Name);
if (exists)
continue;
await _badgeRepository.InsertAsync(new Badge
{
Code = item.Code,
Name = item.Name,
Description = item.Description,
Icon = item.Icon,
@ -1077,20 +1076,19 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
foreach (var item in items.Departments)
{
if (string.IsNullOrWhiteSpace(item.Name) || string.IsNullOrWhiteSpace(item.Code))
if (string.IsNullOrWhiteSpace(item.Name))
continue;
var parentDepartment = await _departmentRepository.FirstOrDefaultAsync(x => x.Code == item.ParentDepartmentCode);
var costCenter = await _costCenterRepository.FirstOrDefaultAsync(x => x.Code == item.CostCenterCode);
var parentDepartment = await _departmentRepository.FirstOrDefaultAsync(x => x.Name == item.ParentDepartmentName);
var costCenter = await _costCenterRepository.FirstOrDefaultAsync(x => x.Name == item.CostCenterName);
var employee = await _employeeRepository.FirstOrDefaultAsync(x => x.Code == item.ManagerCode);
var exists = await _departmentRepository.AnyAsync(x => x.Code == item.Code);
var exists = await _departmentRepository.AnyAsync(x => x.Name == item.Name );
if (exists)
continue;
await _departmentRepository.InsertAsync(new Department
{
Code = item.Code,
Name = item.Name,
Description = item.Description,
ParentDepartmentId = parentDepartment != null ? parentDepartment.Id : null,
@ -1103,20 +1101,19 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
foreach (var item in items.CostCenters)
{
if (string.IsNullOrWhiteSpace(item.Code) || string.IsNullOrWhiteSpace(item.Name))
if (string.IsNullOrWhiteSpace(item.Name))
continue;
var parentCostCenter = await _costCenterRepository.FirstOrDefaultAsync(x => x.Code == item.ParentCostCenterCode);
var parentCostCenter = await _costCenterRepository.FirstOrDefaultAsync(x => x.Name == item.ParentCostCenterName);
var responsibleEmployee = await _employeeRepository.FirstOrDefaultAsync(x => x.Code == item.ResponsibleEmployeeCode);
var department = await _departmentRepository.FirstOrDefaultAsync(x => x.Code == item.DepartmentCode);
var department = await _departmentRepository.FirstOrDefaultAsync(x => x.Name == item.DepartmentName);
var exists = await _costCenterRepository.AnyAsync(x => x.Code == item.Code);
var exists = await _costCenterRepository.AnyAsync(x => x.Name == item.Name);
if (exists)
continue;
await _costCenterRepository.InsertAsync(new CostCenter
{
Code = item.Code,
Name = item.Name,
Description = item.Description,
ParentCostCenterId = parentCostCenter != null ? parentCostCenter.Id : null,
@ -1133,18 +1130,17 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
foreach (var item in items.JobPositions)
{
if (string.IsNullOrWhiteSpace(item.Name) || string.IsNullOrWhiteSpace(item.Code))
if (string.IsNullOrWhiteSpace(item.Name))
continue;
var exists = await _jobPositionRepository.AnyAsync(x => x.Code == item.Code);
var exists = await _jobPositionRepository.AnyAsync(x => x.Name == item.Name);
if (exists)
continue;
var department = await _departmentRepository.FirstOrDefaultAsync(x => x.Code == item.DepartmentCode);
var department = await _departmentRepository.FirstOrDefaultAsync(x => x.Name == item.DepartmentName);
await _jobPositionRepository.InsertAsync(new JobPosition
await _jobPositionRepository.InsertAsync(new JobPosition(item.Name)
{
Code = item.Code,
Name = item.Name,
Description = item.Description,
DepartmentId = department != null ? department.Id : null,
@ -1166,11 +1162,11 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
continue;
var employmentType = await _employeeTypeRepository.FirstOrDefaultAsync(x => x.Name == item.EmploymentTypeName);
var department = await _departmentRepository.FirstOrDefaultAsync(x => x.Code == item.DepartmentCode);
var jobPosition = await _jobPositionRepository.FirstOrDefaultAsync(x => x.Code == item.JobPositionCode);
var department = await _departmentRepository.FirstOrDefaultAsync(x => x.Name == item.DepartmentName);
var jobPosition = await _jobPositionRepository.FirstOrDefaultAsync(x => x.Name == item.JobPositionName);
var manager = await _employeeRepository.FirstOrDefaultAsync(x => x.Code == item.ManagerCode);
var bank = await _bankRepository.FirstOrDefaultAsync(x => x.Code == item.BankCode);
var badge = await _badgeRepository.FirstOrDefaultAsync(x => x.Code == item.BadgeCode);
var bank = await _bankRepository.FirstOrDefaultAsync(x => x.Name == item.BankName);
var badge = await _badgeRepository.FirstOrDefaultAsync(x => x.Name == item.BadgeName);
await _employeeRepository.InsertAsync(new Employee
{
@ -1360,7 +1356,7 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
continue;
var template = await _template360Repository.FirstOrDefaultAsync(x => x.Name == item.TemplateName);
var department = await _departmentRepository.FirstOrDefaultAsync(x => x.Code == item.DepartmentCode);
var department = await _departmentRepository.FirstOrDefaultAsync(x => x.Name == item.DepartmentName);
var targetEmployees = await _employeeRepository.GetListAsync(x =>
item.TargetEmployees.Split('|', StringSplitOptions.RemoveEmptyEntries).Contains(x.Code));
@ -1448,10 +1444,10 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
var employee = await _employeeRepository.FirstOrDefaultAsync(x => x.Code == item.EmployeeCode);
var targetDepartments = new List<Department>();
if (item.DepartmentCodes != null)
if (item.DepartmentNames != null)
{
targetDepartments = await _departmentRepository.GetListAsync(x =>
item.DepartmentCodes.Split('|', StringSplitOptions.RemoveEmptyEntries).Contains(x.Code));
item.DepartmentNames.Split('|', StringSplitOptions.RemoveEmptyEntries).Contains(x.Name));
}
await _announcementRepository.InsertAsync(new Announcement
@ -1790,13 +1786,12 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
//Supply Chain
foreach (var item in items.MaterialTypes)
{
var exists = await _materialTypeRepository.AnyAsync(x => x.Code == item.Code);
var exists = await _materialTypeRepository.AnyAsync(x => x.Name == item.Name);
if (!exists)
{
await _materialTypeRepository.InsertAsync(new MaterialType
{
Code = item.Code,
Name = item.Name,
Description = item.Description,
IsActive = item.IsActive
@ -1806,15 +1801,13 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
foreach (var item in items.MaterialGroups)
{
var exists = await _materialGroupRepository.AnyAsync(x => x.Code == item.Code);
var exists = await _materialGroupRepository.AnyAsync(x => x.Name == item.Name);
if (!exists)
{
var parentGroup = await _materialGroupRepository.FirstOrDefaultAsync(x => x.Code == item.ParentGroupCode);
var parentGroup = await _materialGroupRepository.FirstOrDefaultAsync(x => x.Name == item.ParentGroupName);
await _materialGroupRepository.InsertAsync(new MaterialGroup
{
Code = item.Code,
Name = item.Name,
Description = item.Description,
IsActive = item.IsActive,
@ -1832,8 +1825,8 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
if (exists)
continue;
var type = await _materialTypeRepository.FirstOrDefaultAsync(x => x.Code == item.MaterialTypeCode);
var group = await _materialGroupRepository.FirstOrDefaultAsync(x => x.Code == item.MaterialGroupCode);
var type = await _materialTypeRepository.FirstOrDefaultAsync(x => x.Name == item.MaterialTypeName);
var group = await _materialGroupRepository.FirstOrDefaultAsync(x => x.Name == item.MaterialGroupName);
await _materialRepository.InsertAsync(new Material
{
@ -1943,9 +1936,8 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
if (exists)
continue;
await _lossReasonRepository.InsertAsync(new LossReason
await _lossReasonRepository.InsertAsync(new LossReason(item.Name)
{
Code = item.Code,
Name = item.Name,
Category = item.Category,
Description = item.Description,
@ -2041,8 +2033,8 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
if (exists)
continue;
var department = await _departmentRepository.FirstOrDefaultAsync(x => x.Code == item.DepartmentCode);
var materialType = await _materialTypeRepository.FirstOrDefaultAsync(x => x.Code == item.MaterialTypeCode);
var department = await _departmentRepository.FirstOrDefaultAsync(x => x.Name == item.DepartmentName);
var materialType = await _materialTypeRepository.FirstOrDefaultAsync(x => x.Name == item.MaterialTypeName);
await _approvalRepository.InsertAsync(new Approval
{
@ -2084,16 +2076,15 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
foreach (var item in items.Workcenters)
{
var exists = await _workcenterRepository.AnyAsync(x => x.Code == item.Code);
var exists = await _workcenterRepository.AnyAsync(x => x.Name == item.Name);
if (exists)
continue;
var department = await _departmentRepository.FirstOrDefaultAsync(x => x.Code == item.DepartmentCode);
var department = await _departmentRepository.FirstOrDefaultAsync(x => x.Name == item.DepartmentName);
var workcenterType = await _workcenterTypeRepository.FirstOrDefaultAsync(x => x.Name == item.WorkcenterTypeName);
await _workcenterRepository.InsertAsync(new Workcenter(item.Code)
await _workcenterRepository.InsertAsync(new Workcenter(item.Name)
{
Code = item.Code,
Name = item.Name,
Description = item.Description,
WorkcenterTypeId = workcenterType?.Id,
@ -2113,31 +2104,31 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
}, autoSave: true);
}
foreach (var item in items.MaintenancePlans)
{
var exists = await _maintenancePlanRepository.AnyAsync(x => x.Code == item.Code);
if (exists)
continue;
// foreach (var item in items.MaintenancePlans)
// {
// var exists = await _maintenancePlanRepository.AnyAsync(x => x.Code == item.Code);
// if (exists)
// continue;
var workcenter = await _workcenterRepository.FirstOrDefaultAsync(x => x.Code == item.WorkCenterCode);
// var workcenter = await _workcenterRepository.FirstOrDefaultAsync(x => x.Name == item.WorkCenterName);
await _maintenancePlanRepository.InsertAsync(new PlanWizard
{
Code = item.Code,
WorkcenterId = workcenter?.Id,
PlanType = item.PlanType,
Priority = item.Priority,
Description = item.Description,
Frequency = item.Frequency,
FrequencyUnit = item.FrequencyUnit,
EstimatedDuration = item.EstimatedDuration,
RequiredSkillsJson = item.RequiredSkillsJson,
Instructions = item.Instructions,
NextDue = item.NextDue,
IsActive = item.IsActive,
LastExecuted = item.LastExecuted
}, autoSave: true);
}
// await _maintenancePlanRepository.InsertAsync(new PlanWizard
// {
// Code = item.Code,
// WorkcenterId = workcenter?.Id,
// PlanType = item.PlanType,
// Priority = item.Priority,
// Description = item.Description,
// Frequency = item.Frequency,
// FrequencyUnit = item.FrequencyUnit,
// EstimatedDuration = item.EstimatedDuration,
// RequiredSkillsJson = item.RequiredSkillsJson,
// Instructions = item.Instructions,
// NextDue = item.NextDue,
// IsActive = item.IsActive,
// LastExecuted = item.LastExecuted
// }, autoSave: true);
// }
foreach (var item in items.FaultTypes)
{
@ -2169,24 +2160,23 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
foreach (var item in items.Faults)
{
var exists = await _faultRepository.AnyAsync(x => x.Code == item.Code);
var exists = await _faultRepository.AnyAsync(x => x.Name == item.Name);
if (exists)
continue;
var workcenter = await _workcenterRepository.FirstOrDefaultAsync(x => x.Code == item.WorkCenterCode);
var workcenter = await _workcenterRepository.FirstOrDefaultAsync(x => x.Name == item.WorkCenterName);
var faultType = await _faultTypeRepository.FirstOrDefaultAsync(x => x.Name == item.FaultTypeName);
var faultStatus = await _faultStatusRepository.FirstOrDefaultAsync(x => x.Name == item.Status);
await _faultRepository.InsertAsync(new Fault
{
Code = item.Code,
Name = item.Name,
Description = item.Description,
WorkcenterId = workcenter?.Id,
Location = item.Location,
FaultTypeId = faultType?.Id,
Priority = item.Priority,
Severity = item.Severity,
Title = item.Title,
Description = item.Description,
Status = item.Status,
EstimatedRepairTime = item.EstimatedRepairTime,
ActualRepairTime = item.ActualRepairTime,
@ -2232,7 +2222,6 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
await _warehouseTypeRepository.InsertAsync(new WarehouseType(item.Name)
{
Code = item.Code,
Name = item.Name,
Description = item.Description,
IsActive = item.IsActive
@ -2241,13 +2230,12 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
foreach (var item in items.ZoneTypes)
{
var exists = await _zoneTypeRepository.AnyAsync(x => x.Code == item.Code);
var exists = await _zoneTypeRepository.AnyAsync(x => x.Name == item.Name);
if (exists)
continue;
await _zoneTypeRepository.InsertAsync(new ZoneType(item.Name)
{
Code = item.Code,
Name = item.Name,
Description = item.Description,
IsActive = item.IsActive
@ -2256,13 +2244,12 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
foreach (var item in items.LocationTypes)
{
var exists = await _locationTypeRepository.AnyAsync(x => x.Code == item.Code);
var exists = await _locationTypeRepository.AnyAsync(x => x.Name == item.Name);
if (exists)
continue;
await _locationTypeRepository.InsertAsync(new LocationType(item.Name)
{
Code = item.Code,
Name = item.Name,
Description = item.Description,
IsActive = item.IsActive
@ -2271,16 +2258,15 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
foreach (var item in items.Warehouses)
{
var exists = await _warehouseRepository.AnyAsync(x => x.Code == item.Code);
var exists = await _warehouseRepository.AnyAsync(x => x.Name == item.Name);
if (exists)
continue;
var employee = await _employeeRepository.FirstOrDefaultAsync(x => x.Code == item.EmployeeCode);
var warehousetype = await _warehouseTypeRepository.FirstOrDefaultAsync(x => x.Code == item.WarehouseTypeCode);
var warehousetype = await _warehouseTypeRepository.FirstOrDefaultAsync(x => x.Name == item.WarehouseTypeName);
await _warehouseRepository.InsertAsync(new Warehouse(item.Code)
await _warehouseRepository.InsertAsync(new Warehouse(item.Name)
{
Code = item.Code,
Name = item.Name,
Description = item.Description,
EmployeeId = employee?.Id,
@ -2300,18 +2286,17 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
foreach (var item in items.Zones)
{
var exists = await _zoneRepository.AnyAsync(x => x.Code == item.Code);
var exists = await _zoneRepository.AnyAsync(x => x.Name == item.Name);
if (exists)
continue;
var warehouse = await _warehouseRepository.FirstOrDefaultAsync(x => x.Code == item.WarehouseCode);
var zoneType = await _zoneTypeRepository.FirstOrDefaultAsync(x => x.Code == item.ZoneTypeCode);
var warehouse = await _warehouseRepository.FirstOrDefaultAsync(x => x.Name == item.WarehouseName);
var zoneType = await _zoneTypeRepository.FirstOrDefaultAsync(x => x.Name == item.ZoneTypeName);
await _zoneRepository.InsertAsync(new Zone(item.Name)
{
WarehouseId = warehouse?.Id,
ZoneTypeId = zoneType?.Id,
Code = item.Code,
Name = item.Name,
Description = item.Description,
Temperature = item.Temperature,
@ -2322,13 +2307,13 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
foreach (var item in items.Locations)
{
var exists = await _locationRepository.AnyAsync(x => x.Code == item.Code);
var exists = await _locationRepository.AnyAsync(x => x.Name == item.Name);
if (exists)
continue;
var warehouse = await _warehouseRepository.FirstOrDefaultAsync(x => x.Code == item.WarehouseCode);
var zone = await _zoneRepository.FirstOrDefaultAsync(x => x.Code == item.ZoneCode);
var locationtype = await _locationTypeRepository.FirstOrDefaultAsync(x => x.Code == item.LocationTypeCode);
var warehouse = await _warehouseRepository.FirstOrDefaultAsync(x => x.Name == item.WarehouseName);
var zone = await _zoneRepository.FirstOrDefaultAsync(x => x.Name == item.ZoneName);
var locationtype = await _locationTypeRepository.FirstOrDefaultAsync(x => x.Name == item.LocationTypeName);
var uom = await _uomRepository.FirstOrDefaultAsync(x => x.Name == item.UomId);
await _locationRepository.InsertAsync(new Location(item.Name)
@ -2336,7 +2321,6 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
WarehouseId = warehouse?.Id,
ZoneId = zone?.Id,
LocationTypeId = locationtype?.Id,
Code = item.Code,
Name = item.Name,
Description = item.Description,
IsActive = item.IsActive,
@ -2349,19 +2333,18 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
foreach (var item in items.Putaways)
{
var exists = await _putawayRepository.AnyAsync(x => x.Code == item.Code);
var exists = await _putawayRepository.AnyAsync(x => x.Name == item.Name);
if (exists)
continue;
var warehouse = await _warehouseRepository.FirstOrDefaultAsync(x => x.Code == item.WarehouseCode);
var materialtype = await _materialTypeRepository.FirstOrDefaultAsync(x => x.Code == item.MaterialTypeCode);
var materialgroup = await _materialGroupRepository.FirstOrDefaultAsync(x => x.Code == item.MaterialGroupCode);
var targetzone = await _zoneRepository.FirstOrDefaultAsync(x => x.Code == item.TargetZoneCode);
var targetlocation = await _locationRepository.FirstOrDefaultAsync(x => x.Code == item.TargetLocationCode);
var warehouse = await _warehouseRepository.FirstOrDefaultAsync(x => x.Name == item.WarehouseName);
var materialtype = await _materialTypeRepository.FirstOrDefaultAsync(x => x.Name == item.MaterialTypeName);
var materialgroup = await _materialGroupRepository.FirstOrDefaultAsync(x => x.Name == item.MaterialGroupName);
var targetzone = await _zoneRepository.FirstOrDefaultAsync(x => x.Name == item.TargetZoneName);
var targetlocation = await _locationRepository.FirstOrDefaultAsync(x => x.Name == item.TargetLocationName);
await _putawayRepository.InsertAsync(new Putaway
{
Code = item.Code,
Name = item.Name,
Description = item.Description,
Priority = item.Priority,
@ -2400,7 +2383,6 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
await _operationTypeRepository.InsertAsync(new OperationType
{
Code = item.Code,
Name = item.Name,
Description = item.Description,
CategoryId = operationCategory?.Id,
@ -2414,16 +2396,15 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
foreach (var item in items.Operations)
{
var exists = await _operationRepository.AnyAsync(x => x.Code == item.Code);
var exists = await _operationRepository.AnyAsync(x => x.Name == item.Name);
if (exists)
continue;
var operationType = await _operationTypeRepository.FirstOrDefaultAsync(x => x.Code == item.OperationTypeCode);
var workcenter = await _workcenterRepository.FirstOrDefaultAsync(x => x.Code == item.WorkCenterCode);
var operationType = await _operationTypeRepository.FirstOrDefaultAsync(x => x.Name == item.OperationTypeName);
var workcenter = await _workcenterRepository.FirstOrDefaultAsync(x => x.Name == item.WorkCenterName);
await _operationRepository.InsertAsync(new Operation
{
Code = item.Code,
Name = item.Name,
Description = item.Description,
OperationTypeId = operationType?.Id,
@ -2480,7 +2461,7 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
var bom = await _bomRepository.FirstOrDefaultAsync(x => x.Code == item.BomCode);
var material = await _materialRepository.FirstOrDefaultAsync(x => x.Code == item.MaterialCode);
var uom = await _uomRepository.FirstOrDefaultAsync(x => x.Name == item.UomId);
var operation = await _operationRepository.FirstOrDefaultAsync(x => x.Code == item.OperationCode);
var operation = await _operationRepository.FirstOrDefaultAsync(x => x.Name == item.OperationName);
var exists = await _bomComponentRepository.AnyAsync(x => x.BomId == bom.Id && x.MaterialId == material.Id);
if (exists)
@ -2505,13 +2486,13 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
foreach (var item in items.BomOperations)
{
var bom = await _bomRepository.FirstOrDefaultAsync(x => x.Code == item.BomCode);
var operation = await _operationRepository.FirstOrDefaultAsync(x => x.Code == item.OperationCode);
var operation = await _operationRepository.FirstOrDefaultAsync(x => x.Name == item.OperationName);
var exists = await _bomOperationRepository.AnyAsync(x => x.BomId == bom.Id && x.OperationId == operation.Id);
if (exists)
continue;
var workcenter = await _workcenterRepository.FirstOrDefaultAsync(x => x.Code == item.WorkcenterCode);
var workcenter = await _workcenterRepository.FirstOrDefaultAsync(x => x.Name == item.WorkcenterName);
await _bomOperationRepository.InsertAsync(new BomOperation
{
@ -2765,9 +2746,9 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
foreach (var item in items.Inventories)
{
var material = await _materialRepository.FirstOrDefaultAsync(x => x.Code == item.MaterialCode);
var warehouse = await _warehouseRepository.FirstOrDefaultAsync(x => x.Code == item.WarehouseCode);
var zone = await _zoneRepository.FirstOrDefaultAsync(x => x.Code == item.ZoneCode);
var location = await _locationRepository.FirstOrDefaultAsync(x => x.Code == item.LocationCode);
var warehouse = await _warehouseRepository.FirstOrDefaultAsync(x => x.Name == item.WarehouseName);
var zone = await _zoneRepository.FirstOrDefaultAsync(x => x.Name == item.ZoneName);
var location = await _locationRepository.FirstOrDefaultAsync(x => x.Name == item.LocationName);
var exists = await _inventoryRepository.AnyAsync(x => x.MaterialId == material.Id &&
x.WarehouseId == warehouse.Id &&
@ -2845,33 +2826,6 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
}, autoSave: true);
}
foreach (var item in items.MovementItems)
{
var movement = await _movementRepository.FirstOrDefaultAsync(x => x.MovementNumber == item.MovementNumber);
var exists = await _movementItemRepository.AnyAsync(x => x.MovementId == movement.Id);
if (exists)
continue;
var material = await _materialRepository.FirstOrDefaultAsync(x => x.Code == item.MaterialCode);
var warehouse = await _warehouseRepository.FirstOrDefaultAsync(x => x.Code == item.WarehouseCode);
var zone = await _zoneRepository.FirstOrDefaultAsync(x => x.Code == item.ZoneCode);
var location = await _locationRepository.FirstOrDefaultAsync(x => x.Code == item.LocationCode);
await _movementItemRepository.InsertAsync(new MovementItem
{
MovementId = movement?.Id,
WarehouseId = warehouse?.Id,
ZoneId = zone?.Id,
LocationId = location?.Id,
MaterialId = material?.Id,
Quantity = item.Quantity,
UomId = item.UomId,
LotNumber = item.LotNumber,
Description = item.Description
}, autoSave: true);
}
foreach (var item in items.WaybillStatuses)
{
var exists = await _waybillStatusRepository.AnyAsync(x => x.Name == item.Name);

View file

@ -74,7 +74,6 @@ public class DatabaseViewSeeder : IDataSeedContributor, ITransientDependency
lvl5.TenantId,
lvl5.Id,
lvl5.ParentGroupId,
lvl5.Code,
lvl5.Name,
lvl5.Description,
lvl5.IsActive,

View file

@ -106,7 +106,6 @@ public class TenantSeederDto
public List<WorkcenterTypeSeedDto> WorkcenterTypes { get; set; }
public List<WorkcenterStatusSeedDto> WorkcenterStatuses { get; set; }
public List<WorkcenterSeedDto> Workcenters { get; set; }
public List<MaintenancePlanSeedDto> MaintenancePlans { get; set; }
public List<FaultSeedDto> Faults { get; set; }
public List<FaultStatusSeedDto> FaultStatuses { get; set; }
public List<FaultTypeSeedDto> FaultTypes { get; set; }
@ -141,12 +140,10 @@ public class TenantSeederDto
public List<ProjectWorkTypeSeedDto> ProjectWorkTypes { get; set; }
public List<ProjectPhaseSeedDto> ProjectPhases { get; set; }
public List<ProjectTaskSeedDto> ProjectTasks { get; set; }
public List<ProjectTaskDailySeedDto> ProjectTaskDailies { get; set; }
public List<InventorySeedDto> Inventories { get; set; }
public List<MovementTypeSeedDto> MovementTypes { get; set; }
public List<ReferenceTypeSeedDto> ReferenceTypes { get; set; }
public List<MovementSeedDto> Movements { get; set; }
public List<MovementItemSeedDto> MovementItems { get; set; }
//Accounting
public List<WaybillTypeSeedDto> WaybillTypes { get; set; }
@ -243,21 +240,6 @@ public class MovementSeedDto
public bool IsTransfer { get; set; }
}
public class MovementItemSeedDto
{
public string MovementNumber { get; set; }
public string WarehouseCode { get; set; }
public string ZoneCode { get; set; }
public string LocationCode { get; set; }
public string MaterialCode { get; set; }
public decimal Quantity { get; set; }
public string UomId { get; set; }
public string LotNumber { get; set; }
public string Description { get; set; }
}
public class ReferenceTypeSeedDto
{
public string Name { get; set; }
@ -276,9 +258,9 @@ public class MovementTypeSeedDto
public class InventorySeedDto
{
public string MaterialCode { get; set; }
public string WarehouseCode { get; set; }
public string ZoneCode { get; set; }
public string LocationCode { get; set; }
public string WarehouseName { get; set; }
public string ZoneName { get; set; }
public string LocationName { get; set; }
public decimal Quantity { get; set; }
public decimal ReservedQuantity { get; set; }
@ -451,8 +433,8 @@ public class ProjectTypeSeedDto
public class BomOperationSeedDto
{
public string BomCode { get; set; }
public string OperationCode { get; set; }
public string? WorkcenterCode { get; set; }
public string OperationName { get; set; }
public string? WorkcenterName { get; set; }
public int Sequence { get; set; }
public int SetupTime { get; set; }
public int RunTime { get; set; }
@ -467,7 +449,7 @@ public class BomComponentSeedDto
{
public string BomCode { get; set; }
public string MaterialCode { get; set; }
public string OperationCode { get; set; }
public string OperationName { get; set; }
public decimal Quantity { get; set; }
public string UomId { get; set; }
@ -504,11 +486,10 @@ public class BomTypeSeedDto
public class OperationSeedDto
{
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public string OperationTypeCode { get; set; }
public string WorkCenterCode { get; set; }
public string OperationTypeName { get; set; }
public string WorkCenterName { get; set; }
public int StandardTime { get; set; }
public int SetupTime { get; set; }
public decimal LaborCost { get; set; }
@ -521,7 +502,6 @@ public class OperationSeedDto
public class OperationTypeSeedDto
{
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public string CategoryName { get; set; }
@ -548,21 +528,20 @@ public class PutawaySeedDto
public string Strategy { get; set; }
public bool IsActive { get; set; }
public string WarehouseCode { get; set; }
public string MaterialTypeCode { get; set; }
public string MaterialGroupCode { get; set; }
public string TargetZoneCode { get; set; }
public string TargetLocationCode { get; set; }
public string WarehouseName { get; set; }
public string MaterialTypeName { get; set; }
public string MaterialGroupName { get; set; }
public string TargetZoneName { get; set; }
public string TargetLocationName { get; set; }
}
public class LocationSeedDto
{
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public string WarehouseCode { get; set; }
public string ZoneCode { get; set; }
public string LocationTypeCode { get; set; }
public string WarehouseName { get; set; }
public string ZoneName { get; set; }
public string LocationTypeName { get; set; }
public decimal Capacity { get; set; }
public decimal CurrentStock { get; set; }
@ -573,11 +552,10 @@ public class LocationSeedDto
public class ZoneSeedDto
{
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public string ZoneTypeCode { get; set; }
public string WarehouseCode { get; set; }
public string ZoneTypeName { get; set; }
public string WarehouseName { get; set; }
public decimal Temperature { get; set; }
public decimal Humidity { get; set; }
@ -586,11 +564,10 @@ public class ZoneSeedDto
public class WarehouseSeedDto
{
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public string EmployeeCode { get; set; }
public string WarehouseTypeCode { get; set; }
public string WarehouseTypeName { get; set; }
public string Country { get; set; }
public string City { get; set; }
@ -608,7 +585,6 @@ public class WarehouseSeedDto
public class WarehouseTypeSeedDto
{
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public bool IsActive { get; set; }
@ -616,7 +592,6 @@ public class WarehouseTypeSeedDto
public class ZoneTypeSeedDto
{
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public bool IsActive { get; set; }
@ -624,7 +599,6 @@ public class ZoneTypeSeedDto
public class LocationTypeSeedDto
{
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public bool IsActive { get; set; }
@ -646,14 +620,13 @@ public class WorkorderStatusSeedDto
public class FaultSeedDto
{
public string Code { get; set; }
public string WorkCenterCode { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public string WorkCenterName { get; set; }
public string Location { get; set; }
public string FaultTypeName { get; set; }
public string Priority { get; set; }
public string Severity { get; set; }
public string Title { get; set; }
public string Description { get; set; }
public string Status { get; set; }
public int? EstimatedRepairTime { get; set; }
public int? ActualRepairTime { get; set; }
@ -676,26 +649,8 @@ public class FaultTypeSeedDto
public bool IsActive { get; set; }
}
public class MaintenancePlanSeedDto
{
public string Code { get; set; }
public string WorkCenterCode { get; set; }
public string PlanType { get; set; }
public string Priority { get; set; }
public string Description { get; set; }
public int Frequency { get; set; }
public string FrequencyUnit { get; set; }
public int EstimatedDuration { get; set; }
public string RequiredSkillsJson { get; set; }
public string Instructions { get; set; }
public DateTime NextDue { get; set; }
public bool IsActive { get; set; }
public DateTime? LastExecuted { get; set; }
}
public class WorkcenterSeedDto
{
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public string WorkcenterTypeName { get; set; }
@ -706,7 +661,7 @@ public class WorkcenterSeedDto
public DateTime WarrantyExpiry { get; set; }
public string Location { get; set; }
public string DepartmentCode { get; set; }
public string DepartmentName { get; set; }
public string Status { get; set; }
public string Criticality { get; set; }
@ -718,7 +673,6 @@ public class WorkcenterSeedDto
public class WorkcenterTypeSeedDto
{
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public bool IsActive { get; set; }
@ -734,8 +688,8 @@ public class WorkcenterStatusSeedDto
public class ApprovalSeedDto
{
public string Name { get; set; }
public string DepartmentCode { get; set; }
public string MaterialTypeCode { get; set; }
public string DepartmentName { get; set; }
public string MaterialTypeName { get; set; }
public decimal AmountThreshold { get; set; }
public bool IsActive { get; set; }
}
@ -798,7 +752,6 @@ public class PartnerSeedDto
public class LossReasonSeedDto
{
public string Code { get; set; }
public string Name { get; set; }
public string Category { get; set; }
public string Description { get; set; }
@ -846,8 +799,8 @@ public class MaterialSeedDto
public string Name { get; set; }
public string Barcode { get; set; }
public string Description { get; set; }
public string MaterialTypeCode { get; set; }
public string MaterialGroupCode { get; set; }
public string MaterialTypeName { get; set; }
public string MaterialGroupName { get; set; }
public string UomId { get; set; }
public decimal CostPrice { get; set; }
public decimal SalesPrice { get; set; }
@ -859,7 +812,6 @@ public class MaterialSeedDto
public class MaterialTypeSeedDto
{
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public bool IsActive { get; set; }
@ -867,10 +819,9 @@ public class MaterialTypeSeedDto
public class MaterialGroupSeedDto
{
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public string ParentGroupCode { get; set; }
public string ParentGroupName { get; set; }
public bool IsActive { get; set; }
}
@ -1009,7 +960,7 @@ public class AnnouncementSeedDto
public DateTime? ExpiryDate { get; set; }
public bool IsPinned { get; set; }
public int ViewCount { get; set; }
public string DepartmentCodes { get; set; }
public string DepartmentNames { get; set; }
}
public class ShuttleRouteSeedDto
@ -1060,7 +1011,7 @@ public class Performans360SeedDto
public DateTime StartDate { get; set; }
public DateTime EndDate { get; set; }
public string Status { get; set; }
public string DepartmentCode { get; set; }
public string DepartmentName { get; set; }
public string TargetEmployees { get; set; }
}
@ -1140,25 +1091,24 @@ public class EmployeeSeedDto
public DateTime HireDate { get; set; }
public DateTime? TerminationDate { get; set; }
public string EmploymentTypeName { get; set; }
public string JobPositionCode { get; set; }
public string DepartmentCode { get; set; }
public string JobPositionName { get; set; }
public string DepartmentName { get; set; }
public string WorkLocation { get; set; }
public decimal BaseSalary { get; set; }
public string ManagerCode { get; set; }
public string Currency { get; set; }
public string PayrollGroup { get; set; }
public string BankCode { get; set; }
public string BankName { get; set; }
public string IbanNumber { get; set; }
public string BadgeCode { get; set; }
public string BadgeName { get; set; }
public string EmployeeStatus { get; set; }
public bool IsActive { get; set; }
}
public class BadgeSeedDto
{
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public string Icon { get; set; }
@ -1173,12 +1123,11 @@ public class BadgeSeedDto
public class CostCenterSeedDto
{
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public string ParentCostCenterCode { get; set; }
public string ParentCostCenterName { get; set; }
public string ResponsibleEmployeeCode { get; set; }
public string DepartmentCode { get; set; }
public string DepartmentName { get; set; }
public string CostCenterType { get; set; }
public decimal BudgetedAmount { get; set; }
public decimal ActualAmount { get; set; }
@ -1189,23 +1138,21 @@ public class CostCenterSeedDto
public class DepartmentSeedDto
{
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public string ParentDepartmentCode { get; set; }
public string ParentDepartmentName { get; set; }
public List<string> SubDepartments { get; set; }
public string ManagerCode { get; set; }
public string CostCenterCode { get; set; }
public string CostCenterName { get; set; }
public decimal Budget { get; set; }
public bool IsActive { get; set; }
}
public class JobPositionSeedDto
{
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public string DepartmentCode { get; set; }
public string DepartmentName { get; set; }
public string Level { get; set; }
public decimal MinSalary { get; set; }
public decimal MaxSalary { get; set; }

View file

@ -106,7 +106,6 @@ export interface EmployeeDto {
export interface DepartmentDto {
// İnsan Kaynakları Departmanı
id: string
code: string
name: string
description?: string
parentDepartmentId?: string
@ -125,7 +124,6 @@ export interface DepartmentDto {
export interface JobPositionDto {
// İnsan Kaynakları İş Pozisyonu
id: string
code: string
name: string
description?: string
departmentId: string