refactor(BookStatusEnum): add MissCatalog enum and update default book status
1. 新增BookStatusEnum枚举的MissCatalog项,赋值为-1并添加注释和Description特性 2. 将BookCreatedHandler中新建图书的默认状态从Created改为MissCatalog 3. 添加了发布配置文件用于本地文件系统部署
This commit is contained in:
@ -76,7 +76,7 @@ namespace QuestionLibraryMQConsumer.Handlers
|
|||||||
CreatedTime = DateTime.UtcNow,
|
CreatedTime = DateTime.UtcNow,
|
||||||
UpdatedTime = DateTime.UtcNow,
|
UpdatedTime = DateTime.UtcNow,
|
||||||
Source = message.Source,
|
Source = message.Source,
|
||||||
Status = (int)BookStatusEnum.Created
|
Status = (int)BookStatusEnum.MissCatalog
|
||||||
};
|
};
|
||||||
|
|
||||||
await _db.Db.Insertable(book).ExecuteCommandAsync();
|
await _db.Db.Insertable(book).ExecuteCommandAsync();
|
||||||
|
|||||||
@ -9,12 +9,16 @@ namespace QuestionLibraryMQConsumer.Models
|
|||||||
{
|
{
|
||||||
public enum BookStatusEnum
|
public enum BookStatusEnum
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 缺失目录
|
||||||
|
/// </summary>
|
||||||
|
[Description("缺失目录")]
|
||||||
|
MissCatalog = -1,
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 已创建
|
/// 已创建
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[Description("已创建")]
|
[Description("已创建")]
|
||||||
Created = 0,
|
Created = 0,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 编辑
|
/// 编辑
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
@ -0,0 +1,11 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<!-- https://go.microsoft.com/fwlink/?LinkID=208121. -->
|
||||||
|
<Project>
|
||||||
|
<PropertyGroup>
|
||||||
|
<Configuration>Release</Configuration>
|
||||||
|
<Platform>Any CPU</Platform>
|
||||||
|
<PublishDir>C:\Web\QuestionLibraryMQConsumer</PublishDir>
|
||||||
|
<PublishProtocol>FileSystem</PublishProtocol>
|
||||||
|
<_TargetId>Folder</_TargetId>
|
||||||
|
</PropertyGroup>
|
||||||
|
</Project>
|
||||||
Reference in New Issue
Block a user