public GetGPSendingQM GetGPSendingMasterAndDetails() { var model = new GetGPSendingQM(); using (var connection = new DbConnectionProvider().CreateConnection()) { connection.Open(); var command = new GPSendingMasterAndDetailsSelectCommand { Connection = connection }; model = command.Execute(); } return(model); }
public GetGPSendingQM Execute() { var response = new GetGPSendingQM(); using (var sqlCommand = CreateCommand()) { sqlCommand.Connection = Connection; sqlCommand.CommandText = "[dbo].[uspGetGPSendingMasterAndDetails]"; sqlCommand.CommandType = CommandType.StoredProcedure; using (var reader = SsDbCommandHelper.ExecuteReader(sqlCommand)) { response.getGPSendingModel = reader.ToList <GetGPSendingModel>(); } } return(response); }