Exemplo n.º 1
0
        /// <inheritdoc/>
        public async Task UpdateNavigation(NavigationInput input)
        {
            var navigation = await _navigationRepository.GetAsync(input.Id);

            input.MapTo(navigation);
            await navigationManager.UpdateNavigationAsync(navigation);
        }
Exemplo n.º 2
0
        public ActionResult CreateNavigation()
        {
            var model = new NavigationInput {
                TenantId = AbpSession.TenantId
            };

            return(View("Easyman.FwWeb.Views.Admin.EditNavigation", model));
        }
Exemplo n.º 3
0
        public void SaveNavigationEdit(NavigationInput input)
        {
            var nav = _moduleManage.GetNavigation(input.Id) ?? new Module();

            nav.Name       = input.Name;
            nav.Icon       = input.Icon;
            nav.Code       = input.Code;
            nav.ParentId   = input.ParentId;
            nav.Url        = input.Url;
            nav.ShowOrder  = input.ShowOrder;
            nav.TenantId   = input.TenantId.HasValue ? input.TenantId.Value : 1;
            nav.RoleModule = nav.RoleModule ?? new List <RoleModule>();
            nav.IsUse      = input.IsUse;//是否启用

            var navId = _moduleManage.SaveOrUpdateNavigation(nav);

            _moduleManage.SetRoles(navId, input.RoleIds);
        }
Exemplo n.º 4
0
 /// <inheritdoc/>
 public async Task CreateNavigation(NavigationInput input)
 {
     var navigation = input.MapTo <Navigation>();
     await navigationManager.CreateNavigationAsync(navigation);
 }