Ejemplo n.º 1
0
        void client_GetSysPermissionByIDCompleted(object sender, GetSysPermissionByIDCompletedEventArgs e)
        {
            perm            = e.Result;
            perm.UPDATEDATE = DateTime.Now;
            //perm.UPDATEUSER = Common.CurrentLoginUserInfo.sysuserID;

            this.DataContext = perm;

            if (perm.ISCOMMOM == "1" || perm.ISCOMMOM == null)
            {
                rbtIsAutoyes.IsChecked = true;
                rbtIsAutono.IsChecked  = false;
                this.LayoutRoot.RowDefinitions[3].Height = new GridLength(0);
                this.LayoutRoot.RowDefinitions[4].Height = new GridLength(0);
            }
            else
            {
                rbtIsAutoyes.IsChecked = false;
                rbtIsAutono.IsChecked  = true;
                this.LayoutRoot.RowDefinitions[3].Height = new GridLength(30);
                this.LayoutRoot.RowDefinitions[4].Height = new GridLength(30);
                if (perm.ISCOMMOM == "0" && perm.T_SYS_ENTITYMENUReference.EntityKey != null)
                {
                    client.GetSysMenuByIDAsync(perm.T_SYS_ENTITYMENUReference.EntityKey.EntityKeyValues[0].Value.ToString());
                }
            }
            client.GetSysDictionaryByCategoryAsync("SYSTEMTYPE");
        }
Ejemplo n.º 2
0
        private void InitParas(string menuID)
        {
            ServiceClient = new PermissionServiceClient();
            //ServiceClient.SysMenuAddCompleted += new EventHandler<System.ComponentModel.AsyncCompletedEventArgs>(ServiceClient_SysMenuAddCompleted);
            ServiceClient.SysMenuAddCompleted    += new EventHandler <SysMenuAddCompletedEventArgs>(ServiceClient_SysMenuAddCompleted);
            ServiceClient.SysMenuUpdateCompleted += new EventHandler <System.ComponentModel.AsyncCompletedEventArgs>(ServiceClient_SysMenuUpdateCompleted);

            //ServiceClient.GetSysMenuByTypeCompleted += new EventHandler<GetSysMenuByTypeCompletedEventArgs>(ServiceClient_GetSysMenuByTypeCompleted);
            ServiceClient.GetSysMenuByIDCompleted             += new EventHandler <GetSysMenuByIDCompletedEventArgs>(ServiceClient_GetSysMenuByIDCompleted);
            ServiceClient.GetSysDictionaryByCategoryCompleted += new EventHandler <GetSysDictionaryByCategoryCompletedEventArgs>(ServiceClient_GetSysDictionaryByCategoryCompleted);

            if (FormType == FormTypes.New)
            {
                SysMenu = new T_SYS_ENTITYMENU();
                SysMenu.ENTITYMENUID = Guid.NewGuid().ToString();
                //绑定系统类型
                ServiceClient.GetSysDictionaryByCategoryAsync("SYSTEMTYPE");

                //BindParentMenu();
            }
            if (!string.IsNullOrEmpty(menuID))
            {
                ServiceClient.GetSysMenuByIDAsync(menuID);
            }
        }
Ejemplo n.º 3
0
        private void InitParas(string menuID)
        {

            ServiceClient = new PermissionServiceClient();
            //ServiceClient.SysMenuAddCompleted += new EventHandler<System.ComponentModel.AsyncCompletedEventArgs>(ServiceClient_SysMenuAddCompleted);
            ServiceClient.SysMenuAddCompleted += new EventHandler<SysMenuAddCompletedEventArgs>(ServiceClient_SysMenuAddCompleted);
            ServiceClient.SysMenuUpdateCompleted += new EventHandler<System.ComponentModel.AsyncCompletedEventArgs>(ServiceClient_SysMenuUpdateCompleted);
            
            //ServiceClient.GetSysMenuByTypeCompleted += new EventHandler<GetSysMenuByTypeCompletedEventArgs>(ServiceClient_GetSysMenuByTypeCompleted);
            ServiceClient.GetSysMenuByIDCompleted += new EventHandler<GetSysMenuByIDCompletedEventArgs>(ServiceClient_GetSysMenuByIDCompleted);
            ServiceClient.GetSysDictionaryByCategoryCompleted += new EventHandler<GetSysDictionaryByCategoryCompletedEventArgs>(ServiceClient_GetSysDictionaryByCategoryCompleted);

            if (FormType == FormTypes.New)
            {
                SysMenu = new T_SYS_ENTITYMENU();
                SysMenu.ENTITYMENUID = Guid.NewGuid().ToString();
                //绑定系统类型
                ServiceClient.GetSysDictionaryByCategoryAsync("SYSTEMTYPE");
                
                //BindParentMenu();
            }
            if (!string.IsNullOrEmpty(menuID))
            {
                ServiceClient.GetSysMenuByIDAsync(menuID);
            }

        }