-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* update weather.cs * updated README * added some updates to html and path * updated output, html, added functions * added image * updatet readme * changed button * Feature branch2 (#4) * edit1 * setting up style css * arraning items in css * last changes for the day * links in readme * readme edit * aligning text --------- Co-authored-by: bax082024 <bax082024@gmail.com>
- Loading branch information
Showing
9 changed files
with
156 additions
and
166 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,23 @@ | ||
using System.Collections.Generic; | ||
using System.Text.Json.Serialization; | ||
|
||
// This class represents the weather data returned by the Open-Meteo API | ||
public class WeatherData | ||
{ | ||
[JsonPropertyName("current_weather")] | ||
public CurrentWeatherData CurrentWeather { get; set;} | ||
[JsonPropertyName("hourly")] | ||
public HourlyData Hourly { get; set; } | ||
} | ||
// we dont use all the functions | ||
public class CurrentWeatherData | ||
{ | ||
[JsonPropertyName("temperature")] | ||
public float Temperature { get; set; } | ||
|
||
[JsonPropertyName("windspeed")] | ||
public float Windspeed { get; set; } | ||
public class HourlyData | ||
{ | ||
[JsonPropertyName("temperature_2m")] | ||
public List<float> Temperature2M { get; set; } | ||
|
||
[JsonPropertyName("weathercode")] | ||
public int WeatherCode { get; set; } | ||
[JsonPropertyName("wind_speed_10m")] | ||
public List<float> WindSpeed10M { get; set; } | ||
|
||
[JsonPropertyName("winddirection")] | ||
public int WindDirection { get; set; } | ||
[JsonPropertyName("weather_code")] | ||
public List<int> WeatherCode { get; set; } | ||
|
||
[JsonPropertyName("is_day")] | ||
public int IsDay { get; set; } | ||
// Add other fields like precipitation, rain, etc. if needed | ||
} | ||
|
File renamed without changes.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,23 @@ | ||
# Weather App for Bergen | ||
|
||
|
||
|
||
## Introduction | ||
- This is school project me and Amalie made together. | ||
- we made a weather app to show the weather in our city | ||
|
||
|
||
- This is school project Bax and Amalie made together. | ||
- We made a weather app to show the weather in our city | ||
|
||
### How to use | ||
### How to use | ||
|
||
**Run the app** | ||
|
||
- dotnet run | ||
|
||
**Use the app** | ||
|
||
- http://localhost:5000 | ||
- http://localhost:5000/api/weather | ||
|
||
**Navigate to files** | ||
|
||
|
||
|
||
|
||
A small app for looking up the weather in Bergen, NO. | ||
|
||
-[HTML](/wwwroot/index.html) | ||
|
||
|
||
|[HTML](/wwwroot/index.html)|[CSS](/wwwroot/styles.css)|[Figma](documentation/Figma-design.pdf) | ||
|[Program.cs](/Program.cs)|[WheatherData.cs](/classes/WeatherData.cs) | ||
|[WeatherController.cs](/Controller/WeatherController.cs)|[WheatherService.cs](/Services/WeatherService.cs) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.