Skip to content

Commit

Permalink
Fix some dates format in PNO logbook reports test data
Browse files Browse the repository at this point in the history
  • Loading branch information
ivangabriele committed Mar 24, 2024
1 parent 7876af8 commit 11f9cad
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,4 @@ UPDATE logbook_reports SET value = JSONB_SET(value, '{predictedArrivalDatetimeUt
UPDATE logbook_reports SET value = JSONB_SET(value, '{predictedLandingDatetimeUtc}', TO_JSONB(TO_CHAR(NOW() AT TIME ZONE 'UTC' + INTERVAL '4 hours', 'YYYY-MM-DD"T"HH24:MI:SS"Z"')), true) WHERE id = 104;
UPDATE logbook_reports SET value = JSONB_SET(value, '{tripStartDate}', TO_JSONB(TO_CHAR(NOW() AT TIME ZONE 'UTC' - INTERVAL '10 hours', 'YYYY-MM-DD"T"HH24:MI:SS"Z"')), true) WHERE id = 104;

INSERT INTO logbook_reports (id, cfr, enriched, flag_state, integration_datetime_utc, log_type, operation_datetime_utc, operation_number, operation_type, report_datetime_utc, transmission_format, vessel_id, vessel_name, trip_gears, trip_segments, value) VALUES (105, 'CFR102', true, 'NLD', '2024-03-01T15:00:00', 'PNO', '2024-03-01T15:00:00', 'FAKE_OPERATION_105', 'DAT', '2024-03-01T15:00:00', 'ERS', 102, 'LEVE NEDERLAND', '[{"gear":"DHB","mesh":20.25,"dimensions":"500;500"},{"gear":"DRM","mesh":25.75,"dimensions":"1000;1000"}]', '[{"segment":"NWW03","segmentName":"Chalut de fond en eau profonde ≥100 mm"}]', '{"catchOnboard":[{"weight":25,"nbFish":null,"species":"FRF","faoZone":"27.8.a","effortZone":"C","economicZone":"FRA","statisticalRectangle":"23E6"}],"pnoTypes":[{"pnoTypeName":"Préavis type A","minimumNotificationPeriod":4,"hasDesignatedPorts":false},{"pnoTypeName":"Préavis type B","minimumNotificationPeriod":8,"hasDesignatedPorts":true}],"port":"FRVNE","predictedArrivalDatetimeUtc":"2024-03-01T17:00:00","predictedLandingDatetimeUtc":"2024-03-01T17:30:00","purpose":"LAN","tripStartDate":"2024-03-01T05:00:00"}');
INSERT INTO logbook_reports (id, cfr, enriched, flag_state, integration_datetime_utc, log_type, operation_datetime_utc, operation_number, operation_type, report_datetime_utc, transmission_format, vessel_id, vessel_name, trip_gears, trip_segments, value) VALUES (105, 'CFR102', true, 'NLD', '2024-03-01 15:00:00', 'PNO', '2024-03-01 15:00:00', 'FAKE_OPERATION_105', 'DAT', '2024-03-01 15:00:00', 'ERS', 102, 'LEVE NEDERLAND', '[{"gear":"DHB","mesh":20.25,"dimensions":"500;500"},{"gear":"DRM","mesh":25.75,"dimensions":"1000;1000"}]', '[{"segment":"NWW03","segmentName":"Chalut de fond en eau profonde ≥100 mm"}]', '{"catchOnboard":[{"weight":25,"nbFish":null,"species":"FRF","faoZone":"27.8.a","effortZone":"C","economicZone":"FRA","statisticalRectangle":"23E6"}],"pnoTypes":[{"pnoTypeName":"Préavis type A","minimumNotificationPeriod":4,"hasDesignatedPorts":false},{"pnoTypeName":"Préavis type B","minimumNotificationPeriod":8,"hasDesignatedPorts":true}],"port":"FRVNE","predictedArrivalDatetimeUtc":"2024-03-01T17:00:00Z","predictedLandingDatetimeUtc":"2024-03-01T17:30:00Z","purpose":"LAN","tripStartDate":"2024-03-01T05:00:00Z"}');
Original file line number Diff line number Diff line change
Expand Up @@ -214,12 +214,12 @@
"cfr": "CFR102",
"enriched": true,
"flag_state": "NLD",
"integration_datetime_utc": "2024-03-01T15:00:00",
"integration_datetime_utc": "2024-03-01 15:00:00",
"log_type": "PNO",
"operation_datetime_utc": "2024-03-01T15:00:00",
"operation_datetime_utc": "2024-03-01 15:00:00",
"operation_number": "FAKE_OPERATION_105",
"operation_type": "DAT",
"report_datetime_utc": "2024-03-01T15:00:00",
"report_datetime_utc": "2024-03-01 15:00:00",
"transmission_format": "ERS",
"vessel_id": 102,
"vessel_name": "LEVE NEDERLAND",
Expand Down Expand Up @@ -255,10 +255,10 @@
}
],
"port": "FRVNE",
"predictedArrivalDatetimeUtc": "2024-03-01T17:00:00",
"predictedLandingDatetimeUtc": "2024-03-01T17:30:00",
"predictedArrivalDatetimeUtc": "2024-03-01T17:00:00Z",
"predictedLandingDatetimeUtc": "2024-03-01T17:30:00Z",
"purpose": "LAN",
"tripStartDate": "2024-03-01T05:00:00"
"tripStartDate": "2024-03-01T05:00:00Z"
}
}
]
Expand Down

0 comments on commit 11f9cad

Please sign in to comment.