Store düzenlemeleri

This commit is contained in:
Sedat Öztürk 2025-11-24 23:50:53 +03:00
parent 6cf82fa913
commit ff49904bb0
23 changed files with 3083 additions and 452 deletions

View file

@ -165,8 +165,8 @@
}, },
{ {
"resourceName": "Platform", "resourceName": "Platform",
"key": "App.Warehouse", "key": "App.Store",
"en": "Warehouse", "en": "Store",
"tr": "Depo" "tr": "Depo"
}, },
{ {
@ -6595,21 +6595,18 @@
"tr": "Ürünlerimizi Keşfedin", "tr": "Ürünlerimizi Keşfedin",
"en": "Explore Our Products" "en": "Explore Our Products"
}, },
{ {
"resourceName": "Platform", "resourceName": "Platform",
"key": "Public.hero.slide1.title", "key": "Public.hero.slide1.title",
"tr": "Türkiye'nin Lider Dil Kursu Yazılımı", "tr": "Türkiye'nin Lider Dil Kursu Yazılımı",
"en": "The Turkey's Leading Language Course Software" "en": "The Turkey's Leading Language Course Software"
}, },
{ {
"resourceName": "Platform", "resourceName": "Platform",
"key": "Public.hero.slide1.subtitle", "key": "Public.hero.slide1.subtitle",
"tr": "20 yılı aşkın tecrübemizle, yabancı dil okulları ve kurslar için özel olarak geliştirdiğimiz yazılım çözümlerimizle işletmenizi dijital dünyada bir adım öne taşıyoruz.", "tr": "20 yılı aşkın tecrübemizle, yabancı dil okulları ve kurslar için özel olarak geliştirdiğimiz yazılım çözümlerimizle işletmenizi dijital dünyada bir adım öne taşıyoruz.",
"en": "With over 20 years of experience, we help you take your business one step ahead in the digital world with our software solutions developed specifically for language schools and courses." "en": "With over 20 years of experience, we help you take your business one step ahead in the digital world with our software solutions developed specifically for language schools and courses."
}, },
{ {
"resourceName": "Platform", "resourceName": "Platform",
"key": "Public.hero.slide1.service1.title", "key": "Public.hero.slide1.service1.title",
@ -6646,21 +6643,18 @@
"tr": "İnternet bağlantısının olduğu her yerden, yüksek güvenlik standartlarıyla platformunuza kesintisiz erişim sağlayın.", "tr": "İnternet bağlantısının olduğu her yerden, yüksek güvenlik standartlarıyla platformunuza kesintisiz erişim sağlayın.",
"en": "Access your platform securely and seamlessly from anywhere with an internet connection, supported by enterprise-grade security standards." "en": "Access your platform securely and seamlessly from anywhere with an internet connection, supported by enterprise-grade security standards."
}, },
{ {
"resourceName": "Platform", "resourceName": "Platform",
"key": "Public.hero.slide2.title", "key": "Public.hero.slide2.title",
"tr": "Entegre ERP Otomasyonu", "tr": "Entegre ERP Otomasyonu",
"en": "Integrated ERP Automation" "en": "Integrated ERP Automation"
}, },
{ {
"resourceName": "Platform", "resourceName": "Platform",
"key": "Public.hero.slide2.subtitle", "key": "Public.hero.slide2.subtitle",
"tr": "Operasyonel verimliliğinizi artırmak için tüm iş süreçlerinizi tek ve bütünleşik bir platformdan yönetin.", "tr": "Operasyonel verimliliğinizi artırmak için tüm iş süreçlerinizi tek ve bütünleşik bir platformdan yönetin.",
"en": "Manage all your business processes from a single, integrated platform to enhance operational efficiency." "en": "Manage all your business processes from a single, integrated platform to enhance operational efficiency."
}, },
{ {
"resourceName": "Platform", "resourceName": "Platform",
"key": "Public.hero.slide2.service1.title", "key": "Public.hero.slide2.service1.title",
@ -6697,7 +6691,6 @@
"tr": "Kurumsal güvenlik standartlarına uygun veri koruma altyapısıyla bilgilerinizi yetkisiz erişimlere ve risklere karşı güvence altına alın.", "tr": "Kurumsal güvenlik standartlarına uygun veri koruma altyapısıyla bilgilerinizi yetkisiz erişimlere ve risklere karşı güvence altına alın.",
"en": "Safeguard your information against unauthorized access and risks with enterprise-grade data protection infrastructure." "en": "Safeguard your information against unauthorized access and risks with enterprise-grade data protection infrastructure."
}, },
{ {
"resourceName": "Platform", "resourceName": "Platform",
"key": "Public.hero.slide3.title", "key": "Public.hero.slide3.title",
@ -6710,7 +6703,6 @@
"tr": "Kod yazmadan hızlı uygulama geliştirin, iş süreçlerinizi kolayca dijitalleştirin.", "tr": "Kod yazmadan hızlı uygulama geliştirin, iş süreçlerinizi kolayca dijitalleştirin.",
"en": "Build applications rapidly without coding and digitize your business processes with ease." "en": "Build applications rapidly without coding and digitize your business processes with ease."
}, },
{ {
"resourceName": "Platform", "resourceName": "Platform",
"key": "Public.hero.slide3.service1.title", "key": "Public.hero.slide3.service1.title",
@ -6723,7 +6715,6 @@
"tr": "Sürükle-bırak bileşenlerle hızlı, esnek ve kullanıcı dostu arayüzler oluşturarak uygulama geliştirme süreçlerinizi hızlandırın.", "tr": "Sürükle-bırak bileşenlerle hızlı, esnek ve kullanıcı dostu arayüzler oluşturarak uygulama geliştirme süreçlerinizi hızlandırın.",
"en": "Accelerate your development cycles by creating fast, flexible, and user-friendly interfaces using drag-and-drop components." "en": "Accelerate your development cycles by creating fast, flexible, and user-friendly interfaces using drag-and-drop components."
}, },
{ {
"resourceName": "Platform", "resourceName": "Platform",
"key": "Public.hero.slide3.service2.title", "key": "Public.hero.slide3.service2.title",
@ -6736,7 +6727,6 @@
"tr": "Veri modellerinizden otomatik olarak üretilen RESTful servislerle entegrasyon süreçlerini kolaylaştırın ve geliştirme maliyetlerini azaltın.", "tr": "Veri modellerinizden otomatik olarak üretilen RESTful servislerle entegrasyon süreçlerini kolaylaştırın ve geliştirme maliyetlerini azaltın.",
"en": "Simplify integrations and reduce development costs with automatically generated RESTful services based on your data models." "en": "Simplify integrations and reduce development costs with automatically generated RESTful services based on your data models."
}, },
{ {
"resourceName": "Platform", "resourceName": "Platform",
"key": "Public.hero.slide3.service3.title", "key": "Public.hero.slide3.service3.title",
@ -6749,7 +6739,6 @@
"tr": "Aynı altyapıyla web, mobil ve masaüstü uygulamaları kolayca oluşturun ve tüm platformlarda tutarlı kullanıcı deneyimi sağlayın.", "tr": "Aynı altyapıyla web, mobil ve masaüstü uygulamaları kolayca oluşturun ve tüm platformlarda tutarlı kullanıcı deneyimi sağlayın.",
"en": "Build web, mobile, and desktop applications using a unified infrastructure while delivering a consistent user experience across all platforms." "en": "Build web, mobile, and desktop applications using a unified infrastructure while delivering a consistent user experience across all platforms."
}, },
{ {
"resourceName": "Platform", "resourceName": "Platform",
"key": "Public.login.createAccount", "key": "Public.login.createAccount",
@ -9506,55 +9495,91 @@
}, },
{ {
"resourceName": "Platform", "resourceName": "Platform",
"key": "App.Warehouse.Definitions", "key": "App.Store.WarehouseType",
"tr": "Depo Tipleri",
"en": "Warehouse Types"
},
{
"resourceName": "Platform",
"key": "App.Store.Warehouse",
"tr": "Depolar",
"en": "Warehouses"
},
{
"resourceName": "Platform",
"key": "App.Store.ZoneType",
"tr": "Bölge Tipleri",
"en": "Zone Types"
},
{
"resourceName": "Platform",
"key": "App.Store.Zone",
"tr": "Bölgeler",
"en": "Zones"
},
{
"resourceName": "Platform",
"key": "App.Store.LocationType",
"tr": "Lokasyon Tipleri",
"en": "Location Types"
},
{
"resourceName": "Platform",
"key": "App.Store.Location",
"tr": "Lokasyonlar",
"en": "Locations"
},
{
"resourceName": "Platform",
"key": "App.Store.Definitions",
"tr": "Depo Tanımları", "tr": "Depo Tanımları",
"en": "Warehouse Definitions" "en": "Warehouse Definitions"
}, },
{ {
"resourceName": "Platform", "resourceName": "Platform",
"key": "App.Warehouse.Tracking", "key": "App.Store.Tracking",
"tr": "Lokasyon Takibi", "tr": "Lokasyon Takibi",
"en": "Location Tracking" "en": "Location Tracking"
}, },
{ {
"resourceName": "Platform", "resourceName": "Platform",
"key": "App.Warehouse.Putaway", "key": "App.Store.Putaway",
"tr": "Yerleştirme", "tr": "Yerleştirme",
"en": "Putaway" "en": "Putaway"
}, },
{ {
"resourceName": "Platform", "resourceName": "Platform",
"key": "App.Warehouse.Receipt", "key": "App.Store.Receipt",
"tr": "Stok Girişi", "tr": "Stok Girişi",
"en": "Stock Receipt" "en": "Stock Receipt"
}, },
{ {
"resourceName": "Platform", "resourceName": "Platform",
"key": "App.Warehouse.Issue", "key": "App.Store.Issue",
"tr": "Stok Çıkışı", "tr": "Stok Çıkışı",
"en": "Stock Issue" "en": "Stock Issue"
}, },
{ {
"resourceName": "Platform", "resourceName": "Platform",
"key": "App.Warehouse.Transfer", "key": "App.Store.Transfer",
"tr": "Stok Transferi", "tr": "Stok Transferi",
"en": "Stock Transfer" "en": "Stock Transfer"
}, },
{ {
"resourceName": "Platform", "resourceName": "Platform",
"key": "App.Warehouse.Inventory", "key": "App.Store.Inventory",
"tr": "Stok Durumu", "tr": "Stok Durumu",
"en": "Stock Status" "en": "Stock Status"
}, },
{ {
"resourceName": "Platform", "resourceName": "Platform",
"key": "App.Warehouse.Movements", "key": "App.Store.Movements",
"tr": "Stok Hareketleri", "tr": "Stok Hareketleri",
"en": "Stock Movements" "en": "Stock Movements"
}, },
{ {
"resourceName": "Platform", "resourceName": "Platform",
"key": "App.Warehouse.Stocklevel", "key": "App.Store.Stocklevel",
"tr": "Lot ve Seri No Takibi", "tr": "Lot ve Seri No Takibi",
"en": "Lot and Serial Number Tracking" "en": "Lot and Serial Number Tracking"
}, },

View file

@ -0,0 +1,468 @@
using System;
using System.Collections.Generic;
using System.Data;
using System.Text.Json;
using System.Threading.Tasks;
using Erp.Languages.Languages;
using Erp.Platform.Entities;
using Erp.Platform.Enums;
using Erp.Platform.ListForms;
using Erp.Platform.Queries;
using Microsoft.Extensions.Configuration;
using Volo.Abp.Data;
using Volo.Abp.DependencyInjection;
using Volo.Abp.Domain.Repositories;
using Volo.Abp.Identity;
using AppCodes = Erp.Platform.Data.Seeds.SeedConsts.AppCodes;
using static Erp.Platform.PlatformConsts;
using static Erp.Platform.PlatformSeeder.SeederDefaults;
namespace Erp.Platform.Data.Seeds;
public class ListFormSeeder_Warehouse : IDataSeedContributor, ITransientDependency
{
private readonly IRepository<ListForm, Guid> _listFormRepository;
private readonly IRepository<ListFormField, Guid> _listFormFieldRepository;
private readonly IdentityUserManager _identityUserManager;
private readonly IdentityRoleManager _identityRoleManager;
private readonly IConfiguration _configuration;
public ListFormSeeder_Warehouse(
IRepository<ListForm, Guid> listFormRepository,
IRepository<ListFormField, Guid> listFormFieldRepository,
IdentityUserManager userManager,
IdentityRoleManager roleManager,
IConfiguration configuration)
{
_listFormRepository = listFormRepository;
_listFormFieldRepository = listFormFieldRepository;
_identityUserManager = userManager;
_identityRoleManager = roleManager;
_configuration = configuration;
}
public async Task SeedAsync(DataSeedContext context)
{
var listFormName = String.Empty;
#region Warehouse Type
listFormName = AppCodes.Store.WarehouseType;
if (!await _listFormRepository.AnyAsync(a => a.ListFormCode == listFormName))
{
var listForm = await _listFormRepository.InsertAsync(
new ListForm()
{
ListFormType = ListFormTypeEnum.List,
IsSubForm = false,
ShowNote = true,
LayoutJson = DefaultLayoutJson,
CultureName = LanguageCodes.En,
ListFormCode = listFormName,
Name = listFormName,
Title = listFormName,
DataSourceCode = SeedConsts.DataSources.DefaultCode,
IsTenant = true,
IsBranch = false,
IsOrganizationUnit = false,
Description = listFormName,
SelectCommandType = SelectCommandTypeEnum.Table,
SelectCommand = TableNameResolver.GetFullTableName(nameof(TableNameEnum.WarehouseType)),
KeyFieldName = "Id",
KeyFieldDbSourceType = DbType.Guid,
DefaultFilter = DefaultFilterJson,
SortMode = GridOptions.SortModeSingle,
FilterRowJson = DefaultFilterRowJson,
HeaderFilterJson = DefaultHeaderFilterJson,
SearchPanelJson = DefaultSearchPanelJson,
GroupPanelJson = DefaultGroupPanelJson,
SelectionJson = DefaultSelectionSingleJson,
ColumnOptionJson = DefaultColumnOptionJson,
PermissionJson = DefaultPermissionJson(listFormName),
DeleteCommand = DefaultDeleteCommand(nameof(TableNameEnum.WarehouseType)),
DeleteFieldsDefaultValueJson = DefaultDeleteFieldsDefaultValueJson,
PagerOptionJson = DefaultPagerOptionJson,
InsertFieldsDefaultValueJson = DefaultInsertFieldsDefaultValueJson,
EditingOptionJson = DefaultEditingOptionJson(listFormName, 500, 250, 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 = "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 },
]}
}),
FormFieldsDefaultValueJson = JsonSerializer.Serialize(new FieldsDefaultValue[] {
new() { FieldName = "IsActive", FieldDbType = DbType.Boolean, Value = "true", CustomValueType = FieldCustomValueTypeEnum.Value }
}),
}
);
#region WarehouseType Fields
await _listFormFieldRepository.InsertManyAsync([
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.Guid,
FieldName = "Id",
Width = 100,
ListOrderNo = 1,
Visible = false,
IsActive = true,
IsDeleted = false,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
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,
SourceDbType = DbType.String,
FieldName = "Name",
Width = 350,
ListOrderNo = 3,
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 = "Description",
Width = 500,
ListOrderNo = 4,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.Boolean,
FieldName = "IsActive",
Width = 100,
ListOrderNo = 5,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
}
]);
#endregion
}
#endregion
#region Zone Type
listFormName = AppCodes.Store.ZoneType;
if (!await _listFormRepository.AnyAsync(a => a.ListFormCode == listFormName))
{
var listForm = await _listFormRepository.InsertAsync(
new ListForm()
{
ListFormType = ListFormTypeEnum.List,
IsSubForm = false,
ShowNote = true,
LayoutJson = DefaultLayoutJson,
CultureName = LanguageCodes.En,
ListFormCode = listFormName,
Name = listFormName,
Title = listFormName,
DataSourceCode = SeedConsts.DataSources.DefaultCode,
IsTenant = true,
IsBranch = false,
IsOrganizationUnit = false,
Description = listFormName,
SelectCommandType = SelectCommandTypeEnum.Table,
SelectCommand = TableNameResolver.GetFullTableName(nameof(TableNameEnum.ZoneType)),
KeyFieldName = "Id",
KeyFieldDbSourceType = DbType.Guid,
DefaultFilter = DefaultFilterJson,
SortMode = GridOptions.SortModeSingle,
FilterRowJson = DefaultFilterRowJson,
HeaderFilterJson = DefaultHeaderFilterJson,
SearchPanelJson = DefaultSearchPanelJson,
GroupPanelJson = DefaultGroupPanelJson,
SelectionJson = DefaultSelectionSingleJson,
ColumnOptionJson = DefaultColumnOptionJson,
PermissionJson = DefaultPermissionJson(listFormName),
DeleteCommand = DefaultDeleteCommand(nameof(TableNameEnum.ZoneType)),
DeleteFieldsDefaultValueJson = DefaultDeleteFieldsDefaultValueJson,
PagerOptionJson = DefaultPagerOptionJson,
InsertFieldsDefaultValueJson = DefaultInsertFieldsDefaultValueJson,
EditingOptionJson = DefaultEditingOptionJson(listFormName, 500, 250, 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 = "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 },
]}
}),
FormFieldsDefaultValueJson = JsonSerializer.Serialize(new FieldsDefaultValue[] {
new() { FieldName = "IsActive", FieldDbType = DbType.Boolean, Value = "true", CustomValueType = FieldCustomValueTypeEnum.Value }
}),
}
);
#region ZoneType Fields
await _listFormFieldRepository.InsertManyAsync([
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.Guid,
FieldName = "Id",
Width = 100,
ListOrderNo = 1,
Visible = false,
IsActive = true,
IsDeleted = false,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
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,
SourceDbType = DbType.String,
FieldName = "Name",
Width = 350,
ListOrderNo = 3,
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 = "Description",
Width = 500,
ListOrderNo = 4,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.Boolean,
FieldName = "IsActive",
Width = 100,
ListOrderNo = 5,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
}
]);
#endregion
}
#endregion
#region Location Type
listFormName = AppCodes.Store.LocationType;
if (!await _listFormRepository.AnyAsync(a => a.ListFormCode == listFormName))
{
var listForm = await _listFormRepository.InsertAsync(
new ListForm()
{
ListFormType = ListFormTypeEnum.List,
IsSubForm = false,
ShowNote = true,
LayoutJson = DefaultLayoutJson,
CultureName = LanguageCodes.En,
ListFormCode = listFormName,
Name = listFormName,
Title = listFormName,
DataSourceCode = SeedConsts.DataSources.DefaultCode,
IsTenant = true,
IsBranch = false,
IsOrganizationUnit = false,
Description = listFormName,
SelectCommandType = SelectCommandTypeEnum.Table,
SelectCommand = TableNameResolver.GetFullTableName(nameof(TableNameEnum.LocationType)),
KeyFieldName = "Id",
KeyFieldDbSourceType = DbType.Guid,
DefaultFilter = DefaultFilterJson,
SortMode = GridOptions.SortModeSingle,
FilterRowJson = DefaultFilterRowJson,
HeaderFilterJson = DefaultHeaderFilterJson,
SearchPanelJson = DefaultSearchPanelJson,
GroupPanelJson = DefaultGroupPanelJson,
SelectionJson = DefaultSelectionSingleJson,
ColumnOptionJson = DefaultColumnOptionJson,
PermissionJson = DefaultPermissionJson(listFormName),
DeleteCommand = DefaultDeleteCommand(nameof(TableNameEnum.LocationType)),
DeleteFieldsDefaultValueJson = DefaultDeleteFieldsDefaultValueJson,
PagerOptionJson = DefaultPagerOptionJson,
InsertFieldsDefaultValueJson = DefaultInsertFieldsDefaultValueJson,
EditingOptionJson = DefaultEditingOptionJson(listFormName, 500, 250, 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 = "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 },
]}
}),
FormFieldsDefaultValueJson = JsonSerializer.Serialize(new FieldsDefaultValue[] {
new() { FieldName = "IsActive", FieldDbType = DbType.Boolean, Value = "true", CustomValueType = FieldCustomValueTypeEnum.Value }
}),
}
);
#region ZoneType Fields
await _listFormFieldRepository.InsertManyAsync([
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.Guid,
FieldName = "Id",
Width = 100,
ListOrderNo = 1,
Visible = false,
IsActive = true,
IsDeleted = false,
ValidationRuleJson = DefaultValidationRuleRequiredJson,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
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,
SourceDbType = DbType.String,
FieldName = "Name",
Width = 350,
ListOrderNo = 3,
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 = "Description",
Width = 500,
ListOrderNo = 4,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
},
new() {
ListFormCode = listForm.ListFormCode,
CultureName = LanguageCodes.En,
SourceDbType = DbType.Boolean,
FieldName = "IsActive",
Width = 100,
ListOrderNo = 5,
Visible = true,
IsActive = true,
IsDeleted = false,
AllowSearch = true,
ColumnCustomizationJson = DefaultColumnCustomizationJson,
PermissionJson = DefaultFieldPermissionJson(listForm.Name),
PivotSettingsJson = DefaultPivotSettingsJson
}
]);
#endregion
}
#endregion
}
}

View file

@ -1,187 +0,0 @@
using System;
using System.Collections.Generic;
using System.Data;
using System.Text.Json;
using System.Threading.Tasks;
using Erp.Languages.Languages;
using Erp.Platform.Entities;
using Erp.Platform.Enums;
using Erp.Platform.ListForms;
using Erp.Platform.Queries;
using Microsoft.Extensions.Configuration;
using Volo.Abp.Data;
using Volo.Abp.DependencyInjection;
using Volo.Abp.Domain.Repositories;
using Volo.Abp.Identity;
using Volo.Abp.TenantManagement;
using AbpIdentity = Erp.Platform.Data.Seeds.SeedConsts.AbpIdentity;
using AppCodes = Erp.Platform.Data.Seeds.SeedConsts.AppCodes;
using static Erp.Platform.PlatformConsts;
using static Erp.Platform.PlatformSeeder.SeederDefaults;
namespace Erp.Platform.Data.Seeds;
public class ListFormSeeder_Warehouse : IDataSeedContributor, ITransientDependency
{
private readonly IRepository<ListForm, Guid> _listFormRepository;
private readonly IRepository<ListFormField, Guid> _listFormFieldRepository;
private readonly IdentityUserManager _identityUserManager;
private readonly IdentityRoleManager _identityRoleManager;
private readonly IConfiguration _configuration;
public ListFormSeeder_Warehouse(
IRepository<ListForm, Guid> listFormRepository,
IRepository<ListFormField, Guid> listFormFieldRepository,
IdentityUserManager userManager,
IdentityRoleManager roleManager,
IConfiguration configuration)
{
_listFormRepository = listFormRepository;
_listFormFieldRepository = listFormFieldRepository;
_identityUserManager = userManager;
_identityRoleManager = roleManager;
_configuration = configuration;
}
public async Task SeedAsync(DataSeedContext context)
{
var listFormName = String.Empty;
// #region Workcenter Type
// if (!await _listFormRepository.AnyAsync(a => a.ListFormCode == AppCodes.SupplyChain.MaterialType))
// {
// var listFormMaterialType = await _listFormRepository.InsertAsync(
// new ListForm()
// {
// ListFormType = ListFormTypeEnum.List,
// IsSubForm = false,
// LayoutJson = DefaultLayoutJson,
// CultureName = LanguageCodes.En,
// ListFormCode = AppCodes.SupplyChain.MaterialType,
// Name = AppCodes.SupplyChain.MaterialType,
// Title = AppCodes.SupplyChain.MaterialType,
// DataSourceCode = SeedConsts.DataSources.DefaultCode,
// IsTenant = true,
// IsBranch = false,
// IsOrganizationUnit = false,
// Description = AppCodes.SupplyChain.MaterialType,
// SelectCommandType = SelectCommandTypeEnum.Table,
// SelectCommand = TableNameResolver.GetFullTableName(nameof(TableNameEnum.MaterialType)),
// KeyFieldName = "Id",
// KeyFieldDbSourceType = DbType.Guid,
// DefaultFilter = DefaultFilterJson,
// SortMode = GridOptions.SortModeSingle,
// FilterRowJson = DefaultFilterRowJson,
// HeaderFilterJson = DefaultHeaderFilterJson,
// SearchPanelJson= DefaultSearchPanelJson,
// GroupPanelJson = DefaultGroupPanelJson,
// SelectionJson = DefaultSelectionSingleJson,
// ColumnOptionJson = DefaultColumnOptionJson,
// PermissionJson = DefaultPermissionJson(AppCodes.SupplyChain.MaterialType),
// DeleteCommand = DefaultDeleteCommand(nameof(TableNameEnum.MaterialType)),
// DeleteFieldsDefaultValueJson = DefaultDeleteFieldsDefaultValueJson,
// PagerOptionJson = DefaultPagerOptionJson,
// EditingOptionJson = DefaultEditingOptionJson(AppCodes.SupplyChain.MaterialType, 500, 250, 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 = "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 },
// ]}
// }),
// InsertFieldsDefaultValueJson = DefaultInsertFieldsDefaultValueJson,
// FormFieldsDefaultValueJson = JsonSerializer.Serialize(new FieldsDefaultValue[] {
// new() { FieldName = "IsActive", FieldDbType = DbType.Boolean, Value = "true", CustomValueType = FieldCustomValueTypeEnum.Value }
// }),
// }
// );
// #region MaterialType Fields
// await _listFormFieldRepository.InsertManyAsync(new ListFormField[] {
// new() {
// ListFormCode = listFormMaterialType.ListFormCode,
// CultureName = LanguageCodes.En,
// SourceDbType = DbType.Guid,
// FieldName = "Id",
// Width = 100,
// ListOrderNo = 1,
// Visible = false,
// IsActive = true,
// IsDeleted = false,
// ValidationRuleJson = DefaultValidationRuleRequiredJson,
// ColumnCustomizationJson = DefaultColumnCustomizationJson,
// PermissionJson = DefaultFieldPermissionJson(AppCodes.SupplyChain.MaterialType),
// PivotSettingsJson = DefaultPivotSettingsJson
// },
// new() {
// ListFormCode = listFormMaterialType.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(AppCodes.SupplyChain.MaterialType),
// PivotSettingsJson = DefaultPivotSettingsJson
// },
// new() {
// ListFormCode = listFormMaterialType.ListFormCode,
// CultureName = LanguageCodes.En,
// SourceDbType = DbType.String,
// FieldName = "Name",
// Width = 350,
// ListOrderNo = 3,
// Visible = true,
// IsActive = true,
// IsDeleted = false,
// SortIndex = 1,
// SortDirection = GridColumnOptions.SortOrderAsc,
// AllowSearch = true,
// ValidationRuleJson = DefaultValidationRuleRequiredJson,
// ColumnCustomizationJson = DefaultColumnCustomizationJson,
// PermissionJson = DefaultFieldPermissionJson(AppCodes.SupplyChain.MaterialType),
// PivotSettingsJson = DefaultPivotSettingsJson
// },
// new() {
// ListFormCode = listFormMaterialType.ListFormCode,
// CultureName = LanguageCodes.En,
// SourceDbType = DbType.String,
// FieldName = "Description",
// Width = 500,
// ListOrderNo = 4,
// Visible = true,
// IsActive = true,
// IsDeleted = false,
// AllowSearch = true,
// ColumnCustomizationJson = DefaultColumnCustomizationJson,
// PermissionJson = DefaultFieldPermissionJson(AppCodes.SupplyChain.MaterialType),
// PivotSettingsJson = DefaultPivotSettingsJson
// },
// new() {
// ListFormCode = listFormMaterialType.ListFormCode,
// CultureName = LanguageCodes.En,
// SourceDbType = DbType.Boolean,
// FieldName = "IsActive",
// Width = 100,
// ListOrderNo = 5,
// Visible = true,
// IsActive = true,
// IsDeleted = false,
// AllowSearch = true,
// ColumnCustomizationJson = DefaultColumnCustomizationJson,
// PermissionJson = DefaultFieldPermissionJson(AppCodes.SupplyChain.MaterialType),
// PivotSettingsJson = DefaultPivotSettingsJson
// }
// });
// #endregion
// }
// #endregion
}
}

View file

@ -2507,8 +2507,8 @@
}, },
{ {
"ParentCode": null, "ParentCode": null,
"Code": "App.Warehouse", "Code": "App.Store",
"DisplayName": "App.Warehouse", "DisplayName": "App.Store",
"Order": 1000, "Order": 1000,
"Url": null, "Url": null,
"Icon": "FcOpenedFolder", "Icon": "FcOpenedFolder",
@ -2516,93 +2516,153 @@
"IsDisabled": false "IsDisabled": false
}, },
{ {
"ParentCode": "App.Warehouse", "ParentCode": "App.Store",
"Code": "App.Warehouse.Definitions", "Code": "App.Store.WarehouseType",
"DisplayName": "App.Warehouse.Definitions", "DisplayName": "App.Store.WarehouseType",
"Order": 1, "Order": 1,
"Url": "/admin/list/App.Store.WarehouseType",
"Icon": "FcFactory",
"RequiredPermissionName": "App.Store.WarehouseType",
"IsDisabled": false
},
{
"ParentCode": "App.Store",
"Code": "App.Store.Warehouse",
"DisplayName": "App.Store.Warehouse",
"Order": 2,
"Url": "/admin/list/App.Store.Warehouse",
"Icon": "FcDepartment",
"RequiredPermissionName": "App.Store.Warehouse",
"IsDisabled": false
},
{
"ParentCode": "App.Store",
"Code": "App.Store.ZoneType",
"DisplayName": "App.Store.ZoneType",
"Order": 3,
"Url": "/admin/list/App.Store.ZoneType",
"Icon": "FcTreeStructure",
"RequiredPermissionName": "App.Store.ZoneType",
"IsDisabled": false
},
{
"ParentCode": "App.Store",
"Code": "App.Store.Zone",
"DisplayName": "App.Store.Zone",
"Order": 4,
"Url": "/admin/list/App.Store.Zone",
"Icon": "FcOvertime",
"RequiredPermissionName": "App.Store.Zone",
"IsDisabled": false
},
{
"ParentCode": "App.Store",
"Code": "App.Store.LocationType",
"DisplayName": "App.Store.LocationType",
"Order": 5,
"Url": "/admin/list/App.Store.LocationType",
"Icon": "FcInspection",
"RequiredPermissionName": "App.Store.LocationType",
"IsDisabled": false
},
{
"ParentCode": "App.Store",
"Code": "App.Store.Location",
"DisplayName": "App.Store.Location",
"Order": 6,
"Url": "/admin/list/App.Store.Location",
"Icon": "FcGrid",
"RequiredPermissionName": "App.Store.Location",
"IsDisabled": false
},
{
"ParentCode": "App.Store",
"Code": "App.Store.Definitions",
"DisplayName": "App.Store.Definitions",
"Order": 7,
"Url": "/admin/warehouse/definitions", "Url": "/admin/warehouse/definitions",
"Icon": "FcTodoList", "Icon": "FcTodoList",
"RequiredPermissionName": "App.Warehouse.Definitions", "RequiredPermissionName": "App.Store.Definitions",
"IsDisabled": false "IsDisabled": false
}, },
{ {
"ParentCode": "App.Warehouse", "ParentCode": "App.Store",
"Code": "App.Warehouse.Tracking", "Code": "App.Store.Tracking",
"DisplayName": "App.Warehouse.Tracking", "DisplayName": "App.Store.Tracking",
"Order": 2, "Order": 8,
"Url": "/admin/warehouse/tracking", "Url": "/admin/warehouse/tracking",
"Icon": "FcSearch", "Icon": "FcSearch",
"RequiredPermissionName": "App.Warehouse.Tracking", "RequiredPermissionName": "App.Store.Tracking",
"IsDisabled": false "IsDisabled": false
}, },
{ {
"ParentCode": "App.Warehouse", "ParentCode": "App.Store",
"Code": "App.Warehouse.Putaway", "Code": "App.Store.Putaway",
"DisplayName": "App.Warehouse.Putaway", "DisplayName": "App.Store.Putaway",
"Order": 3, "Order": 9,
"Url": "/admin/warehouse/putaway", "Url": "/admin/warehouse/putaway",
"Icon": "FcCompactCamera", "Icon": "FcCompactCamera",
"RequiredPermissionName": "App.Warehouse.Putaway", "RequiredPermissionName": "App.Store.Putaway",
"IsDisabled": false "IsDisabled": false
}, },
{ {
"ParentCode": "App.Warehouse", "ParentCode": "App.Store",
"Code": "App.Warehouse.Receipt", "Code": "App.Store.Receipt",
"DisplayName": "App.Warehouse.Receipt", "DisplayName": "App.Store.Receipt",
"Order": 4, "Order": 10,
"Url": "/admin/warehouse/receipt", "Url": "/admin/warehouse/receipt",
"Icon": "FcImport", "Icon": "FcImport",
"RequiredPermissionName": "App.Warehouse.Receipt", "RequiredPermissionName": "App.Store.Receipt",
"IsDisabled": false "IsDisabled": false
}, },
{ {
"ParentCode": "App.Warehouse", "ParentCode": "App.Store",
"Code": "App.Warehouse.Issue", "Code": "App.Store.Issue",
"DisplayName": "App.Warehouse.Issue", "DisplayName": "App.Store.Issue",
"Order": 5, "Order": 11,
"Url": "/admin/warehouse/issue", "Url": "/admin/warehouse/issue",
"Icon": "FcExport", "Icon": "FcExport",
"RequiredPermissionName": "App.Warehouse.Issue", "RequiredPermissionName": "App.Store.Issue",
"IsDisabled": false "IsDisabled": false
}, },
{ {
"ParentCode": "App.Warehouse", "ParentCode": "App.Store",
"Code": "App.Warehouse.Transfer", "Code": "App.Store.Transfer",
"DisplayName": "App.Warehouse.Transfer", "DisplayName": "App.Store.Transfer",
"Order": 6, "Order": 12,
"Url": "/admin/warehouse/transfer", "Url": "/admin/warehouse/transfer",
"Icon": "FcSynchronize", "Icon": "FcSynchronize",
"RequiredPermissionName": "App.Warehouse.Transfer", "RequiredPermissionName": "App.Store.Transfer",
"IsDisabled": false "IsDisabled": false
}, },
{ {
"ParentCode": "App.Warehouse", "ParentCode": "App.Store",
"Code": "App.Warehouse.Inventory", "Code": "App.Store.Inventory",
"DisplayName": "App.Warehouse.Inventory", "DisplayName": "App.Store.Inventory",
"Order": 7, "Order": 13,
"Url": "/admin/warehouse/inventory", "Url": "/admin/warehouse/inventory",
"Icon": "FcInspection", "Icon": "FcInspection",
"RequiredPermissionName": "App.Warehouse.Inventory", "RequiredPermissionName": "App.Store.Inventory",
"IsDisabled": false "IsDisabled": false
}, },
{ {
"ParentCode": "App.Warehouse", "ParentCode": "App.Store",
"Code": "App.Warehouse.Movements", "Code": "App.Store.Movements",
"DisplayName": "App.Warehouse.Movements", "DisplayName": "App.Store.Movements",
"Order": 8, "Order": 14,
"Url": "/admin/warehouse/movements", "Url": "/admin/warehouse/movements",
"Icon": "FcParallelTasks", "Icon": "FcParallelTasks",
"RequiredPermissionName": "App.Warehouse.Movements", "RequiredPermissionName": "App.Store.Movements",
"IsDisabled": false "IsDisabled": false
}, },
{ {
"ParentCode": "App.Warehouse", "ParentCode": "App.Store",
"Code": "App.Warehouse.Stocklevel", "Code": "App.Store.Stocklevel",
"DisplayName": "App.Warehouse.Stocklevel", "DisplayName": "App.Store.Stocklevel",
"Order": 9, "Order": 15,
"Url": "/admin/warehouse/stocklevel", "Url": "/admin/warehouse/stocklevel",
"Icon": "FcViewDetails", "Icon": "FcViewDetails",
"RequiredPermissionName": "App.Warehouse.Stocklevel", "RequiredPermissionName": "App.Store.Stocklevel",
"IsDisabled": false "IsDisabled": false
}, },
{ {

File diff suppressed because it is too large Load diff

View file

@ -13,7 +13,7 @@ public enum MenuPrefix
Crm, Crm,
SupplyChain, SupplyChain,
Maintenance, Maintenance,
Warehouse, Store,
Project, Project,
Hr, Hr,
Mrp, Mrp,
@ -35,7 +35,7 @@ public static class MenuPrefixExtensions
MenuPrefix.Crm => "Crm", MenuPrefix.Crm => "Crm",
MenuPrefix.SupplyChain => "Scp", MenuPrefix.SupplyChain => "Scp",
MenuPrefix.Maintenance => "Mnt", MenuPrefix.Maintenance => "Mnt",
MenuPrefix.Warehouse => "Wh", MenuPrefix.Store => "Str",
MenuPrefix.Project => "Prj", MenuPrefix.Project => "Prj",
MenuPrefix.Hr => "Hr", MenuPrefix.Hr => "Hr",
MenuPrefix.Mrp => "Mrp", MenuPrefix.Mrp => "Mrp",

View file

@ -170,5 +170,11 @@ public enum TableNameEnum
FaultType, FaultType,
WorkorderType, WorkorderType,
WorkorderStatus, WorkorderStatus,
Workorder Workorder,
WarehouseType,
Warehouse,
ZoneType,
Zone,
LocationType,
Location,
} }

View file

@ -205,6 +205,14 @@ public static class TableNameResolver
{ nameof(TableNameEnum.Bank), (TablePrefix.TenantByName, MenuPrefix.Accounting) }, { nameof(TableNameEnum.Bank), (TablePrefix.TenantByName, MenuPrefix.Accounting) },
{ nameof(TableNameEnum.BankAccount), (TablePrefix.TenantByName, MenuPrefix.Accounting) }, { nameof(TableNameEnum.BankAccount), (TablePrefix.TenantByName, MenuPrefix.Accounting) },
// 🔹 STORE
{ nameof(TableNameEnum.WarehouseType), (TablePrefix.TenantByName, MenuPrefix.Store) },
{ nameof(TableNameEnum.Warehouse), (TablePrefix.TenantByName, MenuPrefix.Store) },
{ nameof(TableNameEnum.ZoneType), (TablePrefix.TenantByName, MenuPrefix.Store) },
{ nameof(TableNameEnum.Zone), (TablePrefix.TenantByName, MenuPrefix.Store) },
{ nameof(TableNameEnum.LocationType), (TablePrefix.TenantByName, MenuPrefix.Store) },
{ nameof(TableNameEnum.Location), (TablePrefix.TenantByName, MenuPrefix.Store) },
}; };
public static string GetFullTableName(string tableName) public static string GetFullTableName(string tableName)

View file

@ -543,6 +543,17 @@ public static class SeedConsts
public const string Bank = Default + ".Bank"; public const string Bank = Default + ".Bank";
public const string BankAccount = Default + ".BankAccount"; public const string BankAccount = Default + ".BankAccount";
} }
public static class Store
{
public const string Default = Prefix.App + ".Store";
public const string WarehouseType = Default + ".WarehouseType";
public const string Warehouse = Default + ".Warehouse";
public const string ZoneType = Default + ".ZoneType";
public const string Zone = Default + ".Zone";
public const string LocationType = Default + ".LocationType";
public const string Location = Default + ".Location";
}
} }
public static class DataSources public static class DataSources

View file

@ -76,6 +76,7 @@ public class Employee : FullAuditedEntity<Guid>, IMultiTenant
public ICollection<Partner> Partners { get; set; } public ICollection<Partner> Partners { get; set; }
public ICollection<BlogPost> BlogPosts { get; set; } public ICollection<BlogPost> BlogPosts { get; set; }
public ICollection<Opportunity> Opportunities { get; set; } public ICollection<Opportunity> Opportunities { get; set; }
public ICollection<Warehouse> Warehouses { get; set; }
} }

View file

@ -0,0 +1,28 @@
using System;
using Volo.Abp.Domain.Entities.Auditing;
using Volo.Abp.MultiTenancy;
namespace Erp.Platform.Entities;
public class Location : FullAuditedEntity<Guid>, IMultiTenant
{
public Guid? TenantId { get; set; }
public Guid WarehouseId { get; set; }
public Warehouse Warehouse { get; set; }
public Guid ZoneId { get; set; }
public Zone Zone { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public Guid LocationTypeId { get; set; }
public LocationType LocationType { get; set; }
public int Capacity { get; set; }
public int CurrentStock { get; set; }
public bool IsActive { get; set; }
}

View file

@ -0,0 +1,19 @@
using System;
using System.Collections.Generic;
using Volo.Abp.Domain.Entities.Auditing;
using Volo.Abp.MultiTenancy;
namespace Erp.Platform.Entities;
public class LocationType : 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; }
public ICollection<Location> Locations { get; set; }
}

View file

@ -0,0 +1,35 @@
using System;
using System.Collections.Generic;
using Volo.Abp.Domain.Entities.Auditing;
using Volo.Abp.MultiTenancy;
namespace Erp.Platform.Entities;
public class Warehouse : FullAuditedEntity<Guid>, IMultiTenant
{
public Guid? TenantId { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public Guid EmployeeId { get; set; }
public Employee Employee { get; set; }
public string Country { get; set; }
public string City { get; set; }
public string District { get; set; }
public string Township { get; set; }
public string PostalCode { get; set; }
public Guid WarehouseTypeId { get; set; }
public WarehouseType WarehouseType { get; set; }
public bool IsMainWarehouse { get; set; }
public int Capacity { get; set; }
public bool IsActive { get; set; }
public bool TemperatureControlled { get; set; }
public int SecurityLevel { get; set; }
public ICollection<Zone> Zones { get; set; }
public ICollection<Location> Locations { get; set; }
}

View file

@ -0,0 +1,19 @@
using System;
using System.Collections.Generic;
using Volo.Abp.Domain.Entities.Auditing;
using Volo.Abp.MultiTenancy;
namespace Erp.Platform.Entities;
public class WarehouseType : 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; }
public ICollection<Warehouse> Warehouses { get; set; }
}

View file

@ -0,0 +1,27 @@
using System;
using System.Collections.Generic;
using Volo.Abp.Domain.Entities.Auditing;
using Volo.Abp.MultiTenancy;
namespace Erp.Platform.Entities;
public class Zone : FullAuditedEntity<Guid>, IMultiTenant
{
public Guid? TenantId { get; set; }
public Guid WarehouseId { get; set; }
public Warehouse Warehouse { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public Guid ZoneTypeId { get; set; }
public ZoneType ZoneType { get; set; }
public int? Temperature { get; set; } //Sıcaklık
public int? Humidity { get; set; } //Nem
public bool IsActive { get; set; }
public ICollection<Location> Locations { get; set; }
}

View file

@ -0,0 +1,19 @@
using System;
using System.Collections.Generic;
using Volo.Abp.Domain.Entities.Auditing;
using Volo.Abp.MultiTenancy;
namespace Erp.Platform.Entities;
public class ZoneType : 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; }
public ICollection<Zone> Zones { get; set; }
}

View file

@ -230,6 +230,15 @@ public class PlatformDbContext :
public DbSet<BankAccount> BankAccounts { get; set; } public DbSet<BankAccount> BankAccounts { get; set; }
#endregion #endregion
#region Store
public DbSet<WarehouseType> WarehouseTypes { get; set; }
public DbSet<Warehouse> Warehouses { get; set; }
public DbSet<ZoneType> ZoneTypes { get; set; }
public DbSet<Zone> Zones { get; set; }
public DbSet<LocationType> LocationTypes { get; set; }
public DbSet<Location> Locations { get; set; }
#endregion
#region Maintenance #region Maintenance
public DbSet<WorkcenterType> WorkcenterTypes { get; set; } public DbSet<WorkcenterType> WorkcenterTypes { get; set; }
public DbSet<WorkcenterStatus> WorkcenterStatuses { get; set; } public DbSet<WorkcenterStatus> WorkcenterStatuses { get; set; }
@ -2868,5 +2877,129 @@ public class PlatformDbContext :
b.Property(x => x.Description).HasMaxLength(500); b.Property(x => x.Description).HasMaxLength(500);
b.Property(x => x.IsActive).HasDefaultValue(true); b.Property(x => x.IsActive).HasDefaultValue(true);
}); });
builder.Entity<WarehouseType>(b =>
{
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.WarehouseType)), Prefix.DbSchema);
b.ConfigureByConvention();
b.Property(x => x.Code).IsRequired().HasMaxLength(50);
b.Property(x => x.Name).IsRequired().HasMaxLength(50);
b.Property(x => x.Description).HasMaxLength(500);
b.Property(x => x.IsActive).HasDefaultValue(true);
});
builder.Entity<Warehouse>(b =>
{
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.Warehouse)), Prefix.DbSchema);
b.ConfigureByConvention();
b.Property(x => x.Code).IsRequired().HasMaxLength(50);
b.Property(x => x.Name).IsRequired().HasMaxLength(200);
b.Property(x => x.Description).HasMaxLength(500);
b.Property(x => x.EmployeeId).IsRequired();
b.Property(x => x.WarehouseTypeId).IsRequired();
b.Property(x => x.Country).HasMaxLength(100);
b.Property(x => x.City).HasMaxLength(100);
b.Property(x => x.District).HasMaxLength(200);
b.Property(x => x.Township).HasMaxLength(100);
b.Property(x => x.PostalCode).HasMaxLength(20);
b.Property(x => x.IsMainWarehouse).HasDefaultValue(false);
b.Property(x => x.Capacity).HasDefaultValue(0);
b.Property(x => x.IsActive).HasDefaultValue(true);
b.Property(x => x.TemperatureControlled).HasDefaultValue(false);
b.Property(x => x.SecurityLevel).HasDefaultValue(1);
b.HasOne(x => x.WarehouseType)
.WithMany(x => x.Warehouses)
.HasForeignKey(x => x.WarehouseTypeId)
.OnDelete(DeleteBehavior.Restrict);
b.HasOne(x => x.Employee)
.WithMany(x => x.Warehouses)
.HasForeignKey(x => x.EmployeeId)
.OnDelete(DeleteBehavior.Restrict);
});
builder.Entity<ZoneType>(b =>
{
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.ZoneType)), Prefix.DbSchema);
b.ConfigureByConvention();
b.Property(x => x.Code).IsRequired().HasMaxLength(50);
b.Property(x => x.Name).IsRequired().HasMaxLength(50);
b.Property(x => x.Description).HasMaxLength(500);
b.Property(x => x.IsActive).HasDefaultValue(true);
});
builder.Entity<Zone>(b =>
{
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.Zone)), Prefix.DbSchema);
b.ConfigureByConvention();
b.Property(x => x.WarehouseId).IsRequired();
b.Property(x => x.Code).IsRequired().HasMaxLength(50);
b.Property(x => x.Name).IsRequired().HasMaxLength(50);
b.Property(x => x.Description).HasMaxLength(500);
b.Property(x => x.ZoneTypeId).IsRequired();
b.Property(x => x.Temperature).HasDefaultValue(0);
b.Property(x => x.Humidity).HasDefaultValue(0);
b.Property(x => x.IsActive).HasDefaultValue(true);
b.HasOne(x => x.ZoneType)
.WithMany(x => x.Zones)
.HasForeignKey(x => x.ZoneTypeId)
.OnDelete(DeleteBehavior.Restrict);
b.HasOne(x => x.Warehouse)
.WithMany(x => x.Zones)
.HasForeignKey(x => x.WarehouseId)
.OnDelete(DeleteBehavior.Restrict);
});
builder.Entity<LocationType>(b =>
{
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.LocationType)), Prefix.DbSchema);
b.ConfigureByConvention();
b.Property(x => x.Code).IsRequired().HasMaxLength(50);
b.Property(x => x.Name).IsRequired().HasMaxLength(50);
b.Property(x => x.Description).HasMaxLength(500);
b.Property(x => x.IsActive).HasDefaultValue(true);
});
builder.Entity<Location>(b =>
{
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.Location)), Prefix.DbSchema);
b.ConfigureByConvention();
b.Property(x => x.WarehouseId).IsRequired();
b.Property(x => x.ZoneId).IsRequired();
b.Property(x => x.Code).IsRequired().HasMaxLength(50);
b.Property(x => x.Name).IsRequired().HasMaxLength(50);
b.Property(x => x.Description).HasMaxLength(500);
b.Property(x => x.LocationTypeId).IsRequired();
b.Property(x => x.Capacity).HasDefaultValue(0);
b.Property(x => x.CurrentStock).HasDefaultValue(0);
b.Property(x => x.IsActive).HasDefaultValue(true);
b.HasOne(x => x.LocationType)
.WithMany(x => x.Locations)
.HasForeignKey(x => x.LocationTypeId)
.OnDelete(DeleteBehavior.Restrict);
b.HasOne(x => x.Warehouse)
.WithMany(x => x.Locations)
.HasForeignKey(x => x.WarehouseId)
.OnDelete(DeleteBehavior.Restrict);
b.HasOne(x => x.Zone)
.WithMany(x => x.Locations)
.HasForeignKey(x => x.ZoneId)
.OnDelete(DeleteBehavior.Restrict);
});
} }
} }

View file

@ -13,7 +13,7 @@ using Volo.Abp.EntityFrameworkCore;
namespace Erp.Platform.Migrations namespace Erp.Platform.Migrations
{ {
[DbContext(typeof(PlatformDbContext))] [DbContext(typeof(PlatformDbContext))]
[Migration("20251124190041_Initial")] [Migration("20251124204213_Initial")]
partial class Initial partial class Initial
{ {
/// <inheritdoc /> /// <inheritdoc />
@ -6075,6 +6075,157 @@ namespace Erp.Platform.Migrations
b.ToTable("Sas_H_ListFormImportExecute", (string)null); b.ToTable("Sas_H_ListFormImportExecute", (string)null);
}); });
modelBuilder.Entity("Erp.Platform.Entities.Location", b =>
{
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<int>("Capacity")
.ValueGeneratedOnAdd()
.HasColumnType("int")
.HasDefaultValue(0);
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(50)
.HasColumnType("nvarchar(50)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
b.Property<Guid?>("CreatorId")
.HasColumnType("uniqueidentifier")
.HasColumnName("CreatorId");
b.Property<int>("CurrentStock")
.ValueGeneratedOnAdd()
.HasColumnType("int")
.HasDefaultValue(0);
b.Property<Guid?>("DeleterId")
.HasColumnType("uniqueidentifier")
.HasColumnName("DeleterId");
b.Property<DateTime?>("DeletionTime")
.HasColumnType("datetime2")
.HasColumnName("DeletionTime");
b.Property<string>("Description")
.HasMaxLength(500)
.HasColumnType("nvarchar(500)");
b.Property<bool>("IsActive")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(true);
b.Property<bool>("IsDeleted")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(false)
.HasColumnName("IsDeleted");
b.Property<DateTime?>("LastModificationTime")
.HasColumnType("datetime2")
.HasColumnName("LastModificationTime");
b.Property<Guid?>("LastModifierId")
.HasColumnType("uniqueidentifier")
.HasColumnName("LastModifierId");
b.Property<Guid>("LocationTypeId")
.HasColumnType("uniqueidentifier");
b.Property<string>("Name")
.IsRequired()
.HasMaxLength(50)
.HasColumnType("nvarchar(50)");
b.Property<Guid?>("TenantId")
.HasColumnType("uniqueidentifier")
.HasColumnName("TenantId");
b.Property<Guid>("WarehouseId")
.HasColumnType("uniqueidentifier");
b.Property<Guid>("ZoneId")
.HasColumnType("uniqueidentifier");
b.HasKey("Id");
b.HasIndex("LocationTypeId");
b.HasIndex("WarehouseId");
b.HasIndex("ZoneId");
b.ToTable("Str_T_Location", (string)null);
});
modelBuilder.Entity("Erp.Platform.Entities.LocationType", b =>
{
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(50)
.HasColumnType("nvarchar(50)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
b.Property<Guid?>("CreatorId")
.HasColumnType("uniqueidentifier")
.HasColumnName("CreatorId");
b.Property<Guid?>("DeleterId")
.HasColumnType("uniqueidentifier")
.HasColumnName("DeleterId");
b.Property<DateTime?>("DeletionTime")
.HasColumnType("datetime2")
.HasColumnName("DeletionTime");
b.Property<string>("Description")
.HasMaxLength(500)
.HasColumnType("nvarchar(500)");
b.Property<bool>("IsActive")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(true);
b.Property<bool>("IsDeleted")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(false)
.HasColumnName("IsDeleted");
b.Property<DateTime?>("LastModificationTime")
.HasColumnType("datetime2")
.HasColumnName("LastModificationTime");
b.Property<Guid?>("LastModifierId")
.HasColumnType("uniqueidentifier")
.HasColumnName("LastModifierId");
b.Property<string>("Name")
.IsRequired()
.HasMaxLength(50)
.HasColumnType("nvarchar(50)");
b.Property<Guid?>("TenantId")
.HasColumnType("uniqueidentifier")
.HasColumnName("TenantId");
b.HasKey("Id");
b.ToTable("Str_T_LocationType", (string)null);
});
modelBuilder.Entity("Erp.Platform.Entities.LogEntry", b => modelBuilder.Entity("Erp.Platform.Entities.LogEntry", b =>
{ {
b.Property<Guid>("Id") b.Property<Guid>("Id")
@ -11869,6 +12020,182 @@ namespace Erp.Platform.Migrations
b.ToTable("Net_T_Visitor", (string)null); b.ToTable("Net_T_Visitor", (string)null);
}); });
modelBuilder.Entity("Erp.Platform.Entities.Warehouse", b =>
{
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<int>("Capacity")
.ValueGeneratedOnAdd()
.HasColumnType("int")
.HasDefaultValue(0);
b.Property<string>("City")
.HasMaxLength(100)
.HasColumnType("nvarchar(100)");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(50)
.HasColumnType("nvarchar(50)");
b.Property<string>("Country")
.HasMaxLength(100)
.HasColumnType("nvarchar(100)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
b.Property<Guid?>("CreatorId")
.HasColumnType("uniqueidentifier")
.HasColumnName("CreatorId");
b.Property<Guid?>("DeleterId")
.HasColumnType("uniqueidentifier")
.HasColumnName("DeleterId");
b.Property<DateTime?>("DeletionTime")
.HasColumnType("datetime2")
.HasColumnName("DeletionTime");
b.Property<string>("Description")
.HasMaxLength(500)
.HasColumnType("nvarchar(500)");
b.Property<string>("District")
.HasMaxLength(200)
.HasColumnType("nvarchar(200)");
b.Property<Guid>("EmployeeId")
.HasColumnType("uniqueidentifier");
b.Property<bool>("IsActive")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(true);
b.Property<bool>("IsDeleted")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(false)
.HasColumnName("IsDeleted");
b.Property<bool>("IsMainWarehouse")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(false);
b.Property<DateTime?>("LastModificationTime")
.HasColumnType("datetime2")
.HasColumnName("LastModificationTime");
b.Property<Guid?>("LastModifierId")
.HasColumnType("uniqueidentifier")
.HasColumnName("LastModifierId");
b.Property<string>("Name")
.IsRequired()
.HasMaxLength(200)
.HasColumnType("nvarchar(200)");
b.Property<string>("PostalCode")
.HasMaxLength(20)
.HasColumnType("nvarchar(20)");
b.Property<int>("SecurityLevel")
.ValueGeneratedOnAdd()
.HasColumnType("int")
.HasDefaultValue(1);
b.Property<bool>("TemperatureControlled")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(false);
b.Property<Guid?>("TenantId")
.HasColumnType("uniqueidentifier")
.HasColumnName("TenantId");
b.Property<string>("Township")
.HasMaxLength(100)
.HasColumnType("nvarchar(100)");
b.Property<Guid>("WarehouseTypeId")
.HasColumnType("uniqueidentifier");
b.HasKey("Id");
b.HasIndex("EmployeeId");
b.HasIndex("WarehouseTypeId");
b.ToTable("Str_T_Warehouse", (string)null);
});
modelBuilder.Entity("Erp.Platform.Entities.WarehouseType", b =>
{
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(50)
.HasColumnType("nvarchar(50)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
b.Property<Guid?>("CreatorId")
.HasColumnType("uniqueidentifier")
.HasColumnName("CreatorId");
b.Property<Guid?>("DeleterId")
.HasColumnType("uniqueidentifier")
.HasColumnName("DeleterId");
b.Property<DateTime?>("DeletionTime")
.HasColumnType("datetime2")
.HasColumnName("DeletionTime");
b.Property<string>("Description")
.HasMaxLength(500)
.HasColumnType("nvarchar(500)");
b.Property<bool>("IsActive")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(true);
b.Property<bool>("IsDeleted")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(false)
.HasColumnName("IsDeleted");
b.Property<DateTime?>("LastModificationTime")
.HasColumnType("datetime2")
.HasColumnName("LastModificationTime");
b.Property<Guid?>("LastModifierId")
.HasColumnType("uniqueidentifier")
.HasColumnName("LastModifierId");
b.Property<string>("Name")
.IsRequired()
.HasMaxLength(50)
.HasColumnType("nvarchar(50)");
b.Property<Guid?>("TenantId")
.HasColumnType("uniqueidentifier")
.HasColumnName("TenantId");
b.HasKey("Id");
b.ToTable("Str_T_WarehouseType", (string)null);
});
modelBuilder.Entity("Erp.Platform.Entities.WorkHour", b => modelBuilder.Entity("Erp.Platform.Entities.WorkHour", b =>
{ {
b.Property<Guid>("Id") b.Property<Guid>("Id")
@ -12257,6 +12584,152 @@ namespace Erp.Platform.Migrations
b.ToTable("Mnt_T_WorkcenterType", (string)null); b.ToTable("Mnt_T_WorkcenterType", (string)null);
}); });
modelBuilder.Entity("Erp.Platform.Entities.Zone", b =>
{
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(50)
.HasColumnType("nvarchar(50)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
b.Property<Guid?>("CreatorId")
.HasColumnType("uniqueidentifier")
.HasColumnName("CreatorId");
b.Property<Guid?>("DeleterId")
.HasColumnType("uniqueidentifier")
.HasColumnName("DeleterId");
b.Property<DateTime?>("DeletionTime")
.HasColumnType("datetime2")
.HasColumnName("DeletionTime");
b.Property<string>("Description")
.HasMaxLength(500)
.HasColumnType("nvarchar(500)");
b.Property<int?>("Humidity")
.ValueGeneratedOnAdd()
.HasColumnType("int")
.HasDefaultValue(0);
b.Property<bool>("IsActive")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(true);
b.Property<bool>("IsDeleted")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(false)
.HasColumnName("IsDeleted");
b.Property<DateTime?>("LastModificationTime")
.HasColumnType("datetime2")
.HasColumnName("LastModificationTime");
b.Property<Guid?>("LastModifierId")
.HasColumnType("uniqueidentifier")
.HasColumnName("LastModifierId");
b.Property<string>("Name")
.IsRequired()
.HasMaxLength(50)
.HasColumnType("nvarchar(50)");
b.Property<int?>("Temperature")
.ValueGeneratedOnAdd()
.HasColumnType("int")
.HasDefaultValue(0);
b.Property<Guid?>("TenantId")
.HasColumnType("uniqueidentifier")
.HasColumnName("TenantId");
b.Property<Guid>("WarehouseId")
.HasColumnType("uniqueidentifier");
b.Property<Guid>("ZoneTypeId")
.HasColumnType("uniqueidentifier");
b.HasKey("Id");
b.HasIndex("WarehouseId");
b.HasIndex("ZoneTypeId");
b.ToTable("Str_T_Zone", (string)null);
});
modelBuilder.Entity("Erp.Platform.Entities.ZoneType", b =>
{
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(50)
.HasColumnType("nvarchar(50)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
b.Property<Guid?>("CreatorId")
.HasColumnType("uniqueidentifier")
.HasColumnName("CreatorId");
b.Property<Guid?>("DeleterId")
.HasColumnType("uniqueidentifier")
.HasColumnName("DeleterId");
b.Property<DateTime?>("DeletionTime")
.HasColumnType("datetime2")
.HasColumnName("DeletionTime");
b.Property<string>("Description")
.HasMaxLength(500)
.HasColumnType("nvarchar(500)");
b.Property<bool>("IsActive")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(true);
b.Property<bool>("IsDeleted")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(false)
.HasColumnName("IsDeleted");
b.Property<DateTime?>("LastModificationTime")
.HasColumnType("datetime2")
.HasColumnName("LastModificationTime");
b.Property<Guid?>("LastModifierId")
.HasColumnType("uniqueidentifier")
.HasColumnName("LastModifierId");
b.Property<string>("Name")
.IsRequired()
.HasMaxLength(50)
.HasColumnType("nvarchar(50)");
b.Property<Guid?>("TenantId")
.HasColumnType("uniqueidentifier")
.HasColumnName("TenantId");
b.HasKey("Id");
b.ToTable("Str_T_ZoneType", (string)null);
});
modelBuilder.Entity("Erp.Platform.Forum.ForumCategory", b => modelBuilder.Entity("Erp.Platform.Forum.ForumCategory", b =>
{ {
b.Property<Guid>("Id") b.Property<Guid>("Id")
@ -14997,6 +15470,33 @@ namespace Erp.Platform.Migrations
.IsRequired(); .IsRequired();
}); });
modelBuilder.Entity("Erp.Platform.Entities.Location", b =>
{
b.HasOne("Erp.Platform.Entities.LocationType", "LocationType")
.WithMany("Locations")
.HasForeignKey("LocationTypeId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.HasOne("Erp.Platform.Entities.Warehouse", "Warehouse")
.WithMany("Locations")
.HasForeignKey("WarehouseId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.HasOne("Erp.Platform.Entities.Zone", "Zone")
.WithMany("Locations")
.HasForeignKey("ZoneId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.Navigation("LocationType");
b.Navigation("Warehouse");
b.Navigation("Zone");
});
modelBuilder.Entity("Erp.Platform.Entities.MaintenancePlan", b => modelBuilder.Entity("Erp.Platform.Entities.MaintenancePlan", b =>
{ {
b.HasOne("Erp.Platform.Entities.Workcenter", "WorkCenter") b.HasOne("Erp.Platform.Entities.Workcenter", "WorkCenter")
@ -15666,6 +16166,25 @@ namespace Erp.Platform.Migrations
b.Navigation("Employee"); b.Navigation("Employee");
}); });
modelBuilder.Entity("Erp.Platform.Entities.Warehouse", b =>
{
b.HasOne("Erp.Platform.Entities.Employee", "Employee")
.WithMany("Warehouses")
.HasForeignKey("EmployeeId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.HasOne("Erp.Platform.Entities.WarehouseType", "WarehouseType")
.WithMany("Warehouses")
.HasForeignKey("WarehouseTypeId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.Navigation("Employee");
b.Navigation("WarehouseType");
});
modelBuilder.Entity("Erp.Platform.Entities.Workcenter", b => modelBuilder.Entity("Erp.Platform.Entities.Workcenter", b =>
{ {
b.HasOne("Erp.Platform.Entities.Department", "Department") b.HasOne("Erp.Platform.Entities.Department", "Department")
@ -15708,6 +16227,25 @@ namespace Erp.Platform.Migrations
b.Navigation("Workcenter"); b.Navigation("Workcenter");
}); });
modelBuilder.Entity("Erp.Platform.Entities.Zone", b =>
{
b.HasOne("Erp.Platform.Entities.Warehouse", "Warehouse")
.WithMany("Zones")
.HasForeignKey("WarehouseId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.HasOne("Erp.Platform.Entities.ZoneType", "ZoneType")
.WithMany("Zones")
.HasForeignKey("ZoneTypeId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.Navigation("Warehouse");
b.Navigation("ZoneType");
});
modelBuilder.Entity("Erp.Platform.Forum.ForumPost", b => modelBuilder.Entity("Erp.Platform.Forum.ForumPost", b =>
{ {
b.HasOne("Erp.Platform.Forum.ForumPost", "ParentPost") b.HasOne("Erp.Platform.Forum.ForumPost", "ParentPost")
@ -16006,6 +16544,8 @@ namespace Erp.Platform.Migrations
b.Navigation("SurveyResponses"); b.Navigation("SurveyResponses");
b.Navigation("Visitors"); b.Navigation("Visitors");
b.Navigation("Warehouses");
}); });
modelBuilder.Entity("Erp.Platform.Entities.Event", b => modelBuilder.Entity("Erp.Platform.Entities.Event", b =>
@ -16035,6 +16575,11 @@ namespace Erp.Platform.Migrations
b.Navigation("Faults"); b.Navigation("Faults");
}); });
modelBuilder.Entity("Erp.Platform.Entities.LocationType", b =>
{
b.Navigation("Locations");
});
modelBuilder.Entity("Erp.Platform.Entities.LossReason", b => modelBuilder.Entity("Erp.Platform.Entities.LossReason", b =>
{ {
b.Navigation("Opportunities"); b.Navigation("Opportunities");
@ -16234,6 +16779,18 @@ namespace Erp.Platform.Migrations
b.Navigation("Uoms"); b.Navigation("Uoms");
}); });
modelBuilder.Entity("Erp.Platform.Entities.Warehouse", b =>
{
b.Navigation("Locations");
b.Navigation("Zones");
});
modelBuilder.Entity("Erp.Platform.Entities.WarehouseType", b =>
{
b.Navigation("Warehouses");
});
modelBuilder.Entity("Erp.Platform.Entities.Workcenter", b => modelBuilder.Entity("Erp.Platform.Entities.Workcenter", b =>
{ {
b.Navigation("Specifications"); b.Navigation("Specifications");
@ -16249,6 +16806,16 @@ namespace Erp.Platform.Migrations
b.Navigation("Workcenters"); b.Navigation("Workcenters");
}); });
modelBuilder.Entity("Erp.Platform.Entities.Zone", b =>
{
b.Navigation("Locations");
});
modelBuilder.Entity("Erp.Platform.Entities.ZoneType", b =>
{
b.Navigation("Zones");
});
modelBuilder.Entity("Erp.Platform.Forum.ForumCategory", b => modelBuilder.Entity("Erp.Platform.Forum.ForumCategory", b =>
{ {
b.Navigation("Topics"); b.Navigation("Topics");

View file

@ -2569,6 +2569,75 @@ namespace Erp.Platform.Migrations
table.PrimaryKey("PK_Scp_T_SupplyType", x => x.Id); table.PrimaryKey("PK_Scp_T_SupplyType", x => x.Id);
}); });
migrationBuilder.CreateTable(
name: "Str_T_LocationType",
columns: table => new
{
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Code = table.Column<string>(type: "nvarchar(50)", maxLength: 50, nullable: false),
Name = table.Column<string>(type: "nvarchar(50)", maxLength: 50, nullable: false),
Description = table.Column<string>(type: "nvarchar(500)", maxLength: 500, nullable: true),
IsActive = table.Column<bool>(type: "bit", nullable: false, defaultValue: true),
CreationTime = table.Column<DateTime>(type: "datetime2", nullable: false),
CreatorId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
LastModificationTime = table.Column<DateTime>(type: "datetime2", nullable: true),
LastModifierId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
IsDeleted = table.Column<bool>(type: "bit", nullable: false, defaultValue: false),
DeleterId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
DeletionTime = table.Column<DateTime>(type: "datetime2", nullable: true)
},
constraints: table =>
{
table.PrimaryKey("PK_Str_T_LocationType", x => x.Id);
});
migrationBuilder.CreateTable(
name: "Str_T_WarehouseType",
columns: table => new
{
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Code = table.Column<string>(type: "nvarchar(50)", maxLength: 50, nullable: false),
Name = table.Column<string>(type: "nvarchar(50)", maxLength: 50, nullable: false),
Description = table.Column<string>(type: "nvarchar(500)", maxLength: 500, nullable: true),
IsActive = table.Column<bool>(type: "bit", nullable: false, defaultValue: true),
CreationTime = table.Column<DateTime>(type: "datetime2", nullable: false),
CreatorId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
LastModificationTime = table.Column<DateTime>(type: "datetime2", nullable: true),
LastModifierId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
IsDeleted = table.Column<bool>(type: "bit", nullable: false, defaultValue: false),
DeleterId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
DeletionTime = table.Column<DateTime>(type: "datetime2", nullable: true)
},
constraints: table =>
{
table.PrimaryKey("PK_Str_T_WarehouseType", x => x.Id);
});
migrationBuilder.CreateTable(
name: "Str_T_ZoneType",
columns: table => new
{
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Code = table.Column<string>(type: "nvarchar(50)", maxLength: 50, nullable: false),
Name = table.Column<string>(type: "nvarchar(50)", maxLength: 50, nullable: false),
Description = table.Column<string>(type: "nvarchar(500)", maxLength: 500, nullable: true),
IsActive = table.Column<bool>(type: "bit", nullable: false, defaultValue: true),
CreationTime = table.Column<DateTime>(type: "datetime2", nullable: false),
CreatorId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
LastModificationTime = table.Column<DateTime>(type: "datetime2", nullable: true),
LastModifierId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
IsDeleted = table.Column<bool>(type: "bit", nullable: false, defaultValue: false),
DeleterId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
DeletionTime = table.Column<DateTime>(type: "datetime2", nullable: true)
},
constraints: table =>
{
table.PrimaryKey("PK_Str_T_ZoneType", x => x.Id);
});
migrationBuilder.CreateTable( migrationBuilder.CreateTable(
name: "AbpAuditLogActions", name: "AbpAuditLogActions",
columns: table => new columns: table => new
@ -5581,6 +5650,52 @@ namespace Erp.Platform.Migrations
onDelete: ReferentialAction.Cascade); onDelete: ReferentialAction.Cascade);
}); });
migrationBuilder.CreateTable(
name: "Str_T_Warehouse",
columns: table => new
{
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Code = table.Column<string>(type: "nvarchar(50)", maxLength: 50, nullable: false),
Name = table.Column<string>(type: "nvarchar(200)", maxLength: 200, nullable: false),
Description = table.Column<string>(type: "nvarchar(500)", maxLength: 500, nullable: true),
EmployeeId = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
Country = table.Column<string>(type: "nvarchar(100)", maxLength: 100, nullable: true),
City = table.Column<string>(type: "nvarchar(100)", maxLength: 100, nullable: true),
District = table.Column<string>(type: "nvarchar(200)", maxLength: 200, nullable: true),
Township = table.Column<string>(type: "nvarchar(100)", maxLength: 100, nullable: true),
PostalCode = table.Column<string>(type: "nvarchar(20)", maxLength: 20, nullable: true),
WarehouseTypeId = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
IsMainWarehouse = table.Column<bool>(type: "bit", nullable: false, defaultValue: false),
Capacity = table.Column<int>(type: "int", nullable: false, defaultValue: 0),
IsActive = table.Column<bool>(type: "bit", nullable: false, defaultValue: true),
TemperatureControlled = table.Column<bool>(type: "bit", nullable: false, defaultValue: false),
SecurityLevel = table.Column<int>(type: "int", nullable: false, defaultValue: 1),
CreationTime = table.Column<DateTime>(type: "datetime2", nullable: false),
CreatorId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
LastModificationTime = table.Column<DateTime>(type: "datetime2", nullable: true),
LastModifierId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
IsDeleted = table.Column<bool>(type: "bit", nullable: false, defaultValue: false),
DeleterId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
DeletionTime = table.Column<DateTime>(type: "datetime2", nullable: true)
},
constraints: table =>
{
table.PrimaryKey("PK_Str_T_Warehouse", x => x.Id);
table.ForeignKey(
name: "FK_Str_T_Warehouse_Hr_T_Employee_EmployeeId",
column: x => x.EmployeeId,
principalTable: "Hr_T_Employee",
principalColumn: "Id",
onDelete: ReferentialAction.Restrict);
table.ForeignKey(
name: "FK_Str_T_Warehouse_Str_T_WarehouseType_WarehouseTypeId",
column: x => x.WarehouseTypeId,
principalTable: "Str_T_WarehouseType",
principalColumn: "Id",
onDelete: ReferentialAction.Restrict);
});
migrationBuilder.CreateTable( migrationBuilder.CreateTable(
name: "Mnt_T_PlanEmployee", name: "Mnt_T_PlanEmployee",
columns: table => new columns: table => new
@ -5962,6 +6077,45 @@ namespace Erp.Platform.Migrations
onDelete: ReferentialAction.Cascade); onDelete: ReferentialAction.Cascade);
}); });
migrationBuilder.CreateTable(
name: "Str_T_Zone",
columns: table => new
{
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
WarehouseId = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
Code = table.Column<string>(type: "nvarchar(50)", maxLength: 50, nullable: false),
Name = table.Column<string>(type: "nvarchar(50)", maxLength: 50, nullable: false),
Description = table.Column<string>(type: "nvarchar(500)", maxLength: 500, nullable: true),
ZoneTypeId = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
Temperature = table.Column<int>(type: "int", nullable: true, defaultValue: 0),
Humidity = table.Column<int>(type: "int", nullable: true, defaultValue: 0),
IsActive = table.Column<bool>(type: "bit", nullable: false, defaultValue: true),
CreationTime = table.Column<DateTime>(type: "datetime2", nullable: false),
CreatorId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
LastModificationTime = table.Column<DateTime>(type: "datetime2", nullable: true),
LastModifierId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
IsDeleted = table.Column<bool>(type: "bit", nullable: false, defaultValue: false),
DeleterId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
DeletionTime = table.Column<DateTime>(type: "datetime2", nullable: true)
},
constraints: table =>
{
table.PrimaryKey("PK_Str_T_Zone", x => x.Id);
table.ForeignKey(
name: "FK_Str_T_Zone_Str_T_Warehouse_WarehouseId",
column: x => x.WarehouseId,
principalTable: "Str_T_Warehouse",
principalColumn: "Id",
onDelete: ReferentialAction.Restrict);
table.ForeignKey(
name: "FK_Str_T_Zone_Str_T_ZoneType_ZoneTypeId",
column: x => x.ZoneTypeId,
principalTable: "Str_T_ZoneType",
principalColumn: "Id",
onDelete: ReferentialAction.Restrict);
});
migrationBuilder.CreateTable( migrationBuilder.CreateTable(
name: "MaintenanceWorkorderActivity", name: "MaintenanceWorkorderActivity",
columns: table => new columns: table => new
@ -6059,6 +6213,52 @@ namespace Erp.Platform.Migrations
onDelete: ReferentialAction.Cascade); onDelete: ReferentialAction.Cascade);
}); });
migrationBuilder.CreateTable(
name: "Str_T_Location",
columns: table => new
{
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
WarehouseId = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
ZoneId = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
Code = table.Column<string>(type: "nvarchar(50)", maxLength: 50, nullable: false),
Name = table.Column<string>(type: "nvarchar(50)", maxLength: 50, nullable: false),
Description = table.Column<string>(type: "nvarchar(500)", maxLength: 500, nullable: true),
LocationTypeId = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
Capacity = table.Column<int>(type: "int", nullable: false, defaultValue: 0),
CurrentStock = table.Column<int>(type: "int", nullable: false, defaultValue: 0),
IsActive = table.Column<bool>(type: "bit", nullable: false, defaultValue: true),
CreationTime = table.Column<DateTime>(type: "datetime2", nullable: false),
CreatorId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
LastModificationTime = table.Column<DateTime>(type: "datetime2", nullable: true),
LastModifierId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
IsDeleted = table.Column<bool>(type: "bit", nullable: false, defaultValue: false),
DeleterId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
DeletionTime = table.Column<DateTime>(type: "datetime2", nullable: true)
},
constraints: table =>
{
table.PrimaryKey("PK_Str_T_Location", x => x.Id);
table.ForeignKey(
name: "FK_Str_T_Location_Str_T_LocationType_LocationTypeId",
column: x => x.LocationTypeId,
principalTable: "Str_T_LocationType",
principalColumn: "Id",
onDelete: ReferentialAction.Restrict);
table.ForeignKey(
name: "FK_Str_T_Location_Str_T_Warehouse_WarehouseId",
column: x => x.WarehouseId,
principalTable: "Str_T_Warehouse",
principalColumn: "Id",
onDelete: ReferentialAction.Restrict);
table.ForeignKey(
name: "FK_Str_T_Location_Str_T_Zone_ZoneId",
column: x => x.ZoneId,
principalTable: "Str_T_Zone",
principalColumn: "Id",
onDelete: ReferentialAction.Restrict);
});
migrationBuilder.CreateIndex( migrationBuilder.CreateIndex(
name: "IX_AbpAuditLogActions_AuditLogId", name: "IX_AbpAuditLogActions_AuditLogId",
table: "AbpAuditLogActions", table: "AbpAuditLogActions",
@ -7115,6 +7315,41 @@ namespace Erp.Platform.Migrations
table: "Scp_T_RequestItem", table: "Scp_T_RequestItem",
column: "UomId"); column: "UomId");
migrationBuilder.CreateIndex(
name: "IX_Str_T_Location_LocationTypeId",
table: "Str_T_Location",
column: "LocationTypeId");
migrationBuilder.CreateIndex(
name: "IX_Str_T_Location_WarehouseId",
table: "Str_T_Location",
column: "WarehouseId");
migrationBuilder.CreateIndex(
name: "IX_Str_T_Location_ZoneId",
table: "Str_T_Location",
column: "ZoneId");
migrationBuilder.CreateIndex(
name: "IX_Str_T_Warehouse_EmployeeId",
table: "Str_T_Warehouse",
column: "EmployeeId");
migrationBuilder.CreateIndex(
name: "IX_Str_T_Warehouse_WarehouseTypeId",
table: "Str_T_Warehouse",
column: "WarehouseTypeId");
migrationBuilder.CreateIndex(
name: "IX_Str_T_Zone_WarehouseId",
table: "Str_T_Zone",
column: "WarehouseId");
migrationBuilder.CreateIndex(
name: "IX_Str_T_Zone_ZoneTypeId",
table: "Str_T_Zone",
column: "ZoneTypeId");
migrationBuilder.CreateIndex( migrationBuilder.CreateIndex(
name: "IX_Workorders_MaintenanceWorkorderStatusId", name: "IX_Workorders_MaintenanceWorkorderStatusId",
table: "Workorders", table: "Workorders",
@ -7612,6 +7847,9 @@ namespace Erp.Platform.Migrations
migrationBuilder.DropTable( migrationBuilder.DropTable(
name: "Scp_T_RequestItem"); name: "Scp_T_RequestItem");
migrationBuilder.DropTable(
name: "Str_T_Location");
migrationBuilder.DropTable( migrationBuilder.DropTable(
name: "AbpEntityChanges"); name: "AbpEntityChanges");
@ -7720,6 +7958,12 @@ namespace Erp.Platform.Migrations
migrationBuilder.DropTable( migrationBuilder.DropTable(
name: "Scp_T_Request"); name: "Scp_T_Request");
migrationBuilder.DropTable(
name: "Str_T_LocationType");
migrationBuilder.DropTable(
name: "Str_T_Zone");
migrationBuilder.DropTable( migrationBuilder.DropTable(
name: "AbpAuditLogs"); name: "AbpAuditLogs");
@ -7795,6 +8039,12 @@ namespace Erp.Platform.Migrations
migrationBuilder.DropTable( migrationBuilder.DropTable(
name: "Scp_T_RequestType"); name: "Scp_T_RequestType");
migrationBuilder.DropTable(
name: "Str_T_Warehouse");
migrationBuilder.DropTable(
name: "Str_T_ZoneType");
migrationBuilder.DropTable( migrationBuilder.DropTable(
name: "Sas_T_Branch"); name: "Sas_T_Branch");
@ -7804,6 +8054,9 @@ namespace Erp.Platform.Migrations
migrationBuilder.DropTable( migrationBuilder.DropTable(
name: "Sas_H_CountryGroup"); name: "Sas_H_CountryGroup");
migrationBuilder.DropTable(
name: "Str_T_WarehouseType");
migrationBuilder.DropTable( migrationBuilder.DropTable(
name: "Mnt_T_WorkcenterStatus"); name: "Mnt_T_WorkcenterStatus");

View file

@ -6072,6 +6072,157 @@ namespace Erp.Platform.Migrations
b.ToTable("Sas_H_ListFormImportExecute", (string)null); b.ToTable("Sas_H_ListFormImportExecute", (string)null);
}); });
modelBuilder.Entity("Erp.Platform.Entities.Location", b =>
{
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<int>("Capacity")
.ValueGeneratedOnAdd()
.HasColumnType("int")
.HasDefaultValue(0);
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(50)
.HasColumnType("nvarchar(50)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
b.Property<Guid?>("CreatorId")
.HasColumnType("uniqueidentifier")
.HasColumnName("CreatorId");
b.Property<int>("CurrentStock")
.ValueGeneratedOnAdd()
.HasColumnType("int")
.HasDefaultValue(0);
b.Property<Guid?>("DeleterId")
.HasColumnType("uniqueidentifier")
.HasColumnName("DeleterId");
b.Property<DateTime?>("DeletionTime")
.HasColumnType("datetime2")
.HasColumnName("DeletionTime");
b.Property<string>("Description")
.HasMaxLength(500)
.HasColumnType("nvarchar(500)");
b.Property<bool>("IsActive")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(true);
b.Property<bool>("IsDeleted")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(false)
.HasColumnName("IsDeleted");
b.Property<DateTime?>("LastModificationTime")
.HasColumnType("datetime2")
.HasColumnName("LastModificationTime");
b.Property<Guid?>("LastModifierId")
.HasColumnType("uniqueidentifier")
.HasColumnName("LastModifierId");
b.Property<Guid>("LocationTypeId")
.HasColumnType("uniqueidentifier");
b.Property<string>("Name")
.IsRequired()
.HasMaxLength(50)
.HasColumnType("nvarchar(50)");
b.Property<Guid?>("TenantId")
.HasColumnType("uniqueidentifier")
.HasColumnName("TenantId");
b.Property<Guid>("WarehouseId")
.HasColumnType("uniqueidentifier");
b.Property<Guid>("ZoneId")
.HasColumnType("uniqueidentifier");
b.HasKey("Id");
b.HasIndex("LocationTypeId");
b.HasIndex("WarehouseId");
b.HasIndex("ZoneId");
b.ToTable("Str_T_Location", (string)null);
});
modelBuilder.Entity("Erp.Platform.Entities.LocationType", b =>
{
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(50)
.HasColumnType("nvarchar(50)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
b.Property<Guid?>("CreatorId")
.HasColumnType("uniqueidentifier")
.HasColumnName("CreatorId");
b.Property<Guid?>("DeleterId")
.HasColumnType("uniqueidentifier")
.HasColumnName("DeleterId");
b.Property<DateTime?>("DeletionTime")
.HasColumnType("datetime2")
.HasColumnName("DeletionTime");
b.Property<string>("Description")
.HasMaxLength(500)
.HasColumnType("nvarchar(500)");
b.Property<bool>("IsActive")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(true);
b.Property<bool>("IsDeleted")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(false)
.HasColumnName("IsDeleted");
b.Property<DateTime?>("LastModificationTime")
.HasColumnType("datetime2")
.HasColumnName("LastModificationTime");
b.Property<Guid?>("LastModifierId")
.HasColumnType("uniqueidentifier")
.HasColumnName("LastModifierId");
b.Property<string>("Name")
.IsRequired()
.HasMaxLength(50)
.HasColumnType("nvarchar(50)");
b.Property<Guid?>("TenantId")
.HasColumnType("uniqueidentifier")
.HasColumnName("TenantId");
b.HasKey("Id");
b.ToTable("Str_T_LocationType", (string)null);
});
modelBuilder.Entity("Erp.Platform.Entities.LogEntry", b => modelBuilder.Entity("Erp.Platform.Entities.LogEntry", b =>
{ {
b.Property<Guid>("Id") b.Property<Guid>("Id")
@ -11866,6 +12017,182 @@ namespace Erp.Platform.Migrations
b.ToTable("Net_T_Visitor", (string)null); b.ToTable("Net_T_Visitor", (string)null);
}); });
modelBuilder.Entity("Erp.Platform.Entities.Warehouse", b =>
{
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<int>("Capacity")
.ValueGeneratedOnAdd()
.HasColumnType("int")
.HasDefaultValue(0);
b.Property<string>("City")
.HasMaxLength(100)
.HasColumnType("nvarchar(100)");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(50)
.HasColumnType("nvarchar(50)");
b.Property<string>("Country")
.HasMaxLength(100)
.HasColumnType("nvarchar(100)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
b.Property<Guid?>("CreatorId")
.HasColumnType("uniqueidentifier")
.HasColumnName("CreatorId");
b.Property<Guid?>("DeleterId")
.HasColumnType("uniqueidentifier")
.HasColumnName("DeleterId");
b.Property<DateTime?>("DeletionTime")
.HasColumnType("datetime2")
.HasColumnName("DeletionTime");
b.Property<string>("Description")
.HasMaxLength(500)
.HasColumnType("nvarchar(500)");
b.Property<string>("District")
.HasMaxLength(200)
.HasColumnType("nvarchar(200)");
b.Property<Guid>("EmployeeId")
.HasColumnType("uniqueidentifier");
b.Property<bool>("IsActive")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(true);
b.Property<bool>("IsDeleted")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(false)
.HasColumnName("IsDeleted");
b.Property<bool>("IsMainWarehouse")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(false);
b.Property<DateTime?>("LastModificationTime")
.HasColumnType("datetime2")
.HasColumnName("LastModificationTime");
b.Property<Guid?>("LastModifierId")
.HasColumnType("uniqueidentifier")
.HasColumnName("LastModifierId");
b.Property<string>("Name")
.IsRequired()
.HasMaxLength(200)
.HasColumnType("nvarchar(200)");
b.Property<string>("PostalCode")
.HasMaxLength(20)
.HasColumnType("nvarchar(20)");
b.Property<int>("SecurityLevel")
.ValueGeneratedOnAdd()
.HasColumnType("int")
.HasDefaultValue(1);
b.Property<bool>("TemperatureControlled")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(false);
b.Property<Guid?>("TenantId")
.HasColumnType("uniqueidentifier")
.HasColumnName("TenantId");
b.Property<string>("Township")
.HasMaxLength(100)
.HasColumnType("nvarchar(100)");
b.Property<Guid>("WarehouseTypeId")
.HasColumnType("uniqueidentifier");
b.HasKey("Id");
b.HasIndex("EmployeeId");
b.HasIndex("WarehouseTypeId");
b.ToTable("Str_T_Warehouse", (string)null);
});
modelBuilder.Entity("Erp.Platform.Entities.WarehouseType", b =>
{
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(50)
.HasColumnType("nvarchar(50)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
b.Property<Guid?>("CreatorId")
.HasColumnType("uniqueidentifier")
.HasColumnName("CreatorId");
b.Property<Guid?>("DeleterId")
.HasColumnType("uniqueidentifier")
.HasColumnName("DeleterId");
b.Property<DateTime?>("DeletionTime")
.HasColumnType("datetime2")
.HasColumnName("DeletionTime");
b.Property<string>("Description")
.HasMaxLength(500)
.HasColumnType("nvarchar(500)");
b.Property<bool>("IsActive")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(true);
b.Property<bool>("IsDeleted")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(false)
.HasColumnName("IsDeleted");
b.Property<DateTime?>("LastModificationTime")
.HasColumnType("datetime2")
.HasColumnName("LastModificationTime");
b.Property<Guid?>("LastModifierId")
.HasColumnType("uniqueidentifier")
.HasColumnName("LastModifierId");
b.Property<string>("Name")
.IsRequired()
.HasMaxLength(50)
.HasColumnType("nvarchar(50)");
b.Property<Guid?>("TenantId")
.HasColumnType("uniqueidentifier")
.HasColumnName("TenantId");
b.HasKey("Id");
b.ToTable("Str_T_WarehouseType", (string)null);
});
modelBuilder.Entity("Erp.Platform.Entities.WorkHour", b => modelBuilder.Entity("Erp.Platform.Entities.WorkHour", b =>
{ {
b.Property<Guid>("Id") b.Property<Guid>("Id")
@ -12254,6 +12581,152 @@ namespace Erp.Platform.Migrations
b.ToTable("Mnt_T_WorkcenterType", (string)null); b.ToTable("Mnt_T_WorkcenterType", (string)null);
}); });
modelBuilder.Entity("Erp.Platform.Entities.Zone", b =>
{
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(50)
.HasColumnType("nvarchar(50)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
b.Property<Guid?>("CreatorId")
.HasColumnType("uniqueidentifier")
.HasColumnName("CreatorId");
b.Property<Guid?>("DeleterId")
.HasColumnType("uniqueidentifier")
.HasColumnName("DeleterId");
b.Property<DateTime?>("DeletionTime")
.HasColumnType("datetime2")
.HasColumnName("DeletionTime");
b.Property<string>("Description")
.HasMaxLength(500)
.HasColumnType("nvarchar(500)");
b.Property<int?>("Humidity")
.ValueGeneratedOnAdd()
.HasColumnType("int")
.HasDefaultValue(0);
b.Property<bool>("IsActive")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(true);
b.Property<bool>("IsDeleted")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(false)
.HasColumnName("IsDeleted");
b.Property<DateTime?>("LastModificationTime")
.HasColumnType("datetime2")
.HasColumnName("LastModificationTime");
b.Property<Guid?>("LastModifierId")
.HasColumnType("uniqueidentifier")
.HasColumnName("LastModifierId");
b.Property<string>("Name")
.IsRequired()
.HasMaxLength(50)
.HasColumnType("nvarchar(50)");
b.Property<int?>("Temperature")
.ValueGeneratedOnAdd()
.HasColumnType("int")
.HasDefaultValue(0);
b.Property<Guid?>("TenantId")
.HasColumnType("uniqueidentifier")
.HasColumnName("TenantId");
b.Property<Guid>("WarehouseId")
.HasColumnType("uniqueidentifier");
b.Property<Guid>("ZoneTypeId")
.HasColumnType("uniqueidentifier");
b.HasKey("Id");
b.HasIndex("WarehouseId");
b.HasIndex("ZoneTypeId");
b.ToTable("Str_T_Zone", (string)null);
});
modelBuilder.Entity("Erp.Platform.Entities.ZoneType", b =>
{
b.Property<Guid>("Id")
.HasColumnType("uniqueidentifier");
b.Property<string>("Code")
.IsRequired()
.HasMaxLength(50)
.HasColumnType("nvarchar(50)");
b.Property<DateTime>("CreationTime")
.HasColumnType("datetime2")
.HasColumnName("CreationTime");
b.Property<Guid?>("CreatorId")
.HasColumnType("uniqueidentifier")
.HasColumnName("CreatorId");
b.Property<Guid?>("DeleterId")
.HasColumnType("uniqueidentifier")
.HasColumnName("DeleterId");
b.Property<DateTime?>("DeletionTime")
.HasColumnType("datetime2")
.HasColumnName("DeletionTime");
b.Property<string>("Description")
.HasMaxLength(500)
.HasColumnType("nvarchar(500)");
b.Property<bool>("IsActive")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(true);
b.Property<bool>("IsDeleted")
.ValueGeneratedOnAdd()
.HasColumnType("bit")
.HasDefaultValue(false)
.HasColumnName("IsDeleted");
b.Property<DateTime?>("LastModificationTime")
.HasColumnType("datetime2")
.HasColumnName("LastModificationTime");
b.Property<Guid?>("LastModifierId")
.HasColumnType("uniqueidentifier")
.HasColumnName("LastModifierId");
b.Property<string>("Name")
.IsRequired()
.HasMaxLength(50)
.HasColumnType("nvarchar(50)");
b.Property<Guid?>("TenantId")
.HasColumnType("uniqueidentifier")
.HasColumnName("TenantId");
b.HasKey("Id");
b.ToTable("Str_T_ZoneType", (string)null);
});
modelBuilder.Entity("Erp.Platform.Forum.ForumCategory", b => modelBuilder.Entity("Erp.Platform.Forum.ForumCategory", b =>
{ {
b.Property<Guid>("Id") b.Property<Guid>("Id")
@ -14994,6 +15467,33 @@ namespace Erp.Platform.Migrations
.IsRequired(); .IsRequired();
}); });
modelBuilder.Entity("Erp.Platform.Entities.Location", b =>
{
b.HasOne("Erp.Platform.Entities.LocationType", "LocationType")
.WithMany("Locations")
.HasForeignKey("LocationTypeId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.HasOne("Erp.Platform.Entities.Warehouse", "Warehouse")
.WithMany("Locations")
.HasForeignKey("WarehouseId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.HasOne("Erp.Platform.Entities.Zone", "Zone")
.WithMany("Locations")
.HasForeignKey("ZoneId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.Navigation("LocationType");
b.Navigation("Warehouse");
b.Navigation("Zone");
});
modelBuilder.Entity("Erp.Platform.Entities.MaintenancePlan", b => modelBuilder.Entity("Erp.Platform.Entities.MaintenancePlan", b =>
{ {
b.HasOne("Erp.Platform.Entities.Workcenter", "WorkCenter") b.HasOne("Erp.Platform.Entities.Workcenter", "WorkCenter")
@ -15663,6 +16163,25 @@ namespace Erp.Platform.Migrations
b.Navigation("Employee"); b.Navigation("Employee");
}); });
modelBuilder.Entity("Erp.Platform.Entities.Warehouse", b =>
{
b.HasOne("Erp.Platform.Entities.Employee", "Employee")
.WithMany("Warehouses")
.HasForeignKey("EmployeeId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.HasOne("Erp.Platform.Entities.WarehouseType", "WarehouseType")
.WithMany("Warehouses")
.HasForeignKey("WarehouseTypeId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.Navigation("Employee");
b.Navigation("WarehouseType");
});
modelBuilder.Entity("Erp.Platform.Entities.Workcenter", b => modelBuilder.Entity("Erp.Platform.Entities.Workcenter", b =>
{ {
b.HasOne("Erp.Platform.Entities.Department", "Department") b.HasOne("Erp.Platform.Entities.Department", "Department")
@ -15705,6 +16224,25 @@ namespace Erp.Platform.Migrations
b.Navigation("Workcenter"); b.Navigation("Workcenter");
}); });
modelBuilder.Entity("Erp.Platform.Entities.Zone", b =>
{
b.HasOne("Erp.Platform.Entities.Warehouse", "Warehouse")
.WithMany("Zones")
.HasForeignKey("WarehouseId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.HasOne("Erp.Platform.Entities.ZoneType", "ZoneType")
.WithMany("Zones")
.HasForeignKey("ZoneTypeId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.Navigation("Warehouse");
b.Navigation("ZoneType");
});
modelBuilder.Entity("Erp.Platform.Forum.ForumPost", b => modelBuilder.Entity("Erp.Platform.Forum.ForumPost", b =>
{ {
b.HasOne("Erp.Platform.Forum.ForumPost", "ParentPost") b.HasOne("Erp.Platform.Forum.ForumPost", "ParentPost")
@ -16003,6 +16541,8 @@ namespace Erp.Platform.Migrations
b.Navigation("SurveyResponses"); b.Navigation("SurveyResponses");
b.Navigation("Visitors"); b.Navigation("Visitors");
b.Navigation("Warehouses");
}); });
modelBuilder.Entity("Erp.Platform.Entities.Event", b => modelBuilder.Entity("Erp.Platform.Entities.Event", b =>
@ -16032,6 +16572,11 @@ namespace Erp.Platform.Migrations
b.Navigation("Faults"); b.Navigation("Faults");
}); });
modelBuilder.Entity("Erp.Platform.Entities.LocationType", b =>
{
b.Navigation("Locations");
});
modelBuilder.Entity("Erp.Platform.Entities.LossReason", b => modelBuilder.Entity("Erp.Platform.Entities.LossReason", b =>
{ {
b.Navigation("Opportunities"); b.Navigation("Opportunities");
@ -16231,6 +16776,18 @@ namespace Erp.Platform.Migrations
b.Navigation("Uoms"); b.Navigation("Uoms");
}); });
modelBuilder.Entity("Erp.Platform.Entities.Warehouse", b =>
{
b.Navigation("Locations");
b.Navigation("Zones");
});
modelBuilder.Entity("Erp.Platform.Entities.WarehouseType", b =>
{
b.Navigation("Warehouses");
});
modelBuilder.Entity("Erp.Platform.Entities.Workcenter", b => modelBuilder.Entity("Erp.Platform.Entities.Workcenter", b =>
{ {
b.Navigation("Specifications"); b.Navigation("Specifications");
@ -16246,6 +16803,16 @@ namespace Erp.Platform.Migrations
b.Navigation("Workcenters"); b.Navigation("Workcenters");
}); });
modelBuilder.Entity("Erp.Platform.Entities.Zone", b =>
{
b.Navigation("Locations");
});
modelBuilder.Entity("Erp.Platform.Entities.ZoneType", b =>
{
b.Navigation("Zones");
});
modelBuilder.Entity("Erp.Platform.Forum.ForumCategory", b => modelBuilder.Entity("Erp.Platform.Forum.ForumCategory", b =>
{ {
b.Navigation("Topics"); b.Navigation("Topics");

View file

@ -5208,5 +5208,113 @@
"description": "İş emri iptal edildi ve işlem sona erdi", "description": "İş emri iptal edildi ve işlem sona erdi",
"isActive": true "isActive": true
} }
],
"WarehouseTypes": [
{
"code": "RawMaterials",
"name": "Hammaddeler",
"description": "Üretim için kullanılan temel malzemelerin depolandığı alan",
"isActive": true
},
{
"code": "FinishedGoods",
"name": "Mamuller",
"description": "Bitmiş ürünlerin depolandığı alan",
"isActive": true
},
{
"code": "WorkInProgress",
"name": "İşlenmekte olan ürünler",
"description": "Üretim sürecinde olan ürünlerin depolandığı alan",
"isActive": true
},
{
"code": "SpareParts",
"name": "Yedek Parçalar",
"description": "Makine ve ekipman yedek parçalarının depolandığı alan",
"isActive": true
},
{
"code": "Returns",
"name": "İadeler",
"description": "Müşterilerden geri gelen ürünlerin depolandığı alan",
"isActive": true
},
{
"code": "Quarantine",
"name": "Karantina",
"description": "Kalite kontrolü bekleyen ürünlerin depolandığı alan",
"isActive": true
},
{
"code": "Transit",
"name": "Geçici Depo",
"description": "Kısa süreli depolama için kullanılan alan",
"isActive": true
}
],
"ZoneTypes": [
{
"code": "Receiving",
"name": "Alım Bölgesi",
"description": "Malzemelerin teslim alındığı ve ilk kontrollerin yapıldığı alan",
"isActive": true
},
{
"code": "Storage",
"name": "Depolama Bölgesi",
"description": "Malzemelerin düzenli olarak saklandığı alan",
"isActive": true
},
{
"code": "Picking",
"name": "Sevkiyat Bölgesi",
"description": "Siparişlerin hazırlanıp sevk edildiği alan",
"isActive": true
},
{
"code": "QualityControl",
"name": "Kalite Kontrol Bölgesi",
"description": "Malzemelerin kalite kontrolünden geçtiği alan",
"isActive": true
},
{
"code": "Packing",
"name": "Paketleme Bölgesi",
"description": "Ürünlerin paketlendiği ve sevkiyata hazırlandığı alan",
"isActive": true
}
],
"LocationTypes": [
{
"code": "Raf",
"name": "Raf",
"description": "Malzemelerin yerleştirildiği raf sistemleri",
"isActive": true
},
{
"code": "Kutu",
"name": "Kutu",
"description": "Malzemelerin saklandığı kutular",
"isActive": true
},
{
"code": "Zemin",
"name": "Zemin",
"description": "Büyük ve ağır malzemelerin yerleştirildiği zemin alanları",
"isActive": true
},
{
"code": "Palet",
"name": "Palet",
"description": "Paletlerin düzenli olarak saklandığı raf sistemleri",
"isActive": true
},
{
"code": "Tank",
"name": "Tank",
"description": "Sıvı malzemelerin depolandığı tanklar",
"isActive": true
}
] ]
} }

View file

@ -115,6 +115,9 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
private readonly IRepository<FaultType, Guid> _faultTypeRepository; private readonly IRepository<FaultType, Guid> _faultTypeRepository;
private readonly IRepository<MaintenanceWorkorderType, Guid> _workorderTypeRepository; private readonly IRepository<MaintenanceWorkorderType, Guid> _workorderTypeRepository;
private readonly IRepository<MaintenanceWorkorderStatus, Guid> _workorderStatusRepository; private readonly IRepository<MaintenanceWorkorderStatus, Guid> _workorderStatusRepository;
private readonly IRepository<WarehouseType, Guid> _warehouseTypeRepository;
private readonly IRepository<ZoneType, Guid> _zoneTypeRepository;
private readonly IRepository<LocationType, Guid> _locationTypeRepository;
public TenantDataSeeder( public TenantDataSeeder(
IClock clock, IClock clock,
@ -212,7 +215,10 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
IRepository<FaultStatus, Guid> faultStatusRepository, IRepository<FaultStatus, Guid> faultStatusRepository,
IRepository<FaultType, Guid> faultTypeRepository, IRepository<FaultType, Guid> faultTypeRepository,
IRepository<MaintenanceWorkorderType, Guid> workorderTypeRepository, IRepository<MaintenanceWorkorderType, Guid> workorderTypeRepository,
IRepository<MaintenanceWorkorderStatus, Guid> workorderStatusRepository IRepository<MaintenanceWorkorderStatus, Guid> workorderStatusRepository,
IRepository<WarehouseType, Guid> warehouseTypeRepository,
IRepository<ZoneType, Guid> zoneTypeRepository,
IRepository<LocationType, Guid> locationTypeRepository
) )
{ {
_clock = clock; _clock = clock;
@ -312,6 +318,9 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
_faultTypeRepository = faultTypeRepository; _faultTypeRepository = faultTypeRepository;
_workorderTypeRepository = workorderTypeRepository; _workorderTypeRepository = workorderTypeRepository;
_workorderStatusRepository = workorderStatusRepository; _workorderStatusRepository = workorderStatusRepository;
_warehouseTypeRepository = warehouseTypeRepository;
_zoneTypeRepository = zoneTypeRepository;
_locationTypeRepository = locationTypeRepository;
} }
private static IConfigurationRoot BuildConfiguration() private static IConfigurationRoot BuildConfiguration()
@ -2102,6 +2111,51 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
IsActive = item.IsActive IsActive = item.IsActive
}, autoSave: true); }, autoSave: true);
} }
foreach (var item in items.WarehouseTypes)
{
var exists = await _warehouseTypeRepository.AnyAsync(x => x.Code == item.Code);
if (exists)
continue;
await _warehouseTypeRepository.InsertAsync(new WarehouseType
{
Code = item.Code,
Name = item.Name,
Description = item.Description,
IsActive = item.IsActive
}, autoSave: true);
}
foreach (var item in items.ZoneTypes)
{
var exists = await _zoneTypeRepository.AnyAsync(x => x.Code == item.Code);
if (exists)
continue;
await _zoneTypeRepository.InsertAsync(new ZoneType
{
Code = item.Code,
Name = item.Name,
Description = item.Description,
IsActive = item.IsActive
}, autoSave: true);
}
foreach (var item in items.LocationTypes)
{
var exists = await _locationTypeRepository.AnyAsync(x => x.Code == item.Code);
if (exists)
continue;
await _locationTypeRepository.InsertAsync(new LocationType
{
Code = item.Code,
Name = item.Name,
Description = item.Description,
IsActive = item.IsActive
}, autoSave: true);
}
} }
} }

View file

@ -107,6 +107,38 @@ public class TenantSeederDto
public List<FaultTypeSeedDto> FaultTypes { get; set; } public List<FaultTypeSeedDto> FaultTypes { get; set; }
public List<WorkorderTypeSeedDto> WorkorderTypes { get; set; } public List<WorkorderTypeSeedDto> WorkorderTypes { get; set; }
public List<WorkorderStatusSeedDto> WorkorderStatuses { get; set; } public List<WorkorderStatusSeedDto> WorkorderStatuses { get; set; }
//Store
public List<WarehouseTypeSeedDto> WarehouseTypes { get; set; }
// public List<WarehouseSeedDto> Warehouses { get; set; }
public List<ZoneTypeSeedDto> ZoneTypes { get; set; }
// public List<ZoneSeedDto> Zones { get; set; }
public List<LocationTypeSeedDto> LocationTypes { get; set; }
// public List<LocationSeedDto> Locations { get; set; }
}
public class WarehouseTypeSeedDto
{
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public bool IsActive { get; set; }
}
public class ZoneTypeSeedDto
{
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public bool IsActive { get; set; }
}
public class LocationTypeSeedDto
{
public string Code { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public bool IsActive { get; set; }
} }
public class WorkorderTypeSeedDto public class WorkorderTypeSeedDto