Skip to content

Commit

Permalink
ADD: New application highlights
Browse files Browse the repository at this point in the history
  • Loading branch information
nithinjohn22 committed Jan 9, 2024
1 parent 5c8b883 commit 125f9ae
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions inc/class-awsm-job-openings-core.php
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,11 @@ public function register_post_types() {
return;
}

$args['post_type'] = 'awsm_job_application';
$args['numberposts'] = -1;
$args['post_status'] = 'publish';
$application_count = count( get_posts( $args ) );

$labels = array(
'name' => __( 'Applications', 'wp-job-openings' ),
'singular_name' => __( 'Application', 'wp-job-openings' ),
Expand All @@ -125,6 +130,14 @@ public function register_post_types() {
'search_items' => __( 'Search Applications', 'wp-job-openings' ),
'not_found' => __( 'No Applications found', 'wp-job-openings' ),
'not_found_in_trash' => __( 'No Applications found in Trash', 'wp-job-openings' ),
'all_items' => $application_count
? sprintf(
/* translators: Number of applications */
__( 'Applications %s', 'wp-job-openings' ),
'<span class="awaiting-mod">' . $application_count . '</span>'
)
: __( 'Applications', 'wp-job-openings' ),

);

/**
Expand Down

0 comments on commit 125f9ae

Please sign in to comment.