Inhalte aufrufen

Profilbild

Can a Plugin create DB tables?


  • Bitte melden Sie sich an, um eine Antwort zu verfassen.
2 Antworten zu diesem Thema

#1 Amr

Amr

    Newbie

  • Members
  • Punkt
  • 7 Beiträge

Geschrieben: 29 August 2019 - 10:51

Hey again,

 

 

I am in the final step of making my payment gateway plugin and I need to store some id's given by the gateway to be cross referenced

when checking the gateway for the payment status

 

Is there is way to do this in the plugin it self or do i need to modify the core project?

 



#2 Marcus Gesing

Marcus Gesing

    SmartStore AG

  • Administrators
  • 3801 Beiträge

Geschrieben: 29 August 2019 - 13:38

Yes, you can create database tables. But in most cases it's easier and faster to use built-in capabilities like SyncMapping, GenericAttibute etc. for it.

Data in checkout is volatile, it's better to use a session object for it, not the database. Payment IDs from your payment provider can also be stored in Order.AuthorizationTransactionId, Order.AuthorizationTransactionCode, and Order.CaptureTransactionId to later interact with the payment API.

  • Lighthouse gefällt das

Marcus Gesing

Smartstore AG


#3 Amr

Amr

    Newbie

  • Members
  • Punkt
  • 7 Beiträge

Geschrieben: 30 August 2019 - 12:17

thank you 

 

this was really helpful