Example #1
0
        /// <summary>
        /// 获取单个数据
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        public SysresourceModel Get(long id)
        {
            var data = _dataAccess.Get(id);

            if (data == null || data.IsDel == FlagEnum.HadOne.GetHashCode())
            {
                return(null);
            }
            return(data);
        }
Example #2
0
        public void ResourceData_Get_AssignsIsRemoteToValue()
        {
            var resourceData = ResourceData.Get(true, null);

            resourceData.IsRemote.Should().BeTrue();
        }
Example #3
0
        public void ResourceData_Get_AssignsUrlToValue()
        {
            var resourceData = ResourceData.Get(true, "url");

            resourceData.Url.Should().Be("url");
        }