using bizFacade;
using MesServerWork;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace MesServerFunctions
{
    partial class FunctionMES
    {
        /// <summary>
        /// MES保存实时质量数据
        /// </summary>
        /// <param name="OpName"></param>
        /// <param name="tagValue"></param>
        private void MesSaveNowData(object e)
        {
            try
            {
                DoWhatPlc.CustomeEvetnArgs msgEvent = (DoWhatPlc.CustomeEvetnArgs)e;
                string OpName = Convert.ToString(msgEvent.OpName);
                int tagValue = Convert.ToInt32(msgEvent.TagValue);

                // 保存质量数据
                MisDataSaveDateMesRead.Funtion.MesRead(OpName, tagValue.ToString(), msgEvent.TagID.ToString());
            }
            catch (Exception err)
            {
                ////ApplicationLog.WriteLog(err, "Function02:FalseGO");
            }
        }
    }
}
