mirror of
https://gitee.com/dotnetchina/OpenAuth.Net.git
synced 2025-05-07 22:28:01 +08:00
Merge branch 'main' of https://gitee.com/dotnetchina/OpenAuth.Net
This commit is contained in:
commit
154583889a
@ -79,6 +79,11 @@
|
|||||||
/// 会签拒绝的个数
|
/// 会签拒绝的个数
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public int? ConfluenceNo { get; set; }
|
public int? ConfluenceNo { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 可写的表单项ID
|
||||||
|
/// </summary>
|
||||||
|
public string[] CanWriteFormItemIds { get; set; }
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
@ -296,6 +296,11 @@ namespace OpenAuth.App
|
|||||||
|
|
||||||
flowInstance.SchemeContent = JsonHelper.Instance.Serialize(wfruntime.ToSchemeObj());
|
flowInstance.SchemeContent = JsonHelper.Instance.Serialize(wfruntime.ToSchemeObj());
|
||||||
|
|
||||||
|
if (!string.IsNullOrEmpty(request.FrmData))
|
||||||
|
{
|
||||||
|
flowInstance.FrmData = request.FrmData;
|
||||||
|
}
|
||||||
|
|
||||||
UnitWork.Update(flowInstance);
|
UnitWork.Update(flowInstance);
|
||||||
UnitWork.Add(flowInstanceOperationHistory);
|
UnitWork.Add(flowInstanceOperationHistory);
|
||||||
|
|
||||||
@ -596,9 +601,15 @@ namespace OpenAuth.App
|
|||||||
var flowinstance = Get(id);
|
var flowinstance = Get(id);
|
||||||
var resp =flowinstance.MapTo<FlowVerificationResp>();
|
var resp =flowinstance.MapTo<FlowVerificationResp>();
|
||||||
var runtime = new FlowRuntime(flowinstance);
|
var runtime = new FlowRuntime(flowinstance);
|
||||||
|
if (runtime.currentNode != null && runtime.currentNode.setInfo !=null)
|
||||||
|
{
|
||||||
|
resp.CanWriteFormItemIds = runtime.currentNode.setInfo.CanWriteFormItemIds;
|
||||||
|
}
|
||||||
|
|
||||||
if (runtime.nextNode != null && runtime.nextNode.setInfo !=null && runtime.nextNodeType != 4)
|
if (runtime.nextNode != null && runtime.nextNode.setInfo !=null && runtime.nextNodeType != 4)
|
||||||
{
|
{
|
||||||
resp.NextNodeDesignateType = runtime.nextNode.setInfo.NodeDesignate;
|
resp.NextNodeDesignateType = runtime.nextNode.setInfo.NodeDesignate;
|
||||||
|
resp.CanWriteFormItemIds = runtime.currentNode.setInfo.CanWriteFormItemIds;
|
||||||
}
|
}
|
||||||
return resp;
|
return resp;
|
||||||
}
|
}
|
||||||
|
@ -25,5 +25,11 @@ namespace OpenAuth.App.Request
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public string NodeRejectType { get; set; }
|
public string NodeRejectType { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 新的表单数据
|
||||||
|
/// 如果该节点有可以修改的表单项时,会提交表单数据信息
|
||||||
|
/// </summary>
|
||||||
|
public string FrmData { get; set; }
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -17,5 +17,10 @@ namespace OpenAuth.App.Response
|
|||||||
/// 下个节点的执行权限方式
|
/// 下个节点的执行权限方式
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string NextNodeDesignateType { get; set; }
|
public string NextNodeDesignateType { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 当前节点的可写表单Id
|
||||||
|
/// </summary>
|
||||||
|
public string[] CanWriteFormItemIds { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -5,6 +5,7 @@ using OpenAuth.App.Response;
|
|||||||
using OpenAuth.Repository.Domain;
|
using OpenAuth.Repository.Domain;
|
||||||
using OpenAuth.Repository.Interface;
|
using OpenAuth.Repository.Interface;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
|
using System.Threading.Tasks;
|
||||||
using Infrastructure;
|
using Infrastructure;
|
||||||
using OpenAuth.App.Request;
|
using OpenAuth.App.Request;
|
||||||
using OpenAuth.Repository;
|
using OpenAuth.Repository;
|
||||||
@ -30,6 +31,26 @@ namespace OpenAuth.App
|
|||||||
return roles;
|
return roles;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 获取所有的角色
|
||||||
|
/// 为了控制权限,通常只用于流程实例选择执行角色,其他地方请使用Load
|
||||||
|
/// </summary>
|
||||||
|
public async Task<TableResp<Role>> LoadAll(QueryRoleListReq request)
|
||||||
|
{
|
||||||
|
var result = new TableResp<Role>();
|
||||||
|
var objs = UnitWork.Find<Role>(null);
|
||||||
|
if (!string.IsNullOrEmpty(request.key))
|
||||||
|
{
|
||||||
|
objs = objs.Where(u => u.Name.Contains(request.key));
|
||||||
|
}
|
||||||
|
|
||||||
|
result.data = objs.OrderBy(u => u.Name)
|
||||||
|
.Skip((request.page - 1) * request.limit)
|
||||||
|
.Take(request.limit).ToList();
|
||||||
|
result.count = objs.Count();
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 添加角色,如果当前登录用户不是System,则直接把新角色分配给当前登录用户
|
/// 添加角色,如果当前登录用户不是System,则直接把新角色分配给当前登录用户
|
||||||
@ -80,5 +101,7 @@ namespace OpenAuth.App
|
|||||||
{
|
{
|
||||||
_revelanceApp = app;
|
_revelanceApp = app;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -43,7 +43,7 @@ namespace OpenAuth.App
|
|||||||
objs = objs.Where(u => u.ToStatus == request.Status);
|
objs = objs.Where(u => u.ToStatus == request.Status);
|
||||||
}
|
}
|
||||||
|
|
||||||
result.data = objs.OrderBy(u => u.Id)
|
result.data = objs.OrderByDescending(u => u.CreateTime)
|
||||||
.Skip((request.page - 1) * request.limit)
|
.Skip((request.page - 1) * request.limit)
|
||||||
.Take(request.limit);
|
.Take(request.limit);
|
||||||
result.count = objs.Count();
|
result.count = objs.Count();
|
||||||
|
@ -40,7 +40,6 @@ namespace OpenAuth.App
|
|||||||
{
|
{
|
||||||
var loginUser = _auth.GetCurrentUser();
|
var loginUser = _auth.GetCurrentUser();
|
||||||
|
|
||||||
|
|
||||||
IQueryable<User> query = UnitWork.Find<User>(null);
|
IQueryable<User> query = UnitWork.Find<User>(null);
|
||||||
if (!string.IsNullOrEmpty(request.key))
|
if (!string.IsNullOrEmpty(request.key))
|
||||||
{
|
{
|
||||||
@ -48,7 +47,7 @@ namespace OpenAuth.App
|
|||||||
}
|
}
|
||||||
|
|
||||||
var userOrgs = from user in query
|
var userOrgs = from user in query
|
||||||
join relevance in UnitWork.Find<Relevance>(u =>u.Key=="UserOrg")
|
join relevance in UnitWork.Find<Relevance>(u => u.Key == "UserOrg")
|
||||||
on user.Id equals relevance.FirstId into temp
|
on user.Id equals relevance.FirstId into temp
|
||||||
from r in temp.DefaultIfEmpty()
|
from r in temp.DefaultIfEmpty()
|
||||||
join org in UnitWork.Find<Org>(null)
|
join org in UnitWork.Find<Org>(null)
|
||||||
@ -69,7 +68,7 @@ namespace OpenAuth.App
|
|||||||
r.Key,
|
r.Key,
|
||||||
r.SecondId,
|
r.SecondId,
|
||||||
OrgId = o.Id,
|
OrgId = o.Id,
|
||||||
OrgName= o.Name
|
OrgName = o.Name
|
||||||
};
|
};
|
||||||
|
|
||||||
//如果请求的orgId不为空
|
//如果请求的orgId不为空
|
||||||
@ -116,6 +115,72 @@ namespace OpenAuth.App
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 获取所有的用户
|
||||||
|
/// 为了控制权限,通常只用于流程实例选择执行角色,其他地方请使用Load
|
||||||
|
/// </summary>
|
||||||
|
public async Task<TableResp<UserView>> LoadAll(QueryUserListReq request)
|
||||||
|
{
|
||||||
|
IQueryable<User> query = UnitWork.Find<User>(null);
|
||||||
|
if (!string.IsNullOrEmpty(request.key))
|
||||||
|
{
|
||||||
|
query = UnitWork.Find<User>(u => u.Name.Contains(request.key) || u.Account.Contains(request.key));
|
||||||
|
}
|
||||||
|
|
||||||
|
var userOrgs = from user in query
|
||||||
|
join relevance in UnitWork.Find<Relevance>(u => u.Key == "UserOrg")
|
||||||
|
on user.Id equals relevance.FirstId into temp
|
||||||
|
from r in temp.DefaultIfEmpty()
|
||||||
|
join org in UnitWork.Find<Org>(null)
|
||||||
|
on r.SecondId equals org.Id into orgtmp
|
||||||
|
from o in orgtmp.DefaultIfEmpty()
|
||||||
|
select new
|
||||||
|
{
|
||||||
|
user.Account,
|
||||||
|
user.Name,
|
||||||
|
user.Id,
|
||||||
|
user.Sex,
|
||||||
|
user.Status,
|
||||||
|
user.BizCode,
|
||||||
|
user.CreateId,
|
||||||
|
user.CreateTime,
|
||||||
|
user.TypeId,
|
||||||
|
user.TypeName,
|
||||||
|
r.Key,
|
||||||
|
r.SecondId,
|
||||||
|
OrgId = o.Id,
|
||||||
|
OrgName = o.Name
|
||||||
|
};
|
||||||
|
|
||||||
|
//如果请求的orgId不为空
|
||||||
|
if (!string.IsNullOrEmpty(request.orgId))
|
||||||
|
{
|
||||||
|
userOrgs = userOrgs.Where(u => u.Key == Define.USERORG && u.OrgId == request.orgId);
|
||||||
|
}
|
||||||
|
|
||||||
|
var userViews = userOrgs.ToList().GroupBy(b => b.Account).Select(u =>new UserView
|
||||||
|
{
|
||||||
|
Id = u.First().Id,
|
||||||
|
Account = u.Key,
|
||||||
|
Name = u.First().Name,
|
||||||
|
Sex = u.First().Sex,
|
||||||
|
Status = u.First().Status,
|
||||||
|
CreateTime = u.First().CreateTime,
|
||||||
|
CreateUser = u.First().CreateId,
|
||||||
|
OrganizationIds = string.Join(",", u.Select(x=>x.OrgId))
|
||||||
|
,Organizations = string.Join(",", u.Select(x=>x.OrgName))
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
|
return new TableResp<UserView>()
|
||||||
|
{
|
||||||
|
count = userViews.Count(),
|
||||||
|
data = userViews.OrderBy(u => u.Name)
|
||||||
|
.Skip((request.page - 1) * request.limit)
|
||||||
|
.Take(request.limit).ToList()
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
public void AddOrUpdate(UpdateUserReq request)
|
public void AddOrUpdate(UpdateUserReq request)
|
||||||
{
|
{
|
||||||
request.ValidationEntity(u => new {u.Account,u.Name, u.OrganizationIds});
|
request.ValidationEntity(u => new {u.Account,u.Name, u.OrganizationIds});
|
||||||
@ -201,6 +266,7 @@ namespace OpenAuth.App
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 获取指定角色包含的用户列表
|
/// 获取指定角色包含的用户列表
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -228,9 +294,9 @@ namespace OpenAuth.App
|
|||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public async Task<TableData> LoadByOrg(QueryUserListByOrgReq request)
|
public async Task<TableData> LoadByOrg(QueryUserListByOrgReq request)
|
||||||
{
|
{
|
||||||
var users = from userRole in UnitWork.Find<Relevance>(u =>
|
var users = from userOrg in UnitWork.Find<Relevance>(u =>
|
||||||
u.SecondId == request.orgId && u.Key == Define.USERORG)
|
u.SecondId == request.orgId && u.Key == Define.USERORG)
|
||||||
join user in UnitWork.Find<User>(null) on userRole.FirstId equals user.Id into temp
|
join user in UnitWork.Find<User>(null) on userOrg.FirstId equals user.Id into temp
|
||||||
from c in temp.Where(u =>u.Id != null)
|
from c in temp.Where(u =>u.Id != null)
|
||||||
select c;
|
select c;
|
||||||
|
|
||||||
|
@ -88,7 +88,7 @@ namespace OpenAuth.IdentityServer
|
|||||||
else //oracle
|
else //oracle
|
||||||
{
|
{
|
||||||
services.AddDbContext<OpenAuthDBContext>(options =>
|
services.AddDbContext<OpenAuthDBContext>(options =>
|
||||||
options.UseOracle(Configuration.GetConnectionString("OpenAuthDBContext")));
|
options.UseOracle(Configuration.GetConnectionString("OpenAuthDBContext"), o=>o.UseOracleSQLCompatibility("11")));
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -1,7 +1,8 @@
|
|||||||
@section header
|
@section header
|
||||||
{
|
{
|
||||||
<link rel="stylesheet" href="/css/main.css" media="all" />
|
<link rel="stylesheet" href="/css/main.css" media="all"/>
|
||||||
}
|
}
|
||||||
|
|
||||||
<div class="panel_box row">
|
<div class="panel_box row">
|
||||||
<div class="panel col">
|
<div class="panel col">
|
||||||
<a href="javascript:;" data-url="/orgmanager/index">
|
<a href="javascript:;" data-url="/orgmanager/index">
|
||||||
@ -79,7 +80,8 @@
|
|||||||
<p>
|
<p>
|
||||||
<a href="https://gitee.com/yubaolee/OpenAuth.Core" target="_blank" class="layui-btn layui-btn-xs layui-btn-danger">项目地址</a>
|
<a href="https://gitee.com/yubaolee/OpenAuth.Core" target="_blank" class="layui-btn layui-btn-xs layui-btn-danger">项目地址</a>
|
||||||
<a class="layui-btn layui-btn-xs" target="_blank" href="http://doc.openauth.me">在线文档</a>
|
<a class="layui-btn layui-btn-xs" target="_blank" href="http://doc.openauth.me">在线文档</a>
|
||||||
<a class="layui-btn layui-btn-xs layui-btn-danger" target="_blank" href="http://demo.openauth.me:1803">企业版入口</a>
|
<a class="layui-btn layui-btn-xs layui-btn-danger" target="_blank" href="http://demo.openauth.me:1803">企业版/高级版入口</a>
|
||||||
|
<a class="layui-btn layui-btn-xs layui-btn-danger" target="_blank" href="http://demo.openauth.me:1804">企业版H5入口(请使用移动模式或者直接手机查看)</a>
|
||||||
<span style="color: #f00;">注:【本框架遵循LGPL开源协议,企业单位如商用请联系作者授权,谢谢】</span>
|
<span style="color: #f00;">注:【本框架遵循LGPL开源协议,企业单位如商用请联系作者授权,谢谢】</span>
|
||||||
</p>
|
</p>
|
||||||
<p>技术交流QQ群:484498493【已满】 626433139【已满】 566344079</p>
|
<p>技术交流QQ群:484498493【已满】 626433139【已满】 566344079</p>
|
||||||
@ -87,14 +89,33 @@
|
|||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="sysNotice col">
|
<div class="sysNotice col">
|
||||||
<blockquote class="layui-elem-quote title">更新日志</blockquote>
|
<blockquote class="layui-elem-quote title">更新日志</blockquote>
|
||||||
<div class="layui-elem-quote layui-quote-nm">
|
<div class="layui-elem-quote layui-quote-nm">
|
||||||
|
<h3># 3.2</h3>
|
||||||
|
<p>* 【新增】增加在swagger界面查看接口调用时间及SQL执行时间</p>
|
||||||
|
<p>
|
||||||
|
* 【新增】支持同时配置多个类型数据库的连接字符串:
|
||||||
|
详见:<a href="http://doc.openauth.me/core/multidbs.html" target="_blank" class="layui-btn layui-btn-xs layui-btn-danger">http://doc.openauth.me/core/multidbs.html</a>
|
||||||
|
</p>
|
||||||
|
<p>* 【新增】增加swagger接口分组</p>
|
||||||
|
<p>* 【新增】增加流程召回功能</p>
|
||||||
|
<p>* 【新增】增加运行时选定执行人、执行角色功能</p>
|
||||||
|
<p>* 【新增】增加Redis缓存支持</p>
|
||||||
|
<p>* 【新增】新增int类型数据库主键,并支持雪花算法自动生成</p>
|
||||||
|
<p>* 【新增】新增附件管理,上传图片支持生成缩略图</p>
|
||||||
|
</div>
|
||||||
|
<div class="layui-elem-quote layui-quote-nm">
|
||||||
<h3># 2.0</h3>
|
<h3># 2.0</h3>
|
||||||
<p>* 【新增】框架升级至.net core sdk 3.1.100</p>
|
<p>* 【新增】框架升级至.net core sdk 3.1.100</p>
|
||||||
<p>* 【新增】增加<a href="javascript:;" data-url="/usermanager/profile"><cite>个人中心</cite></a>页面,可修改个人信息及切换当前默认部门</p>
|
<p>
|
||||||
<p>* 【优化】升级layui至2.5.6</p>
|
* 【新增】增加
|
||||||
|
<a href="javascript:;" data-url="/usermanager/profile">
|
||||||
|
<cite>个人中心</cite>
|
||||||
|
</a>页面,可修改个人信息及切换当前默认部门
|
||||||
|
</p>
|
||||||
|
<p>* 【优化】升级layui至2.5.6</p>
|
||||||
<p>* 【优化】可以灵活配置用户可访问的机构数据权限</p>
|
<p>* 【优化】可以灵活配置用户可访问的机构数据权限</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="layui-elem-quote layui-quote-nm">
|
<div class="layui-elem-quote layui-quote-nm">
|
||||||
<h3># 1.6</h3>
|
<h3># 1.6</h3>
|
||||||
<p>* 【新增】日志及用户消息板块</p>
|
<p>* 【新增】日志及用户消息板块</p>
|
||||||
<p>* 【新增】企业版代码生成器,可以快速生成带有头/明细结构的页面</p>
|
<p>* 【新增】企业版代码生成器,可以快速生成带有头/明细结构的页面</p>
|
||||||
@ -102,7 +123,7 @@
|
|||||||
<p>* 【新增】完整的字段权限控制,可以控制字段可见及API是否返回字段值</p>
|
<p>* 【新增】完整的字段权限控制,可以控制字段可见及API是否返回字段值</p>
|
||||||
<p>* 【优化】启用数据字典功能</p>
|
<p>* 【优化】启用数据字典功能</p>
|
||||||
<p>* 【优化】优化导航排序、支持多级导航</p>
|
<p>* 【优化】优化导航排序、支持多级导航</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="layui-elem-quote layui-quote-nm">
|
<div class="layui-elem-quote layui-quote-nm">
|
||||||
<h3># 1.5 - 2019.7</h3>
|
<h3># 1.5 - 2019.7</h3>
|
||||||
<p>* 【优化】升级layui至2.5.4</p>
|
<p>* 【优化】升级layui至2.5.4</p>
|
||||||
@ -133,34 +154,34 @@
|
|||||||
<col>
|
<col>
|
||||||
</colgroup>
|
</colgroup>
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr>
|
<tr>
|
||||||
<td>当前版本</td>
|
<td>当前版本</td>
|
||||||
<td class="version"></td>
|
<td class="version"></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td>开发作者</td>
|
<td>开发作者</td>
|
||||||
<td class="author"></td>
|
<td class="author"></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td>网站首页</td>
|
<td>网站首页</td>
|
||||||
<td class="homePage"></td>
|
<td class="homePage"></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td>服务器环境</td>
|
<td>服务器环境</td>
|
||||||
<td class="server"></td>
|
<td class="server"></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td>数据库版本</td>
|
<td>数据库版本</td>
|
||||||
<td class="dataBase"></td>
|
<td class="dataBase"></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td>最大上传限制</td>
|
<td>最大上传限制</td>
|
||||||
<td class="maxUpload"></td>
|
<td class="maxUpload"></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td>当前用户权限</td>
|
<td>当前用户权限</td>
|
||||||
<td class="userRights"></td>
|
<td class="userRights"></td>
|
||||||
</tr>
|
</tr>
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
@ -168,4 +189,4 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<script type="text/javascript" src="/layui/layui.js"></script>
|
<script type="text/javascript" src="/layui/layui.js"></script>
|
||||||
<script type="text/javascript" src="/userJs/main.js?v=2.0.0"></script>
|
<script type="text/javascript" src="/userJs/main.js?v=3.2.0"></script>
|
@ -28,6 +28,6 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<script type="text/javascript" src="/layui/layui.js"></script>
|
<script type="text/javascript" src="/layui/layui.js"></script>
|
||||||
<script type="text/javascript" src="/userJs/sysmessages.js"></script>
|
<script type="text/javascript" src="/userJs/sysmessages.js?v=3.2.1"></script>
|
||||||
|
|
||||||
|
|
||||||
|
@ -59,7 +59,7 @@ layui.config({
|
|||||||
})
|
})
|
||||||
|
|
||||||
//系统基本参数
|
//系统基本参数
|
||||||
$(".version").text("v2.0"); //当前版本
|
$(".version").text("v3.2"); //当前版本
|
||||||
$(".author").text("yubaolee"); //开发作者
|
$(".author").text("yubaolee"); //开发作者
|
||||||
$(".homePage").text("/Home/Index"); //网站首页
|
$(".homePage").text("/Home/Index"); //网站首页
|
||||||
$(".server").text("centos docker"); //服务器环境
|
$(".server").text("centos docker"); //服务器环境
|
||||||
|
@ -21,6 +21,9 @@
|
|||||||
, size: 'sm' //小尺寸的表格
|
, size: 'sm' //小尺寸的表格
|
||||||
,page: true,
|
,page: true,
|
||||||
url: '/SysMessages/Load',
|
url: '/SysMessages/Load',
|
||||||
|
where:{
|
||||||
|
status:999 //全部消息
|
||||||
|
},
|
||||||
cols: [[ //表头
|
cols: [[ //表头
|
||||||
{ field: 'Title', title: '消息标题' }
|
{ field: 'Title', title: '消息标题' }
|
||||||
, { field: 'Content', title: '内容' }
|
, { field: 'Content', title: '内容' }
|
||||||
@ -43,6 +46,7 @@
|
|||||||
if (options != undefined) {
|
if (options != undefined) {
|
||||||
$.extend(config, options);
|
$.extend(config, options);
|
||||||
}
|
}
|
||||||
|
config.status = 999; //全部消息
|
||||||
table.reload('mainList',
|
table.reload('mainList',
|
||||||
{
|
{
|
||||||
url: '/SysMessages/Load',
|
url: '/SysMessages/Load',
|
||||||
|
@ -21,14 +21,16 @@ namespace OpenAuth.Repository
|
|||||||
private ILoggerFactory _LoggerFactory;
|
private ILoggerFactory _LoggerFactory;
|
||||||
private IHttpContextAccessor _httpContextAccessor;
|
private IHttpContextAccessor _httpContextAccessor;
|
||||||
private IConfiguration _configuration;
|
private IConfiguration _configuration;
|
||||||
|
private IOptions<AppSetting> _appConfiguration;
|
||||||
|
|
||||||
public OpenAuthDBContext(DbContextOptions<OpenAuthDBContext> options, ILoggerFactory loggerFactory,
|
public OpenAuthDBContext(DbContextOptions<OpenAuthDBContext> options, ILoggerFactory loggerFactory,
|
||||||
IHttpContextAccessor httpContextAccessor, IConfiguration configuration)
|
IHttpContextAccessor httpContextAccessor, IConfiguration configuration, IOptions<AppSetting> appConfiguration)
|
||||||
: base(options)
|
: base(options)
|
||||||
{
|
{
|
||||||
_LoggerFactory = loggerFactory;
|
_LoggerFactory = loggerFactory;
|
||||||
_httpContextAccessor = httpContextAccessor;
|
_httpContextAccessor = httpContextAccessor;
|
||||||
_configuration = configuration;
|
_configuration = configuration;
|
||||||
|
_appConfiguration = appConfiguration;
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
|
protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
|
||||||
@ -65,7 +67,7 @@ namespace OpenAuth.Repository
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
optionsBuilder.UseOracle(connect);
|
optionsBuilder.UseOracle(connect,options =>options.UseOracleSQLCompatibility("11"));
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.Threading.Tasks;
|
||||||
using Infrastructure;
|
using Infrastructure;
|
||||||
using Microsoft.AspNetCore.Mvc;
|
using Microsoft.AspNetCore.Mvc;
|
||||||
using OpenAuth.App;
|
using OpenAuth.App;
|
||||||
@ -88,7 +89,17 @@ namespace OpenAuth.WebApi.Controllers
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 加载列表
|
/// 获取所有的角色
|
||||||
|
/// 为了控制权限,通常只用于流程实例选择执行角色,其他地方请使用Load
|
||||||
|
/// </summary>
|
||||||
|
[HttpGet]
|
||||||
|
public async Task<TableResp<Role>> LoadAll([FromQuery]QueryRoleListReq request)
|
||||||
|
{
|
||||||
|
return await _app.LoadAll(request);
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 获取登录用户可以访问的角色
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[HttpGet]
|
[HttpGet]
|
||||||
public Response<List<Role>> Load([FromQuery]QueryRoleListReq request)
|
public Response<List<Role>> Load([FromQuery]QueryRoleListReq request)
|
||||||
|
@ -111,6 +111,16 @@ namespace OpenAuth.WebApi.Controllers
|
|||||||
return await _app.Load(request);
|
return await _app.Load(request);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 获取所有的用户
|
||||||
|
/// 为了控制权限,通常只用于流程实例选择执行角色,其他地方请使用Load
|
||||||
|
/// </summary>
|
||||||
|
[HttpGet]
|
||||||
|
public async Task<TableResp<UserView>> LoadAll([FromQuery]QueryUserListReq request)
|
||||||
|
{
|
||||||
|
return await _app.LoadAll(request);
|
||||||
|
}
|
||||||
|
|
||||||
[HttpPost]
|
[HttpPost]
|
||||||
public Response Delete([FromBody]string[] ids)
|
public Response Delete([FromBody]string[] ids)
|
||||||
{
|
{
|
||||||
|
@ -1098,6 +1098,14 @@ CREATE TABLE `sysmessage` (
|
|||||||
PRIMARY KEY (`Id`) USING BTREE
|
PRIMARY KEY (`Id`) USING BTREE
|
||||||
) ENGINE = InnoDB CHARACTER SET = utf8 COLLATE = utf8_bin COMMENT = '系统消息表' ROW_FORMAT = Compact;
|
) ENGINE = InnoDB CHARACTER SET = utf8 COLLATE = utf8_bin COMMENT = '系统消息表' ROW_FORMAT = Compact;
|
||||||
|
|
||||||
|
|
||||||
|
-- ----------------------------
|
||||||
|
-- Records of sysmessage
|
||||||
|
-- ----------------------------
|
||||||
|
INSERT INTO `sysmessage` VALUES ('2e34d7de-2203-42c8-80f7-7d60d7ad996b', '系统消息', 'SYS_MSG', '00000000-0000-0000-0000-000000000000', '00000000-0000-0000-0000-000000000000', '系统管理员', 'System', 0, 0, '', '', '你的流程[带分支条件/普通动态表单的模板2020-02-17 21:32:53]已被超级管理员处理。处理情况如下:【任务节点】【2021-06-13 12:02】同意,备注:同意处理', '2021-06-13 12:02:29', '');
|
||||||
|
INSERT INTO `sysmessage` VALUES ('a0d898bd-ca62-46c8-90df-b73074e76500', '系统消息', 'SYS_MSG', '00000000-0000-0000-0000-000000000000', '00000000-0000-0000-0000-000000000000', '系统管理员', 'System', 0, 1, '', '', '你的流程[带有开发者自定义表单的流程2020-02-17 21:35:45]已被超级管理员处理。处理情况如下:【任意人可以审批】【2021-06-13 13:14】不同意,备注:不同意', '2021-06-13 13:14:39', '');
|
||||||
|
|
||||||
|
|
||||||
-- ----------------------------
|
-- ----------------------------
|
||||||
-- Table structure for uploadfile
|
-- Table structure for uploadfile
|
||||||
-- ----------------------------
|
-- ----------------------------
|
||||||
|
Loading…
Reference in New Issue
Block a user