using BS.Shared.DataContracts;
using BS.Shared.DataContracts.Compact;

namespace BeWo.View.Navigation.Filter
{
    public class SupportConceptNavigationFilter : CustomFilter
    {
        public bool ShowOnlyMySupportConcepts { get; set; }

        public bool ShowOnlyTeamSupportConcepts { get; set; }

        public override bool IsValid(IFilterableDC dc)
        {
            CompactSupportConceptDC scDC = dc as CompactSupportConceptDC;

            if (scDC != null)
            {
                if (this.ShowOnlyMySupportConcepts && scDC != null)
                {
                    return scDC.IsRelatedToEmployee;
                }

                if (this.ShowOnlyTeamSupportConcepts)
                {
                    // return scDC.Customer.IsRelatedToTeamLeader;
                }
            }

            return true;
        }
    }
}