< Summary

Information
Class: OzonDomains.Models.TransactionTimeTrackingSession
Assembly: OzonDomains
File(s): /home/runner/work/Studio2Prod/Studio2Prod/OzonDomains/Models/TransactionTimeTrackingModels.cs
Line coverage
100%
Covered lines: 16
Uncovered lines: 0
Coverable lines: 16
Total lines: 90
Line coverage: 100%
Branch coverage
N/A
Covered branches: 0
Total branches: 0
Branch coverage: N/A
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
get_Id()100%11100%
get_TrackingKey()100%11100%
get_UserName()100%11100%
get_AccessProfileId()100%11100%
get_TransactionType()100%11100%
get_OrdersCountInitial()100%11100%
get_OrderIdsJson()100%11100%
get_StartedAtUtc()100%11100%
get_LastSeenAtUtc()100%11100%
get_IsCompleted()100%11100%
get_CompletedAtUtc()100%11100%
get_IsAbandoned()100%11100%
get_SourceUrl()100%11100%
get_ClientIp()100%11100%
get_UserAgent()100%11100%
get_CreatedAtUtc()100%11100%

File(s)

/home/runner/work/Studio2Prod/Studio2Prod/OzonDomains/Models/TransactionTimeTrackingModels.cs

#LineLine coverage
 1using System.ComponentModel.DataAnnotations;
 2using System.ComponentModel.DataAnnotations.Schema;
 3
 4namespace OzonDomains.Models;
 5
 6[Table("TransactionTimeTrackingSessions")]
 7public class TransactionTimeTrackingSession
 8{
 9    [Key]
 10    [DatabaseGenerated(DatabaseGeneratedOption.Identity)]
 911    public long Id { get; set; }
 12
 13    [Required]
 14    [MaxLength(64)]
 6915    public string TrackingKey { get; set; } = string.Empty;
 16
 17    [Required]
 18    [MaxLength(256)]
 7019    public string UserName { get; set; } = string.Empty;
 20
 2821    public int? AccessProfileId { get; set; }
 22
 23    [Required]
 24    [MaxLength(64)]
 7425    public string TransactionType { get; set; } = string.Empty;
 26
 2927    public int OrdersCountInitial { get; set; }
 28
 29    [Column(TypeName = "longtext")]
 2530    public string? OrderIdsJson { get; set; }
 31
 8132    public DateTime StartedAtUtc { get; set; } = DateTime.UtcNow;
 4533    public DateTime? LastSeenAtUtc { get; set; }
 4134    public bool IsCompleted { get; set; }
 1235    public DateTime? CompletedAtUtc { get; set; }
 5436    public bool IsAbandoned { get; set; }
 37
 38    [MaxLength(1000)]
 2339    public string? SourceUrl { get; set; }
 40
 41    [MaxLength(64)]
 2242    public string? ClientIp { get; set; }
 43
 44    [MaxLength(512)]
 2245    public string? UserAgent { get; set; }
 46
 5347    public DateTime CreatedAtUtc { get; set; } = DateTime.UtcNow;
 48}
 49
 50[Table("TransactionTimeTrackingResults")]
 51public class TransactionTimeTrackingResult
 52{
 53    [Key]
 54    [DatabaseGenerated(DatabaseGeneratedOption.Identity)]
 55    public long Id { get; set; }
 56
 57    public long? TrackingSessionId { get; set; }
 58
 59    [Required]
 60    [MaxLength(64)]
 61    public string TrackingKey { get; set; } = string.Empty;
 62
 63    [Required]
 64    [MaxLength(256)]
 65    public string UserName { get; set; } = string.Empty;
 66
 67    public int? AccessProfileId { get; set; }
 68
 69    [Required]
 70    [MaxLength(64)]
 71    public string TransactionType { get; set; } = string.Empty;
 72
 73    public int OrdersCountFinal { get; set; }
 74    public DateTime StartedAtUtc { get; set; }
 75    public DateTime CompletedAtUtc { get; set; }
 76    public int DurationSeconds { get; set; }
 77    public long TransactionId { get; set; }
 78
 79    [Required]
 80    [MaxLength(1000)]
 81    public string TransactionUrl { get; set; } = string.Empty;
 82
 83    [MaxLength(1000)]
 84    public string? Comment { get; set; }
 85
 86    public DateTime CreatedAtUtc { get; set; } = DateTime.UtcNow;
 87
 88    [ForeignKey(nameof(TrackingSessionId))]
 89    public virtual TransactionTimeTrackingSession? TrackingSession { get; set; }
 90}