using PMSWPF.Data.Entities; namespace PMSWPF.Data.Repositories; public class DevicesRepositories:BaseRepositories { public DevicesRepositories() { } public async Task Add(DbPLC dbPLC) { return await _db.Insertable(dbPLC).ExecuteCommandAsync(); } public async Task> GetAll() { return await _db.Queryable().ToListAsync(); } public async Task GetById(int id) { return await _db.Queryable().FirstAsync(p=>p.id == id); } public async Task DeleteById(int id) { return await _db.Deleteable(new DbPLC() { id = id }).ExecuteCommandAsync(); } }