Skip to content

Commit

Permalink
Merge pull request #81 from TeamWeathy/feature/#80/append-climateicon…
Browse files Browse the repository at this point in the history
…id-to-calendaroverview

#80 Appended field climateIconId to CalendarOverview.
  • Loading branch information
dshyun0226 authored Feb 26, 2021
2 parents 0b66411 + 3e42759 commit 193dbe8
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion WeathyServer/services/calendarService.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,12 @@ module.exports = {
include: [
{
model: DailyWeather,
attributes: ['date', 'temperature_max', 'temperature_min'],
attributes: [
'date',
'temperature_max',
'temperature_min',
'climate_id'
],
where: {
date: {
[Op.and]: {
Expand All @@ -31,6 +36,7 @@ module.exports = {
validCalendarOverviewList.push({
id: weathy.id,
date: weathy.DailyWeather.date,
climateIconId: weathy.DailyWeather.climate_id,
stampId: weathy.emoji_id,
temperature: {
maxTemp: weathy.DailyWeather.temperature_max,
Expand Down

0 comments on commit 193dbe8

Please sign in to comment.