Esempio n. 1
0
        private static void OptionOne(Gestor pObjGestor, UIMenuPrincipal pMenuP)
        {
            AdminPassword(pObjGestor, pMenuP);
            var rValues = pMenuP.RegisterDemo2();

            if (pObjGestor.ClientExists(int.Parse(rValues[0])) == false)
            {
                if (string.IsNullOrEmpty(rValues[4]))
                {
                    pObjGestor.RegisterMethodDemo(rValues[1], rValues[2], int.Parse(rValues[0]), int.Parse(rValues[3]), -1);
                }
                else
                {
                    pObjGestor.RegisterMethodDemo(rValues[1], rValues[2], int.Parse(rValues[0]), int.Parse(rValues[3]), double.Parse(rValues[4]));
                }
            }
            else
            {
                pObjGestor.SetUserInSesion(int.Parse(rValues[0]));
                if (string.IsNullOrEmpty(rValues[4]))
                {
                    pObjGestor.AddAccountDemo();
                }
                else
                {
                    pObjGestor.AddAccountDemo(int.Parse(rValues[0]), double.Parse(rValues[4]));
                }
            }

            pMenuP.DisplayUserInfoDemo(pObjGestor.GetUserInfo(int.Parse(rValues[0])));
        }
Esempio n. 2
0
 private static void OptionThree(Gestor pObjGestor, UIMenuPrincipal pMenuP)
 {
     AdminPassword(pObjGestor, pMenuP);
     pMenuP.DisplayUserInfoDemo(pObjGestor.GetUserInfo(pMenuP.GetUserIdDemo()));
 }