Hr Visitors
This commit is contained in:
parent
850e81862b
commit
fa5ed66ae2
17 changed files with 1326 additions and 267 deletions
|
|
@ -7839,6 +7839,12 @@
|
||||||
"tr": "Duyurular",
|
"tr": "Duyurular",
|
||||||
"en": "Announcements"
|
"en": "Announcements"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"resourceName": "Platform",
|
||||||
|
"key": "App.Hr.Visitor",
|
||||||
|
"tr": "Ziyaretçiler",
|
||||||
|
"en": "Visitors"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"resourceName": "Platform",
|
"resourceName": "Platform",
|
||||||
"key": "App.Definitions.Information",
|
"key": "App.Definitions.Information",
|
||||||
|
|
@ -15395,6 +15401,16 @@
|
||||||
"RequiredPermissionName": "App.Hr.Announcement",
|
"RequiredPermissionName": "App.Hr.Announcement",
|
||||||
"IsDisabled": false
|
"IsDisabled": false
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"ParentCode": "App.Hr",
|
||||||
|
"Code": "App.Hr.Visitor",
|
||||||
|
"DisplayName": "App.Hr.Visitor",
|
||||||
|
"Order": 18,
|
||||||
|
"Url": "/admin/list/list-visitor",
|
||||||
|
"Icon": "FcContacts",
|
||||||
|
"RequiredPermissionName": "App.Hr.Visitor",
|
||||||
|
"IsDisabled": false
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"ParentCode": null,
|
"ParentCode": null,
|
||||||
"Code": "App.Mrp",
|
"Code": "App.Mrp",
|
||||||
|
|
@ -25342,6 +25358,70 @@
|
||||||
"MultiTenancySide": 3,
|
"MultiTenancySide": 3,
|
||||||
"MenuGroup": "Kurs"
|
"MenuGroup": "Kurs"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"GroupName": "App.Hr",
|
||||||
|
"Name": "App.Hr.Visitor",
|
||||||
|
"ParentName": null,
|
||||||
|
"DisplayName": "App.Hr.Visitor",
|
||||||
|
"IsEnabled": true,
|
||||||
|
"MultiTenancySide": 3,
|
||||||
|
"MenuGroup": "Kurs"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"GroupName": "App.Hr",
|
||||||
|
"Name": "App.Hr.Visitor.Create",
|
||||||
|
"ParentName": "App.Hr.Visitor",
|
||||||
|
"DisplayName": "Create",
|
||||||
|
"IsEnabled": true,
|
||||||
|
"MultiTenancySide": 3,
|
||||||
|
"MenuGroup": "Kurs"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"GroupName": "App.Hr",
|
||||||
|
"Name": "App.Hr.Visitor.Update",
|
||||||
|
"ParentName": "App.Hr.Visitor",
|
||||||
|
"DisplayName": "Update",
|
||||||
|
"IsEnabled": true,
|
||||||
|
"MultiTenancySide": 3,
|
||||||
|
"MenuGroup": "Kurs"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"GroupName": "App.Hr",
|
||||||
|
"Name": "App.Hr.Visitor.Delete",
|
||||||
|
"ParentName": "App.Hr.Visitor",
|
||||||
|
"DisplayName": "Delete",
|
||||||
|
"IsEnabled": true,
|
||||||
|
"MultiTenancySide": 3,
|
||||||
|
"MenuGroup": "Kurs"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"GroupName": "App.Hr",
|
||||||
|
"Name": "App.Hr.Visitor.Export",
|
||||||
|
"ParentName": "App.Hr.Visitor",
|
||||||
|
"DisplayName": "Export",
|
||||||
|
"IsEnabled": true,
|
||||||
|
"MultiTenancySide": 3,
|
||||||
|
"MenuGroup": "Kurs"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"GroupName": "App.Hr",
|
||||||
|
"Name": "App.Hr.Visitor.Import",
|
||||||
|
"ParentName": "App.Hr.Visitor",
|
||||||
|
"DisplayName": "Import",
|
||||||
|
"IsEnabled": true,
|
||||||
|
"MultiTenancySide": 3,
|
||||||
|
"MenuGroup": "Kurs"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"GroupName": "App.Hr",
|
||||||
|
"Name": "App.Hr.Visitor.Activity",
|
||||||
|
"ParentName": "App.Hr.Visitor",
|
||||||
|
"DisplayName": "Activity",
|
||||||
|
"IsEnabled": true,
|
||||||
|
"MultiTenancySide": 3,
|
||||||
|
"MenuGroup": "Kurs"
|
||||||
|
},
|
||||||
|
|
||||||
{
|
{
|
||||||
"GroupName": "App.Crm",
|
"GroupName": "App.Crm",
|
||||||
"Name": "App.Crm.Customer",
|
"Name": "App.Crm.Customer",
|
||||||
|
|
|
||||||
|
|
@ -39459,7 +39459,7 @@ public class ListFormsSeeder : IDataSeedContributor, ITransientDependency
|
||||||
FieldName = "Type",
|
FieldName = "Type",
|
||||||
FieldDbType = DbType.String,
|
FieldDbType = DbType.String,
|
||||||
Value = "morning",
|
Value = "morning",
|
||||||
CustomValueType = FieldCustomValueTypeEnum.Value }
|
CustomValueType = FieldCustomValueTypeEnum.Value }
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
@ -39907,7 +39907,7 @@ public class ListFormsSeeder : IDataSeedContributor, ITransientDependency
|
||||||
FieldName = "PublishDate",
|
FieldName = "PublishDate",
|
||||||
FieldDbType = DbType.Date,
|
FieldDbType = DbType.Date,
|
||||||
Value = "@NOW",
|
Value = "@NOW",
|
||||||
CustomValueType = FieldCustomValueTypeEnum.CustomKey }
|
CustomValueType = FieldCustomValueTypeEnum.CustomKey }
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
@ -40338,6 +40338,551 @@ public class ListFormsSeeder : IDataSeedContributor, ITransientDependency
|
||||||
}
|
}
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
#region Visitors
|
||||||
|
if (!await _listFormRepository.AnyAsync(a => a.ListFormCode == ListFormCodes.Lists.Visitor))
|
||||||
|
{
|
||||||
|
var listFormVisitor = await _listFormRepository.InsertAsync(
|
||||||
|
new ListForm()
|
||||||
|
{
|
||||||
|
ListFormType = ListFormTypeEnum.List,
|
||||||
|
IsSubForm = true,
|
||||||
|
LayoutJson = JsonSerializer.Serialize(new LayoutDto()
|
||||||
|
{
|
||||||
|
Grid = true,
|
||||||
|
Card = true,
|
||||||
|
Pivot = true,
|
||||||
|
Chart = true,
|
||||||
|
DefaultLayout = "grid",
|
||||||
|
CardLayoutColumn = 3
|
||||||
|
}),
|
||||||
|
CultureName = LanguageCodes.En,
|
||||||
|
ListFormCode = ListFormCodes.Lists.Visitor,
|
||||||
|
Name = AppCodes.Hr.Visitor,
|
||||||
|
Title = AppCodes.Hr.Visitor,
|
||||||
|
DataSourceCode = SeedConsts.DataSources.DefaultCode,
|
||||||
|
IsTenant = true,
|
||||||
|
IsBranch = false,
|
||||||
|
IsOrganizationUnit = false,
|
||||||
|
Description = AppCodes.Hr.Visitor,
|
||||||
|
SelectCommandType = SelectCommandTypeEnum.Table,
|
||||||
|
SelectCommand = TableNameResolver.GetFullTableName(nameof(TableNameEnum.Visitor)),
|
||||||
|
KeyFieldName = "Id",
|
||||||
|
KeyFieldDbSourceType = DbType.Guid,
|
||||||
|
DefaultFilter = "\"IsDeleted\" = 'false'",
|
||||||
|
SortMode = GridOptions.SortModeSingle,
|
||||||
|
FilterRowJson = JsonSerializer.Serialize(new GridFilterRowDto { Visible = true }),
|
||||||
|
HeaderFilterJson = JsonSerializer.Serialize(new { Visible = true }),
|
||||||
|
SearchPanelJson = JsonSerializer.Serialize(new { Visible = true }),
|
||||||
|
GroupPanelJson = JsonSerializer.Serialize(new { Visible = true }),
|
||||||
|
SelectionJson = JsonSerializer.Serialize(new SelectionDto
|
||||||
|
{
|
||||||
|
Mode = GridOptions.SelectionModeSingle,
|
||||||
|
AllowSelectAll = false
|
||||||
|
}),
|
||||||
|
ColumnOptionJson = JsonSerializer.Serialize(new
|
||||||
|
{
|
||||||
|
ColumnFixingEnabled = true,
|
||||||
|
ColumnAutoWidth = true,
|
||||||
|
ColumnChooserEnabled = true,
|
||||||
|
AllowColumnResizing = true,
|
||||||
|
AllowColumnReordering = true,
|
||||||
|
ColumnResizingMode = "widget",
|
||||||
|
}),
|
||||||
|
PermissionJson = JsonSerializer.Serialize(new PermissionCrudDto
|
||||||
|
{
|
||||||
|
C = AppCodes.Hr.Visitor + ".Create",
|
||||||
|
R = AppCodes.Hr.Visitor,
|
||||||
|
U = AppCodes.Hr.Visitor + ".Update",
|
||||||
|
D = AppCodes.Hr.Visitor + ".Delete",
|
||||||
|
E = AppCodes.Hr.Visitor + ".Export",
|
||||||
|
I = AppCodes.Hr.Visitor + ".Import",
|
||||||
|
A = AppCodes.Hr.Visitor + ".Activity",
|
||||||
|
}),
|
||||||
|
DeleteCommand = $"UPDATE \"{TableNameResolver.GetFullTableName(nameof(TableNameEnum.Visitor))}\" SET \"DeleterId\"=@DeleterId, \"DeletionTime\"=CURRENT_TIMESTAMP, \"IsDeleted\"='true' WHERE \"Id\"=@Id",
|
||||||
|
DeleteFieldsDefaultValueJson = JsonSerializer.Serialize(new FieldsDefaultValue[] {
|
||||||
|
new() {
|
||||||
|
FieldName = "DeleterId",
|
||||||
|
FieldDbType = DbType.Guid,
|
||||||
|
Value = "@USERID",
|
||||||
|
CustomValueType = FieldCustomValueTypeEnum.CustomKey },
|
||||||
|
new() {
|
||||||
|
FieldName = "Id",
|
||||||
|
FieldDbType = DbType.Guid,
|
||||||
|
Value = "@ID",
|
||||||
|
CustomValueType = FieldCustomValueTypeEnum.CustomKey }
|
||||||
|
}),
|
||||||
|
PagerOptionJson = JsonSerializer.Serialize(new GridPagerOptionDto
|
||||||
|
{
|
||||||
|
Visible = true,
|
||||||
|
AllowedPageSizes = "10,20,50,100",
|
||||||
|
ShowPageSizeSelector = true,
|
||||||
|
ShowNavigationButtons = true,
|
||||||
|
ShowInfo = false,
|
||||||
|
InfoText = "Page {0} of {1} ({2} items)",
|
||||||
|
DisplayMode = GridColumnOptions.PagerDisplayModeAdaptive,
|
||||||
|
ScrollingMode = GridColumnOptions.ScrollingModeStandard,
|
||||||
|
LoadPanelEnabled = "auto",
|
||||||
|
LoadPanelText = "Loading..."
|
||||||
|
}),
|
||||||
|
EditingOptionJson = JsonSerializer.Serialize(new GridEditingDto
|
||||||
|
{
|
||||||
|
Popup = new GridEditingPopupDto()
|
||||||
|
{
|
||||||
|
Title = "Visitor Form",
|
||||||
|
Width = 500,
|
||||||
|
Height = 450
|
||||||
|
},
|
||||||
|
AllowDeleting = true,
|
||||||
|
AllowAdding = true,
|
||||||
|
AllowUpdating = true,
|
||||||
|
SendOnlyChangedFormValuesUpdate = false,
|
||||||
|
}),
|
||||||
|
InsertFieldsDefaultValueJson = JsonSerializer.Serialize(new FieldsDefaultValue[] {
|
||||||
|
new() {
|
||||||
|
FieldName = "CreationTime",
|
||||||
|
FieldDbType = DbType.DateTime,
|
||||||
|
Value = "@NOW",
|
||||||
|
CustomValueType = FieldCustomValueTypeEnum.CustomKey },
|
||||||
|
new() {
|
||||||
|
FieldName = "CreatorId",
|
||||||
|
FieldDbType = DbType.Guid,
|
||||||
|
Value = "@USERID",
|
||||||
|
CustomValueType = FieldCustomValueTypeEnum.CustomKey },
|
||||||
|
new() {
|
||||||
|
FieldName = "IsDeleted",
|
||||||
|
FieldDbType = DbType.Boolean,
|
||||||
|
Value = "false",
|
||||||
|
CustomValueType = FieldCustomValueTypeEnum.Value }
|
||||||
|
}),
|
||||||
|
EditingFormJson = JsonSerializer.Serialize(new List<EditingFormDto>()
|
||||||
|
{
|
||||||
|
new() {
|
||||||
|
Order=1, ColCount=1, ColSpan=2, ItemType="group", Items =
|
||||||
|
[
|
||||||
|
new EditingFormItemDto { Order = 1, DataField = "FullName", IsRequired = true, EditorType2 = EditorTypes.dxTextBox },
|
||||||
|
new EditingFormItemDto { Order = 2, DataField = "CompanyName", IsRequired = true, EditorType2 = EditorTypes.dxTextBox },
|
||||||
|
new EditingFormItemDto { Order = 3, DataField = "Email", EditorType2 = EditorTypes.dxTextBox },
|
||||||
|
new EditingFormItemDto { Order = 4, DataField = "Phone", IsRequired = true, EditorType2 = EditorTypes.dxTextBox, EditorOptions = EditorOptionValues.PhoneEditorOptions },
|
||||||
|
new EditingFormItemDto { Order = 5, DataField = "Purpose", IsRequired = true, EditorType2 = EditorTypes.dxTextBox },
|
||||||
|
new EditingFormItemDto { Order = 6, DataField = "VisitDate", IsRequired = true, EditorType2 = EditorTypes.dxDateBox },
|
||||||
|
new EditingFormItemDto { Order = 7, DataField = "CheckIn", EditorType2 = EditorTypes.dxDateBox },
|
||||||
|
new EditingFormItemDto { Order = 8, DataField = "CheckOut", EditorType2 = EditorTypes.dxDateBox },
|
||||||
|
new EditingFormItemDto { Order = 9, DataField = "EmployeeId", IsRequired = true, EditorType2 = EditorTypes.dxSelectBox },
|
||||||
|
new EditingFormItemDto { Order = 10, DataField = "Status", IsRequired = true, EditorType2 = EditorTypes.dxSelectBox },
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}),
|
||||||
|
FormFieldsDefaultValueJson = JsonSerializer.Serialize(new FieldsDefaultValue[]
|
||||||
|
{
|
||||||
|
new() {
|
||||||
|
FieldName = "VisitDate",
|
||||||
|
FieldDbType = DbType.Date,
|
||||||
|
Value = "@NOW",
|
||||||
|
CustomValueType = FieldCustomValueTypeEnum.CustomKey },
|
||||||
|
new() {
|
||||||
|
FieldName = "CheckIn",
|
||||||
|
FieldDbType = DbType.Date,
|
||||||
|
Value = "@NOW",
|
||||||
|
CustomValueType = FieldCustomValueTypeEnum.CustomKey },
|
||||||
|
new() {
|
||||||
|
FieldName = "Status",
|
||||||
|
FieldDbType = DbType.String,
|
||||||
|
Value = "checked-in",
|
||||||
|
CustomValueType = FieldCustomValueTypeEnum.Value },
|
||||||
|
})
|
||||||
|
}
|
||||||
|
);
|
||||||
|
|
||||||
|
#region Visitor Fields
|
||||||
|
await _listFormFieldRepository.InsertManyAsync([
|
||||||
|
new() {
|
||||||
|
ListFormCode = listFormVisitor.ListFormCode,
|
||||||
|
RoleId = null,
|
||||||
|
UserId = null,
|
||||||
|
CultureName = LanguageCodes.En,
|
||||||
|
SourceDbType = DbType.Guid,
|
||||||
|
FieldName = "Id",
|
||||||
|
Width = 100,
|
||||||
|
ListOrderNo = 1,
|
||||||
|
Visible = false,
|
||||||
|
IsActive = true,
|
||||||
|
IsDeleted = false,
|
||||||
|
SortIndex = 0,
|
||||||
|
ValidationRuleJson = JsonSerializer.Serialize(new ValidationRuleDto[] {
|
||||||
|
new ValidationRuleDto() { Type = Enum.GetName(UiColumnValidationRuleTypeEnum.required) }
|
||||||
|
}),
|
||||||
|
ColumnCustomizationJson = JsonSerializer.Serialize(new ColumnCustomizationDto
|
||||||
|
{
|
||||||
|
AllowReordering = true,
|
||||||
|
}),
|
||||||
|
PermissionJson = JsonSerializer.Serialize(new ListFormFieldPermissionDto
|
||||||
|
{
|
||||||
|
C = AppCodes.Hr.Announcement + ".Create",
|
||||||
|
R = AppCodes.Hr.Announcement,
|
||||||
|
U = AppCodes.Hr.Announcement + ".Update",
|
||||||
|
E = true,
|
||||||
|
I = true,
|
||||||
|
Deny = false
|
||||||
|
}),
|
||||||
|
PivotSettingsJson = JsonSerializer.Serialize(new ListFormFieldPivotSettingsDto
|
||||||
|
{
|
||||||
|
IsPivot = true
|
||||||
|
})
|
||||||
|
},
|
||||||
|
new() {
|
||||||
|
ListFormCode = listFormVisitor.ListFormCode,
|
||||||
|
RoleId = null,
|
||||||
|
UserId = null,
|
||||||
|
CultureName = LanguageCodes.En,
|
||||||
|
SourceDbType = DbType.String,
|
||||||
|
FieldName = "FullName",
|
||||||
|
Width = 150,
|
||||||
|
ListOrderNo = 2,
|
||||||
|
Visible = true,
|
||||||
|
IsActive = true,
|
||||||
|
IsDeleted = false,
|
||||||
|
AllowSearch = true,
|
||||||
|
ValidationRuleJson = JsonSerializer.Serialize(new ValidationRuleDto[] {
|
||||||
|
new ValidationRuleDto() { Type = Enum.GetName(UiColumnValidationRuleTypeEnum.required) }
|
||||||
|
}),
|
||||||
|
ColumnCustomizationJson = JsonSerializer.Serialize(new ColumnCustomizationDto
|
||||||
|
{
|
||||||
|
AllowReordering = true,
|
||||||
|
}),
|
||||||
|
PermissionJson = JsonSerializer.Serialize(new ListFormFieldPermissionDto
|
||||||
|
{
|
||||||
|
C = AppCodes.Hr.Visitor + ".Create",
|
||||||
|
R = AppCodes.Hr.Visitor,
|
||||||
|
U = AppCodes.Hr.Visitor + ".Update",
|
||||||
|
E = true,
|
||||||
|
I = true,
|
||||||
|
Deny = false
|
||||||
|
}),
|
||||||
|
PivotSettingsJson = JsonSerializer.Serialize(new ListFormFieldPivotSettingsDto
|
||||||
|
{
|
||||||
|
IsPivot = true
|
||||||
|
})
|
||||||
|
},
|
||||||
|
new() {
|
||||||
|
ListFormCode = listFormVisitor.ListFormCode,
|
||||||
|
RoleId = null,
|
||||||
|
UserId = null,
|
||||||
|
CultureName = LanguageCodes.En,
|
||||||
|
SourceDbType = DbType.String,
|
||||||
|
FieldName = "CompanyName",
|
||||||
|
Width = 200,
|
||||||
|
ListOrderNo = 3,
|
||||||
|
Visible = true,
|
||||||
|
IsActive = true,
|
||||||
|
IsDeleted = false,
|
||||||
|
AllowSearch = true,
|
||||||
|
ValidationRuleJson = JsonSerializer.Serialize(new ValidationRuleDto[] {
|
||||||
|
new ValidationRuleDto() { Type = Enum.GetName(UiColumnValidationRuleTypeEnum.required) }
|
||||||
|
}),
|
||||||
|
ColumnCustomizationJson = JsonSerializer.Serialize(new ColumnCustomizationDto
|
||||||
|
{
|
||||||
|
AllowReordering = true,
|
||||||
|
}),
|
||||||
|
PermissionJson = JsonSerializer.Serialize(new ListFormFieldPermissionDto
|
||||||
|
{
|
||||||
|
C = AppCodes.Hr.Visitor + ".Create",
|
||||||
|
R = AppCodes.Hr.Visitor,
|
||||||
|
U = AppCodes.Hr.Visitor + ".Update",
|
||||||
|
E = true,
|
||||||
|
I = true,
|
||||||
|
Deny = false
|
||||||
|
}),
|
||||||
|
PivotSettingsJson = JsonSerializer.Serialize(new ListFormFieldPivotSettingsDto
|
||||||
|
{
|
||||||
|
IsPivot = true
|
||||||
|
})
|
||||||
|
},
|
||||||
|
new() {
|
||||||
|
ListFormCode = listFormVisitor.ListFormCode,
|
||||||
|
RoleId = null,
|
||||||
|
UserId = null,
|
||||||
|
CultureName = LanguageCodes.En,
|
||||||
|
SourceDbType = DbType.String,
|
||||||
|
FieldName = "Email",
|
||||||
|
Width = 100,
|
||||||
|
ListOrderNo = 4,
|
||||||
|
Visible = true,
|
||||||
|
IsActive = true,
|
||||||
|
IsDeleted = false,
|
||||||
|
AllowSearch = true,
|
||||||
|
ValidationRuleJson = JsonSerializer.Serialize(new ValidationRuleDto[]
|
||||||
|
{
|
||||||
|
new ValidationRuleDto() { Type = Enum.GetName(UiColumnValidationRuleTypeEnum.email) }
|
||||||
|
}),
|
||||||
|
ColumnCustomizationJson = JsonSerializer.Serialize(new ColumnCustomizationDto
|
||||||
|
{
|
||||||
|
AllowReordering = true,
|
||||||
|
}),
|
||||||
|
PermissionJson = JsonSerializer.Serialize(new ListFormFieldPermissionDto
|
||||||
|
{
|
||||||
|
C = AppCodes.Hr.Visitor + ".Create",
|
||||||
|
R = AppCodes.Hr.Visitor,
|
||||||
|
U = AppCodes.Hr.Visitor + ".Update",
|
||||||
|
E = true,
|
||||||
|
I = true,
|
||||||
|
Deny = false
|
||||||
|
}),
|
||||||
|
PivotSettingsJson = JsonSerializer.Serialize(new ListFormFieldPivotSettingsDto
|
||||||
|
{
|
||||||
|
IsPivot = true
|
||||||
|
})
|
||||||
|
},
|
||||||
|
new() {
|
||||||
|
ListFormCode = listFormVisitor.ListFormCode,
|
||||||
|
RoleId = null,
|
||||||
|
UserId = null,
|
||||||
|
CultureName = LanguageCodes.En,
|
||||||
|
SourceDbType = DbType.Int32,
|
||||||
|
FieldName = "Phone",
|
||||||
|
Width = 100,
|
||||||
|
ListOrderNo = 5,
|
||||||
|
Visible = true,
|
||||||
|
IsActive = true,
|
||||||
|
IsDeleted = false,
|
||||||
|
AllowSearch = true,
|
||||||
|
ValidationRuleJson = JsonSerializer.Serialize(new ValidationRuleDto[]
|
||||||
|
{
|
||||||
|
new ValidationRuleDto() { Type = Enum.GetName(UiColumnValidationRuleTypeEnum.email) }
|
||||||
|
}),
|
||||||
|
ColumnCustomizationJson = JsonSerializer.Serialize(new ColumnCustomizationDto
|
||||||
|
{
|
||||||
|
AllowReordering = true,
|
||||||
|
}),
|
||||||
|
PermissionJson = JsonSerializer.Serialize(new ListFormFieldPermissionDto
|
||||||
|
{
|
||||||
|
C = AppCodes.Hr.Visitor + ".Create",
|
||||||
|
R = AppCodes.Hr.Visitor,
|
||||||
|
U = AppCodes.Hr.Visitor + ".Update",
|
||||||
|
E = true,
|
||||||
|
I = true,
|
||||||
|
Deny = false
|
||||||
|
}),
|
||||||
|
PivotSettingsJson = JsonSerializer.Serialize(new ListFormFieldPivotSettingsDto
|
||||||
|
{
|
||||||
|
IsPivot = true
|
||||||
|
})
|
||||||
|
},
|
||||||
|
new() {
|
||||||
|
ListFormCode = listFormVisitor.ListFormCode,
|
||||||
|
RoleId = null,
|
||||||
|
UserId = null,
|
||||||
|
CultureName = LanguageCodes.En,
|
||||||
|
SourceDbType = DbType.String,
|
||||||
|
FieldName = "Purpose",
|
||||||
|
Width = 200,
|
||||||
|
ListOrderNo = 6,
|
||||||
|
Visible = true,
|
||||||
|
IsActive = true,
|
||||||
|
IsDeleted = false,
|
||||||
|
AllowSearch = true,
|
||||||
|
ValidationRuleJson = JsonSerializer.Serialize(new ValidationRuleDto[]
|
||||||
|
{
|
||||||
|
new ValidationRuleDto() { Type = Enum.GetName(UiColumnValidationRuleTypeEnum.email) }
|
||||||
|
}),
|
||||||
|
ColumnCustomizationJson = JsonSerializer.Serialize(new ColumnCustomizationDto
|
||||||
|
{
|
||||||
|
AllowReordering = true,
|
||||||
|
}),
|
||||||
|
PermissionJson = JsonSerializer.Serialize(new ListFormFieldPermissionDto
|
||||||
|
{
|
||||||
|
C = AppCodes.Hr.Visitor + ".Create",
|
||||||
|
R = AppCodes.Hr.Visitor,
|
||||||
|
U = AppCodes.Hr.Visitor + ".Update",
|
||||||
|
E = true,
|
||||||
|
I = true,
|
||||||
|
Deny = false
|
||||||
|
}),
|
||||||
|
PivotSettingsJson = JsonSerializer.Serialize(new ListFormFieldPivotSettingsDto
|
||||||
|
{
|
||||||
|
IsPivot = true
|
||||||
|
})
|
||||||
|
},
|
||||||
|
new() {
|
||||||
|
ListFormCode = listFormVisitor.ListFormCode,
|
||||||
|
RoleId = null,
|
||||||
|
UserId = null,
|
||||||
|
CultureName = LanguageCodes.En,
|
||||||
|
SourceDbType = DbType.Date,
|
||||||
|
FieldName = "VisitDate",
|
||||||
|
Width = 100,
|
||||||
|
ListOrderNo = 7,
|
||||||
|
Visible = true,
|
||||||
|
IsActive = true,
|
||||||
|
IsDeleted = false,
|
||||||
|
AllowSearch = true,
|
||||||
|
ValidationRuleJson = JsonSerializer.Serialize(new ValidationRuleDto[] {
|
||||||
|
new ValidationRuleDto() { Type = Enum.GetName(UiColumnValidationRuleTypeEnum.required) }
|
||||||
|
}),
|
||||||
|
ColumnCustomizationJson = JsonSerializer.Serialize(new ColumnCustomizationDto
|
||||||
|
{
|
||||||
|
AllowReordering = true,
|
||||||
|
}),
|
||||||
|
PermissionJson = JsonSerializer.Serialize(new ListFormFieldPermissionDto
|
||||||
|
{
|
||||||
|
C = AppCodes.Hr.Visitor + ".Create",
|
||||||
|
R = AppCodes.Hr.Visitor,
|
||||||
|
U = AppCodes.Hr.Visitor + ".Update",
|
||||||
|
E = true,
|
||||||
|
I = true,
|
||||||
|
Deny = false
|
||||||
|
}),
|
||||||
|
PivotSettingsJson = JsonSerializer.Serialize(new ListFormFieldPivotSettingsDto
|
||||||
|
{
|
||||||
|
IsPivot = true
|
||||||
|
})
|
||||||
|
},
|
||||||
|
new() {
|
||||||
|
ListFormCode = listFormVisitor.ListFormCode,
|
||||||
|
RoleId = null,
|
||||||
|
UserId = null,
|
||||||
|
CultureName = LanguageCodes.En,
|
||||||
|
SourceDbType = DbType.DateTime,
|
||||||
|
FieldName = "CheckIn",
|
||||||
|
Width = 100,
|
||||||
|
ListOrderNo = 8,
|
||||||
|
Visible = true,
|
||||||
|
IsActive = true,
|
||||||
|
IsDeleted = false,
|
||||||
|
AllowSearch = true,
|
||||||
|
ColumnCustomizationJson = JsonSerializer.Serialize(new ColumnCustomizationDto
|
||||||
|
{
|
||||||
|
AllowReordering = true,
|
||||||
|
}),
|
||||||
|
PermissionJson = JsonSerializer.Serialize(new ListFormFieldPermissionDto
|
||||||
|
{
|
||||||
|
C = AppCodes.Hr.Visitor + ".Create",
|
||||||
|
R = AppCodes.Hr.Visitor,
|
||||||
|
U = AppCodes.Hr.Visitor + ".Update",
|
||||||
|
E = true,
|
||||||
|
I = true,
|
||||||
|
Deny = false
|
||||||
|
}),
|
||||||
|
PivotSettingsJson = JsonSerializer.Serialize(new ListFormFieldPivotSettingsDto
|
||||||
|
{
|
||||||
|
IsPivot = true
|
||||||
|
})
|
||||||
|
},
|
||||||
|
new() {
|
||||||
|
ListFormCode = listFormVisitor.ListFormCode,
|
||||||
|
RoleId = null,
|
||||||
|
UserId = null,
|
||||||
|
CultureName = LanguageCodes.En,
|
||||||
|
SourceDbType = DbType.DateTime,
|
||||||
|
FieldName = "CheckOut",
|
||||||
|
Width = 100,
|
||||||
|
ListOrderNo = 9,
|
||||||
|
Visible = true,
|
||||||
|
IsActive = true,
|
||||||
|
IsDeleted = false,
|
||||||
|
AllowSearch = true,
|
||||||
|
ColumnCustomizationJson = JsonSerializer.Serialize(new ColumnCustomizationDto
|
||||||
|
{
|
||||||
|
AllowReordering = true,
|
||||||
|
}),
|
||||||
|
PermissionJson = JsonSerializer.Serialize(new ListFormFieldPermissionDto
|
||||||
|
{
|
||||||
|
C = AppCodes.Hr.Visitor + ".Create",
|
||||||
|
R = AppCodes.Hr.Visitor,
|
||||||
|
U = AppCodes.Hr.Visitor + ".Update",
|
||||||
|
E = true,
|
||||||
|
I = true,
|
||||||
|
Deny = false
|
||||||
|
}),
|
||||||
|
PivotSettingsJson = JsonSerializer.Serialize(new ListFormFieldPivotSettingsDto
|
||||||
|
{
|
||||||
|
IsPivot = true
|
||||||
|
})
|
||||||
|
},
|
||||||
|
new() {
|
||||||
|
ListFormCode = listFormVisitor.ListFormCode,
|
||||||
|
RoleId = null,
|
||||||
|
UserId = null,
|
||||||
|
CultureName = LanguageCodes.En,
|
||||||
|
SourceDbType = DbType.Guid,
|
||||||
|
FieldName = "EmployeeId",
|
||||||
|
Width = 100,
|
||||||
|
ListOrderNo = 10,
|
||||||
|
Visible = true,
|
||||||
|
IsActive = true,
|
||||||
|
IsDeleted = false,
|
||||||
|
AllowSearch = true,
|
||||||
|
LookupJson = JsonSerializer.Serialize(new LookupDto
|
||||||
|
{
|
||||||
|
DataSourceType = UiLookupDataSourceTypeEnum.Query,
|
||||||
|
DisplayExpr = "name",
|
||||||
|
ValueExpr = "key",
|
||||||
|
LookupQuery = LookUpQueryValues.EmployeeValues
|
||||||
|
}),
|
||||||
|
ColumnCustomizationJson = JsonSerializer.Serialize(new ColumnCustomizationDto
|
||||||
|
{
|
||||||
|
AllowReordering = true,
|
||||||
|
}),
|
||||||
|
PermissionJson = JsonSerializer.Serialize(new ListFormFieldPermissionDto
|
||||||
|
{
|
||||||
|
C = AppCodes.Hr.Visitor + ".Create",
|
||||||
|
R = AppCodes.Hr.Visitor,
|
||||||
|
U = AppCodes.Hr.Visitor + ".Update",
|
||||||
|
E = true,
|
||||||
|
I = true,
|
||||||
|
Deny = false
|
||||||
|
}),
|
||||||
|
PivotSettingsJson = JsonSerializer.Serialize(new ListFormFieldPivotSettingsDto
|
||||||
|
{
|
||||||
|
IsPivot = true
|
||||||
|
})
|
||||||
|
},
|
||||||
|
new() {
|
||||||
|
ListFormCode = listFormVisitor.ListFormCode,
|
||||||
|
RoleId = null,
|
||||||
|
UserId = null,
|
||||||
|
CultureName = LanguageCodes.En,
|
||||||
|
SourceDbType = DbType.String,
|
||||||
|
FieldName = "Status",
|
||||||
|
Width = 100,
|
||||||
|
ListOrderNo = 11,
|
||||||
|
Visible = true,
|
||||||
|
IsActive = true,
|
||||||
|
IsDeleted = false,
|
||||||
|
AllowSearch = true,
|
||||||
|
LookupJson = JsonSerializer.Serialize(new LookupDto
|
||||||
|
{
|
||||||
|
DataSourceType = UiLookupDataSourceTypeEnum.StaticData,
|
||||||
|
DisplayExpr = "name",
|
||||||
|
ValueExpr = "key",
|
||||||
|
LookupQuery = JsonSerializer.Serialize(new LookupDataDto[] {
|
||||||
|
new () { Key= "checked-in", Name= "Checked-in" },
|
||||||
|
new () { Key= "checked-out", Name= "Checked-out" },
|
||||||
|
new () { Key= "scheduled", Name= "Scheduled" },
|
||||||
|
}),
|
||||||
|
}),
|
||||||
|
ColumnCustomizationJson = JsonSerializer.Serialize(new ColumnCustomizationDto
|
||||||
|
{
|
||||||
|
AllowReordering = true,
|
||||||
|
}),
|
||||||
|
PermissionJson = JsonSerializer.Serialize(new ListFormFieldPermissionDto
|
||||||
|
{
|
||||||
|
C = AppCodes.Hr.Visitor + ".Create",
|
||||||
|
R = AppCodes.Hr.Visitor,
|
||||||
|
U = AppCodes.Hr.Visitor + ".Update",
|
||||||
|
E = true,
|
||||||
|
I = true,
|
||||||
|
Deny = false
|
||||||
|
}),
|
||||||
|
PivotSettingsJson = JsonSerializer.Serialize(new ListFormFieldPivotSettingsDto
|
||||||
|
{
|
||||||
|
IsPivot = true
|
||||||
|
})
|
||||||
|
},
|
||||||
|
]);
|
||||||
|
#endregion
|
||||||
|
}
|
||||||
|
#endregion
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -121,5 +121,6 @@ public enum TableNameEnum
|
||||||
Certificate,
|
Certificate,
|
||||||
Reservation,
|
Reservation,
|
||||||
ShuttleRoute,
|
ShuttleRoute,
|
||||||
Announcement
|
Announcement,
|
||||||
|
Visitor
|
||||||
}
|
}
|
||||||
|
|
@ -532,6 +532,7 @@ public static class PlatformConsts
|
||||||
public const string Reservation = "list-reservation";
|
public const string Reservation = "list-reservation";
|
||||||
public const string ShuttleRoute = "list-shuttleroute";
|
public const string ShuttleRoute = "list-shuttleroute";
|
||||||
public const string Announcement = "list-announcement";
|
public const string Announcement = "list-announcement";
|
||||||
|
public const string Visitor = "list-visitor";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -139,6 +139,7 @@ public static class TableNameResolver
|
||||||
{ nameof(TableNameEnum.Reservation), (PlatformConsts.TablePrefix.TenantByName, MenuPrefix.Hr) },
|
{ nameof(TableNameEnum.Reservation), (PlatformConsts.TablePrefix.TenantByName, MenuPrefix.Hr) },
|
||||||
{ nameof(TableNameEnum.ShuttleRoute), (PlatformConsts.TablePrefix.TenantByName, MenuPrefix.Hr) },
|
{ nameof(TableNameEnum.ShuttleRoute), (PlatformConsts.TablePrefix.TenantByName, MenuPrefix.Hr) },
|
||||||
{ nameof(TableNameEnum.Announcement), (PlatformConsts.TablePrefix.TenantByName, MenuPrefix.Hr) },
|
{ nameof(TableNameEnum.Announcement), (PlatformConsts.TablePrefix.TenantByName, MenuPrefix.Hr) },
|
||||||
|
{ nameof(TableNameEnum.Visitor), (PlatformConsts.TablePrefix.TenantByName, MenuPrefix.Hr) },
|
||||||
|
|
||||||
// 🔹 ACCOUNTING
|
// 🔹 ACCOUNTING
|
||||||
{ nameof(TableNameEnum.Bank), (PlatformConsts.TablePrefix.TenantByName, MenuPrefix.Accounting) },
|
{ nameof(TableNameEnum.Bank), (PlatformConsts.TablePrefix.TenantByName, MenuPrefix.Accounting) },
|
||||||
|
|
|
||||||
|
|
@ -470,6 +470,7 @@ public static class SeedConsts
|
||||||
public const string Reservation = Default + ".Reservation";
|
public const string Reservation = Default + ".Reservation";
|
||||||
public const string ShuttleRoute = Default + ".ShuttleRoute";
|
public const string ShuttleRoute = Default + ".ShuttleRoute";
|
||||||
public const string Announcement = Default + ".Announcement";
|
public const string Announcement = Default + ".Announcement";
|
||||||
|
public const string Visitor = Default + ".Visitor";
|
||||||
}
|
}
|
||||||
|
|
||||||
public static class Accounting
|
public static class Accounting
|
||||||
|
|
|
||||||
|
|
@ -12,6 +12,7 @@ public class Certificate : FullAuditedEntity<Guid>, IMultiTenant
|
||||||
public Training Training { get; set; }
|
public Training Training { get; set; }
|
||||||
|
|
||||||
public Guid EmployeeId { get; set; }
|
public Guid EmployeeId { get; set; }
|
||||||
|
public Employee Employee { get; set; }
|
||||||
public int? Score { get; set; }
|
public int? Score { get; set; }
|
||||||
public DateTime IssueDate { get; set; }
|
public DateTime IssueDate { get; set; }
|
||||||
public DateTime? ExpiryDate { get; set; }
|
public DateTime? ExpiryDate { get; set; }
|
||||||
|
|
|
||||||
|
|
@ -66,10 +66,10 @@ public class Employee : FullAuditedEntity<Guid>, IMultiTenant
|
||||||
public string EmployeeStatus { get; set; }
|
public string EmployeeStatus { get; set; }
|
||||||
public bool IsActive { get; set; }
|
public bool IsActive { get; set; }
|
||||||
|
|
||||||
// Navigation lists (placeholders)
|
|
||||||
public ICollection<Overtime> Overtimes { get; set; }
|
public ICollection<Overtime> Overtimes { get; set; }
|
||||||
public ICollection<Leave> Leaves { get; set; }
|
public ICollection<Leave> Leaves { get; set; }
|
||||||
// public ICollection<HrPerformanceEvaluation> Evaluations { get; set; }
|
public ICollection<Announcement> Announcements { get; set; }
|
||||||
// public ICollection<HrTraining> Trainings { get; set; }
|
public ICollection<Visitor> Visitors { get; set; }
|
||||||
// public ICollection<HrDisciplinaryAction> DisciplinaryActions { get; set; }
|
public ICollection<Reservation> Reservations { get; set; }
|
||||||
|
public ICollection<Certificate> Certificates { get; set; }
|
||||||
}
|
}
|
||||||
|
|
|
||||||
23
api/src/Kurs.Platform.Domain/Entities/Tenant/Hr/Visitor.cs
Normal file
23
api/src/Kurs.Platform.Domain/Entities/Tenant/Hr/Visitor.cs
Normal file
|
|
@ -0,0 +1,23 @@
|
||||||
|
// Domain/Entities/Visitor.cs
|
||||||
|
using System;
|
||||||
|
using Volo.Abp.Domain.Entities.Auditing;
|
||||||
|
using Volo.Abp.MultiTenancy;
|
||||||
|
|
||||||
|
namespace Kurs.Platform.Entities;
|
||||||
|
|
||||||
|
public class Visitor : FullAuditedEntity<Guid>, IMultiTenant
|
||||||
|
{
|
||||||
|
public Guid? TenantId { get; set; }
|
||||||
|
|
||||||
|
public string FullName { get; set; }
|
||||||
|
public string CompanyName { get; set; }
|
||||||
|
public string Email { get; set; }
|
||||||
|
public string Phone { get; set; }
|
||||||
|
public string Purpose { get; set; }
|
||||||
|
public DateTime VisitDate { get; set; }
|
||||||
|
public DateTime? CheckIn { get; set; }
|
||||||
|
public DateTime? CheckOut { get; set; }
|
||||||
|
public Guid? EmployeeId { get; set; } // HrEmployee referansı
|
||||||
|
public Employee Employee { get; set; }
|
||||||
|
public string Status { get; set; } //checked-in, checked-out, scheduled
|
||||||
|
}
|
||||||
|
|
@ -182,6 +182,7 @@ public class PlatformDbContext :
|
||||||
public DbSet<Reservation> Reservations { get; set; }
|
public DbSet<Reservation> Reservations { get; set; }
|
||||||
public DbSet<ShuttleRoute> ShuttleRoutes { get; set; }
|
public DbSet<ShuttleRoute> ShuttleRoutes { get; set; }
|
||||||
public DbSet<Announcement> Announcements { get; set; }
|
public DbSet<Announcement> Announcements { get; set; }
|
||||||
|
public DbSet<Visitor> Visitors { get; set; }
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
|
@ -1918,6 +1919,12 @@ public class PlatformDbContext :
|
||||||
.HasForeignKey(x => x.TrainingId)
|
.HasForeignKey(x => x.TrainingId)
|
||||||
.HasPrincipalKey(e => e.Id)
|
.HasPrincipalKey(e => e.Id)
|
||||||
.OnDelete(DeleteBehavior.Cascade);
|
.OnDelete(DeleteBehavior.Cascade);
|
||||||
|
|
||||||
|
b.HasOne(x => x.Employee)
|
||||||
|
.WithMany(e => e.Certificates)
|
||||||
|
.HasForeignKey(x => x.EmployeeId)
|
||||||
|
.HasPrincipalKey(e => e.Id)
|
||||||
|
.OnDelete(DeleteBehavior.Restrict);
|
||||||
});
|
});
|
||||||
|
|
||||||
builder.Entity<Reservation>(b =>
|
builder.Entity<Reservation>(b =>
|
||||||
|
|
@ -1931,6 +1938,12 @@ public class PlatformDbContext :
|
||||||
b.Property(x => x.Purpose).IsRequired().HasMaxLength(500);
|
b.Property(x => x.Purpose).IsRequired().HasMaxLength(500);
|
||||||
b.Property(x => x.Notes).HasMaxLength(1000);
|
b.Property(x => x.Notes).HasMaxLength(1000);
|
||||||
b.Property(x => x.Status).IsRequired().HasMaxLength(50);
|
b.Property(x => x.Status).IsRequired().HasMaxLength(50);
|
||||||
|
|
||||||
|
b.HasOne(x => x.Employee)
|
||||||
|
.WithMany(e => e.Reservations)
|
||||||
|
.HasForeignKey(x => x.EmployeeId)
|
||||||
|
.HasPrincipalKey(e => e.Id)
|
||||||
|
.OnDelete(DeleteBehavior.Restrict);
|
||||||
});
|
});
|
||||||
|
|
||||||
builder.Entity<ShuttleRoute>(b =>
|
builder.Entity<ShuttleRoute>(b =>
|
||||||
|
|
@ -1961,6 +1974,31 @@ public class PlatformDbContext :
|
||||||
b.Property(x => x.Departments).HasMaxLength(1000);
|
b.Property(x => x.Departments).HasMaxLength(1000);
|
||||||
b.Property(x => x.Attachments).HasMaxLength(2000);
|
b.Property(x => x.Attachments).HasMaxLength(2000);
|
||||||
b.Property(x => x.ViewCount).HasDefaultValue(0);
|
b.Property(x => x.ViewCount).HasDefaultValue(0);
|
||||||
|
|
||||||
|
b.HasOne(x => x.Employee)
|
||||||
|
.WithMany(e => e.Announcements)
|
||||||
|
.HasForeignKey(x => x.EmployeeId)
|
||||||
|
.HasPrincipalKey(e => e.Id)
|
||||||
|
.OnDelete(DeleteBehavior.Restrict);
|
||||||
|
});
|
||||||
|
|
||||||
|
builder.Entity<Visitor>(b =>
|
||||||
|
{
|
||||||
|
b.ToTable(TableNameResolver.GetFullTableName(nameof(TableNameEnum.Visitor)), Prefix.DbSchema);
|
||||||
|
b.ConfigureByConvention();
|
||||||
|
|
||||||
|
b.Property(x => x.FullName).IsRequired().HasMaxLength(100);
|
||||||
|
b.Property(x => x.CompanyName).HasMaxLength(150);
|
||||||
|
b.Property(a => a.Phone).IsRequired().HasMaxLength(20);
|
||||||
|
b.Property(x => x.Email).HasMaxLength(150);
|
||||||
|
b.Property(x => x.Purpose).HasMaxLength(250);
|
||||||
|
b.Property(x => x.Status).IsRequired().HasMaxLength(20);
|
||||||
|
|
||||||
|
b.HasOne(x => x.Employee)
|
||||||
|
.WithMany(e => e.Visitors)
|
||||||
|
.HasForeignKey(x => x.EmployeeId)
|
||||||
|
.HasPrincipalKey(e => e.Id)
|
||||||
|
.OnDelete(DeleteBehavior.Restrict);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,7 @@ using Volo.Abp.EntityFrameworkCore;
|
||||||
namespace Kurs.Platform.Migrations
|
namespace Kurs.Platform.Migrations
|
||||||
{
|
{
|
||||||
[DbContext(typeof(PlatformDbContext))]
|
[DbContext(typeof(PlatformDbContext))]
|
||||||
[Migration("20251025170721_Initial")]
|
[Migration("20251025190722_Initial")]
|
||||||
partial class Initial
|
partial class Initial
|
||||||
{
|
{
|
||||||
/// <inheritdoc />
|
/// <inheritdoc />
|
||||||
|
|
@ -1684,6 +1684,8 @@ namespace Kurs.Platform.Migrations
|
||||||
|
|
||||||
b.HasKey("Id");
|
b.HasKey("Id");
|
||||||
|
|
||||||
|
b.HasIndex("EmployeeId");
|
||||||
|
|
||||||
b.HasIndex("TrainingId");
|
b.HasIndex("TrainingId");
|
||||||
|
|
||||||
b.ToTable("T_Hr_Certificate", (string)null);
|
b.ToTable("T_Hr_Certificate", (string)null);
|
||||||
|
|
@ -8261,6 +8263,91 @@ namespace Kurs.Platform.Migrations
|
||||||
b.ToTable("T_Adm_Vehicle", (string)null);
|
b.ToTable("T_Adm_Vehicle", (string)null);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
modelBuilder.Entity("Kurs.Platform.Entities.Visitor", b =>
|
||||||
|
{
|
||||||
|
b.Property<Guid>("Id")
|
||||||
|
.HasColumnType("uniqueidentifier");
|
||||||
|
|
||||||
|
b.Property<DateTime?>("CheckIn")
|
||||||
|
.HasColumnType("datetime2");
|
||||||
|
|
||||||
|
b.Property<DateTime?>("CheckOut")
|
||||||
|
.HasColumnType("datetime2");
|
||||||
|
|
||||||
|
b.Property<string>("CompanyName")
|
||||||
|
.HasMaxLength(150)
|
||||||
|
.HasColumnType("nvarchar(150)");
|
||||||
|
|
||||||
|
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>("Email")
|
||||||
|
.HasMaxLength(150)
|
||||||
|
.HasColumnType("nvarchar(150)");
|
||||||
|
|
||||||
|
b.Property<Guid?>("EmployeeId")
|
||||||
|
.HasColumnType("uniqueidentifier");
|
||||||
|
|
||||||
|
b.Property<string>("FullName")
|
||||||
|
.IsRequired()
|
||||||
|
.HasMaxLength(100)
|
||||||
|
.HasColumnType("nvarchar(100)");
|
||||||
|
|
||||||
|
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>("Phone")
|
||||||
|
.IsRequired()
|
||||||
|
.HasMaxLength(20)
|
||||||
|
.HasColumnType("nvarchar(20)");
|
||||||
|
|
||||||
|
b.Property<string>("Purpose")
|
||||||
|
.HasMaxLength(250)
|
||||||
|
.HasColumnType("nvarchar(250)");
|
||||||
|
|
||||||
|
b.Property<string>("Status")
|
||||||
|
.IsRequired()
|
||||||
|
.HasMaxLength(20)
|
||||||
|
.HasColumnType("nvarchar(20)");
|
||||||
|
|
||||||
|
b.Property<Guid?>("TenantId")
|
||||||
|
.HasColumnType("uniqueidentifier")
|
||||||
|
.HasColumnName("TenantId");
|
||||||
|
|
||||||
|
b.Property<DateTime>("VisitDate")
|
||||||
|
.HasColumnType("datetime2");
|
||||||
|
|
||||||
|
b.HasKey("Id");
|
||||||
|
|
||||||
|
b.HasIndex("EmployeeId");
|
||||||
|
|
||||||
|
b.ToTable("T_Hr_Visitor", (string)null);
|
||||||
|
});
|
||||||
|
|
||||||
modelBuilder.Entity("Kurs.Platform.Entities.WorkHour", b =>
|
modelBuilder.Entity("Kurs.Platform.Entities.WorkHour", b =>
|
||||||
{
|
{
|
||||||
b.Property<Guid>("Id")
|
b.Property<Guid>("Id")
|
||||||
|
|
@ -10578,8 +10665,9 @@ namespace Kurs.Platform.Migrations
|
||||||
modelBuilder.Entity("Kurs.Platform.Entities.Announcement", b =>
|
modelBuilder.Entity("Kurs.Platform.Entities.Announcement", b =>
|
||||||
{
|
{
|
||||||
b.HasOne("Kurs.Platform.Entities.Employee", "Employee")
|
b.HasOne("Kurs.Platform.Entities.Employee", "Employee")
|
||||||
.WithMany()
|
.WithMany("Announcements")
|
||||||
.HasForeignKey("EmployeeId");
|
.HasForeignKey("EmployeeId")
|
||||||
|
.OnDelete(DeleteBehavior.Restrict);
|
||||||
|
|
||||||
b.Navigation("Employee");
|
b.Navigation("Employee");
|
||||||
});
|
});
|
||||||
|
|
@ -10637,12 +10725,20 @@ namespace Kurs.Platform.Migrations
|
||||||
|
|
||||||
modelBuilder.Entity("Kurs.Platform.Entities.Certificate", b =>
|
modelBuilder.Entity("Kurs.Platform.Entities.Certificate", b =>
|
||||||
{
|
{
|
||||||
|
b.HasOne("Kurs.Platform.Entities.Employee", "Employee")
|
||||||
|
.WithMany("Certificates")
|
||||||
|
.HasForeignKey("EmployeeId")
|
||||||
|
.OnDelete(DeleteBehavior.Restrict)
|
||||||
|
.IsRequired();
|
||||||
|
|
||||||
b.HasOne("Kurs.Platform.Entities.Training", "Training")
|
b.HasOne("Kurs.Platform.Entities.Training", "Training")
|
||||||
.WithMany("Certificates")
|
.WithMany("Certificates")
|
||||||
.HasForeignKey("TrainingId")
|
.HasForeignKey("TrainingId")
|
||||||
.OnDelete(DeleteBehavior.Cascade)
|
.OnDelete(DeleteBehavior.Cascade)
|
||||||
.IsRequired();
|
.IsRequired();
|
||||||
|
|
||||||
|
b.Navigation("Employee");
|
||||||
|
|
||||||
b.Navigation("Training");
|
b.Navigation("Training");
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
@ -11067,9 +11163,9 @@ namespace Kurs.Platform.Migrations
|
||||||
modelBuilder.Entity("Kurs.Platform.Entities.Reservation", b =>
|
modelBuilder.Entity("Kurs.Platform.Entities.Reservation", b =>
|
||||||
{
|
{
|
||||||
b.HasOne("Kurs.Platform.Entities.Employee", "Employee")
|
b.HasOne("Kurs.Platform.Entities.Employee", "Employee")
|
||||||
.WithMany()
|
.WithMany("Reservations")
|
||||||
.HasForeignKey("EmployeeId")
|
.HasForeignKey("EmployeeId")
|
||||||
.OnDelete(DeleteBehavior.Cascade)
|
.OnDelete(DeleteBehavior.Restrict)
|
||||||
.IsRequired();
|
.IsRequired();
|
||||||
|
|
||||||
b.Navigation("Employee");
|
b.Navigation("Employee");
|
||||||
|
|
@ -11119,6 +11215,16 @@ namespace Kurs.Platform.Migrations
|
||||||
b.Navigation("UomCategory");
|
b.Navigation("UomCategory");
|
||||||
});
|
});
|
||||||
|
|
||||||
|
modelBuilder.Entity("Kurs.Platform.Entities.Visitor", b =>
|
||||||
|
{
|
||||||
|
b.HasOne("Kurs.Platform.Entities.Employee", "Employee")
|
||||||
|
.WithMany("Visitors")
|
||||||
|
.HasForeignKey("EmployeeId")
|
||||||
|
.OnDelete(DeleteBehavior.Restrict);
|
||||||
|
|
||||||
|
b.Navigation("Employee");
|
||||||
|
});
|
||||||
|
|
||||||
modelBuilder.Entity("Kurs.Platform.Forum.ForumPost", b =>
|
modelBuilder.Entity("Kurs.Platform.Forum.ForumPost", b =>
|
||||||
{
|
{
|
||||||
b.HasOne("Kurs.Platform.Forum.ForumPost", "ParentPost")
|
b.HasOne("Kurs.Platform.Forum.ForumPost", "ParentPost")
|
||||||
|
|
@ -11360,9 +11466,17 @@ namespace Kurs.Platform.Migrations
|
||||||
|
|
||||||
modelBuilder.Entity("Kurs.Platform.Entities.Employee", b =>
|
modelBuilder.Entity("Kurs.Platform.Entities.Employee", b =>
|
||||||
{
|
{
|
||||||
|
b.Navigation("Announcements");
|
||||||
|
|
||||||
|
b.Navigation("Certificates");
|
||||||
|
|
||||||
b.Navigation("Leaves");
|
b.Navigation("Leaves");
|
||||||
|
|
||||||
b.Navigation("Overtimes");
|
b.Navigation("Overtimes");
|
||||||
|
|
||||||
|
b.Navigation("Reservations");
|
||||||
|
|
||||||
|
b.Navigation("Visitors");
|
||||||
});
|
});
|
||||||
|
|
||||||
modelBuilder.Entity("Kurs.Platform.Entities.Event", b =>
|
modelBuilder.Entity("Kurs.Platform.Entities.Event", b =>
|
||||||
|
|
@ -3324,37 +3324,6 @@ namespace Kurs.Platform.Migrations
|
||||||
onDelete: ReferentialAction.Cascade);
|
onDelete: ReferentialAction.Cascade);
|
||||||
});
|
});
|
||||||
|
|
||||||
migrationBuilder.CreateTable(
|
|
||||||
name: "T_Hr_Certificate",
|
|
||||||
columns: table => new
|
|
||||||
{
|
|
||||||
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
|
|
||||||
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
|
|
||||||
TrainingId = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
|
|
||||||
EmployeeId = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
|
|
||||||
Score = table.Column<int>(type: "int", nullable: true),
|
|
||||||
IssueDate = table.Column<DateTime>(type: "datetime2", nullable: false),
|
|
||||||
ExpiryDate = table.Column<DateTime>(type: "datetime2", nullable: true),
|
|
||||||
CertificateUrl = table.Column<string>(type: "nvarchar(300)", maxLength: 300, nullable: 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_T_Hr_Certificate", x => x.Id);
|
|
||||||
table.ForeignKey(
|
|
||||||
name: "FK_T_Hr_Certificate_T_Hr_Training_TrainingId",
|
|
||||||
column: x => x.TrainingId,
|
|
||||||
principalTable: "T_Hr_Training",
|
|
||||||
principalColumn: "Id",
|
|
||||||
onDelete: ReferentialAction.Cascade);
|
|
||||||
});
|
|
||||||
|
|
||||||
migrationBuilder.CreateTable(
|
migrationBuilder.CreateTable(
|
||||||
name: "T_Sas_ApiEndpoint",
|
name: "T_Sas_ApiEndpoint",
|
||||||
columns: table => new
|
columns: table => new
|
||||||
|
|
@ -3932,6 +3901,37 @@ namespace Kurs.Platform.Migrations
|
||||||
table.PrimaryKey("PK_T_Hr_Announcement", x => x.Id);
|
table.PrimaryKey("PK_T_Hr_Announcement", x => x.Id);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
migrationBuilder.CreateTable(
|
||||||
|
name: "T_Hr_Certificate",
|
||||||
|
columns: table => new
|
||||||
|
{
|
||||||
|
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
|
||||||
|
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
|
||||||
|
TrainingId = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
|
||||||
|
EmployeeId = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
|
||||||
|
Score = table.Column<int>(type: "int", nullable: true),
|
||||||
|
IssueDate = table.Column<DateTime>(type: "datetime2", nullable: false),
|
||||||
|
ExpiryDate = table.Column<DateTime>(type: "datetime2", nullable: true),
|
||||||
|
CertificateUrl = table.Column<string>(type: "nvarchar(300)", maxLength: 300, nullable: 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_T_Hr_Certificate", x => x.Id);
|
||||||
|
table.ForeignKey(
|
||||||
|
name: "FK_T_Hr_Certificate_T_Hr_Training_TrainingId",
|
||||||
|
column: x => x.TrainingId,
|
||||||
|
principalTable: "T_Hr_Training",
|
||||||
|
principalColumn: "Id",
|
||||||
|
onDelete: ReferentialAction.Cascade);
|
||||||
|
});
|
||||||
|
|
||||||
migrationBuilder.CreateTable(
|
migrationBuilder.CreateTable(
|
||||||
name: "T_Hr_CostCenter",
|
name: "T_Hr_CostCenter",
|
||||||
columns: table => new
|
columns: table => new
|
||||||
|
|
@ -4287,7 +4287,42 @@ namespace Kurs.Platform.Migrations
|
||||||
column: x => x.EmployeeId,
|
column: x => x.EmployeeId,
|
||||||
principalTable: "T_Hr_Employee",
|
principalTable: "T_Hr_Employee",
|
||||||
principalColumn: "Id",
|
principalColumn: "Id",
|
||||||
onDelete: ReferentialAction.Cascade);
|
onDelete: ReferentialAction.Restrict);
|
||||||
|
});
|
||||||
|
|
||||||
|
migrationBuilder.CreateTable(
|
||||||
|
name: "T_Hr_Visitor",
|
||||||
|
columns: table => new
|
||||||
|
{
|
||||||
|
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
|
||||||
|
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
|
||||||
|
FullName = table.Column<string>(type: "nvarchar(100)", maxLength: 100, nullable: false),
|
||||||
|
CompanyName = table.Column<string>(type: "nvarchar(150)", maxLength: 150, nullable: true),
|
||||||
|
Email = table.Column<string>(type: "nvarchar(150)", maxLength: 150, nullable: true),
|
||||||
|
Phone = table.Column<string>(type: "nvarchar(20)", maxLength: 20, nullable: false),
|
||||||
|
Purpose = table.Column<string>(type: "nvarchar(250)", maxLength: 250, nullable: true),
|
||||||
|
VisitDate = table.Column<DateTime>(type: "datetime2", nullable: false),
|
||||||
|
CheckIn = table.Column<DateTime>(type: "datetime2", nullable: true),
|
||||||
|
CheckOut = table.Column<DateTime>(type: "datetime2", nullable: true),
|
||||||
|
EmployeeId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
|
||||||
|
Status = table.Column<string>(type: "nvarchar(20)", maxLength: 20, nullable: false),
|
||||||
|
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_T_Hr_Visitor", x => x.Id);
|
||||||
|
table.ForeignKey(
|
||||||
|
name: "FK_T_Hr_Visitor_T_Hr_Employee_EmployeeId",
|
||||||
|
column: x => x.EmployeeId,
|
||||||
|
principalTable: "T_Hr_Employee",
|
||||||
|
principalColumn: "Id",
|
||||||
|
onDelete: ReferentialAction.Restrict);
|
||||||
});
|
});
|
||||||
|
|
||||||
migrationBuilder.CreateIndex(
|
migrationBuilder.CreateIndex(
|
||||||
|
|
@ -4834,6 +4869,11 @@ namespace Kurs.Platform.Migrations
|
||||||
table: "T_Hr_Announcement",
|
table: "T_Hr_Announcement",
|
||||||
column: "EmployeeId");
|
column: "EmployeeId");
|
||||||
|
|
||||||
|
migrationBuilder.CreateIndex(
|
||||||
|
name: "IX_T_Hr_Certificate_EmployeeId",
|
||||||
|
table: "T_Hr_Certificate",
|
||||||
|
column: "EmployeeId");
|
||||||
|
|
||||||
migrationBuilder.CreateIndex(
|
migrationBuilder.CreateIndex(
|
||||||
name: "IX_T_Hr_Certificate_TrainingId",
|
name: "IX_T_Hr_Certificate_TrainingId",
|
||||||
table: "T_Hr_Certificate",
|
table: "T_Hr_Certificate",
|
||||||
|
|
@ -4959,6 +4999,11 @@ namespace Kurs.Platform.Migrations
|
||||||
table: "T_Hr_Reservation",
|
table: "T_Hr_Reservation",
|
||||||
column: "EmployeeId");
|
column: "EmployeeId");
|
||||||
|
|
||||||
|
migrationBuilder.CreateIndex(
|
||||||
|
name: "IX_T_Hr_Visitor_EmployeeId",
|
||||||
|
table: "T_Hr_Visitor",
|
||||||
|
column: "EmployeeId");
|
||||||
|
|
||||||
migrationBuilder.CreateIndex(
|
migrationBuilder.CreateIndex(
|
||||||
name: "IX_T_Sas_ApiEndpoint_EntityId",
|
name: "IX_T_Sas_ApiEndpoint_EntityId",
|
||||||
table: "T_Sas_ApiEndpoint",
|
table: "T_Sas_ApiEndpoint",
|
||||||
|
|
@ -4994,7 +5039,16 @@ namespace Kurs.Platform.Migrations
|
||||||
table: "T_Hr_Announcement",
|
table: "T_Hr_Announcement",
|
||||||
column: "EmployeeId",
|
column: "EmployeeId",
|
||||||
principalTable: "T_Hr_Employee",
|
principalTable: "T_Hr_Employee",
|
||||||
principalColumn: "Id");
|
principalColumn: "Id",
|
||||||
|
onDelete: ReferentialAction.Restrict);
|
||||||
|
|
||||||
|
migrationBuilder.AddForeignKey(
|
||||||
|
name: "FK_T_Hr_Certificate_T_Hr_Employee_EmployeeId",
|
||||||
|
table: "T_Hr_Certificate",
|
||||||
|
column: "EmployeeId",
|
||||||
|
principalTable: "T_Hr_Employee",
|
||||||
|
principalColumn: "Id",
|
||||||
|
onDelete: ReferentialAction.Restrict);
|
||||||
|
|
||||||
migrationBuilder.AddForeignKey(
|
migrationBuilder.AddForeignKey(
|
||||||
name: "FK_T_Hr_CostCenter_T_Hr_Department_DepartmentId",
|
name: "FK_T_Hr_CostCenter_T_Hr_Department_DepartmentId",
|
||||||
|
|
@ -5312,6 +5366,9 @@ namespace Kurs.Platform.Migrations
|
||||||
migrationBuilder.DropTable(
|
migrationBuilder.DropTable(
|
||||||
name: "T_Hr_ShuttleRoute");
|
name: "T_Hr_ShuttleRoute");
|
||||||
|
|
||||||
|
migrationBuilder.DropTable(
|
||||||
|
name: "T_Hr_Visitor");
|
||||||
|
|
||||||
migrationBuilder.DropTable(
|
migrationBuilder.DropTable(
|
||||||
name: "T_Prt_Interesting");
|
name: "T_Prt_Interesting");
|
||||||
|
|
||||||
|
|
@ -1681,6 +1681,8 @@ namespace Kurs.Platform.Migrations
|
||||||
|
|
||||||
b.HasKey("Id");
|
b.HasKey("Id");
|
||||||
|
|
||||||
|
b.HasIndex("EmployeeId");
|
||||||
|
|
||||||
b.HasIndex("TrainingId");
|
b.HasIndex("TrainingId");
|
||||||
|
|
||||||
b.ToTable("T_Hr_Certificate", (string)null);
|
b.ToTable("T_Hr_Certificate", (string)null);
|
||||||
|
|
@ -8258,6 +8260,91 @@ namespace Kurs.Platform.Migrations
|
||||||
b.ToTable("T_Adm_Vehicle", (string)null);
|
b.ToTable("T_Adm_Vehicle", (string)null);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
modelBuilder.Entity("Kurs.Platform.Entities.Visitor", b =>
|
||||||
|
{
|
||||||
|
b.Property<Guid>("Id")
|
||||||
|
.HasColumnType("uniqueidentifier");
|
||||||
|
|
||||||
|
b.Property<DateTime?>("CheckIn")
|
||||||
|
.HasColumnType("datetime2");
|
||||||
|
|
||||||
|
b.Property<DateTime?>("CheckOut")
|
||||||
|
.HasColumnType("datetime2");
|
||||||
|
|
||||||
|
b.Property<string>("CompanyName")
|
||||||
|
.HasMaxLength(150)
|
||||||
|
.HasColumnType("nvarchar(150)");
|
||||||
|
|
||||||
|
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>("Email")
|
||||||
|
.HasMaxLength(150)
|
||||||
|
.HasColumnType("nvarchar(150)");
|
||||||
|
|
||||||
|
b.Property<Guid?>("EmployeeId")
|
||||||
|
.HasColumnType("uniqueidentifier");
|
||||||
|
|
||||||
|
b.Property<string>("FullName")
|
||||||
|
.IsRequired()
|
||||||
|
.HasMaxLength(100)
|
||||||
|
.HasColumnType("nvarchar(100)");
|
||||||
|
|
||||||
|
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>("Phone")
|
||||||
|
.IsRequired()
|
||||||
|
.HasMaxLength(20)
|
||||||
|
.HasColumnType("nvarchar(20)");
|
||||||
|
|
||||||
|
b.Property<string>("Purpose")
|
||||||
|
.HasMaxLength(250)
|
||||||
|
.HasColumnType("nvarchar(250)");
|
||||||
|
|
||||||
|
b.Property<string>("Status")
|
||||||
|
.IsRequired()
|
||||||
|
.HasMaxLength(20)
|
||||||
|
.HasColumnType("nvarchar(20)");
|
||||||
|
|
||||||
|
b.Property<Guid?>("TenantId")
|
||||||
|
.HasColumnType("uniqueidentifier")
|
||||||
|
.HasColumnName("TenantId");
|
||||||
|
|
||||||
|
b.Property<DateTime>("VisitDate")
|
||||||
|
.HasColumnType("datetime2");
|
||||||
|
|
||||||
|
b.HasKey("Id");
|
||||||
|
|
||||||
|
b.HasIndex("EmployeeId");
|
||||||
|
|
||||||
|
b.ToTable("T_Hr_Visitor", (string)null);
|
||||||
|
});
|
||||||
|
|
||||||
modelBuilder.Entity("Kurs.Platform.Entities.WorkHour", b =>
|
modelBuilder.Entity("Kurs.Platform.Entities.WorkHour", b =>
|
||||||
{
|
{
|
||||||
b.Property<Guid>("Id")
|
b.Property<Guid>("Id")
|
||||||
|
|
@ -10575,8 +10662,9 @@ namespace Kurs.Platform.Migrations
|
||||||
modelBuilder.Entity("Kurs.Platform.Entities.Announcement", b =>
|
modelBuilder.Entity("Kurs.Platform.Entities.Announcement", b =>
|
||||||
{
|
{
|
||||||
b.HasOne("Kurs.Platform.Entities.Employee", "Employee")
|
b.HasOne("Kurs.Platform.Entities.Employee", "Employee")
|
||||||
.WithMany()
|
.WithMany("Announcements")
|
||||||
.HasForeignKey("EmployeeId");
|
.HasForeignKey("EmployeeId")
|
||||||
|
.OnDelete(DeleteBehavior.Restrict);
|
||||||
|
|
||||||
b.Navigation("Employee");
|
b.Navigation("Employee");
|
||||||
});
|
});
|
||||||
|
|
@ -10634,12 +10722,20 @@ namespace Kurs.Platform.Migrations
|
||||||
|
|
||||||
modelBuilder.Entity("Kurs.Platform.Entities.Certificate", b =>
|
modelBuilder.Entity("Kurs.Platform.Entities.Certificate", b =>
|
||||||
{
|
{
|
||||||
|
b.HasOne("Kurs.Platform.Entities.Employee", "Employee")
|
||||||
|
.WithMany("Certificates")
|
||||||
|
.HasForeignKey("EmployeeId")
|
||||||
|
.OnDelete(DeleteBehavior.Restrict)
|
||||||
|
.IsRequired();
|
||||||
|
|
||||||
b.HasOne("Kurs.Platform.Entities.Training", "Training")
|
b.HasOne("Kurs.Platform.Entities.Training", "Training")
|
||||||
.WithMany("Certificates")
|
.WithMany("Certificates")
|
||||||
.HasForeignKey("TrainingId")
|
.HasForeignKey("TrainingId")
|
||||||
.OnDelete(DeleteBehavior.Cascade)
|
.OnDelete(DeleteBehavior.Cascade)
|
||||||
.IsRequired();
|
.IsRequired();
|
||||||
|
|
||||||
|
b.Navigation("Employee");
|
||||||
|
|
||||||
b.Navigation("Training");
|
b.Navigation("Training");
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
@ -11064,9 +11160,9 @@ namespace Kurs.Platform.Migrations
|
||||||
modelBuilder.Entity("Kurs.Platform.Entities.Reservation", b =>
|
modelBuilder.Entity("Kurs.Platform.Entities.Reservation", b =>
|
||||||
{
|
{
|
||||||
b.HasOne("Kurs.Platform.Entities.Employee", "Employee")
|
b.HasOne("Kurs.Platform.Entities.Employee", "Employee")
|
||||||
.WithMany()
|
.WithMany("Reservations")
|
||||||
.HasForeignKey("EmployeeId")
|
.HasForeignKey("EmployeeId")
|
||||||
.OnDelete(DeleteBehavior.Cascade)
|
.OnDelete(DeleteBehavior.Restrict)
|
||||||
.IsRequired();
|
.IsRequired();
|
||||||
|
|
||||||
b.Navigation("Employee");
|
b.Navigation("Employee");
|
||||||
|
|
@ -11116,6 +11212,16 @@ namespace Kurs.Platform.Migrations
|
||||||
b.Navigation("UomCategory");
|
b.Navigation("UomCategory");
|
||||||
});
|
});
|
||||||
|
|
||||||
|
modelBuilder.Entity("Kurs.Platform.Entities.Visitor", b =>
|
||||||
|
{
|
||||||
|
b.HasOne("Kurs.Platform.Entities.Employee", "Employee")
|
||||||
|
.WithMany("Visitors")
|
||||||
|
.HasForeignKey("EmployeeId")
|
||||||
|
.OnDelete(DeleteBehavior.Restrict);
|
||||||
|
|
||||||
|
b.Navigation("Employee");
|
||||||
|
});
|
||||||
|
|
||||||
modelBuilder.Entity("Kurs.Platform.Forum.ForumPost", b =>
|
modelBuilder.Entity("Kurs.Platform.Forum.ForumPost", b =>
|
||||||
{
|
{
|
||||||
b.HasOne("Kurs.Platform.Forum.ForumPost", "ParentPost")
|
b.HasOne("Kurs.Platform.Forum.ForumPost", "ParentPost")
|
||||||
|
|
@ -11357,9 +11463,17 @@ namespace Kurs.Platform.Migrations
|
||||||
|
|
||||||
modelBuilder.Entity("Kurs.Platform.Entities.Employee", b =>
|
modelBuilder.Entity("Kurs.Platform.Entities.Employee", b =>
|
||||||
{
|
{
|
||||||
|
b.Navigation("Announcements");
|
||||||
|
|
||||||
|
b.Navigation("Certificates");
|
||||||
|
|
||||||
b.Navigation("Leaves");
|
b.Navigation("Leaves");
|
||||||
|
|
||||||
b.Navigation("Overtimes");
|
b.Navigation("Overtimes");
|
||||||
|
|
||||||
|
b.Navigation("Reservations");
|
||||||
|
|
||||||
|
b.Navigation("Visitors");
|
||||||
});
|
});
|
||||||
|
|
||||||
modelBuilder.Entity("Kurs.Platform.Entities.Event", b =>
|
modelBuilder.Entity("Kurs.Platform.Entities.Event", b =>
|
||||||
|
|
|
||||||
|
|
@ -100,7 +100,9 @@
|
||||||
"props": null,
|
"props": null,
|
||||||
"description": null,
|
"description": null,
|
||||||
"isActive": true,
|
"isActive": true,
|
||||||
"dependencies": ["AxiosListComponent"]
|
"dependencies": [
|
||||||
|
"AxiosListComponent"
|
||||||
|
]
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"ReportCategories": [
|
"ReportCategories": [
|
||||||
|
|
@ -2209,7 +2211,12 @@
|
||||||
"minSalary": 80000,
|
"minSalary": 80000,
|
||||||
"maxSalary": 120000,
|
"maxSalary": 120000,
|
||||||
"currencyCode": "USD",
|
"currencyCode": "USD",
|
||||||
"requiredSkills": ["JavaScript", "TypeScript", "React", "Node.js"],
|
"requiredSkills": [
|
||||||
|
"JavaScript",
|
||||||
|
"TypeScript",
|
||||||
|
"React",
|
||||||
|
"Node.js"
|
||||||
|
],
|
||||||
"responsibilities": [
|
"responsibilities": [
|
||||||
"Develop frontend and backend applications",
|
"Develop frontend and backend applications",
|
||||||
"Write clean and maintainable code",
|
"Write clean and maintainable code",
|
||||||
|
|
@ -3629,5 +3636,40 @@
|
||||||
"viewCount": 312,
|
"viewCount": 312,
|
||||||
"departmentCodes": "BAK|DEP"
|
"departmentCodes": "BAK|DEP"
|
||||||
}
|
}
|
||||||
|
],
|
||||||
|
"Visitors": [
|
||||||
|
{
|
||||||
|
"fullName": "Ali Veli",
|
||||||
|
"companyName": "ABC Teknoloji",
|
||||||
|
"email": "ali.veli@abc.com",
|
||||||
|
"phone": "5321112233",
|
||||||
|
"visitDate": "2025-10-05",
|
||||||
|
"checkIn": "05-10-2025",
|
||||||
|
"employeeCode": "EMP-001",
|
||||||
|
"purpose": "İş Ortaklığı Görüşmesi",
|
||||||
|
"status": "checked-in"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"fullName": "Fatma Yıldız",
|
||||||
|
"companyName": "XYZ Danışmanlık",
|
||||||
|
"email": "fatma@xyz.com",
|
||||||
|
"phone": "5332223344",
|
||||||
|
"visitDate": "01-10-2024",
|
||||||
|
"employeeCode": "EMP-002",
|
||||||
|
"purpose": "Eğitim Danışmanlığı",
|
||||||
|
"status": "scheduled"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"fullName": "Mehmet Kara",
|
||||||
|
"companyName": "DEF Yazılım",
|
||||||
|
"email": "mehmet@def.com",
|
||||||
|
"phone": "5343334455",
|
||||||
|
"visitDate": "08-10-2024",
|
||||||
|
"checkIn": "08-10-2024",
|
||||||
|
"checkOut": "10-10-2024",
|
||||||
|
"employeeCode": "EMP-003",
|
||||||
|
"purpose": "Teknik Sunum",
|
||||||
|
"status": "checked-out"
|
||||||
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
@ -77,6 +77,7 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
|
||||||
private readonly IRepository<Reservation, Guid> _reservationRepository;
|
private readonly IRepository<Reservation, Guid> _reservationRepository;
|
||||||
private readonly IRepository<ShuttleRoute, Guid> _shuttleRouteRepository;
|
private readonly IRepository<ShuttleRoute, Guid> _shuttleRouteRepository;
|
||||||
private readonly IRepository<Announcement, Guid> _announcementRepository;
|
private readonly IRepository<Announcement, Guid> _announcementRepository;
|
||||||
|
private readonly IRepository<Visitor, Guid> _visitorRepository;
|
||||||
|
|
||||||
public TenantDataSeeder(
|
public TenantDataSeeder(
|
||||||
IRepository<IdentityUser, Guid> repositoryUser,
|
IRepository<IdentityUser, Guid> repositoryUser,
|
||||||
|
|
@ -137,7 +138,8 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
|
||||||
IRepository<Training, Guid> trainingRepository,
|
IRepository<Training, Guid> trainingRepository,
|
||||||
IRepository<Reservation, Guid> reservationRepository,
|
IRepository<Reservation, Guid> reservationRepository,
|
||||||
IRepository<ShuttleRoute, Guid> shuttleRouteRepository,
|
IRepository<ShuttleRoute, Guid> shuttleRouteRepository,
|
||||||
IRepository<Announcement, Guid> announcementRepository
|
IRepository<Announcement, Guid> announcementRepository,
|
||||||
|
IRepository<Visitor, Guid> visitorRepository
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
_repositoryUser = repositoryUser;
|
_repositoryUser = repositoryUser;
|
||||||
|
|
@ -199,6 +201,7 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
|
||||||
_reservationRepository = reservationRepository;
|
_reservationRepository = reservationRepository;
|
||||||
_shuttleRouteRepository = shuttleRouteRepository;
|
_shuttleRouteRepository = shuttleRouteRepository;
|
||||||
_announcementRepository = announcementRepository;
|
_announcementRepository = announcementRepository;
|
||||||
|
_visitorRepository = visitorRepository;
|
||||||
}
|
}
|
||||||
|
|
||||||
private static IConfigurationRoot BuildConfiguration()
|
private static IConfigurationRoot BuildConfiguration()
|
||||||
|
|
@ -1282,5 +1285,28 @@ public class TenantDataSeeder : IDataSeedContributor, ITransientDependency
|
||||||
Departments = string.Join("|", targetDepartments.Select(d => d.Id)),
|
Departments = string.Join("|", targetDepartments.Select(d => d.Id)),
|
||||||
}, autoSave: true);
|
}, autoSave: true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
foreach (var item in items.Visitors)
|
||||||
|
{
|
||||||
|
var exists = await _visitorRepository.AnyAsync(x => x.FullName == item.FullName);
|
||||||
|
if (exists)
|
||||||
|
continue;
|
||||||
|
|
||||||
|
var employee = await _employeeRepository.FirstOrDefaultAsync(x => x.Code == item.EmployeeCode);
|
||||||
|
await _visitorRepository.InsertAsync(new Visitor
|
||||||
|
{
|
||||||
|
FullName = item.FullName,
|
||||||
|
CompanyName = item.CompanyName,
|
||||||
|
Email = item.Email,
|
||||||
|
Phone = item.Phone,
|
||||||
|
Purpose = item.Purpose,
|
||||||
|
VisitDate = item.VisitDate,
|
||||||
|
CheckIn = item.CheckIn,
|
||||||
|
CheckOut = item.CheckOut,
|
||||||
|
EmployeeId = employee != null ? employee.Id : null,
|
||||||
|
Status = item.Status
|
||||||
|
}, autoSave: true);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -66,6 +66,21 @@ public class TenantSeederDto
|
||||||
public List<ReservationSeedDto> Reservations { get; set; }
|
public List<ReservationSeedDto> Reservations { get; set; }
|
||||||
public List<ShuttleRouteSeedDto> ShuttleRoutes { get; set; }
|
public List<ShuttleRouteSeedDto> ShuttleRoutes { get; set; }
|
||||||
public List<AnnouncementSeedDto> Announcements { get; set; }
|
public List<AnnouncementSeedDto> Announcements { get; set; }
|
||||||
|
public List<VisitorSeedDto> Visitors { get; set; }
|
||||||
|
}
|
||||||
|
|
||||||
|
public class VisitorSeedDto
|
||||||
|
{
|
||||||
|
public string FullName { get; set; }
|
||||||
|
public string CompanyName { get; set; }
|
||||||
|
public string Email { get; set; }
|
||||||
|
public string Phone { get; set; }
|
||||||
|
public string Purpose { get; set; }
|
||||||
|
public DateTime VisitDate { get; set; }
|
||||||
|
public DateTime? CheckIn { get; set; }
|
||||||
|
public DateTime? CheckOut { get; set; }
|
||||||
|
public string EmployeeCode { get; set; }
|
||||||
|
public string Status { get; set; }
|
||||||
}
|
}
|
||||||
|
|
||||||
public class AnnouncementSeedDto
|
public class AnnouncementSeedDto
|
||||||
|
|
@ -75,14 +90,14 @@ public class AnnouncementSeedDto
|
||||||
public string Content { get; set; }
|
public string Content { get; set; }
|
||||||
public string ImageUrl { get; set; }
|
public string ImageUrl { get; set; }
|
||||||
public string Category { get; set; }
|
public string Category { get; set; }
|
||||||
public string EmployeeCode { get; set; }
|
public string EmployeeCode { get; set; }
|
||||||
public DateTime PublishDate { get; set; }
|
public DateTime PublishDate { get; set; }
|
||||||
public DateTime? ExpiryDate { get; set; }
|
public DateTime? ExpiryDate { get; set; }
|
||||||
public bool IsPinned { get; set; }
|
public bool IsPinned { get; set; }
|
||||||
public int ViewCount { get; set; }
|
public int ViewCount { get; set; }
|
||||||
public string DepartmentCodes { get; set; }
|
public string DepartmentCodes { get; set; }
|
||||||
}
|
}
|
||||||
|
|
||||||
public class ShuttleRouteSeedDto
|
public class ShuttleRouteSeedDto
|
||||||
{
|
{
|
||||||
public string Name { get; set; }
|
public string Name { get; set; }
|
||||||
|
|
@ -93,7 +108,7 @@ public class ShuttleRouteSeedDto
|
||||||
public int Available { get; set; }
|
public int Available { get; set; }
|
||||||
public string Type { get; set; }
|
public string Type { get; set; }
|
||||||
}
|
}
|
||||||
|
|
||||||
public class ReservationSeedDto
|
public class ReservationSeedDto
|
||||||
{
|
{
|
||||||
public string Type { get; set; }
|
public string Type { get; set; }
|
||||||
|
|
@ -106,7 +121,7 @@ public class ReservationSeedDto
|
||||||
public string Notes { get; set; }
|
public string Notes { get; set; }
|
||||||
public string Status { get; set; }
|
public string Status { get; set; }
|
||||||
}
|
}
|
||||||
|
|
||||||
public class TrainingSeedDto
|
public class TrainingSeedDto
|
||||||
{
|
{
|
||||||
public string Title { get; set; }
|
public string Title { get; set; }
|
||||||
|
|
|
||||||
|
|
@ -15,171 +15,6 @@ import {
|
||||||
SocialPost,
|
SocialPost,
|
||||||
} from '@/types/intranet'
|
} from '@/types/intranet'
|
||||||
|
|
||||||
export const mockEvents: CalendarEvent[] = [
|
|
||||||
{
|
|
||||||
id: 'evt1',
|
|
||||||
title: 'Yaz Pikniği 2025',
|
|
||||||
description:
|
|
||||||
'Şirket çalışanları olarak doğayla iç içe harika bir gün geçirdik. Takım oyunları, barbekü ve çok eğlence!',
|
|
||||||
type: 'social',
|
|
||||||
date: new Date('2025-10-20'),
|
|
||||||
location: 'Polonezköy Piknik Alanı',
|
|
||||||
organizer: mockEmployees[4],
|
|
||||||
participants: 45,
|
|
||||||
photos: [
|
|
||||||
'https://images.unsplash.com/photo-1530541930197-ff16ac917b0e?w=800',
|
|
||||||
'https://images.unsplash.com/photo-1527529482837-4698179dc6ce?w=800',
|
|
||||||
'https://images.unsplash.com/photo-1528605105345-5344ea20e269?w=800',
|
|
||||||
'https://images.unsplash.com/photo-1504196606672-aef5c9cefc92?w=800',
|
|
||||||
],
|
|
||||||
comments: [
|
|
||||||
{
|
|
||||||
id: 'c1',
|
|
||||||
author: mockEmployees[0],
|
|
||||||
content: 'Muhteşem bir gündü! Yılın en güzel etkinliği 🎉',
|
|
||||||
creationTime: new Date('2025-07-16T10:30:00'),
|
|
||||||
likes: 12,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: 'c2',
|
|
||||||
author: mockEmployees[2],
|
|
||||||
content: 'Voleybol turnuvası harikaydı, gelecek yıl yine yapalım!',
|
|
||||||
creationTime: new Date('2025-07-16T14:20:00'),
|
|
||||||
likes: 8,
|
|
||||||
},
|
|
||||||
],
|
|
||||||
likes: 34,
|
|
||||||
isPublished: true,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: 'evt2',
|
|
||||||
title: 'Hackathon 2025',
|
|
||||||
description: '24 saatlik yazılım geliştirme maratonu. İnovasyon, teknoloji ve takım çalışması!',
|
|
||||||
type: 'training',
|
|
||||||
date: new Date('2025-20-22'),
|
|
||||||
location: 'Ofis - Ana Salon',
|
|
||||||
organizer: mockEmployees[0],
|
|
||||||
participants: 28,
|
|
||||||
photos: [
|
|
||||||
'https://images.unsplash.com/photo-1504384308090-c894fdcc538d?w=800',
|
|
||||||
'https://images.unsplash.com/photo-1522071820081-009f0129c71c?w=800',
|
|
||||||
'https://images.unsplash.com/photo-1531482615713-2afd69097998?w=800',
|
|
||||||
],
|
|
||||||
comments: [
|
|
||||||
{
|
|
||||||
id: 'c3',
|
|
||||||
author: mockEmployees[1],
|
|
||||||
content: 'Ekibimiz 2. oldu! Çok gurur duydum herkesle 💪',
|
|
||||||
creationTime: new Date('2025-09-11T09:00:00'),
|
|
||||||
likes: 15,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: 'c4',
|
|
||||||
author: mockEmployees[3],
|
|
||||||
content: 'Gece boyunca kod yazmak ve pizza yemek priceless! 🍕',
|
|
||||||
creationTime: new Date('2025-09-11T11:45:00'),
|
|
||||||
likes: 10,
|
|
||||||
},
|
|
||||||
],
|
|
||||||
likes: 42,
|
|
||||||
isPublished: true,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: 'evt3',
|
|
||||||
title: 'Kurumsal Futbol Turnuvası',
|
|
||||||
description: 'Departmanlar arası futbol turnuvasında ter döktük, gol attık ve kazandık! 🏆',
|
|
||||||
type: 'sport',
|
|
||||||
date: new Date('2025-10-25'),
|
|
||||||
location: 'Spor Kompleksi Halı Saha',
|
|
||||||
organizer: mockEmployees[2],
|
|
||||||
participants: 32,
|
|
||||||
photos: [
|
|
||||||
'https://images.unsplash.com/photo-1579952363873-27f3bade9f55?w=800',
|
|
||||||
'https://images.unsplash.com/photo-1574629810360-7efbbe195018?w=800',
|
|
||||||
'https://images.unsplash.com/photo-1431324155629-1a6deb1dec8d?w=800',
|
|
||||||
'https://images.unsplash.com/photo-1553778263-73a83bab9b0c?w=800',
|
|
||||||
],
|
|
||||||
comments: [
|
|
||||||
{
|
|
||||||
id: 'c5',
|
|
||||||
author: mockEmployees[4],
|
|
||||||
content: 'İT departmanı şampiyon oldu! Gelecek sene kupayı koruyacağız 🏆',
|
|
||||||
creationTime: new Date('2025-06-21T08:30:00'),
|
|
||||||
likes: 18,
|
|
||||||
},
|
|
||||||
],
|
|
||||||
likes: 28,
|
|
||||||
isPublished: true,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: 'evt4',
|
|
||||||
title: 'Yılbaşı Gala Gecesi 2024',
|
|
||||||
description: 'Harika bir yıla muhteşem bir gala ile veda ettik. Müzik, dans ve sürprizler!',
|
|
||||||
type: 'company',
|
|
||||||
date: new Date('2024-12-28'),
|
|
||||||
location: 'Grand Hotel - Balo Salonu',
|
|
||||||
organizer: mockEmployees[3],
|
|
||||||
participants: 68,
|
|
||||||
photos: [
|
|
||||||
'https://images.unsplash.com/photo-1511795409834-ef04bbd61622?w=800',
|
|
||||||
'https://images.unsplash.com/photo-1519167758481-83f29da8c2b9?w=800',
|
|
||||||
'https://images.unsplash.com/photo-1464366400600-7168b8af9bc3?w=800',
|
|
||||||
'https://images.unsplash.com/photo-1478147427282-58a87a120781?w=800',
|
|
||||||
'https://images.unsplash.com/photo-1492684223066-81342ee5ff30?w=800',
|
|
||||||
],
|
|
||||||
comments: [
|
|
||||||
{
|
|
||||||
id: 'c6',
|
|
||||||
author: mockEmployees[0],
|
|
||||||
content: 'Yılın en şık gecesi! Organizasyon mükemmeldi 👏',
|
|
||||||
creationTime: new Date('2024-12-29T10:00:00'),
|
|
||||||
likes: 25,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: 'c7',
|
|
||||||
author: mockEmployees[1],
|
|
||||||
content: 'Tombala hediyelerim harika, çok teşekkürler! 🎁',
|
|
||||||
creationTime: new Date('2024-12-29T12:30:00'),
|
|
||||||
likes: 14,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: 'c8',
|
|
||||||
author: mockEmployees[2],
|
|
||||||
content: 'Müzik grubunuz süperdi, dans pistinden ayrılamadık! 🎵',
|
|
||||||
creationTime: new Date('2024-12-29T15:20:00'),
|
|
||||||
likes: 19,
|
|
||||||
},
|
|
||||||
],
|
|
||||||
likes: 51,
|
|
||||||
isPublished: true,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: 'evt5',
|
|
||||||
title: 'Sanat Atölyesi - Ebru Workshop',
|
|
||||||
description: 'Geleneksel Türk sanatı ebru yapımı atölyesinde harika eserler ortaya çıktı!',
|
|
||||||
type: 'culture',
|
|
||||||
date: new Date('2025-05-12'),
|
|
||||||
location: 'Ofis - Yaratıcı Alan',
|
|
||||||
organizer: mockEmployees[1],
|
|
||||||
participants: 18,
|
|
||||||
photos: [
|
|
||||||
'https://images.unsplash.com/photo-1460661419201-fd4cecdf8a8b?w=800',
|
|
||||||
'https://images.unsplash.com/photo-1513364776144-60967b0f800f?w=800',
|
|
||||||
'https://images.unsplash.com/photo-1515405295579-ba7b45403062?w=800',
|
|
||||||
],
|
|
||||||
comments: [
|
|
||||||
{
|
|
||||||
id: 'c9',
|
|
||||||
author: mockEmployees[3],
|
|
||||||
content: 'İlk defa ebru yaptım, çok huzurlu bir deneyimdi 🎨',
|
|
||||||
creationTime: new Date('2025-05-13T09:15:00'),
|
|
||||||
likes: 11,
|
|
||||||
},
|
|
||||||
],
|
|
||||||
likes: 22,
|
|
||||||
isPublished: true,
|
|
||||||
},
|
|
||||||
]
|
|
||||||
|
|
||||||
export const mockExpenseRequests: ExpenseRequest[] = [
|
export const mockExpenseRequests: ExpenseRequest[] = [
|
||||||
{
|
{
|
||||||
|
|
@ -361,50 +196,6 @@ export const mockSurveys: Survey[] = [
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
|
|
||||||
export const mockVisitors: Visitor[] = [
|
|
||||||
{
|
|
||||||
id: 'vis1',
|
|
||||||
fullName: 'Ali Veli',
|
|
||||||
company: 'ABC Teknoloji',
|
|
||||||
email: 'ali.veli@abc.com',
|
|
||||||
phone: '+90 532 111 22 33',
|
|
||||||
visitDate: new Date('2024-10-20T10:00:00'),
|
|
||||||
checkIn: new Date('2024-10-20T10:15:00'),
|
|
||||||
host: mockEmployees[1],
|
|
||||||
purpose: 'İş Ortaklığı Görüşmesi',
|
|
||||||
status: 'checked-in',
|
|
||||||
badgeNumber: 'V-001',
|
|
||||||
photo: 'https://i.pravatar.cc/150?img=60',
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: 'vis2',
|
|
||||||
fullName: 'Fatma Yıldız',
|
|
||||||
company: 'XYZ Danışmanlık',
|
|
||||||
email: 'fatma@xyz.com',
|
|
||||||
phone: '+90 533 222 33 44',
|
|
||||||
visitDate: new Date('2024-10-21T14:00:00'),
|
|
||||||
host: mockEmployees[2],
|
|
||||||
purpose: 'Eğitim Danışmanlığı',
|
|
||||||
status: 'scheduled',
|
|
||||||
photo: 'https://i.pravatar.cc/150?img=47',
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: 'vis3',
|
|
||||||
fullName: 'Mehmet Kara',
|
|
||||||
company: 'DEF Yazılım',
|
|
||||||
email: 'mehmet@def.com',
|
|
||||||
phone: '+90 534 333 44 55',
|
|
||||||
visitDate: new Date('2024-10-18T11:00:00'),
|
|
||||||
checkIn: new Date('2024-10-18T11:05:00'),
|
|
||||||
checkOut: new Date('2024-10-18T13:30:00'),
|
|
||||||
host: mockEmployees[3],
|
|
||||||
purpose: 'Teknik Sunum',
|
|
||||||
status: 'checked-out',
|
|
||||||
badgeNumber: 'V-002',
|
|
||||||
photo: 'https://i.pravatar.cc/150?img=68',
|
|
||||||
},
|
|
||||||
]
|
|
||||||
|
|
||||||
export const mockSocialPosts: SocialPost[] = [
|
export const mockSocialPosts: SocialPost[] = [
|
||||||
{
|
{
|
||||||
id: '1',
|
id: '1',
|
||||||
|
|
@ -660,7 +451,6 @@ export const mockSocialPosts: SocialPost[] = [
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
/////////////////////////////////////////////////////////////////////////////////////
|
/////////////////////////////////////////////////////////////////////////////////////
|
||||||
///////EKLENENLER//////////
|
///////EKLENENLER//////////
|
||||||
export const mockTrainings: Training[] = [
|
export const mockTrainings: Training[] = [
|
||||||
|
|
@ -979,4 +769,214 @@ export const mockAnnouncements: Announcement[] = [
|
||||||
viewCount: 312,
|
viewCount: 312,
|
||||||
attachments: [{ name: 'Bilgi_Guvenligi_Politikasi_v2.pdf', url: '#', size: '2.4 MB' }],
|
attachments: [{ name: 'Bilgi_Guvenligi_Politikasi_v2.pdf', url: '#', size: '2.4 MB' }],
|
||||||
},
|
},
|
||||||
|
]
|
||||||
|
|
||||||
|
export const mockEvents: CalendarEvent[] = [
|
||||||
|
{
|
||||||
|
id: 'evt1',
|
||||||
|
title: 'Yaz Pikniği 2025',
|
||||||
|
description:
|
||||||
|
'Şirket çalışanları olarak doğayla iç içe harika bir gün geçirdik. Takım oyunları, barbekü ve çok eğlence!',
|
||||||
|
type: 'social',
|
||||||
|
date: new Date('2025-10-20'),
|
||||||
|
location: 'Polonezköy Piknik Alanı',
|
||||||
|
organizer: mockEmployees[4],
|
||||||
|
participants: 45,
|
||||||
|
photos: [
|
||||||
|
'https://images.unsplash.com/photo-1530541930197-ff16ac917b0e?w=800',
|
||||||
|
'https://images.unsplash.com/photo-1527529482837-4698179dc6ce?w=800',
|
||||||
|
'https://images.unsplash.com/photo-1528605105345-5344ea20e269?w=800',
|
||||||
|
'https://images.unsplash.com/photo-1504196606672-aef5c9cefc92?w=800',
|
||||||
|
],
|
||||||
|
comments: [
|
||||||
|
{
|
||||||
|
id: 'c1',
|
||||||
|
author: mockEmployees[0],
|
||||||
|
content: 'Muhteşem bir gündü! Yılın en güzel etkinliği 🎉',
|
||||||
|
creationTime: new Date('2025-07-16T10:30:00'),
|
||||||
|
likes: 12,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 'c2',
|
||||||
|
author: mockEmployees[2],
|
||||||
|
content: 'Voleybol turnuvası harikaydı, gelecek yıl yine yapalım!',
|
||||||
|
creationTime: new Date('2025-07-16T14:20:00'),
|
||||||
|
likes: 8,
|
||||||
|
},
|
||||||
|
],
|
||||||
|
likes: 34,
|
||||||
|
isPublished: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 'evt2',
|
||||||
|
title: 'Hackathon 2025',
|
||||||
|
description: '24 saatlik yazılım geliştirme maratonu. İnovasyon, teknoloji ve takım çalışması!',
|
||||||
|
type: 'training',
|
||||||
|
date: new Date('2025-20-22'),
|
||||||
|
location: 'Ofis - Ana Salon',
|
||||||
|
organizer: mockEmployees[0],
|
||||||
|
participants: 28,
|
||||||
|
photos: [
|
||||||
|
'https://images.unsplash.com/photo-1504384308090-c894fdcc538d?w=800',
|
||||||
|
'https://images.unsplash.com/photo-1522071820081-009f0129c71c?w=800',
|
||||||
|
'https://images.unsplash.com/photo-1531482615713-2afd69097998?w=800',
|
||||||
|
],
|
||||||
|
comments: [
|
||||||
|
{
|
||||||
|
id: 'c3',
|
||||||
|
author: mockEmployees[1],
|
||||||
|
content: 'Ekibimiz 2. oldu! Çok gurur duydum herkesle 💪',
|
||||||
|
creationTime: new Date('2025-09-11T09:00:00'),
|
||||||
|
likes: 15,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 'c4',
|
||||||
|
author: mockEmployees[3],
|
||||||
|
content: 'Gece boyunca kod yazmak ve pizza yemek priceless! 🍕',
|
||||||
|
creationTime: new Date('2025-09-11T11:45:00'),
|
||||||
|
likes: 10,
|
||||||
|
},
|
||||||
|
],
|
||||||
|
likes: 42,
|
||||||
|
isPublished: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 'evt3',
|
||||||
|
title: 'Kurumsal Futbol Turnuvası',
|
||||||
|
description: 'Departmanlar arası futbol turnuvasında ter döktük, gol attık ve kazandık! 🏆',
|
||||||
|
type: 'sport',
|
||||||
|
date: new Date('2025-10-25'),
|
||||||
|
location: 'Spor Kompleksi Halı Saha',
|
||||||
|
organizer: mockEmployees[2],
|
||||||
|
participants: 32,
|
||||||
|
photos: [
|
||||||
|
'https://images.unsplash.com/photo-1579952363873-27f3bade9f55?w=800',
|
||||||
|
'https://images.unsplash.com/photo-1574629810360-7efbbe195018?w=800',
|
||||||
|
'https://images.unsplash.com/photo-1431324155629-1a6deb1dec8d?w=800',
|
||||||
|
'https://images.unsplash.com/photo-1553778263-73a83bab9b0c?w=800',
|
||||||
|
],
|
||||||
|
comments: [
|
||||||
|
{
|
||||||
|
id: 'c5',
|
||||||
|
author: mockEmployees[4],
|
||||||
|
content: 'İT departmanı şampiyon oldu! Gelecek sene kupayı koruyacağız 🏆',
|
||||||
|
creationTime: new Date('2025-06-21T08:30:00'),
|
||||||
|
likes: 18,
|
||||||
|
},
|
||||||
|
],
|
||||||
|
likes: 28,
|
||||||
|
isPublished: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 'evt4',
|
||||||
|
title: 'Yılbaşı Gala Gecesi 2024',
|
||||||
|
description: 'Harika bir yıla muhteşem bir gala ile veda ettik. Müzik, dans ve sürprizler!',
|
||||||
|
type: 'company',
|
||||||
|
date: new Date('2024-12-28'),
|
||||||
|
location: 'Grand Hotel - Balo Salonu',
|
||||||
|
organizer: mockEmployees[3],
|
||||||
|
participants: 68,
|
||||||
|
photos: [
|
||||||
|
'https://images.unsplash.com/photo-1511795409834-ef04bbd61622?w=800',
|
||||||
|
'https://images.unsplash.com/photo-1519167758481-83f29da8c2b9?w=800',
|
||||||
|
'https://images.unsplash.com/photo-1464366400600-7168b8af9bc3?w=800',
|
||||||
|
'https://images.unsplash.com/photo-1478147427282-58a87a120781?w=800',
|
||||||
|
'https://images.unsplash.com/photo-1492684223066-81342ee5ff30?w=800',
|
||||||
|
],
|
||||||
|
comments: [
|
||||||
|
{
|
||||||
|
id: 'c6',
|
||||||
|
author: mockEmployees[0],
|
||||||
|
content: 'Yılın en şık gecesi! Organizasyon mükemmeldi 👏',
|
||||||
|
creationTime: new Date('2024-12-29T10:00:00'),
|
||||||
|
likes: 25,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 'c7',
|
||||||
|
author: mockEmployees[1],
|
||||||
|
content: 'Tombala hediyelerim harika, çok teşekkürler! 🎁',
|
||||||
|
creationTime: new Date('2024-12-29T12:30:00'),
|
||||||
|
likes: 14,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 'c8',
|
||||||
|
author: mockEmployees[2],
|
||||||
|
content: 'Müzik grubunuz süperdi, dans pistinden ayrılamadık! 🎵',
|
||||||
|
creationTime: new Date('2024-12-29T15:20:00'),
|
||||||
|
likes: 19,
|
||||||
|
},
|
||||||
|
],
|
||||||
|
likes: 51,
|
||||||
|
isPublished: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 'evt5',
|
||||||
|
title: 'Sanat Atölyesi - Ebru Workshop',
|
||||||
|
description: 'Geleneksel Türk sanatı ebru yapımı atölyesinde harika eserler ortaya çıktı!',
|
||||||
|
type: 'culture',
|
||||||
|
date: new Date('2025-05-12'),
|
||||||
|
location: 'Ofis - Yaratıcı Alan',
|
||||||
|
organizer: mockEmployees[1],
|
||||||
|
participants: 18,
|
||||||
|
photos: [
|
||||||
|
'https://images.unsplash.com/photo-1460661419201-fd4cecdf8a8b?w=800',
|
||||||
|
'https://images.unsplash.com/photo-1513364776144-60967b0f800f?w=800',
|
||||||
|
'https://images.unsplash.com/photo-1515405295579-ba7b45403062?w=800',
|
||||||
|
],
|
||||||
|
comments: [
|
||||||
|
{
|
||||||
|
id: 'c9',
|
||||||
|
author: mockEmployees[3],
|
||||||
|
content: 'İlk defa ebru yaptım, çok huzurlu bir deneyimdi 🎨',
|
||||||
|
creationTime: new Date('2025-05-13T09:15:00'),
|
||||||
|
likes: 11,
|
||||||
|
},
|
||||||
|
],
|
||||||
|
likes: 22,
|
||||||
|
isPublished: true,
|
||||||
|
},
|
||||||
|
]
|
||||||
|
|
||||||
|
export const mockVisitors: Visitor[] = [
|
||||||
|
{
|
||||||
|
id: 'vis1',
|
||||||
|
fullName: 'Ali Veli',
|
||||||
|
company: 'ABC Teknoloji',
|
||||||
|
email: 'ali.veli@abc.com',
|
||||||
|
phone: '+90 532 111 22 33',
|
||||||
|
visitDate: new Date('2025-10-25T10:00:00'),
|
||||||
|
checkIn: new Date('2025-10-25T10:15:00'),
|
||||||
|
host: mockEmployees[1],
|
||||||
|
purpose: 'İş Ortaklığı Görüşmesi',
|
||||||
|
status: 'checked-in',
|
||||||
|
badgeNumber: 'V-001',
|
||||||
|
photo: 'https://i.pravatar.cc/150?img=60',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 'vis2',
|
||||||
|
fullName: 'Fatma Yıldız',
|
||||||
|
company: 'XYZ Danışmanlık',
|
||||||
|
email: 'fatma@xyz.com',
|
||||||
|
phone: '+90 533 222 33 44',
|
||||||
|
visitDate: new Date('2024-10-21T14:00:00'),
|
||||||
|
host: mockEmployees[2],
|
||||||
|
purpose: 'Eğitim Danışmanlığı',
|
||||||
|
status: 'scheduled',
|
||||||
|
photo: 'https://i.pravatar.cc/150?img=47',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 'vis3',
|
||||||
|
fullName: 'Mehmet Kara',
|
||||||
|
company: 'DEF Yazılım',
|
||||||
|
email: 'mehmet@def.com',
|
||||||
|
phone: '+90 534 333 44 55',
|
||||||
|
visitDate: new Date('2024-10-18T11:00:00'),
|
||||||
|
checkIn: new Date('2024-10-18T11:05:00'),
|
||||||
|
checkOut: new Date('2024-10-18T13:30:00'),
|
||||||
|
host: mockEmployees[3],
|
||||||
|
purpose: 'Teknik Sunum',
|
||||||
|
status: 'checked-out',
|
||||||
|
badgeNumber: 'V-002',
|
||||||
|
photo: 'https://i.pravatar.cc/150?img=68',
|
||||||
|
},
|
||||||
]
|
]
|
||||||
Loading…
Reference in a new issue