服务端的TigerApi 框架,基于.NET6 2024 版本
Rodney Chen
2024-05-30 7e25ed322740ed337296a990bac67e95bc250ac0
Tiger.Api/Controllers/Base/SystemController.cs
@@ -7,6 +7,7 @@
using Rhea.Common;
using Tiger.IBusiness;
using System.Threading;
using System.Linq;
namespace Tiger.Api.Controllers.Base
{
@@ -95,6 +96,26 @@
        }
        /// <summary>
        /// 获取Api产品
        /// </summary>
        /// <returns></returns>
        [HttpGet]
        [Route("System/Base/[action]")]
        public IActionResult GetEntitys()
        {
            Assembly assembly = Assembly.Load("Tiger.Model");
            Type[] types = assembly.GetTypes();
            var entitys = types.Where(q => q.GetInterfaces().Contains(typeof(Model.iEntity)) && q.IsClass).ToList();
            var data = entitys.Select(q => new
            {
                q.Namespace,
                q.FullName,
                Properties = q.GetProperties().Select(p => new { p.Name, Type = p.PropertyType.Name }).ToList()
            });
            return Ok(data);
        }
        /// <summary>
        /// GetCertification(ApiAction)
        /// 在注册表HKEY_LOCAL_MACHINE\SOFTWARE\TigerClouds节点中读取密钥证书
        /// </summary>