diff --git a/HKCardOUT/Bootstrapper.cs b/HKCardOUT/Bootstrapper.cs index 1b418df..2d22141 100644 --- a/HKCardOUT/Bootstrapper.cs +++ b/HKCardOUT/Bootstrapper.cs @@ -59,7 +59,11 @@ namespace HKCardOUT /// protected override void Configure() { +#if DEBUG var configer = (new ConfigurationBuilder()).AddJsonFile("options.json").Build(); +#else + var configer = (new ConfigurationBuilder()).AddJsonFile("options.pro.json").Build(); +#endif DataBus.ConnectionString = configer.GetConnectionString("Sqlite"); HKLib.Configer.MqAddress = configer["MQ"]; DataBus.Cron = configer["Cron"]; diff --git a/HKCardOUT/HKCardOUT.csproj b/HKCardOUT/HKCardOUT.csproj index 4172f6b..a3b017c 100644 --- a/HKCardOUT/HKCardOUT.csproj +++ b/HKCardOUT/HKCardOUT.csproj @@ -47,6 +47,9 @@ + + Always + Always diff --git a/HKCardOUT/options.json b/HKCardOUT/options.json index 214c75c..651e366 100644 --- a/HKCardOUT/options.json +++ b/HKCardOUT/options.json @@ -1,26 +1,27 @@ { + //此配置文件为测试环境 //服务地址 - "SaasRoute": "https://bpa.black-pa.com:21527/kitchen/", + "SaasRoute": "https://bpa.black-pa.com:21528/kitchen/", //启动设备调试 - "StartDevice": true, + "StartDevice": false, //串口 - "COM": "COM3", + "COM": "COM8", //定时任务时间表达式 每隔6小时推送一次 - "Cron": "0 0 0/6 * * ?", + "Cron": "0/5 * * * * ?", //店铺ID - "StoreId": "a19535e8-119f-4b10-a011-6288fd3ddb37", + "StoreId": "6341f7d5-2d62-4a7d-8386-3467741efcef", //加盟商Id - "TenantId": "68d4de9c-a277-4d7a-a192-e9fa91327d41", + "TenantId": "78d635f7-8ee4-4be4-b26a-462016196826", //本地数据库 "ConnectionStrings": { "Sqlite": "HKSQL.db3" }, //每个时间段的刷卡次数 - "Count": 1, + "Count": 999, //取消单卡刷卡限制 "Cancel": false, //MQ测试地址 - "MQ": "host=10.2.1.21:5672;username=guest;password=guest" + //"MQ": "host=10.2.1.21:5672;username=guest;password=guest" //MQ正式地址 - //"MQ": "host=47.108.65.220;username=root;password=pwd" + "MQ": "host=47.108.65.220;username=root;password=pwd" } diff --git a/HKCardOUT/options.pro.json b/HKCardOUT/options.pro.json new file mode 100644 index 0000000..3ec44f3 --- /dev/null +++ b/HKCardOUT/options.pro.json @@ -0,0 +1,27 @@ +{ + //此配置文件为正式环境 + //服务地址 + "SaasRoute": "https://witt.black-pa.com/kitchen/", + //启动设备调试 + "StartDevice": true, + //串口 + "COM": "COM8", + //定时任务时间表达式 每隔6小时推送一次 + "Cron": "0 0 0/6 * * ?", + //店铺ID + "StoreId": "0c32b2e2-0dc9-4941-b73d-3dc91f7268ab", + //加盟商Id + "TenantId": "01911b43-8844-4d93-b916-34208e31ba66", + //本地数据库 + "ConnectionStrings": { + "Sqlite": "HKSQL.db3" + }, + //每个时间段的刷卡次数 + "Count": 1, + //取消单卡刷卡限制 + "Cancel": true, + //MQ测试地址 + //"MQ": "host=10.2.1.21:5672;username=guest;password=guest" + //MQ正式地址 + "MQ": "host=47.108.65.220;username=root;password=pwd" +}