Sequences

Version Date Notes By
0.1 2018-07-20 Initial release ROB

The various sequences already implemented in WeMigrane have, each, a specific purpose that will be documented bellow.

Base All Modules

Active Development: Will eventually cover all modules.

Copies all information from v9 to v10 Administration, Documentation, Plans and Surveys.

Base All Modules Preprocessing

Active Development: Needs to be informed (somehow) of the modules that are actually going to be cleaned

Handles cleaning a v10 database before modules are imported

Base Audits

Migrates the v9 to v10 Audits module.

Base Ems

Migrates the v9 to v10 EMS module.

Base Equipment

Migrates the v9 to v10 Equipments module.

Base Full Legislation

NOTE: ACTIVE DEVELOPMENT - Needs to run on a database containing only WeMake data (no tests have been made for multiple clients in same database, no garanty of working correcly. If a mistake is made during migration, the only way to try again is to revert the database to a version before the migration was attempted!)

Migrates the v9 to v10 Legislation module for client information only.

Parameters

Parameter Purpose
client_id The id (integer) that the client will use in v10 database
client_name This is a string identifying the client specific diploma changes (a json file located in BaseFullLegislation/DiplomaClientChanges)

The diploma client changes file

Each client will contain a diploma client changes json file describing the changes to diploma classifications made by the client (new, edit or delete) operations so that the sequence can import these as usual.

The diploma client changes file to be used is indicated when running the migration like so:

php artisan wemigrane:execute_sequence base_full_legislation -p=client_id:1 -p=client_name=slm

Example of a diploma client changes: (remove the comments if copying as json files do not support them)

{
    "groups": {
        // v9 groups
        "23": {
            // key is equal to v9 table id
            "operations": [
                "edit"
            ]
        },
        "24": {
            "operations": [
                "edit"
            ]
        },
        "100": {
            "operations": [
                "new"
            ]
        }
    },
    "sub_groups": {
        // v10 groups
        "16": {
            "operations": [
                "edit"
            ]
        },
        "17": {
            "operations": [
                "edit"
            ]
        },
        ...
    }
}

Base Legislation

Migrates v9 to v10 WeMake legislation information.

Base Legislation Just Files

Carefull using this one as it wipes the files table before beggining.

Migrates v9 to v10 WeMake legislation information files (and files only).

Base Legislation Wemake Just Classifications

This migration expects the tables bellow to be empty.

Migrates diploma_classifications and diploma_diploma_classifications tables (v9 to v10) with WeMake data.

Base Meetings

Migrates the v9 to v10 Meetings module.

Base Occurrences

Migrates the v9 to v10 Occurrences module.

Base OHS

Migrates the v9 to v10 OHS module.

Base Plans

Migrates the v9 to v10 Plans module.

Base Processes

Migrates the v9 to v10 Processes module.

Base Risk

Migrates the v9 to v10 Risk module.

Base Suppliers

Migrates the v9 to v10 Suppliers module.

Base Surveys

Migrates the v9 to v10 Surveys module.

Benteler All Modules

Migrates the v9 to v10 Benteler client with Administration and Document modules (with client specific changes).

Cerealis All Modules

Migrates the v9 to v10 Benteler client with Administration, Document, Plan and Audit modules (with client specific changes).

IPG All Modules

Migrates the v9 to v10 Benteler client with Administration, Document and Plan modules (with client specific changes).

Legislation V10 V9

There are bugs?

Migrates the legislation diplomas v10 to v9.

Portucalence All Modules

Migrates the v9 to v10 Benteler client with Administration and Document modules (with client specific changes).

V10 Import New Languages

This migration was made to import a series of files as a migration of a new language into SGI V10 (these files are generated by V10 New Language Sequence)

V10 New Language Sequence

This sequence generates translation files (whose english strings are to be replaced with the new language translations).

Wemake All Modules

Sequence for migrating WeMake (us) as a client (like benteler) with Administration and Document modules (with no client specific changes).

Wemigrane Test

Testing sequence, do not use.