Skip to content

Commit

Permalink
Merge pull request #57 from boxuk/add-links-to-title-of-consents
Browse files Browse the repository at this point in the history
[J#PEAK-4210][ FEATURE ][ REFACTOR ] Cookie banner link changes
  • Loading branch information
Ritchbox authored Feb 4, 2022
2 parents b02cda9 + 3b134d3 commit 1f4df45
Show file tree
Hide file tree
Showing 17 changed files with 1,048 additions and 640 deletions.
28 changes: 14 additions & 14 deletions admin/partials/requests.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@
<div class="nav-tab-wrapper">
<?php foreach ( $tabs as $key => $value ) : ?>
<a href="<?php echo esc_url( '#' . $key ); ?>" class="nav-tab">
<?php echo esc_html( $value['name'] ); ?>
<?php esc_html_e( $value['name'] ); ?>
<?php if ( $value['count'] ) : ?>
<span class="gdpr-pending-requests-badge"><?php echo esc_html( $value['count'] ); ?></span>
<span class="gdpr-pending-requests-badge"><?php esc_html_e( $value['count'] ); ?></span>
<?php endif ?>
</a>
<?php endforeach; ?>
Expand All @@ -43,8 +43,8 @@
<?php if ( isset( $rectify ) && ! empty( $rectify ) ) : ?>
<?php foreach ( $rectify as $i => $request ) : ?>
<tr>
<td class="row-title"><?php echo esc_html( $request['email'] ); ?></td>
<td class="text-center"><?php echo esc_html( $request['date'] ); ?></td>
<td class="row-title"><?php esc_html_e( $request['email'] ); ?></td>
<td class="text-center"><?php esc_html_e( $request['date'] ); ?></td>
<td class="text-center">
<?php
echo wp_kses(
Expand Down Expand Up @@ -110,9 +110,9 @@
<?php if ( isset( $complaint ) && ! empty( $complaint ) ) : ?>
<?php foreach ( $complaint as $i => $request ) : ?>
<tr>
<td class="row-title"><?php echo esc_html( $request['email'] ); ?></td>
<td class="text-center"><?php echo esc_html( $request['date'] ); ?></td>
<td class="text-center"><?php echo esc_html( wp_unslash( $request['data'] ) ); ?></td>
<td class="row-title"><?php esc_html_e( $request['email'] ); ?></td>
<td class="text-center"><?php esc_html_e( $request['date'] ); ?></td>
<td class="text-center"><?php esc_html_e( wp_unslash( $request['data'] ) ); ?></td>
<td class="text-center">
<form class="frm-process-complaint" action="<?php echo esc_url( admin_url( 'admin-post.php' ) ); ?>" method="post">
<?php wp_nonce_field( 'gdpr-request-nonce', 'gdpr_cancel_complaint_nonce' ); ?>
Expand Down Expand Up @@ -182,8 +182,8 @@
<?php foreach ( $delete as $i => $request ) : ?>
<?php $user = get_user_by( 'email', $request['email'] ); ?>
<tr class="<?php echo ( 0 === $index % 2 ? '' : 'alternate' ); ?>">
<td class="row-title"><?php echo esc_html( $request['email'] ); ?></td>
<td class="text-center"><?php echo esc_html( $request['date'] ); ?></td>
<td class="row-title"><?php esc_html_e( $request['email'] ); ?></td>
<td class="text-center"><?php esc_html_e( $request['date'] ); ?></td>
<td class="text-center">
<?php
if ( GDPR_Requests::user_has_content( $user ) ) {
Expand Down Expand Up @@ -242,17 +242,17 @@
}
?>
<tr>
<td class="row-title"><?php echo esc_attr( $pt->label ); ?></td>
<td class="text-center"><?php echo esc_attr( $count ); ?></td>
<td class="row-title"><?php esc_html_e( $pt->label ); ?></td>
<td class="text-center"><?php esc_html_e( $count ); ?></td>
<td class="text-center">
<a href="<?php echo esc_url( admin_url( 'edit.php?post_type=' . $pt->name . '&author=' . $uid ) ); ?>" target="_blank" class="button"><?php echo esc_html( $pt->labels->view_items ); ?></a>
<a href="<?php echo esc_url( admin_url( 'edit.php?post_type=' . $pt->name . '&author=' . $uid ) ); ?>" target="_blank" class="button"><?php esc_html_e( $pt->labels->view_items ); ?></a>
</td>
<td class="text-center">
<select name="reassign" class="gdpr-reassign">
<option value="0"></option>
<?php $admins = get_users( array( 'role' => 'administrator' ) ); ?>
<?php foreach ( $admins as $admin ) : ?>
<option value="<?php echo esc_attr( $admin->ID ); ?>"><?php echo esc_html( $admin->display_name ); ?></option>
<option value="<?php echo esc_attr( $admin->ID ); ?>"><?php esc_html_e( $admin->display_name ); ?></option>
<?php endforeach; ?>
</select>
</td>
Expand Down Expand Up @@ -284,7 +284,7 @@
?>
<tr>
<td class="row-title"><?php esc_html_e( 'Comments', 'gdpr' ); ?></td>
<td class="text-center"><?php echo esc_html( $comment_count ); ?></td>
<td class="text-center"><?php esc_html_e( $comment_count ); ?></td>
<td class="text-center"><a href="<?php echo esc_url( admin_url( 'edit-comments.php?comment_status=all&s=' . rawurlencode( $request['email'] ) ) ); ?>" target="_blank" class="button"><?php esc_html_e( 'View Comments', 'gdpr' ); ?></a></td>
<td></td>
<td class="text-center">
Expand Down
Loading

0 comments on commit 1f4df45

Please sign in to comment.