SDSM:Pending Changes: Difference between revisions

From SMUSwiki
Jump to navigation Jump to search
(Add comment that juliomotol can't be upgraded prior to Laravel 10 upgrade.)
(Purge almost all items as they graduated from Pending to Historical.)
 
(17 intermediate revisions by the same user not shown)
Line 12: Line 12:


It is similar to the [[SDSM:Historical_Changes|Historical Changes]] part
It is similar to the [[SDSM:Historical_Changes|Historical Changes]] part
but that it describes work which was prepared and published in a Git branch
but that it describes work which was prepared and published in Git feature
but it was deemed premature to merge it to the trunk, such as due to a
branches that are longer lived and not yet merged to the trunk; in
desire for more testing first, or because it was possibly unfinished; in
contrast, ''Historical'' is for work that ''was'' merged to trunk.
contrast, ''Historical'' is for work that ''was'' merged to trunk.


[[#top|RETURN]]
[[#top|RETURN]]


== SDS Laravel: Internal Design Changes ==
== SDS Laravel: Removed Application Functionality ==


=== 2024 May 7: Replace model attrs "dates" with "casts" ===
=== 2024 Jun 25: Remove Screens For Application For Student Enrollment By Parents ===


Laravel supported a "dates" model attribute through version 9, and then
This task removed the ''SDS Laravel'' screens that supported parents
Laravel 10 removed it. The function of this was to enumerate database/model
applications for student enrollment of their children directly in '''SDS'''.
fields that were supposed to be automatically converted to Carbon DateTime
The functionality became obsolete and unused when Blackbaud started being
objects; so under Laravel 8, any "dates" declarations would be respected,
used for applications instead, and applications were imported to '''SDS'''
while under Laravel 10 they would be ignored.
from Blackbaud by an automated process.


Compare:
These 20 source files were simply removed:


* https://laravel.com/api/9.x/Illuminate/Database/Eloquent/Concerns/HasAttributes.html
* app/Http/Controllers/Application/ApplicationController.php
* https://laravel.com/api/10.x/Illuminate/Database/Eloquent/Concerns/HasAttributes.html
* app/Http/Controllers/Application/FamilyInfoController.php
* app/Http/Controllers/Application/OtherController.php
* app/Http/Controllers/Application/ParentInfoController.php
* app/Http/Controllers/Application/ParentQuestionController.php
* app/Http/Controllers/Application/StudentInfoController.php
* app/Http/Controllers/Application/StudentQuestionController.php
* app/Http/Controllers/System/EditBoardingQuestionController.php
* resources/js/components/application/AddressInfo.vue
* resources/js/components/application/FamilyStatus.vue
* resources/js/components/application/GuardianHolder.vue
* resources/js/components/application/GuardianInfo.vue
* resources/views/application/home.blade.php
* resources/views/application/index.blade.php
* resources/views/application/parentinfo/index.blade.php
* resources/views/application/studentinfo/index.blade.php
* resources/views/includes/application_menu.blade.php
* resources/views/system/boarding_question/create.blade.php
* resources/views/system/boarding_question/edit.blade.php
* resources/views/system/boarding_question/index.blade.php


As a result, simply upgrading ''SDS Laravel'' from Laravel 8 to 10 resulted
These 3 source files were updated to remove references to the removed ones:
in many parts of the app breaking in various ways including when simply
visiting the post-login home screen, as PHP died with errors like
<code>Call to a member function format() on int</code>.


To fix this, any instances of <code>protected $dates = ['x',...]</code>
* resources/js/app.js
in model classes were replaced with
* resources/views/includes/menu.blade.php
<code>protected $casts = ['x'=>'datetime',...]</code>
* routes/web.php
which was the more modern way to get the same functionality, which exists
in both Laravel 8 and 10. For the few model classes that already had other
<code>$casts</code> declarations, the replacements were merged with those.


The changes of this task were not merged to trunk yet because it was deemed
Note that Laravel Eloquent Models related to this functionality were
important to give each instance of the changed 51 model classes more
explicitly left alone, so they can still thoroughly represent the actual
thorough testing before merging than they had received as of 2024 May 7.
database structure, and they can still be used by other processes.
One key reason for this is the idea that the fields in question might not
Likewise, references to student applications in other screens were left
all be date+time, and rather may be date-only or time-only.
alone as they may still be relevant to the Blackbaud process or for history.
All ''SDS Laravel'' screens accessible from a main menu item were found to
load and at a glance seemed to display correctly, with these changes
included, but that is as far as any testing went as of 2024 May 7.
(There are 2 such screens that didn't load, but they didn't load prior to
these changes either, and that is a separate concern.)
 
As of 2024 May 7, the changes of this task have been bundled with the
changes of the task upgrading ''SDS Laravel'' from Laravel 8 to 10, so the
sum changes would receive the necessary thorough testing together before
being merged to trunk. However, since the changes of this task do not
depend on the upgrade, it is possible that a subset of them may be fully
tested and merged sooner when other changes using the same models occur.
 
[[#top|RETURN]]
 
== SDS Laravel: Changes to Third-Party Dependencies ==
 
=== 2024 May 3: Upgrade Laravel from 8.x to 10.x ===
 
This task updated <code>composer.json</code> to require the latest
PHP-8.1-compatible major version of the PHP library dependency Laravel from
8.x to 10.x.
 
To be more specific, it made these dependency changes:
 
* barryvdh/laravel-debugbar (^3.7 to ^3.13.5)
* directorytree/ldaprecord-laravel (^2.7.3 unchanged but upgrade exists)
* etern8ty/beanstream (dev-master unchanged but upgrade exists)
* fakerphp/faker (^1.23.1 unchanged)
* fideloper/proxy (^4.4.2 removed as Laravel has its upgrade built-in)
* goldspecdigital/laravel-eloquent-uuid (^8.0.1 to ^10.0)
* guzzlehttp/guzzle (^7.8.1 unchanged)
* intervention/image (^2.7.2 unchanged but upgrade exists)
* juliomotol/laravel-auth-timeout (^3.1.1 to ^4.1)
* lab404/laravel-impersonate (^1.7.5)
* laravel/framework (^8.83.27 to ^10.48.10)
* laravel/helpers (^1.7 unchanged but possibly no longer needed)
* laravel/pint (^1.15.3 added but not yet used)
* laravel/sail (^1.29.1 added but not yet used)
* laravel/sanctum (^3.3.3 added but not yet used)
* laravel/tinker (^2.9 unchanged)
* laravel/ui (^3.4.6 to 4.5.1)
* mockery/mockery (^1.6.11 unchanged)
* nunomaduro/collision (^5.11 to ^7.10)
* phpunit/phpunit (^10.5.20 unchanged)
* spatie/laravel-ignition (^1.6.4 to ^2.7)
* staudenmeir/eloquent-has-many-deep (^1.14.4 to ^1.19.3)
 
Note that <code>juliomotol/laravel-auth-timeout</code> version 4.1 requires
Laravel version 9 or greater so it can not be upgraded from 3.1.1 prior to
the Laravel 10 upgrade.
 
This task also updated <code>app/Http/Middleware/TrustProxies.php</code> to
be compatible with the replacement of <code>fideloper/proxy</code> with a
Laravel built-in. The changes were in 2 spots.
 
First was this substitution:
 
    use Fideloper\Proxy\TrustProxies as Middleware;
 
    use Illuminate\Http\Middleware\TrustProxies as Middleware;
 
Second was this substitution:
 
    protected $headers = Request::HEADER_X_FORWARDED_ALL;
 
    protected $headers =
        Request::HEADER_X_FORWARDED_FOR |
        Request::HEADER_X_FORWARDED_HOST |
        Request::HEADER_X_FORWARDED_PORT |
        Request::HEADER_X_FORWARDED_PROTO |
        Request::HEADER_X_FORWARDED_AWS_ELB;
 
This task also updated
<code>app/Http/Middleware/AuthTimeoutMiddleware.php </code> to be
compatible with the <code>juliomotol/laravel-auth-timeout</code> upgrade.
 
There was this 1 substitution:
 
    use JulioMotol\AuthTimeout\Middleware\AuthTimeoutMiddleware as BaseMiddleware;
 
    use JulioMotol\AuthTimeout\Middlewares\CheckAuthTimeout as BaseMiddleware;
 
This task also explored upgrades to some other PHP library dependencies but
they were excluded due to requiring more substantial  code changes for
compatibility, and will be returned to later.


[[#top|RETURN]]
[[#top|RETURN]]

Latest revision as of 22:17, 5 August 2024


This document consists of multiple parts; for a directory to all of the parts, see SDSM:Index.

Description

This part of the SDS Modernization (SDSM) document enumerates a not necessarily exhaustive list of pending changes or improvements that were made to SDS, made by Darren Duncan if by whom is not otherwise specified.

It is similar to the Historical Changes part but that it describes work which was prepared and published in Git feature branches that are longer lived and not yet merged to the trunk; in contrast, Historical is for work that was merged to trunk.

RETURN

SDS Laravel: Removed Application Functionality

2024 Jun 25: Remove Screens For Application For Student Enrollment By Parents

This task removed the SDS Laravel screens that supported parents applications for student enrollment of their children directly in SDS. The functionality became obsolete and unused when Blackbaud started being used for applications instead, and applications were imported to SDS from Blackbaud by an automated process.

These 20 source files were simply removed:

  • app/Http/Controllers/Application/ApplicationController.php
  • app/Http/Controllers/Application/FamilyInfoController.php
  • app/Http/Controllers/Application/OtherController.php
  • app/Http/Controllers/Application/ParentInfoController.php
  • app/Http/Controllers/Application/ParentQuestionController.php
  • app/Http/Controllers/Application/StudentInfoController.php
  • app/Http/Controllers/Application/StudentQuestionController.php
  • app/Http/Controllers/System/EditBoardingQuestionController.php
  • resources/js/components/application/AddressInfo.vue
  • resources/js/components/application/FamilyStatus.vue
  • resources/js/components/application/GuardianHolder.vue
  • resources/js/components/application/GuardianInfo.vue
  • resources/views/application/home.blade.php
  • resources/views/application/index.blade.php
  • resources/views/application/parentinfo/index.blade.php
  • resources/views/application/studentinfo/index.blade.php
  • resources/views/includes/application_menu.blade.php
  • resources/views/system/boarding_question/create.blade.php
  • resources/views/system/boarding_question/edit.blade.php
  • resources/views/system/boarding_question/index.blade.php

These 3 source files were updated to remove references to the removed ones:

  • resources/js/app.js
  • resources/views/includes/menu.blade.php
  • routes/web.php

Note that Laravel Eloquent Models related to this functionality were explicitly left alone, so they can still thoroughly represent the actual database structure, and they can still be used by other processes. Likewise, references to student applications in other screens were left alone as they may still be relevant to the Blackbaud process or for history.

RETURN