-
Notifications
You must be signed in to change notification settings - Fork 41
Form actions refresh plus paypal #3093
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
base: rock/form-actions-refresh
Are you sure you want to change the base?
Changes from all commits
53b3d36
4e4fd04
b5216cc
f09c65e
7519c16
9dc10fe
5f29189
4c6474e
dfd8f00
c288ce2
23f2960
4f1d094
b4b0ee2
0887269
541f0ef
0f4a0c8
d7dacb3
4de0da4
82a74d8
5c50f1a
f4ff77f
0040dd6
d8596c3
be35b9b
40fc871
332b616
61f9239
4a37737
696373a
881d61b
ac2bbe9
bd94c9a
dc44012
22cc98e
a52c8dd
dde6a1a
78f27ea
cac80b2
b1e1f92
3e9853f
9aa1fd2
d4ab544
7035d9c
74a58f6
d8a5a79
c3b843c
20a2529
5247e9b
beeee8f
f24748f
fbbe8d4
72fd1ac
f676851
6c4b6a5
e121a31
c322ddb
196d620
0af2f88
2365857
086541a
f7761de
b9e5197
87a6773
ac7b02a
c6bdde5
7f68479
aba8e82
bfa4fb7
7e0e860
4ed0695
7fb37a5
1afae70
6d14ec8
c847b04
952051b
be52e5b
88313c2
3a319d8
21e890b
f4d7390
63d25c7
a2be037
0db8cfd
a693eae
1697110
8c82179
8297ee4
9e6a4aa
464cc18
3379590
94eeb0c
a00036e
cc2112d
3cfe19c
4b304f0
b92d79a
a6d87d3
ba573ee
1c8269a
fa5fb6d
adb0ae1
bb6e02b
74e137c
fcf6c09
5b208c0
d618f1f
4c6d10e
d9d08e4
6c8429f
1a8a28f
60f8a03
36c0572
fe82572
7839e98
5449e31
b099fde
050c32e
3bbb42a
d08cbeb
e2c8b1c
dbcd198
2b8e22c
62a070f
2186e99
c8dacb8
c7454a2
f649d80
743a39e
6b6d44e
c9291c2
be11130
67d1c72
7578a91
544a2d1
822587d
93e30f9
d6d0280
f8a73b9
dd6ad7f
b3b5083
1205022
c620a8f
88cbfb7
e992294
e026af1
f442016
0806e09
e9feedb
9852bbe
7b58e78
7a01741
fd032da
5f76897
258a0e4
202ef7e
66372a3
2a00116
64601f7
2151f10
fa551cb
3a3f70d
094dad9
6e1b724
0d8dbcc
bc7ff90
3bc9b83
304ca19
c10c5ea
6c38a61
9a6a893
c1b60ed
069da46
30e279c
3039bcc
36b9640
bf25dc1
0d344cb
1267097
827f360
294d286
5fbd6ed
c59663d
0fd4b9e
9128c09
c228a7e
c8c9f99
270de89
e375a1c
ac17153
35d3548
20ad8ec
e6ac1f8
b238afa
a17c064
a5b01db
deedbad
cd41741
9aee2ad
e1ba1c7
06cecba
5735f5e
7cd9a12
d4970c8
23bc794
cb7513c
2baf23d
7810466
23da8b6
00059ef
2e3b32b
f7fbd3d
998aa5f
c5db8ae
95a3f98
82d59f7
cd25c32
de450a4
f235ea4
ef08eb5
4ba6fae
8dcd9e8
abfad6a
2421583
9e6863d
69d2ccf
98798fd
e31579f
9ee41fc
d176d03
432f350
722b644
a949396
c531a97
f85b34a
3db1ea2
6452b07
47ce24e
5c3d8a1
e5beaaf
45fa9f2
f1fd5e2
28ba254
a560016
5f96b84
2eefb12
66e762a
af1bd56
b240c27
95eb4c4
541da16
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -3,12 +3,19 @@ | |
| die( 'You are not allowed to call this page directly.' ); | ||
| } | ||
|
|
||
| $limit = $action_control->action_options['limit']; | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
|
|
||
| if ( 'paypal' === $action_control->id_base ) { | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
| // The PayPal add-on may overwrite this so change it back. | ||
| $limit = 1; | ||
| } | ||
|
|
||
| $single_action_attrs = array_merge( | ||
| $data, | ||
| array( | ||
| 'href' => 'javascript:void(0)', | ||
| 'class' => $classes . ' button frm-button-secondary frm-button-sm frm-with-icon frm-ml-auto-force frm-fadein-down-short', | ||
| 'data-limit' => $action_control->action_options['limit'], | ||
| 'data-limit' => $limit, | ||
| 'data-actiontype' => $action_control->id_base, | ||
| ) | ||
| ); | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -30,15 +30,53 @@ | |
| /** | ||
| * Add paypal action. | ||
| */ | ||
| class FrmDefPayPalAction extends FrmFormAction { | ||
| class FrmPayPalLiteAction extends FrmFormAction { | ||
| public function __construct() { | ||
| $action_ops = FrmFormAction::default_action_opts( 'frm_paypal_icon frm_show_upgrade' ); | ||
| $action_ops['color'] = '#001c64'; | ||
| $action_ops = array( | ||
| 'classes' => 'frmfont frm_paypal_icon', | ||
| 'color' => 'var(--primary-700)', | ||
| ); | ||
|
|
||
| parent::__construct( 'paypal', 'PayPal', $action_ops ); | ||
| } | ||
| } | ||
|
|
||
| /** | ||
| * Add paypal legacy action. | ||
| */ | ||
| if ( class_exists( 'FrmPaymentAction' ) ) { | ||
| class FrmDefPayPalLegacyAction extends FrmPaymentAction { | ||
| public function __construct() { | ||
| parent::__construct(); | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
|
|
||
| $this->id_base = 'paypal-legacy'; | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
| $this->name = 'PayPal (Legacy)'; | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
| } | ||
| } | ||
| } | ||
|
|
||
| class FrmStripeLiteAction extends FrmFormAction { | ||
| public function __construct() { | ||
| $action_ops = array( | ||
| 'classes' => 'frmfont frm_stripe_icon', | ||
| 'color' => '#635bff', | ||
| ); | ||
|
|
||
| parent::__construct( 'stripe', 'Stripe', $action_ops ); | ||
| } | ||
| } | ||
|
|
||
| class FrmSquareAction extends FrmFormAction { | ||
| public function __construct() { | ||
| $action_ops = array( | ||
| 'classes' => 'frmfont frm_square_icon', | ||
| 'color' => '#000', | ||
| ); | ||
|
|
||
| parent::__construct( 'square', 'Square', $action_ops ); | ||
| } | ||
| } | ||
|
|
||
| /** | ||
| * Add quiz action. | ||
| */ | ||
|
|
||
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The function call is not valid, which will result in a fatal runtime error.