diff --git a/VideoAnalysis/Components/Pages/VideoTaskPage.razor b/VideoAnalysis/Components/Pages/VideoTaskPage.razor index 8e649fb..dee6bd8 100644 --- a/VideoAnalysis/Components/Pages/VideoTaskPage.razor +++ b/VideoAnalysis/Components/Pages/VideoTaskPage.razor @@ -1,12 +1,13 @@ 锘緻page "/" -@using AntDesign -@using AntDesign.TableModels -@using System.ComponentModel.DataAnnotations -@using Learn.VideoAnalysis.Controllers.Dto -@using SqlSugar -@using VideoAnalysisCore.Model -@using VideoAnalysisCore.Model.Dto -@using VideoAnalysisCore.Enum +@ using AntDesign +@ using AntDesign.TableModels +@ using System.ComponentModel.DataAnnotations +@ using Learn.VideoAnalysis.Controllers.Dto +@ using SqlSugar +@ using VideoAnalysisCore.Model +@ using VideoAnalysisCore.Model.Dto +@ using VideoAnalysisCore.Enum; + using VideoAnalysisCore.Model.Enum AudioRecognition(IFormFile file) { - using var s = file.OpenReadStream(); + using var s = file.OpenReadStream(); var res = await SenseVoice.RunTask(s); return Ok(res); } @@ -83,7 +84,7 @@ namespace Learn.VideoAnalysis.Controllers /// 路径 /// [HttpGet(Name = "fts_data")] - public async Task FTS_Data(string path= "itn_subject_sx.fst") + public async Task FTS_Data(string path = "itn_subject_sx.fst") { var hotwords = JsonSerializer .Deserialize(System.IO.File.ReadAllText(Path.Combine(AppCommon.AIModelFile, "Hotwords.json"))); @@ -115,7 +116,7 @@ namespace Learn.VideoAnalysis.Controllers .FirstAsync(); if (task is null) return BadRequest("未能找到对应任务"); - if (subject is not null) + if (subject is not null) { task.Subject = subject; await videoTaskDB.UpdateAsync(task); @@ -134,7 +135,7 @@ namespace Learn.VideoAnalysis.Controllers /// /// [HttpPost(Name = "TestInsertChannel")] - public IActionResult TestInsertChannel(int @enum=1, string msg= "1") + public IActionResult TestInsertChannel(int @enum = 1, string msg = "1") { RedisExpand.InsertChannel(@enum.ToEnum().Value , msg); @@ -149,12 +150,12 @@ namespace Learn.VideoAnalysis.Controllers [HttpPost(Name = "VideoAnalysis")] public async Task VideoAnalysis(VideoAnalysisReq req) { - if (!ModelState.IsValid) return BadRequest(ModelState); + if (!ModelState.IsValid) return BadRequest(ModelState); - if(await videoTaskDB.IsAnyAsync(s=>s.TagId == req.TagId) ) + if (await videoTaskDB.IsAnyAsync(s => s.TagId == req.TagId)) return BadRequest("重复添加"); // 自动映射属性到哈希 - var task = new VideoTask() + var task = new VideoTask() { ComeFrom = GetClientIpAddress(), MediaUrl = req.MediaUrl, @@ -172,30 +173,10 @@ namespace Learn.VideoAnalysis.Controllers .ToDictionary(s => s.Name, s => s.GetValue(task)); RedisExpand.Redis.HMSet(RedisExpandKey.Task(task.Id), hashEntries); RedisExpand.Redis.LPush(RedisExpandKey.ChannelKey, task.Id); - return Ok(task.Id); + return Ok(task.Id); } - /// - /// 蓝鲸智库_添加文件节点监控 - /// - /// 请求体 - /// - [HttpPost(Name = "ZY_NodeMonitoring")] - public async Task ZY_NodeMonitoring(NodeMonitoringReq req) - { - //if (!ModelState.IsValid) return BadRequest(ModelState); - - //入库 - //task.Id = await videoTaskDB.InsertReturnBigIdentityAsync(task); - //var hashEntries = task.GetType() - // .GetProperties(BindingFlags.Public | BindingFlags.Instance) - // .ToDictionary(s => s.Name, s => s.GetValue(task)); - //RedisExpand.Redis.HMSet(RedisExpandKey.Task(task.Id), hashEntries); - //RedisExpand.Redis.LPush(RedisExpandKey.ChannelKey, task.Id); - return Ok(); - } - diff --git a/VideoAnalysis/Controllers/Dto/ApiDto.cs b/VideoAnalysis/Controllers/Dto/ApiDto.cs index 7784f6f..512610d 100644 --- a/VideoAnalysis/Controllers/Dto/ApiDto.cs +++ b/VideoAnalysis/Controllers/Dto/ApiDto.cs @@ -3,7 +3,7 @@ using SqlSugar; using System.ComponentModel.DataAnnotations; using UserCenter.Model.Enum; using VideoAnalysisCore.AICore.GPT.Dto; -using VideoAnalysisCore.Enum; +using VideoAnalysisCore.Model.Enum; namespace Learn.VideoAnalysis.Controllers.Dto { @@ -16,15 +16,11 @@ namespace Learn.VideoAnalysis.Controllers.Dto /// 濯掍綋璺緞 /// [Required(ErrorMessage = "鏂囦欢鑺傜偣ID鏄繀濉」")] - public string NodeId { get; set; } = string.Empty; + public long NodeId { get; set; } /// /// 浠诲姟绫诲瀷 /// public TaskTypeEnum? Type { get; set; } - /// - /// 鑷畾涔夊 浠诲姟瀹屾垚鍚庨檮甯﹂氱煡 - /// - public string Tag { get; set; } = string.Empty; } /// diff --git a/VideoAnalysis/Controllers/LJZK_Controller.cs b/VideoAnalysis/Controllers/LJZK_Controller.cs new file mode 100644 index 0000000..5efa27e --- /dev/null +++ b/VideoAnalysis/Controllers/LJZK_Controller.cs @@ -0,0 +1,74 @@ + +using VideoAnalysisCore.Common; +using Microsoft.AspNetCore.Mvc; +using System.Reflection; +using MapsterMapper; +using Mapster; +using VideoAnalysisCore.AICore.SherpaOnnx; +using UserCenter.Model.Enum; +using VideoAnalysisCore.AICore.GPT.ChatGPT; +using VideoAnalysisCore.AICore.GPT; +using System.Text.Json; +using Microsoft.AspNetCore.Authorization; +using VideoAnalysisCore.Model.Enum; + +namespace Learn.VideoAnalysis.Controllers +{ + /// + /// 蓝鲸字库接口 + /// + [ApiController] + [Route("LJZK/[action]")] + public class LJZK_Controller : ControllerBase + { + private readonly ILogger _logger; + private readonly IMapper mp; + private readonly Repository nodesubscriptionDB; + private readonly IBserGPT chatGPT; + public LJZK_Controller(ILogger logger, + IMapper mp, IBserGPT chatGPT, Repository nodesubscriptionDB) + { + _logger = logger; + this.mp = mp; + this.chatGPT = chatGPT; + this.nodesubscriptionDB = nodesubscriptionDB; + } + + + /// + /// 蓝鲸智库_添加文件节点监控 + /// + /// 请求体 + /// + [HttpPost(Name = "NodeSubscription")] + public async Task NodeSubscription(NodeMonitoringReq req) + { + if (nodesubscriptionDB.IsAny(s => s.NodeId == req.NodeId)) + return BadRequest("重复添加了节点监控任务" + req.NodeId); + var res = await nodesubscriptionDB.InsertReturnEntityAsync(new NodeSubscription() + { + NodeId = req.NodeId, + TaskType = req.Type ?? default + }); + return Ok(res); + } + + /// + /// 获取任务类型 + /// + /// + [HttpGet(Name = "TaskTypList")] + public IActionResult TaskType() + { + Type type = typeof(TaskTypeEnum); + return Ok(Enum.GetValues(type).Cast() + .Select(s => new { Text = s.ToString(), Value = (int)s })); + } + + + + + + + } +} diff --git a/VideoAnalysis/appsettings.json b/VideoAnalysis/appsettings.json index 696ed04..d184168 100644 --- a/VideoAnalysis/appsettings.json +++ b/VideoAnalysis/appsettings.json @@ -43,7 +43,7 @@ "DB": { "ConnectionString": "AllowLoadLocalInfile=true;Server=192.168.2.9;User ID=root;Password=qwe123!@#;Port=3306;Database=learn.videoanalysis;CharSet=utf8mb4;pooling=true;SslMode=None", "SqlType": "MySql", - "UpdateTable": false + "UpdateTable": true }, "OtherDBArr": [ { diff --git a/VideoAnalysisCore/AICore/FFMPGE/FFMPGEHandle.cs b/VideoAnalysisCore/AICore/FFMPGE/FFMPGEHandle.cs index b92a2ec..faf8b6a 100644 --- a/VideoAnalysisCore/AICore/FFMPGE/FFMPGEHandle.cs +++ b/VideoAnalysisCore/AICore/FFMPGE/FFMPGEHandle.cs @@ -8,6 +8,7 @@ using System.Xml.Linq; using System.Runtime.InteropServices; using SqlSugar.IOC; using VideoAnalysisCore.Model; +using VideoAnalysisCore.Model.Enum; namespace VideoAnalysisCore.AICore.FFMPGE { @@ -85,7 +86,7 @@ namespace VideoAnalysisCore.AICore.FFMPGE { Console.WriteLine("杞崲瀹屾垚=>" + e.Output.Name); //鍔犲叆涓嬩竴闃熷垪 - RedisExpand.InsertChannel(Enum.RedisChannelEnum.ParsingCaptions, Task); + RedisExpand.InsertChannel(RedisChannelEnum.ParsingCaptions, Task); } } } diff --git a/VideoAnalysisCore/AICore/GPT/ChatGPT/Chat_GPT.cs b/VideoAnalysisCore/AICore/GPT/ChatGPT/Chat_GPT.cs index 2325f4e..5bae611 100644 --- a/VideoAnalysisCore/AICore/GPT/ChatGPT/Chat_GPT.cs +++ b/VideoAnalysisCore/AICore/GPT/ChatGPT/Chat_GPT.cs @@ -3,7 +3,6 @@ using System.Text.Json; using VideoAnalysisCore.Model; using System.Text; using System.ComponentModel.DataAnnotations; -using VideoAnalysisCore.Enum; using System.Reflection; using VideoAnalysisCore.Model.Dto; using VideoAnalysisCore.AICore.GPT.Dto; @@ -11,6 +10,7 @@ using VideoAnalysisCore.AICore.GPT; using System.Threading.Tasks; using VideoAnalysisCore.AICore.SherpaOnnx; using VideoAnalysisCore.Model.钃濋哺鏅哄簱; +using VideoAnalysisCore.Model.Enum; namespace VideoAnalysisCore.AICore.GPT.ChatGPT { diff --git a/VideoAnalysisCore/AICore/GPT/DeepSeek/DeepSeek_GPT.cs b/VideoAnalysisCore/AICore/GPT/DeepSeek/DeepSeek_GPT.cs index a013a57..26c7806 100644 --- a/VideoAnalysisCore/AICore/GPT/DeepSeek/DeepSeek_GPT.cs +++ b/VideoAnalysisCore/AICore/GPT/DeepSeek/DeepSeek_GPT.cs @@ -3,7 +3,6 @@ using System.Text.Json; using VideoAnalysisCore.Model; using System.Text; using System.ComponentModel.DataAnnotations; -using VideoAnalysisCore.Enum; using System.Reflection; using VideoAnalysisCore.Model.Dto; using VideoAnalysisCore.AICore.GPT.Dto; @@ -11,6 +10,7 @@ using System.Threading.Tasks; using VideoAnalysisCore.AICore.GPT.ChatGPT; using VideoAnalysisCore.AICore.SherpaOnnx; using VideoAnalysisCore.Model.钃濋哺鏅哄簱; +using VideoAnalysisCore.Model.Enum; namespace VideoAnalysisCore.AICore.GPT.DeepSeek { diff --git a/VideoAnalysisCore/AICore/GPT/Dto/CallGPTRes.cs b/VideoAnalysisCore/AICore/GPT/Dto/CallGPTRes.cs index ec29722..5693eea 100644 --- a/VideoAnalysisCore/AICore/GPT/Dto/CallGPTRes.cs +++ b/VideoAnalysisCore/AICore/GPT/Dto/CallGPTRes.cs @@ -4,8 +4,8 @@ using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; -using VideoAnalysisCore.Enum; using VideoAnalysisCore.Model.Dto; +using VideoAnalysisCore.Model.Enum; namespace VideoAnalysisCore.AICore.GPT.Dto { diff --git a/VideoAnalysisCore/AICore/GPT/KIMI/KIMI_GPT.cs b/VideoAnalysisCore/AICore/GPT/KIMI/KIMI_GPT.cs index 9678c03..5576b54 100644 --- a/VideoAnalysisCore/AICore/GPT/KIMI/KIMI_GPT.cs +++ b/VideoAnalysisCore/AICore/GPT/KIMI/KIMI_GPT.cs @@ -8,7 +8,6 @@ using System.Text; using FFmpeg.NET.Services; using Microsoft.Extensions.Primitives; using System.ComponentModel.DataAnnotations; -using VideoAnalysisCore.Enum; using System.Reflection; using FreeRedis; using VideoAnalysisCore.Model.Dto; @@ -17,6 +16,7 @@ using SqlSugar.IOC; using VideoAnalysisCore.AICore.GPT.Dto; using VideoAnalysisCore.AICore.GPT; using VideoAnalysisCore.AICore.GPT.ChatGPT; +using VideoAnalysisCore.Model.Enum; namespace VideoAnalysisCore.AICore.GPT.KIMI { diff --git a/VideoAnalysisCore/AICore/SherpaOnnx/SenseVoice.cs b/VideoAnalysisCore/AICore/SherpaOnnx/SenseVoice.cs index fbdfb15..878c816 100644 --- a/VideoAnalysisCore/AICore/SherpaOnnx/SenseVoice.cs +++ b/VideoAnalysisCore/AICore/SherpaOnnx/SenseVoice.cs @@ -12,6 +12,7 @@ using System.Text.RegularExpressions; using System.Threading.Tasks; using VideoAnalysisCore.Common; using VideoAnalysisCore.Model; +using VideoAnalysisCore.Model.Enum; using static System.Runtime.InteropServices.JavaScript.JSType; namespace VideoAnalysisCore.AICore.SherpaOnnx @@ -267,7 +268,7 @@ namespace VideoAnalysisCore.AICore.SherpaOnnx .Where(it => it.Id == long.Parse(task)); await RedisExpand.Redis.HMSetAsync(RedisExpandKey.Task(task), "Captions", res); //RedisExpand.InsertChannel(Enum.RedisChannelEnum.ParsingSpeaker, task); - RedisExpand.InsertChannel(Enum.RedisChannelEnum.ChatModelAnalysis, task); + RedisExpand.InsertChannel(RedisChannelEnum.ChatModelAnalysis, task); } } diff --git a/VideoAnalysisCore/AICore/SherpaOnnx/Speaker.cs b/VideoAnalysisCore/AICore/SherpaOnnx/Speaker.cs index c434ee4..219eb7f 100644 --- a/VideoAnalysisCore/AICore/SherpaOnnx/Speaker.cs +++ b/VideoAnalysisCore/AICore/SherpaOnnx/Speaker.cs @@ -7,6 +7,7 @@ using SherpaOnnx; using SqlSugar.IOC; using VideoAnalysisCore.Model; using System.Text.Json; +using VideoAnalysisCore.Model.Enum; namespace VideoAnalysisCore.AICore.SherpaOnnx { @@ -81,7 +82,7 @@ namespace VideoAnalysisCore.AICore.SherpaOnnx .SetColumns(it => it.Speaker == speakerStr) .Where(it => it.Id == long.Parse(task)); //鍔犲叆涓嬩竴闃熷垪 - RedisExpand.InsertChannel(Enum.RedisChannelEnum.ChatModelAnalysis, task); + RedisExpand.InsertChannel(RedisChannelEnum.ChatModelAnalysis, task); } } diff --git a/VideoAnalysisCore/AICore/Whisper/WhisperHandle.cs b/VideoAnalysisCore/AICore/Whisper/WhisperHandle.cs index 8ab2f15..f244ec2 100644 --- a/VideoAnalysisCore/AICore/Whisper/WhisperHandle.cs +++ b/VideoAnalysisCore/AICore/Whisper/WhisperHandle.cs @@ -4,6 +4,7 @@ using System.Linq; using Whisper.net; using Whisper.net.Ggml; using Whisper.net.Wave; +using VideoAnalysisCore.Model.Enum; namespace VideoAnalysisCore.AICore.Whisper { @@ -45,7 +46,7 @@ namespace VideoAnalysisCore.AICore.Whisper res.Add(new WhisperResDto(segment)); } RedisExpand.Redis.HMSet(RedisExpandKey.Task(task), "Captions", res); - RedisExpand.InsertChannel(Enum.RedisChannelEnum.ParsingSpeaker, task); + RedisExpand.InsertChannel(RedisChannelEnum.ParsingSpeaker, task); } /// /// 妫娴嬭瑷鐨勬柟娉 diff --git a/VideoAnalysisCore/Common/AppCommon.cs b/VideoAnalysisCore/Common/AppCommon.cs index 46194d9..838aa06 100644 --- a/VideoAnalysisCore/Common/AppCommon.cs +++ b/VideoAnalysisCore/Common/AppCommon.cs @@ -15,10 +15,9 @@ using System.Text.RegularExpressions; using System.Threading.Tasks; using UserCenter.Model.Interface; using VideoAnalysisCore.AICore.SherpaOnnx; -using VideoAnalysisCore.Enum; -using VideoAnalysisCore.Interface; -using VideoAnalysisCore.Model; using VideoAnalysisCore.Model.Dto; +using VideoAnalysisCore.Model.Enum; +using VideoAnalysisCore.Model.Interface; namespace VideoAnalysisCore.Common { @@ -406,7 +405,9 @@ namespace VideoAnalysisCore.Common /// 鏁版嵁搴撻厤缃 /// public DBConfig DB { get; set; } = new DBConfig(); - + /// + /// 鍏朵粬鏁版嵁搴撻厤缃 + /// public DBConfig[] OtherDBArr { get; set; } = Array.Empty(); } diff --git a/VideoAnalysisCore/Common/CoravelExpand.cs b/VideoAnalysisCore/Common/CoravelExpand.cs index b4a1438..720fdb7 100644 --- a/VideoAnalysisCore/Common/CoravelExpand.cs +++ b/VideoAnalysisCore/Common/CoravelExpand.cs @@ -17,14 +17,14 @@ namespace VideoAnalysisCore.Common { service.AddScheduler(); - service.AddTransient(); + service.AddTransient(); } public static void Run(IServiceProvider provider) { provider.UseScheduler(scheduler => { //姣5鍒嗛挓鎵ц涓娆 鏈鐞嗚棰戞壂鎻 - scheduler.Schedule().EveryFiveMinutes(); + scheduler.Schedule().EveryFiveMinutes(); }); } } diff --git a/VideoAnalysisCore/Common/DownloadFile.cs b/VideoAnalysisCore/Common/DownloadFile.cs index a5ceb4b..2cd469a 100644 --- a/VideoAnalysisCore/Common/DownloadFile.cs +++ b/VideoAnalysisCore/Common/DownloadFile.cs @@ -8,6 +8,7 @@ using System.IO; using System.Net; using System.Threading.Tasks; using VideoAnalysisCore.Model; +using VideoAnalysisCore.Model.Enum; namespace VideoAnalysisCore.Common { @@ -153,7 +154,7 @@ namespace VideoAnalysisCore.Common else if (download.Status == DownloadStatus.Completed) { //鍔犲叆涓嬩竴闃熷垪 - RedisExpand.InsertChannel(Enum.RedisChannelEnum.SeparateAudio, task); + RedisExpand.InsertChannel(RedisChannelEnum.SeparateAudio, task); return; } diff --git a/VideoAnalysisCore/Common/RedisExpand.cs b/VideoAnalysisCore/Common/RedisExpand.cs index 6de3f7a..365d26b 100644 --- a/VideoAnalysisCore/Common/RedisExpand.cs +++ b/VideoAnalysisCore/Common/RedisExpand.cs @@ -17,9 +17,9 @@ using VideoAnalysisCore.AICore.GPT.Dto; //using VideoAnalysisCore.AICore.FFMPGE; using VideoAnalysisCore.AICore.SherpaOnnx; using VideoAnalysisCore.AICore.Whisper; -using VideoAnalysisCore.Enum; using VideoAnalysisCore.Model; using VideoAnalysisCore.Model.Dto; +using VideoAnalysisCore.Model.Enum; namespace VideoAnalysisCore.Common { diff --git a/VideoAnalysisCore/Enum/ScoreTypeEnum.cs b/VideoAnalysisCore/Enum/ScoreTypeEnum.cs deleted file mode 100644 index 5ed30ef..0000000 --- a/VideoAnalysisCore/Enum/ScoreTypeEnum.cs +++ /dev/null @@ -1,13 +0,0 @@ -锘縩amespace VideoAnalysisCore.Enum -{ - /// - /// 寰楀垎绫诲瀷 - /// - public enum ScoreTypeEnum - { - 浼=75, - 鑹=50, - 涓=25, - 宸=0, - } -} diff --git a/VideoAnalysisCore/Job/NodeSubscriptionJob.cs b/VideoAnalysisCore/Job/NodeSubscriptionJob.cs new file mode 100644 index 0000000..2a39c7f --- /dev/null +++ b/VideoAnalysisCore/Job/NodeSubscriptionJob.cs @@ -0,0 +1,68 @@ +锘縰sing Coravel.Invocable; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using VideoAnalysisCore.Common; +using VideoAnalysisCore.Model; +using VideoAnalysisCore.Model.钃濋哺鏅哄簱; + +namespace VideoAnalysisCore.Job +{ + /// + /// [钃濋哺鏅哄簱] 鏌ユ壘鏈鐞嗙殑瑙嗛 + /// + public class NodeSubscriptionJob : IInvocable + { + private readonly Repository nodesubscriptionDB; + private readonly Repository attachmentsDB; + public NodeSubscriptionJob(Repository videoTaskDB, Repository nodesubscriptionDB) + { + this.attachmentsDB = videoTaskDB; + this.nodesubscriptionDB = nodesubscriptionDB; + } + public async Task Invoke() + { + Console.WriteLine($"{DateTime.Now} Invoke=>{this.GetType().FullName}"); + + var tasks = await nodesubscriptionDB.GetListAsync(s => s.Enable); + foreach (var item in tasks) + { + var fileNodeId = item.NodeId; + var data = attachmentsDB.Context.Ado + .SqlQuery($""" + SELECT + * + FROM + Attachments + WHERE + Id IN ( + SELECT + AttachmentsId + FROM + Material + WHERE + id IN ( + SELECT + MaterialId + FROM + FileContentMaterial + WHERE + FileContentId IN ( SELECT id FROM FileContent WHERE BagId IN ( SELECT Id FROM FileDirectory WHERE Id={fileNodeId} AND types = 1 AND DeleteState = 0 ) ) + AND DeleteState = 0 + AND ( MaterialName NOT LIKE '%PPT%' OR MaterialName NOT LIKE '%ppt%' ) + ) + ) + AND Type = '褰曟挱瑙嗛' + AND ( + NAME NOT LIKE '%PPT%' + OR NAME NOT LIKE '%ppt%' + ) + """); + + + } + } + } +} diff --git a/VideoAnalysisCore/Job/UnprocessedVideoJob.cs b/VideoAnalysisCore/Job/UnprocessedVideoJob.cs deleted file mode 100644 index 224835a..0000000 --- a/VideoAnalysisCore/Job/UnprocessedVideoJob.cs +++ /dev/null @@ -1,28 +0,0 @@ -锘縰sing Coravel.Invocable; -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; -using VideoAnalysisCore.Common; -using VideoAnalysisCore.Model; - -namespace VideoAnalysisCore.Job -{ - /// - /// 鏌ユ壘鏈鐞嗙殑瑙嗛 - /// - public class UnprocessedVideoJob : IInvocable - { - private readonly Repository videoTaskDB; - public UnprocessedVideoJob(Repository videoTaskDB) - { - this.videoTaskDB = videoTaskDB; - } - public async Task Invoke() - { - - - } - } -} diff --git a/VideoAnalysisCore/Model/CourseGradingCriteria.cs b/VideoAnalysisCore/Model/CourseGradingCriteria.cs index 1cfd29d..ec8f8bb 100644 --- a/VideoAnalysisCore/Model/CourseGradingCriteria.cs +++ b/VideoAnalysisCore/Model/CourseGradingCriteria.cs @@ -6,7 +6,7 @@ using System.Net; using UserCenter.Model.Enum; using VideoAnalysisCore.AICore.SherpaOnnx; using VideoAnalysisCore.Enum; -using VideoAnalysisCore.Interface; +using VideoAnalysisCore.Model.Interface; using Whisper.net; namespace VideoAnalysisCore.Model diff --git a/VideoAnalysisCore/Model/Dto/HotwordMode.cs b/VideoAnalysisCore/Model/Dto/HotwordMode.cs index b842e37..d31e1c8 100644 --- a/VideoAnalysisCore/Model/Dto/HotwordMode.cs +++ b/VideoAnalysisCore/Model/Dto/HotwordMode.cs @@ -4,7 +4,7 @@ using System.Linq; using System.Text; using System.Threading.Tasks; -namespace VideoAnalysisCore.Model +namespace VideoAnalysisCore.Model.Dto { public class HotwordMode { diff --git a/VideoAnalysisCore/Model/Dto/SpeakerCaptionsDto.cs b/VideoAnalysisCore/Model/Dto/SpeakerCaptionsDto.cs index c2c1f7f..fca152e 100644 --- a/VideoAnalysisCore/Model/Dto/SpeakerCaptionsDto.cs +++ b/VideoAnalysisCore/Model/Dto/SpeakerCaptionsDto.cs @@ -1,6 +1,6 @@ 锘縰sing AntDesign; using VideoAnalysisCore.AICore.GPT.Dto; -using VideoAnalysisCore.Enum; +using VideoAnalysisCore.Model.Enum; namespace VideoAnalysisCore.Model.Dto { diff --git a/VideoAnalysisCore/Model/Dto/VideoTaskDto.cs b/VideoAnalysisCore/Model/Dto/VideoTaskDto.cs index 574a58e..a80893d 100644 --- a/VideoAnalysisCore/Model/Dto/VideoTaskDto.cs +++ b/VideoAnalysisCore/Model/Dto/VideoTaskDto.cs @@ -6,9 +6,9 @@ using System.ComponentModel; using System.Linq; using System.Text; using System.Threading.Tasks; -using VideoAnalysisCore.Enum; using System.Text.Json; using UserCenter.Model.Enum; +using VideoAnalysisCore.Model.Enum; namespace VideoAnalysisCore.Model.Dto { diff --git a/VideoAnalysisCore/Enum/QuestionTypeEnum.cs b/VideoAnalysisCore/Model/Enum/QuestionTypeEnum.cs similarity index 96% rename from VideoAnalysisCore/Enum/QuestionTypeEnum.cs rename to VideoAnalysisCore/Model/Enum/QuestionTypeEnum.cs index 61c311d..61f6307 100644 --- a/VideoAnalysisCore/Enum/QuestionTypeEnum.cs +++ b/VideoAnalysisCore/Model/Enum/QuestionTypeEnum.cs @@ -5,7 +5,7 @@ using System.Linq; using System.Text; using System.Threading.Tasks; -namespace VideoAnalysisCore.Enum +namespace VideoAnalysisCore.Model.Enum { public enum QuestionTypeEnum { diff --git a/VideoAnalysisCore/Enum/RedisChannelEnum.cs b/VideoAnalysisCore/Model/Enum/RedisChannelEnum.cs similarity index 94% rename from VideoAnalysisCore/Enum/RedisChannelEnum.cs rename to VideoAnalysisCore/Model/Enum/RedisChannelEnum.cs index 281d95d..716321c 100644 --- a/VideoAnalysisCore/Enum/RedisChannelEnum.cs +++ b/VideoAnalysisCore/Model/Enum/RedisChannelEnum.cs @@ -1,4 +1,4 @@ -锘縩amespace VideoAnalysisCore.Enum +锘縩amespace VideoAnalysisCore.Model.Enum { /// /// redis 棰戦亾 diff --git a/VideoAnalysisCore/Model/Enum/ScoreTypeEnum.cs b/VideoAnalysisCore/Model/Enum/ScoreTypeEnum.cs new file mode 100644 index 0000000..cbbc98e --- /dev/null +++ b/VideoAnalysisCore/Model/Enum/ScoreTypeEnum.cs @@ -0,0 +1,13 @@ +锘縩amespace VideoAnalysisCore.Model.Enum +{ + /// + /// 寰楀垎绫诲瀷 + /// + public enum ScoreTypeEnum + { + 浼 = 75, + 鑹 = 50, + 涓 = 25, + 宸 = 0, + } +} diff --git a/VideoAnalysisCore/Enum/TaskTypeEnum.cs b/VideoAnalysisCore/Model/Enum/TaskTypeEnum.cs similarity index 93% rename from VideoAnalysisCore/Enum/TaskTypeEnum.cs rename to VideoAnalysisCore/Model/Enum/TaskTypeEnum.cs index 69d3389..b87e627 100644 --- a/VideoAnalysisCore/Enum/TaskTypeEnum.cs +++ b/VideoAnalysisCore/Model/Enum/TaskTypeEnum.cs @@ -5,7 +5,7 @@ using System.Linq; using System.Text; using System.Threading.Tasks; -namespace VideoAnalysisCore.Enum +namespace VideoAnalysisCore.Model.Enum { public enum TaskTypeEnum { diff --git a/VideoAnalysisCore/Enum/TeacherAnswerTypeEnum.cs b/VideoAnalysisCore/Model/Enum/TeacherAnswerTypeEnum.cs similarity index 88% rename from VideoAnalysisCore/Enum/TeacherAnswerTypeEnum.cs rename to VideoAnalysisCore/Model/Enum/TeacherAnswerTypeEnum.cs index 4c2e5fd..5e6605b 100644 --- a/VideoAnalysisCore/Enum/TeacherAnswerTypeEnum.cs +++ b/VideoAnalysisCore/Model/Enum/TeacherAnswerTypeEnum.cs @@ -4,7 +4,7 @@ using System.Linq; using System.Text; using System.Threading.Tasks; -namespace VideoAnalysisCore.Enum +namespace VideoAnalysisCore.Model.Enum { public enum TeacherAnswerTypeEnum { diff --git a/VideoAnalysisCore/Enum/TimeBaseEnum.cs b/VideoAnalysisCore/Model/Enum/TimeBaseEnum.cs similarity index 93% rename from VideoAnalysisCore/Enum/TimeBaseEnum.cs rename to VideoAnalysisCore/Model/Enum/TimeBaseEnum.cs index 1bc39ac..f31374f 100644 --- a/VideoAnalysisCore/Enum/TimeBaseEnum.cs +++ b/VideoAnalysisCore/Model/Enum/TimeBaseEnum.cs @@ -1,4 +1,4 @@ -锘縩amespace VideoAnalysisCore.Enum +锘縩amespace VideoAnalysisCore.Model.Enum { /// /// 鏃堕棿绾跨被鍨 diff --git a/VideoAnalysisCore/Interface/IDB.cs b/VideoAnalysisCore/Model/Interface/IDB.cs similarity index 82% rename from VideoAnalysisCore/Interface/IDB.cs rename to VideoAnalysisCore/Model/Interface/IDB.cs index 9bb9511..1a825b3 100644 --- a/VideoAnalysisCore/Interface/IDB.cs +++ b/VideoAnalysisCore/Model/Interface/IDB.cs @@ -4,7 +4,7 @@ using System.Linq; using System.Text; using System.Threading.Tasks; -namespace VideoAnalysisCore.Interface +namespace VideoAnalysisCore.Model.Interface { /// /// 琛ㄥ睘浜嶪DB diff --git a/VideoAnalysisCore/Model/NodeSubscription.cs b/VideoAnalysisCore/Model/NodeSubscription.cs new file mode 100644 index 0000000..9be18cb --- /dev/null +++ b/VideoAnalysisCore/Model/NodeSubscription.cs @@ -0,0 +1,55 @@ +锘縰sing AntDesign; +using SqlSugar; +using System.ComponentModel; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using System.Net; +using UserCenter.Model.Enum; +using VideoAnalysisCore.AICore.SherpaOnnx; +using VideoAnalysisCore.Model.Enum; +using VideoAnalysisCore.Model.Interface; +using Whisper.net; + +namespace VideoAnalysisCore.Model +{ + /// + /// [钃濋哺鏅哄簱]鏂囦欢鑺傜偣璁㈤槄 + /// + [SugarTable("nodesubscription")] + public class NodeSubscription: IDB + { + /// + /// Id + /// + [SugarColumn(IsPrimaryKey = true, IsIdentity = true)] + [DisplayName("缂栧彿")] + public long Id { get; set; } + /// + /// 鏂囦欢鑺傜偣Id + /// + [DisplayName("鏂囦欢鑺傜偣Id"), Required] + public long NodeId { get; set; } + + /// + /// 缁戝畾瀛︾ + /// + [DisplayName("缁戝畾瀛︾")] + public TaskTypeEnum TaskType { get; set; } + /// + /// 鏄惁鍚敤 + /// + [DisplayName("鏄惁鍚敤")] + public bool Enable { get; set; } = true; + /// + /// 鏈鍚庢墽琛岀殑id鍊 + /// + [DisplayName("鏈鍚庢墽琛岀殑id鍊")] + public long LastId { get; set; } + /// + /// 鍒涘缓鏃堕棿 + /// + [DisplayName("鍒涘缓鏃堕棿")] + public DateTime CreateTime { get; set; } =DateTime.Now; + + } +} diff --git a/VideoAnalysisCore/Model/VideoKonwPoint.cs b/VideoAnalysisCore/Model/VideoKonwPoint.cs index 3d5d1e7..18d4a87 100644 --- a/VideoAnalysisCore/Model/VideoKonwPoint.cs +++ b/VideoAnalysisCore/Model/VideoKonwPoint.cs @@ -6,7 +6,7 @@ using UserCenter.Model.Enum; using VideoAnalysisCore.AICore.GPT.Dto; using VideoAnalysisCore.AICore.SherpaOnnx; using VideoAnalysisCore.Enum; -using VideoAnalysisCore.Interface; +using VideoAnalysisCore.Model.Interface; using Whisper.net; namespace VideoAnalysisCore.Model diff --git a/VideoAnalysisCore/Model/VideoTask.cs b/VideoAnalysisCore/Model/VideoTask.cs index 22a5a7e..3fc49e6 100644 --- a/VideoAnalysisCore/Model/VideoTask.cs +++ b/VideoAnalysisCore/Model/VideoTask.cs @@ -5,8 +5,8 @@ using System.Text.Json; using UserCenter.Model.Enum; using VideoAnalysisCore.AICore.GPT.Dto; using VideoAnalysisCore.AICore.SherpaOnnx; -using VideoAnalysisCore.Enum; -using VideoAnalysisCore.Interface; +using VideoAnalysisCore.Model.Enum; +using VideoAnalysisCore.Model.Interface; using Whisper.net; namespace VideoAnalysisCore.Model diff --git a/VideoAnalysisCore/Model/钃濋哺鏅哄簱/Attachments.cs b/VideoAnalysisCore/Model/钃濋哺鏅哄簱/Attachments.cs index 66296fa..eecf394 100644 --- a/VideoAnalysisCore/Model/钃濋哺鏅哄簱/Attachments.cs +++ b/VideoAnalysisCore/Model/钃濋哺鏅哄簱/Attachments.cs @@ -4,7 +4,7 @@ using System.Text; using SqlSugar; using VideoAnalysisCore.Interface; -namespace App.Model +namespace VideoAnalysisCore.Model.钃濋哺鏅哄簱 { /// ///鏂囦欢闄勪欢 @@ -16,10 +16,10 @@ namespace App.Model public Attachments() { - this.SchoolId = Convert.ToInt64("0"); - this.Sort = Convert.ToInt32("0"); - this.CreateTime = DateTime.Now; - this.DeleteState = false; + SchoolId = Convert.ToInt64("0"); + Sort = Convert.ToInt32("0"); + CreateTime = DateTime.Now; + DeleteState = false; } /// @@ -175,7 +175,7 @@ namespace App.Model [SugarColumn(ColumnDescription = "鏂板鐢ㄦ埛瑙掕壊id", IsNullable = true)] public long AdminRoleId { get; set; } - + } diff --git a/VideoAnalysisCore/Model/钃濋哺鏅哄簱/FileContent.cs b/VideoAnalysisCore/Model/钃濋哺鏅哄簱/FileContent.cs index eb3738a..25af937 100644 --- a/VideoAnalysisCore/Model/钃濋哺鏅哄簱/FileContent.cs +++ b/VideoAnalysisCore/Model/钃濋哺鏅哄簱/FileContent.cs @@ -4,25 +4,26 @@ using System.Text; using SqlSugar; using VideoAnalysisCore.Interface; -namespace App.Model +namespace VideoAnalysisCore.Model.钃濋哺鏅哄簱 { /// /// 鏂囦欢鍐呭琛 /// [SugarTable("FileContent")] [Tenant("1002")] - public partial class FileContent + public partial class FileContent { - public FileContent(){ + public FileContent() + { - this.Sort =Convert.ToInt32("0"); - this.CreateTime =DateTime.Now; - this.DeleteState =false; + Sort = Convert.ToInt32("0"); + CreateTime = DateTime.Now; + DeleteState = false; - } - - [SugarColumn(IsPrimaryKey=true,IsIdentity=true)] - public long Id {get;set;} + } + + [SugarColumn(IsPrimaryKey = true, IsIdentity = true)] + public long Id { get; set; } /// /// Desc:鍐呭鍚嶇О @@ -30,7 +31,7 @@ namespace App.Model /// Nullable:False /// [SugarColumn(ColumnDescription = "鍐呭鍚嶇О", ColumnDataType = "nvarchar(500)", IsNullable = false)] - public string FileName {get;set;} + public string FileName { get; set; } /// /// Desc: @@ -38,23 +39,23 @@ namespace App.Model /// Nullable:True /// [SugarColumn(ColumnDescription = "瀛︽牎id", IsNullable = true)] - public long? SchoolId {get;set;} + public long? SchoolId { get; set; } - /// - /// Desc: - /// Default: - /// Nullable:True - /// + /// + /// Desc: + /// Default: + /// Nullable:True + /// [SugarColumn(ColumnDescription = "瀛︽牎鍚嶇О", ColumnDataType = "nvarchar(100)", IsNullable = true)] - public string SchoolName {get;set;} + public string SchoolName { get; set; } - /// - /// Desc:骞寸骇 - /// Default: - /// Nullable:True - /// + /// + /// Desc:骞寸骇 + /// Default: + /// Nullable:True + /// [SugarColumn(ColumnDescription = "骞寸骇", ColumnDataType = "nvarchar(30)", IsNullable = true)] - public string GradeName {get;set;} + public string GradeName { get; set; } /// /// Desc:绉戠洰 @@ -63,44 +64,44 @@ namespace App.Model /// [SugarColumn(ColumnDescription = "绉戠洰", IsNullable = true)] - public int? SubjectId {get;set;} + public int? SubjectId { get; set; } - /// - /// Desc: - /// Default: - /// Nullable:True - /// + /// + /// Desc: + /// Default: + /// Nullable:True + /// [SugarColumn(ColumnDescription = "绉戠洰鍚嶇О", ColumnDataType = "nvarchar(50)", IsNullable = true)] - public string SubjectName {get;set;} + public string SubjectName { get; set; } - /// - /// Desc:鏂囦欢绯荤粺鐩綍id - /// Default: - /// Nullable:False - /// + /// + /// Desc:鏂囦欢绯荤粺鐩綍id + /// Default: + /// Nullable:False + /// [SugarColumn(ColumnDescription = "浠剁郴缁熺洰褰昳d", IsNullable = false)] - public long FileDirectoryId {get;set;} + public long FileDirectoryId { get; set; } - /// - /// Desc: - /// Default:0 - /// Nullable:False - /// + /// + /// Desc: + /// Default:0 + /// Nullable:False + /// [SugarColumn(ColumnDescription = "鎺掑簭", IsNullable = false, DefaultValue = "0")] - public int Sort {get;set;} + public int Sort { get; set; } - - public DateTime CreateTime {get;set;} - - public bool DeleteState {get;set;} - /// - /// Desc:鏂囦欢鍖匢d - /// Default: - /// Nullable:False - /// + public DateTime CreateTime { get; set; } + + public bool DeleteState { get; set; } + + /// + /// Desc:鏂囦欢鍖匢d + /// Default: + /// Nullable:False + /// [SugarColumn(ColumnDescription = "鏂囦欢鍖卛d", IsNullable = false)] - public long BagId {get;set;} + public long BagId { get; set; } /// /// Desc:浣滆 @@ -108,7 +109,7 @@ namespace App.Model /// Nullable:True /// [SugarColumn(ColumnDescription = "浣滆", ColumnDataType = "nvarchar(200)", IsNullable = true)] - public string Author {get;set;} + public string Author { get; set; } /// /// 鏄惁鍙互涓嬭浇 @@ -117,12 +118,12 @@ namespace App.Model /// /// 绠$悊鍛榠d /// - [SugarColumn(ColumnDescription = "绠$悊鍛榠d", IsNullable = true)] + [SugarColumn(ColumnDescription = "绠$悊鍛榠d", IsNullable = true)] public long? AdminId { get; set; } /// /// 绠$悊鍛樿鑹瞚d /// - [SugarColumn(ColumnDescription = "绠$悊鍛樿鑹瞚d", IsNullable = true)] + [SugarColumn(ColumnDescription = "绠$悊鍛樿鑹瞚d", IsNullable = true)] public long? AdminRoleId { get; set; } } } diff --git a/VideoAnalysisCore/Model/钃濋哺鏅哄簱/FileContentMaterial.cs b/VideoAnalysisCore/Model/钃濋哺鏅哄簱/FileContentMaterial.cs index a79eb62..8c4613c 100644 --- a/VideoAnalysisCore/Model/钃濋哺鏅哄簱/FileContentMaterial.cs +++ b/VideoAnalysisCore/Model/钃濋哺鏅哄簱/FileContentMaterial.cs @@ -4,56 +4,57 @@ using System.Text; using SqlSugar; using VideoAnalysisCore.Interface; -namespace App.Model +namespace VideoAnalysisCore.Model.钃濋哺鏅哄簱 { /// /// /// [SugarTable("FileContentMaterial")] [Tenant("1002")] - public partial class FileContentMaterial + public partial class FileContentMaterial { - public FileContentMaterial(){ + public FileContentMaterial() + { - this.CreateTime =DateTime.Now; - this.DeleteState =false; + CreateTime = DateTime.Now; + DeleteState = false; - } - /// - /// Desc:鏂囦欢绯荤粺鍐呭 - /// Default: - /// Nullable:False - /// - [SugarColumn(IsPrimaryKey=true,IsIdentity=true)] - public long Id {get;set;} + } + /// + /// Desc:鏂囦欢绯荤粺鍐呭 + /// Default: + /// Nullable:False + /// + [SugarColumn(IsPrimaryKey = true, IsIdentity = true)] + public long Id { get; set; } - /// - /// Desc:鏂囦欢绯荤粺鍐呭 - /// Default: - /// Nullable:False - /// - public long FileContentId {get;set;} + /// + /// Desc:鏂囦欢绯荤粺鍐呭 + /// Default: + /// Nullable:False + /// + public long FileContentId { get; set; } - /// - /// Desc:绱犳潗id - /// Default: - /// Nullable:False - /// - public long MaterialId {get;set;} + /// + /// Desc:绱犳潗id + /// Default: + /// Nullable:False + /// + public long MaterialId { get; set; } - /// - /// Desc: - /// Default:DateTime.Now - /// Nullable:False - /// - public DateTime CreateTime {get;set;} + /// + /// Desc: + /// Default:DateTime.Now + /// Nullable:False + /// + public DateTime CreateTime { get; set; } - /// - /// Desc: - /// Default:0 - /// Nullable:False - /// - public bool DeleteState {get;set;} + /// + /// Desc: + /// Default:0 + /// Nullable:False + /// + public bool DeleteState { get; set; } public int Sort { get; set; } diff --git a/VideoAnalysisCore/Model/钃濋哺鏅哄簱/FileDirectory.cs b/VideoAnalysisCore/Model/钃濋哺鏅哄簱/FileDirectory.cs index e0e3173..82f9eb2 100644 --- a/VideoAnalysisCore/Model/钃濋哺鏅哄簱/FileDirectory.cs +++ b/VideoAnalysisCore/Model/钃濋哺鏅哄簱/FileDirectory.cs @@ -4,31 +4,32 @@ using System.Text; using SqlSugar; using VideoAnalysisCore.Interface; -namespace App.Model +namespace VideoAnalysisCore.Model.钃濋哺鏅哄簱 { /// /// 鏂囦欢鐩綍琛 /// [SugarTable("FileDirectory")] [Tenant("1002")] - public partial class FileDirectory + public partial class FileDirectory { - public FileDirectory(){ + public FileDirectory() + { - this.State =Convert.ToInt32("1"); - this.IsCheckedSelect =true; - this.IsLastNode =false; - this.ParentId =Convert.ToInt64("0"); - this.CreateTime =DateTime.Now; - this.DeleteState =false; - this.AliasName =Convert.ToString(""); - this.IsPublic =false; - this.Types =Convert.ToInt32("-1"); - this.Code =Convert.ToString(""); + State = Convert.ToInt32("1"); + IsCheckedSelect = true; + IsLastNode = false; + ParentId = Convert.ToInt64("0"); + CreateTime = DateTime.Now; + DeleteState = false; + AliasName = Convert.ToString(""); + IsPublic = false; + Types = Convert.ToInt32("-1"); + Code = Convert.ToString(""); - } - [SugarColumn(IsPrimaryKey=true,IsIdentity=true)] - public long Id {get;set;} + } + [SugarColumn(IsPrimaryKey = true, IsIdentity = true)] + public long Id { get; set; } /// /// Desc:鍚嶇О @@ -36,116 +37,116 @@ namespace App.Model /// Nullable:False /// [SugarColumn(ColumnDescription = "鍚嶇О", ColumnDataType = "nvarchar(50)", IsNullable = false)] - public string Name {get;set;} + public string Name { get; set; } - /// - /// Desc:鎺掑簭 - /// Default: - /// Nullable:False - /// + /// + /// Desc:鎺掑簭 + /// Default: + /// Nullable:False + /// [SugarColumn(ColumnDescription = "鎺掑簭", IsNullable = false)] - public int Sort {get;set;} + public int Sort { get; set; } - /// - /// Desc:缁撴瀯鐘舵 1=鏄剧ず - /// Default:1 - /// Nullable:False - /// - [SugarColumn(ColumnDescription = "缁撴瀯鐘舵 1=鏄剧ず", IsNullable = false,DefaultValue ="1")] - public int State {get;set;} + /// + /// Desc:缁撴瀯鐘舵 1=鏄剧ず + /// Default:1 + /// Nullable:False + /// + [SugarColumn(ColumnDescription = "缁撴瀯鐘舵 1=鏄剧ず", IsNullable = false, DefaultValue = "1")] + public int State { get; set; } - /// - /// Desc:鏄惁鑷姩鎺堟潈 - /// Default:1 - /// Nullable:False - /// + /// + /// Desc:鏄惁鑷姩鎺堟潈 + /// Default:1 + /// Nullable:False + /// [SugarColumn(ColumnDescription = "鏄惁鑷姩鎺堟潈", IsNullable = false, DefaultValue = "1")] - public bool IsCheckedSelect {get;set;} + public bool IsCheckedSelect { get; set; } - /// - /// Desc:鏄惁鏈鍚庝竴绾ц妭鐐 - /// Default:0 - /// Nullable:False - /// + /// + /// Desc:鏄惁鏈鍚庝竴绾ц妭鐐 + /// Default:0 + /// Nullable:False + /// [SugarColumn(ColumnDescription = "鏄惁鏈鍚庝竴绾ц妭鐐", IsNullable = false, DefaultValue = "0")] - public bool IsLastNode {get;set;} + public bool IsLastNode { get; set; } - /// - /// Desc:涓婄骇id - /// Default:0 - /// Nullable:False - /// + /// + /// Desc:涓婄骇id + /// Default:0 + /// Nullable:False + /// [SugarColumn(ColumnDescription = "涓婄骇id", IsNullable = false, DefaultValue = "0")] - public long ParentId {get;set;} + public long ParentId { get; set; } - - public DateTime CreateTime {get;set;} - - public bool DeleteState {get;set;} - /// - /// Desc:鍒悕 - /// Default: - /// Nullable:False - /// + public DateTime CreateTime { get; set; } + + public bool DeleteState { get; set; } + + /// + /// Desc:鍒悕 + /// Default: + /// Nullable:False + /// [SugarColumn(ColumnDescription = "鍒悕", ColumnDataType = "nvarchar(50)", IsNullable = false)] - public string AliasName {get;set;} + public string AliasName { get; set; } - /// - /// Desc:鏄惁鍏紑 - /// Default:0 - /// Nullable:True - /// + /// + /// Desc:鏄惁鍏紑 + /// Default:0 + /// Nullable:True + /// [SugarColumn(ColumnDescription = "鏄惁鍏紑", IsNullable = true, DefaultValue = "0")] - public bool? IsPublic {get;set;} + public bool? IsPublic { get; set; } - /// - /// Desc:鍏朵粬=-1锛岀洰褰=0,璇剧▼=1,绔=2,鑺=3 - /// Default:-1 - /// Nullable:True - /// + /// + /// Desc:鍏朵粬=-1锛岀洰褰=0,璇剧▼=1,绔=2,鑺=3 + /// Default:-1 + /// Nullable:True + /// [SugarColumn(ColumnDescription = "鍏朵粬=-1锛岀洰褰=0,璇剧▼=1,绔=2,鑺=3", IsNullable = true, DefaultValue = "-1")] - public int? Types {get;set;} + public int? Types { get; set; } - /// - /// Desc: - /// Default: - /// Nullable:True - /// + /// + /// Desc: + /// Default: + /// Nullable:True + /// [SugarColumn(ColumnDescription = "鏇存柊鏃堕棿", IsNullable = true)] - public DateTime? UpdateTime {get;set;} + public DateTime? UpdateTime { get; set; } - /// - /// Desc:璇剧▼id锛堟潵婧恈ourseinfo锛 - /// Default: - /// Nullable:True - /// + /// + /// Desc:璇剧▼id锛堟潵婧恈ourseinfo锛 + /// Default: + /// Nullable:True + /// [SugarColumn(ColumnDescription = "璇剧▼id锛堟潵婧恈ourseinfo锛", IsNullable = true)] - public long? CourseId {get;set;} + public long? CourseId { get; set; } - /// - /// Desc:鏁欐潗鐗堟湰id锛堟潵婧 textboox_versions锛 - /// Default: - /// Nullable:True - /// + /// + /// Desc:鏁欐潗鐗堟湰id锛堟潵婧 textboox_versions锛 + /// Default: + /// Nullable:True + /// [SugarColumn(ColumnDescription = "鏁欐潗鐗堟湰id锛堟潵婧 textboox_versions锛", IsNullable = true)] - public long? VersionsId {get;set;} + public long? VersionsId { get; set; } - /// - /// Desc: - /// Default: - /// Nullable:True - /// + /// + /// Desc: + /// Default: + /// Nullable:True + /// [SugarColumn(ColumnDescription = "", ColumnDataType = "nvarchar(50)", IsNullable = true)] - public string Code {get;set;} + public string Code { get; set; } - /// - /// Desc:鏍硅妭鐐筰d - /// Default: - /// Nullable:True - /// + /// + /// Desc:鏍硅妭鐐筰d + /// Default: + /// Nullable:True + /// [SugarColumn(ColumnDescription = "鏍硅妭鐐筰d", IsNullable = true)] - public long? RootId {get;set;} + public long? RootId { get; set; } /// /// 绠$悊鍛榠d /// diff --git a/VideoAnalysisCore/Model/钃濋哺鏅哄簱/Material.cs b/VideoAnalysisCore/Model/钃濋哺鏅哄簱/Material.cs index 49cd3e8..8b0e3c8 100644 --- a/VideoAnalysisCore/Model/钃濋哺鏅哄簱/Material.cs +++ b/VideoAnalysisCore/Model/钃濋哺鏅哄簱/Material.cs @@ -4,24 +4,24 @@ using System.Text; using SqlSugar; using VideoAnalysisCore.Interface; -namespace App.Model +namespace VideoAnalysisCore.Model.钃濋哺鏅哄簱 { /// ///绱犳潗琛 /// [SugarTable("Material")] [Tenant("1002")] - public partial class Material + public partial class Material { public Material() { - this.TagId = Convert.ToInt64("0"); - this.CreateTime = DateTime.Now; - this.DeleteState = false; - this.DownState = false; + TagId = Convert.ToInt64("0"); + CreateTime = DateTime.Now; + DeleteState = false; + DownState = false; } - + [SugarColumn(IsPrimaryKey = true, IsIdentity = true)] public long Id { get; set; } @@ -46,7 +46,7 @@ namespace App.Model /// Default:0 /// Nullable:False /// - [SugarColumn(ColumnDescription = "绱犳爣绛綢d", IsNullable = false,DefaultValue ="0")] + [SugarColumn(ColumnDescription = "绱犳爣绛綢d", IsNullable = false, DefaultValue = "0")] public long TagId { get; set; } /// @@ -62,7 +62,7 @@ namespace App.Model /// Default: /// Nullable:False /// - [SugarColumn(ColumnDescription = "闄勪欢id",IsNullable = false)] + [SugarColumn(ColumnDescription = "闄勪欢id", IsNullable = false)] public long AttachmentsId { get; set; } /// @@ -72,9 +72,9 @@ namespace App.Model /// [SugarColumn(ColumnDescription = "鍐呭", ColumnDataType = "nvarchar(max)", IsNullable = true)] public string Desc { get; set; } - + public DateTime CreateTime { get; set; } - + public bool DeleteState { get; set; } /// @@ -88,10 +88,10 @@ namespace App.Model /// Default: /// Nullable:False /// - [SugarColumn(ColumnDescription = "鏂板鐢ㄦ埛鍚嶇О",ColumnDataType = "nvarchar(50)")] + [SugarColumn(ColumnDescription = "鏂板鐢ㄦ埛鍚嶇О", ColumnDataType = "nvarchar(50)")] public string CreateUserName { get; set; } - [SugarColumn(ColumnDescription = "瀛︽牎id",IsNullable =true)] + [SugarColumn(ColumnDescription = "瀛︽牎id", IsNullable = true)] public long SchoolId { get; set; } [SugarColumn(ColumnDescription = "瀛︽牎鍚嶇О", ColumnDataType = "nvarchar(50)", IsNullable = true)] @@ -99,12 +99,12 @@ namespace App.Model /// /// 鏄惁鍙互涓嬭浇 /// - [SugarColumn(ColumnDescription = "鏄惁鍙互涓嬭浇", DefaultValue ="0")] + [SugarColumn(ColumnDescription = "鏄惁鍙互涓嬭浇", DefaultValue = "0")] public bool DownState { get; set; } /// /// 鏂板鐢ㄦ埛瑙掕壊id /// - [SugarColumn(ColumnDescription = "鏂板鐢ㄦ埛瑙掕壊id",IsNullable =true)] + [SugarColumn(ColumnDescription = "鏂板鐢ㄦ埛瑙掕壊id", IsNullable = true)] public long AdminRoleId { get; set; } } }