Compare commits
No commits in common. "de443b5fa8cde7d7c8f4532d236c46f75dcfbc1c" and "7f5c578d785cc5908de0a044c4ed601231e247e8" have entirely different histories.
de443b5fa8
...
7f5c578d78
@ -2,7 +2,7 @@
|
|||||||
<!-- 定义项目加载属性 -->
|
<!-- 定义项目加载属性 -->
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<!--JiShe.ServicePro版本-->
|
<!--JiShe.ServicePro版本-->
|
||||||
<ServiceProVersion>1.0.5.26</ServiceProVersion>
|
<ServiceProVersion>1.0.5.22</ServiceProVersion>
|
||||||
<!--Volo Abp 版本-->
|
<!--Volo Abp 版本-->
|
||||||
<VoloAbpVersion>9.1.1</VoloAbpVersion>
|
<VoloAbpVersion>9.1.1</VoloAbpVersion>
|
||||||
|
|
||||||
|
|||||||
@ -5,12 +5,8 @@
|
|||||||
},
|
},
|
||||||
"ConnectionStrings": {
|
"ConnectionStrings": {
|
||||||
"Default": "Data Source=47.110.60.222;Port=13306;Database=JiSheIoTProDB;uid=root;pwd=JiShe!aqG#5kGgh&0;charset=utf8mb4;Allow User Variables=true;AllowLoadLocalInfile=true;",
|
"Default": "Data Source=47.110.60.222;Port=13306;Database=JiSheIoTProDB;uid=root;pwd=JiShe!aqG#5kGgh&0;charset=utf8mb4;Allow User Variables=true;AllowLoadLocalInfile=true;",
|
||||||
//"PrepayDB": "server=118.190.144.92;database=jishe.sysdb;uid=sa;pwd=admin@2023;Encrypt=False;Trust Server Certificate=False",
|
"PrepayDB": "server=118.190.144.92;database=jishe.sysdb;uid=sa;pwd=admin@2023;Encrypt=False;Trust Server Certificate=False",
|
||||||
//"EnergyDB": "server=118.190.144.92;database=db_energy;uid=sa;pwd=admin@2023;Encrypt=False;Trust Server Certificate=False"
|
"EnergyDB": "server=118.190.144.92;database=db_energy;uid=sa;pwd=admin@2023;Encrypt=False;Trust Server Certificate=False"
|
||||||
|
|
||||||
// 正式
|
|
||||||
"PrepayDB": "server=rm-m5el3d1u1k0wzk70n2o.sqlserver.rds.aliyuncs.com,3433;database=jishe.sysdb;uid=v3sa;pwd=JiShe123;Encrypt=False;Trust Server Certificate=False",
|
|
||||||
"EnergyDB": "server=rm-wz9hw529i3j1e3b5fbo.sqlserver.rds.aliyuncs.com,3433;database=db_energy;uid=yjdb;pwd=Kdjdhf+9*7ad222LL;Encrypt=False;Trust Server Certificate=False"
|
|
||||||
},
|
},
|
||||||
"Hangfire": {
|
"Hangfire": {
|
||||||
"Redis": {
|
"Redis": {
|
||||||
@ -67,12 +63,12 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"FreeRedisOptions": {
|
"FreeRedisOptions": {
|
||||||
"ConnectionString": "47.110.53.196:6379,password=1q3J@BGf!yhTaD46nS#,abortConnect=false,connectTimeout=30000,allowAdmin=true,maxPoolSize=500,defaultdatabase=10",
|
"ConnectionString": "47.110.53.196:6379,password=1q3J@BGf!yhTaD46nS#,abortConnect=false,connectTimeout=30000,allowAdmin=true,maxPoolSize=50,defaultdatabase=14",
|
||||||
"UseDistributedCache": true
|
"UseDistributedCache": true
|
||||||
},
|
},
|
||||||
"FreeSqlProviderOptions": {
|
"FreeSqlProviderOptions": {
|
||||||
"UsePrepayDB": true,
|
"UsePrepayDB": true,
|
||||||
"UseEnergyDB": true,
|
"UseEnergyDB": false,
|
||||||
"PrintLog": false
|
"PrintLog": false
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -32,7 +32,7 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"FreeRedisOptions": {
|
"FreeRedisOptions": {
|
||||||
"ConnectionString": "172.21.40.198:6379,password=1q3J@BGf!yhTaD46nS#,syncTimeout=30000,abortConnect=false,connectTimeout=30000,allowAdmin=true,maxPoolSize=500,defaultdatabase=14",
|
"ConnectionString": "172.21.40.198:6379,password=1q3J@BGf!yhTaD46nS#,syncTimeout=30000,abortConnect=false,connectTimeout=30000,allowAdmin=true,maxPoolSize=50,defaultdatabase=14",
|
||||||
"UseDistributedCache": true
|
"UseDistributedCache": true
|
||||||
},
|
},
|
||||||
"FreeSqlProviderOptions": {
|
"FreeSqlProviderOptions": {
|
||||||
|
|||||||
@ -1,5 +1,3 @@
|
|||||||
using JiShe.IoT.Jobs.ToMysql;
|
|
||||||
using JiShe.IoT.Jobs.ToRedis;
|
|
||||||
using JiShe.ServicePro.DeviceManagement;
|
using JiShe.ServicePro.DeviceManagement;
|
||||||
using JiShe.ServicePro.DynamicMenuManagement;
|
using JiShe.ServicePro.DynamicMenuManagement;
|
||||||
using JiShe.ServicePro.FileManagement;
|
using JiShe.ServicePro.FileManagement;
|
||||||
@ -7,7 +5,6 @@ using JiShe.ServicePro.FreeRedisProvider;
|
|||||||
using JiShe.ServicePro.FreeSqlProvider;
|
using JiShe.ServicePro.FreeSqlProvider;
|
||||||
using JiShe.ServicePro.IoTDBManagement;
|
using JiShe.ServicePro.IoTDBManagement;
|
||||||
using JiShe.ServicePro.TemplateManagement;
|
using JiShe.ServicePro.TemplateManagement;
|
||||||
using Microsoft.Extensions.DependencyInjection;
|
|
||||||
|
|
||||||
namespace JiShe.IoT
|
namespace JiShe.IoT
|
||||||
{
|
{
|
||||||
@ -23,7 +20,6 @@ namespace JiShe.IoT
|
|||||||
typeof(FileManagementApplicationModule),
|
typeof(FileManagementApplicationModule),
|
||||||
typeof(IoTDBManagementApplicationModule),
|
typeof(IoTDBManagementApplicationModule),
|
||||||
typeof(ServiceProFreeRedisProviderModule),
|
typeof(ServiceProFreeRedisProviderModule),
|
||||||
typeof(ServiceProFreeSqlProviderModule),
|
|
||||||
typeof(DeviceManagementApplicationModule)
|
typeof(DeviceManagementApplicationModule)
|
||||||
)]
|
)]
|
||||||
public class IoTApplicationModule : AbpModule
|
public class IoTApplicationModule : AbpModule
|
||||||
@ -36,21 +32,5 @@ namespace JiShe.IoT
|
|||||||
});
|
});
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public override void PostConfigureServices(ServiceConfigurationContext context)
|
|
||||||
{
|
|
||||||
// ¶¨Ê±ÈÎÎñ
|
|
||||||
ConfigureBackgroundJob(context);
|
|
||||||
}
|
|
||||||
|
|
||||||
private static void ConfigureBackgroundJob(ServiceConfigurationContext context)
|
|
||||||
{
|
|
||||||
context.Services.AddHostedService<BathSyncFocusDataToMysqlJob>();
|
|
||||||
context.Services.AddHostedService<BathSyncAmmeterDataToMysqlJob>();
|
|
||||||
context.Services.AddHostedService<BathSyncWatermeterDataToMysqlJob>();
|
|
||||||
context.Services.AddHostedService<CacheDeviceDataToRedisJob>();
|
|
||||||
context.Services.AddHostedService<CacheFocusDataToRedisJob>();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,41 +0,0 @@
|
|||||||
using JiShe.ServicePro.Core;
|
|
||||||
using JiShe.ServicePro.DeviceManagement.Meters;
|
|
||||||
using Microsoft.Extensions.Logging;
|
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JiShe.IoT.Jobs.ToMysql
|
|
||||||
{
|
|
||||||
/// <summary>
|
|
||||||
/// 批量同步电表 ammeter 数据到mysql
|
|
||||||
/// </summary>
|
|
||||||
public class BathSyncAmmeterDataToMysqlJob : SystemBackGroundWorkService
|
|
||||||
{
|
|
||||||
private readonly ILogger<BathSyncAmmeterDataToMysqlJob> _logger;
|
|
||||||
public readonly MeterAppService _meterAppService;
|
|
||||||
public BathSyncAmmeterDataToMysqlJob(ILogger<BathSyncAmmeterDataToMysqlJob> logger, MeterAppService meterAppService) : base(logger)
|
|
||||||
{
|
|
||||||
_logger = logger;
|
|
||||||
_meterAppService = meterAppService;
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// 定时执行
|
|
||||||
/// </summary>
|
|
||||||
/// <param name="cancellationToken"></param>
|
|
||||||
/// <returns></returns>
|
|
||||||
protected override Task DoWorkAsync(CancellationToken cancellationToken)
|
|
||||||
{
|
|
||||||
return _meterAppService.BathSyncAmmeterDataAsync();
|
|
||||||
}
|
|
||||||
|
|
||||||
protected override TimeSpan GetInterval()
|
|
||||||
{
|
|
||||||
// 每隔3小时执行一次
|
|
||||||
return TimeSpan.FromHours(3);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@ -1,37 +0,0 @@
|
|||||||
using JiShe.ServicePro.Core;
|
|
||||||
using JiShe.ServicePro.DeviceManagement.Focuses;
|
|
||||||
using Microsoft.Extensions.Logging;
|
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JiShe.IoT.Jobs.ToMysql
|
|
||||||
{
|
|
||||||
/// <summary>
|
|
||||||
/// 批量同步集中器 Focus数据到Mysql
|
|
||||||
/// </summary>
|
|
||||||
public class BathSyncFocusDataToMysqlJob : SystemBackGroundWorkService
|
|
||||||
{
|
|
||||||
|
|
||||||
private readonly ILogger<BathSyncFocusDataToMysqlJob> _logger;
|
|
||||||
public readonly FocusAppService _focusAppService;
|
|
||||||
public BathSyncFocusDataToMysqlJob(ILogger<BathSyncFocusDataToMysqlJob> logger, FocusAppService focusAppService) : base(logger)
|
|
||||||
{
|
|
||||||
_logger = logger;
|
|
||||||
_focusAppService = focusAppService;
|
|
||||||
}
|
|
||||||
|
|
||||||
protected override Task DoWorkAsync(CancellationToken cancellationToken)
|
|
||||||
{
|
|
||||||
return _focusAppService.BathSyncFocusDataAsync();
|
|
||||||
}
|
|
||||||
|
|
||||||
protected override TimeSpan GetInterval()
|
|
||||||
{
|
|
||||||
// 每隔3小时执行一次
|
|
||||||
return TimeSpan.FromHours(3);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@ -1,41 +0,0 @@
|
|||||||
using JiShe.ServicePro.Core;
|
|
||||||
using JiShe.ServicePro.DeviceManagement.Meters;
|
|
||||||
using Microsoft.Extensions.Logging;
|
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JiShe.IoT.Jobs.ToMysql
|
|
||||||
{
|
|
||||||
/// <summary>
|
|
||||||
/// 批量同步 水表 watermeter 数据到mysql
|
|
||||||
/// </summary>
|
|
||||||
public class BathSyncWatermeterDataToMysqlJob : SystemBackGroundWorkService
|
|
||||||
{
|
|
||||||
private readonly ILogger<BathSyncWatermeterDataToMysqlJob> _logger;
|
|
||||||
public readonly MeterAppService _meterAppService;
|
|
||||||
public BathSyncWatermeterDataToMysqlJob(ILogger<BathSyncWatermeterDataToMysqlJob> logger, MeterAppService meterAppService) : base(logger)
|
|
||||||
{
|
|
||||||
_logger = logger;
|
|
||||||
_meterAppService = meterAppService;
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// 定时执行
|
|
||||||
/// </summary>
|
|
||||||
/// <param name="cancellationToken"></param>
|
|
||||||
/// <returns></returns>
|
|
||||||
protected override Task DoWorkAsync(CancellationToken cancellationToken)
|
|
||||||
{
|
|
||||||
return _meterAppService.BathSyncWatermeterDataAsync();
|
|
||||||
}
|
|
||||||
|
|
||||||
protected override TimeSpan GetInterval()
|
|
||||||
{
|
|
||||||
// 每隔3小时执行一次
|
|
||||||
return TimeSpan.FromHours(3);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@ -1,40 +0,0 @@
|
|||||||
using JiShe.ServicePro.Core;
|
|
||||||
using JiShe.ServicePro.DeviceManagement.Meters;
|
|
||||||
using Microsoft.Extensions.Logging;
|
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JiShe.IoT.Jobs.ToRedis
|
|
||||||
{
|
|
||||||
/// <summary>
|
|
||||||
/// 缓存设备数据到redis
|
|
||||||
/// </summary>
|
|
||||||
public class CacheDeviceDataToRedisJob : SystemBackGroundWorkService
|
|
||||||
{
|
|
||||||
private readonly ILogger<CacheDeviceDataToRedisJob> _logger;
|
|
||||||
public readonly MeterAppService _meterAppService;
|
|
||||||
public CacheDeviceDataToRedisJob(ILogger<CacheDeviceDataToRedisJob> logger, MeterAppService meterAppService) : base(logger)
|
|
||||||
{
|
|
||||||
_logger = logger;
|
|
||||||
_meterAppService = meterAppService;
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// 定时执行
|
|
||||||
/// </summary>
|
|
||||||
/// <param name="cancellationToken"></param>
|
|
||||||
/// <returns></returns>
|
|
||||||
protected override Task DoWorkAsync(CancellationToken cancellationToken)
|
|
||||||
{
|
|
||||||
return _meterAppService.CacheDeviceDataToRedisAsync();
|
|
||||||
}
|
|
||||||
|
|
||||||
protected override TimeSpan GetInterval()
|
|
||||||
{
|
|
||||||
return TimeSpan.FromHours(1);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@ -1,37 +0,0 @@
|
|||||||
using JiShe.ServicePro.Core;
|
|
||||||
using JiShe.ServicePro.DeviceManagement.Focuses;
|
|
||||||
using JiShe.ServicePro.DeviceManagement.Meters;
|
|
||||||
using Microsoft.Extensions.Logging;
|
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JiShe.IoT.Jobs.ToRedis
|
|
||||||
{
|
|
||||||
/// <summary>
|
|
||||||
/// 缓存集中器数据到Redis
|
|
||||||
/// </summary>
|
|
||||||
public class CacheFocusDataToRedisJob : SystemBackGroundWorkService
|
|
||||||
{
|
|
||||||
|
|
||||||
private readonly ILogger<CacheFocusDataToRedisJob> _logger;
|
|
||||||
public readonly FocusAppService _focusAppService;
|
|
||||||
public CacheFocusDataToRedisJob(ILogger<CacheFocusDataToRedisJob> logger, FocusAppService focusAppService) : base(logger)
|
|
||||||
{
|
|
||||||
_logger = logger;
|
|
||||||
_focusAppService= focusAppService;
|
|
||||||
}
|
|
||||||
|
|
||||||
protected override Task DoWorkAsync(CancellationToken cancellationToken)
|
|
||||||
{
|
|
||||||
return _focusAppService.CacheFocusDataToRedisAsync();
|
|
||||||
}
|
|
||||||
|
|
||||||
protected override TimeSpan GetInterval()
|
|
||||||
{
|
|
||||||
return TimeSpan.FromHours(1);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@ -1,4 +1,4 @@
|
|||||||
using JiShe.ServicePro.ApacheIoTDB.Provider.ISessionPools;
|
using JiShe.ServicePro.IoTDBManagement.SessionPools;
|
||||||
|
|
||||||
namespace JiShe.IoT.Data
|
namespace JiShe.IoT.Data
|
||||||
{
|
{
|
||||||
|
|||||||
@ -13,8 +13,8 @@ using Volo.Abp.EntityFrameworkCore;
|
|||||||
namespace JiShe.IoT.Migrations
|
namespace JiShe.IoT.Migrations
|
||||||
{
|
{
|
||||||
[DbContext(typeof(IoTDbContext))]
|
[DbContext(typeof(IoTDbContext))]
|
||||||
[Migration("20250611083124_initCreate")]
|
[Migration("20250609070511_initCeate")]
|
||||||
partial class initCreate
|
partial class initCeate
|
||||||
{
|
{
|
||||||
/// <inheritdoc />
|
/// <inheritdoc />
|
||||||
protected override void BuildTargetModel(ModelBuilder modelBuilder)
|
protected override void BuildTargetModel(ModelBuilder modelBuilder)
|
||||||
@ -352,10 +352,6 @@ namespace JiShe.IoT.Migrations
|
|||||||
.HasColumnType("int")
|
.HasColumnType("int")
|
||||||
.HasComment("旧系统授权最后修改者Id");
|
.HasComment("旧系统授权最后修改者Id");
|
||||||
|
|
||||||
b.Property<int>("ProjectID")
|
|
||||||
.HasColumnType("int")
|
|
||||||
.HasComment("项目ID");
|
|
||||||
|
|
||||||
b.Property<string>("Remark")
|
b.Property<string>("Remark")
|
||||||
.HasColumnType("longtext")
|
.HasColumnType("longtext")
|
||||||
.HasComment("备注");
|
.HasComment("备注");
|
||||||
@ -364,11 +360,6 @@ namespace JiShe.IoT.Migrations
|
|||||||
.HasColumnType("tinyint(1)")
|
.HasColumnType("tinyint(1)")
|
||||||
.HasComment("是否自研");
|
.HasComment("是否自研");
|
||||||
|
|
||||||
b.Property<string>("SimCard")
|
|
||||||
.HasMaxLength(80)
|
|
||||||
.HasColumnType("varchar(80)")
|
|
||||||
.HasComment("通讯SIM卡卡号");
|
|
||||||
|
|
||||||
b.Property<string>("SoftwareReleaseDate")
|
b.Property<string>("SoftwareReleaseDate")
|
||||||
.HasMaxLength(80)
|
.HasMaxLength(80)
|
||||||
.HasColumnType("varchar(80)")
|
.HasColumnType("varchar(80)")
|
||||||
@ -388,10 +379,6 @@ namespace JiShe.IoT.Migrations
|
|||||||
.HasColumnName("TenantId")
|
.HasColumnName("TenantId")
|
||||||
.HasComment("租户ID");
|
.HasComment("租户ID");
|
||||||
|
|
||||||
b.Property<int>("TimeDensity")
|
|
||||||
.HasColumnType("int")
|
|
||||||
.HasComment("采集密度");
|
|
||||||
|
|
||||||
b.Property<int>("UpLink")
|
b.Property<int>("UpLink")
|
||||||
.HasMaxLength(20)
|
.HasMaxLength(20)
|
||||||
.HasColumnType("int")
|
.HasColumnType("int")
|
||||||
@ -409,24 +396,10 @@ namespace JiShe.IoT.Migrations
|
|||||||
b.Property<Guid>("Id")
|
b.Property<Guid>("Id")
|
||||||
.HasColumnType("char(36)");
|
.HasColumnType("char(36)");
|
||||||
|
|
||||||
b.Property<string>("Address")
|
|
||||||
.HasMaxLength(20)
|
|
||||||
.HasColumnType("varchar(20)")
|
|
||||||
.HasComment("表计地址");
|
|
||||||
|
|
||||||
b.Property<bool>("ArchiveStatus")
|
b.Property<bool>("ArchiveStatus")
|
||||||
.HasColumnType("tinyint(1)")
|
.HasColumnType("tinyint(1)")
|
||||||
.HasComment("归档状态");
|
.HasComment("归档状态");
|
||||||
|
|
||||||
b.Property<string>("AreaCode")
|
|
||||||
.HasMaxLength(20)
|
|
||||||
.HasColumnType("varchar(20)")
|
|
||||||
.HasComment("表计区域编码");
|
|
||||||
|
|
||||||
b.Property<int>("AutomaticReport")
|
|
||||||
.HasColumnType("int")
|
|
||||||
.HasComment("是否自动采集");
|
|
||||||
|
|
||||||
b.Property<int>("Baudrate")
|
b.Property<int>("Baudrate")
|
||||||
.HasColumnType("int")
|
.HasColumnType("int")
|
||||||
.HasComment("波特率");
|
.HasComment("波特率");
|
||||||
@ -436,10 +409,6 @@ namespace JiShe.IoT.Migrations
|
|||||||
.HasColumnType("varchar(128)")
|
.HasColumnType("varchar(128)")
|
||||||
.HasComment("品牌类型");
|
.HasComment("品牌类型");
|
||||||
|
|
||||||
b.Property<int>("BusinessSystem")
|
|
||||||
.HasColumnType("int")
|
|
||||||
.HasComment("业务系统");
|
|
||||||
|
|
||||||
b.Property<string>("ConcurrencyStamp")
|
b.Property<string>("ConcurrencyStamp")
|
||||||
.IsConcurrencyToken()
|
.IsConcurrencyToken()
|
||||||
.IsRequired()
|
.IsRequired()
|
||||||
@ -455,11 +424,6 @@ namespace JiShe.IoT.Migrations
|
|||||||
.HasColumnType("char(36)")
|
.HasColumnType("char(36)")
|
||||||
.HasColumnName("CreatorId");
|
.HasColumnName("CreatorId");
|
||||||
|
|
||||||
b.Property<string>("DataTypes")
|
|
||||||
.HasMaxLength(5000)
|
|
||||||
.HasColumnType("varchar(5000)")
|
|
||||||
.HasComment("采集项编号ID");
|
|
||||||
|
|
||||||
b.Property<int>("DatabaseBusiID")
|
b.Property<int>("DatabaseBusiID")
|
||||||
.HasColumnType("int")
|
.HasColumnType("int")
|
||||||
.HasComment("业务库ID");
|
.HasComment("业务库ID");
|
||||||
@ -507,11 +471,6 @@ namespace JiShe.IoT.Migrations
|
|||||||
.HasDefaultValue(false)
|
.HasDefaultValue(false)
|
||||||
.HasColumnName("IsDeleted");
|
.HasColumnName("IsDeleted");
|
||||||
|
|
||||||
b.Property<string>("ItemCodes")
|
|
||||||
.HasMaxLength(5000)
|
|
||||||
.HasColumnType("varchar(5000)")
|
|
||||||
.HasComment("采集项编码");
|
|
||||||
|
|
||||||
b.Property<DateTime?>("LastModificationTime")
|
b.Property<DateTime?>("LastModificationTime")
|
||||||
.HasColumnType("datetime(6)")
|
.HasColumnType("datetime(6)")
|
||||||
.HasColumnName("LastModificationTime");
|
.HasColumnName("LastModificationTime");
|
||||||
@ -520,11 +479,6 @@ namespace JiShe.IoT.Migrations
|
|||||||
.HasColumnType("char(36)")
|
.HasColumnType("char(36)")
|
||||||
.HasColumnName("LastModifierId");
|
.HasColumnName("LastModifierId");
|
||||||
|
|
||||||
b.Property<string>("LinkType")
|
|
||||||
.HasMaxLength(128)
|
|
||||||
.HasColumnType("varchar(128)")
|
|
||||||
.HasComment("水表通讯方案");
|
|
||||||
|
|
||||||
b.Property<string>("MeterAddress")
|
b.Property<string>("MeterAddress")
|
||||||
.IsRequired()
|
.IsRequired()
|
||||||
.HasMaxLength(40)
|
.HasMaxLength(40)
|
||||||
@ -545,11 +499,6 @@ namespace JiShe.IoT.Migrations
|
|||||||
.HasColumnType("int")
|
.HasColumnType("int")
|
||||||
.HasComment("表计类型");
|
.HasComment("表计类型");
|
||||||
|
|
||||||
b.Property<string>("MeterTypeName")
|
|
||||||
.HasMaxLength(128)
|
|
||||||
.HasColumnType("varchar(128)")
|
|
||||||
.HasComment("水表设备类型");
|
|
||||||
|
|
||||||
b.Property<int>("MeteringCode")
|
b.Property<int>("MeteringCode")
|
||||||
.HasColumnType("int")
|
.HasColumnType("int")
|
||||||
.HasComment("表计编码");
|
.HasComment("表计编码");
|
||||||
@ -595,21 +544,17 @@ namespace JiShe.IoT.Migrations
|
|||||||
.HasColumnType("tinyint(1)")
|
.HasColumnType("tinyint(1)")
|
||||||
.HasComment("是否单倍率");
|
.HasComment("是否单倍率");
|
||||||
|
|
||||||
b.Property<int>("Special")
|
|
||||||
.HasColumnType("int")
|
|
||||||
.HasComment("是否特殊表");
|
|
||||||
|
|
||||||
b.Property<Guid?>("TenantId")
|
b.Property<Guid?>("TenantId")
|
||||||
.HasColumnType("char(36)")
|
.HasColumnType("char(36)")
|
||||||
.HasColumnName("TenantId")
|
.HasColumnName("TenantId")
|
||||||
.HasComment("租户ID");
|
.HasComment("租户ID");
|
||||||
|
|
||||||
b.Property<decimal>("TimesA")
|
b.Property<decimal>("TimesA")
|
||||||
.HasColumnType("decimal(12, 4)")
|
.HasColumnType("decimal(65,30)")
|
||||||
.HasComment("倍率A");
|
.HasComment("倍率A");
|
||||||
|
|
||||||
b.Property<decimal>("Timev")
|
b.Property<decimal>("Timev")
|
||||||
.HasColumnType("decimal(12, 4)")
|
.HasColumnType("decimal(65,30)")
|
||||||
.HasComment("倍率V");
|
.HasComment("倍率V");
|
||||||
|
|
||||||
b.Property<bool>("TripState")
|
b.Property<bool>("TripState")
|
||||||
@ -6,7 +6,7 @@ using Microsoft.EntityFrameworkCore.Migrations;
|
|||||||
namespace JiShe.IoT.Migrations
|
namespace JiShe.IoT.Migrations
|
||||||
{
|
{
|
||||||
/// <inheritdoc />
|
/// <inheritdoc />
|
||||||
public partial class initCreate : Migration
|
public partial class initCeate : Migration
|
||||||
{
|
{
|
||||||
/// <inheritdoc />
|
/// <inheritdoc />
|
||||||
protected override void Up(MigrationBuilder migrationBuilder)
|
protected override void Up(MigrationBuilder migrationBuilder)
|
||||||
@ -755,12 +755,8 @@ namespace JiShe.IoT.Migrations
|
|||||||
Status = table.Column<bool>(type: "tinyint(1)", nullable: false, comment: "是否在线状态"),
|
Status = table.Column<bool>(type: "tinyint(1)", nullable: false, comment: "是否在线状态"),
|
||||||
HeartbeatInterval = table.Column<int>(type: "int", nullable: false, comment: "心跳间隔"),
|
HeartbeatInterval = table.Column<int>(type: "int", nullable: false, comment: "心跳间隔"),
|
||||||
LastRefreshTime = table.Column<DateTime>(type: "datetime(6)", nullable: true, comment: "最后刷新时间"),
|
LastRefreshTime = table.Column<DateTime>(type: "datetime(6)", nullable: true, comment: "最后刷新时间"),
|
||||||
TimeDensity = table.Column<int>(type: "int", nullable: false, comment: "采集密度"),
|
|
||||||
FocusId = table.Column<long>(type: "bigint", nullable: false, comment: "集中器ID"),
|
FocusId = table.Column<long>(type: "bigint", nullable: false, comment: "集中器ID"),
|
||||||
ProjectID = table.Column<int>(type: "int", nullable: false, comment: "项目ID"),
|
|
||||||
Enabled = table.Column<bool>(type: "tinyint(1)", nullable: false, comment: "是否启用"),
|
Enabled = table.Column<bool>(type: "tinyint(1)", nullable: false, comment: "是否启用"),
|
||||||
SimCard = table.Column<string>(type: "varchar(80)", maxLength: 80, nullable: true, comment: "通讯SIM卡卡号")
|
|
||||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
|
||||||
MakerNo = table.Column<string>(type: "varchar(80)", maxLength: 80, nullable: true, comment: "厂商代号")
|
MakerNo = table.Column<string>(type: "varchar(80)", maxLength: 80, nullable: true, comment: "厂商代号")
|
||||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||||
DeviceNo = table.Column<string>(type: "varchar(80)", maxLength: 80, nullable: true, comment: "设备编号")
|
DeviceNo = table.Column<string>(type: "varchar(80)", maxLength: 80, nullable: true, comment: "设备编号")
|
||||||
@ -849,7 +845,6 @@ namespace JiShe.IoT.Migrations
|
|||||||
columns: table => new
|
columns: table => new
|
||||||
{
|
{
|
||||||
Id = table.Column<Guid>(type: "char(36)", nullable: false, collation: "ascii_general_ci"),
|
Id = table.Column<Guid>(type: "char(36)", nullable: false, collation: "ascii_general_ci"),
|
||||||
BusinessSystem = table.Column<int>(type: "int", nullable: false, comment: "业务系统"),
|
|
||||||
MeterName = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: false, comment: "表计名称")
|
MeterName = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: false, comment: "表计名称")
|
||||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||||
MeterAddress = table.Column<string>(type: "varchar(40)", maxLength: 40, nullable: false, comment: "表计地址")
|
MeterAddress = table.Column<string>(type: "varchar(40)", maxLength: 40, nullable: false, comment: "表计地址")
|
||||||
@ -869,8 +864,8 @@ namespace JiShe.IoT.Migrations
|
|||||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||||
ArchiveStatus = table.Column<bool>(type: "tinyint(1)", nullable: false, comment: "归档状态"),
|
ArchiveStatus = table.Column<bool>(type: "tinyint(1)", nullable: false, comment: "归档状态"),
|
||||||
TripState = table.Column<bool>(type: "tinyint(1)", nullable: false, comment: "是否跳闸"),
|
TripState = table.Column<bool>(type: "tinyint(1)", nullable: false, comment: "是否跳闸"),
|
||||||
TimesA = table.Column<decimal>(type: "decimal(12,4)", nullable: false, comment: "倍率A"),
|
TimesA = table.Column<decimal>(type: "decimal(65,30)", nullable: false, comment: "倍率A"),
|
||||||
Timev = table.Column<decimal>(type: "decimal(12,4)", nullable: false, comment: "倍率V"),
|
Timev = table.Column<decimal>(type: "decimal(65,30)", nullable: false, comment: "倍率V"),
|
||||||
HaveValve = table.Column<bool>(type: "tinyint(1)", nullable: true, comment: "是否带阀控"),
|
HaveValve = table.Column<bool>(type: "tinyint(1)", nullable: true, comment: "是否带阀控"),
|
||||||
FocusId = table.Column<int>(type: "int", nullable: false, comment: "集中器ID"),
|
FocusId = table.Column<int>(type: "int", nullable: false, comment: "集中器ID"),
|
||||||
MeterId = table.Column<int>(type: "int", nullable: false, comment: "表计ID"),
|
MeterId = table.Column<int>(type: "int", nullable: false, comment: "表计ID"),
|
||||||
@ -879,20 +874,6 @@ namespace JiShe.IoT.Migrations
|
|||||||
Enabled = table.Column<bool>(type: "tinyint(1)", nullable: false, comment: "是否启用"),
|
Enabled = table.Column<bool>(type: "tinyint(1)", nullable: false, comment: "是否启用"),
|
||||||
GatherCount = table.Column<int>(type: "int", nullable: false, comment: "采集项数量"),
|
GatherCount = table.Column<int>(type: "int", nullable: false, comment: "采集项数量"),
|
||||||
FunctionCount = table.Column<int>(type: "int", nullable: false, comment: "功能数量(包含采集项和阀控等)"),
|
FunctionCount = table.Column<int>(type: "int", nullable: false, comment: "功能数量(包含采集项和阀控等)"),
|
||||||
ItemCodes = table.Column<string>(type: "varchar(5000)", maxLength: 5000, nullable: true, comment: "采集项编码")
|
|
||||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
|
||||||
DataTypes = table.Column<string>(type: "varchar(5000)", maxLength: 5000, nullable: true, comment: "采集项编号ID")
|
|
||||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
|
||||||
Address = table.Column<string>(type: "varchar(20)", maxLength: 20, nullable: true, comment: "表计地址")
|
|
||||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
|
||||||
AreaCode = table.Column<string>(type: "varchar(20)", maxLength: 20, nullable: true, comment: "表计区域编码")
|
|
||||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
|
||||||
LinkType = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: true, comment: "水表通讯方案")
|
|
||||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
|
||||||
MeterTypeName = table.Column<string>(type: "varchar(128)", maxLength: 128, nullable: true, comment: "水表设备类型")
|
|
||||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
|
||||||
Special = table.Column<int>(type: "int", nullable: false, comment: "是否特殊表"),
|
|
||||||
AutomaticReport = table.Column<int>(type: "int", nullable: false, comment: "是否自动采集"),
|
|
||||||
ConcurrencyStamp = table.Column<string>(type: "varchar(40)", maxLength: 40, nullable: false)
|
ConcurrencyStamp = table.Column<string>(type: "varchar(40)", maxLength: 40, nullable: false)
|
||||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||||
CreationTime = table.Column<DateTime>(type: "datetime(6)", nullable: false),
|
CreationTime = table.Column<DateTime>(type: "datetime(6)", nullable: false),
|
||||||
@ -349,10 +349,6 @@ namespace JiShe.IoT.Migrations
|
|||||||
.HasColumnType("int")
|
.HasColumnType("int")
|
||||||
.HasComment("旧系统授权最后修改者Id");
|
.HasComment("旧系统授权最后修改者Id");
|
||||||
|
|
||||||
b.Property<int>("ProjectID")
|
|
||||||
.HasColumnType("int")
|
|
||||||
.HasComment("项目ID");
|
|
||||||
|
|
||||||
b.Property<string>("Remark")
|
b.Property<string>("Remark")
|
||||||
.HasColumnType("longtext")
|
.HasColumnType("longtext")
|
||||||
.HasComment("备注");
|
.HasComment("备注");
|
||||||
@ -361,11 +357,6 @@ namespace JiShe.IoT.Migrations
|
|||||||
.HasColumnType("tinyint(1)")
|
.HasColumnType("tinyint(1)")
|
||||||
.HasComment("是否自研");
|
.HasComment("是否自研");
|
||||||
|
|
||||||
b.Property<string>("SimCard")
|
|
||||||
.HasMaxLength(80)
|
|
||||||
.HasColumnType("varchar(80)")
|
|
||||||
.HasComment("通讯SIM卡卡号");
|
|
||||||
|
|
||||||
b.Property<string>("SoftwareReleaseDate")
|
b.Property<string>("SoftwareReleaseDate")
|
||||||
.HasMaxLength(80)
|
.HasMaxLength(80)
|
||||||
.HasColumnType("varchar(80)")
|
.HasColumnType("varchar(80)")
|
||||||
@ -385,10 +376,6 @@ namespace JiShe.IoT.Migrations
|
|||||||
.HasColumnName("TenantId")
|
.HasColumnName("TenantId")
|
||||||
.HasComment("租户ID");
|
.HasComment("租户ID");
|
||||||
|
|
||||||
b.Property<int>("TimeDensity")
|
|
||||||
.HasColumnType("int")
|
|
||||||
.HasComment("采集密度");
|
|
||||||
|
|
||||||
b.Property<int>("UpLink")
|
b.Property<int>("UpLink")
|
||||||
.HasMaxLength(20)
|
.HasMaxLength(20)
|
||||||
.HasColumnType("int")
|
.HasColumnType("int")
|
||||||
@ -406,24 +393,10 @@ namespace JiShe.IoT.Migrations
|
|||||||
b.Property<Guid>("Id")
|
b.Property<Guid>("Id")
|
||||||
.HasColumnType("char(36)");
|
.HasColumnType("char(36)");
|
||||||
|
|
||||||
b.Property<string>("Address")
|
|
||||||
.HasMaxLength(20)
|
|
||||||
.HasColumnType("varchar(20)")
|
|
||||||
.HasComment("表计地址");
|
|
||||||
|
|
||||||
b.Property<bool>("ArchiveStatus")
|
b.Property<bool>("ArchiveStatus")
|
||||||
.HasColumnType("tinyint(1)")
|
.HasColumnType("tinyint(1)")
|
||||||
.HasComment("归档状态");
|
.HasComment("归档状态");
|
||||||
|
|
||||||
b.Property<string>("AreaCode")
|
|
||||||
.HasMaxLength(20)
|
|
||||||
.HasColumnType("varchar(20)")
|
|
||||||
.HasComment("表计区域编码");
|
|
||||||
|
|
||||||
b.Property<int>("AutomaticReport")
|
|
||||||
.HasColumnType("int")
|
|
||||||
.HasComment("是否自动采集");
|
|
||||||
|
|
||||||
b.Property<int>("Baudrate")
|
b.Property<int>("Baudrate")
|
||||||
.HasColumnType("int")
|
.HasColumnType("int")
|
||||||
.HasComment("波特率");
|
.HasComment("波特率");
|
||||||
@ -433,10 +406,6 @@ namespace JiShe.IoT.Migrations
|
|||||||
.HasColumnType("varchar(128)")
|
.HasColumnType("varchar(128)")
|
||||||
.HasComment("品牌类型");
|
.HasComment("品牌类型");
|
||||||
|
|
||||||
b.Property<int>("BusinessSystem")
|
|
||||||
.HasColumnType("int")
|
|
||||||
.HasComment("业务系统");
|
|
||||||
|
|
||||||
b.Property<string>("ConcurrencyStamp")
|
b.Property<string>("ConcurrencyStamp")
|
||||||
.IsConcurrencyToken()
|
.IsConcurrencyToken()
|
||||||
.IsRequired()
|
.IsRequired()
|
||||||
@ -452,11 +421,6 @@ namespace JiShe.IoT.Migrations
|
|||||||
.HasColumnType("char(36)")
|
.HasColumnType("char(36)")
|
||||||
.HasColumnName("CreatorId");
|
.HasColumnName("CreatorId");
|
||||||
|
|
||||||
b.Property<string>("DataTypes")
|
|
||||||
.HasMaxLength(5000)
|
|
||||||
.HasColumnType("varchar(5000)")
|
|
||||||
.HasComment("采集项编号ID");
|
|
||||||
|
|
||||||
b.Property<int>("DatabaseBusiID")
|
b.Property<int>("DatabaseBusiID")
|
||||||
.HasColumnType("int")
|
.HasColumnType("int")
|
||||||
.HasComment("业务库ID");
|
.HasComment("业务库ID");
|
||||||
@ -504,11 +468,6 @@ namespace JiShe.IoT.Migrations
|
|||||||
.HasDefaultValue(false)
|
.HasDefaultValue(false)
|
||||||
.HasColumnName("IsDeleted");
|
.HasColumnName("IsDeleted");
|
||||||
|
|
||||||
b.Property<string>("ItemCodes")
|
|
||||||
.HasMaxLength(5000)
|
|
||||||
.HasColumnType("varchar(5000)")
|
|
||||||
.HasComment("采集项编码");
|
|
||||||
|
|
||||||
b.Property<DateTime?>("LastModificationTime")
|
b.Property<DateTime?>("LastModificationTime")
|
||||||
.HasColumnType("datetime(6)")
|
.HasColumnType("datetime(6)")
|
||||||
.HasColumnName("LastModificationTime");
|
.HasColumnName("LastModificationTime");
|
||||||
@ -517,11 +476,6 @@ namespace JiShe.IoT.Migrations
|
|||||||
.HasColumnType("char(36)")
|
.HasColumnType("char(36)")
|
||||||
.HasColumnName("LastModifierId");
|
.HasColumnName("LastModifierId");
|
||||||
|
|
||||||
b.Property<string>("LinkType")
|
|
||||||
.HasMaxLength(128)
|
|
||||||
.HasColumnType("varchar(128)")
|
|
||||||
.HasComment("水表通讯方案");
|
|
||||||
|
|
||||||
b.Property<string>("MeterAddress")
|
b.Property<string>("MeterAddress")
|
||||||
.IsRequired()
|
.IsRequired()
|
||||||
.HasMaxLength(40)
|
.HasMaxLength(40)
|
||||||
@ -542,11 +496,6 @@ namespace JiShe.IoT.Migrations
|
|||||||
.HasColumnType("int")
|
.HasColumnType("int")
|
||||||
.HasComment("表计类型");
|
.HasComment("表计类型");
|
||||||
|
|
||||||
b.Property<string>("MeterTypeName")
|
|
||||||
.HasMaxLength(128)
|
|
||||||
.HasColumnType("varchar(128)")
|
|
||||||
.HasComment("水表设备类型");
|
|
||||||
|
|
||||||
b.Property<int>("MeteringCode")
|
b.Property<int>("MeteringCode")
|
||||||
.HasColumnType("int")
|
.HasColumnType("int")
|
||||||
.HasComment("表计编码");
|
.HasComment("表计编码");
|
||||||
@ -592,21 +541,17 @@ namespace JiShe.IoT.Migrations
|
|||||||
.HasColumnType("tinyint(1)")
|
.HasColumnType("tinyint(1)")
|
||||||
.HasComment("是否单倍率");
|
.HasComment("是否单倍率");
|
||||||
|
|
||||||
b.Property<int>("Special")
|
|
||||||
.HasColumnType("int")
|
|
||||||
.HasComment("是否特殊表");
|
|
||||||
|
|
||||||
b.Property<Guid?>("TenantId")
|
b.Property<Guid?>("TenantId")
|
||||||
.HasColumnType("char(36)")
|
.HasColumnType("char(36)")
|
||||||
.HasColumnName("TenantId")
|
.HasColumnName("TenantId")
|
||||||
.HasComment("租户ID");
|
.HasComment("租户ID");
|
||||||
|
|
||||||
b.Property<decimal>("TimesA")
|
b.Property<decimal>("TimesA")
|
||||||
.HasColumnType("decimal(12, 4)")
|
.HasColumnType("decimal(65,30)")
|
||||||
.HasComment("倍率A");
|
.HasComment("倍率A");
|
||||||
|
|
||||||
b.Property<decimal>("Timev")
|
b.Property<decimal>("Timev")
|
||||||
.HasColumnType("decimal(12, 4)")
|
.HasColumnType("decimal(65,30)")
|
||||||
.HasComment("倍率V");
|
.HasComment("倍率V");
|
||||||
|
|
||||||
b.Property<bool>("TripState")
|
b.Property<bool>("TripState")
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user