Например. из хранимой процедуры я возвращаю записи для двух запросов
Код: Выделить всё
Select * LMS_Survey
Select * from LMS_SurveyQuestion
Select * from LMS_SurveyQuestionOptionChoice
Код: Выделить всё
public class LMS_SurveyTraineeViewModel
{
public LMS_SurveyDetailsViewModel SurveyDetailsViewModel { get; set; }
public LMS_SurveyQuestionsViewModel SurveyQuestionsViewModel { get; set; }
public LMS_SurveyQuestionOptionChoiceViewModel SurveyQuestionOptionChoiceViewModel { get; set; }
}
Код: Выделить всё
public List GetTraineeSurvey(int surveyID)
{
try
{
List modelList = new List();
modelList = dbcontext.Set().FromSql("LMSSP_GetTraineeSurvey @surveyID = {0},@LanguageID = {1}", surveyID, AppTenant.SelectedLanguageID).ToList();
return modelList;
}
catch (Exception ex)
{
throw ex;
}
}
Подробнее здесь: https://stackoverflow.com/questions/417 ... n-net-core
Мобильная версия