示例#1
0
<?php

global $post;
?>

<div class="ip-support-meta">
	<p>
		<span>Section: <?php 
echo get_ip_the_sections(', ', $post->ID);
?>
</span>
		<span>Status: <?php 
echo get_support_request_status($post->ID, true);
?>
</span>
	</p>
</div>


示例#2
0
<?php

/**
 * Represents the view for the support request meta box.
 *
 * @since				1.0.0
 * @package			IssuePress
 * @subpackage	IssuePress/admin/views
 * @author			Matthew Simo <*****@*****.**>
 * @license			GPL-2.0+
 * @link				http://issuepress.co
 */
$status = get_support_request_status($support_request->ID);
// Support Request Status - defaults to 'open'
?>
		<p>
			<label for="ip_support_status"><?php 
_e('Status:', $this->name);
?>
</label>
			<select name="ip_support_status">
				<option value="open" ><?php 
_e('Open', $this->name);
?>
</option>
				<option value="closed" ><?php 
_e('Closed', $this->name);
?>
</option>
			</select>
		</p>
 /**
  * Adds the Status Custom Column Data to the Manage Support Requests Admin Panel for each item
  *
  * @since		1.0.0
  */
 public function add_status_column_data($column, $support_request_ID)
 {
     if ($column != 'status') {
         return;
     } else {
         $status = get_support_request_status($support_request_ID);
         if ($status == 'closed') {
             _e('Closed', $this->name);
         } else {
             _e('Open', $this->name);
         }
     }
 }