This commit is contained in:
2024-04-11 17:31:32 +08:00
parent f6eaa2f481
commit 4fbc6c0267
200 changed files with 1252 additions and 1860 deletions

View File

@@ -2,7 +2,7 @@
"JNPF_App": {
"CodeAreasName": [ "SubDev" ],
//系统文件路径
"SystemPath": "D:\\ToTong\\tnb\\Resources",
"SystemPath": "D:\\cosmoplat\\tnb\\Resources",
//微信公众号允许上传文件类型
"MPUploadFileType": [
"bmp",
@@ -102,7 +102,7 @@
// 软件的错误报告
"ErrorReport": false,
//软件的错误报告发给谁
"ErrorReportTo": "tuotong_tech@163.com"
"ErrorReportTo": ""
},
// ================== 单点登录配置(和其他登录方式 只能二选一) ============================== -->
"OAuth": {

View File

@@ -1,21 +0,0 @@
{
"AppSettings": {
"InjectMiniProfiler": true,
"SupportPackageNamePrefixs": [ "Tnb" ]
},
"Kestrel": {
"Endpoints": {
"Http": {
"Url": "http://0.0.0.0:9231"
}
}
},
"YitId": {
"WorkerId": 1, //必须 全局唯一,必须 程序设定,理论最大值 2^WorkerIdBitLength-1
"WorkerIdBitLength": 4, //机器码位长,决定 WorkerId 的最大值,默认值6,取值范围 [1, 16]
"SeqBitLength": 4 //序列数位长,默认值6,取值范围 [3, 21](建议不小于4),决定每毫秒基础生成的ID个数
},
"UnifyResultSettings": {
"ShowExceptionDetail": true
}
}

View File

@@ -4,7 +4,7 @@
"ip": "localhost",
"port": 6379,
"password": "05jWEoJa8v",
"RedisConnectionString": "{0}:{1},password={2}, poolsize=500,ssl=false,defaultDatabase=0"
"RedisConnectionString": "{0}:{1},password={2}, poolsize=500,ssl=false,defaultDatabase=7"
},
"Redis": {
"ip": "localhost",

View File

@@ -1,16 +1,24 @@
{
"ConnectionStrings": {
"ConfigId": "default",
"DBType": "PostgreSQL", //MySql;SqlServer;Oracle;PostgreSQL;Dm;Kdbndp;Sqlite;
"DBType": "MySql", //MySql;SqlServer;Oracle;PostgreSQL;Dm;Kdbndp;Sqlite;
<<<<<<< HEAD
"Host": "127.0.0.1",//"10.67.53.241",
=======
"Host": "localhost",
//"Host": "127.0.0.1",
"Port": "5432",
>>>>>>> aec1d3b15533e5faafe3b2294830b095cff93f2d
"Port": "3306",
//"DBName": "tianyi_db",
//"UserName": "postgres",
//"Password": "pass@word123",
"DBName": "tianyi",
"UserName": "postgres",
"Password": "pass@word123",
"DBName": "xinte_cloud",
<<<<<<< HEAD
"UserName": "root",//"totong",
"Password": "root",//"+vKyHUbtxQ",
=======
"UserName": "totong",
"Password": "+vKyHUbtxQ",
>>>>>>> aec1d3b15533e5faafe3b2294830b095cff93f2d
//SqlServer
//"DefaultConnection": "server={0},{1};database={2};uid={3};pwd={4};MultipleActiveResultSets=true"
//Kdbndp

View File

@@ -2,10 +2,9 @@
"DevName3": "Elevator3",
"DevName4": "Elevator4",
"HeartbeatDevNames": [ "Elevator3", "Elevator4" ],
"tags": [ "SysStatus", "RunStatus", "FloorNo", "DoorStatus", "AGVStatus" ],
"token": "780BE4144636CF47DDF3920B0F1D069B",
"GetTagListUrl": "http://192.168.11.110:9100/Dev/GetTagList",
"GetTagUrl": "http://192.168.11.110:9100/Dev/GetTag",
"WriteTagUrl": "http://192.168.11.110:9100/Dev/writeTag",
"Environment": "tianyi"
"Environment": ""
}

View File

@@ -3,9 +3,9 @@
"ValidateIssuerSigningKey": true, // 是否验证密钥bool 类型默认true
"IssuerSigningKey": "RkayGi4ltkMWrSQKsQTWic1VnakqsQfaJOmJIBUWE1gxGaS0IrJHxa9anjVAwuew", // 密钥string 类型必须是复杂密钥长度大于16
"ValidateIssuer": true, // 是否验证签发方bool 类型默认true
"ValidIssuer": "tuotong", // 签发方string 类型
"ValidIssuer": "cosmoplat", // 签发方string 类型
"ValidateAudience": true, // 是否验证签收方bool 类型默认true
"ValidAudience": "tuotong", // 签收方string 类型
"ValidAudience": "cosmoplat", // 签收方string 类型
"ValidateLifetime": true, // 是否验证过期时间bool 类型默认true建议true
"ExpiredTime": 1440, // 过期时间long 类型单位分钟默认20分钟
"ClockSkew": 5 // 过期时间容错值long 类型单位秒默认5秒

View File

@@ -1,3 +0,0 @@
{
"TestLocation": "CP-A08-47"
}

View File

@@ -0,0 +1,29 @@
{
"Nacos": {
"EndPoint": "",
"ServerAddresses": [ "http://localhost:8848/" ], // nacos服务端地址
"DefaultTimeOut": 15000,
"Namespace": "dev", // 服务注册到的命名空间id
"ListenInterval": 1000,
"ServiceName": "tnb-core", //服务名称
"GroupName": "DEFAULT_GROUP", //服务分组
"ClusterName": "DEFAULT",
"Ip": "",
"PreferredNetworks": "", // select an IP that matches the prefix as the service registration IP
"Port": 9212,
"Weight": 100, // 权重
"RegisterEnabled": true,
"InstanceEnabled": true,
"Ephemeral": true,
"Secure": false,
"AccessKey": "",
"SecretKey": "",
"UserName": "nacos",
"Password": "nacos",
"ConfigUseRpc": true, // 为true时通过 gRPC 去和 nacos server 交互nacos 2.x版本要设置为true": null,
"NamingUseRpc": true, // 为true时通过 gRPC 去和 nacos server 交互, nacos 2.x版本要设置为true": null,
"NamingLoadCacheAtStart": "",
"LBStrategy": "WeightRandom", // WeightRandom WeightRoundRobin
"Metadata": {}
}
}

View File

@@ -1,6 +1,6 @@
{
"OSS": {
"BucketName": "jnpfsoftoss",
"BucketName": "cosmoplatoss",
//文件存储类型(Invalid(本地),MinIo,Aliyun,QCloud,Qiniu)
"Provider": "Invalid",
"Endpoint": "192.168.0.60:9000",

View File

@@ -1,12 +1,12 @@
{
"SpecificationDocumentSettings": {
"DocumentTitle": "ToTong Next Builder",
"DocumentTitle": "Cosmoplat Next Builder",
"DocExpansionState": "None",
"RoutePrefix": "swagger",
"GroupOpenApiInfos": [
{
"Group": "Default",
"Title": "ToTong Next Builder",
"Title": "Cosmoplat Next Builder",
"Description": "",
"Version": "3.4.6"
}

View File

@@ -1,7 +1,7 @@
{
"Tenant": {
"MultiTenancy": false,
"MultiTenancyDBInterFace": "http://www.tuotong-tech.com/api/Saas/Tenant/DbContent/",
"MultiTenancyDBInterFace": "",
"MultiTenancyType": ""
}
}

View File

@@ -6,8 +6,6 @@ public class WebComponent : IWebComponent
public void Load(WebApplicationBuilder builder, ComponentContext componentContext)
{
builder.Host.UseWindowsService();
builder.Configuration.AddJsonFile("Location.json", optional: true, reloadOnChange: true);
//// 日志过滤
//builder.Logging.AddFilter((provider, category, logLevel) =>
//{

View File

@@ -4,7 +4,7 @@
"commandName": "Project",
"dotnetRunMessages": true,
"launchBrowser": false,
"applicationUrl": "http://localhost:5000",
"applicationUrl": "http://0.0.0.0:9212",
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Production"
}

View File

@@ -7,6 +7,7 @@ using JNPF.SpecificationDocument;
using JNPF.TaskScheduler.Interfaces.TaskScheduler;
using JNPF.VisualDev;
using Microsoft.Extensions.Options;
using Nacos.AspNetCore.V2;
using Senparc.CO2NET;
using Senparc.CO2NET.RegisterServices;
using Senparc.Weixin;
@@ -49,7 +50,7 @@ public class Startup : AppStartup
services.AddMemoryCache(); // 使用本地缓存必须添加
services.AddConfigurableOptions<CacheOptions>();
services.AddSingleton(typeof(ISingleton), typeof(RedisData));
// services.AddSingleton(typeof(ISingleton), typeof(RedisData));
// 微信
services.AddSenparcGlobalServices(App.Configuration) // Senparc.CO2NET 全局注册
.AddSenparcWeixinServices(App.Configuration); // Senparc.Weixin 注册如果使用Senparc.Weixin SDK则添加
@@ -57,14 +58,14 @@ public class Startup : AppStartup
services.AddOverideVisualDev();
//定时任务
SnowflakeIdHelper.InitYitIdWorker();
services.AddHostedService<TimedTaskBackgroundService>();
services.AddSingleton<BackgroundService, TimedTaskBackgroundService>(sp => new TimedTaskBackgroundService());
//services.AddHostedService<TimedTaskBackgroundService>();
//services.AddSingleton<BackgroundService, TimedTaskBackgroundService>(sp => new TimedTaskBackgroundService());
//var bgSvc = App.GetRequiredService<BackgroundService>();
//bgSvc.StartAsync(CancellationToken.None);
services.AddHostedService<RedisBackGround>();
//services.AddHostedService<RedisBackGround>();
services.AddNacosAspNet(App.Configuration, "Nacos");
}
@@ -113,6 +114,7 @@ public class Startup : AppStartup
endpoints.MapControllerRoute(name: "default", pattern: "{controller=Home}/{action=Index}/{id?}");
});
SnowflakeIdHelper.InitYitIdWorker();
bool isStartTimeJob = App.GetConfig<bool>("IsStartTimeJob");
if (isStartTimeJob)

View File

@@ -44,9 +44,7 @@
<ProjectReference Include="..\..\BasicData\Tnb.BasicData\Tnb.BasicData.csproj" />
<ProjectReference Include="..\..\EquipMgr\Tnb.EquipMgr\Tnb.EquipMgr.csproj" />
<ProjectReference Include="..\..\message\Tnb.Message\Tnb.Message.csproj" />
<ProjectReference Include="..\..\PerMgr\Tnb.PerMgr\Tnb.PerMgr.csproj" />
<ProjectReference Include="..\..\ProductionMgr\Tnb.ProductionMgr\Tnb.ProductionMgr.csproj" />
<ProjectReference Include="..\..\QcMgr\Tnb.QcMgr\Tnb.QcMgr.csproj" />
<ProjectReference Include="..\..\system\Tnb.OAuth\Tnb.OAuth.csproj" />
<ProjectReference Include="..\..\system\Tnb.Systems\Tnb.Systems.csproj" />
<ProjectReference Include="..\..\taskschedule\Tnb.TaskScheduler\Tnb.TaskScheduler.csproj" />

View File

@@ -1,4 +1,9 @@
{
"AllowedHosts": "*",
"ConfigurationScanDirectories": [ "Configurations" ]
"ConfigurationScanDirectories": [ "Configurations" ],
"YitId": {
"WorkerId": 1, //必须 全局唯一,必须 程序设定,理论最大值 2^WorkerIdBitLength-1
"WorkerIdBitLength": 4, //机器码位长,决定 WorkerId 的最大值,默认值6,取值范围 [1, 16]
"SeqBitLength": 4 //序列数位长,默认值6,取值范围 [3, 21](建议不小于4),决定每毫秒基础生成的ID个数
}
}

View File

@@ -1,8 +1,4 @@
/////////////////////////////////////////////////////////////////////////////////
// 宁波拓通e智造平台 ToTong Next Builder //
// https://git.tuotong-tech.com/tnb/tnb-server //
/////////////////////////////////////////////////////////////////////////////////

@using Tnb.Core;
@using Tnb.Vengine;
@using Tnb.Vengine.Domain;

View File

@@ -1,8 +1,4 @@
/////////////////////////////////////////////////////////////////////////////////
// 宁波拓通e智造平台 ToTong Next Builder //
// https://git.tuotong-tech.com/tnb/tnb-server //
/////////////////////////////////////////////////////////////////////////////////

@using Tnb.Core;
@using Tnb.Vengine;
@using Tnb.Vengine.Domain;

View File

@@ -1,11 +1,5 @@
////////////////////////////////////////////////////
// 本文件由拓通低代码开发平台自动生成,请不要修改 //
// ________ ___ ________ //
// /__ __/ / \ /__ __/ //
// / / / / / / //
// / / / / / / //
// /__/ \___/ /__/ //
// //
// 本文件由卡奥斯低代码开发平台自动生成,请不要修改 //
////////////////////////////////////////////////////
@using Tnb.Core;

View File

@@ -1,8 +1,4 @@
/////////////////////////////////////////////////////////////////////////////////
// 宁波拓通e智造平台 ToTong Next Builder //
// https://git.tuotong-tech.com/tnb/tnb-server //
/////////////////////////////////////////////////////////////////////////////////

@using Tnb.Core;
@using Tnb.Vengine;
@using Tnb.Vengine.Domain;

View File

@@ -1,11 +1,5 @@
////////////////////////////////////////////////////
// 本文件由拓通低代码开发平台自动生成,请不要修改 //
// ________ ___ ________ //
// /__ __/ / \ /__ __/ //
// / / / / / / //
// / / / / / / //
// /__/ \___/ /__/ //
// //
// 本文件由卡奥斯低代码开发平台自动生成,请不要修改 //
////////////////////////////////////////////////////
@using JNPF.Common.Extension;