Skip to content

Commit

Permalink
Merge pull request #2993 from rokwire/release/v4.2.52+1652
Browse files Browse the repository at this point in the history
Release/v4.2.52+1652
  • Loading branch information
sandeep-ps authored Feb 22, 2023
2 parents 3a5515c + 9136556 commit 42b813f
Show file tree
Hide file tree
Showing 82 changed files with 1,817 additions and 900 deletions.
50 changes: 50 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,56 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## Unreleased

## [4.2.52] - 2023-02-16
- Launch privacy policy web content in an external web browser on iOS platforms [#2909](https://github.com/rokwire/illinois-app/issues/2909).
- Launch feedback web content in an external web browser on iOS platforms [#2909](https://github.com/rokwire/illinois-app/issues/2909).

## [4.2.51] - 2023-02-15
### Fixed
- Fixed scrolling issues in research questionnaire prompt and acknowledgement panels [#2985](https://github.com/rokwire/illinois-app/issues/2985).
- Android: Crash for foldable devices [#2920](https://github.com/rokwire/illinois-app/issues/2920).

## [4.2.50] - 2023-02-13
### Changed
- Updated analytics log for research questionnaire answers [#2910](https://github.com/rokwire/illinois-app/issues/2910).
- Updated English strings [#2596](https://github.com/rokwire/illinois-app/issues/2596).
### Fixed
- Displaying athletics event from notifications inbox [#2874](https://github.com/rokwire/illinois-app/issues/2874).
- Handle tap action over poll and wellness todo items notification [#2645](https://github.com/rokwire/illinois-app/issues/2645).
- Load appointments only if the user is signed in [#2923](https://github.com/rokwire/illinois-app/issues/2923).
- Scrolling in wellness MyMcKinley Appointments [#2958](https://github.com/rokwire/illinois-app/issues/2958).
- Open appointments list panel on tap over appointment inbox message if appointment id does not exist [#2969](https://github.com/rokwire/illinois-app/issues/2969).
- Open appointment detail panel on tap over appointment inbox message [#2969](https://github.com/rokwire/illinois-app/issues/2969).
- Fixed navigation target when requesting directions to building [#2955](https://github.com/rokwire/illinois-app/issues/2955).
- Retrieve sorted appointments from the backend [#2971](https://github.com/rokwire/illinois-app/issues/2971).
### Added
- Cache appointments account [#2905](https://github.com/rokwire/illinois-app/issues/2905).

## [4.2.49] - 2023-01-05
### Fixed
- Fixed delete poll notification processing [#2173](https://github.com/rokwire/illinois-app/issues/2173).
- Fixed dropdown menu needs extending in Groups Manage Members [#2407](https://github.com/rokwire/illinois-app/issues/2407).
- Fixed empty iCard expiration date processing for retired faculty/staff [#2892](https://github.com/rokwire/illinois-app/issues/2892).
- Fixed update privacy dialog scrolling (+ some other nonsense items) [#2891](https://github.com/rokwire/illinois-app/issues/2891).
- Formatting date times in events [#2719](https://github.com/rokwire/illinois-app/issues/2719).
### Changed
- Show user profile picture for personal info button in root header bar [#2157](https://github.com/rokwire/illinois-app/issues/2157).
- Text update: Settings - Sign In/Sign Out [#2457](https://github.com/rokwire/illinois-app/issues/2457).

## [4.2.48] - 2023-01-03
### Fixed
- Refresh issue with appointments [#2843](https://github.com/rokwire/illinois-app/issues/2843).
- Added appointments default end date time [#2842](https://github.com/rokwire/illinois-app/issues/2842).
- Remove dimmed foreground decoration from video tutorial thumbnails [#2823](https://github.com/rokwire/illinois-app/issues/2823).
- Fixed "Add Cover Image" button background color [#2868](https://github.com/rokwire/illinois-app/issues/2868).
### Added
- Added muted indicator to inbox message card [#2877](https://github.com/rokwire/illinois-app/issues/2877).
- Show not logged in message in Illini Cash and MTD Buss Wallet cards [#2867](https://github.com/rokwire/illinois-app/issues/2877).
### Deleted
- Removed explanation message "View current studies that match ..." from questionnaire acknowledgement panel [#2873](https://github.com/rokwire/illinois-app/issues/2873).
### Changed
- Always use orange favorite icon, removed all references to the blue favorite icon [#2165](https://github.com/rokwire/illinois-app/issues/2165).

## [4.2.47] - 2022-12-22
### Changed
- Polls :: not-signed-in error - needs better message [#2777](https://github.com/rokwire/illinois-app/issues/2777).
Expand Down
2 changes: 2 additions & 0 deletions SECURITY.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ Patches for [ **illinois-app** ] will only be applied to the following versions:

| Version | Supported |
| ------- | ------------------ |
| 4.2.52 | :white_check_mark: |
| < 4.2.52 | :x: |
| 4.2.47 | :white_check_mark: |
| < 4.2.47 | :x: |
| 4.1.36 | :white_check_mark: |
Expand Down
3 changes: 3 additions & 0 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -192,6 +192,9 @@ dependencies {

//Security
implementation "androidx.security:security-crypto:1.1.0-alpha03"

// Support foldable devices
implementation "androidx.window:window:1.0.0"
//end Common

//Google Maps
Expand Down
64 changes: 46 additions & 18 deletions android/app/src/main/java/edu/illinois/rokwire/Utils.java
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
import android.graphics.Bitmap;
import android.graphics.drawable.Drawable;
import android.graphics.drawable.GradientDrawable;
import android.location.Location;
import android.text.format.DateUtils;
import android.util.Log;
import android.view.View;
Expand Down Expand Up @@ -178,35 +179,62 @@ public static HashMap optLocation(HashMap explore) {
return null;
}

public static HashMap optStudentCourseLocation(HashMap explore) {
return optStudentCourseLocation(explore, false);
}

public static HashMap optStudentCourseLocation(HashMap explore, boolean destinaton) {
Object sectionObj = explore.get("coursesection");
public static HashMap optStudentCourseBuilding(HashMap explore) {
Object sectionObj = (explore != null) ? explore.get("coursesection") : null;
if (sectionObj instanceof HashMap) {
HashMap sectionMap = (HashMap) sectionObj;
Object buildingObj = sectionMap.get("building");
if (buildingObj instanceof HashMap) {
HashMap buildingMap = (HashMap) buildingObj;
if (destinaton) {
Object entracesObj = buildingMap.get("entrances");
if (entracesObj instanceof ArrayList) {
ArrayList entracesList = (ArrayList) entracesObj;
if (entracesList.size() > 0) {
Object entraceObj = entracesList.get(0);
if (entraceObj instanceof HashMap) {
return (HashMap) entraceObj;
}
}
}
}
return buildingMap;
}
}
return null;
}

public static HashMap optStudentCourseLocation(HashMap explore) {
return optStudentCourseBuilding(explore);
}

public static HashMap optBuildingDestinationLocation(HashMap buildingMap, android.location.Location origin, boolean requireAda) {
Object entracesObj = (buildingMap != null) ? buildingMap.get("entrances") : null;
if ((entracesObj instanceof ArrayList) && (origin != null)) {
LatLng orgLatLng = new LatLng(origin.getLatitude(), origin.getLongitude());
HashMap minEntrance = null, minAdaEntrance = null;
double minDistance = -1.0, minAdaDistance = -1.0;
ArrayList entracesList = (ArrayList) entracesObj;
for (Object entraceObj : entracesList) {
if (entraceObj instanceof HashMap) {
HashMap entraceMap = (HashMap) entraceObj;
LatLng entraceLatLng = optLatLng(entraceMap);
if (entraceLatLng != null) {
double distance = Location.getDistanceBetween(orgLatLng, entraceLatLng);
if ((minDistance < 0.0) || (distance < minDistance)) {
minDistance = distance;
minEntrance = entraceMap;
}

Object adaObj = entraceMap.get("adaCompliant");
boolean adaEntrance = (adaObj instanceof Boolean) ? (Boolean)adaObj : false;
if (requireAda && (adaEntrance == true) && ((minAdaDistance < 0.0) || (distance < minAdaDistance))) {
minAdaDistance = distance;
minAdaEntrance = entraceMap;
}
}
}
}


if (requireAda && (minAdaEntrance != null)) {
return minAdaEntrance;
}
else if (minEntrance != null) {
return minEntrance;
}
}
return buildingMap;
}

public static Integer optLocationFloor(HashMap explore) {
if (explore == null) {
return null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
initUiViews();
initCoreLocation();
initExplore();
initExplore(null);
initNavigation();
buildTravelModes();
}
Expand Down Expand Up @@ -254,6 +254,7 @@ private void onCoreLocationUpdate() {
if (coreLocation != null) {
if (!firstLocationUpdatePassed) {
firstLocationUpdatePassed = true;
initExplore(coreLocation);
handleFirstLocationUpdate();
}

Expand Down Expand Up @@ -290,7 +291,7 @@ private void stopMonitor() {

//region Explores

private void initExplore() {
private void initExplore(android.location.Location origin) {
Serializable exploreSerializable = getIntent().getSerializableExtra("explore");
if (exploreSerializable == null) {
return;
Expand All @@ -299,13 +300,13 @@ private void initExplore() {
HashMap singleExplore;
singleExplore = (HashMap) exploreSerializable;
this.explore = singleExplore;
initExploreLocation(singleExplore);
initExploreLocation(singleExplore, origin);
} else if (exploreSerializable instanceof ArrayList) {
ArrayList explores = (ArrayList) exploreSerializable;
this.explore = explores;
Object firstExplore = (explores.size() > 0) ? explores.get(0) : null;
if (firstExplore instanceof HashMap) {
initExploreLocation((HashMap) firstExplore);
initExploreLocation((HashMap) firstExplore, origin);
}
}
}
Expand Down Expand Up @@ -367,15 +368,20 @@ private void updateExploreMarkerAppearance() {
cameraZoom = currentCameraZoom;
}

private void initExploreLocation(HashMap singleExplore) {
private void initExploreLocation(HashMap singleExplore, Location location) {
Utils.ExploreType exploreType = Utils.Explore.getExploreType(singleExplore);
if ((exploreType == Utils.ExploreType.PARKING) || (exploreType == Utils.ExploreType.MTD_STOP)) {
LatLng latLng = Utils.Explore.optLocationLatLng(singleExplore);
if (latLng != null) {
this.exploreLocation = Utils.Explore.createLocationMap(latLng);
}
} else if (exploreType == Utils.ExploreType.BUILDING) {
boolean requireAda = Utils.Map.getValueFromPath(options, "requireAda", false);
this.exploreLocation = Utils.Explore.optBuildingDestinationLocation(singleExplore, location, requireAda);
} else if (exploreType == Utils.ExploreType.STUDENT_COURSE) {
this.exploreLocation = Utils.Explore.optStudentCourseLocation(singleExplore, true);
boolean requireAda = Utils.Map.getValueFromPath(options, "requireAda", false);
HashMap buildingMap = Utils.Explore.optStudentCourseBuilding(singleExplore);
this.exploreLocation = Utils.Explore.optBuildingDestinationLocation(singleExplore, location, requireAda);
} else {
this.exploreLocation = Utils.Explore.optLocation(singleExplore);
}
Expand Down
101 changes: 96 additions & 5 deletions assets/extra/appointments.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,99 @@
[
{
"id": "08c122e3-2174-438b-94d4-f231198c26bc",
"account_id": "2222",
"date": "2023-01-14T07:30:444Z",
"type": "InPerson",
"location": {
"id": "555556",
"title": "McKinley Health Center, East wing, 3rd floor",
"latitude": 40.10291,
"longitude": -88.21961,
"phone": "555-333-777"
},
"cancelled": false,
"instructions": "Some instructions 1 ...",
"host": {
"first_name": "John",
"last_name": "Doe"
}
},
{
"id": "08c122e3-2174-438b-94d4-f231198c26ba",
"account_id": "2222",
"date": "2023-01-13T07:30:444Z",
"type": "InPerson",
"location": {
"id": "555555",
"title": "McKinley Health Center, East wing, 3rd floor",
"latitude": 40.10291,
"longitude": -88.21961,
"phone": "555-333-777"
},
"cancelled": false,
"instructions": "Some instructions 1 ...",
"host": {
"first_name": "John",
"last_name": "Doe"
}
},
{
"id": "08c122e3-2174-438b-f231198c26ba",
"account_id": "2222",
"date": "2023-01-12T08:22:444Z",
"type": "Online",
"online_details": {
"url": "https://mymckinley.illinois.edu",
"meeting_id": "asdasd",
"meeting_passcode": "passs"
},
"cancelled": false,
"instructions": "Some instructions 2 ...",
"host": {
"first_name": "JoAnn",
"last_name": "Doe"
}
},
{
"id": "2174-438b-94d4-f231198c26ba",
"account_id": "2222",
"date": "2023-01-11T10:30:444Z",
"type": "InPerson",
"location": {
"id": "777",
"title": "McKinley Health Center 8, South wing, 2nd floor",
"latitude": 40.08514,
"longitude": -88.27801,
"phone": "555-444-777"
},
"cancelled": false,
"instructions": "Some instructions 3 ...",
"host": {
"first_name": "Bill",
"last_name": ""
}
},
{
"id": "08c122e3",
"account_id": "2222",
"date": "2023-01-10T11:34:444Z",
"type": "Online",
"online_details": {
"url": "https://mymckinley.illinois.edu",
"meeting_id": "09jj",
"meeting_passcode": "dfkj3940"
},
"cancelled": false,
"instructions": "Some instructions 4 ...",
"host": {
"first_name": "Peter",
"last_name": "Grow"
}
},
{
"id": "08c122e3-2174-438b-94d4-f231198c26bc",
"account_id": "2222",
"date": "2023-01-14T07:30:444Z",
"date": "2023-02-14T07:30:444Z",
"type": "InPerson",
"location": {
"id": "555556",
Expand All @@ -21,7 +112,7 @@
{
"id": "08c122e3-2174-438b-94d4-f231198c26ba",
"account_id": "2222",
"date": "2023-01-13T07:30:444Z",
"date": "2023-02-13T07:30:444Z",
"type": "InPerson",
"location": {
"id": "555555",
Expand All @@ -40,7 +131,7 @@
{
"id": "08c122e3-2174-438b-f231198c26ba",
"account_id": "2222",
"date": "2023-01-12T08:22:444Z",
"date": "2023-02-12T08:22:444Z",
"type": "Online",
"online_details": {
"url": "https://mymckinley.illinois.edu",
Expand All @@ -57,7 +148,7 @@
{
"id": "2174-438b-94d4-f231198c26ba",
"account_id": "2222",
"date": "2023-01-11T10:30:444Z",
"date": "2023-02-11T10:30:444Z",
"type": "InPerson",
"location": {
"id": "777",
Expand All @@ -76,7 +167,7 @@
{
"id": "08c122e3",
"account_id": "2222",
"date": "2023-01-10T11:34:444Z",
"date": "2023-02-10T11:34:444Z",
"type": "Online",
"online_details": {
"url": "https://mymckinley.illinois.edu",
Expand Down
Loading

0 comments on commit 42b813f

Please sign in to comment.