style: 修改目录
@@ -0,0 +1,16 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Yi.BBS.Domain.Shared.Forum.EnumClasses
|
||||
{
|
||||
public enum QueryDiscussTypeEnum
|
||||
{
|
||||
New,
|
||||
Suggest,
|
||||
Host
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Yi.BBS.Domain.Shared.Forum.Etos
|
||||
{
|
||||
public class SeeDiscussEventArgs
|
||||
{
|
||||
public long DiscussId { get; set; }
|
||||
public int OldSeeNum { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,255 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using Yi.Framework.Data.DataSeeds;
|
||||
using Yi.Framework.Ddd.Repositories;
|
||||
using Yi.RBAC.Domain.Identity.Entities;
|
||||
using Yi.RBAC.Domain.Shared.Identity.EnumClasses;
|
||||
|
||||
namespace Yi.BBS.Domain.DataSeed
|
||||
{
|
||||
[AppService(typeof(IDataSeed))]
|
||||
public class BbsMenuDataSeed : AbstractDataSeed<MenuEntity>
|
||||
{
|
||||
public BbsMenuDataSeed(IRepository<MenuEntity> repository) : base(repository)
|
||||
{
|
||||
}
|
||||
|
||||
public override async Task<bool> IsInvoker()
|
||||
{
|
||||
return !await _repository.IsAnyAsync(x => x.MenuName == "BBS");
|
||||
}
|
||||
public override List<MenuEntity> GetSeedData()
|
||||
{
|
||||
List<MenuEntity> entities = new List<MenuEntity>();
|
||||
//BBS
|
||||
MenuEntity bbs = new MenuEntity()
|
||||
{
|
||||
Id = SnowflakeHelper.NextId,
|
||||
MenuName = "BBS",
|
||||
MenuType = MenuTypeEnum.Catalogue,
|
||||
Router = "/bbs",
|
||||
IsShow = true,
|
||||
IsLink = false,
|
||||
MenuIcon = "international",
|
||||
OrderNum = 97,
|
||||
ParentId = 0,
|
||||
IsDeleted = false
|
||||
};
|
||||
entities.Add(bbs);
|
||||
//文章管理
|
||||
MenuEntity article = new MenuEntity()
|
||||
{
|
||||
Id = SnowflakeHelper.NextId,
|
||||
MenuName = "文章管理",
|
||||
PermissionCode = "bbs:article:list",
|
||||
MenuType = MenuTypeEnum.Menu,
|
||||
Router = "article",
|
||||
IsShow = true,
|
||||
IsLink = false,
|
||||
IsCache = true,
|
||||
Component = "bbs/article/index",
|
||||
MenuIcon = "education",
|
||||
OrderNum = 100,
|
||||
ParentId = bbs.Id,
|
||||
IsDeleted = false
|
||||
};
|
||||
entities.Add(article);
|
||||
|
||||
MenuEntity articleQuery = new MenuEntity()
|
||||
{
|
||||
Id = SnowflakeHelper.NextId,
|
||||
MenuName = "文章查询",
|
||||
PermissionCode = "bbs:article:query",
|
||||
MenuType = MenuTypeEnum.Component,
|
||||
OrderNum = 100,
|
||||
ParentId = article.Id,
|
||||
IsDeleted = false
|
||||
};
|
||||
entities.Add(articleQuery);
|
||||
|
||||
MenuEntity articleAdd = new MenuEntity()
|
||||
{
|
||||
Id = SnowflakeHelper.NextId,
|
||||
MenuName = "文章新增",
|
||||
PermissionCode = "bbs:article:add",
|
||||
MenuType = MenuTypeEnum.Component,
|
||||
OrderNum = 100,
|
||||
ParentId = article.Id,
|
||||
IsDeleted = false
|
||||
};
|
||||
entities.Add(articleAdd);
|
||||
|
||||
MenuEntity articleEdit = new MenuEntity()
|
||||
{
|
||||
Id = SnowflakeHelper.NextId,
|
||||
MenuName = "文章修改",
|
||||
PermissionCode = "bbs:article:edit",
|
||||
MenuType = MenuTypeEnum.Component,
|
||||
OrderNum = 100,
|
||||
ParentId = article.Id,
|
||||
IsDeleted = false
|
||||
};
|
||||
entities.Add(articleEdit);
|
||||
|
||||
MenuEntity articleRemove = new MenuEntity()
|
||||
{
|
||||
Id = SnowflakeHelper.NextId,
|
||||
MenuName = "文章删除",
|
||||
PermissionCode = "bbs:article:remove",
|
||||
MenuType = MenuTypeEnum.Component,
|
||||
OrderNum = 100,
|
||||
ParentId = article.Id,
|
||||
IsDeleted = false
|
||||
};
|
||||
entities.Add(articleRemove);
|
||||
|
||||
|
||||
//主题管理
|
||||
MenuEntity discuss = new MenuEntity()
|
||||
{
|
||||
Id = SnowflakeHelper.NextId,
|
||||
MenuName = "主题管理",
|
||||
PermissionCode = "bbs:discuss:list",
|
||||
MenuType = MenuTypeEnum.Menu,
|
||||
Router = "discuss",
|
||||
IsShow = true,
|
||||
IsLink = false,
|
||||
IsCache = true,
|
||||
Component = "bbs/discuss/index",
|
||||
MenuIcon = "education",
|
||||
OrderNum = 100,
|
||||
ParentId = bbs.Id,
|
||||
IsDeleted = false
|
||||
};
|
||||
entities.Add(discuss);
|
||||
|
||||
MenuEntity discussQuery = new MenuEntity()
|
||||
{
|
||||
Id = SnowflakeHelper.NextId,
|
||||
MenuName = "主题查询",
|
||||
PermissionCode = "bbs:discuss:query",
|
||||
MenuType = MenuTypeEnum.Component,
|
||||
OrderNum = 100,
|
||||
ParentId = discuss.Id,
|
||||
IsDeleted = false
|
||||
};
|
||||
entities.Add(discussQuery);
|
||||
|
||||
MenuEntity discussAdd = new MenuEntity()
|
||||
{
|
||||
Id = SnowflakeHelper.NextId,
|
||||
MenuName = "主题新增",
|
||||
PermissionCode = "bbs:discuss:add",
|
||||
MenuType = MenuTypeEnum.Component,
|
||||
OrderNum = 100,
|
||||
ParentId = discuss.Id,
|
||||
IsDeleted = false
|
||||
};
|
||||
entities.Add(discussAdd);
|
||||
|
||||
MenuEntity discussEdit = new MenuEntity()
|
||||
{
|
||||
Id = SnowflakeHelper.NextId,
|
||||
MenuName = "主题修改",
|
||||
PermissionCode = "bbs:discuss:edit",
|
||||
MenuType = MenuTypeEnum.Component,
|
||||
OrderNum = 100,
|
||||
ParentId = discuss.Id,
|
||||
IsDeleted = false
|
||||
};
|
||||
entities.Add(discussEdit);
|
||||
|
||||
MenuEntity discussRemove = new MenuEntity()
|
||||
{
|
||||
Id = SnowflakeHelper.NextId,
|
||||
MenuName = "主题删除",
|
||||
PermissionCode = "bbs:discuss:remove",
|
||||
MenuType = MenuTypeEnum.Component,
|
||||
OrderNum = 100,
|
||||
ParentId = discuss.Id,
|
||||
IsDeleted = false
|
||||
};
|
||||
entities.Add(discussRemove);
|
||||
|
||||
|
||||
|
||||
//板块管理
|
||||
MenuEntity plate = new MenuEntity()
|
||||
{
|
||||
Id = SnowflakeHelper.NextId,
|
||||
MenuName = "板块管理",
|
||||
PermissionCode = "bbs:plate:list",
|
||||
MenuType = MenuTypeEnum.Menu,
|
||||
Router = "plate",
|
||||
IsShow = true,
|
||||
IsLink = false,
|
||||
IsCache = true,
|
||||
Component = "bbs/plate/index",
|
||||
MenuIcon = "education",
|
||||
OrderNum = 100,
|
||||
ParentId = bbs.Id,
|
||||
IsDeleted = false
|
||||
};
|
||||
entities.Add(plate);
|
||||
|
||||
MenuEntity plateQuery = new MenuEntity()
|
||||
{
|
||||
Id = SnowflakeHelper.NextId,
|
||||
MenuName = "板块查询",
|
||||
PermissionCode = "bbs:plate:query",
|
||||
MenuType = MenuTypeEnum.Component,
|
||||
OrderNum = 100,
|
||||
ParentId = plate.Id,
|
||||
IsDeleted = false
|
||||
};
|
||||
entities.Add(plateQuery);
|
||||
|
||||
MenuEntity plateAdd = new MenuEntity()
|
||||
{
|
||||
Id = SnowflakeHelper.NextId,
|
||||
MenuName = "板块新增",
|
||||
PermissionCode = "bbs:plate:add",
|
||||
MenuType = MenuTypeEnum.Component,
|
||||
OrderNum = 100,
|
||||
ParentId = plate.Id,
|
||||
IsDeleted = false
|
||||
};
|
||||
entities.Add(plateAdd);
|
||||
|
||||
MenuEntity plateEdit = new MenuEntity()
|
||||
{
|
||||
Id = SnowflakeHelper.NextId,
|
||||
MenuName = "板块修改",
|
||||
PermissionCode = "bbs:plate:edit",
|
||||
MenuType = MenuTypeEnum.Component,
|
||||
OrderNum = 100,
|
||||
ParentId = plate.Id,
|
||||
IsDeleted = false
|
||||
};
|
||||
entities.Add(plateEdit);
|
||||
|
||||
MenuEntity plateRemove = new MenuEntity()
|
||||
{
|
||||
Id = SnowflakeHelper.NextId,
|
||||
MenuName = "板块删除",
|
||||
PermissionCode = "bbs:plate:remove",
|
||||
MenuType = MenuTypeEnum.Component,
|
||||
OrderNum = 100,
|
||||
ParentId = plate.Id,
|
||||
IsDeleted = false
|
||||
};
|
||||
entities.Add(plateRemove);
|
||||
|
||||
//默认值
|
||||
entities.ForEach(m =>
|
||||
{
|
||||
m.IsDeleted = false;
|
||||
m.State = true;
|
||||
});
|
||||
return entities;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,31 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using Cike.EventBus.EventHandlerAbstracts;
|
||||
using Yi.BBS.Domain.Forum.Entities;
|
||||
using Yi.BBS.Domain.Shared.Forum.Etos;
|
||||
using Yi.Framework.Ddd.Repositories;
|
||||
using Yi.RBAC.Domain.Shared.Identity.Etos;
|
||||
|
||||
namespace Yi.BBS.Domain.Forum.Event
|
||||
{
|
||||
public class SeeDiscussEventHandler : IDistributedEventHandler<SeeDiscussEventArgs>
|
||||
{
|
||||
private IRepository<DiscussEntity> _repository;
|
||||
public SeeDiscussEventHandler(IRepository<DiscussEntity> repository)
|
||||
{
|
||||
_repository = repository;
|
||||
}
|
||||
public async Task HandlerAsync(SeeDiscussEventArgs eventData)
|
||||
{
|
||||
var entity= await _repository.GetByIdAsync(eventData.DiscussId);
|
||||
if (entity is not null) {
|
||||
entity.SeeNum += 1;
|
||||
await _repository.UpdateAsync(entity);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
BIN
Yi.Framework.Net6/src/project/bbs/Yi.BBS.Web/ip2region.db
Normal file
|
After Width: | Height: | Size: 27 KiB |
|
After Width: | Height: | Size: 23 KiB |
|
After Width: | Height: | Size: 23 KiB |
|
After Width: | Height: | Size: 24 KiB |
|
After Width: | Height: | Size: 21 KiB |
|
After Width: | Height: | Size: 24 KiB |
|
After Width: | Height: | Size: 23 KiB |
|
After Width: | Height: | Size: 24 KiB |
|
After Width: | Height: | Size: 16 KiB |
|
After Width: | Height: | Size: 8.9 KiB |
|
After Width: | Height: | Size: 31 KiB |
|
After Width: | Height: | Size: 9.2 KiB |
|
After Width: | Height: | Size: 30 KiB |
|
After Width: | Height: | Size: 30 KiB |
|
After Width: | Height: | Size: 21 KiB |
|
After Width: | Height: | Size: 21 KiB |
|
After Width: | Height: | Size: 21 KiB |
|
After Width: | Height: | Size: 21 KiB |
|
After Width: | Height: | Size: 21 KiB |
|
After Width: | Height: | Size: 21 KiB |
|
After Width: | Height: | Size: 21 KiB |
|
After Width: | Height: | Size: 21 KiB |
|
After Width: | Height: | Size: 21 KiB |
|
After Width: | Height: | Size: 21 KiB |
|
After Width: | Height: | Size: 21 KiB |
|
After Width: | Height: | Size: 21 KiB |
|
After Width: | Height: | Size: 616 KiB |
|
After Width: | Height: | Size: 616 KiB |
|
After Width: | Height: | Size: 616 KiB |
|
After Width: | Height: | Size: 616 KiB |
|
After Width: | Height: | Size: 616 KiB |
|
After Width: | Height: | Size: 616 KiB |
|
After Width: | Height: | Size: 616 KiB |
|
After Width: | Height: | Size: 616 KiB |
|
After Width: | Height: | Size: 616 KiB |
|
After Width: | Height: | Size: 616 KiB |
|
After Width: | Height: | Size: 616 KiB |
|
After Width: | Height: | Size: 616 KiB |
|
After Width: | Height: | Size: 5.4 KiB |
|
After Width: | Height: | Size: 5.4 KiB |
|
After Width: | Height: | Size: 5.4 KiB |
|
After Width: | Height: | Size: 5.4 KiB |
|
After Width: | Height: | Size: 5.4 KiB |
|
After Width: | Height: | Size: 5.4 KiB |
|
After Width: | Height: | Size: 5.4 KiB |
|
After Width: | Height: | Size: 5.4 KiB |
|
After Width: | Height: | Size: 5.4 KiB |
|
After Width: | Height: | Size: 5.4 KiB |
|
After Width: | Height: | Size: 5.4 KiB |
|
After Width: | Height: | Size: 5.4 KiB |
@@ -1,28 +0,0 @@
|
||||
3-5
|
||||
一周一次
|
||||
|
||||
实现涂膜功能
|
||||
1:数据存储,Crud
|
||||
2:后台线程,任务调度
|
||||
3:plc通信交互,IM工厂
|
||||
4:定时任务界面管控
|
||||
5:signlr开发
|
||||
6:授权鉴权
|
||||
7:用户角色菜单模块
|
||||
8:配置文件统一标准化
|
||||
9:规范问题
|
||||
10:动态api
|
||||
11:发布订阅
|
||||
12:resful
|
||||
13:dto注释
|
||||
14:代码中文
|
||||
15:种子数据
|
||||
|
||||
1:job任务调度的模式,可以在if上的改
|
||||
2:Crud,EntityServiceBase,考虑复用的话sqlsugar这块就不用动了、仓储、工作单元、过滤器
|
||||
3:IOptionsWritable ,直接可以复用
|
||||
4:事件,是否需要,需要的话,用哪个
|
||||
5:动态api,是否需要
|
||||
6:IM,IVarReader中的IDataChannel工厂
|
||||
6:ISignal
|
||||
7:微软日志扩展,这块是否考虑封装出来,还是直接提供微软日志的扩展,我们提供模板就可以了
|
||||
@@ -1,28 +0,0 @@
|
||||
3-5
|
||||
一周一次
|
||||
|
||||
实现涂膜功能
|
||||
1:数据存储,Crud
|
||||
2:后台线程,任务调度
|
||||
3:plc通信交互,IM工厂
|
||||
4:定时任务界面管控
|
||||
5:signlr开发
|
||||
6:授权鉴权
|
||||
7:用户角色菜单模块
|
||||
8:配置文件统一标准化
|
||||
9:规范问题
|
||||
10:动态api
|
||||
11:发布订阅
|
||||
12:resful
|
||||
13:dto注释
|
||||
14:代码中文
|
||||
15:种子数据
|
||||
|
||||
1:job任务调度的模式,可以在if上的改
|
||||
2:Crud,EntityServiceBase,考虑复用的话sqlsugar这块就不用动了、仓储、工作单元、过滤器
|
||||
3:IOptionsWritable ,直接可以复用
|
||||
4:事件,是否需要,需要的话,用哪个
|
||||
5:动态api,是否需要
|
||||
6:IM,IVarReader中的IDataChannel工厂
|
||||
6:ISignal
|
||||
7:微软日志扩展,这块是否考虑封装出来,还是直接提供微软日志的扩展,我们提供模板就可以了
|
||||
@@ -1,28 +0,0 @@
|
||||
3-5
|
||||
一周一次
|
||||
|
||||
实现涂膜功能
|
||||
1:数据存储,Crud
|
||||
2:后台线程,任务调度
|
||||
3:plc通信交互,IM工厂
|
||||
4:定时任务界面管控
|
||||
5:signlr开发
|
||||
6:授权鉴权
|
||||
7:用户角色菜单模块
|
||||
8:配置文件统一标准化
|
||||
9:规范问题
|
||||
10:动态api
|
||||
11:发布订阅
|
||||
12:resful
|
||||
13:dto注释
|
||||
14:代码中文
|
||||
15:种子数据
|
||||
|
||||
1:job任务调度的模式,可以在if上的改
|
||||
2:Crud,EntityServiceBase,考虑复用的话sqlsugar这块就不用动了、仓储、工作单元、过滤器
|
||||
3:IOptionsWritable ,直接可以复用
|
||||
4:事件,是否需要,需要的话,用哪个
|
||||
5:动态api,是否需要
|
||||
6:IM,IVarReader中的IDataChannel工厂
|
||||
6:ISignal
|
||||
7:微软日志扩展,这块是否考虑封装出来,还是直接提供微软日志的扩展,我们提供模板就可以了
|
||||
@@ -1,28 +0,0 @@
|
||||
3-5
|
||||
一周一次
|
||||
|
||||
实现涂膜功能
|
||||
1:数据存储,Crud
|
||||
2:后台线程,任务调度
|
||||
3:plc通信交互,IM工厂
|
||||
4:定时任务界面管控
|
||||
5:signlr开发
|
||||
6:授权鉴权
|
||||
7:用户角色菜单模块
|
||||
8:配置文件统一标准化
|
||||
9:规范问题
|
||||
10:动态api
|
||||
11:发布订阅
|
||||
12:resful
|
||||
13:dto注释
|
||||
14:代码中文
|
||||
15:种子数据
|
||||
|
||||
1:job任务调度的模式,可以在if上的改
|
||||
2:Crud,EntityServiceBase,考虑复用的话sqlsugar这块就不用动了、仓储、工作单元、过滤器
|
||||
3:IOptionsWritable ,直接可以复用
|
||||
4:事件,是否需要,需要的话,用哪个
|
||||
5:动态api,是否需要
|
||||
6:IM,IVarReader中的IDataChannel工厂
|
||||
6:ISignal
|
||||
7:微软日志扩展,这块是否考虑封装出来,还是直接提供微软日志的扩展,我们提供模板就可以了
|
||||
|
Before Width: | Height: | Size: 21 KiB |
|
Before Width: | Height: | Size: 17 KiB |
|
Before Width: | Height: | Size: 30 KiB |
|
Before Width: | Height: | Size: 30 KiB |
|
Before Width: | Height: | Size: 10 KiB |