Example #1
0
        //从数据行中读取数据到TuiQinPlan中
        public static void EndworkFromDB(TuiQinPlan Plan, DataRow dr)
        {
            TrainPlanFromDB(Plan.trainPlan, dr);
            GroupFromDB(Plan.tuiqinGroup.group, dr);
            Plan.beginWorkTime = Plan.trainPlan.kaiCheTime.ToString("yyyy-MM-dd HH:mm:ss");
            //Plan.tuiqinGroup.isOver = dr["bIsOver"].ToString();
            //Plan.tuiqinGroup.signed = dr["bSigned"].ToString();
            Plan.tuiqinGroup.testAlcoholInfo1.testAlcoholResult = TFParse.DBToInt(dr["nDrinkResult1"], 0);
            Plan.tuiqinGroup.testAlcoholInfo1.testTime          = TFParse.DBToDateTime(dr["dtTestTime1"], DateTime.Parse("1899-01-01")).ToString("yyyy-MM-dd HH:mm:ss");
            //Plan.tuiqinGroup.testAlcoholInfo1.picture = dr["Picture1"].ToString();
            Plan.tuiqinGroup.testAlcoholInfo2.testAlcoholResult = TFParse.DBToInt(dr["nDrinkResult2"], 0);
            Plan.tuiqinGroup.testAlcoholInfo2.testTime          = TFParse.DBToDateTime(dr["dtTestTime2"], DateTime.Parse("1899-01-01")).ToString("yyyy-MM-dd HH:mm:ss");
            //Plan.tuiqinGroup.testAlcoholInfo2.picture = dr["Picture2"].ToString();
            Plan.tuiqinGroup.testAlcoholInfo3.testAlcoholResult = TFParse.DBToInt(dr["nDrinkResult3"], 0);
            Plan.tuiqinGroup.testAlcoholInfo3.testTime          = TFParse.DBToDateTime(dr["dtTestTime3"], DateTime.Parse("1899-01-01")).ToString("yyyy-MM-dd HH:mm:ss");
            //Plan.tuiqinGroup.testAlcoholInfo3.picture = dr["Picture3"].ToString();
            Plan.tuiqinGroup.testAlcoholInfo4.testAlcoholResult = TFParse.DBToInt(dr["nDrinkResult4"], 0);
            Plan.tuiqinGroup.testAlcoholInfo4.testTime          = TFParse.DBToDateTime(dr["dtTestTime4"], DateTime.Parse("1899-01-01")).ToString("yyyy-MM-dd HH:mm:ss");
            //Plan.tuiqinGroup.testAlcoholInfo4.picture = dr["Picture4"].ToString();

            //Plan.tuiqinGroup.turnAlarmMinutes = dr["nTurnAlarmMinutes"].ToString();
            //Plan.tuiqinGroup.turnMinutes = dr["nTurnMinutes"].ToString() ;
            //Plan.tuiqinGroup.turnStartTime = TFParse.DBToDateTime(dr["dtTurnStartTime"], DateTime.Parse("1899-01-01")).ToString("yyyy-MM-dd HH:mm:ss");
            Plan.tuiqinGroup.verifyID1 = TFParse.DBToInt(dr["nVerifyID1"].ToString(), 0);
            Plan.tuiqinGroup.verifyID2 = TFParse.DBToInt(dr["nVerifyID2"].ToString(), 0);
            Plan.tuiqinGroup.verifyID3 = TFParse.DBToInt(dr["nVerifyID3"].ToString(), 0);
            Plan.tuiqinGroup.verifyID4 = TFParse.DBToInt(dr["nVerifyID4"].ToString(), 0);
        }
Example #2
0
 //从数据行中读取数据到NamedGroup中
 public static void OrderGroupFromDB(TF.RunSafty.NamePlate.MD.OrderGroup group, DataRow dr)
 {
     GroupFromDB(group.group, dr);
     group.lastArriveTime   = TFParse.DBToDateTime(dr["dtLastArriveTime"], DateTime.Parse("1899-01-01")).ToString("yyyy-MM-dd HH:mm:Ss");
     group.orderID          = dr["strOrderGUID"].ToString();
     group.trainmanjiaoluID = dr["strTrainmanJiaoluGUID"].ToString();
     group.order            = TFParse.DBToInt(dr["nOrder"], 0);
 }
Example #3
0
 public static void MealTicketRuleFromDB(MealTicketRule Rule, DataRow DR)
 {
     Rule.strName         = DR["strName"].ToString();
     Rule.strGUID         = DR["strGUID"].ToString();
     Rule.strWorkShopGUID = DR["strWorkShopGUID"].ToString();
     Rule.iA    = TFParse.DBToInt(DR["iA"], 0);
     Rule.iB    = TFParse.DBToInt(DR["iB"], 0);
     Rule.iType = TFParse.DBToInt(DR["iType"], 0);
 }
Example #4
0
 //从数据行中读取数据到NamedGroup中
 public static void NamedGroupFromDB(RRsNamedGroup group, DataRow dr)
 {
     GroupFromDB(group.Group, dr);
     group.dtLastArriveTime      = TFParse.DBToDateTime(dr["dtLastArriveTime"], DateTime.Parse("1899-01-01"));
     group.strCheciGUID          = dr["strCheciGUID"].ToString();
     group.strTrainmanJiaoluGUID = dr["strTrainmanJiaoluGUID"].ToString();
     group.nCheciOrder           = TFParse.DBToInt(dr["nCheciOrder"], 0);
     group.nCheciType            = TFParse.DBToInt(dr["nCheciType"], 0);
     group.strCheci1             = dr["strCheci1"].ToString();
     group.strCheci2             = dr["strCheci2"].ToString();
 }
Example #5
0
 public static void MealTicketCheciFromDB(MealTicketCheCi Rule, DataRow DR)
 {
     Rule.strWorkShopGUID = DR["strWorkShopGUID"].ToString();
     Rule.iType           = TFParse.DBToInt(DR["iType"], 0);
     Rule.strQuDuan       = DR["strQuDuan"].ToString();
     Rule.strRuleGUID     = DR["strRuleGUID"].ToString();
     Rule.strGUID         = DR["strGUID"].ToString();
     Rule.strCheCi        = DR["strCheCi"].ToString();
     Rule.dtStartTime     = TFParse.DBToDateTime(DR["dtStartTime"], DateTime.Parse("1899-01-01"));
     Rule.dtEndTime       = TFParse.DBToDateTime(DR["dtEndTime"], DateTime.Parse("1899-01-01"));
 }
Example #6
0
        //从数据行中读取数据到TrainPlan中
        public static void TrainPlanFromDB(TrainPlan Plan, DataRow dr)
        {
            Plan.createSiteGUID = dr["strCreateSiteGUID"].ToString();
            Plan.createSiteName = dr["strCreateSiteName"].ToString();
            Plan.createTime     = TFParse.DBToDateTime(dr["dtCreateTime"], DateTime.Parse("1899-01-01"));
            Plan.createUserGUID = dr["strCreateUserGUID"].ToString();
            Plan.createUserName = dr["strCreateUserName"].ToString();

            Plan.dragTypeID     = dr["nDragType"].ToString();
            Plan.dragTypeName   = dr["nDragTypeName"].ToString();
            Plan.endStationID   = dr["strEndStation"].ToString();
            Plan.endStationName = dr["strEndStationName"].ToString();
            Plan.firstStartTime = TFParse.DBToDateTime(dr["dtFirstStartTime"], DateTime.Parse("1899-01-01"));

            Plan.kaiCheTime     = TFParse.DBToDateTime(dr["dtChuQinTime"], DateTime.Parse("1899-01-01"));
            Plan.kehuoID        = dr["nKehuoID"].ToString();
            Plan.kehuoName      = dr["strKehuoName"].ToString();
            Plan.lastArriveTime = TFParse.DBToDateTime(dr["dtLastArriveTime"], DateTime.Parse("1899-01-01"));
            Plan.mainPlanGUID   = dr["strMainPlanGUID"].ToString();

            Plan.placeID       = dr["strPlaceID"].ToString();
            Plan.placeName     = dr["strPlaceName"].ToString();
            Plan.planID        = dr["strTrainPlanGUID"].ToString();
            Plan.planStateID   = TFParse.DBToInt(dr["nPlanState"], 0);
            Plan.planStateName = dr["strPlanStateName"].ToString();

            Plan.planTypeID     = dr["nPlanType"].ToString();
            Plan.planTypeName   = dr["strPlanTypeName"].ToString();
            Plan.realStartTime  = TFParse.DBToDateTime(dr["dtRealStartTime"], DateTime.Parse("1899-01-01"));
            Plan.remarkTypeID   = dr["nRemarkType"].ToString();
            Plan.remarkTypeName = dr["strRemarkTypeName"].ToString();

            Plan.startStationID   = dr["strStartStation"].ToString();
            Plan.startStationName = dr["strStartStationName"].ToString();
            Plan.startTime        = TFParse.DBToDateTime(dr["dtStartTime"], DateTime.Parse("1899-01-01"));
            Plan.strRemark        = dr["strRemark"].ToString();
            Plan.strTrainPlanGUID = dr["strTrainPlanGUID"].ToString();

            Plan.trainJiaoluGUID  = dr["strTrainJiaoluGUID"].ToString();
            Plan.trainJiaoluName  = dr["strTrainJiaoluName"].ToString();
            Plan.trainmanTypeID   = dr["nTrainmanTypeID"].ToString();
            Plan.trainmanTypeName = dr["strTrainmanTypeName"].ToString();
            Plan.trainNo          = dr["strTrainNo"].ToString();

            Plan.trainNumber   = dr["strTrainNumber"].ToString();
            Plan.trainTypeName = dr["strTrainTypeName"].ToString();
        }
Example #7
0
        //
        public static void BeginworkFromDB(ChuQinPlan Plan, DataRow dr)
        {
            TrainPlanFromDB(Plan.trainPlan, dr);
            GroupFromDB(Plan.chuqinGroup.group, dr);
            Plan.chuqinGroup.verifyID1 = TFParse.DBToInt(dr["nVerifyID1"], 0);
            Plan.chuqinGroup.testAlcoholInfo1.testAlcoholResult = TFParse.DBToInt(dr["nDrinkResult1"], 0);
            Plan.chuqinGroup.testAlcoholInfo1.testTime          = TFParse.DBToDateTime(dr["dtTestTime1"], DateTime.Parse("1899-01-01")).ToString("yyyy-MM-dd HH:mm:ss");

            Plan.chuqinGroup.verifyID2 = TFParse.DBToInt(dr["nVerifyID2"], 0);
            Plan.chuqinGroup.testAlcoholInfo2.testAlcoholResult = TFParse.DBToInt(dr["nDrinkResult2"], 0);
            Plan.chuqinGroup.testAlcoholInfo2.testTime          = TFParse.DBToDateTime(dr["dtTestTime2"], DateTime.Parse("1899-01-01")).ToString("yyyy-MM-dd HH:mm:ss");

            Plan.chuqinGroup.verifyID3 = TFParse.DBToInt(dr["nVerifyID3"], 0);
            Plan.chuqinGroup.testAlcoholInfo3.testAlcoholResult = TFParse.DBToInt(dr["nDrinkResult3"], 0);
            Plan.chuqinGroup.testAlcoholInfo3.testTime          = TFParse.DBToDateTime(dr["dtTestTime3"], DateTime.Parse("1899-01-01")).ToString("yyyy-MM-dd HH:mm:ss");

            Plan.chuqinGroup.verifyID4 = TFParse.DBToInt(dr["nVerifyID4"], 0);
            Plan.chuqinGroup.testAlcoholInfo4.testAlcoholResult = TFParse.DBToInt(dr["nDrinkResult4"], 0);
            Plan.chuqinGroup.testAlcoholInfo4.testTime          = TFParse.DBToDateTime(dr["dtTestTime4"], DateTime.Parse("1899-01-01")).ToString("yyyy-MM-dd HH:mm:ss");
        }
Example #8
0
 //从数据行中读取数据到Rest中
 public static void RestFromDB(Rest rest, DataRow dr)
 {
     rest.dtArriveTime = TFParse.DBToDateTime(dr["dtArriveTime"], DateTime.Parse("1899-01-01"));
     rest.dtCallTime   = TFParse.DBToDateTime(dr["dtCallTime"], DateTime.Parse("1899-01-01"));
     rest.nNeedRest    = TFParse.DBToInt(dr["nNeedRest"], 0);
 }