public StudioGridView(BsonDocument Detail, IPageStudio PageStudio) { InitializeComponent(); TextCreatedTime.Text = Detail["Created"].ToLocalTime().ToString(); TextStudio.Text = Detail["Name"].ToString(); TextType.Text = Detail["Type"].ToString(); TextUniqeID.Text = Detail["Token"].ToString(); TextTokenCreator.Text = Detail["Creator"].ToString(); TextDatabase.Text = Detail["Database"].ToString(); //open main page MouseDown += (s, e) => { SettingUser.CurentDetailStudio = Detail; PageAUT.Placeholder.Children.Add(new MainPage()); PageStudio.ChangeVisibility(false); }; }
public SubPageAddNewStudio(IPageStudio PageStudio) { InitializeComponent(); //action btn close BTNClose.MouseDown += (s, e) => { ShowPage(0, () => { Visibility = Visibility.Collapsed; }); }; //Actin btn add new Studio BTNAdd.Worker += () => { if (InputNameStudio.Text.Length >= 5) { SDK.SDK_PageDashboards.DashboardGame.PageStudios.CreatStudio(InputNameStudio.Text, Result => { if (Result) { Debug.WriteLine("Created"); Visibility = Visibility.Collapsed; PageStudio.InitStudios(); } else { Debug.WriteLine("NotCreated"); } }); } else { Debug.WriteLine("Input Name Studio Short"); } }; }