Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature 683: Fixed server status check and made login async #686

Merged
merged 12 commits into from Nov 25, 2020

Conversation

AdrianPlesner
Copy link
Contributor

Closes #683
The check server status method did not request the correct api-endpoint, always resulting in 404 route not found. While fixing this, we also discovered that the login was completely backwards and not actually async. This, being related to the issue, has been fixed as well.

@codecov
Copy link

codecov bot commented Nov 24, 2020

Codecov Report

Merging #686 (11beded) into develop (b0758a6) will decrease coverage by 0.2%.
The diff coverage is 28.5%.

@@            Coverage Diff            @@
##           develop    #686     +/-   ##
=========================================
- Coverage     86.3%   86.0%   -0.3%     
=========================================
  Files           76      76             
  Lines         3565    3584     +19     
=========================================
+ Hits          3078    3085      +7     
- Misses         487     499     +12     
Impacted Files Coverage Δ
lib/blocs/auth_bloc.dart 32.6% <22.2%> (-13.2%) ⬇️
lib/screens/login_screen.dart 73.5% <36.3%> (+6.8%) ⬆️

@Determinatoro
Copy link
Contributor

Determinatoro commented Nov 24, 2020

Please use the following checklist, @JeppeKLau. Feel free to check it off as you go along.

Assets

  • The environments.json file has the following default values:
{
  "SERVER_HOST": "https://srv.giraf.cs.aau.dk/DEV/API",
  "DEBUG": true,
  "USERNAME": "Graatand",
  "PASSWORD": "password"
}

Code Design

  • The code is in the right place? (Both in terms of folder structure and class structure)
  • The code is not over-engineered. Examples of over-engineering: Implemented behavior for future problems
  • This code could not, to the best of my knowledge, have reused existing code
  • The code does not introduce functionality that is unnecessary for solving the problem

Code Readability

  • Names are meaningful and self-documenting
  • It is understandable, by reading the code, what it does
  • The code is simple and readable. i.e. it contains no "hack", or obscure solution

Code Maintainability

  • Has all the added code been properly commented

Only check one of the items below:

  • The functionality does not need to be covered by tests
  • The functionality needs to be covered by tests

Only check these if the functionality needs to be covered by tests:

  • All functionality is covered by tests
  • The tests has sensible names
  • By reading the tests you know what they cover
  • The tests cover sensible cases. Both happy paths and exception paths
  • The tests cover the full functionality. i.e., The tests fails if some of the requested functionality is missing

Functionality

For this part, open the app, and test:

  • The features that the code claims to implement, are actually implemented
  • The code does not look like it has bugs
  • All the new screens are reachable through in-app navigation

@Determinatoro
Copy link
Contributor

Determinatoro commented Nov 24, 2020

Please use the following checklist, @Riasalit. Feel free to check it off as you go along.

Assets

  • The environments.json file has the following default values:
{
  "SERVER_HOST": "https://srv.giraf.cs.aau.dk/DEV/API",
  "DEBUG": true,
  "USERNAME": "Graatand",
  "PASSWORD": "password"
}

Code Design

  • The code is in the right place? (Both in terms of folder structure and class structure)
  • The code is not over-engineered. Examples of over-engineering: Implemented behavior for future problems
  • This code could not, to the best of my knowledge, have reused existing code
  • The code does not introduce functionality that is unnecessary for solving the problem

Code Readability

  • Names are meaningful and self-documenting
  • It is understandable, by reading the code, what it does
  • The code is simple and readable. i.e. it contains no "hack", or obscure solution

Code Maintainability

  • Has all the added code been properly commented

Only check one of the items below:

  • The functionality does not need to be covered by tests
  • The functionality needs to be covered by tests

Only check these if the functionality needs to be covered by tests:

  • All functionality is covered by tests
  • The tests has sensible names
  • By reading the tests you know what they cover
  • The tests cover sensible cases. Both happy paths and exception paths
  • The tests cover the full functionality. i.e., The tests fails if some of the requested functionality is missing

Functionality

For this part, open the app, and test:

  • The features that the code claims to implement, are actually implemented
  • The code does not look like it has bugs
  • All the new screens are reachable through in-app navigation

Copy link
Contributor

@Riasalit Riasalit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image

Altså ved ikke om det her skyldes den her branch... men kan ikke logge ind

lib/blocs/auth_bloc.dart Outdated Show resolved Hide resolved
@AdrianPlesner
Copy link
Contributor Author

@Riasalit Jeg har brug for at se mere af loggen fra dit api for at kunne identificere hvad der er galt, men mit bud er at det nok har noget at gøre med den kombination af web-api og api_client du bruger. Det er testet og virker med den nyeste version af develop af begge.

@AdrianPlesner
Copy link
Contributor Author

AdrianPlesner commented Nov 24, 2020

Account controller I web-api er fornyligt ændret fra v1 til v2 så hvis man ikke får opdateret både web-api og api_client kan man ikke logge ind da end-points så ikke passer sammen.

Copy link
Contributor

@JeppeKLau JeppeKLau left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Error handling er en stor mangel.

Udover kommentarene, kunne jeg forestille mig der var smartere måder at tjekke om vi har forbindelse til internettet, end blot at pinge Googles url. Ved godt det ikke er direkte relateret til issuet, men jeg vil nu stadig gerne se det ændret.

Umiddelbart vil jeg også sige at jeg ikke har hørt om den der Completer som bliver brugt. Kunne forestille mig at samme funktionalitet kan opnås ved bare at have nogle gode asynkrone funktioner, der bliver ventet på de rigtige steder.

Se også manglende punkter på checklisten.

Comment on lines 54 to 56
}).onError((Object error){
completer.complete();
});
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Umiddelbart vil jeg mene at det ikke er smart bare at gennemtvinge en færdiggørelse ved en fejl.

lib/blocs/auth_bloc.dart Show resolved Hide resolved
Comment on lines 263 to 265
final String loginUrl = environment.getVar<String>('SERVER_HOST');
final String loginUrl = environment.getVar<String>('SERVER_HOST') + '/v1/Status';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Jeg kan forestille mig at man kan tilgå statusen på en anden måde, fx. gennem api klienten. Ellers burde det tilføjes.

Udover dette, giver navnet på variablen ikke mening da det ikke er på det endpoint vi logger ind.

@Riasalit
Copy link
Contributor

Soooo flutter simply refuses to get the latest version of the api-client

@AdrianPlesner
Copy link
Contributor Author

Soooo flutter simply refuses to get the latest version of the api-client

Yup det virker til at være problemet

@Riasalit
Copy link
Contributor

image

We in bois.
"flutter packages upgrade" og så slet den forkerte cachede versio...... igen igen... virkede

@JeppeKLau
Copy link
Contributor

Soooo flutter simply refuses to get the latest version of the api-client

Jeg fik det til at virke ved at fjerne api_client fra pubspec.yaml, køre flutter pub get, tilføje den tilbage i pubspec.yaml og køre flutter pub get igen - ser ud til at pubspec.lock har en forkert resolved-ref for api_client

@AdrianPlesner
Copy link
Contributor Author

Soooo flutter simply refuses to get the latest version of the api-client

Jeg fik det til at virke ved at fjerne api_client fra pubspec.yaml, køre flutter pub get, tilføje den tilbage i pubspec.yaml og køre flutter pub get igen - ser ud til at pubspec.lock har en forkert resolved-ref for api_client

Jeg bruger samme methode

@Riasalit
Copy link
Contributor

Soooo flutter simply refuses to get the latest version of the api-client

Jeg fik det til at virke ved at fjerne api_client fra pubspec.yaml, køre flutter pub get, tilføje den tilbage i pubspec.yaml og køre flutter pub get igen - ser ud til at pubspec.lock har en forkert resolved-ref for api_client

Jeg bruger samme methode

prøvede det. men det gjorde intet for mig

Riasalit
Riasalit previously approved these changes Nov 25, 2020
Copy link
Contributor

@Riasalit Riasalit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CI actions failer

Copy link
Contributor

@Riasalit Riasalit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Vil gerne have at der står hvad funktionen gør

@AdrianPlesner AdrianPlesner marked this pull request as ready for review November 25, 2020 10:27
@AdrianPlesner
Copy link
Contributor Author

Vil gerne have at der står hvad funktionen gør

Ups. 😄

Riasalit
Riasalit previously approved these changes Nov 25, 2020
Copy link
Contributor

@JeppeKLau JeppeKLau left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Se kommentarer :)

Comment on lines 66 to 69
checkInternetConnection().then((bool hasInternetConnection) {
if (hasInternetConnection) {
// Checking server connection, if true check username/password
checkServerConnection().then((bool hasServerConnection) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Jeg tænker at hvis man får en SocketException, så må der være noget galt med enten internet forbindelsen eller forbindelsen til serveren. Så jeg tænker det måske er fint nok bare at kontrollere forbindelsen til serveren, da det ikke er nødvendigt at tjekke forbindelsen til internettet hvis man alligevel får en SocketException.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Det sørger jo bare for at håndtere fejl vi ikke regner med at der kommer. Det er bare for en sikkerheds skyld. Jeg tænker heller ikke at der kan være andet end manglede forbindelse til enten server eller internet, men man kan vel ikke være helt sikker. 🤷

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Det er bare et spildt tjek. Desuden, som jeg også sagde før, er det virkelig ikke smart at tjekke om man har internet ved at pinge Google. Der er ikke noget der siger at deres service ikke kunne ske at gå ned på et tidpunkt i fremtiden.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Det er da en meget standard måde at gøre det på, og så er det cross platform.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Der er det her plugin som jeg kan se ville kunne short circuit at tjekke om man har internet, inden man begynder på at pinge rundt på nettet.
Dertil vil jeg så nævne at der også findes det her plugin der automatisk pinger en række af hjemmesider og ikke blot en enkelt som vi gør her. Det giver en mindre chance for fejl da de alle skal misse før der konkluderes at man ingen forbindelse har.

De to plugins i sammenhæng kunne jeg se gav en god sikkerhed for at tjekke om man har internet eller ej.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oki doki så, hvis du insisterer.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Vi kan ikke bruge connectivity pakken, den giver build errors på android, jeg håber du kan nøjes med den anden.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Det må være nok så - tænkte bare der måske var et eller andet indbygget, men det her må være nok

Comment on lines 36 to 37
@override
void showNotifyDialog() {
// Checking username/password
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Når du har fjernet funktionen i koden, ser jeg ingen grund til at bringe funktionen tilbage til testen. Hvis testen er afhængig af funktionen, må testen skrives om så den ikke er afhængig af funktionen.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

lib/blocs/auth_bloc.dart Outdated Show resolved Hide resolved
Copy link
Contributor

@JeppeKLau JeppeKLau left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Vi er der næsten Adrian. Vil tilføje at det er dejligt at se du har rykket business logic om i BLOCen frem for at have det i screenen

Comment on lines 84 to 86
completer.completeError(error);
completer.complete(false);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Var det ikke den der skulle give en error tilbage når der skete en fejl?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Joh, men det er egentligt nok at håndter fejler her. At smide fejler videre giver bare endnu et unødvendigt led med onError -> createErrorDialog, og i sidste ende giver det samme resultat

Comment on lines +110 to +114
/// Create an unknown error dialog
void unknownErrorDialog(String key){
creatingNotifyDialog('Der skete en ukendt fejl, prøv igen eller '
'kontakt en administrator', 'key');
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Jeg kan godt se ideen, men virker bare lidt fjollet når den kun bruges tre gange, hvor man bare kunne indsætte creatingNotifyDialog med den passende key

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Jah, jeg synes 3 gange var for meget

@LivHolm LivHolm merged commit b7d66d4 into develop Nov 25, 2020
@LivHolm LivHolm deleted the feature/683 branch November 25, 2020 14:18
Determinatoro added a commit that referenced this pull request Dec 4, 2020
* Update package link (#554)

This organization has been renamed, and so the name is up for grabs. Currently, it still works because Github redirects to the renamed organization page, but if the old name is registered, the redirection will stop, and thus many tests will break. This update will ensure that the link won't break.

* Feature/562 Updates to unit tests (#564)

* Updated unit tests

* Update weekplans_bloc_test.dart

* FIxes for linter

* Feature 531: Pictogram title text no longer in all caps (#558)

* Pictogram text is no longer all caps

The first letter under every pictogram will now be upper case, while the rest will be lower case.

* Tests now work for pictogram test

Tests have been adjusted to correctly reflect the new changes and have been tested, so they fail when expected and succeed when expected.

* Fixed too long lines

Co-authored-by: Adrian Plesner <adrian.plesner@gmail.com>

* Feature/434 (#567)

* Update .gitignore

* Feature/434

* develop to feature/434 (#566)

* Update package link (#554)

This organization has been renamed, and so the name is up for grabs. Currently, it still works because Github redirects to the renamed organization page, but if the old name is registered, the redirection will stop, and thus many tests will break. This update will ensure that the link won't break.

* Feature/562 Updates to unit tests (#564)

* Updated unit tests

* Update weekplans_bloc_test.dart

* FIxes for linter

Co-authored-by: Bogi Napoleon Wennerstrøm <bogi.wennerstrom@gmail.com>
Co-authored-by: Jakob Precht <sporvogn@live.com>

* Update .gitignore

Co-authored-by: Mustafa Al-Dailemi <Mustafa-ALD@users.noreply.github.com>
Co-authored-by: Bogi Napoleon Wennerstrøm <bogi.wennerstrom@gmail.com>
Co-authored-by: Jakob Precht <sporvogn@live.com>

* feature #471: Created error messages for already existing users (#561)

* Created error messages for already existing users

created an error handler in new_citizen_screen.dart to handle errors from the client_api

* Added documentation for the exception handler

* Update new_citizen_screen.dart

removed dependency on a illagal variable, which which made the class not imutable

* Update new_citizen_screen.dart

fixed linting

* Fixed issue 304 in weekplaner. Edited handleOnTapWeekPlanAdd in weekplan_selector_screen.dart (#560)

Co-authored-by: Riasalit <daniel-vilslev@hotmail.com>

* Feature 485: Created a new errorColor variable  (#557)

* made a errorColor variable with the standard error color for dart and used for a incorrectly colored text field

* Update routes.dart

Undid change to route

* Feature 527: Opacity changed to 40% on disabled buttons (#556)

* Opacity changed to 40% on disabled buttons

In the file lib/style/custom_color.dart the opacity for the disabled button has been changed from 65%(A6) to 40%(66), and the border has been changed from 100% opacity (FF) to 40% (66). The gradient has also been changed from 27% (46) to 40% (66).

* Update custom_color.dart

Co-authored-by: Adrian Plesner <adrian.plesner@gmail.com>

* Release 2020 S0 R1 (#578)

* Releasefix 570: Created class for converting Error codes to Danish messages (#574)

* Created class for converting Error codes to Danish messages

The class can be expanded with more of the error codes from the ErrorKey class such that it can be used with all comunication with the api_client

* added unit tests for creating new citizens

Also moved the error handling to the error code translater class for easier use when it needs to be implemented in more classes

* Added comments for some helper functions in the Widget tests

* Removed unused imports

* en test mere til at gøre code coverage glad

Den case burde den aldrig komme ind i normalvis, men nu er testen der i guess

* Removed another unused package

why linter no tell though?

* Releasefix 573: Username validation expanded in new_citizen_bloc.dart (#575)

* Username validation expanded in new_citizen_bloc.dart

Pull Request for #573
The _usernamevalidation method has been revised from blacklisting spaces only to a whitelist regex that contains only all letters, ÆØÅ, numbers, underscore( _ ) or a hyphen ( - )

The warning message under the text field has been updated to explain this change.

A test has been added to verify this feature in new_citizen_bloc_test.dart.

* Update new_citizen_screen.dart

missing letter in "tom"

Co-authored-by: Riasalit <daniel-vilslev@hotmail.com>
Co-authored-by: ProgDaniel <43956461+ProgDaniel@users.noreply.github.com>

* Update issue templates (#581)

Added "not prioritised" as default label

* Feature 535: Buggy "Fortryd" button on activity (#585)

* Updates local ActivityModel instance after changing state normal/cancelled

* Immutable fix

* Added a test

Added a test with when the activity is cancelled, then uncancelled and a timer is added.

Co-authored-by: Adrian Plesner <adrian.plesner@gmail.com>

* Feature 580: Newly added citizens appear in the choose citizen list immediately  (#590)

* Fixed import

* Fixed import

* Nu virker det endelig

* Make pretty and write comments

* Fix linting issues

* Fix linting issues 2!

Co-authored-by: OliverSorensen <Ossa18@student.aau.dk>

* Refactoring of font sizes (#599)

* Refactoring of font sizes

Font sizes now have a document where they are defined. There was used a font size of 25 twice in upload_image_from_phone_screen which has been set to 24 so it's the same as the other places. Likewise the font size was set to 18 in weekplan_selector_screen and it's been set to 20 as in line with the rest of the app.

* Update font_size.dart

* Update weekplan_selector_screen.dart

* Update font_size.dart

* Feature/474: With a lot of activities on a single weekplan, a activity sometime jump back to the bottom when moved (#598)

* Changed activity order

* Changed activity order

Co-authored-by: Rikke Husted Østergaard <raster16@student.aau.dk>

* Feature 273: Users can delete pictograms they have created (#606)

* Can I push?

* Working tests

* delete function in pictogram block

* Delete button

* Delete button and dialog box

* Added delete button to pictograms

Delete buttons are only active on the users own pictograms

* Update pubspec

* Insert user in PictogramSearch

* Added Directionality to the stack Widget

* Insert user in PictogramSearch
Fix tests

* Fix linting issues

* Removed unnecessary comment

* Removed test segment

Co-authored-by: twaxlol <folese18@student.aau.dk>

* Revert "Feature 273: Users can delete pictograms they have created (#606)" (#611)

This reverts commit f8b6a1b.

* Feature/529: Guardians should be able to mark activities as complete like the citizens can (#602)

* Another button

* Complete activity button is rendered in guardian mode

* Removed containers and added proper padding

* Feature 514: Popped the context for the activity icon setting options. (#582)

* Popped the context for the activity icon setting options.

* Fixed import

* Create completed_activity_icon_selection_screen_test.dart

* Update completed_activity_icon_selection_screen_test.dart

* Refactor how completed activity setting is saved

* Fixed completed_activity_icon_selection_screen_test.dart test

* Fixed linting issues

* Update workflow flutter version

* Fix linting issues

* Refactor how settings are saved

* Test settings screens are popped

Co-authored-by: oliver <ossa18@student.aau.dk>
Co-authored-by: twaxlol <folese18@student.aau.dk>
Co-authored-by: twaxlol <45589745+twaxlol@users.noreply.github.com>

* Feature 499: Refactor to not use observable (#609)

* Observable is a bitch

* Observable is a bitch

* Fixed tests. No longer uses unmodifyable lists

* Fix linting issues !

* Force ImagePicker dependency to be lower than 0.6.7 as these versions deprecates a used function and the suggested solution does not work.

* Update github action flutter version

* Use develop branch of api_client

Co-authored-by: OliverSorensen <Ossa18@student.aau.dk>

* Feature 273: User are able to delete pictograms they have created (#621)

* Can I push?

* Working tests

* delete function in pictogram block

* Delete button

* Delete button and dialog box

* Added delete button to pictograms

Delete buttons are only active on the users own pictograms

* Update pubspec

* Insert user in PictogramSearch

* Added Directionality to the stack Widget

* Insert user in PictogramSearch
Fix tests

* Fix linting issues

* Removed unnecessary comment

* Removed test segment

* Fix so pictogram delete button does not show up on pictogram field when making a new weekplan

* Delete button only show up on pictograms the current user has access to.
If delete should fail, a notify popup with an errormessage is shown.
Tests are added.

* Revert "Merge branch 'develop' into feature/273"

This reverts commit 9f933ec, reversing
changes made to 5424442.

* Revert "Revert "Merge branch 'develop' into feature/273""

This reverts commit f9122e1

* Fix Observable merge

* Fix error with fixed image size

Co-authored-by: twaxlol <folese18@student.aau.dk>
Co-authored-by: Mustafa Al-Dailemi <43955099+Mustafa-ALD@users.noreply.github.com>
Co-authored-by: Mustafa Al-Dailemi <Mustafa-ALD@users.noreply.github.com>

* Changed background color of timer to white, when finished (#594)

Co-authored-by: OliverSorensen <Ossa18@student.aau.dk>

* Feature 563: Activity screen buttons (Timer & Choiceboard) buttons now boxes instead of icons. (#596)

* Choiceboard card is now button + early testing of timer card button

The card containing "Tilføj ChoiceBoard" is now the button itself, rather than the plus icon below it

The Timer button is in testing to implement the same functionality as the ChoiceBoard button.

* Final iteration of activity screen buttons

The timer button on the activity screen will now properly "disable" (by making the highlight- and splashcolors invisible when tapped.)

* Reverted mistaken commit

* Update font value to default in _develop branch

* Compatability with #273 and linter fix

This commit adds a missing user parameter in the changed PictogramSearch method, as well as fixes a linting issue that clashed with GitHub Actions

* Feature 495: Changed pictogram box changes (#559)

* Changed pictogram box changes

The Issue was that some text was cut off when it spanned multiple lines, as the box size was static. this has been solved by allowing the pictogram box to be as high as the elements within and set the max amount of lines for the text to 2.

this made smaller words split into 2 lines, which was further solved by only allowing the text to be 1 line of only 1 word was present in the string.

* Update pictogram_text.dart

Now sets textlines to 2 if a word cant fit on one line

* Minimum Android APK changed from 16 (Jelly Bean) to 23 (Marshmallow) (#647)

minSdkVersion has been increased from 16 to 23, primarily to prevent a library warning with text relocations.

This is also due to Jelly Bean no longer being supported and is far too outdated to be worth.

* Feature/418 As a guardian i would like to be able to search for a specific weekplan so it is easier for me to find (#593)

* intermediate push

* more difficult than expected

* bump

* Someone take over please

* Functionality done - trying to fix a minor issue

* Fixed the minor issue

* Hotfix

* Dirty hotfix

* bump

* moar fixes

* All done

* bump

* Release prep

Tried fixing pubspec.lock - unsure why it changed.
Set the sdk version to be 2.1 as the develop branch.
Removed flutter_bloc depedency - again, not sure why it was added
Changed the SERVER_HOST to be the live server.

* Update pubspec.lock

* Update pubspec.lock

* Streams are dumb

* Ready to ship

Fixed issue with user not having any old week plans.
Changed the name of the `WeekPlansBloc` to `WeekPlanSelectorBloc` for better readability.
Fixed test.
Removed `Observable` class.
Updated SDK to 2.2.0 for set literals support.
Minor changes in a bunch of places from the name change of `WeekplanSelectorBloc`.

Co-Authored-By: Alexander <31063192+ggAlexS@users.noreply.github.com>

* Update environments.json

* Removed comments

Co-Authored-By: Alexander <31063192+ggAlexS@users.noreply.github.com>

* Trying to fix CI errors

Undid chages to pubspec.lock
Fixed linting isssues in various files: added const keywords and changed a deprecated function.

* Take 2

CI is using old versions - this should be fixed at some point.

* Update pubspec.lock

* Merge branch 'develop' into feature/418

Co-Authored-By: Alexander <31063192+ggAlexS@users.noreply.github.com>

* Update copy_resolve_screen_test.dart

Co-Authored-By: Alexander <31063192+ggAlexS@users.noreply.github.com>

Co-authored-by: Jeppe Krogh Laursen <jeppe.k.l.97@gmail.com>
Co-authored-by: JeppeKLau <44167691+JeppeKLau@users.noreply.github.com>

* Loading the first pictogram in the activity bloc (#650)

* Revert "Feature/418 As a guardian i would like to be able to search for a specific weekplan so it is easier for me to find (#593)" (#657)

This reverts commit d045b80.

* Feature 615: citizens can now open completed activities  (#651)

* Removed !

* Update weekplan_day_column.dart

* Reverted some changes

Co-authored-by: twaxlol <folese18@student.aau.dk>
Co-authored-by: OliverSorensen <Ossa18@student.aau.dk>

* Fixed unit test errors (#661)

Fixed errors in copy_resolve_screen_test.dart
Fixed errors in show_activity_screen_test.dart
Fixed errors in weekplan_selector_screen_test.dart

* Feature/592: "Overståede Uger" includes current week (#663)

* Added some tests and beginning to design the algorithm

* It should work now, next is thorough testing

* Tested, and fixed edge cases

* Fixed linting stuff

* Long line in a comment

* Because GitHub CI couldn't find the file

* Because CI is still stupid

* Create Dates_with_weeks_2020_to_2030_semi.csv

* Mac os problem fixed

* stupid linting... again

Co-authored-by: Alexander Nykjær <alax0013@gmail.com>
Co-authored-by: Michelle Terpling <michelle@terpling.dk>

* Feature/595 Used MediaQuery to adjust the layout for all screens (upload_image_from_phone) (#655)

* made the

* Text and image overlflow fixed and code optimisation

Added MediaQuery to manage changes such as rotationg the screen and replaced the column with a widget that returns a container. This works for both tablet and mobile phone device

* minor

* Issue 595 clean code fix

beautifying and small changes

* Revert changes to gitignore, evviroment jason and pubspec

This reverts commit 4d5999e.

Co-authored-by: ChristofferAaen <cbaaen@live.dk>

* Feature/429.5 (#654)

* Fixed delay on erroneous login

* Merge develop into feature/429.5 (#653)

* Feature 495: Changed pictogram box changes (#559)

* Changed pictogram box changes

The Issue was that some text was cut off when it spanned multiple lines, as the box size was static. this has been solved by allowing the pictogram box to be as high as the elements within and set the max amount of lines for the text to 2.

this made smaller words split into 2 lines, which was further solved by only allowing the text to be 1 line of only 1 word was present in the string.

* Update pictogram_text.dart

Now sets textlines to 2 if a word cant fit on one line

* Minimum Android APK changed from 16 (Jelly Bean) to 23 (Marshmallow) (#647)

minSdkVersion has been increased from 16 to 23, primarily to prevent a library warning with text relocations.

This is also due to Jelly Bean no longer being supported and is far too outdated to be worth.

Co-authored-by: Riasalit <daniel-vilslev@hotmail.com>
Co-authored-by: ProgDaniel <43956461+ProgDaniel@users.noreply.github.com>

Co-authored-by: Mustafa Al-Dailemi <43955099+Mustafa-ALD@users.noreply.github.com>
Co-authored-by: Riasalit <daniel-vilslev@hotmail.com>
Co-authored-by: ProgDaniel <43956461+ProgDaniel@users.noreply.github.com>

* Feature 538: No lingering weekplans when editing (#656)

* Reverted some changes

* Maybe not hacky

* Mere await

* Mere await

* Fix add new weekplan was counted

Co-authored-by: OliverSorensen <Ossa18@student.aau.dk>

* Feature/371 (#664)

* not done yet

needs more

* small change

* unit test + flutter test

not done yet

* Flutter test of undo button (genoptag knap)

* Revert "small change"

This reverts commit aeb448f.

* Update weekplan_bloc.dart

Co-authored-by: myname <email@email.email>

* Weekplanner 668: Inconsistency in settings menu for citizens (#682)

* Fixed the issue

Added a null check. Also fixed some issues that had arisen due to conflicting pushes in earlier sprints, so the code is consistent.

* Linter

* Linter

* Linter

* Feature/540: Collapse "overståede uger" (#665)

* Update weekplan_selector_screen.dart

* Fixed button position

Also added a key for testing

* Incomplete test

* Test implemented

Test has been implemented and naming convention fix.

* Linter

* Fixed

* Update weekplan_selector_screen.dart

Co-authored-by: JohanKrogh <johan.krogh@gmail.com>

* Feature 683: Fixed server status check and made login async (#686)

* WIP: Make login actually async

* Fixed tests and status endpoint

* Login from popup async too

* Handle error right

* More correct error handling

* Check server status through api_client

* One comment

* Remove unnecessary method from test

* Specify types on wait

* Be completely sure about internet connection :)

* Remove library due to build errors

* oops

* Feature/592.5 (#685)

* Skipped a test instead of commenting it out

* Cleaned up the code, and fixed a small issue

The issue was that it made the calculations from a specific time of day, not at 00:00

* Linting

* Just a small rename

* Small speed up for December

* Split the current week algorithm into different methods, and cleaned up

* Linting

* Final refactor to something the we can actually explain to someone else

Removed unneeded tests

* Moved a method

* Moved a statement

* Removed unnecessary complication

* feature/696: Inconsistent buttons (#701)

* Inconsistent buttons

Only partly solved the issue.
The buttons now correctly remove the timer and add choiceboard options when marking an activity as completed as well as cancelled. Furthermore an isEnabled has been added to the cancel button, so it becomes disables when the state is completed.
The buttons however only become disabled, when you reenter the activity. This is due to the fact the other button does not check for a new state, when the first button is pressed and as such does not get the new state information, when an acitivty is completed or cancelled. There is not enough time to fix this before release, and as such only the most system breaking part of the bug has been fixed, as it would do some funky things, when trying to make a choiceboard on a completed activity.

* Update show_activity_screen.dart

Fixed missing Add Choiceboard on new activities

* Changed values for release (#706)

Co-authored-by: Frederik Spang <fthoms16@student.aau.dk>
Co-authored-by: Frederik Spang <frederik@progras.dk>
Co-authored-by: Bogi Napoleon Wennerstrøm <bogi.wennerstrom@gmail.com>
Co-authored-by: Rikke Husted Østergaard <raster16@student.aau.dk>
Co-authored-by: Adrian Plesner <adrian.plesner@gmail.com>
Co-authored-by: Mustafa Al-Dailemi <43955099+Mustafa-ALD@users.noreply.github.com>
Co-authored-by: Mustafa Al-Dailemi <Mustafa-ALD@users.noreply.github.com>
Co-authored-by: Riasalit <daniel-vilslev@hotmail.com>
Co-authored-by: Mostaan H <34608699+smh87@users.noreply.github.com>
Co-authored-by: Kristian Benny Winther Sørensen <43601483+kbwsoorensen@users.noreply.github.com>
Co-authored-by: ProgDaniel <43956461+ProgDaniel@users.noreply.github.com>
Co-authored-by: Ane Søgaard Jørgensen <42242841+Kaliahh@users.noreply.github.com>
Co-authored-by: AdrianPlesner <33195961+AdrianPlesner@users.noreply.github.com>
Co-authored-by: OliverSorensen <Ossa18@student.aau.dk>
Co-authored-by: LJensen0403 <44022936+LJensen0403@users.noreply.github.com>
Co-authored-by: twaxlol <folese18@student.aau.dk>
Co-authored-by: Liv Holm <43985985+LivHolm@users.noreply.github.com>
Co-authored-by: twaxlol <45589745+twaxlol@users.noreply.github.com>
Co-authored-by: Alexander <31063192+ggAlexS@users.noreply.github.com>
Co-authored-by: Jeppe Krogh Laursen <jeppe.k.l.97@gmail.com>
Co-authored-by: JeppeKLau <44167691+JeppeKLau@users.noreply.github.com>
Co-authored-by: JohanKrogh <johan.krogh1@gmail.com>
Co-authored-by: Alexander Nykjær <alax0013@gmail.com>
Co-authored-by: Michelle Terpling <michelle@terpling.dk>
Co-authored-by: ZohraAmini <amini.zohra.za@gmail.com>
Co-authored-by: ChristofferAaen <cbaaen@live.dk>
Co-authored-by: Emil7370 <43956069+Emil7370@users.noreply.github.com>
Co-authored-by: myname <email@email.email>
Co-authored-by: JohanKrogh <johan.krogh@gmail.com>
JakobFaarGreg pushed a commit that referenced this pull request Oct 12, 2021
* Release/2020es3r1 (#707)

* Update package link (#554)

This organization has been renamed, and so the name is up for grabs. Currently, it still works because Github redirects to the renamed organization page, but if the old name is registered, the redirection will stop, and thus many tests will break. This update will ensure that the link won't break.

* Feature/562 Updates to unit tests (#564)

* Updated unit tests

* Update weekplans_bloc_test.dart

* FIxes for linter

* Feature 531: Pictogram title text no longer in all caps (#558)

* Pictogram text is no longer all caps

The first letter under every pictogram will now be upper case, while the rest will be lower case.

* Tests now work for pictogram test

Tests have been adjusted to correctly reflect the new changes and have been tested, so they fail when expected and succeed when expected.

* Fixed too long lines

Co-authored-by: Adrian Plesner <adrian.plesner@gmail.com>

* Feature/434 (#567)

* Update .gitignore

* Feature/434

* develop to feature/434 (#566)

* Update package link (#554)

This organization has been renamed, and so the name is up for grabs. Currently, it still works because Github redirects to the renamed organization page, but if the old name is registered, the redirection will stop, and thus many tests will break. This update will ensure that the link won't break.

* Feature/562 Updates to unit tests (#564)

* Updated unit tests

* Update weekplans_bloc_test.dart

* FIxes for linter

Co-authored-by: Bogi Napoleon Wennerstrøm <bogi.wennerstrom@gmail.com>
Co-authored-by: Jakob Precht <sporvogn@live.com>

* Update .gitignore

Co-authored-by: Mustafa Al-Dailemi <Mustafa-ALD@users.noreply.github.com>
Co-authored-by: Bogi Napoleon Wennerstrøm <bogi.wennerstrom@gmail.com>
Co-authored-by: Jakob Precht <sporvogn@live.com>

* feature #471: Created error messages for already existing users (#561)

* Created error messages for already existing users

created an error handler in new_citizen_screen.dart to handle errors from the client_api

* Added documentation for the exception handler

* Update new_citizen_screen.dart

removed dependency on a illagal variable, which which made the class not imutable

* Update new_citizen_screen.dart

fixed linting

* Fixed issue 304 in weekplaner. Edited handleOnTapWeekPlanAdd in weekplan_selector_screen.dart (#560)

Co-authored-by: Riasalit <daniel-vilslev@hotmail.com>

* Feature 485: Created a new errorColor variable  (#557)

* made a errorColor variable with the standard error color for dart and used for a incorrectly colored text field

* Update routes.dart

Undid change to route

* Feature 527: Opacity changed to 40% on disabled buttons (#556)

* Opacity changed to 40% on disabled buttons

In the file lib/style/custom_color.dart the opacity for the disabled button has been changed from 65%(A6) to 40%(66), and the border has been changed from 100% opacity (FF) to 40% (66). The gradient has also been changed from 27% (46) to 40% (66).

* Update custom_color.dart

Co-authored-by: Adrian Plesner <adrian.plesner@gmail.com>

* Release 2020 S0 R1 (#578)

* Releasefix 570: Created class for converting Error codes to Danish messages (#574)

* Created class for converting Error codes to Danish messages

The class can be expanded with more of the error codes from the ErrorKey class such that it can be used with all comunication with the api_client

* added unit tests for creating new citizens

Also moved the error handling to the error code translater class for easier use when it needs to be implemented in more classes

* Added comments for some helper functions in the Widget tests

* Removed unused imports

* en test mere til at gøre code coverage glad

Den case burde den aldrig komme ind i normalvis, men nu er testen der i guess

* Removed another unused package

why linter no tell though?

* Releasefix 573: Username validation expanded in new_citizen_bloc.dart (#575)

* Username validation expanded in new_citizen_bloc.dart

Pull Request for #573
The _usernamevalidation method has been revised from blacklisting spaces only to a whitelist regex that contains only all letters, ÆØÅ, numbers, underscore( _ ) or a hyphen ( - )

The warning message under the text field has been updated to explain this change.

A test has been added to verify this feature in new_citizen_bloc_test.dart.

* Update new_citizen_screen.dart

missing letter in "tom"

Co-authored-by: Riasalit <daniel-vilslev@hotmail.com>
Co-authored-by: ProgDaniel <43956461+ProgDaniel@users.noreply.github.com>

* Update issue templates (#581)

Added "not prioritised" as default label

* Feature 535: Buggy "Fortryd" button on activity (#585)

* Updates local ActivityModel instance after changing state normal/cancelled

* Immutable fix

* Added a test

Added a test with when the activity is cancelled, then uncancelled and a timer is added.

Co-authored-by: Adrian Plesner <adrian.plesner@gmail.com>

* Feature 580: Newly added citizens appear in the choose citizen list immediately  (#590)

* Fixed import

* Fixed import

* Nu virker det endelig

* Make pretty and write comments

* Fix linting issues

* Fix linting issues 2!

Co-authored-by: OliverSorensen <Ossa18@student.aau.dk>

* Refactoring of font sizes (#599)

* Refactoring of font sizes

Font sizes now have a document where they are defined. There was used a font size of 25 twice in upload_image_from_phone_screen which has been set to 24 so it's the same as the other places. Likewise the font size was set to 18 in weekplan_selector_screen and it's been set to 20 as in line with the rest of the app.

* Update font_size.dart

* Update weekplan_selector_screen.dart

* Update font_size.dart

* Feature/474: With a lot of activities on a single weekplan, a activity sometime jump back to the bottom when moved (#598)

* Changed activity order

* Changed activity order

Co-authored-by: Rikke Husted Østergaard <raster16@student.aau.dk>

* Feature 273: Users can delete pictograms they have created (#606)

* Can I push?

* Working tests

* delete function in pictogram block

* Delete button

* Delete button and dialog box

* Added delete button to pictograms

Delete buttons are only active on the users own pictograms

* Update pubspec

* Insert user in PictogramSearch

* Added Directionality to the stack Widget

* Insert user in PictogramSearch
Fix tests

* Fix linting issues

* Removed unnecessary comment

* Removed test segment

Co-authored-by: twaxlol <folese18@student.aau.dk>

* Revert "Feature 273: Users can delete pictograms they have created (#606)" (#611)

This reverts commit f8b6a1b.

* Feature/529: Guardians should be able to mark activities as complete like the citizens can (#602)

* Another button

* Complete activity button is rendered in guardian mode

* Removed containers and added proper padding

* Feature 514: Popped the context for the activity icon setting options. (#582)

* Popped the context for the activity icon setting options.

* Fixed import

* Create completed_activity_icon_selection_screen_test.dart

* Update completed_activity_icon_selection_screen_test.dart

* Refactor how completed activity setting is saved

* Fixed completed_activity_icon_selection_screen_test.dart test

* Fixed linting issues

* Update workflow flutter version

* Fix linting issues

* Refactor how settings are saved

* Test settings screens are popped

Co-authored-by: oliver <ossa18@student.aau.dk>
Co-authored-by: twaxlol <folese18@student.aau.dk>
Co-authored-by: twaxlol <45589745+twaxlol@users.noreply.github.com>

* Feature 499: Refactor to not use observable (#609)

* Observable is a bitch

* Observable is a bitch

* Fixed tests. No longer uses unmodifyable lists

* Fix linting issues !

* Force ImagePicker dependency to be lower than 0.6.7 as these versions deprecates a used function and the suggested solution does not work.

* Update github action flutter version

* Use develop branch of api_client

Co-authored-by: OliverSorensen <Ossa18@student.aau.dk>

* Feature 273: User are able to delete pictograms they have created (#621)

* Can I push?

* Working tests

* delete function in pictogram block

* Delete button

* Delete button and dialog box

* Added delete button to pictograms

Delete buttons are only active on the users own pictograms

* Update pubspec

* Insert user in PictogramSearch

* Added Directionality to the stack Widget

* Insert user in PictogramSearch
Fix tests

* Fix linting issues

* Removed unnecessary comment

* Removed test segment

* Fix so pictogram delete button does not show up on pictogram field when making a new weekplan

* Delete button only show up on pictograms the current user has access to.
If delete should fail, a notify popup with an errormessage is shown.
Tests are added.

* Revert "Merge branch 'develop' into feature/273"

This reverts commit 9f933ec, reversing
changes made to 5424442.

* Revert "Revert "Merge branch 'develop' into feature/273""

This reverts commit f9122e1

* Fix Observable merge

* Fix error with fixed image size

Co-authored-by: twaxlol <folese18@student.aau.dk>
Co-authored-by: Mustafa Al-Dailemi <43955099+Mustafa-ALD@users.noreply.github.com>
Co-authored-by: Mustafa Al-Dailemi <Mustafa-ALD@users.noreply.github.com>

* Changed background color of timer to white, when finished (#594)

Co-authored-by: OliverSorensen <Ossa18@student.aau.dk>

* Feature 563: Activity screen buttons (Timer & Choiceboard) buttons now boxes instead of icons. (#596)

* Choiceboard card is now button + early testing of timer card button

The card containing "Tilføj ChoiceBoard" is now the button itself, rather than the plus icon below it

The Timer button is in testing to implement the same functionality as the ChoiceBoard button.

* Final iteration of activity screen buttons

The timer button on the activity screen will now properly "disable" (by making the highlight- and splashcolors invisible when tapped.)

* Reverted mistaken commit

* Update font value to default in _develop branch

* Compatability with #273 and linter fix

This commit adds a missing user parameter in the changed PictogramSearch method, as well as fixes a linting issue that clashed with GitHub Actions

* Feature 495: Changed pictogram box changes (#559)

* Changed pictogram box changes

The Issue was that some text was cut off when it spanned multiple lines, as the box size was static. this has been solved by allowing the pictogram box to be as high as the elements within and set the max amount of lines for the text to 2.

this made smaller words split into 2 lines, which was further solved by only allowing the text to be 1 line of only 1 word was present in the string.

* Update pictogram_text.dart

Now sets textlines to 2 if a word cant fit on one line

* Minimum Android APK changed from 16 (Jelly Bean) to 23 (Marshmallow) (#647)

minSdkVersion has been increased from 16 to 23, primarily to prevent a library warning with text relocations.

This is also due to Jelly Bean no longer being supported and is far too outdated to be worth.

* Feature/418 As a guardian i would like to be able to search for a specific weekplan so it is easier for me to find (#593)

* intermediate push

* more difficult than expected

* bump

* Someone take over please

* Functionality done - trying to fix a minor issue

* Fixed the minor issue

* Hotfix

* Dirty hotfix

* bump

* moar fixes

* All done

* bump

* Release prep

Tried fixing pubspec.lock - unsure why it changed.
Set the sdk version to be 2.1 as the develop branch.
Removed flutter_bloc depedency - again, not sure why it was added
Changed the SERVER_HOST to be the live server.

* Update pubspec.lock

* Update pubspec.lock

* Streams are dumb

* Ready to ship

Fixed issue with user not having any old week plans.
Changed the name of the `WeekPlansBloc` to `WeekPlanSelectorBloc` for better readability.
Fixed test.
Removed `Observable` class.
Updated SDK to 2.2.0 for set literals support.
Minor changes in a bunch of places from the name change of `WeekplanSelectorBloc`.

Co-Authored-By: Alexander <31063192+ggAlexS@users.noreply.github.com>

* Update environments.json

* Removed comments

Co-Authored-By: Alexander <31063192+ggAlexS@users.noreply.github.com>

* Trying to fix CI errors

Undid chages to pubspec.lock
Fixed linting isssues in various files: added const keywords and changed a deprecated function.

* Take 2

CI is using old versions - this should be fixed at some point.

* Update pubspec.lock

* Merge branch 'develop' into feature/418

Co-Authored-By: Alexander <31063192+ggAlexS@users.noreply.github.com>

* Update copy_resolve_screen_test.dart

Co-Authored-By: Alexander <31063192+ggAlexS@users.noreply.github.com>

Co-authored-by: Jeppe Krogh Laursen <jeppe.k.l.97@gmail.com>
Co-authored-by: JeppeKLau <44167691+JeppeKLau@users.noreply.github.com>

* Loading the first pictogram in the activity bloc (#650)

* Revert "Feature/418 As a guardian i would like to be able to search for a specific weekplan so it is easier for me to find (#593)" (#657)

This reverts commit d045b80.

* Feature 615: citizens can now open completed activities  (#651)

* Removed !

* Update weekplan_day_column.dart

* Reverted some changes

Co-authored-by: twaxlol <folese18@student.aau.dk>
Co-authored-by: OliverSorensen <Ossa18@student.aau.dk>

* Fixed unit test errors (#661)

Fixed errors in copy_resolve_screen_test.dart
Fixed errors in show_activity_screen_test.dart
Fixed errors in weekplan_selector_screen_test.dart

* Feature/592: "Overståede Uger" includes current week (#663)

* Added some tests and beginning to design the algorithm

* It should work now, next is thorough testing

* Tested, and fixed edge cases

* Fixed linting stuff

* Long line in a comment

* Because GitHub CI couldn't find the file

* Because CI is still stupid

* Create Dates_with_weeks_2020_to_2030_semi.csv

* Mac os problem fixed

* stupid linting... again

Co-authored-by: Alexander Nykjær <alax0013@gmail.com>
Co-authored-by: Michelle Terpling <michelle@terpling.dk>

* Feature/595 Used MediaQuery to adjust the layout for all screens (upload_image_from_phone) (#655)

* made the

* Text and image overlflow fixed and code optimisation

Added MediaQuery to manage changes such as rotationg the screen and replaced the column with a widget that returns a container. This works for both tablet and mobile phone device

* minor

* Issue 595 clean code fix

beautifying and small changes

* Revert changes to gitignore, evviroment jason and pubspec

This reverts commit 4d5999e.

Co-authored-by: ChristofferAaen <cbaaen@live.dk>

* Feature/429.5 (#654)

* Fixed delay on erroneous login

* Merge develop into feature/429.5 (#653)

* Feature 495: Changed pictogram box changes (#559)

* Changed pictogram box changes

The Issue was that some text was cut off when it spanned multiple lines, as the box size was static. this has been solved by allowing the pictogram box to be as high as the elements within and set the max amount of lines for the text to 2.

this made smaller words split into 2 lines, which was further solved by only allowing the text to be 1 line of only 1 word was present in the string.

* Update pictogram_text.dart

Now sets textlines to 2 if a word cant fit on one line

* Minimum Android APK changed from 16 (Jelly Bean) to 23 (Marshmallow) (#647)

minSdkVersion has been increased from 16 to 23, primarily to prevent a library warning with text relocations.

This is also due to Jelly Bean no longer being supported and is far too outdated to be worth.

Co-authored-by: Riasalit <daniel-vilslev@hotmail.com>
Co-authored-by: ProgDaniel <43956461+ProgDaniel@users.noreply.github.com>

Co-authored-by: Mustafa Al-Dailemi <43955099+Mustafa-ALD@users.noreply.github.com>
Co-authored-by: Riasalit <daniel-vilslev@hotmail.com>
Co-authored-by: ProgDaniel <43956461+ProgDaniel@users.noreply.github.com>

* Feature 538: No lingering weekplans when editing (#656)

* Reverted some changes

* Maybe not hacky

* Mere await

* Mere await

* Fix add new weekplan was counted

Co-authored-by: OliverSorensen <Ossa18@student.aau.dk>

* Feature/371 (#664)

* not done yet

needs more

* small change

* unit test + flutter test

not done yet

* Flutter test of undo button (genoptag knap)

* Revert "small change"

This reverts commit aeb448f.

* Update weekplan_bloc.dart

Co-authored-by: myname <email@email.email>

* Weekplanner 668: Inconsistency in settings menu for citizens (#682)

* Fixed the issue

Added a null check. Also fixed some issues that had arisen due to conflicting pushes in earlier sprints, so the code is consistent.

* Linter

* Linter

* Linter

* Feature/540: Collapse "overståede uger" (#665)

* Update weekplan_selector_screen.dart

* Fixed button position

Also added a key for testing

* Incomplete test

* Test implemented

Test has been implemented and naming convention fix.

* Linter

* Fixed

* Update weekplan_selector_screen.dart

Co-authored-by: JohanKrogh <johan.krogh@gmail.com>

* Feature 683: Fixed server status check and made login async (#686)

* WIP: Make login actually async

* Fixed tests and status endpoint

* Login from popup async too

* Handle error right

* More correct error handling

* Check server status through api_client

* One comment

* Remove unnecessary method from test

* Specify types on wait

* Be completely sure about internet connection :)

* Remove library due to build errors

* oops

* Feature/592.5 (#685)

* Skipped a test instead of commenting it out

* Cleaned up the code, and fixed a small issue

The issue was that it made the calculations from a specific time of day, not at 00:00

* Linting

* Just a small rename

* Small speed up for December

* Split the current week algorithm into different methods, and cleaned up

* Linting

* Final refactor to something the we can actually explain to someone else

Removed unneeded tests

* Moved a method

* Moved a statement

* Removed unnecessary complication

* feature/696: Inconsistent buttons (#701)

* Inconsistent buttons

Only partly solved the issue.
The buttons now correctly remove the timer and add choiceboard options when marking an activity as completed as well as cancelled. Furthermore an isEnabled has been added to the cancel button, so it becomes disables when the state is completed.
The buttons however only become disabled, when you reenter the activity. This is due to the fact the other button does not check for a new state, when the first button is pressed and as such does not get the new state information, when an acitivty is completed or cancelled. There is not enough time to fix this before release, and as such only the most system breaking part of the bug has been fixed, as it would do some funky things, when trying to make a choiceboard on a completed activity.

* Update show_activity_screen.dart

Fixed missing Add Choiceboard on new activities

* Changed values for release (#706)

Co-authored-by: Frederik Spang <fthoms16@student.aau.dk>
Co-authored-by: Frederik Spang <frederik@progras.dk>
Co-authored-by: Bogi Napoleon Wennerstrøm <bogi.wennerstrom@gmail.com>
Co-authored-by: Rikke Husted Østergaard <raster16@student.aau.dk>
Co-authored-by: Adrian Plesner <adrian.plesner@gmail.com>
Co-authored-by: Mustafa Al-Dailemi <43955099+Mustafa-ALD@users.noreply.github.com>
Co-authored-by: Mustafa Al-Dailemi <Mustafa-ALD@users.noreply.github.com>
Co-authored-by: Riasalit <daniel-vilslev@hotmail.com>
Co-authored-by: Mostaan H <34608699+smh87@users.noreply.github.com>
Co-authored-by: Kristian Benny Winther Sørensen <43601483+kbwsoorensen@users.noreply.github.com>
Co-authored-by: ProgDaniel <43956461+ProgDaniel@users.noreply.github.com>
Co-authored-by: Ane Søgaard Jørgensen <42242841+Kaliahh@users.noreply.github.com>
Co-authored-by: AdrianPlesner <33195961+AdrianPlesner@users.noreply.github.com>
Co-authored-by: OliverSorensen <Ossa18@student.aau.dk>
Co-authored-by: LJensen0403 <44022936+LJensen0403@users.noreply.github.com>
Co-authored-by: twaxlol <folese18@student.aau.dk>
Co-authored-by: Liv Holm <43985985+LivHolm@users.noreply.github.com>
Co-authored-by: twaxlol <45589745+twaxlol@users.noreply.github.com>
Co-authored-by: Alexander <31063192+ggAlexS@users.noreply.github.com>
Co-authored-by: Jeppe Krogh Laursen <jeppe.k.l.97@gmail.com>
Co-authored-by: JeppeKLau <44167691+JeppeKLau@users.noreply.github.com>
Co-authored-by: JohanKrogh <johan.krogh1@gmail.com>
Co-authored-by: Alexander Nykjær <alax0013@gmail.com>
Co-authored-by: Michelle Terpling <michelle@terpling.dk>
Co-authored-by: ZohraAmini <amini.zohra.za@gmail.com>
Co-authored-by: ChristofferAaen <cbaaen@live.dk>
Co-authored-by: Emil7370 <43956069+Emil7370@users.noreply.github.com>
Co-authored-by: myname <email@email.email>
Co-authored-by: JohanKrogh <johan.krogh@gmail.com>

* Changes in versions (#708)

ro0dkll/upload-to-google-play updated to 1.0.7
App version updated to 1.2.2

Co-authored-by: Jakob Precht <sporvogn@live.com>
Co-authored-by: Frederik Spang <fthoms16@student.aau.dk>
Co-authored-by: Frederik Spang <frederik@progras.dk>
Co-authored-by: Bogi Napoleon Wennerstrøm <bogi.wennerstrom@gmail.com>
Co-authored-by: Rikke Husted Østergaard <raster16@student.aau.dk>
Co-authored-by: Adrian Plesner <adrian.plesner@gmail.com>
Co-authored-by: Mustafa Al-Dailemi <43955099+Mustafa-ALD@users.noreply.github.com>
Co-authored-by: Mustafa Al-Dailemi <Mustafa-ALD@users.noreply.github.com>
Co-authored-by: Riasalit <daniel-vilslev@hotmail.com>
Co-authored-by: Mostaan H <34608699+smh87@users.noreply.github.com>
Co-authored-by: Kristian Benny Winther Sørensen <43601483+kbwsoorensen@users.noreply.github.com>
Co-authored-by: ProgDaniel <43956461+ProgDaniel@users.noreply.github.com>
Co-authored-by: Ane Søgaard Jørgensen <42242841+Kaliahh@users.noreply.github.com>
Co-authored-by: AdrianPlesner <33195961+AdrianPlesner@users.noreply.github.com>
Co-authored-by: OliverSorensen <Ossa18@student.aau.dk>
Co-authored-by: LJensen0403 <44022936+LJensen0403@users.noreply.github.com>
Co-authored-by: twaxlol <folese18@student.aau.dk>
Co-authored-by: Liv Holm <43985985+LivHolm@users.noreply.github.com>
Co-authored-by: twaxlol <45589745+twaxlol@users.noreply.github.com>
Co-authored-by: Alexander <31063192+ggAlexS@users.noreply.github.com>
Co-authored-by: Jeppe Krogh Laursen <jeppe.k.l.97@gmail.com>
Co-authored-by: JeppeKLau <44167691+JeppeKLau@users.noreply.github.com>
Co-authored-by: JohanKrogh <johan.krogh1@gmail.com>
Co-authored-by: Alexander Nykjær <alax0013@gmail.com>
Co-authored-by: Michelle Terpling <michelle@terpling.dk>
Co-authored-by: ZohraAmini <amini.zohra.za@gmail.com>
Co-authored-by: ChristofferAaen <cbaaen@live.dk>
Co-authored-by: Emil7370 <43956069+Emil7370@users.noreply.github.com>
Co-authored-by: myname <email@email.email>
Co-authored-by: JohanKrogh <johan.krogh@gmail.com>
Co-authored-by: Jakob Faarbaek Gregersen <jfg@bluepp.dk>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

The function checkServerConnection always throws an error
5 participants