Beispiel #1
0
        public ResponseResult <List <dynamic> > GetEntityInfoWithAttrValueList(EntityInfoQuery query)
        {
            var result = ResponseResult <List <dynamic> > .Default();

            try
            {
                var entity = FBDataService.GetEntityInfoWithAttrValueList(query);
                result = ResponseResult <List <dynamic> > .Success(entity);
            }
            catch (System.Exception ex)
            {
                result = ResponseResult <List <dynamic> > .Error(
                    string.Format("获取单挑表单数据失败,错误{0}", ex.Message)
                    );
            }
            return(result);
        }
        /// <summary>
        /// 获取特定表单的实例数据
        /// </summary>
        /// <param name="query">实体查询对象</param>
        /// <returns>表单数值列表</returns>
        public List <dynamic> GetEntityInfoWithAttrValueList(EntityInfoQuery query)
        {
            List <dynamic> list = null;

            try
            {
                var param = new DynamicParameters();
                param.Add("@queryType", 1);
                param.Add("@entityDefID", query.EntityDefID);

                using (var conn = SessionFactory.CreateConnection())
                {
                    list = QuickRepository.ExecProcQuery <dynamic>(conn, "pr_eav_EntityAttrValuePivotGet", param).ToList <dynamic>();
                }
                return(list);
            }
            catch (System.Exception ex)
            {
                throw;
            }
        }