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


PHP testproject::genComboReqSpec方法代码示例

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


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

示例1: initializeGui

function initializeGui(&$dbHandler, &$argsObj)
{
    $tproject_mgr = new testproject($dbHandler);
    $gui = new stdClass();
    $gui->tcasePrefix = $tproject_mgr->getTestCasePrefix($argsObj->tprojectID) . config_get('testcase_cfg')->glue_character;
    $gui->mainCaption = lang_get('testproject') . " " . $argsObj->tprojectName;
    $gui->importance = config_get('testcase_importance_default');
    $gui->creation_date_from = null;
    $gui->creation_date_to = null;
    $gui->modification_date_from = null;
    $gui->modification_date_to = null;
    $gui->search_important_notice = sprintf(lang_get('search_important_notice'), $argsObj->tprojectName);
    $gui->design_cf = $tproject_mgr->cfield_mgr->get_linked_cfields_at_design($argsObj->tprojectID, cfield_mgr::ENABLED, null, 'testcase');
    $gui->keywords = $tproject_mgr->getKeywords($argsObj->tprojectID);
    $gui->filter_by['design_scope_custom_fields'] = !is_null($gui->design_cf);
    $gui->filter_by['keyword'] = !is_null($gui->keywords);
    $reqSpecSet = $tproject_mgr->genComboReqSpec($argsObj->tprojectID);
    $gui->filter_by['requirement_doc_id'] = !is_null($reqSpecSet);
    $gui->option_importance = array(0 => '', HIGH => lang_get('high_importance'), MEDIUM => lang_get('medium_importance'), LOW => lang_get('low_importance'));
    return $gui;
}
开发者ID:mokal,项目名称:DCN_TestLink,代码行数:21,代码来源:tcSearchForm.php

示例2: processTestCase

/**
 * processTestCase
 *
 */
function processTestCase(&$dbHandler, &$argsObj, &$guiObj)
{
    $tproject_mgr = new testproject($dbHandler);
    $guiObj->arrReqSpec = $tproject_mgr->genComboReqSpec($argsObj->tproject_id, 'dotted', " ");
    $SRS_qty = count($guiObj->arrReqSpec);
    if ($SRS_qty > 0) {
        $tc_mgr = new testcase($dbHandler);
        $arrTc = $tc_mgr->get_by_id($argsObj->id);
        if ($arrTc) {
            $guiObj->tcTitle = $arrTc[0]['name'];
            // get first ReqSpec if not defined
            if (is_null($argsObj->idReqSpec)) {
                reset($guiObj->arrReqSpec);
                $argsObj->idReqSpec = key($guiObj->arrReqSpec);
            }
            if ($argsObj->idReqSpec) {
                $req_spec_mgr = new requirement_spec_mgr($dbHandler);
                $guiObj->arrAssignedReq = $req_spec_mgr->get_requirements($argsObj->idReqSpec, 'assigned', $argsObj->id);
                if (!is_null($guiObj->arrAssignedReq)) {
                    $xc = $req_spec_mgr->getAssignedCoverage($argsObj->idReqSpec);
                    $l2d = count($guiObj->arrAssignedReq);
                    for ($xdx = 0; $xdx < $l2d; $xdx++) {
                        $guiObj->arrAssignedReq[$xdx]['coverageAuthor'] = $xc[$guiObj->arrAssignedReq[$xdx]['id']]['login'];
                        $guiObj->arrAssignedReq[$xdx]['coverageTS'] = $xc[$guiObj->arrAssignedReq[$xdx]['id']]['creation_ts'];
                    }
                }
                $guiObj->arrAllReq = $req_spec_mgr->get_requirements($argsObj->idReqSpec);
                $guiObj->arrUnassignedReq = array_diff_byId($guiObj->arrAllReq, $guiObj->arrAssignedReq);
            }
        }
    }
    return $guiObj;
}
开发者ID:mokal,项目名称:DCN_TestLink,代码行数:37,代码来源:reqTcAssign.php

示例3: templateConfiguration

 * For a test project, list test cases that has no requirement assigned
 * 
 * rev: 20081109 - franciscom - BUGID 512
 *
 */
require_once "../../config.inc.php";
require_once "common.php";
require_once "specview.php";
testlinkInitPage($db, false, false, "checkRights");
$templateCfg = templateConfiguration();
$tables = tlObjectWithDB::getDBTables(array('req_coverage', 'nodes_hierarchy', 'tcversions', 'node_types'));
$args = init_args();
$tproject_mgr = new testproject($db);
// get list of available Req Specification
// $reqSpec = $tproject_mgr->getOptionReqSpec($args->tproject_id);
$reqSpec = $tproject_mgr->genComboReqSpec($args->tproject_id);
$uncovered = null;
$gui = new stdClass();
$gui->items = null;
$gui->tproject_name = $args->tproject_name;
$gui->has_reqspec = count($reqSpec) > 0;
$gui->has_requirements = false;
$gui->has_tc = false;
if ($gui->has_reqspec) {
    // Check if at least one of these requirement spec are not empty.
    $reqSpecMgr = new requirement_spec_mgr($db);
    foreach ($reqSpec as $reqSpecID => $name) {
        if ($gui->has_requirements = $reqSpecMgr->get_requirements_count($reqSpecID) > 0) {
            break;
        }
    }
开发者ID:CristianOspinaOspina,项目名称:testlinkpruebas,代码行数:31,代码来源:uncoveredTestCases.php

示例4: processTestCase

/**
 * processTestCase
 *
 */
function processTestCase(&$dbHandler, &$argsObj, &$guiObj)
{
    $tproject_mgr = new testproject($dbHandler);
    // $guiObj->arrReqSpec = $tproject_mgr->getOptionReqSpec($argsObj->tproject_id,testproject::GET_NOT_EMPTY_REQSPEC);
    $guiObj->arrReqSpec = $tproject_mgr->genComboReqSpec($argsObj->tproject_id);
    $SRS_qty = count($guiObj->arrReqSpec);
    if ($SRS_qty > 0) {
        $tc_mgr = new testcase($dbHandler);
        $arrTc = $tc_mgr->get_by_id($argsObj->id);
        if ($arrTc) {
            $guiObj->tcTitle = $arrTc[0]['name'];
            // get first ReqSpec if not defined
            if (is_null($argsObj->idReqSpec)) {
                reset($guiObj->arrReqSpec);
                $argsObj->idReqSpec = key($guiObj->arrReqSpec);
            }
            if ($argsObj->idReqSpec) {
                $req_spec_mgr = new requirement_spec_mgr($dbHandler);
                $guiObj->arrAssignedReq = $req_spec_mgr->get_requirements($argsObj->idReqSpec, 'assigned', $argsObj->id);
                $guiObj->arrAllReq = $req_spec_mgr->get_requirements($argsObj->idReqSpec);
                $guiObj->arrUnassignedReq = array_diff_byId($guiObj->arrAllReq, $guiObj->arrAssignedReq);
            }
        }
    }
    return $guiObj;
}
开发者ID:moraesmv,项目名称:testlink-code,代码行数:30,代码来源:reqTcAssign.php

示例5: basename

require_once "common.php";
require_once 'requirements.inc.php';
require_once 'requirement_spec_mgr.class.php';
require_once 'requirement_mgr.class.php';
testlinkInitPage($db, false, false, "checkRights");
$template_dir = 'requirements/';
$default_template = str_replace('.php', '.tpl', basename($_SERVER['SCRIPT_NAME']));
$args = init_args();
$tproject_mgr = new testproject($db);
$req_spec_mgr = new requirement_spec_mgr($db);
$tcasecfg = config_get('testcase_cfg');
$tcprefix = $tproject_mgr->getTestCasePrefix($args->tprojectID) . $tcasecfg->glue_character;
// get list of ReqSpec
$ns = new stdClass();
// $ns->reqSpec = $tproject_mgr->getOptionReqSpec($args->tprojectID);
$ns->reqSpec = $tproject_mgr->genComboReqSpec($args->tprojectID);
//get first ReqSpec if not defined
if ($args->reqSpecID == 0 && count($ns->reqSpec)) {
    reset($ns->reqSpec);
    $args->reqSpecID = key($ns->reqSpec);
}
// collect REQ data
$ns->coverage = $req_spec_mgr->get_coverage($args->reqSpecID);
$ns->metrics = $req_spec_mgr->get_metrics($args->reqSpecID);
$smarty = new TLSmarty();
foreach ($ns as $key => $value) {
    $smarty->assign($key, $value);
}
$smarty->assign('tcprefix', $tcprefix);
$smarty->assign('selectedReqSpec', $args->reqSpecID);
$smarty->assign('modify_req_rights', has_rights($db, "mgt_modify_req"));
开发者ID:tamtrong,项目名称:testlink,代码行数:31,代码来源:reqSpecAnalyse.php

示例6: init_args

**/
require_once "../../config.inc.php";
require_once "../functions/common.php";
testlinkInitPage($db);
$templateCfg = templateConfiguration();
$tproject_mgr = new testproject($db);
$args = init_args();
$gui = new stdClass();
$gui->tcasePrefix = $tproject_mgr->getTestCasePrefix($args->tprojectID) . config_get('testcase_cfg')->glue_character;
$gui->mainCaption = lang_get('testproject') . " " . $args->tprojectName;
$gui->importance = config_get('testcase_importance_default');
$enabled = 1;
$no_filters = null;
$gui->design_cf = $tproject_mgr->cfield_mgr->get_linked_cfields_at_design($args->tprojectID, $enabled, $no_filters, 'testcase');
$gui->keywords = $tproject_mgr->getKeywords($args->tprojectID);
$reqSpecSet = $tproject_mgr->genComboReqSpec($args->tprojectID);
$gui->filter_by['design_scope_custom_fields'] = !is_null($gui->design_cf);
$gui->filter_by['keyword'] = !is_null($gui->keywords);
$gui->filter_by['requirement_doc_id'] = !is_null($reqSpecSet);
$gui->option_importance = array(0 => '', HIGH => lang_get('high_importance'), MEDIUM => lang_get('medium_importance'), LOW => lang_get('low_importance'));
$gui->creation_date_from = null;
$gui->creation_date_to = null;
$smarty = new TLSmarty();
$smarty->assign('gui', $gui);
$smarty->display($templateCfg->template_dir . 'tcSearchForm.tpl');
/**
 * 
 *
 */
function init_args()
{
开发者ID:tamtrong,项目名称:testlink,代码行数:31,代码来源:tcSearchForm.php


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