32 lines
		
	
	
		
			1.0 KiB
		
	
	
	
		
			C#
		
	
	
	
	
	
			
		
		
	
	
			32 lines
		
	
	
		
			1.0 KiB
		
	
	
	
		
			C#
		
	
	
	
	
	
| namespace Adaptation.Shared.Metrology;
 | |
| 
 | |
| public partial class WS
 | |
| {
 | |
| 
 | |
|     public class Attachment
 | |
|     {
 | |
| 
 | |
| #nullable enable
 | |
| 
 | |
|         public long HeaderId { get; set; }
 | |
|         public string UniqueId { get; set; }
 | |
|         public string SubGroupId { get; set; }
 | |
|         public string AttachmentId { get; set; }
 | |
|         public string SourceFileName { get; set; }
 | |
|         public string HeaderIdDirectory { get; set; }
 | |
|         public string DestinationFileName { get; set; }
 | |
| 
 | |
|         public Attachment(Results? results, string headerIdDirectory, string uniqueId, string destinationFileName, string sourceFileName)
 | |
|         {
 | |
|             UniqueId = uniqueId;
 | |
|             SourceFileName = sourceFileName;
 | |
|             HeaderIdDirectory = headerIdDirectory;
 | |
|             DestinationFileName = destinationFileName;
 | |
|             AttachmentId = System.Guid.NewGuid().ToString();
 | |
|             HeaderId = results?.HeaderId is null ? -1 : results.HeaderId.Value;
 | |
|             SubGroupId = results?.SubgroupId is null ? string.Empty : results.SubgroupId.Value.ToString();
 | |
|         }
 | |
| 
 | |
|     }
 | |
| 
 | |
| } |