refactoring

This commit is contained in:
2023-06-22 10:01:27 +03:00
parent e9d4053e65
commit d549877567
116 changed files with 1216 additions and 11709 deletions
@@ -0,0 +1,21 @@
namespace MyOffice.Data.Repositories.Item;
using MyOffice.Data.Models.Items;
public class ItemGlobalRepository : AppRepository<ItemGlobal>, IItemGlobalRepository
{
public ItemGlobal? Get(Guid id)
{
return _context.ItemGlobals.FirstOrDefault(x => x.Id == id);
}
public ItemGlobal? GetByName(string name)
{
return _context.ItemGlobals.FirstOrDefault(x => x.Name == name);
}
public bool Add(ItemGlobal itemGlobal)
{
return AddBase(itemGlobal) > 0;
}
}