48 lines
1.3 KiB
C#
48 lines
1.3 KiB
C#
using Step.Model.DatabaseModels;
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.ComponentModel.DataAnnotations;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
|
|
namespace Step.Model.DTOModels.ToolModels
|
|
{
|
|
public class DTONcMagazinePositionModel
|
|
{
|
|
public byte MagazineId { get; set; }
|
|
|
|
public int PositionId { get; set; }
|
|
|
|
[Required]
|
|
public bool Disabled { get; set; }
|
|
|
|
[Required]
|
|
public byte Type { get; set; }
|
|
|
|
public int? ShankId { get; set; }
|
|
|
|
public static explicit operator DTONcMagazinePositionModel(DbNcMagazinePositionModel obj)
|
|
{
|
|
return new DTONcMagazinePositionModel()
|
|
{
|
|
MagazineId = obj.MagazineId,
|
|
PositionId = obj.PositionId,
|
|
Disabled = obj.Disabled,
|
|
Type = obj.Type
|
|
};
|
|
}
|
|
|
|
public static explicit operator DbNcMagazinePositionModel(DTONcMagazinePositionModel obj)
|
|
{
|
|
return new DbNcMagazinePositionModel()
|
|
{
|
|
MagazineId = obj.MagazineId,
|
|
PositionId = obj.PositionId,
|
|
Disabled = obj.Disabled,
|
|
Type = obj.Type
|
|
};
|
|
}
|
|
}
|
|
}
|