public List<ListViewModel> GetAll() { //buscar na api do github List<Take> take = _repository.GetAll(); var mySelect = MySelect.myselect(take); return mySelect; }
/// <summary> /// 房间联动餐桌 /// </summary> /// <param name="roomID">房间ID</param> /// <returns></returns> public JsonResult GetTableList(string roomID) { var res = new JsonResult(); var list = MySelect.getTable(roomID); res.Data = list; res.JsonRequestBehavior = JsonRequestBehavior.AllowGet; return(res); }
public void TestModulo() { byte result = 0x00; MySelect sel = MySelect.Quad; bool b2 = ((byte)sel & (1 << 2)) != 0; bool b1 = ((byte)sel & (1 << 1)) != 0; bool b0 = ((byte)sel & (1 << 0)) != 0; SetBit(b2, 2, ref result); SetBit(b1, 1, ref result); SetBit(b0, 0, ref result); Debug.Print(result.ToString()); }
public ActionResult OmOrOperationDetail() { ViewBag.ddlRoom = MySelect.ToSelectOrigin(MySelect.getRoom(ShopId), "", "选择房间"); return(View()); }
protected override void OnPageLoad() { base.OnPageLoad(); ErrorLog("Load plugin"); // set actions //GUIGraphicsContext.OnNewAction -= ah; GUIGraphicsContext.OnNewAction += ah; // disable exclusive mode Log.Info("DBox2 plugin: Disabling DX9 exclusive mode"); GUIMessage msg = new GUIMessage(GUIMessage.MessageType.GUI_MSG_SWITCH_FULL_WINDOWED, 0, 0, 0, 0, 0, null); GUIWindowManager.SendMessage(msg); // init record fields GUIPropertyManager.SetProperty("#Dbox.Record.channel", " "); GUIPropertyManager.SetProperty("#Dbox.Record.title", " "); GUIPropertyManager.SetProperty("#Dbox.Record.start", " "); GUIPropertyManager.SetProperty("#Dbox.Record.stop", " "); #region set timer // start update ticker _Update.Interval = 2000; _Update.Tick += new EventHandler(_Update_Tick); _Update.Start(); // start OSD ticker _OSDTimer.Interval = 1000; _OSDTimer.Tick += new EventHandler(_OSDTimer_Tick); _OSDTimer.Start(); #endregion //set video window position if (videoWindow != null) { GUIGraphicsContext.VideoWindow = new Rectangle(videoWindow.XPosition, videoWindow.YPosition, videoWindow.Width, videoWindow.Height); } // TV is off btnTVOnOff.Selected = false; #region init vlc // close last instance if (vlcControl != null) vlcControl = null; // SaveDir exits ? if (!Directory.Exists(RecDir)) Directory.CreateDirectory(RecDir); if (!Directory.Exists(SnapDir)) Directory.CreateDirectory(SnapDir); // new instance vlcControl = new VideoLanControl(); vlcControl = VideoLanControl.Instance; // control is now visible vlcControl.Visible = false; vlcControl.Enabled = false; // add control to GUI GUIGraphicsContext.form.Controls.Add(vlcControl); // set focus GUIGraphicsContext.form.Focus(); #endregion #region init osd // prepare osd if (osd == null) { osd = new MyOSD(); osd.Visible = false; GUIGraphicsContext.form.Controls.Add(osd); GUIGraphicsContext.form.Focus(); } // prepare select if (sel == null) { sel = new MySelect(); sel.Visible = false; GUIGraphicsContext.form.Controls.Add(sel); GUIGraphicsContext.form.Focus(); } if (info == null) { info = new MyOSD_Info(); info.Visible = false; GUIGraphicsContext.form.Controls.Add(info); GUIGraphicsContext.form.Focus(); } if (chan == null) { chan = new MyOSD_Chan(_TV_Bouquets); chan.Visible = false; GUIGraphicsContext.form.Controls.Add(chan); GUIGraphicsContext.form.Focus(); } #endregion // init channel display chan.DisplayBouq(ActBouquetNo.ToString(), "1"); // set windows SetWindows(); //Disable program & timeshift for now GUIControl.DisableControl(GetID, 2); GUIControl.DisableControl(GetID, 9); //focus on/off GUIControl.FocusControl(GetID, 8); // set localized labels for static controls GUIPropertyManager.SetProperty("#header_label", Mydbox.GUILocalizeStrings.Get(0)); // MyDreamDboxTV GUIControl.SetControlLabel(GetID, btnTVGuide.GetID, Mydbox.GUILocalizeStrings.Get(600)); // Program GUIControl.SetControlLabel(GetID, btnRecord.GetID, Mydbox.GUILocalizeStrings.Get(601)); // Record GUIControl.SetControlLabel(GetID, btnSnap.GetID, Mydbox.GUILocalizeStrings.Get(602)); // Snapshot GUIControl.SetControlLabel(GetID, btnBouquet.GetID, Mydbox.GUILocalizeStrings.Get(603)); // Group GUIControl.SetControlLabel(GetID, btnChannel.GetID, Mydbox.GUILocalizeStrings.Get(604)); // Channel GUIControl.SetControlLabel(GetID, btnTVOnOff.GetID, Mydbox.GUILocalizeStrings.Get(605)); //On/Off GUIControl.SetControlLabel(GetID, btnShiftOnOff.GetID, Mydbox.GUILocalizeStrings.Get(606)); // Shift GUIControl.SetControlLabel(GetID, btnRecordings.GetID, Mydbox.GUILocalizeStrings.Get(607)); // Recordings GUIControl.SetControlLabel(GetID, btnWhatsThis.GetID, Mydbox.GUILocalizeStrings.Get(608)); // Whats .. if (AutoOn == "yes") { _isFullScreen = true; SetWindows(); btnTVOnOff.Selected = true; AutoOn = "no"; PlayCurrentChannel(); } EPG_Thread = new System.Threading.Thread(new System.Threading.ThreadStart(EPG_Refresh)); EPG_Thread.Start(); System.Threading.Thread.Sleep(0); }