Exemplo n.º 1
0
        private bool IsDuplicateSalesRegion()
        {
            var query = salesregions.GroupBy(x => x.Name.Trim().ToUpper())
                        .Where(g => g.Count() > 1)
                        .Select(y => y.Key)
                        .ToList();

            return(query.Count > 0);
        }
Exemplo n.º 2
0
        private bool IsDuplicateName()
        {
            var query = countries.GroupBy(x => x.Name.Trim().ToUpper())
                        .Where(g => g.Count() > 1)
                        .Select(y => y.Key)
                        .ToList();

            return(query.Count > 0);
        }
        private bool IsDuplicateSpec(int _id)
        {
            var query = _filteredassetgroupspecifications.GroupBy(x => x.SpecificationNameID)
                        .Where(g => g.Count() > 1)
                        .Select(y => y.Key)
                        .ToList();

            return(query.Count > 0);
        }
Exemplo n.º 4
0
        private bool IsDuplicateName()
        {
            bool _isduplicate = false;
            var  query        = _marketsegments.GroupBy(x => x.GOM.Name.ToUpper())
                                .Where(g => g.Count() > 1)
                                .Select(y => y.Key)
                                .ToList();

            if (query.Count > 0)
            {
                return(true);
            }

            return(_isduplicate);
        }
        private void CheckForDuplicateCountry()
        {
            var query = _associateaccesspermissions.GroupBy(x => x.CountryID)
                        .Where(g => g.Count() > 1)
                        .Select(y => y.Key)
                        .ToList();

            if (query.Count > 0)
            {
                DuplicatePermission = true;
            }
            else
            {
                DuplicatePermission = false;
            }
        }
Exemplo n.º 6
0
        private bool IsDuplicateName(string _name)
        {
            bool _isduplicate = false;

            var query = _customers.GroupBy(x => x.Name.ToUpper())
                        .Where(g => g.Count() > 1)
                        .Select(y => y.Key)
                        .ToList();

            if (query.Count > 0)
            {
                return(true);
            }

            return(_isduplicate);
        }