feat: 新增工作服务项目并调整部分接口路由

1. 新增QYZH.InteractiveMagazine.WorkService工作服务项目,包含队列消费者框架、Hangfire定时任务支持
2. 修复PetService中未定义FeedPetOutput变量的问题
3. 调整JournalController的路由前缀从api/icr改为api
4. 将工作服务项目添加到解决方案中
This commit is contained in:
glz
2026-06-11 18:01:07 +08:00
parent e493c85d08
commit 4142b621c3
12 changed files with 433 additions and 2 deletions

View File

@ -0,0 +1,48 @@
{
"ConnectionStrings": {
"DefaultConnection": "server=192.168.20.150;port=13306;database=InteractiveMagazine;user=user;password=n68792bu!y99r905;charset=utf8mb4;"
},
"RabbitMq": {
"HostName": "192.168.20.150",
"Port": 5672,
"UserName": "smartschool",
"Password": "@ss%&*otz%d*pq2S",
"VirtualHost": "InteractiveMagazine"
},
"Serilog": {
"MinimumLevel": {
"Default": "Information",
"Override": {
"Microsoft": "Warning",
"System": "Warning",
"Hangfire": "Information"
}
},
"WriteTo": [
{
"Name": "Console"
},
{
"Name": "File",
"Args": {
"path": "logs/worker-log-.txt",
"rollingInterval": "Day"
}
}
]
},
"HangfireJobs": {
"_说明": "定时任务配置。新增任务只需在 Jobs 数组中追加一项。Cron格式分 时 日 月 星期5位。常用* * * * * 每分钟 | */5 * * * * 每5分钟 | 0 * * * * 每小时 | 0 9 * * * 每天9点 | 0 0 * * 1 每周一午夜",
"Jobs": [
{
"Name": "sample-job",
"JobType": "QYZH.InteractiveMagazine.WorkService.Jobs.SampleJob",
"MethodName": "ExecuteAsync",
"Cron": "* * * * *",
"Enabled": false,
"Description": "示例任务(默认关闭,仅用于验证框架运行)"
}
]
},
"AllowedHosts": "*"
}