當前位置: 首頁>>代碼示例>>PHP>>正文


PHP project_get_id_by_name函數代碼示例

本文整理匯總了PHP中project_get_id_by_name函數的典型用法代碼示例。如果您正苦於以下問題:PHP project_get_id_by_name函數的具體用法?PHP project_get_id_by_name怎麽用?PHP project_get_id_by_name使用的例子?那麽, 這裏精選的函數代碼示例或許可以為您提供幫助。


在下文中一共展示了project_get_id_by_name函數的7個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: getMantisBugByProjectName

function getMantisBugByProjectName($project_name, $status = "")
{
    $project_id = project_get_id_by_name($project_name);
    if ($project_id == 0) {
        return 0;
    }
    return getMantisBugByProjectId($project_id, $status);
}
開發者ID:n2i,項目名稱:xvnkb,代碼行數:8,代碼來源:mantishelper.php

示例2: ensure_project_exists

 function ensure_project_exists($p_name, $p_description)
 {
     $t_project_id = project_get_id_by_name($p_name);
     if ($t_project_id !== false) {
         return $t_project_id;
     }
     return project_create('MantisBT', 'Mantis Bug Tracker', 50);
 }
開發者ID:mantishub,項目名稱:MantisSeeder,代碼行數:8,代碼來源:Seeder.php

示例3: mci_get_project_id

function mci_get_project_id($p_project)
{
    if ((int) $p_project['id'] != 0) {
        $t_project_id = (int) $p_project['id'];
    } else {
        $t_project_id = project_get_id_by_name($p_project['name']);
    }
    return $t_project_id;
}
開發者ID:raultm,項目名稱:mantisbt,代碼行數:9,代碼來源:mc_api.php

示例4: mci_get_project_id

function mci_get_project_id($p_project)
{
    if (isset($p_project['id']) && (int) $p_project['id'] != 0) {
        $t_project_id = (int) $p_project['id'];
    } else {
        if (isset($p_project['name']) && !is_blank($p_project['name'])) {
            $t_project_id = project_get_id_by_name($p_project['name']);
        } else {
            $t_project_id = ALL_PROJECTS;
        }
    }
    return $t_project_id;
}
開發者ID:nourchene-benslimane,項目名稱:mantisV0,代碼行數:13,代碼來源:mc_api.php

示例5: getProject

 public function getProject($proj)
 {
     if (MANTIS_LOCAL) {
         $ret = new StdClass();
         $ret->id = project_get_id_by_name($proj);
     } else {
         $projects = $this->client->mc_projects_get_user_accessible(MANTIS_USER, MANTIS_PWD);
         foreach ($projects as $p) {
             if ($p->name == $proj) {
                 $ret = $p;
             }
         }
     }
     return $ret;
 }
開發者ID:brotherbard,項目名稱:feedbackreporter,代碼行數:15,代碼來源:mantis.php

示例6: print_project_header_changelog

/**
 * Print header for the specified project
 * @param string $p_project_name project name to display
 * @return null
 */
function print_project_header_changelog($p_project_name)
{
    echo '<br /><span class="pagetitle">', string_display_line($p_project_name), ' - ', lang_get('changelog'), '</span><br />';
    echo '<tt>';
}
$t_user_id = auth_get_current_user_id();
$f_project = gpc_get_string('project', '');
if (is_blank($f_project)) {
    $f_project_id = gpc_get_int('project_id', -1);
} else {
    $f_project_id = project_get_id_by_name($f_project);
    if ($f_project_id === 0) {
        trigger_error(ERROR_PROJECT_NOT_FOUND, ERROR);
    }
}
$f_version = gpc_get_string('version', '');
if (is_blank($f_version)) {
    $f_version_id = gpc_get_int('version_id', -1);
    # If both version_id and project_id parameters are supplied, then version_id take precedence.
    if ($f_version_id == -1) {
        if ($f_project_id == -1) {
            $t_project_id = helper_get_current_project();
        } else {
            $t_project_id = $f_project_id;
        }
    } else {
開發者ID:WebuddhaInc,項目名稱:mantisbt-plugin-wbquickreport,代碼行數:31,代碼來源:changelog_page.php

示例7: mc_project_get_id_from_name

/**
 * Get the id of a project via the project's name.
 *
 * @param string $p_username     The name of the user trying to access the versions.
 * @param string $p_password     The password of the user.
 * @param string $p_project_name The name of the project to retrieve.
 * @return int  The id of the project with the given name, 0 if there is no such project.
 */
function mc_project_get_id_from_name($p_username, $p_password, $p_project_name)
{
    $t_user_id = mci_check_login($p_username, $p_password);
    if ($t_user_id === false) {
        return mci_soap_fault_login_failed();
    }
    return project_get_id_by_name($p_project_name);
}
開發者ID:derrickweaver,項目名稱:mantisbt,代碼行數:16,代碼來源:mc_project_api.php


注:本文中的project_get_id_by_name函數示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。