コード例 #1
0
 public async Task <ApiJsonResultData> MedicalInsuranceDataAllQuery([FromBody] MedicalInsuranceDataAllParamUIQueryParam param)
 {
     return(await new ApiJsonResultData(ModelState).RunWithTryAsync(async y =>
     {
         //[FromBody] MedicalInsuranceDataAllParamUIQueryParam param
         var data = await _dataBaseHelpService.SaveMedicalInsuranceDataAllQuery(param);
         y.Data = data;
     }));
 }
コード例 #2
0
        /// <summary>
        ///  医保反馈数据查询
        /// </summary>
        /// <param name="user"></param>
        /// <param name="param"></param>
        /// <returns></returns>
        public async Task <MedicalInsuranceDataAllDto> SaveMedicalInsuranceDataAllQuery(MedicalInsuranceDataAllParamUIQueryParam param)
        {
            using (var _sqlConnection = new SqlConnection(_connectionString))
            {
                var resultData = new MedicalInsuranceDataAllDto();
                _sqlConnection.Open();
                string strSql = $@"
                SELECT [DataAllId]
                      ,[ParticipationJson]
                      ,[ResultDataJson]
                      ,[DataType]
                      ,[DataId]
                      ,[HisMedicalInsuranceId]
                      ,[BusinessId]
                      ,[Remark]
                      ,[CreateUserId]
                      ,[CreateTime]
                      ,[DeleteTime]
                      ,[OrgCode]
                      ,[DeleteUserId]
                  FROM [dbo].[MedicalInsuranceDataAll] where DataId='{param.DataId}' and  DataType='{param.DataType}' and OrgCode='{param.OrgCode}' and BusinessId='{param.BusinessId}' and  DeleteTime is  null";
                var    data   = await _sqlConnection.QueryFirstOrDefaultAsync <MedicalInsuranceDataAllDto>(strSql);

                return(data ?? resultData);
            }
        }