Skip to content

Commit 5c321be

Browse files
committed
fixed route on link pagination
1 parent dc3cfa2 commit 5c321be

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

admin/jobs.php

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@ function scripted_create_current_jobs_callback()
88
$ID = get_option( '_scripted_ID' );
99
$accessToken = get_option( '_scripted_auccess_tokent' );
1010
$paged = (isset($_GET['paged']) and $_GET['paged'] !='') ? sanitize_text_field($_GET['paged']) : '';
11-
$per_page = 15;
12-
$validate = validateApiKey($ID,$accessToken);
13-
$out = '<div class="wrap">';
11+
$per_page = 15;
12+
$validate = validateApiKey($ID,$accessToken);
13+
$out = '<div class="wrap">';
1414

1515
if ( $_GET['auth'] )
1616
$out .= '<div class="notice notice-success" id="message"><p>Great! Your code validation is correct. Thanks, enjoy...</p></div>';
@@ -19,7 +19,7 @@ function scripted_create_current_jobs_callback()
1919

2020
$filter = (!isset($_GET['filter'])) ? 'all' : sanitize_text_field($_GET['filter']);
2121
$jobUrl = ($filter !='all') ? 'jobs/'.$filter : 'jobs/';
22-
22+
2323
if($validate) {
2424
$url = ($paged != '') ? $jobUrl.'?next_cursor='.$paged : $jobUrl;
2525
$result = curlRequest($url);
@@ -61,7 +61,7 @@ function scripted_create_current_jobs_callback()
6161

6262
$paggination .='<span class="pagination-links">
6363
<span class="displaying-num">'.$totalProjects.' items</span>
64-
<a href="admin.php?page=scripted_current_jobs&paged='.$next.'&filter='.$filter.'" title="Go to the next page" class="next-page '.$nextPage.'">&rsaquo;</a>';
64+
<a href="admin.php?page=scripted_jobs&paged='.$next.'&filter='.$filter.'" title="Go to the next page" class="next-page '.$nextPage.'">&rsaquo;</a>';
6565

6666
$paggination .='</span>
6767
</div>
@@ -169,7 +169,7 @@ function finishedProjectActions(proId,actions) {
169169
type: 'POST',
170170
url: '<?php echo wp_nonce_url( admin_url('admin-ajax.php'), 'create_reject_accept' );?>&do='+actions+'&project_id='+proId+'&action=scripted_poject_finished',
171171
data: '',
172-
success: function(data) {
172+
success: function(data) { console.log(data);
173173
if(actions == 'Accept')
174174
jQuery("#accept_"+proId).html(data);
175175
else if(actions == 'Reject')

0 commit comments

Comments
 (0)