public function deletePost()
{
if (empty($_POST['post_id'])) {
$return['status'] = 0;
$return['data'] = '';
echo json_encode($return);
exit;
}
!is_array($_POST['post_id']) && ($_POST['post_id'] = array($_POST['post_id']));
$data['post_id'] = array('in', $_POST['post_id']);
$res = D('weiba_post')->where($data)->delete();
if ($res) {
D('weiba_reply')->where($data)->delete();
$return['status'] = 1;
$return['data'] = L('PUBLIC_ADMIN_OPRETING_SUCCESS');
} else {
$return['status'] = 0;
$return['data'] = L('PUBLIC_ADMIN_OPRETING_ERROR');
}
echo json_encode($return);
exit;
}