add duty-time and poi (จาก google maps ไปก่อน)
This commit is contained in:
parent
43932f742b
commit
78f8c0813c
30 changed files with 3395 additions and 4 deletions
27
BMA.EHR.Leave.Service/DTOs/DutyTime/CreateDutyTimeDto.cs
Normal file
27
BMA.EHR.Leave.Service/DTOs/DutyTime/CreateDutyTimeDto.cs
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
using Microsoft.EntityFrameworkCore;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace BMA.EHR.Command.Service.DTOs.DutyTime
|
||||
{
|
||||
public class CreateDutyTimeDto
|
||||
{
|
||||
|
||||
[Required, Comment("คำอธิบาย")]
|
||||
public string Description { get; set; } = string.Empty;
|
||||
|
||||
[Required, Comment("เวลาเข้างานช่วงเช้า")]
|
||||
public string StartTimeMorning { get; set; } = "00:00";
|
||||
|
||||
[Required, Comment("เวลาออกงานช่วงเช้า")]
|
||||
public string EndTimeMorning { get; set; } = "00:00";
|
||||
|
||||
[Required, Comment("เวลาเข้างานช่วงบ่าย")]
|
||||
public string StartTimeAfternoon { get; set; } = "00:00";
|
||||
|
||||
[Required, Comment("เวลาออกงานช่วงบ่าย")]
|
||||
public string EndTimeAfternoon { get; set; } = "00:00";
|
||||
|
||||
[Required, Comment("สถานะว่ารอบใดเป็นค่า Default ของข้าราชการ (สำหรับทุกคนที่ยังไม่ได้ทำการเลือกรอบ)")]
|
||||
public bool IsDefault { get; set; } = false;
|
||||
}
|
||||
}
|
||||
17
BMA.EHR.Leave.Service/DTOs/DutyTime/UpdateDutyTimeDto.cs
Normal file
17
BMA.EHR.Leave.Service/DTOs/DutyTime/UpdateDutyTimeDto.cs
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
using Microsoft.EntityFrameworkCore;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace BMA.EHR.Command.Service.DTOs.DutyTime
|
||||
{
|
||||
public class UpdateDutyTimeDto
|
||||
{
|
||||
[Required, Comment("คำอธิบาย")]
|
||||
public string Description { get; set; } = string.Empty;
|
||||
|
||||
[Required, Comment("สถานะว่ารอบใดเป็นค่า Default ของข้าราชการ (สำหรับทุกคนที่ยังไม่ได้ทำการเลือกรอบ)")]
|
||||
public bool IsDefault { get; set; } = false;
|
||||
|
||||
[Required, Comment("สถานะการเปิดใช้งาน (เปิด/ปิด)")]
|
||||
public bool IsActive { get; set; } = true;
|
||||
}
|
||||
}
|
||||
9
BMA.EHR.Leave.Service/DTOs/POI/GetPOIDto.cs
Normal file
9
BMA.EHR.Leave.Service/DTOs/POI/GetPOIDto.cs
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
namespace BMA.EHR.Command.Service.DTOs.POI
|
||||
{
|
||||
public class GetPOIDto
|
||||
{
|
||||
public double Lat { get; set; } = 0;
|
||||
|
||||
public double Lon { get; set; } = 0;
|
||||
}
|
||||
}
|
||||
28
BMA.EHR.Leave.Service/DTOs/POI/GetPOIResultDto.cs
Normal file
28
BMA.EHR.Leave.Service/DTOs/POI/GetPOIResultDto.cs
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
namespace BMA.EHR.Command.Service.DTOs.POI
|
||||
{
|
||||
public class GetPOIResultDto
|
||||
{
|
||||
public List<POIItem> results { get; set; } = new List<POIItem>();
|
||||
}
|
||||
|
||||
public class POIItem
|
||||
{
|
||||
public string place_id { get; set; } = string.Empty;
|
||||
|
||||
public string name { get; set; } = string.Empty;
|
||||
|
||||
public GeometryItem geometry { get; set; } = new();
|
||||
}
|
||||
|
||||
public class GeometryItem
|
||||
{
|
||||
public LocationItem location { get; set; } = new();
|
||||
}
|
||||
|
||||
public class LocationItem
|
||||
{
|
||||
public double lat { get; set; } = 0;
|
||||
|
||||
public double lng { get; set; } = 0;
|
||||
}
|
||||
}
|
||||
13
BMA.EHR.Leave.Service/DTOs/POI/POIResultDto.cs
Normal file
13
BMA.EHR.Leave.Service/DTOs/POI/POIResultDto.cs
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
namespace BMA.EHR.Command.Service.DTOs.POI
|
||||
{
|
||||
public class POIResultDto
|
||||
{
|
||||
public string Id { get; set; } = string.Empty;
|
||||
|
||||
public string Name { get; set; } = string.Empty;
|
||||
|
||||
public double Latitude { get; set; } = 0;
|
||||
|
||||
public double Longitude { get; set; } = 0;
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue