Exemplo n.º 1
0
        //客房
        private void btnRoom_Click(object sender, EventArgs e)
        {
            //BathDBDataContext db_new = new BathDBDataContext(LogIn.connectionString);
            if (!dao.get_authority(LogIn.m_User, "包房管理"))
            {
                BathClass.printErrorMsg("权限不够!");
                return;
            }

            if (MConvert<bool>.ToTypeOrDefault(LogIn.options.启用客房面板, false))
            {
                RoomViewForm rvForm = new RoomViewForm();
                rvForm.ShowDialog();
            }
            else
            {
                var form = new CabViewForm();
                form.ShowDialog();
            }
            //RoomViewForm rmvForm = new RoomViewForm();
            //rmvForm.ShowDialog();
        }
Exemplo n.º 2
0
        //客房
        private void btnRoom_Click(object sender, EventArgs e)
        {
            BathDBDataContext db_new = new BathDBDataContext(LogIn.connectionString);
            if (!BathClass.getAuthority(db_new, LogIn.m_User, "包房管理"))
            {
                BathClass.printErrorMsg("权限不够!");
                return;
            }

            if (BathClass.ToBool(db_new.Options.FirstOrDefault().启用客房面板))
            {
                RoomViewForm rvForm = new RoomViewForm();
                rvForm.ShowDialog();
            }
            else
            {
                var form = new CabViewForm();
                form.ShowDialog();
            }
            RoomViewForm rmvForm = new RoomViewForm();
            rmvForm.ShowDialog();
        }
Exemplo n.º 3
0
 //包厢管理
 private void btnCab_Click(object sender, EventArgs e)
 {
     CabViewForm form = new CabViewForm();
     form.ShowDialog();
 }
Exemplo n.º 4
0
        //包厢管理
        private void btnRoom_Click(object sender, EventArgs e)
        {
            var db = new BathDBDataContext(LogIn.connectionString);
            if (!BathClass.getAuthority(db, LogIn.m_User, "客房管理"))
            {
                GeneralClass.printErrorMsg("不具有权限");
                return;
            }

            if (MConvert<bool>.ToTypeOrDefault(db.Options.FirstOrDefault().启用客房面板, false))
            {
                RoomViewForm rvForm = new RoomViewForm();
                rvForm.ShowDialog();
            }
            else
            {
                var form = new CabViewForm();
                form.ShowDialog();
            }
        }