按照软件设计文档开始重构代码01
This commit is contained in:
@@ -2,6 +2,7 @@ using DMS.Core.Models;
|
||||
using SqlSugar;
|
||||
using System.Collections.Generic;
|
||||
using System.Threading.Tasks;
|
||||
using DMS.Infrastructure.Entities;
|
||||
|
||||
namespace DMS.Infrastructure.Interfaces
|
||||
{
|
||||
|
||||
@@ -7,13 +7,14 @@ namespace DMS.Infrastructure.Interfaces
|
||||
{
|
||||
public interface IMqttRepository
|
||||
{
|
||||
Task<DbMqtt> GetByIdAsync(int id);
|
||||
Task<List<DbMqtt>> GetAllAsync();
|
||||
Task<int> AddAsync(DbMqtt mqtt);
|
||||
Task<int> UpdateAsync(DbMqtt mqtt);
|
||||
Task<int> DeleteAsync(DbMqtt mqtt);
|
||||
Task<DbMqttServer> GetByIdAsync(int id);
|
||||
Task<List<DbMqttServer>> GetAllAsync();
|
||||
Task<int> AddAsync(DbMqttServer mqtt);
|
||||
Task<int> UpdateAsync(DbMqttServer mqtt);
|
||||
Task<int> DeleteAsync(DbMqttServer mqtt);
|
||||
Task BeginTranAsync();
|
||||
Task CommitTranAsync();
|
||||
Task RollbackTranAsync();
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,12 +1,13 @@
|
||||
using DMS.Core.Models;
|
||||
using System.Collections.Generic;
|
||||
using System.Threading.Tasks;
|
||||
using DMS.Infrastructure.Entities;
|
||||
|
||||
namespace DMS.Infrastructure.Interfaces
|
||||
{
|
||||
public interface IVariableMqttAliasRepository
|
||||
{
|
||||
Task<VariableMqtt?> GetByIdAsync(int variableDataId, int mqttId);
|
||||
Task<DbVariableMqttAlias?> GetByIdAsync(int variableDataId, int mqttId);
|
||||
Task<int> UpdateAliasAsync(int variableDataId, int mqttId, string newAlias);
|
||||
Task<int> DeleteAsync(int variableDataId, int mqttId);
|
||||
Task BeginTranAsync();
|
||||
|
||||
Reference in New Issue
Block a user