All Projects → yuzd → Antmgr

yuzd / Antmgr

Licence: apache-2.0
netcore+vue mvc role management 快速开发系统(菜单,角色,权限[精确到按钮])

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to Antmgr

onvif-discovery
C# .NetStandard 2.0 library to discover ONVIF compliant devices
Stars: ✭ 29 (-89.26%)
Mutual labels:  netcore
ModernWpf
Modern styles and controls for your WPF applications without need WinRT
Stars: ✭ 65 (-75.93%)
Mutual labels:  netcore
Egorozh.ColorPicker
🎨🎨🎨 Best of the best ColorPicker on WPF and AvaloniaUI
Stars: ✭ 39 (-85.56%)
Mutual labels:  netcore
AspNetCore.Identity.RavenDb
RavenDB user/role persistent store for ASP.NET Core identity provider
Stars: ✭ 17 (-93.7%)
Mutual labels:  netcore
Mediator
Small .NET library that helps with the implementation of mediator pattern for commands, events and queries
Stars: ✭ 31 (-88.52%)
Mutual labels:  netcore
matorral
An open-source, very simple & extensible project managent tool written using Django/Python
Stars: ✭ 21 (-92.22%)
Mutual labels:  management-system
awesome-dotnet-async
A curated list of awesome articles and resources to learning and practicing about async, threading, and channels in .Net platform. 😉
Stars: ✭ 84 (-68.89%)
Mutual labels:  netcore
Anet
A .NET Core Common Library , Framework and Boilerplate.
Stars: ✭ 255 (-5.56%)
Mutual labels:  netcore
H.NotifyIcon.WPF
NotifyIcon for .Net Core 3.1 and .Net 5 WPF.
Stars: ✭ 44 (-83.7%)
Mutual labels:  netcore
csharp-ddd-skeleton
🦈✨ C# DDD Skeleton: Bootstrap your new C# projects applying Hexagonal Architecture and Domain-Driven Design patterns
Stars: ✭ 67 (-75.19%)
Mutual labels:  netcore
Sharer
Arduino & .NET serial communication library to read/write variables and remote call functions using the Sharer protocol. Works on Windows, Linux and MacOS.
Stars: ✭ 21 (-92.22%)
Mutual labels:  netcore
EntityFrameworkCore.SqlServer.SimpleBulks
Very simple .net library (lightweight, easy to use and customize) that supports bulk insert (return db generated Ids), bulk update, bulk delete and bulk merge database operations. Lambda Expression is also supported.
Stars: ✭ 95 (-64.81%)
Mutual labels:  netcore
Coding-Standards
Coding Guidelines for C#
Stars: ✭ 125 (-53.7%)
Mutual labels:  netcore
EPPlus4PHP
an easy-to-use excel library for php project which is compiled with peachpie. NOT FOR THE COMMON PHP PROJECT!
Stars: ✭ 15 (-94.44%)
Mutual labels:  netcore
netcore-wcf-service-proxy
Example of consuming multiple WCF services using a proxy implementation in a ASP.NET Core Web-application.
Stars: ✭ 42 (-84.44%)
Mutual labels:  netcore
ddd-net-ef-core
Self study: DDD, .net core, entity framework core
Stars: ✭ 41 (-84.81%)
Mutual labels:  netcore
SimCaptcha
✅ 一个简单易用的点触验证码 (前端+后端)
Stars: ✭ 49 (-81.85%)
Mutual labels:  netcore
Apijson.net
后端接口自动化 .NET CORE版本
Stars: ✭ 263 (-2.59%)
Mutual labels:  netcore
Iview2 Management System
a basic management system example written by iview2.0 & Vue2.
Stars: ✭ 255 (-5.56%)
Mutual labels:  management-system
Cake.Curl
🍰↕️ A cross-platform add-in for Cake that allows to transfer files to and from remote URLs using curl.
Stars: ✭ 17 (-93.7%)
Mutual labels:  netcore

AntMgr

基于netcore2.0 mvc 开发的 快速搭建具有如下特色的后台管理系统 最新版已升级到aspnetcore3.1

特色:

  1. 用户管理
  2. 菜单管理
  3. 角色管理
  4. 权限管理[精确到按钮])
  5. 代码生成器(一键生成CRUD前后端代码 增+删+改+查【分页】导入+导出)
  6. SQL工具(智能字段提示)
  7. 约定大于配置,开发简单效率高,权限配置友好不复杂
  8. 支持mysql和sqlserver两种数据库。切换数据库不用改任何代码

角色支持遗传,比如 :共有ABCD四个功能权限,分配了 A B 2个权限给 超级管理员角色的用户,支持让超级管理员用户还能自己创建角色。但是只能选择 A B 2个。无法看到 C D!

遇到问题可有加群咨询

image

如何使用 wiki:https://github.com/yuzd/AntMgr/wiki

代码克隆到本地 用vs2017或以上版本 打开工程。

项目结构如下:

image image

找到DbModel下面的初始化db脚本

  • mysql数据库的初始化脚本
  • sqlserver数据库的初始化脚本(我测试用的是2012)

image

以下教程采用的是mysql数据库,如果您是用MSSQL的话请看wiki里面有专门介绍注意点。

里面包含4张表的schema和初始化数据,你可以新建一个db,也可以导入到你现有的db

  1. system_users 系统用户表
  2. system_menu 系统菜单表
  3. system_role 系统角色表
  4. system_page_action 按钮权限表

image

导入db成功后在项目配置文件里面修改成正确的db链接字符串

image

F5启动应用 会进入登录页面

image

如果是按照上面初始化db脚本的话 初始化的登录名 zdyu 密码 123456

登录成功如下图:

首页

image

菜单管理

image

权限管理

image

角色管理

image image

系统用户

image

代码自动生成

image image

SQL工具(智能字段提示,写sql再也不用担心忘记字段名称了)

image

权限如何设计的

  • 一个菜单(system_menu)对应一个view页面【1:1】
  • 一个用户(system_user)只能有一个角色(system_role)【1:1】
  • 一个角色(system_role)可以配置多个菜单权限(view页面) 和view页面里面的功能模块(ru按钮) 【1:N】
  • 每个菜单(view页面)下的功能模块(如按钮)配置实际该功能用到的接口【1:N】

约定>配置 权限设计其实很简单

权限主要拦截器代码实现在: image

用户登录态是记录在cookie的 默认的keyName:cbeid 可以在这个里面更改 image

约定一

具有权限拦截的Controller类上面统一打上[API("controller作用描述")] 方法上面打上 [API("方法作用描述")]

约定二

在页面里面写需要权限控制的按钮的时候

<button type="button" class="authorization" action-id="role-add" action-name="新增角色" style="display: none" >新增角色</button>

标签名称 含义
action-id 表示这个权限按钮的id 在当前view唯一
action-name 权限按钮的作用描述
display 默认使用 none 隐藏
class 必须有 authorization

只要遵守如上2个约定开发好页面和controller后,按照如下步骤进行配置权限

  1. 在菜单管理加入新增的页面
  2. 在权限管理配置功能按钮对应用到的接口
  3. 在角色管理修改对应的角色

其他说明

后台用到了的Orm框架:

https://github.com/yuzd/AntData.ORM

配合ORM框架的vs一键生成dbmodel 插件 wiki有插件使用教程

https://marketplace.visualstudio.com/items?itemName=nainaigu.AntDataVS

配合ORM框架的rider一键生成dbmodel 插件 wiki有插件使用教程

https://plugins.jetbrains.com/plugin/14033

WIKI有更详细的教程

https://github.com/yuzd/AntMgr/wiki

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].