Exemple #1
0
 public void Configure(EntityTypeBuilder <RequestPlayer> builder)
 {
     builder.ToTable("request_players");
     builder.Property(o => o.Id).HasSnakeCaseColumnName();
     builder.Property(o => o.PlayerId).HasSnakeCaseColumnName();
     builder.Property(o => o.TeamId).HasSnakeCaseColumnName();
     builder.Property(o => o.SeasonId).HasSnakeCaseColumnName();
     builder.Property(o => o.ReservationNumber)
     .HasConversion(o => o.Value, o => ReservationNumber.FromValue(o))
     .HasSnakeCaseColumnName();
     builder.Property(o => o.ReservationBranchNumber).HasSnakeCaseColumnName();
     builder.Property(o => o.Category)
     .HasSnakeCaseColumnName()
     .HasEnumerationConversion();
     builder.Property(o => o.RequestType)
     .HasSnakeCaseColumnName()
     .HasEnumerationConversion();
     builder.Property(o => o.ApproveState)
     .HasSnakeCaseColumnName()
     .HasEnumerationConversion();
     builder.Property(o => o.RequestedDateTime).HasSnakeCaseColumnName();
     builder.Property(o => o.PlayerRegistrationFee)
     .HasConversion(o => o.Value, o => new PlayerRegistrationFee(o))
     .HasSnakeCaseColumnName();
     builder.Property(o => o.ApproveDateTime).HasSnakeCaseColumnName();
     builder.HasOne(o => o.Season);
     builder.HasOne(o => o.Team);
     builder.HasOne(o => o.Player);
 }
Exemple #2
0
 /// <summary>
 /// 登録選手の新しいインスタンスを生成します。
 /// </summary>
 /// <param name="playerId">選手id。</param>
 /// <param name="teamId">団体id。</param>
 /// <param name="seasonId">年度id。</param>
 /// <param name="reservationNumber">予約番号。</param>
 /// <param name="reservationBranchNumber">予約番号枝番。</param>
 /// <param name="category">カテゴリー。</param>
 /// <param name="requestType">申請種別。</param>
 /// <param name="approveState">受領状態。</param>
 /// <param name="requestedDateTime">申請受付日。</param>
 /// <param name="playerRegistrationFee">選手登録料。</param>
 /// <param name="approveDateTime">受領日。</param>
 public RequestPlayer(
     int playerId,
     int teamId,
     int seasonId,
     ReservationNumber reservationNumber,
     int reservationBranchNumber,
     Category category,
     RequestType requestType,
     ApproveState approveState,
     DateTime requestedDateTime,
     PlayerRegistrationFee playerRegistrationFee,
     DateTime?approveDateTime
     )
 {
     this.PlayerId                = playerId;
     this.TeamId                  = teamId;
     this.SeasonId                = seasonId;
     this.ReservationNumber       = reservationNumber;
     this.ReservationBranchNumber = reservationBranchNumber;
     this.Category                = category;
     this.RequestType             = requestType;
     this.ApproveState            = approveState;
     this.RequestedDateTime       = requestedDateTime;
     this.PlayerRegistrationFee   = playerRegistrationFee;
     this.ApproveDateTime         = approveDateTime;
 }
 public bool MatchesSearch(string querry)
 {
     if (UserName.ToLower().Contains(querry.ToLower()) || ReservationNumber.Contains(querry.ToLower()))
     {
         return(true);
     }
     return(false);
 }
    private Reservation(
        ReservationId id,
        SeatId seatId,
        CustomerId customerId,
        ReservationNumber reservationNumber
        )
    {
        var @event = new TentativeReservationCreated(
            id,
            seatId,
            customerId,
            reservationNumber
            );

        Enqueue(@event);
        Apply(@event);
    }
Exemple #5
0
 /// <summary>
 /// 登録団体の新しいインスタンスを生成します。
 /// </summary>
 /// <param name="teamId">団体id。</param>
 /// <param name="seasonId">年度id。</param>
 /// <param name="reservationNumber">予約番号。</param>
 /// <param name="approveState">受領状態。</param>
 /// <param name="requestedDateTime">申請受付日。</param>
 /// <param name="requestedFee">申請登録料。</param>
 /// <param name="approveDateTime">受領日。</param>
 /// <param name="mailState">メール送信状態。</param>
 public RequestTeam(
     int teamId,
     int seasonId,
     ReservationNumber reservationNumber,
     ApproveState approveState,
     DateTime requestedDateTime,
     RequestedFee requestedFee,
     DateTime?approveDateTime,
     MailState mailState
     )
 {
     this.TeamId            = teamId;
     this.SeasonId          = seasonId;
     this.ReservationNumber = reservationNumber;
     this.ApproveState      = approveState;
     this.RequestedDateTime = requestedDateTime;
     this.RequestedFee      = requestedFee;
     this.ApproveDateTime   = approveDateTime;
     this.MailState         = mailState;
 }
Exemple #6
0
 public void Configure(EntityTypeBuilder <RequestTeam> builder)
 {
     builder.ToTable("request_teams");
     builder.Property(o => o.Id).HasSnakeCaseColumnName();
     builder.Property(o => o.TeamId).HasSnakeCaseColumnName();
     builder.Property(o => o.SeasonId).HasSnakeCaseColumnName();
     builder.Property(o => o.ReservationNumber)
     .HasConversion(o => o.Value, o => ReservationNumber.FromValue(o))
     .HasSnakeCaseColumnName();
     builder.Property(o => o.ApproveState)
     .HasSnakeCaseColumnName()
     .HasEnumerationConversion();
     builder.Property(o => o.RequestedDateTime).HasSnakeCaseColumnName();
     builder.Property(o => o.RequestedFee)
     .HasConversion(o => o.Value, o => new RequestedFee(o))
     .HasSnakeCaseColumnName();
     builder.Property(o => o.ApproveDateTime).HasSnakeCaseColumnName();
     builder.Property(o => o.MailState)
     .HasSnakeCaseColumnName()
     .HasEnumerationConversion();
     builder.HasOne(o => o.Season);
     builder.HasOne(o => o.Team);
 }