3955 Commits

Author SHA1 Message Date
d89417ceea Fix intermittent sorting of criterion to actual order ()
When you tried to edit a grading template in  "Project management" -> "Grading Templates" the criterion could be shown in an order not reflecting the sortOrder of the criterion.
The reason was that we only got the arbitrary order depending on the insertion order in the database.

Changed the Collection to a List, it is now an ArrayList. Also added @OrderBy("sortOrder ASC") to actually sort by the order of the criterion thus ensuring visual order is intact.

Co-authored-by: Tom Zhao <tom.zhao@dsv.su.se>
Reviewed-on: 
Reviewed-by: Tom Zhao <tom.zhao@dsv.su.se>
Co-authored-by: Nico Athanassiadis <nico@dsv.su.se>
Co-committed-by: Nico Athanassiadis <nico@dsv.su.se>
2024-11-14 12:39:41 +01:00
cfe61a9ed8 task/3382: Harmonize database names as snake_case ()
Co-authored-by: Andreas Svanberg <andreass@dsv.su.se>
Reviewed-on: 
Reviewed-by: ansv7779 <andreass@dsv.su.se>
Co-authored-by: Tom Zhao <tom.zhao@dsv.su.se>
Co-committed-by: Tom Zhao <tom.zhao@dsv.su.se>
2024-11-12 13:33:43 +01:00
8e5c9f5687 Allow longer final thesis titles ()
The titles entered are most often the same as the project title. The project title however has no length limit. When such a project tries to upload their final thesis the system will crash because the accepted long project title is rejected as the final thesis title.

This change removes the length limit on final thesis titles to bring them to parity with the project title.

See OTRS ticket [202411011026](https://otrs.dsv.su.se/otrs/index.pl?Action=AgentTicketZoom;TicketID=389771#1413199)

This change has already been done manually in the production system to resolve the above ticket.

## How to test
Submit a final thesis using a title longer than 255 characters and see that is accepted.

Reviewed-on: 
Reviewed-by: niat8586 <nico@dsv.su.se>
Co-authored-by: Andreas Svanberg <andreass@dsv.su.se>
Co-committed-by: Andreas Svanberg <andreass@dsv.su.se>
2024-11-11 11:17:15 +01:00
ccac2c1cf8 Enable creating an API using Spring Web ()
SciPro will have to provide information to the upcoming student portal. Wicket does not have the ability to serve JSON in the usual REST way and is only able to serve HTML. The most common way to write JSON over HTTP API:s in Java is using Spring Web, but currently SciPro uses Guice for dependency injection rather than Spring which makes adding Spring Web a bit more tricky.

This pull request attempts to solve this by doing the following;
* Replacing Guice with Spring
* Adding a new API module that uses Spring Web
* Turning the entire system into a standard Spring Boot web application

The hope is that these changes will bring the following benefits;
* Harmonize our web stack (Daisy uses Spring and the new lecture hall system is full Spring Boot)
* Enable easy development of a traditional JSON over HTTP API
* Ease future recruitment by using the most common Java web frameworks

Reviewed-on: 
Reviewed-by: niat8586 <nico@dsv.su.se>
Co-authored-by: Andreas Svanberg <andreass@dsv.su.se>
Co-committed-by: Andreas Svanberg <andreass@dsv.su.se>
2024-11-06 11:23:28 +01:00
e18af72336 Allows admins to manage grading report templates ()
# Manage grading report templates
Every once in a while the criteria used to asses theses and individual performance changes. When this happens the criteria in SciPro needs to be updated.

Up until now there has not been a GUI to do this and it has instead been done manually, sometimes using database migrations. It was also time-sensitive since there was only ever one template (per project type) in SciPro such that the change had to happen at the correct time when the new template was to take effect.

There was also the question of how to calculate the grade the author should receive based on the point sum from the supervisors assessment of all the criteria and these limits were hard-coded in the system.

These changes address all of the above;
 * There can be multiple templates per type.
 * Each template has a period during which it is are current.
 * Each template has defined the conversion of point sums to grades.

The periods can not overlap and a template remains current from its start date until another template's start date is reached. There can not be two templates (within a project type) that become valid on the same date.

## How to test
 1. Log in as administrator
 2. Go to "Project management"
 3. Go to "Grading templates"
 4. Create/edit new templates
 5. View current template

Card 3482

Co-authored-by: niat8586 <nico@dsv.su.se>
Reviewed-on: 
Reviewed-by: niat8586 <nico@dsv.su.se>
Co-authored-by: Andreas Svanberg <andreass@dsv.su.se>
Co-committed-by: Andreas Svanberg <andreass@dsv.su.se>
2024-10-30 10:05:22 +01:00
d8e4f0dd22 Stop confusing Spring Boot with copied classes
These classes were copied from Spring Data a long time ago. Their existence on the class path confuses Spring Boot into thinking we use Spring Data JPA which we do not.
2024-10-28 14:02:31 +01:00
949de4a260 Allow supervisors to write a note associated with their projects ()
There is a need among supervisors to maintain some work notes for each project. Where they are in the process, what students need to do, and other such things.

This PR gives the supervisors the ability to write a note for each project on their overview page.

Card 3399

Reviewed-on: 
Reviewed-by: niat8586 <nico@dsv.su.se>
2024-07-10 13:43:27 +02:00
4dc0ba32d0 Enable supervisors to get an overview of forum activity ()
Their project overview page now include a column indicating if any thread in that forum has an unread post and it also acts as a quick link directly to the forum.

Fixes 
Card 3399

Reviewed-on: 
Reviewed-by: niat8586 <nico@dsv.su.se>
Co-authored-by: Andreas Svanberg <andreass@dsv.su.se>
Co-committed-by: Andreas Svanberg <andreass@dsv.su.se>
2024-07-10 13:18:20 +02:00
663b92eb3b 3380 Specify information URL about the review process for supervisors
Administrators want to inform the supervisors how the reviewers are assigned and what dates are important during the thesis writing process.

They can now configure an information URL for each type of project under "Admin / System / Type settings" that is shown to the supervisors as they enter the review process.
2024-05-27 16:29:23 +02:00
0c06dbd6a3 3392 Multiple reviews on the same project should not fulfil multiple targets
Targets set by administrators are based on how many projects the reviewer gets assigned. If there are multiple reviews on a single project due to rejecting earlier versions the reviewer does not get more time.
2024-05-22 12:49:15 +02:00
58cd2003a7 3392 Refactoring 2024-05-22 12:38:57 +02:00
a79ee20cba 3392 Failing test 2024-05-22 12:35:50 +02:00
e8e8bf8a68 3376 Upgrade Hibernate 2024-05-07 12:23:48 +02:00
8ccd6156b7 Fix table casing 2024-05-02 10:17:50 +02:00
aa469a425b Fixed warning/error due to difference in name resolution between IntelliJ and Hibernate. 2024-04-26 10:07:54 +02:00
f5950a43ba 3126 Remove possibility to reply to forum posts via e-mail
Unused feature that caused issues with repeated posts.
2024-04-26 10:05:30 +02:00
bd90b34c42 Fix URKUND integration with new Guice UnitOfWork changes
Can not fetch the settings from the authenticator since that is ran on a HTTP request dispatching thread where no UnitOfWork has started.It is not possible to fetch the credentials in the constructor since then it would not be possible to change the settings while the system is running. Instead recreate the client with prefetched credentials on every request.
2024-04-25 09:51:51 +02:00
28bc8bf05a Merge branch 'wicket-10' into develop 2024-04-24 12:26:11 +02:00
29d8acf4d5 3361 Fix simultaneous requests to open the same checklist
What happens in there are simultaneous requests to open a checklist.
Both threads will read the checklist from the database, and since it
is versioned they will both get version N.
Then both threads will try to update the last open date and save the
checklist. When saving a versioned object a SQL query of the form
UPDATE checklist SET version = N+1 WHERE id = ? AND version = N
is generated, the first such query will succeed but the second one
will not update any row which Hibernate treats as an optimistic
locking error.
To work around this we use a global lock to ensure that only one
thread can update the checklist at a time. We can't use the
EntityManagers lock method since that too will cause an optimistic
locking failure. This is an unfortunate global lock that will affect
everyone even if they open different checklist, but it is such an
underused feature that it should not be a problem.
2024-04-22 15:28:08 +02:00
42cd644e74 Merge branch 'develop' into wicket-10
# Conflicts:
#	view/src/main/java/se/su/dsv/scipro/supervisor/pages/SupervisorViewGroupThreadPage.java
2024-04-16 14:13:03 +02:00
0474b18911 3207 Dubblett - POST finalseminar 2024-04-08 15:44:51 +02:00
3a530879a7 2870 Stöd för att ange nationellt ämneskategori i samband med att godkänner final thesis 2024-04-08 15:43:55 +02:00
a76ff3db2a 3262 Improve feedback when students select a supervisor idea 2024-04-03 14:55:47 +02:00
db84cc6c17 3157 Fix problem with marking threads read when opening the same thread multiple times simultaneously 2024-04-03 11:01:04 +02:00
nikos dimitrakas
a3dbed13d2 Property för att kunna visa sql (false som default). Propertyn database.showSql i pom.xml verkar inte ha någon effekt. 2024-04-02 13:52:56 +02:00
139ecd8bbd 3273 Do not mark thesis as "Sent to examiner" before it is actually sent
What happened was an empty list was returned if we got a bad response from the grading service. So when the check was performed "is there any examination without a grade" then it was true because there were no examinations to begin with.
2024-03-27 09:57:09 +01:00
7420970e4b 3257 förtydliga datum för inskickandet av uppsatsen till examinator 2024-03-21 12:45:06 +01:00
f072429753 3351 Upgrade to Wicket 10
Related Jakarta migration upgrades as well
2024-03-14 15:09:49 +01:00
465706e1be Merge branch '3204-reviewer-capacity' into develop 2024-02-06 11:34:10 +01:00
dc616e48fe 3321 PO Sort reviewer candidates 2024-02-05 14:38:07 +01:00
8385c1292b 3321 PO Show the review period while assigning reviewers. 2024-02-05 12:43:58 +01:00
14d2dcbba0 3321 PO Show the currently assigned reviewer's target information 2024-02-05 10:11:05 +01:00
95a300eeee 3321 PO Show a warning about targets when assigned a reviewer to a project before a review has been requested. 2024-02-01 16:01:24 +01:00
764986d007 3321 Do not include the current reviewer as a candidate. 2024-02-01 15:42:56 +01:00
36d3ab35ad 3321 PO 4) Show current reviewer and allow un-assigning 2024-02-01 15:40:39 +01:00
b4edcf50c7 3321 PO 6) Never suggest the supervisor as a suitable reviewer candidate 2024-02-01 15:11:47 +01:00
bf572189d3 3298 Filter projects by reviewer 2024-02-01 14:57:51 +01:00
0acf5f2bad 3122 tr fIX Stöd för manuell hantering av slutsem för handledare 2024-01-25 16:26:09 +01:00
c23981f510 2870 Allow supervisors to set national subject category 2024-01-22 12:50:39 +01:00
3ad7dd2261 Merge branch 'develop' into 3204-reviewer-capacity 2024-01-22 12:26:17 +01:00
1355dbb92c 3321 PO Separate reviewers mismatched on language/research area.
Reviewers that can review in all languages will never be mismatched on language.
Added a note for projects that have not specified language to communicate with administrators doing assignment why a reviewer is classified as potentially unsuitable.
2024-01-22 11:09:04 +01:00
4e08d1f82c 3204 Return reviewer history even if they had no targets assigned 2024-01-19 10:00:15 +01:00
4d58f2b31b 3122 tr fIX Stöd för manuell hantering av slutsem för handledare 2024-01-18 10:48:31 +01:00
671cf74104 3204 Show the remaining targets 2024-01-18 10:39:11 +01:00
2a0eb66b2f 3204 Include the number of performed reviews in the target history 2024-01-17 12:39:47 +01:00
f447c7db11 Merge remote-tracking branch 'origin/develop' into develop 2024-01-16 17:21:35 +01:00
e57f610311 3204 View target history 2024-01-12 16:29:39 +01:00
5826341e45 3204 Remove old methods 2024-01-12 16:04:48 +01:00
01daec2c0c 3204 Move tests to the new calendar year based methods 2024-01-12 15:25:41 +01:00
0d1650f3f3 3204 Set reviewer targets by calendar year 2024-01-12 15:13:27 +01:00