コード例 #1
0
 /// <summary>
 ///     上班
 /// </summary>
 public static void StartWork(SimulatorBase sender, CheckpointArgs args)
 {
     ((Staff)sender).IsWorking = true;
     StaffSQLController.CheckSql((Staff)sender, true);
     Debug.WriteLine(((Staff)sender).StaffName + "上班!");
     SimulatorTimer.SpeedSetNormal();
 }
コード例 #2
0
        /// <summary>
        ///     下班
        /// </summary>
        public static void QuitWork(SimulatorBase sender, CheckpointArgs args)
        {
            var staff = (Staff)sender;

            staff.IsWorking = false;
            StaffSQLController.CheckSql(staff, false);

            Debug.WriteLine(((Staff)sender).StaffName + "下班!");
            if (staff.StaffStudioObject.FindWorkingStaffs().Count == 0)
            {
                SimulatorTimer.SpeedSetQuick();
            }
        }