public ActionResult Exist(FileInfoParamDto vm)
        {
            if (vm != null && !string.IsNullOrEmpty(vm.Name) && vm.Type != (int)FileInfoType.None)
            {
                var  fileInfoService = this.GetService <IFileInfoService>();
                bool result          = fileInfoService.Exist(vm);

                return(Success(result));
            }

            return(Error());
        }
Пример #2
0
        public virtual bool Exist(FileInfoParamDto vm)
        {
            var fileInfoRepository = this.GetRepository <IFileInfoRepository>();

            return(fileInfoRepository.Exist(vm.Directory, vm.Name, vm.Type));
        }