fix cargo teleporter (#27255)
* fix cargo teleporter * don't delete orders * basado
This commit is contained in:
@@ -1,47 +1,55 @@
|
||||
using Robust.Shared.Serialization;
|
||||
using Content.Shared.Access.Components;
|
||||
using System.Text;
|
||||
namespace Content.Shared.Cargo
|
||||
{
|
||||
[NetSerializable, Serializable]
|
||||
public sealed class CargoOrderData
|
||||
[DataDefinition, NetSerializable, Serializable]
|
||||
public sealed partial class CargoOrderData
|
||||
{
|
||||
/// <summary>
|
||||
/// Price when the order was added.
|
||||
/// </summary>
|
||||
[DataField]
|
||||
public int Price;
|
||||
|
||||
/// <summary>
|
||||
/// A unique (arbitrary) ID which identifies this order.
|
||||
/// </summary>
|
||||
public readonly int OrderId;
|
||||
[DataField]
|
||||
public int OrderId { get; private set; }
|
||||
|
||||
/// <summary>
|
||||
/// Prototype Id for the item to be created
|
||||
/// </summary>
|
||||
public readonly string ProductId;
|
||||
[DataField]
|
||||
public string ProductId { get; private set; }
|
||||
|
||||
/// <summary>
|
||||
/// Prototype Name
|
||||
/// </summary>
|
||||
public readonly string ProductName;
|
||||
[DataField]
|
||||
public string ProductName { get; private set; }
|
||||
|
||||
/// <summary>
|
||||
/// The number of items in the order. Not readonly, as it might change
|
||||
/// due to caps on the amount of orders that can be placed.
|
||||
/// </summary>
|
||||
[DataField]
|
||||
public int OrderQuantity;
|
||||
|
||||
/// <summary>
|
||||
/// How many instances of this order that we've already dispatched
|
||||
/// </summary>
|
||||
[DataField]
|
||||
public int NumDispatched = 0;
|
||||
|
||||
public readonly string Requester;
|
||||
[DataField]
|
||||
public string Requester { get; private set; }
|
||||
// public String RequesterRank; // TODO Figure out how to get Character ID card data
|
||||
// public int RequesterId;
|
||||
public readonly string Reason;
|
||||
[DataField]
|
||||
public string Reason { get; private set; }
|
||||
public bool Approved => Approver is not null;
|
||||
[DataField]
|
||||
public string? Approver;
|
||||
|
||||
public CargoOrderData(int orderId, string productId, string productName, int price, int amount, string requester, string reason)
|
||||
|
||||
Reference in New Issue
Block a user