当前位置: 首页>>代码示例>>PHP>>正文


PHP Feedback::fetch方法代码示例

本文整理汇总了PHP中Feedback::fetch方法的典型用法代码示例。如果您正苦于以下问题:PHP Feedback::fetch方法的具体用法?PHP Feedback::fetch怎么用?PHP Feedback::fetch使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Feedback的用法示例。


在下文中一共展示了Feedback::fetch方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: array

$request =& HTTPRequest::instance();
if ($request->exist('group_id')) {
    $group_id = $request->get('group_id');
    session_require(array('group' => $group_id, 'admin_flags' => 'A'));
    echo '<table><tr><td><div style="overflow:auto; height:250px; border:1px solid gray">';
    // First make a quick hash of this project's restricted users
    $current_group_restricted_users = array();
    $sql = "SELECT user.user_id from user, user_group WHERE user.status='R' AND user.user_id=user_group.user_id AND user_group.group_id={$group_id}";
    $res = db_query($sql);
    while ($row = db_fetch_array($res)) {
        $current_group_restricted_users[$row['user_id']] = true;
    }
    $hp = Codendi_HTMLPurifier::instance();
    $sql = "SELECT user_id, user_name, realname, status FROM user WHERE status='A' OR status='R' ORDER BY user_name";
    $res = db_query($sql);
    $member_id = array();
    while ($row = db_fetch_array($res)) {
        // Don't display restricted users that don't belong to the project
        if ($row['status'] == 'R') {
            if (!isset($current_group_restricted_users[$row['user_id']]) || !$current_group_restricted_users[$row['user_id']]) {
                continue;
            }
        }
        echo '<div><b>' . $row['user_name'] . '</b> (' . $hp->purify($row['realname'], CODENDI_PURIFIER_CONVERT_HTML) . ")</div>\n";
    }
    echo '</div></td></tr></table>';
} else {
    $feedback = new Feedback();
    $feedback->log('error', $GLOBALS['Language']->getText('global', 'missing_parameters'));
    echo $feedback->fetch();
}
开发者ID:pombredanne,项目名称:tuleap,代码行数:31,代码来源:list_all_users.php

示例2: get_data_feedback_deleted

 /**
  * AJAX response which marked as deleted record.
  * return json of feedback with DELETED state.
  * role: administrator
  */
 public function get_data_feedback_deleted()
 {
     $model_feedback = new Feedback();
     $data = $model_feedback->fetch(Feedback::DELETED);
     echo json_encode($data);
 }
开发者ID:anggadarkprince,项目名称:web-businesscareer,代码行数:11,代码来源:FeedbackController.php

示例3: frsValidator

             $name = $request->get('name');
             $package_id = $request->get('package_id');
             $date = $request->get('date');
             $group_id = $request->get('group_id');
             $release_id = $request->get('release_id');
             $validator = new frsValidator();
             $release = array('name' => $name, 'release_id' => $release_id, 'package_id' => $package_id, 'date' => $date);
             if ($validator->isValidForUpdate($release, $group_id)) {
                 //frs valid
                 $header = array('valid' => true);
             } else {
                 //frs non valid
                 $errors = $validator->getErrors();
                 $feedback = new Feedback();
                 $feedback->log('error', $errors[0]);
                 $header = array('valid' => false, 'msg' => $feedback->fetch());
             }
             header(json_header($header));
         }
     } else {
         if ($action == 'refresh_file_list') {
             $project = $request->getProject();
             $frsff = new FRSFileFactory();
             $file_list = $frsff->getUploadedFileNames($project);
             $available_ftp_files = implode(",", $file_list);
             $purifier = Codendi_HTMLPurifier::instance();
             $available_ftp_files = $purifier->purify($available_ftp_files, CODENDI_PURIFIER_JS_DQUOTE);
             echo '{"valid":true, "msg":"' . $available_ftp_files . '"}';
         }
     }
 }
开发者ID:pombredanne,项目名称:tuleap,代码行数:31,代码来源:frsajax.php


注:本文中的Feedback::fetch方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。