Adding initial auction system
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
using MongoDB.Bson;
|
||||
using MongoDB.Bson.Serialization.Attributes;
|
||||
|
||||
namespace GameAuthApi.Models;
|
||||
|
||||
public class Auction
|
||||
{
|
||||
[BsonId]
|
||||
[BsonRepresentation(BsonType.ObjectId)]
|
||||
public string Id { get; set; }
|
||||
|
||||
[BsonRepresentation(BsonType.ObjectId)]
|
||||
public string ItemId { get; set; }
|
||||
|
||||
[BsonRepresentation(BsonType.ObjectId)]
|
||||
public string SellerPlayerId { get; set; }
|
||||
|
||||
[BsonRepresentation(BsonType.ObjectId)]
|
||||
public string HighestBidderId { get; set; }
|
||||
|
||||
public int StartingPrice { get; set; }
|
||||
public int CurrentPrice { get; set; }
|
||||
public bool IsClosed { get; set; } = false;
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
namespace GameAuthApi.Models;
|
||||
|
||||
public class BidRequest
|
||||
{
|
||||
public string AuctionId { get; set; }
|
||||
public int BidAmount { get; set; }
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
namespace GameAuthApi.Models;
|
||||
|
||||
public class CreateAuctionRequest
|
||||
{
|
||||
public string ItemId { get; set; }
|
||||
public int StartingPrice { get; set; }
|
||||
}
|
||||
Reference in New Issue
Block a user