Day2 fix: recreate device_manager entities and boilerplate
This commit is contained in:
@@ -0,0 +1,36 @@
|
||||
using SqlSugar;
|
||||
using VolPro.Entity.SystemModels;
|
||||
|
||||
namespace VolPro.Entity.DomainModels
|
||||
{
|
||||
[Entity(TableCnName="设备管理",TableName="base_device",DBServer="ServiceDbContext")]
|
||||
public partial class base_device : ServiceEntity
|
||||
{
|
||||
[SugarColumn(IsPrimaryKey=true,IsIdentity=true)] public int DeviceId { get; set; }
|
||||
public string DeviceName { get; set; } = "";
|
||||
[SugarColumn(IsPrimaryKey=true)] public string AdapterCode { get; set; } = "";
|
||||
public string SourceId { get; set; } = "";
|
||||
public string? DeviceCategory { get; set; }
|
||||
public string? DeviceGroup { get; set; }
|
||||
public int? PointId { get; set; }
|
||||
public int? GatewayNodeId { get; set; }
|
||||
public string? IsParent { get; set; }
|
||||
public int? ParentDeviceId { get; set; }
|
||||
public string? IsOnline { get; set; }
|
||||
public string? Enable { get; set; }
|
||||
public string? Protocol { get; set; }
|
||||
public string? IpAddress { get; set; }
|
||||
public int? Port { get; set; }
|
||||
public DateTime? LastSyncTime { get; set; }
|
||||
public string? MapModelId { get; set; }
|
||||
public string? MapModelScale { get; set; }
|
||||
public string? MapModelRotation { get; set; }
|
||||
public string? ExtraData { get; set; }
|
||||
public int? CreateID { get; set; }
|
||||
public string? Creator { get; set; }
|
||||
public DateTime? CreateDate { get; set; }
|
||||
public int? ModifyID { get; set; }
|
||||
public string? Modifier { get; set; }
|
||||
public DateTime? ModifyDate { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,25 @@
|
||||
using SqlSugar;
|
||||
using VolPro.Entity.SystemModels;
|
||||
|
||||
namespace VolPro.Entity.DomainModels
|
||||
{
|
||||
[Entity(TableCnName="网关节点",TableName="gateway_nodes",DBServer="ServiceDbContext")]
|
||||
public partial class gateway_nodes : ServiceEntity
|
||||
{
|
||||
[SugarColumn(IsPrimaryKey=true,IsIdentity=true)] public int NodeId { get; set; }
|
||||
public string NodeCode { get; set; } = "";
|
||||
public string? NodeName { get; set; }
|
||||
public string? NodeToken { get; set; }
|
||||
public string? AdapterTypes { get; set; }
|
||||
public string? BaseUrl { get; set; }
|
||||
public string? IsOnline { get; set; }
|
||||
public string? Enable { get; set; }
|
||||
public DateTime? LastHeartbeat { get; set; }
|
||||
public int? CreateID { get; set; }
|
||||
public string? Creator { get; set; }
|
||||
public DateTime? CreateDate { get; set; }
|
||||
public int? ModifyID { get; set; }
|
||||
public string? Modifier { get; set; }
|
||||
public DateTime? ModifyDate { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,24 @@
|
||||
using SqlSugar;
|
||||
using VolPro.Entity.SystemModels;
|
||||
|
||||
namespace VolPro.Entity.DomainModels
|
||||
{
|
||||
[Entity(TableCnName="告警记录",TableName="iot_alarm",DBServer="ServiceDbContext")]
|
||||
public partial class iot_alarm : ServiceEntity
|
||||
{
|
||||
[SugarColumn(IsPrimaryKey=true,IsIdentity=true)] public int AlarmId { get; set; }
|
||||
public string? SourceAlarmId { get; set; }
|
||||
public int? DeviceId { get; set; }
|
||||
public string? AdapterCode { get; set; }
|
||||
public string? AlarmLevel { get; set; }
|
||||
public string? AlarmDesc { get; set; }
|
||||
public double? AlarmValue { get; set; }
|
||||
public double? ThresholdValue { get; set; }
|
||||
public DateTime? StartTime { get; set; }
|
||||
public DateTime? EndTime { get; set; }
|
||||
public DateTime? ConfirmTime { get; set; }
|
||||
public string? State { get; set; }
|
||||
public string? ConfirmUser { get; set; }
|
||||
public DateTime? CreateDate { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
using SqlSugar;
|
||||
using VolPro.Entity.SystemModels;
|
||||
|
||||
namespace VolPro.Entity.DomainModels
|
||||
{
|
||||
[Entity(TableCnName="数据归档",TableName="iot_devicedata",DBServer="ServiceDbContext")]
|
||||
public partial class iot_devicedata : ServiceEntity
|
||||
{
|
||||
[SugarColumn(IsPrimaryKey=true,IsIdentity=true)] public int DataId { get; set; }
|
||||
public int? DeviceId { get; set; }
|
||||
public string? AdapterCode { get; set; }
|
||||
public int? PointIndex { get; set; }
|
||||
public double? Value { get; set; }
|
||||
public DateTime? UpdateTime { get; set; }
|
||||
public DateTime? CreateDate { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
namespace VolPro.Entity.DomainModels { public partial class base_device { } }
|
||||
@@ -0,0 +1 @@
|
||||
namespace VolPro.Entity.DomainModels { public partial class gateway_nodes { } }
|
||||
@@ -0,0 +1 @@
|
||||
namespace VolPro.Entity.DomainModels { public partial class iot_alarm { } }
|
||||
@@ -0,0 +1 @@
|
||||
namespace VolPro.Entity.DomainModels { public partial class iot_devicedata { } }
|
||||
@@ -0,0 +1 @@
|
||||
namespace VolPro.Entity.DomainModels { public partial class video_channel { } }
|
||||
@@ -0,0 +1 @@
|
||||
namespace VolPro.Entity.DomainModels { public partial class video_record { } }
|
||||
@@ -0,0 +1,17 @@
|
||||
using SqlSugar;
|
||||
using VolPro.Entity.SystemModels;
|
||||
|
||||
namespace VolPro.Entity.DomainModels
|
||||
{
|
||||
[Entity(TableCnName="视频通道",TableName="video_channel",DBServer="ServiceDbContext")]
|
||||
public partial class video_channel : ServiceEntity
|
||||
{
|
||||
[SugarColumn(IsPrimaryKey=true)] public int ChannelId { get; set; }
|
||||
[SugarColumn(IsPrimaryKey=true)] public int DeviceId { get; set; }
|
||||
public string? ChannelNo { get; set; }
|
||||
public string? SourceId { get; set; }
|
||||
public string? ChannelName { get; set; }
|
||||
public string? IsOnline { get; set; }
|
||||
public DateTime? CreateDate { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
using SqlSugar;
|
||||
using VolPro.Entity.SystemModels;
|
||||
|
||||
namespace VolPro.Entity.DomainModels
|
||||
{
|
||||
[Entity(TableCnName="录像文件",TableName="video_record",DBServer="ServiceDbContext")]
|
||||
public partial class video_record : ServiceEntity
|
||||
{
|
||||
[SugarColumn(IsPrimaryKey=true,IsIdentity=true)] public int RecordId { get; set; }
|
||||
public int? ChannelId { get; set; }
|
||||
public string? FilePath { get; set; }
|
||||
public long? Size { get; set; }
|
||||
public DateTime? StartTime { get; set; }
|
||||
public DateTime? EndTime { get; set; }
|
||||
public double? Duration { get; set; }
|
||||
public DateTime? CreateDate { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using VolPro.Core.Controllers.Basic;
|
||||
using VolPro.Entity.AttributeManager;
|
||||
using Warehouse.IServices;
|
||||
|
||||
namespace Warehouse.Controllers
|
||||
{
|
||||
[Route("api/base_device")]
|
||||
[PermissionTable(Name = "base_device")]
|
||||
public partial class base_deviceController : ApiBaseController<Ibase_deviceService>
|
||||
{
|
||||
public base_deviceController(Ibase_deviceService service) : base(service) { }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using VolPro.Core.Controllers.Basic;
|
||||
using VolPro.Entity.AttributeManager;
|
||||
using Warehouse.IServices;
|
||||
|
||||
namespace Warehouse.Controllers
|
||||
{
|
||||
[Route("api/gateway_nodes")]
|
||||
[PermissionTable(Name = "gateway_nodes")]
|
||||
public partial class gateway_nodesController : ApiBaseController<Igateway_nodesService>
|
||||
{
|
||||
public gateway_nodesController(Igateway_nodesService service) : base(service) { }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using VolPro.Core.Controllers.Basic;
|
||||
using VolPro.Entity.AttributeManager;
|
||||
using Warehouse.IServices;
|
||||
|
||||
namespace Warehouse.Controllers
|
||||
{
|
||||
[Route("api/iot_alarm")]
|
||||
[PermissionTable(Name = "iot_alarm")]
|
||||
public partial class iot_alarmController : ApiBaseController<Iiot_alarmService>
|
||||
{
|
||||
public iot_alarmController(Iiot_alarmService service) : base(service) { }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using VolPro.Core.Controllers.Basic;
|
||||
using VolPro.Entity.AttributeManager;
|
||||
using Warehouse.IServices;
|
||||
|
||||
namespace Warehouse.Controllers
|
||||
{
|
||||
[Route("api/iot_devicedata")]
|
||||
[PermissionTable(Name = "iot_devicedata")]
|
||||
public partial class iot_devicedataController : ApiBaseController<Iiot_devicedataService>
|
||||
{
|
||||
public iot_devicedataController(Iiot_devicedataService service) : base(service) { }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using VolPro.Core.Controllers.Basic;
|
||||
using VolPro.Entity.AttributeManager;
|
||||
using Warehouse.IServices;
|
||||
|
||||
namespace Warehouse.Controllers
|
||||
{
|
||||
[Route("api/video_channel")]
|
||||
[PermissionTable(Name = "video_channel")]
|
||||
public partial class video_channelController : ApiBaseController<Ivideo_channelService>
|
||||
{
|
||||
public video_channelController(Ivideo_channelService service) : base(service) { }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using VolPro.Core.Controllers.Basic;
|
||||
using VolPro.Entity.AttributeManager;
|
||||
using Warehouse.IServices;
|
||||
|
||||
namespace Warehouse.Controllers
|
||||
{
|
||||
[Route("api/video_record")]
|
||||
[PermissionTable(Name = "video_record")]
|
||||
public partial class video_recordController : ApiBaseController<Ivideo_recordService>
|
||||
{
|
||||
public video_recordController(Ivideo_recordService service) : base(service) { }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Entity.DomainModels;
|
||||
|
||||
namespace Warehouse.IRepositories
|
||||
{
|
||||
public partial interface Ibase_deviceRepository : IRepository<base_device>
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Entity.DomainModels;
|
||||
|
||||
namespace Warehouse.IRepositories
|
||||
{
|
||||
public partial interface Igateway_nodesRepository : IRepository<gateway_nodes>
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Entity.DomainModels;
|
||||
|
||||
namespace Warehouse.IRepositories
|
||||
{
|
||||
public partial interface Iiot_alarmRepository : IRepository<iot_alarm>
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Entity.DomainModels;
|
||||
|
||||
namespace Warehouse.IRepositories
|
||||
{
|
||||
public partial interface Iiot_devicedataRepository : IRepository<iot_devicedata>
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Entity.DomainModels;
|
||||
|
||||
namespace Warehouse.IRepositories
|
||||
{
|
||||
public partial interface Ivideo_channelRepository : IRepository<video_channel>
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Entity.DomainModels;
|
||||
|
||||
namespace Warehouse.IRepositories
|
||||
{
|
||||
public partial interface Ivideo_recordRepository : IRepository<video_record>
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Entity.DomainModels;
|
||||
|
||||
namespace Warehouse.IServices
|
||||
{
|
||||
public partial interface Ibase_deviceService : IService<base_device>
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Entity.DomainModels;
|
||||
|
||||
namespace Warehouse.IServices
|
||||
{
|
||||
public partial interface Igateway_nodesService : IService<gateway_nodes>
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Entity.DomainModels;
|
||||
|
||||
namespace Warehouse.IServices
|
||||
{
|
||||
public partial interface Iiot_alarmService : IService<iot_alarm>
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Entity.DomainModels;
|
||||
|
||||
namespace Warehouse.IServices
|
||||
{
|
||||
public partial interface Iiot_devicedataService : IService<iot_devicedata>
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Entity.DomainModels;
|
||||
|
||||
namespace Warehouse.IServices
|
||||
{
|
||||
public partial interface Ivideo_channelService : IService<video_channel>
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Entity.DomainModels;
|
||||
|
||||
namespace Warehouse.IServices
|
||||
{
|
||||
public partial interface Ivideo_recordService : IService<video_record>
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
namespace Warehouse.IServices
|
||||
{
|
||||
public partial interface Ibase_deviceService
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
namespace Warehouse.IServices
|
||||
{
|
||||
public partial interface Igateway_nodesService
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
namespace Warehouse.IServices
|
||||
{
|
||||
public partial interface Iiot_alarmService
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
namespace Warehouse.IServices
|
||||
{
|
||||
public partial interface Iiot_devicedataService
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
namespace Warehouse.IServices
|
||||
{
|
||||
public partial interface Ivideo_channelService
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
namespace Warehouse.IServices
|
||||
{
|
||||
public partial interface Ivideo_recordService
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Entity.DomainModels;
|
||||
using Warehouse.IRepositories;
|
||||
|
||||
namespace Warehouse.Repositories
|
||||
{
|
||||
public partial class base_deviceRepository : RepositoryBase<base_device>, Ibase_deviceRepository
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Entity.DomainModels;
|
||||
using Warehouse.IRepositories;
|
||||
|
||||
namespace Warehouse.Repositories
|
||||
{
|
||||
public partial class gateway_nodesRepository : RepositoryBase<gateway_nodes>, Igateway_nodesRepository
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Entity.DomainModels;
|
||||
using Warehouse.IRepositories;
|
||||
|
||||
namespace Warehouse.Repositories
|
||||
{
|
||||
public partial class iot_alarmRepository : RepositoryBase<iot_alarm>, Iiot_alarmRepository
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Entity.DomainModels;
|
||||
using Warehouse.IRepositories;
|
||||
|
||||
namespace Warehouse.Repositories
|
||||
{
|
||||
public partial class iot_devicedataRepository : RepositoryBase<iot_devicedata>, Iiot_devicedataRepository
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Entity.DomainModels;
|
||||
using Warehouse.IRepositories;
|
||||
|
||||
namespace Warehouse.Repositories
|
||||
{
|
||||
public partial class video_channelRepository : RepositoryBase<video_channel>, Ivideo_channelRepository
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Entity.DomainModels;
|
||||
using Warehouse.IRepositories;
|
||||
|
||||
namespace Warehouse.Repositories
|
||||
{
|
||||
public partial class video_recordRepository : RepositoryBase<video_record>, Ivideo_recordRepository
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -1,41 +1,19 @@
|
||||
/*
|
||||
*所有关于base_device类的业务代码应在此处编写
|
||||
*可使用repository.调用常用方法,获取EF/Dapper等信息
|
||||
*如果需要事务请使用repository.DbContextBeginTransaction
|
||||
*也可使用DBServerProvider.手动获取数据库相关信息
|
||||
*用户信息、权限、角色等使用UserContext.Current操作
|
||||
*base_deviceService对增、删、改查、导入、导出、审核业务代码扩展参照ServiceFunFilter
|
||||
*/
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Core.Extensions.AutofacManager;
|
||||
using VolPro.Entity.DomainModels;
|
||||
using System.Linq;
|
||||
using VolPro.Core.Utilities;
|
||||
using System.Linq.Expressions;
|
||||
using VolPro.Core.Extensions;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Warehouse.IRepositories;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
|
||||
namespace Warehouse.Services
|
||||
{
|
||||
public partial class base_deviceService
|
||||
{
|
||||
private readonly IHttpContextAccessor _httpContextAccessor;
|
||||
private readonly Ibase_deviceRepository _repository;//访问数据库
|
||||
private readonly Ibase_deviceRepository _repository;
|
||||
|
||||
[ActivatorUtilitiesConstructor]
|
||||
public base_deviceService(
|
||||
Ibase_deviceRepository dbRepository,
|
||||
IHttpContextAccessor httpContextAccessor
|
||||
)
|
||||
: base(dbRepository)
|
||||
public base_deviceService(Ibase_deviceRepository dbRepository, IHttpContextAccessor httpContextAccessor) : base(dbRepository)
|
||||
{
|
||||
_httpContextAccessor = httpContextAccessor;
|
||||
_repository = dbRepository;
|
||||
//多租户会用到这init代码,其他情况可以不用
|
||||
//base.Init(dbRepository);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,41 +1,19 @@
|
||||
/*
|
||||
*所有关于gateway_nodes类的业务代码应在此处编写
|
||||
*可使用repository.调用常用方法,获取EF/Dapper等信息
|
||||
*如果需要事务请使用repository.DbContextBeginTransaction
|
||||
*也可使用DBServerProvider.手动获取数据库相关信息
|
||||
*用户信息、权限、角色等使用UserContext.Current操作
|
||||
*gateway_nodesService对增、删、改查、导入、导出、审核业务代码扩展参照ServiceFunFilter
|
||||
*/
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Core.Extensions.AutofacManager;
|
||||
using VolPro.Entity.DomainModels;
|
||||
using System.Linq;
|
||||
using VolPro.Core.Utilities;
|
||||
using System.Linq.Expressions;
|
||||
using VolPro.Core.Extensions;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Warehouse.IRepositories;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
|
||||
namespace Warehouse.Services
|
||||
{
|
||||
public partial class gateway_nodesService
|
||||
{
|
||||
private readonly IHttpContextAccessor _httpContextAccessor;
|
||||
private readonly Igateway_nodesRepository _repository;//访问数据库
|
||||
private readonly Igateway_nodesRepository _repository;
|
||||
|
||||
[ActivatorUtilitiesConstructor]
|
||||
public gateway_nodesService(
|
||||
Igateway_nodesRepository dbRepository,
|
||||
IHttpContextAccessor httpContextAccessor
|
||||
)
|
||||
: base(dbRepository)
|
||||
public gateway_nodesService(Igateway_nodesRepository dbRepository, IHttpContextAccessor httpContextAccessor) : base(dbRepository)
|
||||
{
|
||||
_httpContextAccessor = httpContextAccessor;
|
||||
_repository = dbRepository;
|
||||
//多租户会用到这init代码,其他情况可以不用
|
||||
//base.Init(dbRepository);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,41 +1,19 @@
|
||||
/*
|
||||
*所有关于iot_alarm类的业务代码应在此处编写
|
||||
*可使用repository.调用常用方法,获取EF/Dapper等信息
|
||||
*如果需要事务请使用repository.DbContextBeginTransaction
|
||||
*也可使用DBServerProvider.手动获取数据库相关信息
|
||||
*用户信息、权限、角色等使用UserContext.Current操作
|
||||
*iot_alarmService对增、删、改查、导入、导出、审核业务代码扩展参照ServiceFunFilter
|
||||
*/
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Core.Extensions.AutofacManager;
|
||||
using VolPro.Entity.DomainModels;
|
||||
using System.Linq;
|
||||
using VolPro.Core.Utilities;
|
||||
using System.Linq.Expressions;
|
||||
using VolPro.Core.Extensions;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Warehouse.IRepositories;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
|
||||
namespace Warehouse.Services
|
||||
{
|
||||
public partial class iot_alarmService
|
||||
{
|
||||
private readonly IHttpContextAccessor _httpContextAccessor;
|
||||
private readonly Iiot_alarmRepository _repository;//访问数据库
|
||||
private readonly Iiot_alarmRepository _repository;
|
||||
|
||||
[ActivatorUtilitiesConstructor]
|
||||
public iot_alarmService(
|
||||
Iiot_alarmRepository dbRepository,
|
||||
IHttpContextAccessor httpContextAccessor
|
||||
)
|
||||
: base(dbRepository)
|
||||
public iot_alarmService(Iiot_alarmRepository dbRepository, IHttpContextAccessor httpContextAccessor) : base(dbRepository)
|
||||
{
|
||||
_httpContextAccessor = httpContextAccessor;
|
||||
_repository = dbRepository;
|
||||
//多租户会用到这init代码,其他情况可以不用
|
||||
//base.Init(dbRepository);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,41 +1,19 @@
|
||||
/*
|
||||
*所有关于iot_devicedata类的业务代码应在此处编写
|
||||
*可使用repository.调用常用方法,获取EF/Dapper等信息
|
||||
*如果需要事务请使用repository.DbContextBeginTransaction
|
||||
*也可使用DBServerProvider.手动获取数据库相关信息
|
||||
*用户信息、权限、角色等使用UserContext.Current操作
|
||||
*iot_devicedataService对增、删、改查、导入、导出、审核业务代码扩展参照ServiceFunFilter
|
||||
*/
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Core.Extensions.AutofacManager;
|
||||
using VolPro.Entity.DomainModels;
|
||||
using System.Linq;
|
||||
using VolPro.Core.Utilities;
|
||||
using System.Linq.Expressions;
|
||||
using VolPro.Core.Extensions;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Warehouse.IRepositories;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
|
||||
namespace Warehouse.Services
|
||||
{
|
||||
public partial class iot_devicedataService
|
||||
{
|
||||
private readonly IHttpContextAccessor _httpContextAccessor;
|
||||
private readonly Iiot_devicedataRepository _repository;//访问数据库
|
||||
private readonly Iiot_devicedataRepository _repository;
|
||||
|
||||
[ActivatorUtilitiesConstructor]
|
||||
public iot_devicedataService(
|
||||
Iiot_devicedataRepository dbRepository,
|
||||
IHttpContextAccessor httpContextAccessor
|
||||
)
|
||||
: base(dbRepository)
|
||||
public iot_devicedataService(Iiot_devicedataRepository dbRepository, IHttpContextAccessor httpContextAccessor) : base(dbRepository)
|
||||
{
|
||||
_httpContextAccessor = httpContextAccessor;
|
||||
_repository = dbRepository;
|
||||
//多租户会用到这init代码,其他情况可以不用
|
||||
//base.Init(dbRepository);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,41 +1,19 @@
|
||||
/*
|
||||
*所有关于video_channel类的业务代码应在此处编写
|
||||
*可使用repository.调用常用方法,获取EF/Dapper等信息
|
||||
*如果需要事务请使用repository.DbContextBeginTransaction
|
||||
*也可使用DBServerProvider.手动获取数据库相关信息
|
||||
*用户信息、权限、角色等使用UserContext.Current操作
|
||||
*video_channelService对增、删、改查、导入、导出、审核业务代码扩展参照ServiceFunFilter
|
||||
*/
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Core.Extensions.AutofacManager;
|
||||
using VolPro.Entity.DomainModels;
|
||||
using System.Linq;
|
||||
using VolPro.Core.Utilities;
|
||||
using System.Linq.Expressions;
|
||||
using VolPro.Core.Extensions;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Warehouse.IRepositories;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
|
||||
namespace Warehouse.Services
|
||||
{
|
||||
public partial class video_channelService
|
||||
{
|
||||
private readonly IHttpContextAccessor _httpContextAccessor;
|
||||
private readonly Ivideo_channelRepository _repository;//访问数据库
|
||||
private readonly Ivideo_channelRepository _repository;
|
||||
|
||||
[ActivatorUtilitiesConstructor]
|
||||
public video_channelService(
|
||||
Ivideo_channelRepository dbRepository,
|
||||
IHttpContextAccessor httpContextAccessor
|
||||
)
|
||||
: base(dbRepository)
|
||||
public video_channelService(Ivideo_channelRepository dbRepository, IHttpContextAccessor httpContextAccessor) : base(dbRepository)
|
||||
{
|
||||
_httpContextAccessor = httpContextAccessor;
|
||||
_repository = dbRepository;
|
||||
//多租户会用到这init代码,其他情况可以不用
|
||||
//base.Init(dbRepository);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,41 +1,19 @@
|
||||
/*
|
||||
*所有关于video_record类的业务代码应在此处编写
|
||||
*可使用repository.调用常用方法,获取EF/Dapper等信息
|
||||
*如果需要事务请使用repository.DbContextBeginTransaction
|
||||
*也可使用DBServerProvider.手动获取数据库相关信息
|
||||
*用户信息、权限、角色等使用UserContext.Current操作
|
||||
*video_recordService对增、删、改查、导入、导出、审核业务代码扩展参照ServiceFunFilter
|
||||
*/
|
||||
using VolPro.Core.BaseProvider;
|
||||
using VolPro.Core.Extensions.AutofacManager;
|
||||
using VolPro.Entity.DomainModels;
|
||||
using System.Linq;
|
||||
using VolPro.Core.Utilities;
|
||||
using System.Linq.Expressions;
|
||||
using VolPro.Core.Extensions;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Warehouse.IRepositories;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
|
||||
namespace Warehouse.Services
|
||||
{
|
||||
public partial class video_recordService
|
||||
{
|
||||
private readonly IHttpContextAccessor _httpContextAccessor;
|
||||
private readonly Ivideo_recordRepository _repository;//访问数据库
|
||||
private readonly Ivideo_recordRepository _repository;
|
||||
|
||||
[ActivatorUtilitiesConstructor]
|
||||
public video_recordService(
|
||||
Ivideo_recordRepository dbRepository,
|
||||
IHttpContextAccessor httpContextAccessor
|
||||
)
|
||||
: base(dbRepository)
|
||||
public video_recordService(Ivideo_recordRepository dbRepository, IHttpContextAccessor httpContextAccessor) : base(dbRepository)
|
||||
{
|
||||
_httpContextAccessor = httpContextAccessor;
|
||||
_repository = dbRepository;
|
||||
//多租户会用到这init代码,其他情况可以不用
|
||||
//base.Init(dbRepository);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,9 +1,3 @@
|
||||
/*
|
||||
*Author:jxx
|
||||
*Contact:283591387@qq.com
|
||||
*代码由框架生成,此处任何更改都可能导致被代码生成器覆盖
|
||||
*所有业务编写全部应在Partial文件夹下base_deviceService与Ibase_deviceService中编写
|
||||
*/
|
||||
using Warehouse.IRepositories;
|
||||
using Warehouse.IServices;
|
||||
using VolPro.Core.BaseProvider;
|
||||
@@ -12,11 +6,11 @@ using VolPro.Entity.DomainModels;
|
||||
|
||||
namespace Warehouse.Services
|
||||
{
|
||||
public partial class base_deviceService : ServiceBase<base_device, Ibase_deviceRepository>
|
||||
, Ibase_deviceService, IDependency
|
||||
public partial class base_deviceService : ServiceBase<base_device, Ibase_deviceRepository>, Ibase_deviceService, IDependency
|
||||
{
|
||||
public static Ibase_deviceService Instance
|
||||
{
|
||||
get { return AutofacContainerModule.GetService<Ibase_deviceService>(); } }
|
||||
public static Ibase_deviceService Instance
|
||||
{
|
||||
get { return AutofacContainerModule.GetService<Ibase_deviceService>(); }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,9 +1,3 @@
|
||||
/*
|
||||
*Author:jxx
|
||||
*Contact:283591387@qq.com
|
||||
*代码由框架生成,此处任何更改都可能导致被代码生成器覆盖
|
||||
*所有业务编写全部应在Partial文件夹下gateway_nodesService与Igateway_nodesService中编写
|
||||
*/
|
||||
using Warehouse.IRepositories;
|
||||
using Warehouse.IServices;
|
||||
using VolPro.Core.BaseProvider;
|
||||
@@ -12,11 +6,11 @@ using VolPro.Entity.DomainModels;
|
||||
|
||||
namespace Warehouse.Services
|
||||
{
|
||||
public partial class gateway_nodesService : ServiceBase<gateway_nodes, Igateway_nodesRepository>
|
||||
, Igateway_nodesService, IDependency
|
||||
public partial class gateway_nodesService : ServiceBase<gateway_nodes, Igateway_nodesRepository>, Igateway_nodesService, IDependency
|
||||
{
|
||||
public static Igateway_nodesService Instance
|
||||
{
|
||||
get { return AutofacContainerModule.GetService<Igateway_nodesService>(); } }
|
||||
public static Igateway_nodesService Instance
|
||||
{
|
||||
get { return AutofacContainerModule.GetService<Igateway_nodesService>(); }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,9 +1,3 @@
|
||||
/*
|
||||
*Author:jxx
|
||||
*Contact:283591387@qq.com
|
||||
*代码由框架生成,此处任何更改都可能导致被代码生成器覆盖
|
||||
*所有业务编写全部应在Partial文件夹下iot_alarmService与Iiot_alarmService中编写
|
||||
*/
|
||||
using Warehouse.IRepositories;
|
||||
using Warehouse.IServices;
|
||||
using VolPro.Core.BaseProvider;
|
||||
@@ -12,11 +6,11 @@ using VolPro.Entity.DomainModels;
|
||||
|
||||
namespace Warehouse.Services
|
||||
{
|
||||
public partial class iot_alarmService : ServiceBase<iot_alarm, Iiot_alarmRepository>
|
||||
, Iiot_alarmService, IDependency
|
||||
public partial class iot_alarmService : ServiceBase<iot_alarm, Iiot_alarmRepository>, Iiot_alarmService, IDependency
|
||||
{
|
||||
public static Iiot_alarmService Instance
|
||||
{
|
||||
get { return AutofacContainerModule.GetService<Iiot_alarmService>(); } }
|
||||
public static Iiot_alarmService Instance
|
||||
{
|
||||
get { return AutofacContainerModule.GetService<Iiot_alarmService>(); }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,9 +1,3 @@
|
||||
/*
|
||||
*Author:jxx
|
||||
*Contact:283591387@qq.com
|
||||
*代码由框架生成,此处任何更改都可能导致被代码生成器覆盖
|
||||
*所有业务编写全部应在Partial文件夹下iot_devicedataService与Iiot_devicedataService中编写
|
||||
*/
|
||||
using Warehouse.IRepositories;
|
||||
using Warehouse.IServices;
|
||||
using VolPro.Core.BaseProvider;
|
||||
@@ -12,11 +6,11 @@ using VolPro.Entity.DomainModels;
|
||||
|
||||
namespace Warehouse.Services
|
||||
{
|
||||
public partial class iot_devicedataService : ServiceBase<iot_devicedata, Iiot_devicedataRepository>
|
||||
, Iiot_devicedataService, IDependency
|
||||
public partial class iot_devicedataService : ServiceBase<iot_devicedata, Iiot_devicedataRepository>, Iiot_devicedataService, IDependency
|
||||
{
|
||||
public static Iiot_devicedataService Instance
|
||||
{
|
||||
get { return AutofacContainerModule.GetService<Iiot_devicedataService>(); } }
|
||||
public static Iiot_devicedataService Instance
|
||||
{
|
||||
get { return AutofacContainerModule.GetService<Iiot_devicedataService>(); }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,9 +1,3 @@
|
||||
/*
|
||||
*Author:jxx
|
||||
*Contact:283591387@qq.com
|
||||
*代码由框架生成,此处任何更改都可能导致被代码生成器覆盖
|
||||
*所有业务编写全部应在Partial文件夹下video_channelService与Ivideo_channelService中编写
|
||||
*/
|
||||
using Warehouse.IRepositories;
|
||||
using Warehouse.IServices;
|
||||
using VolPro.Core.BaseProvider;
|
||||
@@ -12,11 +6,11 @@ using VolPro.Entity.DomainModels;
|
||||
|
||||
namespace Warehouse.Services
|
||||
{
|
||||
public partial class video_channelService : ServiceBase<video_channel, Ivideo_channelRepository>
|
||||
, Ivideo_channelService, IDependency
|
||||
public partial class video_channelService : ServiceBase<video_channel, Ivideo_channelRepository>, Ivideo_channelService, IDependency
|
||||
{
|
||||
public static Ivideo_channelService Instance
|
||||
{
|
||||
get { return AutofacContainerModule.GetService<Ivideo_channelService>(); } }
|
||||
public static Ivideo_channelService Instance
|
||||
{
|
||||
get { return AutofacContainerModule.GetService<Ivideo_channelService>(); }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,9 +1,3 @@
|
||||
/*
|
||||
*Author:jxx
|
||||
*Contact:283591387@qq.com
|
||||
*代码由框架生成,此处任何更改都可能导致被代码生成器覆盖
|
||||
*所有业务编写全部应在Partial文件夹下video_recordService与Ivideo_recordService中编写
|
||||
*/
|
||||
using Warehouse.IRepositories;
|
||||
using Warehouse.IServices;
|
||||
using VolPro.Core.BaseProvider;
|
||||
@@ -12,11 +6,11 @@ using VolPro.Entity.DomainModels;
|
||||
|
||||
namespace Warehouse.Services
|
||||
{
|
||||
public partial class video_recordService : ServiceBase<video_record, Ivideo_recordRepository>
|
||||
, Ivideo_recordService, IDependency
|
||||
public partial class video_recordService : ServiceBase<video_record, Ivideo_recordRepository>, Ivideo_recordService, IDependency
|
||||
{
|
||||
public static Ivideo_recordService Instance
|
||||
{
|
||||
get { return AutofacContainerModule.GetService<Ivideo_recordService>(); } }
|
||||
public static Ivideo_recordService Instance
|
||||
{
|
||||
get { return AutofacContainerModule.GetService<Ivideo_recordService>(); }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user