using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ProjectManagementSystem.Model.Models
{
    public class ScaleWeightData
    {
        public string companyCode { get; set; }
        public string billNo { get; set; }
        public string batchNo { get; set; }
        public string carNo { get; set; }
        public double grossWeight { get; set; }
        public double netWeight { get; set; }
        public string scaleName { get; set; }
        public string recordTime { get; set; }
        public string recordPeopleCode { get; set; }
        public string recordPeopleName { get; set; }
        public string remarks { get; set; }

        [JsonIgnore]
        public int Status { get; set; }
        [JsonIgnore]
        public DateTime LastUpdateTime { get; set; }
        [JsonIgnore]
        public bool DataValid
        {
            get { return (DateTime.Now - LastUpdateTime).TotalSeconds < 5; }
        }
    }
}

