Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes from latest report #93

Merged
merged 317 commits into from
May 14, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
317 commits
Select commit Hold shift + click to select a range
1900daa
remove colon
andreasantillana Dec 29, 2016
3ab9eda
Passing the error message to the display section
Jan 2, 2017
9d828c6
remove fiscal entity
andreasantillana Jan 2, 2017
dbe57da
grab price as shown
andreasantillana Jan 2, 2017
4fcfeb2
Adding all error in to url
Jan 3, 2017
862566f
Sending all error messages in URL in order to allow the template to d…
Jan 3, 2017
d0eea12
add empty files
andreasantillana Jan 4, 2017
7454800
Merge pull request #30 from conekta/fix/error-display
andreasantillana Jan 4, 2017
5e03d3a
Event signature authentication added
Jan 5, 2017
310891f
Merge pull request #31 from conekta/feature/rsa-signature
andreasantillana Jan 9, 2017
0ae9a4d
Merge pull request #29 from conekta/fix/minor-fixes-1.1
andreasantillana Jan 9, 2017
0577e7e
add soft validation for customer info
andreasantillana Jan 11, 2017
4118cf4
Merge pull request #33 from conekta/fix/phone-soft-validation
Jan 11, 2017
d69169a
add tax lines and new amount calculation
andreasantillana Jan 12, 2017
3d22aa0
Merge pull request #34 from conekta/fix/fix-order-amount
Jan 12, 2017
397dc77
use downloadable when virtual
andreasantillana Jan 12, 2017
ba91869
Merge pull request #35 from conekta/fix/line-items-type
Jan 12, 2017
5adb936
Updating discount lines for version 2.0
Jan 30, 2017
cd5c21f
upgrade library
andreasantillana Jan 30, 2017
6d03110
use 2.0.0 and fix discounts
andreasantillana Jan 30, 2017
e69a7d2
add fiscal entity
andreasantillana Jan 30, 2017
184ebee
Merge pull request #36 from conekta/feature/discount-lines
MauricioMurga Feb 2, 2017
8f00c21
Merge pull request #37 from conekta/feature/error-adaptation
MauricioMurga Feb 2, 2017
44500ca
Merge branch 'dev' into feature/upgrade-1.1
MauricioMurga Feb 2, 2017
64b5fb6
Merge pull request #10 from conekta/feature/upgrade-1.1
MauricioMurga Feb 2, 2017
03440eb
update conekta-php
Feb 2, 2017
967d5d8
version bump
Feb 2, 2017
ab6b1b5
Fixing error string concatenation
Feb 2, 2017
dc82eb7
Merge pull request #38 from conekta/fix/prestashop-errors
MauricioMurga Feb 2, 2017
009053f
Updating Prestashop lib, and sky issue
Feb 15, 2017
da5afb7
Merge pull request #40 from conekta/fix/sku-issue
MauricioMurga Feb 15, 2017
2a105e9
Removing code bar, modifying payment_source to payment_method
Feb 15, 2017
8c2a99d
Removing fiscal entity. Updating Oxxo Pay text in frontend
Feb 15, 2017
ef0264f
Reinserting reference for OxxoPay
Feb 15, 2017
567faf5
Upgrading PHP lib
Feb 15, 2017
b766d9f
Merge pull request #41 from conekta/fix/removing-codebar
MauricioMurga Feb 16, 2017
c84a9b1
Making description optional if it is less than two characters short.
Feb 22, 2017
2d0c3ec
Removing banorte as a payment method option
Feb 22, 2017
29904bc
Merge pull request #42 from conekta/fix/item-description
MauricioMurga Feb 23, 2017
aaec6c1
Merge pull request #43 from conekta/feature/remove-banorte
MauricioMurga Feb 23, 2017
d5adac1
Updating OXXO Pay Visual Elements
Feb 24, 2017
5411afb
Updating administrator options for OxxoPay
Feb 24, 2017
0bc12bf
Merge pull request #44 from conekta/feature/oxxo-pay-update
MauricioMurga Feb 24, 2017
e8ad120
Fixing webhooks implementation
Mar 10, 2017
6887917
Merge pull request #46 from conekta/fix/webhooks
MauricioMurga Mar 10, 2017
7ee137f
This fix verifies the data information before proceeding to do any op…
Mar 10, 2017
8b212bb
Version bump
Mar 10, 2017
f6cf3b2
Merge pull request #47 from conekta/fix/webhook-ping
Mar 10, 2017
3c421e8
fix monthly installments
andreasantillana Mar 16, 2017
42e9223
Merge pull request #48 from conekta/fix/monthly-installments
Mar 16, 2017
1b26523
Fixing monthly installments bug. Version bump.
Apr 7, 2017
42342e6
Merge pull request #50 from conekta/fix/installments
andreasantillana Apr 7, 2017
ddbd5b4
webhook validation
Jun 6, 2017
f20378b
trnaslation change mail error fix
Jun 6, 2017
773b578
Merge pull request #53 from conekta/bugfix/webhook-validation
andreasantillana Jun 7, 2017
8b45e0f
Merge pull request #54 from conekta/dev
andreasantillana Jun 7, 2017
b64e0c7
version bump
Jun 12, 2017
03a17fb
version bump
Jun 12, 2017
f704ed6
Create CHANGELOG
Jun 12, 2017
c7f3476
Merge pull request #55 from conekta/bugfix/webhook-validation
Jun 12, 2017
ee45664
Fix oxxopay error
JoValo Jun 16, 2017
a17bae6
Merge pull request #56 from conekta/feature/josserfixes
luiscarlos-gonzalez Jun 20, 2017
ba56d6b
Version bump
JoValo Jun 21, 2017
5dbb7df
Merge pull request #58 from conekta/feature/jossfixes
Jun 21, 2017
e746928
Merge pull request #59 from conekta/dev
Jun 30, 2017
d596bd8
Dev (#66)
JoValo Aug 3, 2017
0f1efd1
Feature/headers prestashop (#68) (#69)
JoValo Aug 16, 2017
30265f0
Update PHP Library
JoValo Aug 16, 2017
af101f0
Merge pull request #70 from conekta/feature/update-php-library
Aug 16, 2017
445b52f
Merge pull request #71 from conekta/dev
JoValo Aug 16, 2017
2466dc4
Prestashop 1.7 update
Aug 17, 2017
1c57bb4
Update README.md
Aug 17, 2017
4b888e7
Versión Update
KarlaRobinson Aug 22, 2017
4582998
Certificates update with public CA
JoValo Aug 23, 2017
30e376f
Version bump
JoValo Aug 23, 2017
80f8f71
standardize changelog
Sep 6, 2017
95b186d
Merge pull request #74 from conekta/feature/std_changelog
KarlaRobinson Sep 6, 2017
f0fe3e4
Docs: Delete unused changelog
JoValo Sep 8, 2017
e1bdf83
Merge pull request #73 from conekta/feature/ca-bundle
Sep 8, 2017
185fda8
Docs: Version bump
JoValo Sep 9, 2017
c26bf42
Merge pull request #75 from conekta/feature/version-bump
JoValo Sep 9, 2017
046a043
Fix in orders with discounts without code
Apr 12, 2018
a577b1d
Merge pull request #78 from Rolige/patch-1
Apr 13, 2018
acd80fe
Feature: PHP lib update
Apr 25, 2018
4d4ffcd
Merge pull request #81 from conekta/feature/lib-update
Apr 25, 2018
5ef587d
Feature: Fix webhook
Apr 25, 2018
f8d5cd7
Merge pull request #82 from conekta/feature/webhook-fix
Apr 25, 2018
005625e
first commit
LucianoPSerfe Nov 19, 2020
ebb8f4e
adding magento credentials in readme
Nov 26, 2020
0ee71ef
adding folders
Nov 26, 2020
27c31c5
adding --user root
Nov 26, 2020
4f4aa2e
updated
Nov 26, 2020
2337af2
changing linio for conekta
Nov 26, 2020
685d737
changing more linio for conekta
Nov 26, 2020
8a69301
changing title
Nov 26, 2020
274a799
more changes in readme
Nov 26, 2020
335cb21
added permissions commands
Nov 27, 2020
219fd40
0079705 - Added inputs fields and validations
Dec 11, 2020
8daf97a
0079705 - small change
Dec 11, 2020
534c214
Merge branch 'development' of git.serfe.com:project/conekta-prestasho…
Dec 15, 2020
7155e46
0079705 - file to handle styles in conekta prestasho settings
Dec 15, 2020
3303a18
Merge branch '0079705-t-i1-prestashop-cap-payment-time-for-oxxo-payme…
Dec 15, 2020
e71c28d
Revert "0079705 - file to handle styles in conekta prestasho settings"
Dec 15, 2020
c61fa3a
0079705 - Edit on notification.php
Dec 15, 2020
d1a4aad
0079705 - conekta prestashop files added
Dec 15, 2020
d36c2a7
Merge branch '0079705-t-i1-prestashop-cap-payment-time-for-oxxo-payme…
Dec 15, 2020
cd189be
0079705 - Task done
Dec 15, 2020
33a3612
Merge branch '0079705-t-i1-prestashop-cap-payment-time-for-oxxo-payme…
Dec 15, 2020
365062f
0079705 - Task done
Dec 15, 2020
5df8905
Merge branch '0079705-t-i1-prestashop-cap-payment-time-for-oxxo-payme…
Dec 15, 2020
c9c5daf
update wit development
Dec 28, 2020
f627313
delete prestashop folder from conekta plugin
Dec 29, 2020
6d0d02c
0080936 - send order id as metadata to conekta panel
Dec 31, 2020
cf5a2f5
Merge branch '0080936-t-i2-prestashop-send-order-id-as-metadata-inste…
Dec 31, 2020
9d8ad4b
0080616 - Get event refunded or canceled from conekta api and change …
Jan 11, 2021
55986fb
0080936 - send cart id
Jan 12, 2021
803f6be
0080616 - Change order status from conekta event
Jan 12, 2021
2e960f0
Merge branch '0080936-t-i2-prestashop-send-order-id-as-metadata-inste…
Jan 12, 2021
886de41
Merge branch 'development' of git.serfe.com:project/conekta-prestasho…
Jan 12, 2021
f2ca5c5
0080936 - get order by cart id
Jan 13, 2021
e196951
Merge branch '0080936-t-i2-prestashop-send-order-id-as-metadata-inste…
Jan 13, 2021
6739516
0080616 - Pulling from dev
Jan 13, 2021
bf4a898
0080616 - Standard refund done
Jan 15, 2021
07c6175
0080616 - Standard refund done
Jan 19, 2021
287b855
merge changes
LucianoPSerfe Jan 22, 2021
ce29747
merge and update branches
LucianoPSerfe Jan 22, 2021
b7a169e
Merge branch 'master' into 'development'
LucianoPSerfe Feb 11, 2021
8512144
0082128: [T][I3][Prestashop] - Habilitar guardado de tarjetas
lucianon-serfe Mar 1, 2021
7704998
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 1, 2021
590651a
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 1, 2021
4a7c879
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 1, 2021
2433a44
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 1, 2021
87fb2ff
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 1, 2021
47146bf
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 1, 2021
1236451
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 1, 2021
dea2d52
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 1, 2021
8f243aa
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 1, 2021
358c3b9
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
a4c7e51
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
032d4bd
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
2f5b9f5
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
2f312d8
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
2358e8d
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
a66d253
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
0c430f2
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
fc8252c
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
c8cfdeb
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
2d9cc03
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
a81c5d0
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
708c9ce
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
1e60f8a
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
886a100
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
b7371b8
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
1f3eb9e
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
923ff88
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
67b366d
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
d059193
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
9dc7525
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
b26d924
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
ecb6237
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
ac2c082
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
ca59f19
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
3a67855
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
65a1318
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
6a7fa61
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
dd090ec
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
bad3a6b
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 2, 2021
2a0e02c
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 3, 2021
ba5fda3
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 3, 2021
50d491c
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 3, 2021
25fbdab
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 3, 2021
21a3442
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 3, 2021
57de0e6
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 3, 2021
40b7273
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 3, 2021
d52773e
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 3, 2021
917b958
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 3, 2021
9e9275d
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 3, 2021
3ea5cc6
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 3, 2021
7849a16
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 3, 2021
c5e1e0d
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 3, 2021
0bcbd32
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 4, 2021
eb2d116
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 4, 2021
fe6e970
0082128 - Conekta checkout integration
lucianon-serfe Mar 5, 2021
dce5d02
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 5, 2021
868d924
codacy stage PR
lucianon-serfe Mar 8, 2021
238e196
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 8, 2021
cd37718
82773 additional metadata information sending was implemented
federicoh-serfe Mar 8, 2021
268a2bb
0082449: [T][Prestashop] Codacy check
lucianon-serfe Mar 8, 2021
1be9c1a
Merge pull request #2 from lucianon-serfe/serfe-stage
lucianon-serfe Mar 8, 2021
ecbede7
82773 metadata cap was implemented
federicoh-serfe Mar 9, 2021
b16eb98
82773 attribute cap changed from 5 to 12
federicoh-serfe Mar 11, 2021
bb9e733
attribute limit read from a constant value
federicoh-serfe Mar 11, 2021
b653dbb
Merge branch '82773-elegir-datos-para-enviar-en-metadatos' into 'deve…
leandro-serfe Mar 12, 2021
137c5ea
82128 - Integration of the conekta form with Prestashop
lucianon-serfe Mar 12, 2021
7e3f7b2
82128 - The payment workflow changed.
lucianon-serfe Mar 18, 2021
42ef9e1
82128 - The payment workflow changed.
lucianon-serfe Mar 19, 2021
3bb69af
82128 - Enable card save
lucianon-serfe Mar 26, 2021
426ce6d
82128 - Enable card save
lucianon-serfe Mar 26, 2021
3d4205a
82773 metadata sending adapted
federicoh-serfe Mar 29, 2021
263c4af
83539 - Admin checkbox issue resolved
lucianon-serfe Mar 30, 2021
e32a17c
Merge branch '0083539-prestashop-no-devuelve-el-valor-de-on-demand-en…
lucianon-serfe Mar 30, 2021
30bb664
83578 - detect purchases with amounts less than $ 20
lucianon-serfe Mar 31, 2021
4059f86
83578 - Minimum purchase amount warning message added.
lucianon-serfe Apr 1, 2021
9a7cce9
Merge branch '0083578-prestashop-falla-formulario-con-ordenes-menores…
lucianon-serfe Apr 5, 2021
deefd11
83662 - added tax lines in order details
lucianon-serfe Apr 6, 2021
d3cafea
Merge branch '82773-elegir-datos-para-enviar-en-metadatos' into 'deve…
LucianoPSerfe Apr 6, 2021
efe81fc
83819 - the incorporation of the shipping lines in the order was impr…
lucianon-serfe Apr 8, 2021
84baa45
83932 - add metadata of the plugin name and version
lucianon-serfe Apr 12, 2021
873b4a3
fixed issue of the incorrect added attribute
lucianon-serfe Apr 12, 2021
db7822d
Merge branch 'development' of git.serfe.com:project/conekta-prestasho…
lucianon-serfe Apr 12, 2021
537eb94
83308 - create checkbox to enable 3ds
lucianon-serfe Apr 14, 2021
eafd6e0
84000 - Added column in the database type mode
lucianon-serfe Apr 14, 2021
d7670b8
Merge branch '83932-prestashop-identificar-plugin-prestashop-en-las-t…
gaston-serfe Apr 19, 2021
9c6ca3a
83308 - Added the 3ds checkbox in the prestashop admin
lucianon-serfe Apr 19, 2021
c2cb6b2
Merge branch 'development' of git.serfe.com:project/conekta-prestasho…
lucianon-serfe Apr 19, 2021
dad0f67
84000 - fix the bug create duplicated order
lucianon-serfe Apr 20, 2021
cf35663
84000 - fix the bug create duplicated order
lucianon-serfe Apr 20, 2021
a6a48d9
merge with development
gaston-serfe Apr 23, 2021
3d888e6
Merge branch '0083662-no-incluye-los-tax-lines-en-el-resumen-de-pago'…
gaston-serfe Apr 23, 2021
b52b9a2
84386 - correction following the code standard
lucianon-serfe Apr 23, 2021
163428f
merge and update branches
lucianon-serfe Apr 23, 2021
4f4b95d
merge and update branches
lucianon-serfe Apr 23, 2021
bb69cd8
merge and update branches
lucianon-serfe Apr 23, 2021
6d1c668
Merge branch '83308-t-i3-s17-prestashop-implementar-soporte-de-3ds' i…
gaston-serfe Apr 23, 2021
34e6bec
84386 - correction following the code standard
lucianon-serfe Apr 23, 2021
5b9f1e6
merge and update branches
lucianon-serfe Apr 23, 2021
8a72570
merge with development
gaston-serfe Apr 23, 2021
6971cdd
84386 - correction following the code standard
lucianon-serfe Apr 26, 2021
bb6406e
84386 - correction following the code standard
lucianon-serfe Apr 26, 2021
df82068
80198- fixed issue with merge
gaston-serfe Apr 26, 2021
dd9447b
80198- recovered missing change on merge
gaston-serfe Apr 26, 2021
909e101
80198- added missing drop table required
gaston-serfe Apr 26, 2021
32a5e2d
Merge branch '84000-no-hay-diferencia-entre-ids-de-produccion-y-prueb…
gaston-serfe Apr 27, 2021
5f90acc
84386 - correction following the code standard
lucianon-serfe Apr 27, 2021
4fd85d5
84386 - Merge, update and code standardin branch
lucianon-serfe Apr 27, 2021
64d0245
Merge branch '84386-t-i5-s19-prestashop-revisar-y-correcion-segun-el-…
gaston-serfe Apr 27, 2021
b276efa
84386 - correction according to psr-2 standard
lucianon-serfe Apr 29, 2021
02335d6
Merge branch 'master' of https://github.com/conekta/conekta_prestashop
lucianon-serfe May 3, 2021
87ca641
84628 - Merge and update branch
lucianon-serfe May 3, 2021
61861c6
Merge branch '84386-t-i5-s19-prestashop-revisar-y-correcion-segun-el-…
gaston-serfe May 3, 2021
4d24731
84628 - Merge and update branch
lucianon-serfe May 3, 2021
4c4e497
84628 - Merge and update branch
lucianon-serfe May 3, 2021
1d37294
84628 - Merge and update branch
lucianon-serfe May 3, 2021
7e6bfde
Merge branch '84628-t-i5-s19-prestashop-correcion-de-conflictos-de-re…
gaston-serfe May 4, 2021
b89b57b
85085- updated instalation guide
gaston-serfe May 14, 2021
af0390f
85085- fixed issues reported
gaston-serfe May 14, 2021
6e3b29d
85085- implemented other fixes required
gaston-serfe May 14, 2021
cc9c8a5
Update README.md
gaston-serfe May 14, 2021
2b7f4a5
merge with conekta master
gaston-serfe May 14, 2021
211fec0
Merge branch 'serfe-stage' of github.com:gaston-serfe/conekta_prestas…
gaston-serfe May 14, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Current version features:
Installation
-----------

Clone the module using git clone --recursive [email protected]:conekta/conektapaymentsprestashop.git
Clone the module using <pre>git clone --recursive [email protected]:conekta/conekta_prestashop.git ./conektapaymentsprestashop</pre>

There is no custom installation for this plugin, just the default:

Expand Down
52 changes: 27 additions & 25 deletions conektapaymentsprestashop.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,20 +10,20 @@
*
* ConektaPaymentsPrestashop File Doc Comment
*
* @category ConektaPaymentsPrestashop
* @package ConektaPaymentsPrestashop
* @author Conekta <[email protected]>
* @copyright 2012-2019 Conekta
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
* @category ConektaPaymentsPrestashop
* @package ConektaPaymentsPrestashop
* @version GIT: @1.1.0@
* @link https://conekta.com/
*/

use PrestaShop\PrestaShop\Core\Payment\PaymentOption;

require_once __DIR__ . '/model/Config.php';
require_once __DIR__ . '/model/Database.php';
require_once __DIR__ . '/lib/conekta-php/lib/Conekta.php';
require_once dirname(__FILE__) . '/model/Config.php';
require_once dirname(__FILE__) . '/model/Database.php';
require_once dirname(__FILE__) . '/lib/conekta-php/lib/Conekta.php';

if (!defined('_PS_VERSION_')) {
exit;
Expand Down Expand Up @@ -94,11 +94,11 @@ public function __construct()
);
$order_elements = array_keys(get_class_vars('Cart'));
foreach ($order_elements as $element) {
$settings[] = 'ORDER_'.strtoupper($element);
$settings[] = 'ORDER_'.Tools::strtoupper($element);
}
$product_elements = self::CART_PRODUCT_ATTR;
foreach ($product_elements as $element) {
$settings[] = 'PRODUCT_'.strtoupper($element);
$settings[] = 'PRODUCT_'.Tools::strtoupper($element);
}

$config = Configuration::getMultiple($settings);
Expand Down Expand Up @@ -478,6 +478,7 @@ public function hookHeader()
\Conekta\Conekta::setApiKey($key);
\Conekta\Conekta::setPlugin("Prestashop1.7");
\Conekta\Conekta::setApiVersion("2.0.0");
\Conekta\Conekta::setLocale($iso_code);

if (Tools::getValue('controller') != 'order-opc' && (!($_SERVER['PHP_SELF'] == __PS_BASE_URI__ . 'order.php' || $_SERVER['PHP_SELF'] == __PS_BASE_URI__ . 'order-opc.php' || Tools::getValue('controller') == 'order' || Tools::getValue('controller') == 'orderopc' || Tools::getValue('step') == 3))) {
return;
Expand Down Expand Up @@ -513,7 +514,7 @@ public function hookHeader()
array_push($payment_options, 'card');
}

$msi = false;
// $msi = false;
$force_3ds = false;
$on_demand_enabled = false;
$address_delivery = new Address((int) $cart->id_address_delivery);
Expand All @@ -537,7 +538,7 @@ public function hookHeader()
}

$shippingContact = Config::getShippingContact($customer, $address_delivery, $state, $country);
$customerInfo = Config::getCustomerInfo($customer, $address_delivery);
$customerInfo = Config::getCustomerInfo($customer);

$result = Database::getConektaMetadata($customer->id, $this->conekta_mode, "conekta_customer_id");

Expand Down Expand Up @@ -591,7 +592,7 @@ public function hookHeader()

$order_elements = array_keys(get_class_vars('Cart'));
foreach ($order_elements as $element) {
if (!empty(Configuration::get('ORDER_'.strtoupper($element))) && property_exists($this->context->cart, $element)) {
if (!empty(Configuration::get('ORDER_'.Tools::strtoupper($element))) && property_exists($this->context->cart, $element)) {
$order_details['metadata'][$element] = $this->context->cart->$element;
}
}
Expand All @@ -601,13 +602,13 @@ public function hookHeader()
$index ='product-'.$item['id_product'];
$order_details['metadata'][$index] = '';
foreach ($product_elements as $element) {
if (!empty(Configuration::get('PRODUCT_'.strtoupper($element)))
if (!empty(Configuration::get('PRODUCT_'.Tools::strtoupper($element)))
&& array_key_exists($element, $item)
) {
$order_details['metadata'][$index] .= $this->buildRecursiveMetadata($item[$element], $element);
}
}
$order_details['metadata'][$index] = substr($order_details['metadata'][$index], 0, -2);
$order_details['metadata'][$index] = Tools::substr($order_details['metadata'][$index], 0, -2);
}

$amount = 0;
Expand Down Expand Up @@ -715,18 +716,18 @@ public function buildRecursiveMetadata($data_object, $key)
$string = '';
if (gettype($data_object) == 'array') {
foreach (array_keys($data_object) as $data_key) {
$key_concat = strval($key).'-'.strval($data_key);
$key_concat = (string)($key).'-'.(string)($data_key);
if (empty($data_object[$data_key])) {
$string .= strval($key_concat) . ': NULL | ';
$string .= (string)($key_concat) . ': NULL | ';
} else {
$string .= $this->buildRecursiveMetadata($data_object[$data_key], $key_concat);
}
}
} else {
if (empty($data_object)) {
$string .= strval($key) . ': NULL | ';
$string .= (string)($key) . ': NULL | ';
} else {
$string .= strval($key) . ': ' . strval($data_object) . ' | ';
$string .= (string)($key) . ': ' . (string)($data_object) . ' | ';
}
}
return $string;
Expand Down Expand Up @@ -860,15 +861,15 @@ private function postValidation()
$i = 0;
$attributes_count = 0;
while ($i < count($order_elements) && $attributes_count <= METADATA_LIMIT) {
if (!empty(Tools::getValue('ORDER_'.strtoupper($order_elements[$i])))) {
if (!empty(Tools::getValue('ORDER_'.Tools::strtoupper($order_elements[$i])))) {
$attributes_count++;
}
$i++;
}
$i = 0;
$product_elements = self::CART_PRODUCT_ATTR;
while ($i < count($product_elements) && $attributes_count <= METADATA_LIMIT) {
if (!empty(Tools::getValue('PRODUCT_'.strtoupper($product_elements[$i])))) {
if (!empty(Tools::getValue('PRODUCT_'.Tools::strtoupper($product_elements[$i])))) {
$attributes_count++;
}
$i++;
Expand Down Expand Up @@ -923,11 +924,11 @@ private function postProcess()

$order_elements = array_keys(get_class_vars('Cart'));
foreach ($order_elements as $element) {
Configuration::updateValue('ORDER_'.strtoupper($element), Tools::getValue('ORDER_'.strtoupper($element)));
Configuration::updateValue('ORDER_'.Tools::strtoupper($element), Tools::getValue('ORDER_'.Tools::strtoupper($element)));
}
$product_elements = self::CART_PRODUCT_ATTR;
foreach ($product_elements as $element) {
Configuration::updateValue('PRODUCT_'.strtoupper($element), Tools::getValue('PRODUCT_'.strtoupper($element)));
Configuration::updateValue('PRODUCT_'.Tools::strtoupper($element), Tools::getValue('PRODUCT_'.Tools::strtoupper($element)));
}
}

Expand Down Expand Up @@ -972,11 +973,11 @@ public function getConfigFieldsValues()
);
$order_elements = array_keys(get_class_vars('Cart'));
foreach ($order_elements as $element) {
$ret['ORDER_'.strtoupper($element)] = Configuration::get('ORDER_'.strtoupper($element));
$ret['ORDER_'.Tools::strtoupper($element)] = Configuration::get('ORDER_'.Tools::strtoupper($element));
}
$product_elements = self::CART_PRODUCT_ATTR;
foreach ($product_elements as $element) {
$ret['PRODUCT_'.strtoupper($element)] = Configuration::get('PRODUCT_'.strtoupper($element));
$ret['PRODUCT_'.Tools::strtoupper($element)] = Configuration::get('PRODUCT_'.Tools::strtoupper($element));
}

return $ret;
Expand All @@ -997,7 +998,7 @@ public function buildAdminContent()
$order_meta = array();
foreach ($order_elements as $val) {
$order_meta[] = array(
"id" => strtoupper($val),
"id" => Tools::strtoupper($val),
"name" => $val,
"val" => $val
);
Expand All @@ -1007,7 +1008,7 @@ public function buildAdminContent()
$product_meta = array();
foreach ($product_elements as $val) {
$product_meta[] = array(
"id" => strtoupper($val),
"id" => Tools::strtoupper($val),
"name" => $val,
"val" => $val
);
Expand Down Expand Up @@ -1561,7 +1562,7 @@ public function processPayment($conektaOrderId)
\Conekta\Conekta::setApiVersion("2.0.0");
\Conekta\Conekta::setPluginVersion($this->version);
\Conekta\Conekta::setLocale($iso_code);
$cart = $this->context->cart;
// $cart = $this->context->cart;
try {
$order = \Conekta\Order::find($conektaOrderId);
$charge_response = $order->charges[0];
Expand All @@ -1581,6 +1582,7 @@ public function processPayment($conektaOrderId)
}
}

$reference = $charge_response->payment_method->reference;
if (isset($charge_response->id) && $charge_response->payment_method->type == "cash") {
Database::insertOxxoPayment($order, $charge_response, $reference, $this->currentOrder, $this->context->cart->id);
} elseif (isset($charge_response->id) && $charge_response->payment_method->type == "spei") {
Expand Down
9 changes: 4 additions & 5 deletions controllers/front/validation.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,21 +10,21 @@
*
* Validation File Doc Comment
*
* @category Validation
* @package Validation
* @author Conekta <[email protected]>
* @copyright 2012-2019 Conekta
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
* @category Validation
* @package Validation
* @version GIT: @1.1.0@
* @link https://conekta.com/
*/

/**
* ConektaPaymentsPrestashopValidationModuleFrontController Class Doc Comment
*
* @author Conekta <[email protected]>
* @category Class
* @package ConektaPaymentsPrestashopValidationModuleFrontController
* @author Conekta <[email protected]>
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
* @link https://conekta.com/
*/
Expand All @@ -50,9 +50,8 @@ public function postProcess()
}
}
if (!$authorized) {
print_r ($this->getTranslator()->trans('This payment method is not available.', array(), 'Modules.ConektaPaymentsPrestashop.Shop'));
print_r($this->getTranslator()->trans('This payment method is not available.', array(), 'Modules.ConektaPaymentsPrestashop.Shop'));
} else {

if (!Validate::isLoadedObject($customer)) {
Tools::redirect('index.php?controller=order&step=1');
}
Expand Down
6 changes: 3 additions & 3 deletions model/Config.php
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ public static function getDiscountLines($discounts)
array(
array(
'code' => (string) $discount['name'],
'amount' => str_replace(',','',number_format(($discount['value_real'] * 100))),
'amount' => str_replace(',', '', number_format(($discount['value_real'] * 100))),
'type'=>'coupon'
)
)
Expand All @@ -91,7 +91,7 @@ public static function getDiscountLines($discounts)

public static function getShippingLines($shipping_service, $shipping_carrier = '', $shipping_price = '')
{
$shipping_price = str_replace(',','',number_format(($shipping_price * 100)));
$shipping_price = str_replace(',', '', number_format(($shipping_price * 100)));
$shipping_lines = array(
array(
"amount" => $shipping_price,
Expand Down Expand Up @@ -122,7 +122,7 @@ public static function getShippingContact($customer = '', $address_delivery = ''
return $shipping_contact;
}

public static function getCustomerInfo($customer = '', $address_delivery = '')
public static function getCustomerInfo($customer = '')
{
$customer_info = array(
"name" => $customer->firstname . " " . $customer->lastname,
Expand Down
6 changes: 3 additions & 3 deletions model/Database.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,21 +10,21 @@
*
* Database File Doc Comment
*
* @category Database
* @package Database
* @author Conekta <[email protected]>
* @copyright 2012-2019 Conekta
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
* @category Database
* @package Database
* @version GIT: @1.1.0@
* @link https://conekta.com/
*/

/**
* Database Class Doc Comment
*
* @author Conekta <[email protected]>
* @category Class
* @package Database
* @author Conekta <[email protected]>
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
* @link https://conekta.com/
*/
Expand Down
8 changes: 4 additions & 4 deletions notification.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,17 @@
*
* Notification File Doc Comment
*
* @category Notification
* @package Notification
* @author Conekta <[email protected]>
* @copyright 2012-2019 Conekta
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
* @category Notification
* @package Notification
* @version GIT: @1.1.0@
* @link https://conekta.com/
*/

require_once __DIR__ . '/../../config/config.inc.php';
require_once __DIR__ . '/../../init.php';
require_once dirname(__FILE__) . '/../../config/config.inc.php';
require_once dirname(__FILE__) . '/../../init.php';

if (!defined('_PS_VERSION_')) {
exit;
Expand Down
25 changes: 25 additions & 0 deletions views/js/functions.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,28 @@
/**
* 2007-2021 Conekta
*
* NOTICE OF LICENSE
*
* This source file is subject to the Open Software License (OSL 3.0)
* that is bundled with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://opensource.org/licenses/osl-3.0.php
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to [email protected] so we can send you a copy immediately.
*
* DISCLAIMER
*
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
* versions in the future. If you wish to customize PrestaShop for your
* needs please refer to http://www.prestashop.com for more information.
*
* @author Conekta <[email protected]>
* @copyright 2012-2021 Conekta
* @version v2.0.0
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
* International Registered Trademark & Property of PrestaShop SA
*/

$(document).ready(function() {
//initial state
Expand Down
4 changes: 2 additions & 2 deletions views/js/tokenize.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/**
* 2007-2016 Conekta
* 2012-2021 Conekta
*
* NOTICE OF LICENSE
*
Expand All @@ -18,7 +18,7 @@
* needs please refer to http://www.prestashop.com for more information.
*
* @author Conekta <[email protected]>
* @copyright 2012-2016 Conekta
* @copyright 2012-2021 Conekta
* @version v2.0.0
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
* International Registered Trademark & Property of PrestaShop SA
Expand Down
4 changes: 2 additions & 2 deletions views/templates/front/payment_form.tpl
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{*
* 2007-2019 PrestaShop and Contributors
* 2007-2021 PrestaShop and Contributors
*
* NOTICE OF LICENSE
*
Expand All @@ -18,7 +18,7 @@
* needs please refer to https://www.prestashop.com for more information.
*
* @author Conekta <[email protected]>
* @copyright 2007-2019 PrestaShop SA and Contributors
* @copyright 2007-2021 PrestaShop SA and Contributors
* @version v1.0.0
* @license https://opensource.org/licenses/AFL-3.0 Academic Free License 3.0 (AFL-3.0)
* International Registered Trademark & Property of PrestaShop SA
Expand Down
4 changes: 2 additions & 2 deletions views/templates/front/payment_return.tpl
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{*
* 2007-2019 PrestaShop and Contributors
* 2007-2021 PrestaShop and Contributors
*
* NOTICE OF LICENSE
*
Expand All @@ -18,7 +18,7 @@
* needs please refer to https://www.prestashop.com for more information.
*
* @author Conekta <[email protected]>
* @copyright 2007-2019 PrestaShop SA and Contributors
* @copyright 2007-2021 PrestaShop SA and Contributors
* @version v1.0.0
* @license https://opensource.org/licenses/AFL-3.0 Academic Free License 3.0 (AFL-3.0)
* International Registered Trademark & Property of PrestaShop SA
Expand Down
Loading