Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
W
woocommerce-quick-donation
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wordpress
woocommerce-quick-donation
Commits
ef8391d7
Commit
ef8391d7
authored
Nov 02, 2015
by
Varun Sridharan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixes #21
Fixed issue #21
parent
27b0ba82
Changes
4
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
830 additions
and
37 deletions
+830
-37
class-admin-functions.php
includes/admin/class-admin-functions.php
+11
-5
class-admin-help.php
includes/admin/class-admin-help.php
+222
-0
class-admin-init.php
includes/admin/class-admin-init.php
+2
-1
wp-donation-listing-table.php
includes/admin/wp-donation-listing-table.php
+595
-31
No files found.
includes/admin/class-admin-functions.php
View file @
ef8391d7
...
...
@@ -20,7 +20,7 @@ class WooCommerce_Quick_Donation_Admin_Function {
public
function
__construct
(){
add_action
(
'post_row_actions'
,
array
(
$this
,
'protect_donation_product'
),
99
,
2
);
add_action
(
'parse_query'
,
array
(
$this
,
'hide_donation_order_woocommerce_order'
)
);
add_filter
(
'wc_order_types'
,
array
(
$this
,
'add_wc_order_types'
),
99
,
2
);
add_filter
(
'wc_order_types'
,
array
(
$this
,
'add_wc_order_types'
),
1
,
2
);
}
...
...
@@ -41,11 +41,17 @@ class WooCommerce_Quick_Donation_Admin_Function {
public
function
add_wc_order_types
(
$order_types
,
$type
){
$order_type
=
$order_types
;
global
$post_type
;
if
(
''
==
$type
){
$order_type
[]
=
WC_QD_PT
;
$order_type
[]
=
'wc
qd_project'
;
$order_type
[]
=
'wc
_qd_orders'
;
}
if
(
'shop_order'
==
$type
){
$order_type
[]
=
WC_QD_PT
;
$order_type
[]
=
'wc_qd_orders'
;
}
return
$order_type
;
}
...
...
includes/admin/class-admin-help.php
0 → 100644
View file @
ef8391d7
This diff is collapsed.
Click to expand it.
includes/admin/class-admin-init.php
View file @
ef8391d7
...
...
@@ -139,6 +139,7 @@ class WooCommerce_Quick_Donation_Admin {
public
function
init_admin_class
(){
$this
->
functions
=
new
WooCommerce_Quick_Donation_Admin_Function
;
$this
->
admin_order_page
=
new
WooCommerce_Quick_Donation_Admin_Order_Page_Functions
;
$this
->
admin_help
=
new
WooCommerce_Quick_Donation_Admin_Help
;
}
...
...
@@ -180,7 +181,7 @@ class WooCommerce_Quick_Donation_Admin {
$args
[
'meta_query'
][][
'value'
]
=
$_GET
[
'dproj'
];
$args
[
'meta_query'
][][
'compare'
]
=
'='
;
}
if
(
isset
(
$_GET
[
'
order_status'
])){
$args
[
'post_status'
]
=
$_GET
[
'order
_status'
];}
if
(
isset
(
$_GET
[
'
post_status'
])){
$args
[
'post_status'
]
=
$_GET
[
'post
_status'
];}
$wp_query
=
new
WP_Query
(
$args
);
require
(
'wp-donation-listing-table.php'
);
tt_render_list_page
(
$wp_query
);
...
...
includes/admin/wp-donation-listing-table.php
View file @
ef8391d7
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment