Press n or j to go to the next uncovered block, b, p or k for the previous block.
| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 | 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x | import {Status} from '@logchain/models/status';
import {RegulatoryDashboardsFilterFieldEnum} from '@logchain/types';
import {AnyObject} from '@loopback/repository';
export namespace Constants {
/**
* Default limit
*/
export const DefaultLimit = 100;
/**
* Default activities limit
*/
export const ActivitiesLimit = 20;
export const KILOBYTE = 1024;
/**
* Default role for new main contact.
*/
export const DefaultRole = 6;
/**
* Realm api
*/
export const ApiRealm = {
Public: 'Public',
Private: 'Private',
};
/**
* The constants for access
*/
export const Access = {
Denied: 0,
Allowed: 1,
};
/**
* The constants for access scopes
*/
export const AccessScope = {
Create: 'create',
Retrieve: 'retrieve',
Update: 'update',
Delete: 'delete',
Validate: 'validate',
Override: 'override',
Copy: 'copy',
};
/**
* The constants for action log
*/
export const ActionLabel = {
Create: 'created',
Retrieve: 'retrieved',
Update: 'updated',
Delete: 'deleted',
Validate: 'validated',
Override: 'override',
Copy: 'copied',
};
/**
* The map of email template.
*/
export const Email = {
// user
InformUserAfterDeactivate: 'inform-user-after-deactivate',
InformUserAfterDelete: 'inform-user-after-delete',
InformUserAfterCompletedDocumentRecord: 'inform-user-after-completed-document-record',
CompanyRegulatoryResponded: 'company-regulatory-responded',
InformUserAfterUpdateDuplicatedPhoneNumber: 'inform-user-after-update-duplicated-phone-number',
InformUserAfterApprovedDocument: 'inform-user-after-approved-document',
InformUserAfterRejectedDocument: 'inform-user-after-rejected-document',
// company
WelcomePartner: 'welcome-partner',
InformSupportTeamAfterPDFGenerationFailed: 'inform-support-team-after-pdf-generation-failed',
InformLogchainAdminAfterDeleteCompany: 'inform-logchain-admin-after-delete-company',
InformAdminOfCompanyAfterDeactivate: 'inform-admin-of-company-after-deactivate',
InformAdminOfCompanyAfterDeleteCompany: 'inform-admin-of-company-after-delete-company',
// request
InformProviderCompanyForNewRequest: 'inform-provider-company-for-new-request',
InformRequesterCompanyForRequestDenied: 'inform-requester-company-for-request-denied',
InformRequesterCompanyForQuoteSent: 'inform-requester-company-for-quote-sent',
InformProviderCompanyForQuoteDenied: 'inform-provider-company-for-quote-denied',
InformProviderCompanyForQuoteAccepted: 'inform-provider-company-for-quote-accepted',
// Flow Validation
InviteCompanyToValidateTheFlow: 'invite-company-to-validate-the-flow',
InformCompanyAfterFlowIsLive: 'inform-company-after-flow-is-live',
InformCompanyAfterFlowForValidationHasBeenRejected: 'inform-company-after-flow-for-validation-has-been-rejected',
InformCompanyAfterFlowIsRejected: 'inform-company-after-flow-is-rejected',
InformCompanyAfterFlowContainersAreAdded: 'inform-company-after-flow-containers-are-added',
InformCompanyAfterFlowContainersAreUpdated: 'inform-company-after-flow-containers-are-updated',
InformCompanyAfterFlowContainersAreDeleted: 'inform-company-after-flow-containers-are-deleted',
InformCompanyAfterFlowContainersAreRejected: 'inform-company-after-flow-containers-are-rejected',
InformCompanyAfterFlowIsValidated: 'inform-company-after-flow-is-validated',
InformCompanyAfterFlowIsUpdated: 'inform-company-after-flow-is-updated',
InformCompanyAfterFlowIsCompleted: 'inform-company-after-flow-is-completed',
InformCompanyAfterFlowValidationIsRejected: 'inform-company-after-flow-validation-is-rejected',
InformCompanyAfterFlowDeliveryIsUpdated: 'inform-company-after-flow-delivery-is-updated',
InformCompanyAfterFlowExpectedDatesIsUpdated: 'inform-company-after-flow-expected-dates-is-updated',
InformCompanyAfterFlowContainerNoIsUpdated: 'inform-company-after-flow-container-no-is-updated',
EM101: 'inform-company-after-feature-overriden-no-validation',
EM102: 'inform-company-after-feature-overriden-validation-approved',
EM103: 'inform-company-after-feature-overriden-validation-rejected',
EM121: 'inform-company-after-flow-action-is-completed',
// regulatory declaration
RegulatoryDeclarationProcessingError: 'regulatory-declaration-processing-error',
RegulatoryDeclarationFieldRequired: 'regulatory-declaration-field-required',
RegulatoryDeclarationIndicatorNeedsToBeTrue: 'regulatory-declaration-indicator-needs-to-be-true',
RegulatoryDeclarationSubmittedToCustoms: 'regulatory-declaration-submitted-to-customs',
RegulatoryDeclarationErrorFromCustoms: 'regulatory-declaration-error-from-customs',
RegulatoryDeclarationRejectedByCustoms: 'regulatory-declaration-rejected-by-customs',
RegulatoryDeclarationCancellationApproved: 'regulatory-declaration-cancellation-approved',
RegulatoryDeclarationApprovedByCustoms: 'regulatory-declaration-approved-by-customs',
InformUserProcessExpectedActionData: 'inform-user-process-expected-action-data',
InformUserProcessDueActionData: 'inform-user-process-due-action-data',
PreExpiryNotification: 'pre-expiry-notification',
ExpiryNotification: 'expiry-notification',
CompanyReferringAccessRevokedNotification: 'company-referring-access-revoked-notification',
};
/**
* The map of notification translation
*/
export const Notification = {
FlowActivated: 'flows.activated',
FlowIsLive: 'flows.isLive',
FlowIsUpdated: 'flows.isUpdated',
FlowIsCancelled: 'flows.isCancelled',
FlowIsValidated: 'flows.isValidated',
FlowIsCompleted: 'flows.isCompleted',
FlowIsLiveAndUpdated: 'flows.isLiveAndUpdated',
FlowContainersAreCancelled: 'flows.containersAreCancelled',
FlowValidationIsRejected: 'flows.validationIsRejected',
FlowExpectedDatesIsUpdated: 'flows.expectedDatesIsUpdated',
VerificationsAction: 'verifications',
VerificationsRejected: 'verifications_rejected',
VerificationsValidated: 'verifications_validated',
PdfCreationFailed: 'pdf_creation_failed',
CompanyRegulatoryResponded: 'company_regulatory_responded',
EM101: 'EM101',
EM102: 'EM102',
EM103: 'EM103',
EM121: 'EM121', // inform-company-after-flow-action-is-completed
PreExpiryNotification: 'pre_expiry_notification',
ExpiryNotification: 'expiry_notification',
Drop: 'scan_drop',
Receive: 'scan_receive',
Packing: 'scan_packing',
Packed: 'scan_packed',
Pickup: 'scan_pickup',
PickedUp: 'scan_picked_up',
Completed: 'scan_completed',
// Rejection
RejectPhysicalPartMismatch: 'scan_reject_physical_part_mismatch',
RejectEQLabelMismatch: 'scan_reject_eq_label_mismatch',
RejectEQLabelPhysicalMismatch: 'scan_reject_eq_label_physical_mismatch',
RejectOilLeak: 'scan_reject_oil_leak',
RejectPmoCancelled: 'scan_reject_pmo_cancelled_receive',
RejectOthers: 'scan_reject_others_receive',
RejectPackingCancelled: 'scan_reject_pmo_cancelled_packing',
RejectPackingOthers: 'scan_reject_others_packing',
RejectPackedCancelled: 'scan_reject_pmo_cancelled_packed',
RejectPackedOthers: 'scan_reject_others_packed',
RejectPickupPackingIssue: 'scan_reject_packing_issue_pickup',
RejectPickupCancelled: 'scan_reject_pmo_cancelled_pickup',
RejectPickupOthers: 'scan_reject_others_pickup',
RejectPickedUpCancelled: 'scan_reject_pmo_cancelled_picked_up',
RejectPickedUpOthers: 'scan_reject_others_picked_up',
};
// export const NotificationLinks: Record<string, string> = {
// drop: '/scan-code/receive-result',
// receive: '/scan-code/packing-result',
// packing: '/scan-code/packed-result',
// packed: '/scan-code/for-pickup-result',
// pickup: '/scan-code/picked-result',
// pickedUp: '/scan-code/completed-result',
// rejected: '/scan-code/rejected-result',
// };
/**
* The map of request persona with ID.
* The same with id in DB.personas
*/
export const RequestPersona = {
ISOTankDepot: 2,
ISOTankProvider: 3,
Shipper: 6,
TruckingCompany: 8,
};
/**
* The map of persona with ID.
* The same with id in DB.personas
*/
export const Persona = {
Consignee: 1,
Port: 4,
Railhead: 5,
ShippingLine: 7,
LogChain: 9,
Agent: 10,
BulkStorageTerminal: 11,
Carrier: 12,
FreightForwarder: 13,
...RequestPersona,
};
/* Persona Labels */
export const PersonaLabel = [
'',
'Consignee',
'ISO Tank Depot',
'Logistics Service Provider',
'Port',
'Railhead',
'Shipper',
'Shipping Line',
'Trucking Company',
'LogChain',
'Agent',
'Bulk Storage Terminal',
'Carrier',
'Freight Forwarder',
];
/**
* The map of document id.
* The same with id in DB.documents
*/
export const Documents = {
GateInChecklist: 1,
GateOutChecklist: 2,
WeighbridgeAttachment: 3,
};
/**
* The map of document id.
* The same with id in DB.documents
*/
export const WeighbridgeType = {
Form: 0,
Attachment: 1,
};
/**
* The map of Weighbridge Category Text.
*/
export const WeighbridgeCategory = {
WeighbridgeEntry: 0,
WeighbridgeExit: 1,
};
export const WeighbridgeCategoryText = ['Weighbridge Entry', 'Weighbridge Exit'];
/**
* The map of EIR document id.
* The same with id in DB.eirs
*/
export const EirDocumentType = {
Receipt: 0,
Additional: 1,
};
/**
* The map of Weighbridge Category Text.
*/
export const EirDocumentTypeText = ['Equipment Interchange Receipt.', 'Additional documents.'];
/**
* The map of BOL document id.
* The same with id in DB.eirs
*/
export const BolDocumentType = {
Report: 0,
Additional: 1,
};
/**
* The map of BOL document type Text.
*/
export const BolDocumentTypeText = ['Bill of Lading Report.', 'Additional documents.'];
/**
* Activity for Lift (action for ISO Tank)
*/
export const PlannedActivity = {
loading: 0,
heating_cooling: 1,
M_and_R: 2,
pickup_empty_clean: 3,
pickup_empty_dirty: 4,
pickup_full: 5,
cleaning: 6,
storage_empty: 7,
storage_full: 8,
};
/**
* Revoke CA Reason
* https://hyperledger-fabric-ca.readthedocs.io/en/master/users-guide.html?#revoking-a-certificate-or-identity
*/
export const RevokeReason = {
UnSpecified: '1',
KeyCompromise: '2',
CaCompromise: '3',
AffiliationChange: '4',
Superseded: '5',
CessationOfOperation: '6',
CertificateHold: '7',
RemoveFromCrl: '8',
PrivilegeWithdrawn: '9',
AaCompromise: '10',
};
/**
* Eir type.
* 0. Direct
* 1. Indirect
*/
export const EirType = {
Direct: 0,
Indirect: 1,
};
/**
* Eir type.
* 0. Direct
* 1. Indirect
*/
export const EirTypeText = ['Direct', 'Indirect'];
/**
* Step for flow.
*/
export const FlowStep = {
One: 1,
Two: 2,
Three: 3,
Four: 4,
Five: 5,
Six: 6,
};
/**
* UI Step For Flow Validation
*/
export const FlowValidationUIStep = {
One: 1,
Two: 2,
Three: 3,
};
/**
* Company privacy status
*/
export const PrivacyStatus = {
Public: 'Public',
Private: 'Private',
};
/**
* Entry record methods
* 0. Form
* 1. Attachment
*/
export const EntryRecordMethod = {
Form: 0,
Attachment: 1,
};
/**
* Entry Record type Status.
* 0. GateIn
* 1. GateOut
*/
export const EntryRecordType = {
GateIn: 0,
GateOut: 1,
};
/**
* Entry Record type Status.
* 0. GateIn
* 1. GateOut
*/
export const EntryRecordTypeText = ['Gate In', 'Gate Out'];
/**
* Entry Record Planned Activities.
* 0. Others
* 1. Loading
* 2. Unloading
* 3. Site Activities
*/
export const EntryRecordPlannedActivities = {
GateIn: 0,
GateOut: 1,
Unloading: 2,
SiteActivities: 3,
};
/**
* Loading Types.
* 0. Load Chemical
* 1. Unload Chemical
*/
export const LoadingType = {
LoadChemical: 0,
UnloadChemical: 1,
};
export const LoadingTypeText = ['Load Chemical', 'Unload Chemical'];
/**
* Lift Types.
* 0. Lift On
* 1. Lift Off
*/
export const LiftType = {
LiftOn: 0,
LiftOff: 1,
};
export const LiftTypeText = ['Lift On', 'Lift Off'];
/**
* OnLoading Types.
* 1. OnLoading
* 2. Offloading
*/
export const OnLoadingType = {
OnLoading: 1,
Offloading: 2,
};
export const OnLoadingTypeText = ['OnLoading', 'OnLoading', 'Offloading'];
/**
* Company other type.
* 0. Customer
* 1. Supplier
*/
export const CompanyOtherType = {
Customer: 0,
Supplier: 1,
};
/**
* The map of VesselType.
* The same with id in DB.vessels
*/
export const VesselType = {
Arrival: 0,
Departure: 1,
};
export const VesselTypeText = ['Arrival', 'Departure'];
/**
* The map of CargoType.
* The same with id in DB.cargos
*/
export const CargoType = {
Container: 1,
Package: 2,
};
export const CargoTypeText = ['Unknown', 'Container', 'Package'];
/**
* The map of CollarType.
* The same with id in DB.collar_types
*/
export const CollarType = {
All: 0,
Blue: 1,
White: 2,
};
export const CollarTypeText = ['All', 'Blue', 'White'];
/**
* The map of CategoryType.
* The same with id in DB.categories
*/
export const CategoryType = {
All: 0,
Company: 1,
ProcessTemplate: 2,
};
export const CategoryTypeText = ['All', 'Company', 'Process Template'];
/**
* The map of LicenceType.
* The same with id in DB.licences
* 0. All
* 1. Free
* 2. Subscription
*/
export const LicenceType = {
None: 0,
Free: 1,
Subscription: 2,
};
export const LicenceTypeText = ['None', 'Free', 'Subscription'];
/**
* The map of LicenceRate.
* The same with id in DB.licences
* 0. None
* 1. Monthly
* 2. Yearly
*/
export const LicenceRate = {
None: 0,
Monthly: 1,
Yearly: 2,
};
export const LicenceRateText = ['None', 'Monthly', 'Yearly'];
/**
* The map of CargoActionType.
* The same with id in DB.cargos
*/
export const CargoActionType = {
CargoCollection: 0,
CargoDelivery: 1,
};
export const VesselActionTypeText = ['Cargo Collection', 'Cargo Delivery'];
export const DGDActionText = 'DGD';
/**
* Form Id.
*/
export const Form = {
Document: 0,
LiftOn: 2,
GateIn: 3,
WeighbridgeEntry: 4,
LoadChemical: 5,
WeighbridgeExit: 6,
GateOut: 7,
EIR: 8,
LiftOff: 10,
ReheatTank: 11,
UnloadChemical: 12,
BOL: 13,
OnLoading: 14,
OffLoading: 15,
VesselArrival: 16,
VesselDeparture: 17,
CargoCollection: 18,
CargoDelivery: 19,
DGD: 20,
};
/**
* Form label.
*/
export const FormLabel = [
'Document',
'',
'Lift On',
'Gate In',
'Weighbridge Entry',
'Load Chemical',
'Weighbridge Exit',
'Gate Out',
'EIR',
'',
'Lift Off',
'Reheat Tank',
'Unload Chemical',
'BOL',
'On Loading',
'Off Loading',
'Vessel Arrival',
'Vessel Departure',
'Cargo Collection',
'Cargo Delivery',
'DGD',
];
/**
* Calista dropdown code values
*/
export const CalistaDropdownCode = {
ApplType: 'appl_type',
ApplProdType: 'appl_prod_type',
BgInd: 'bg_ind',
CarType: 'car_type',
CascCode: 'casc_code',
CertType: 'cert_type',
CnlReasonCode: 'cnl_reason_code',
Country: 'country',
CtPcCode: 'ct_pc_code',
CtnTypeSize: 'ctn_type_size',
CurrCode: 'curr_code',
DecType: 'dec_type',
EngCapPowerUom: 'eng_cap_power_uom',
InvTermType: 'inv_term_type',
LocCode: 'loc_code',
PackType: 'pack_type',
DocId: 'doc_id',
TptMode: 'tpt_mode',
VesselType: 'vessel_type',
QtyUom: 'qty_uom',
};
/**
* Country code for Regulatory Filing.
*/
export const CountryCode = {
Singapore: 'SG',
};
export const CalistaRouteId = {
Import: '2021072317445552',
Export: '2021071416484145',
};
export const doNotAllowedCopyFields: Record<string, boolean> = {
tot_dut_qty: true,
hs_qty: true,
dut_qty: true,
alcohol_percent: true,
in_house_ship_doc: true,
out_house_ship_doc: true,
};
export const defaultValuesForCopy: AnyObject = {
hs_code: ' ',
cty_origin: ' ',
hs_qty: '{}',
release_loc: '{}',
receipt_loc: '{}',
s3_uri: '/',
};
export const dynamicDateField: AnyObject = {};
dynamicDateField[RegulatoryDashboardsFilterFieldEnum.CREATED_DATE] = true;
dynamicDateField[RegulatoryDashboardsFilterFieldEnum.MODIFIED_DATE] = true;
export const fakePhoneNumber = '+1000000000';
export const allowedDocumentTypes = ['doc', 'docx', 'xls', 'xlsx'];
export const doNotDuplicatedPersonas = [Persona.Consignee, Persona.Shipper];
export const loadingFinishedStatuses = [Status.Loading.Cancelled, Status.Loading.Completed];
export const liftFinishedStatuses = [Status.Lift.Cancelled, Status.Lift.Completed];
export const onloadingFinishedStatuses = [Status.OnLoading.Cancelled, Status.OnLoading.Completed];
export const weighbridgeFinishedStatuses = [Status.Weighbridge.Cancelled, Status.Weighbridge.Completed];
export const documentFinishedStatuses = [Status.Document.Cancelled, Status.Document.Completed];
export const eirFinishedStatuses = [Status.Eir.Cancelled, Status.Eir.Completed];
export const bolFinishedStatuses = [Status.Bol.Cancelled, Status.Bol.Completed];
export const vesselFinishedStatuses = [Status.Vessel.Cancelled, Status.Vessel.Completed];
export const cargoFinishedStatuses = [Status.Cargo.Cancelled, Status.Cargo.Completed];
export const reheatingFinishedStatuses = [Status.Reheating.Cancelled, Status.Reheating.Completed];
export const dgdFinishedStatuses = [Status.DGD.Cancelled, Status.DGD.Completed];
export const ActionAfterCancelledText = [
'Unknown',
'Cancel & Continue Flow',
'Cancel & Stop Flow',
'Cancel & Create New Action',
];
/**
* Shipper
* Logistics Service Provider
* Freight Forwarder
*/
export const PersonasForSendingStep1 = [Persona.Shipper, Persona.ISOTankProvider, Persona.FreightForwarder];
/** Upon validation of a shipper (or shipper and Logistics Service Provider) then notification is sent to the rest of the persona with the flow that is not a trucking company
Agent (if any)
Bulk Storage Terminal (if any)
Carrier (if any)
Consignee (if any)
ISO Tank Depot (if any)
Port (if any)
Railhead (if any)
Shipping Line (if any)
*/
export const PersonasForSendingStep2 = [
Persona.Agent,
Persona.BulkStorageTerminal,
Persona.Consignee,
Persona.ISOTankDepot,
Persona.Port,
Persona.Railhead,
Persona.ShippingLine,
];
export const PersonasForSendingStep3 = [Persona.TruckingCompany, Persona.Carrier];
export const ModelsUsingCustomLog = [
'EntryRecord',
'Loading',
'Weighbridge',
'Lift',
'OnLoading',
'Eir',
'Bol',
'Company',
'CompanyPersona',
'Flow',
'Document',
'TradeLane',
];
export const TruckingPersonas = [Persona.TruckingCompany, Persona.Carrier];
export const PersonaIdForExternalFlowCreation = [
Persona.Consignee,
Persona.ISOTankDepot,
Persona.Port,
Persona.Railhead,
Persona.Shipper,
Persona.BulkStorageTerminal,
];
export const FormIdForExternalFlowCreation = [
Form.Document,
Form.LiftOn,
Form.GateIn,
Form.WeighbridgeEntry,
Form.LoadChemical,
Form.WeighbridgeExit,
Form.GateOut,
Form.LiftOff,
Form.ReheatTank,
Form.UnloadChemical,
Form.BOL,
Form.OnLoading,
Form.OffLoading,
Form.VesselArrival,
Form.VesselDeparture,
Form.CargoCollection,
Form.CargoDelivery,
Form.DGD,
];
export const CompanyActivityLabel = 'Company information';
export const CompanyPersonaLabel = 'Company Persona';
/**
* Locales
*/
export const LocaleText = {
en: 'English',
es: 'Español',
ja: '日本語',
zh: '中文(繁體)',
};
export const Locales = [
{lang: 'en', label: LocaleText.en},
{lang: 'es', label: LocaleText.es},
{lang: 'ja', label: LocaleText.ja},
{lang: 'zh', label: LocaleText.zh},
];
export const DefaultContainerInterval = 30;
export const MaxItemsForActionListInEmail = 500;
export const safety_data_sheet_label = 'Safety Data Sheet';
export const addendum_label = 'Addendum';
export const update_expected_dates_label = 'Update Expected Dates';
export const update_container_no_label = 'Update Container No';
export const cancel_container_no_label = 'Cancel Container No';
export const accepted_the_flow_action = 'ACCEPT';
export const accepted_the_flow_action_label = 'validated the flow';
export const rejected_the_flow_action = 'REJECT';
export const rejected_the_flow_action_label = 'rejected the flow';
export const action_data_status_text = {
[Status.Document.New]: 'New',
[Status.Document.InProgress]: 'In Progress',
[Status.Document.Cancelled]: 'Cancelled',
[Status.Document.Completed]: 'Completed',
};
export const report_filter_live_status_text = {
[Status.LiveStatus.New]: 'New',
[Status.LiveStatus.InTransit]: 'In Transit',
[Status.LiveStatus.Rejected]: 'Rejected',
[Status.LiveStatus.Completed]: 'Completed',
};
export const flow_status_text = {
[Status.Flow.New]: 'New',
[Status.Flow.InProgress]: 'In Progress',
[Status.Flow.Inactive]: 'Inactive',
[Status.Flow.ForValidation]: 'For Validation',
[Status.Flow.Validated]: 'Validated',
[Status.Flow.Rejected]: 'Rejected',
[Status.Flow.Live]: 'Live',
};
export const validation_status_text = {
[Status.Verification.ForValidation]: 'Pending Validation',
[Status.Verification.Validated]: 'Rejected',
[Status.Verification.Rejected]: 'Validated',
[Status.Verification.ValidationNotNeeded]: 'Validation Not Needed',
};
export const personas_allowed_validated_by_flow_owner = [
Persona.Agent,
Persona.ISOTankProvider,
Persona.FreightForwarder,
Persona.ShippingLine,
Persona.Consignee,
Persona.Port,
Persona.Shipper,
Persona.ISOTankDepot,
Persona.BulkStorageTerminal,
];
export const remarks_behalf_of_the_validation = 'Job {0} has been accepted by {1} on your behalf.';
export const personas_can_create_flow = [Persona.Shipper, Persona.ISOTankProvider, Persona.FreightForwarder];
export const forms_have_expected_weight = [
Form.LoadChemical,
Form.UnloadChemical,
Form.LiftOn,
Form.LiftOff,
Form.OffLoading,
Form.OnLoading,
];
export const forms_have_vessel_data = [Form.VesselArrival, Form.VesselDeparture];
export const response1009_for_update_xml = 'Container No not in the platform or not on any active flow.';
export const cmd_qpdf = './bin/qpdf-11.9.0-bin-linux-x86_64/bin/qpdf';
export const table2links: AnyObject = {
entry_records: 'intermodal/entries/in/{id}',
documents: 'compliance/document-detail/{id}',
loadings: 'intermodal/loading-detail/{id}',
onloadings: 'intermodal/on-loading-detail/{id}',
lifts: 'intermodal/load-unload/{id}',
weighbridges: 'intermodal/weighbridge-detail/{id}',
eirs: 'intermodal/eir-detail/{id}',
bols: 'intermodal/bol-detail/{id}',
transports: 'requests/Current%20Transport%20List-detail/{id}',
vessels: 'intermodal/vessel-detail/{id}',
dgds: 'intermodal/dgd-detail/{id}',
cargoes: 'intermodal/cargo-detail/{id}',
};
export const sutton_xml_path = 'suttons/xml/';
export const error_message_duplicated_container_no = 'Container no should be unique within the same flow.';
export const xml_updated_fields_mapping: AnyObject = {
'<FrPlanDchDate>': '<tt-edi-sect>.<PlanFrDate>',
'<FrPlanLdgDate>': '<tt-edi-sect>.<PlanFrDate>',
'<ToPlanDchdate>': '<tt-edi-sect>.<PlanToDate>',
'<ToPlanLdgDate>': '<tt-edi-sect>.<PlanToDate>',
'<tt-edi-vessel>.<DchPort-Date>': '<tt-edi-sect>.<UnLoadedVesselDate>',
'<tt-edi-vessel>.<LdgPort-Date>': '<tt-edi-sect>.<LoadedVesselDate>',
'<tt-edi-vessel>.<PlanFrDate>': '<tt-edi-sect>.<PlanFrDate>',
'<tt-edi-vessel>.<PlanToDate>': '<tt-edi-sect>.<PlanToDate>',
};
export const xml_updated_fields_using_sect = [
'<tt-edi-vessel>.<DchPort-Date>',
'<tt-edi-vessel>.<LdgPort-Date>',
'<tt-edi-vessel>.<PlanFrDate>',
'<tt-edi-vessel>.<PlanToDate>',
];
export const xml_updated_fields = [
'<FrPlanDchDate>',
'<FrPlanLdgDate>',
'<ToPlanDchdate>',
'<ToPlanLdgDate>',
'<tt-edi-vessel>.<DchPort-Date>',
'<tt-edi-vessel>.<LdgPort-Date>',
'<tt-edi-vessel>.<PlanFrDate>',
'<tt-edi-vessel>.<PlanToDate>',
];
export const ReportType: AnyObject = {
MasterReport: 1,
};
export const FooterText: AnyObject = {
CompletedNoValidator: '{0} & no validation needed. Action by {1} on {2}.',
CompletedWithValidator: '{0} & pending validation. Action by {1} on {2}. File pending validation by {3}.',
ValidatedWithValidator:
"{0} action by {1} on {2}. File validated by {3} on {2}. Previous versions of this document exist and they should be considered invalid. Newer versions of this document may exist, you can check verify this document's current status online in the LogChain platform.",
RejectedWithValidator: 'Action by {0} on {1}. File rejected by {2} on {1}.',
};
export const systemActions: string[] = [
'Safety Data Sheet',
'Cancel Container No',
'Update Expected Dates',
'Update Container No',
];
export const errorMessage: AnyObject = {
'no-licence-for-user':
'Access denied. Your company’s subscription has expired or is inactive. Please contact your administrator for more details.',
'no-licence-for-admin':
'Your company’s licence subscription has expired or is inactive. Please contact LogChain to renew your subscription or activate your plan.',
'blue-users-limit-reached': 'Allowed active blue collar user limit has been reached for this company’s license.',
'white-users-limit-reached': 'Allowed active white collar user limit has been reached for this company’s license.',
};
export const link2CompanyDetail: AnyObject = {
companies: 'admin/company',
};
}
|