杨前锦
2025-07-01 a93b0e99036c24b9bd58c79bf5e7364b1ba28bae
HH.WCS.Mobox3/HH.WCS.Mobox3.FJJT/models/WCSTask.cs
New file
@@ -0,0 +1,63 @@
using HH.WCS.Mobox3.FJJT.models;
using SqlSugar;
using System;
namespace HH.WCS.Mobox3.FJJT {
    [SugarTable("TN_Task")]
    public class WCSTask : BaseModel {
        public string S_DATA { get; set; }
        public int N_SORT_NO { get; set; }
        public string S_START_AREA { get; set; }
        public string S_END_AREA { get; set; }
        public string S_START_LOC { get; set; }
        public string S_END_LOC { get; set; }
        public string S_NOTE { get; set; }
        public DateTime? T_START_TIME { get; set; }
        public DateTime? T_END_TIME { get; set; }
        public string S_EQ_NO { get; set; }
        public string S_TYPE { get; set; }
        public string S_B_STATE { get; set; } = "等待";
        /// <summary>
        /// 0等待   1已推送       2执行    3完成    4错误
        /// </summary>
        public int N_B_STATE { get; set; }
        public string S_START_WH { get; set; }
        public string S_END_WH { get; set; }
        public string S_START_SITE { get; set; }
        public int S_START_SITE_LAYER { get; set; }
        public string S_END_SITE { get; set; }
        public int S_END_SITE_LAYER { get; set; }
        /// <summary>
        ///0无 1NDC 2天目 3国自 4输送机 5立库
        /// </summary>
        public int N_SCHEDULE_TYPE { get; set; }
        public string S_SCHEDULE_TYPE { get; set; }
        public int N_TYPE { get; set; }
        public string S_FACTORY { get; set; }=util.Settings.FacCode;
        public int N_PRIORITY { get; set; }
        public string S_ERR { get; set; }
        public string S_OP_CODE { get; set; }
        public string S_CODE { get; set; }
        public int N_ERR { get; set; }
        public string S_EQ_TASK_CODE { get; set; }
        public string S_STATE_PRE { get; set; }
        public int N_REVIEW_RESULT { get; set; }
        public string S_CNTR_CODE { get; set; }
        public string S_OP_NAME { get; set; }
        internal static string GetStateStr(int state) {
            //0等待     1已推送       2执行    3完成    4错误
            var status = "";
            switch (state) {
                case 0: status = "等待"; break;
                case 1: status = "已推送"; break;
                case 2: status = "执行中"; break;
                case 3: status = "完成"; break;
                case 4: status = "错误"; break;
            }
            return status;
        }
    }
}