FIC_Solar/SolarPower/Repository/Interface/ICompanyRepository.cs
2021-06-09 15:03:24 +08:00

63 lines
2.0 KiB
C#
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

using SolarPower.Models.Company;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
namespace SolarPower.Repository.Interface
{
public interface ICompanyRepository : IRepositoryBase<Company>
{
/// <summary>
/// 取得狀態為正常的公司
/// </summary>
/// <param name="id"></param>
/// <returns></returns>
SimpleCompany GetOneNormalSimpleCompanyById(int id);
/// <summary>
/// 修改公司資料
/// </summary>
/// <param name="entity"></param>
/// <param name="properties"></param>
/// <returns></returns>
Task UpdateCompany(UpdateCompany entity, List<string> properties);
/// <summary>
/// 取得下拉式公司選單須為Deleted: 0、Status: 1
/// </summary>
/// <param name="filter"></param>
/// <returns></returns>
Task<List<CompanySelectItemList>> GetCompanySelectOptionListAsync();
/// <summary>
/// 透過搜尋條件,查詢過濾後的公司
/// </summary>
/// <param name="filter"></param>
/// <returns></returns>
Task<List<CompanyDataTable>> GetAllByFilterAsync(PostCompanyFilter filter);
/// <summary>
/// 透過公司Id查詢該公司底下狀態為正常的使用者
/// </summary>
/// <param name="filter"></param>
/// <returns></returns>
Task<int> GetNormalUserNumberByCompanyIdAsync(int id);
/// <summary>
/// 取得單一公司資料
/// </summary>
/// <param name="id"></param>
/// <returns></returns>
Task<Company> GetOneCompany(int id);
/// <summary>
/// 透過統編,取得單一公司基本資料
/// </summary>
/// <param name="taxIDNumber"></param>
/// <returns></returns>
Task<SimpleCompany> GetOneNormalSimpleCompanyByTaxIDNumber(string taxIDNumber);
}
}