using Edge.Core.Parser.BinaryParser.Attributes;
using System;
using System.Collections.Generic;
using System.Text;

namespace HengshanPaymentTerminal.MessageEntity.Outgoing
{
    /// <summary>
    /// 后台回复加油机灰卡查询之结果
    /// </summary>
    public class QueryGrayRecordResult : CardMessageBase
    {
        public QueryGrayRecordResult() : base(Command.GrayRecord)
        {

        }

        /// <summary>
        /// 0x00 = Match, other value = No Match
        /// </summary>
        [Format(1, EncodingType.BIN, -89)]
        public byte Match { get; set; }

        [Format(10, EncodingType.BcdString, -88)]
        public string Asn { get; set; }

        [Format(4, EncodingType.BIN, -87)]
        public int Balance { get; set; }

        //[Format(3, EncodingType.BIN, -86)]
        //public int Amount { get; set; }

        [Format(3, EncodingType.BIN, -85)]
        public int Amount1 { get; set; }

        [Format(2, EncodingType.BIN, -84)]
        public ushort Ctc { get; set; }

        [Format(7, EncodingType.BcdString, -83)]
        public string Time { get; set; }

        [Format(4, EncodingType.HexString, -82)]
        public string Gmac { get; set; }

        [Format(6, EncodingType.HexString, -81)]
        public string PsamTid { get; set; }

        [Format(4, EncodingType.BIN, -80)]
        public int PsamTtc { get; set; }

        [Format(3, EncodingType.BIN, -79)]
        public int Volume { get; set; }
    }
}
