SysConfigService.cs 497 B

1234567891011121314151617
  1. using Infrastructure.Attribute;
  2. using ZR.Model.System;
  3. namespace ZR.ServiceCore.Services
  4. {
  5. /// <summary>
  6. /// 参数配置Service业务层处理
  7. /// </summary>
  8. [AppService(ServiceType = typeof(ISysConfigService), ServiceLifetime = LifeTime.Transient)]
  9. public class SysConfigService : BaseService<SysConfig>, ISysConfigService
  10. {
  11. public SysConfig GetSysConfigByKey(string key)
  12. {
  13. return Queryable().First(f => f.ConfigKey == key);
  14. }
  15. }
  16. }