2022-07-04 05:29:16 +05:00
|
|
|
|
using AsbCloudApp.Data.DailyReport;
|
2022-06-29 13:04:30 +05:00
|
|
|
|
using ClosedXML.Excel;
|
|
|
|
|
|
|
|
|
|
namespace AsbCloudInfrastructure.Services.DailyReport.DailyReportBlocks
|
|
|
|
|
{
|
2023-04-18 16:22:53 +05:00
|
|
|
|
|
2022-06-29 13:04:30 +05:00
|
|
|
|
internal class SignBlock : BlockAbstract
|
|
|
|
|
{
|
2022-07-25 18:02:39 +05:00
|
|
|
|
private readonly SignDto blockDto;
|
2022-06-29 13:04:30 +05:00
|
|
|
|
public CellAddress AddressDrillMasterHead { get; }
|
|
|
|
|
public CellAddress AddressDrillMaster { get; }
|
|
|
|
|
public CellAddress AddressSupervisorHead { get; }
|
|
|
|
|
public CellAddress AddressSupervisor { get; }
|
2022-06-30 16:01:46 +05:00
|
|
|
|
public override CellAddress AddressBlockBegin { get; }
|
2022-06-29 13:04:30 +05:00
|
|
|
|
public override CellAddress AddressBlockEnd { get; }
|
|
|
|
|
|
2022-07-25 18:02:39 +05:00
|
|
|
|
public SignBlock(CellAddress addressBlockBegin, SignDto blockDto)
|
2022-06-29 13:04:30 +05:00
|
|
|
|
{
|
|
|
|
|
AddressBlockBegin = addressBlockBegin.Copy();
|
|
|
|
|
this.blockDto = blockDto;
|
|
|
|
|
AddressDrillMasterHead = addressBlockBegin + (3, 0);
|
2022-07-06 09:21:35 +05:00
|
|
|
|
AddressDrillMaster = AddressDrillMasterHead + (0, 5);
|
2022-06-29 13:04:30 +05:00
|
|
|
|
AddressSupervisorHead = AddressDrillMasterHead + (2, 0);
|
2022-07-06 09:21:35 +05:00
|
|
|
|
AddressSupervisor = AddressSupervisorHead + (0, 5);
|
2022-06-29 13:04:30 +05:00
|
|
|
|
AddressBlockEnd = AddressSupervisor + (0,1);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public override void Draw(IXLWorksheet sheet)
|
|
|
|
|
{
|
2022-07-06 09:21:35 +05:00
|
|
|
|
sheet.Range(AddressDrillMasterHead.RowNumber, AddressDrillMasterHead.ColumnNumber
|
|
|
|
|
, AddressDrillMasterHead.RowNumber, AddressDrillMasterHead.ColumnNumber + 2)
|
|
|
|
|
.Merge()
|
|
|
|
|
.SetValue("Мастер буровой ");
|
|
|
|
|
sheet.Range(AddressDrillMaster.RowNumber, AddressDrillMaster.ColumnNumber
|
|
|
|
|
, AddressDrillMaster.RowNumber, AddressDrillMaster.ColumnNumber + 2)
|
|
|
|
|
.Merge()
|
|
|
|
|
.SetValue($"{blockDto.DrillingMaster}");
|
|
|
|
|
sheet.Range(AddressSupervisorHead.RowNumber, AddressSupervisorHead.ColumnNumber
|
|
|
|
|
, AddressSupervisorHead.RowNumber, AddressSupervisorHead.ColumnNumber + 2)
|
|
|
|
|
.Merge()
|
|
|
|
|
.SetValue("Супервайзер ");
|
|
|
|
|
sheet.Range(AddressSupervisor.RowNumber, AddressSupervisor.ColumnNumber
|
|
|
|
|
, AddressSupervisor.RowNumber, AddressSupervisor.ColumnNumber + 2)
|
|
|
|
|
.Merge()
|
|
|
|
|
.SetValue($"{blockDto.Supervisor}");
|
2022-06-29 13:04:30 +05:00
|
|
|
|
}
|
|
|
|
|
}
|
2023-04-18 16:22:53 +05:00
|
|
|
|
|
2022-06-29 13:04:30 +05:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|