Example #1
0
        private int meSerial;  //报文ID

        public CTask()
        {
            meDetail      = EnmTaskStatusDetail.NoSend;
            meCreateDtime = CObject.DefDatetime;
            meSendDtime   = CObject.DefDatetime;
            meFinishDtime = CObject.DefDatetime;
            meSerial      = 0; //暂时不用的
        }
Example #2
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="detail"></param>
        /// <returns></returns>
        public static string ConvertSendStateDetail(EnmTaskStatusDetail detail)
        {
            string msg = "";

            switch (detail)
            {
            case EnmTaskStatusDetail.NoSend:
                msg = "等待发送";
                break;

            case EnmTaskStatusDetail.SendWaitAsk:
                msg = "等待ACK";
                break;

            case EnmTaskStatusDetail.Asked:
                msg = "交互成功";
                break;

            default:
                msg = detail.ToString();
                break;
            }
            return(msg);
        }
Example #3
0
        /// <summary>
        /// 将作业状态转化为中文表示方式
        /// </summary>
        /// <param name="status"></param>
        /// <returns></returns>
        public static string ConvertTaskStatus(EnmTaskStatus status, EnmTaskStatusDetail detail)
        {
            string msg = "";

            #region
            switch (status)
            {
            case EnmTaskStatus.ICarInWaitFirstSwipeCard:
                msg = "有车入库";
                break;

            case EnmTaskStatus.IFirstSwipedWaitforCheckSize:
                msg = "刷第一次卡";
                break;

            case EnmTaskStatus.ISecondSwipedWaitforCheckSize:
                msg = "下发(1,9)";
                break;

            case EnmTaskStatus.ISecondSwipedWaitforEVDown:
                msg = "下发(1,1)";
                break;

            case EnmTaskStatus.ISecondSwipedWaitforCarLeave:
                msg = "等待车辆离开";
                break;

            case EnmTaskStatus.IEVDownFinished:
                msg = "确认入库";
                break;

            case EnmTaskStatus.IEVDownFinishing:
                msg = "下发(1,54)";
                break;

            case EnmTaskStatus.ICheckCarFail:
                msg = "检测失败";
                break;

            case EnmTaskStatus.IHallFinishing:
                msg = "下发(1,55)";
                break;

            case EnmTaskStatus.OWaitforEVDown:
                msg = "取车(3,1)";
                break;

            case EnmTaskStatus.OEVDownFinishing:
                msg = "下发(3,54)";
                break;

            case EnmTaskStatus.OEVDownWaitforTVLoad:
                msg = "等待TV卸载";
                break;

            case EnmTaskStatus.OWaitforEVUp:
                msg = "出车卸载完成";
                break;

            case EnmTaskStatus.OCarOutWaitforDriveaway:
                msg = "等待车辆离开";
                break;

            case EnmTaskStatus.OHallFinishing:
                msg = "车辆已驶出";
                break;

            case EnmTaskStatus.TempWaitforEVDown:
                msg = "取物(2,1)";
                break;

            case EnmTaskStatus.TempEVDownFinishing:
                msg = "下发(2,54)";
                break;

            case EnmTaskStatus.TempEVDownWaitforTVLoad:
                msg = "等待TV卸载";
                break;

            case EnmTaskStatus.TempWaitforEVUp:
                msg = "出车卸载完成";
                break;

            case EnmTaskStatus.TempOCarOutWaitforDrive:
                msg = "等待车辆离开";
                break;

            case EnmTaskStatus.TempHallFinishing:
                msg = "车辆已驶出";
                break;

            case EnmTaskStatus.Finished:
                msg = "作业完成";
                break;

            case EnmTaskStatus.TMURO:
                msg = "故障中";
                break;

            case EnmTaskStatus.TWaitforLoad:
                msg = "装载中";
                break;

            case EnmTaskStatus.TWaitforUnload:
                msg = "卸载中";
                break;

            case EnmTaskStatus.TWaitforMove:
                msg = "移动中";
                break;

            case EnmTaskStatus.LoadFinishing:
                msg = "装载完成";
                break;

            case EnmTaskStatus.UnLoadFinishing:
                msg = "卸载完成";
                break;

            case EnmTaskStatus.MoveFinishing:
                msg = "移动完成";
                break;

            case EnmTaskStatus.WillWaitForUnload:
                msg = "等待下发卸载";
                break;

            case EnmTaskStatus.TMUROWaitforLoad:
                msg = "MURO下发装载";
                break;

            case EnmTaskStatus.TMUROWaitforUnload:
                msg = "MURO下发卸载";
                break;

            case EnmTaskStatus.ReCheckInLoad:
                msg = "上报复检尺寸";
                break;

            case EnmTaskStatus.WaitforDeleteTask:
                msg = "删除指令";
                break;

            default:
                msg = status.ToString();
                break;
            }
            if (detail == EnmTaskStatusDetail.SendWaitAsk)
            {
                msg += ",等待ACK";
            }
            else if (detail == EnmTaskStatusDetail.Asked)
            {
                msg += ",收到ACK";
            }
            #endregion
            return(msg);
        }