Opened 3 years ago

Closed 3 years ago

#1309 closed task (fixed)

ID generator for new referral forms

Reported by: Nicklas Nordborg Owned by: Nicklas Nordborg
Priority: major Milestone: Reggie v4.31.2
Component: net.sf.basedb.reggie Keywords:
Cc:

Description

The referral form generator implemented in #897 should be replaced with simpler functionality that only generate a csv-file in a format suitable to be sent to BD47 (Biobanksavdelning 47).

The wizard should ask for a starting number (last 5 digits in the SCAN-B ID) and the number of "kits" to generate. The starting number should be automatically incremented and remembered between sessions.

It should also ask for a site so that the first 2 digits can be added.

There is also two types of kits: a regular kit and a neoadjuvant kit that affects number of referral forms. Also, Halmstad (33) and Jönköping (99) need special handling.

The wizard should generate a csv file with 3 columns: RemissID: The generated ID Remisstyp: The type of referral form affects the procedures at BD47 Remissmottagare: Name of site

There are 7 possible values for Remisstyp.

  1. SCAN-B KlinPat: Regular 7-digit SCAN-B id
  2. SCAN-B KlinKem: Prefix K + 7-digit SCAN-B id
  3. SCAN-B KlinKemNeo: Prefix K + 7-digit SCAN-B id + suffix C
  4. SCAN-B KlinKem33: Same as 2 but used for Halmstad
  5. SCAN-B KlinKemNeo33: Same as 3 but used for Halmstad
  6. SCAN-B KlinKem99: Same as 2 but used for Jönköping
  7. SCAN-B KlinKemNeo99: Same as 3 but used for Jönköping

The types that should be included in the csv depends on the selected type of kit and the site. If a regular kit is created type 1 and 2 should be included, but Halmstad and Jönköping need to have 4 or 6 instead of 2. If a neoadjuvant kit is created type 1, 2 and 3 should be included with same replacements for Halmstad and Jönköping.

The old referral form generator can also be removed as part of this ticket.

Change History (6)

comment:1 by Nicklas Nordborg, 3 years ago

In 6268:

References #1309: ID generator for new referral forms

Removed code for generating referral forms.

comment:2 by Nicklas Nordborg, 3 years ago

In 6269:

References #1309: ID generator for new referral forms

The new ID-generator should now be working.

The last used SCAN-B number is stored in 5-digit form in the last-referral-id setting for the ClientApp.REGGIE'. We also store the last used value for "Number of kits" in last-referral-num-kits. To make this work it is important that the logged in user has WRITE permission to the "Reggie" Client in BASE. This is implemented by giving the PatientCurator group the relevant permissions in the installation wizard.

comment:3 by Nicklas Nordborg, 3 years ago

In 6270:

References #1309: ID generator for new referral forms

Change the wizard so that generated files are stored in the BASE file system. There is also a log file containing the settings used for each file.

A new directory is created by the installation wizard: /home/SCANB/ReferralIdLogs

comment:4 by Nicklas Nordborg, 3 years ago

In 6272:

References #1309: ID generator for new referral forms

New entries to the log file are now added at the beginning of the file so that the most recent are displayed first.

comment:5 by Nicklas Nordborg, 3 years ago

In 6273:

References #1309: ID generator for new referral forms

Remove unused import.

comment:6 by Nicklas Nordborg, 3 years ago

Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.