diff --git a/Infrastructure/Helpers/ImgHelper.cs b/Infrastructure/Helpers/ImgHelper.cs index 13222fdd..6503542f 100644 --- a/Infrastructure/Helpers/ImgHelper.cs +++ b/Infrastructure/Helpers/ImgHelper.cs @@ -1,5 +1,5 @@ -// -// Copyright (c) 2019 openauth.me. All rights reserved. +// +// Copyright (c) 2019 openauth.net.cn. All rights reserved. // // www.cnblogs.com/yubaolee // 生成缩略图 diff --git a/OpenAuth.App/AuthContextFactory.cs b/OpenAuth.App/AuthContextFactory.cs index 8070382a..c4c81f9d 100644 --- a/OpenAuth.App/AuthContextFactory.cs +++ b/OpenAuth.App/AuthContextFactory.cs @@ -7,7 +7,7 @@ // Last Modified On : 07-05-2018 // *********************************************************************** // -// Copyright (c) http://www.openauth.me. All rights reserved. +// Copyright (c) http://www.openauth.net.cn. All rights reserved. // // // 用户权限策略工厂 diff --git a/OpenAuth.App/AuthStrategies/NormalAuthStrategy.cs b/OpenAuth.App/AuthStrategies/NormalAuthStrategy.cs index f0ef8abe..dad26d38 100644 --- a/OpenAuth.App/AuthStrategies/NormalAuthStrategy.cs +++ b/OpenAuth.App/AuthStrategies/NormalAuthStrategy.cs @@ -7,7 +7,7 @@ // Last Modified On : 07-04-2018 // *********************************************************************** // -// Copyright (c) http://www.openauth.me. All rights reserved. +// Copyright (c) http://www.openauth.net.cn. All rights reserved. // // // 普通用户授权策略 diff --git a/OpenAuth.App/AuthStrategies/SystemAuthStrategy.cs b/OpenAuth.App/AuthStrategies/SystemAuthStrategy.cs index 87d90d02..c0a3165b 100644 --- a/OpenAuth.App/AuthStrategies/SystemAuthStrategy.cs +++ b/OpenAuth.App/AuthStrategies/SystemAuthStrategy.cs @@ -7,7 +7,7 @@ // Last Modified On : 07-05-2018 // *********************************************************************** // -// Copyright (c) http://www.openauth.me. All rights reserved. +// Copyright (c) http://www.openauth.net.cn. All rights reserved. // // // 超级管理员授权策略 diff --git a/OpenAuth.App/Base/BaseApp.cs b/OpenAuth.App/Base/BaseApp.cs index 97549e3b..41705215 100644 --- a/OpenAuth.App/Base/BaseApp.cs +++ b/OpenAuth.App/Base/BaseApp.cs @@ -18,7 +18,7 @@ namespace OpenAuth.App /// /// 用于事务操作 - /// 使用详见:http://doc.openauth.me/core/unitwork.html + /// 使用详见:http://doc.openauth.net.cn/core/unitwork.html /// protected IUnitWork UnitWork; diff --git a/OpenAuth.App/Category/Response/CategoryTypeResp.cs b/OpenAuth.App/Category/Response/CategoryTypeResp.cs new file mode 100644 index 00000000..bb670907 --- /dev/null +++ b/OpenAuth.App/Category/Response/CategoryTypeResp.cs @@ -0,0 +1,10 @@ +using OpenAuth.Repository.Domain; + +namespace OpenAuth.App.Response +{ + public class CategoryTypeResp : CategoryType + { + public string ParentId { get; set; } + + } +} \ No newline at end of file diff --git a/OpenAuth.App/Flow/FlowLine.cs b/OpenAuth.App/Flow/FlowLine.cs index d6590fd7..5f1c5ab3 100644 --- a/OpenAuth.App/Flow/FlowLine.cs +++ b/OpenAuth.App/Flow/FlowLine.cs @@ -1,5 +1,5 @@ -// -// Copyright (c) 2019 openauth.me. All rights reserved. +// +// Copyright (c) 2019 openauth.net.cn. All rights reserved. // // www.cnblogs.com/yubaolee // 2019-03-05 diff --git a/OpenAuth.App/Flow/FlowRuntime.cs b/OpenAuth.App/Flow/FlowRuntime.cs index 70ae339c..cc07be31 100644 --- a/OpenAuth.App/Flow/FlowRuntime.cs +++ b/OpenAuth.App/Flow/FlowRuntime.cs @@ -7,7 +7,7 @@ // Last Modified On : 07-19-2018 // *********************************************************************** // -// Copyright (c) http://www.openauth.me. All rights reserved. +// Copyright (c) http://www.openauth.net.cn. All rights reserved. // // // 一个正在运行中的流程实例 diff --git a/OpenAuth.App/FlowInstance/FlowInstanceApp.cs b/OpenAuth.App/FlowInstance/FlowInstanceApp.cs index eea8ab22..f604a08c 100644 --- a/OpenAuth.App/FlowInstance/FlowInstanceApp.cs +++ b/OpenAuth.App/FlowInstance/FlowInstanceApp.cs @@ -7,7 +7,7 @@ // Last Modified On : 07-19-2018 // *********************************************************************** // -// Copyright (c) http://www.openauth.me. All rights reserved. +// Copyright (c) http://www.openauth.net.cn. All rights reserved. // // // *********************************************************************** diff --git a/OpenAuth.App/FlowInstance/Response/FlowVerificationResp.cs b/OpenAuth.App/FlowInstance/Response/FlowVerificationResp.cs index 19a9b014..c54c9869 100644 --- a/OpenAuth.App/FlowInstance/Response/FlowVerificationResp.cs +++ b/OpenAuth.App/FlowInstance/Response/FlowVerificationResp.cs @@ -7,11 +7,18 @@ namespace OpenAuth.App.Response /// /// 预览表单数据 /// - /// The FRM data HTML. public string FrmPreviewHtml { get { return FormUtil.Preview(this); } } + + /// + /// 预览表单数据表单项包含读写控制权限) + /// + public string FrmHtml + { + get { return FormUtil.GetHtml(this.FrmContentData, this.FrmContentParse, this.FrmData, "",this.CanWriteFormItemIds); } + } /// /// 下个节点的执行权限方式 diff --git a/OpenAuth.App/Form/FormUtil.cs b/OpenAuth.App/Form/FormUtil.cs index dd76b0d8..889f40fd 100644 --- a/OpenAuth.App/Form/FormUtil.cs +++ b/OpenAuth.App/Form/FormUtil.cs @@ -1,3 +1,4 @@ +using System.Linq; using System.Text; using Infrastructure; using Newtonsoft.Json.Linq; @@ -6,9 +7,12 @@ using OpenAuth.Repository.Domain; namespace OpenAuth.App { - public class FormUtil { + public class FormUtil + { + + private static string READONLY = "view"; - public static string GetHtml(string contentData, string contentParse,string frmData, string action) + public static string GetHtml(string contentData, string contentParse,string frmData, string action,params string[] canWriteFormItemIds) { if (string.IsNullOrEmpty(contentData)) { @@ -30,6 +34,11 @@ namespace OpenAuth.App else name = json.GetValue("name").ToString(); + if (canWriteFormItemIds != null && canWriteFormItemIds.Length > 0) + { + action = canWriteFormItemIds.Contains(name) ? "":READONLY; + } + string tempHtml = ""; switch (leipiplugins) { @@ -79,7 +88,7 @@ namespace OpenAuth.App return string.Empty; } - return GetHtml(form.ContentData, form.ContentParse,null, ""); + return GetHtml(form.ContentData, form.ContentParse,form.FrmData, ""); } @@ -98,7 +107,7 @@ namespace OpenAuth.App } return GetHtml(flowInstance.FrmContentData, flowInstance.FrmContentParse, - flowInstance.FrmData, "view"); + flowInstance.FrmData, READONLY); } //text @@ -118,7 +127,7 @@ namespace OpenAuth.App value = item.GetValue("value") == null ? "" : item.GetValue("value").ToString(); string style =item.GetValue("style") == null ? "" : item.GetValue("style").ToString(); string tempHtml = string.Format(temp, value, name, style); - if("view"==action) + if(READONLY==action) return string.Format("",style,value); return tempHtml; } @@ -147,7 +156,7 @@ namespace OpenAuth.App string temp_html = string.Format(temp, name, name, style, script, value); - if("view"==action) + if(READONLY==action) return string.Format("", style, value); return temp_html; } @@ -186,7 +195,7 @@ namespace OpenAuth.App temp_html += string.Format(temp, name, cvalue, Ischecked, cvalue); } - return "view"==action ? string.Format("", "", value) : temp_html; + return READONLY==action ? string.Format("", "", value) : temp_html; } //Checkboxs @@ -229,7 +238,7 @@ namespace OpenAuth.App } - return "view" == action ? string.Format("", "", view_value) : temp_html; + return READONLY == action ? string.Format("", "", view_value) : temp_html; } //Select(比较特殊) @@ -254,7 +263,7 @@ namespace OpenAuth.App content = content.Replace(option, selected); //把选项替换成选中项 } - return "view" == action ? string.Format("", "", value) : content; + return READONLY == action ? string.Format("", "", value) : content; } @@ -295,7 +304,7 @@ namespace OpenAuth.App temp = orgType + "二维码 "; temp_html = string.Format(temp, name, value); } - else if ("view"==action) + else if (READONLY==action) { //可以采用 http://qrcode.leipi.org/ @@ -363,7 +372,7 @@ namespace OpenAuth.App // { // if (i == tdCount - 1) // listTitle.set(i, "操作"); - // if ("view"==(action) && i == tdCount - 1) continue;//如果是查看最后一列不显示 + // if (ACTION==(action) && i == tdCount - 1) continue;//如果是查看最后一列不显示 // trTitle += string.Format("{0}", listTitle.get(i)); // } // trTitle = "" + trTitle + ""; @@ -419,7 +428,7 @@ namespace OpenAuth.App // if (i == tdCount - 1)//最后一列不显示 // { - // if ("view"==(action)) continue; + // if (ACTION==(action)) continue; // //tr += ""; // else // tr += "删除"; @@ -427,7 +436,7 @@ namespace OpenAuth.App // } // else // { - // if ("view"==(action)) + // if (ACTION==(action)) // { // tr += string.Format("{0}", tdValue); // } @@ -449,7 +458,7 @@ namespace OpenAuth.App // //region // if (sum != "") // { - // if ("view"==(action)) + // if (ACTION==(action)) // tdSum += string.Format("合计:value{0}{1}", i, listUnit.get(i)); // else // tdSum += string.Format("合计:{3}", i, tdname, sum, listUnit.get(i)); @@ -476,7 +485,7 @@ namespace OpenAuth.App // tdSum = string.Format("{0}", tdSum); // } // } - // if ("view"==(action)) + // if (ACTION==(action)) // theader = string.Format(theader, tdCount, title, "", trTitle); // else // theader = string.Format(theader, tdCount, title, btnAdd, trTitle); diff --git a/OpenAuth.App/Form/Response/FormResp.cs b/OpenAuth.App/Form/Response/FormResp.cs index eb29960c..03e8e589 100644 --- a/OpenAuth.App/Form/Response/FormResp.cs +++ b/OpenAuth.App/Form/Response/FormResp.cs @@ -48,6 +48,11 @@ namespace OpenAuth.App.Response /// 表单原html模板未经处理的 /// public string Content { get; set; } + + /// + /// 表单的数据 + /// + public string FrmData { get; set; } /// /// 排序码 @@ -69,5 +74,15 @@ namespace OpenAuth.App.Response get { return FormUtil.GetHtml(this); } } + public string[] CanWriteFormItemIds { get; set; } + + /// + /// 用户显示(表单项包含读写控制权限) + /// + public string HtmlWithCanWriteIds + { + get { return FormUtil.GetHtml(this.ContentData, this.ContentParse, this.FrmData,"",this.CanWriteFormItemIds); } + } + } } \ No newline at end of file diff --git a/OpenAuth.App/Interface/IAuthStrategy.cs b/OpenAuth.App/Interface/IAuthStrategy.cs index bca1b098..94e5952c 100644 --- a/OpenAuth.App/Interface/IAuthStrategy.cs +++ b/OpenAuth.App/Interface/IAuthStrategy.cs @@ -7,7 +7,7 @@ // Last Modified On : 07-05-2018 // *********************************************************************** // -// Copyright (c) http://www.openauth.me. All rights reserved. +// Copyright (c) http://www.openauth.net.cn. All rights reserved. // // // 授权策略接口 diff --git a/OpenAuth.Identity/Config.cs b/OpenAuth.Identity/Config.cs index aff9734a..cdb46858 100644 --- a/OpenAuth.Identity/Config.cs +++ b/OpenAuth.Identity/Config.cs @@ -43,7 +43,7 @@ namespace OpenAuth.IdentityServer var host = "http://localhost"; if (isProduction) { - host = "http://demo.openauth.me"; //切换为自己的服务器信息 + host = "http://demo.openauth.net.cn"; //切换为自己的服务器信息 } return new[] { diff --git a/OpenAuth.Identity/Startup.cs b/OpenAuth.Identity/Startup.cs index 05c50b6a..26ccd369 100644 --- a/OpenAuth.Identity/Startup.cs +++ b/OpenAuth.Identity/Startup.cs @@ -49,8 +49,8 @@ namespace OpenAuth.IdentityServer // { // origins = new [] // { -// "http://demo.openauth.me:1803", -// "http://demo.openauth.me:52789" +// "http://demo.openauth.net.cn:1803", +// "http://demo.openauth.net.cn:52789" // }; // } // services.AddCors(option=>option.AddPolicy("cors", policy => diff --git a/OpenAuth.Mvc/Controllers/CategoriesController.cs b/OpenAuth.Mvc/Controllers/CategoriesController.cs index 5de095f8..13f293fb 100644 --- a/OpenAuth.Mvc/Controllers/CategoriesController.cs +++ b/OpenAuth.Mvc/Controllers/CategoriesController.cs @@ -1,4 +1,5 @@ using System; +using System.Collections.Generic; using System.Threading.Tasks; using Infrastructure; using Microsoft.AspNetCore.Mvc; @@ -87,8 +88,18 @@ namespace OpenAuth.Mvc.Controllers /// public string AllTypes() { - var data = _categoryTypeApp.AllTypes(); - return JsonHelper.Instance.Serialize(data); + var resp = new Response>(); + try + { + resp.Result = _categoryTypeApp.AllTypes().MapToList(); + } + catch (Exception e) + { + resp.Code = 500; + resp.Message = e.Message; + } + return JsonHelper.Instance.Serialize(resp); + } } diff --git a/OpenAuth.Mvc/Controllers/ErrorController.cs b/OpenAuth.Mvc/Controllers/ErrorController.cs index 64ef3894..16ee52f2 100644 --- a/OpenAuth.Mvc/Controllers/ErrorController.cs +++ b/OpenAuth.Mvc/Controllers/ErrorController.cs @@ -7,7 +7,7 @@ // Last Modified On : 07-24-2018 // *********************************************************************** // -// Copyright (c) http://www.openauth.me. All rights reserved. +// Copyright (c) http://www.openauth.net.cn. All rights reserved. // // // 异常处理页面 diff --git a/OpenAuth.Mvc/Controllers/UserSessionController.cs b/OpenAuth.Mvc/Controllers/UserSessionController.cs index c4ce62d4..6c51c978 100644 --- a/OpenAuth.Mvc/Controllers/UserSessionController.cs +++ b/OpenAuth.Mvc/Controllers/UserSessionController.cs @@ -7,7 +7,7 @@ // Last Modified On : 07-04-2018 // *********************************************************************** // -// Copyright (c) http://www.openauth.me. All rights reserved. +// Copyright (c) http://www.openauth.net.cn. All rights reserved. // // // 获取登录用户的全部信息 diff --git a/OpenAuth.Mvc/Test/UserSessionControllerTest.cs b/OpenAuth.Mvc/Test/UserSessionControllerTest.cs index 4cb10ab8..eebb708b 100644 --- a/OpenAuth.Mvc/Test/UserSessionControllerTest.cs +++ b/OpenAuth.Mvc/Test/UserSessionControllerTest.cs @@ -7,7 +7,7 @@ // Last Modified On : 07-02-2018 // *********************************************************************** // -// Copyright (c) http://www.openauth.me. All rights reserved. +// Copyright (c) http://www.openauth.net.cn. All rights reserved. // // // 测试加载用户菜单 diff --git a/OpenAuth.Mvc/Views/Categories/Index.cshtml b/OpenAuth.Mvc/Views/Categories/Index.cshtml index 64051a4c..db670108 100644 --- a/OpenAuth.Mvc/Views/Categories/Index.cshtml +++ b/OpenAuth.Mvc/Views/Categories/Index.cshtml @@ -24,7 +24,7 @@
-
@@ -63,4 +63,4 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/OpenAuth.Mvc/Views/Home/Main.cshtml b/OpenAuth.Mvc/Views/Home/Main.cshtml index 33a8af77..dbcb5bba 100644 --- a/OpenAuth.Mvc/Views/Home/Main.cshtml +++ b/OpenAuth.Mvc/Views/Home/Main.cshtml @@ -79,9 +79,9 @@

项目地址 - 在线文档 - 企业版/高级版入口 - 企业版H5入口(请使用移动模式或者直接手机查看) + 在线文档 + 企业版/高级版入口 + 企业版H5入口(请使用移动模式或者直接手机查看) 注:【本框架遵循LGPL开源协议,企业单位如商用请联系作者授权,谢谢】

技术交流QQ群:484498493【已满】     626433139【已满】    566344079

@@ -94,7 +94,7 @@

* 【新增】增加在swagger界面查看接口调用时间及SQL执行时间

* 【新增】支持同时配置多个类型数据库的连接字符串: - 详见:http://doc.openauth.me/core/multidbs.html + 详见:http://doc.openauth.net.cn/core/multidbs.html

* 【新增】增加swagger接口分组

* 【新增】增加流程召回功能

@@ -130,7 +130,7 @@

* 【优化】流程处理页面展示

* 【优化】流程支持角色审批

* 【新增】集成IdentityServer4,实现基于OAuth2的登录体系

-

* 【新增】建立三方对接规范,已有系统可以无缝对接流程引擎,请参考官方对接说明

+

* 【新增】建立三方对接规范,已有系统可以无缝对接流程引擎,请参考官方对接说明

diff --git a/OpenAuth.Mvc/appsettings.Production.json b/OpenAuth.Mvc/appsettings.Production.json index b6b7b6d7..b1677ba1 100644 --- a/OpenAuth.Mvc/appsettings.Production.json +++ b/OpenAuth.Mvc/appsettings.Production.json @@ -10,7 +10,7 @@ "OpenAuthDBContext": "server=127.0.0.1;user id=root;database=openauthdb;password=000000" //my sql }, "AppSetting": { - "IdentityServerUrl": "http://demo.openauth.me:12796", //IdentityServer服务器地址。如果为空,则不启用OAuth认证 + "IdentityServerUrl": "http://demo.openauth.net.cn:12796", //IdentityServer服务器地址。如果为空,则不启用OAuth认证 // "IdentityServerUrl": "", //IdentityServer服务器地址。如果为空,则不启用OAuth认证 "SSOPassport": "http://localhost:52789", "Version": "demo", diff --git a/OpenAuth.Mvc/wwwroot/userJs/categories.js b/OpenAuth.Mvc/wwwroot/userJs/categories.js index d957a474..a2eb26cf 100644 --- a/OpenAuth.Mvc/wwwroot/userJs/categories.js +++ b/OpenAuth.Mvc/wwwroot/userJs/categories.js @@ -78,6 +78,11 @@ layui.config({ }, mounted(){ form.render(); + var _this = this; + layui.droptree("/Categories/AllTypes", "#TypeName", "#TypeId", false,function (ids, names) { + _this.tmp.TypeName = ids; + _this.tmp.TypeId = names; + }); } }); }else{ diff --git a/OpenAuth.Mvc/wwwroot/userJs/flowInstanceEdit.js b/OpenAuth.Mvc/wwwroot/userJs/flowInstanceEdit.js index afe92fb3..ba044408 100644 --- a/OpenAuth.Mvc/wwwroot/userJs/flowInstanceEdit.js +++ b/OpenAuth.Mvc/wwwroot/userJs/flowInstanceEdit.js @@ -95,7 +95,7 @@ if (data.Result.FrmType == 0) { $("#frmPreview").html(data.Result.Html); } else { - $("#frmPreview").html('复杂表单暂时只能在企业版查看,开源版预计会在以后的开源版本中发布'); + $("#frmPreview").html('复杂表单暂时只能在企业版查看,开源版预计会在以后的开源版本中发布'); } } }); diff --git a/OpenAuth.Mvc/wwwroot/userJs/flowSchemeDesign.js b/OpenAuth.Mvc/wwwroot/userJs/flowSchemeDesign.js index aa0c9403..eb8d7e1b 100644 --- a/OpenAuth.Mvc/wwwroot/userJs/flowSchemeDesign.js +++ b/OpenAuth.Mvc/wwwroot/userJs/flowSchemeDesign.js @@ -47,7 +47,7 @@ if (data.Result.FrmType == 0) { _this.frmPreview = data.Result.Html } else { - _this.frmPreview = '复杂表单暂时只能在企业版查看,开源版预计会在以后的开源版本中发布' + _this.frmPreview = '复杂表单暂时只能在企业版查看,开源版预计会在以后的开源版本中发布' } }); } diff --git a/OpenAuth.Mvc/wwwroot/userJs/flowSchemePreview.js b/OpenAuth.Mvc/wwwroot/userJs/flowSchemePreview.js index aa932245..ae36b320 100644 --- a/OpenAuth.Mvc/wwwroot/userJs/flowSchemePreview.js +++ b/OpenAuth.Mvc/wwwroot/userJs/flowSchemePreview.js @@ -58,7 +58,7 @@ if (data.Result.FrmType == 0) { $("#frmPreview").html(data.Result.Html); } else { - $("#frmPreview").html("复杂表单暂时只能在企业版查看,开源版预计会在以后的开源版本中发布"); + $("#frmPreview").html("复杂表单暂时只能在企业版查看,开源版预计会在以后的开源版本中发布"); } }); }); diff --git a/OpenAuth.Mvc/wwwroot/userJs/flowinstanceDetail.js b/OpenAuth.Mvc/wwwroot/userJs/flowinstanceDetail.js index b2f26739..be68afec 100644 --- a/OpenAuth.Mvc/wwwroot/userJs/flowinstanceDetail.js +++ b/OpenAuth.Mvc/wwwroot/userJs/flowinstanceDetail.js @@ -51,7 +51,7 @@ if (data.Result.FrmType == 0) { $("#frmPreview").html(data.Result.FrmPreviewHtml); } else { - $("#frmPreview").html("复杂表单暂时只能在企业版查看,开源版预计会在以后的开源版本中发布"); + $("#frmPreview").html("复杂表单暂时只能在企业版查看,开源版预计会在以后的开源版本中发布"); } flowDesignPanel.reinitSize($(window).width() - 30, $(window).height() - 120); diff --git a/OpenAuth.Mvc/wwwroot/userJs/formEdit.js b/OpenAuth.Mvc/wwwroot/userJs/formEdit.js index 569ed478..a3108a7a 100644 --- a/OpenAuth.Mvc/wwwroot/userJs/formEdit.js +++ b/OpenAuth.Mvc/wwwroot/userJs/formEdit.js @@ -278,7 +278,7 @@ if (obj.FrmType === 0) { ue.setContent(obj.Content); } else { - ue.setContent("复杂表单暂时只能在企业版查看,开源版预计会在以后的开源版本中发布"); + ue.setContent("复杂表单暂时只能在企业版查看,开源版预计会在以后的开源版本中发布"); } }, 500); }); diff --git a/OpenAuth.Mvc/wwwroot/userJs/preview.js b/OpenAuth.Mvc/wwwroot/userJs/preview.js index fa6a0bf4..45178304 100644 --- a/OpenAuth.Mvc/wwwroot/userJs/preview.js +++ b/OpenAuth.Mvc/wwwroot/userJs/preview.js @@ -10,7 +10,7 @@ if (data.Result.FrmType == 0) { $("#content").html(data.Result.Html); } else { - $("#content").html("复杂表单暂时只能在企业版查看,开源版预计会在以后的开源版本中发布"); + $("#content").html("复杂表单暂时只能在企业版查看,开源版预计会在以后的开源版本中发布"); } }); diff --git a/OpenAuth.Mvc/wwwroot/userJs/verification.js b/OpenAuth.Mvc/wwwroot/userJs/verification.js index 1ddbbded..f3a89691 100644 --- a/OpenAuth.Mvc/wwwroot/userJs/verification.js +++ b/OpenAuth.Mvc/wwwroot/userJs/verification.js @@ -26,7 +26,7 @@ if (data.Result.FrmType == 0) { $("#frmPreview").html(data.Result.FrmPreviewHtml); } else { - $("#frmPreview").html("复杂表单暂时只能在企业版查看,开源版预计会在以后的开源版本中发布"); + $("#frmPreview").html("复杂表单暂时只能在企业版查看,开源版预计会在以后的开源版本中发布"); } //让层自适应iframe diff --git a/OpenAuth.Repository/Domain/UploadFile.cs b/OpenAuth.Repository/Domain/UploadFile.cs index c298f759..d0b58310 100644 --- a/OpenAuth.Repository/Domain/UploadFile.cs +++ b/OpenAuth.Repository/Domain/UploadFile.cs @@ -1,5 +1,5 @@ -// -// Copyright (c) 2019 openauth.me. All rights reserved. +// +// Copyright (c) 2019 openauth.net.cn. All rights reserved. // // www.cnblogs.com/yubaolee // 2019-03-07 diff --git a/OpenAuth.Repository/Interface/IUnitWork.cs b/OpenAuth.Repository/Interface/IUnitWork.cs index ecee9906..57ad2817 100644 --- a/OpenAuth.Repository/Interface/IUnitWork.cs +++ b/OpenAuth.Repository/Interface/IUnitWork.cs @@ -22,7 +22,7 @@ namespace OpenAuth.Repository.Interface { /// /// 工作单元接口 - /// 使用详见:http://doc.openauth.me/core/unitwork.html + /// 使用详见:http://doc.openauth.net.cn/core/unitwork.html /// 适合在一下情况使用: /// 1 在同一事务中进行多表操作 /// 2 需要多表联合查询 @@ -90,7 +90,7 @@ namespace OpenAuth.Repository.Interface void Save(); /// - /// 该方法不支持EF自带的事务,需要ExecuteWithTransaction配合才能实现事务控制,详见:http://doc.openauth.me/core/unitwork.html + /// 该方法不支持EF自带的事务,需要ExecuteWithTransaction配合才能实现事务控制,详见:http://doc.openauth.net.cn/core/unitwork.html /// /// /// diff --git a/OpenAuth.WebApi/Controllers/FlowInstancesController.cs b/OpenAuth.WebApi/Controllers/FlowInstancesController.cs index 3cb6878e..fd8a8ed3 100644 --- a/OpenAuth.WebApi/Controllers/FlowInstancesController.cs +++ b/OpenAuth.WebApi/Controllers/FlowInstancesController.cs @@ -1,5 +1,5 @@ -// -// Copyright (c) 2019 openauth.me. All rights reserved. +// +// Copyright (c) 2019 openauth.net.cn. All rights reserved. // // www.cnblogs.com/yubaolee // 2018-09-06 diff --git a/OpenAuth.WebApi/Controllers/FormsController.cs b/OpenAuth.WebApi/Controllers/FormsController.cs index 69d2b93c..14144ce4 100644 --- a/OpenAuth.WebApi/Controllers/FormsController.cs +++ b/OpenAuth.WebApi/Controllers/FormsController.cs @@ -19,13 +19,24 @@ namespace OpenAuth.WebApi.Controllers { private readonly FormApp _app; + /// + /// 获取表单 + /// + /// 表单ID + /// 针对动态表单项读写控制 + /// [HttpGet] - public Response Get(string id) + public Response Get(string id, string canWriteFormItemIds) { var result = new Response(); try { result.Result = _app.FindSingle(id); + + if (!string.IsNullOrEmpty(canWriteFormItemIds)) + { + result.Result.CanWriteFormItemIds = JsonHelper.Instance.Deserialize(canWriteFormItemIds); + } } catch (Exception ex) { diff --git a/OpenAuth.WebApi/Model/GlobalHttpHeaderOperationFilter.cs b/OpenAuth.WebApi/Model/GlobalHttpHeaderOperationFilter.cs index 9b15d2d2..33e2934f 100644 --- a/OpenAuth.WebApi/Model/GlobalHttpHeaderOperationFilter.cs +++ b/OpenAuth.WebApi/Model/GlobalHttpHeaderOperationFilter.cs @@ -1,5 +1,5 @@ -// -// Copyright (c) 2019 openauth.me. All rights reserved. +// +// Copyright (c) 2019 openauth.net.cn. All rights reserved. // // www.cnblogs.com/yubaolee // 2019-01-05 diff --git a/OpenAuth.WebApi/Startup.cs b/OpenAuth.WebApi/Startup.cs index fcfe4313..45457afe 100644 --- a/OpenAuth.WebApi/Startup.cs +++ b/OpenAuth.WebApi/Startup.cs @@ -155,8 +155,8 @@ namespace OpenAuth.WebApi // { // origins = new [] // { -// "http://demo.openauth.me:1803", -// "http://demo.openauth.me:52789" +// "http://demo.openauth.net.cn:1803", +// "http://demo.openauth.net.cn:52789" // }; // } // services.AddCors(option=>option.AddPolicy("cors", policy => diff --git a/OpenAuth.WebApi/Test/CheckControllerTest.cs b/OpenAuth.WebApi/Test/CheckControllerTest.cs index 5f74711b..713a53c9 100644 --- a/OpenAuth.WebApi/Test/CheckControllerTest.cs +++ b/OpenAuth.WebApi/Test/CheckControllerTest.cs @@ -1,5 +1,5 @@ // -// Copyright (c) http://www.openauth.me. All rights reserved. +// Copyright (c) http://www.openauth.net.cn. All rights reserved. // // // 测试加载用户菜单 diff --git a/OpenAuth.WebApi/appsettings.Production.json b/OpenAuth.WebApi/appsettings.Production.json index f4cc6092..d8353e06 100644 --- a/OpenAuth.WebApi/appsettings.Production.json +++ b/OpenAuth.WebApi/appsettings.Production.json @@ -13,7 +13,7 @@ }, "AppSetting": { "IdentityServerUrl": "", //IdentityServer服务器地址。如果为空,则不启用OAuth认证 - //"IdentityServerUrl": "http://demo.openauth.me:12796", //IdentityServer服务器地址。如果为空,则不启用OAuth认证 + //"IdentityServerUrl": "http://demo.openauth.net.cn:12796", //IdentityServer服务器地址。如果为空,则不启用OAuth认证 "DbTypes": { "OpenAuthDBContext":"MySql" //数据库类型:SqlServer、MySql、Oracle },