• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP getFilter函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中getFilter函数的典型用法代码示例。如果您正苦于以下问题:PHP getFilter函数的具体用法?PHP getFilter怎么用?PHP getFilter使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



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

示例1: get_otd_bi

 /**
  * Gets the collection of data for the OTD graph of database for the selected period.
  *  
  * @param int $selectedPeriod period selected for display.
  * 
  * @return array Information relevant to the OTD graph.
  * 
  */
 public function get_otd_bi($selected_period = "x")
 {
     $this->db_tickets = $this->load->database('oracle', TRUE);
     $sql = $sql = "SELECT   TARGET_RELEASE,\n\t\tTO_CHAR(SCHED_FINISH_DATE, 'YYYY/MM') as ByYearMonth,\n\t\tSUM(CASE WHEN ACTUAL_FINISH_DATE <= SCHED_FINISH_DATE THEN 1 ELSE 0 END) AS PASSED,\n\t\tSUM(CASE WHEN ACTUAL_FINISH_DATE > SCHED_FINISH_DATE THEN 1 ELSE 0 END) AS NOT_PASSED,\n\t\tcount (*) as TOTAL,\n\t\tROUND (((SUM(CASE WHEN ACTUAL_FINISH_DATE <= SCHED_FINISH_DATE THEN 1 ELSE 0 END) * 100) / count (*) )) as AVERG\n\t\t FROM vw_24fitness_all_tickets \n\t\tWHERE IT_GROUP='BI' AND \n\t\tTARGET_RELEASE IS NOT NULL AND\n\t\tACTUAL_FINISH_DATE IS NOT NULL AND\n\t\tSCHED_FINISH_DATE IS NOT NULL AND \n\t\tSCHED_FINISH_DATE between to_date (?, 'yyyy/mm/dd') AND \n\t\tto_date (?, 'yyyy/mm/dd')\n\t\tGROUP BY TO_CHAR(SCHED_FINISH_DATE, 'YYYY/MM'), TARGET_RELEASE \n\t\tORDER BY ByYearMonth";
     $query = $this->db_tickets->query($sql, getFilter($selected_period));
     return $query->result();
 }
开发者ID:sholo,项目名称:dashboard,代码行数:15,代码来源:business_model.php


示例2: get_estimation_variance_detailed_data

 /**
  * Gets a collection of data relevant to each point of the graph, to show details of each ticket.
  *  
  * @param int $selectedPeriod period selected for display.
  * @param String $assigned_to User to show detail.
  * 
  * @return array Information relevant to the Estimation Variance graph.
  * 
  */
 public function get_estimation_variance_detailed_data($selected_period = "x", $assigned_to)
 {
     $this->db_tickets = $this->load->database('oracle', TRUE);
     if ($selected_period == 'year') {
         //This is to rename the names of the months by digit, for the search in the query.
         $assigned_to == 'JANUARY' ? $month = 1 : '';
         $assigned_to == 'FEBRUARY' ? $month = 2 : '';
         $assigned_to == 'MARCH' ? $month = 3 : '';
         $assigned_to == 'APRIL' ? $month = 4 : '';
         $assigned_to == 'MAY' ? $month = 5 : '';
         $assigned_to == 'JUNE' ? $month = 6 : '';
         $assigned_to == 'JULY' ? $month = 7 : '';
         $assigned_to == 'AUGUST' ? $month = 8 : '';
         $assigned_to == 'SEPTEMBER' ? $month = 9 : '';
         $assigned_to == 'OCTOBER' ? $month = 10 : '';
         $assigned_to == 'NOVEMBER' ? $month = 11 : '';
         $assigned_to == 'DECEMBER' ? $month = 12 : '';
         $sql = "SELECT ticket_id, ASSIGNED_TO, title, actual_effort, estimated_fix_time, round((ACTUAL_EFFORT / ESTIMATED_FIX_TIME),2) as DIVISION, prod_deployment_date \n\t\t\tFROM vw_24fitness_all_tickets WHERE \n\t\t\tIT_GROUP='BI' AND prod_deployment_date between \n\t\t\tto_date (?, 'yyyy/mm/dd') AND to_date (?, 'yyyy/mm/dd') and EXTRACT(MONTH FROM prod_deployment_date)=" . $month . "  ORDER BY ASSIGNED_TO";
     } else {
         $sql = "SELECT ticket_id, ASSIGNED_TO, title, actual_effort, estimated_fix_time, round((ACTUAL_EFFORT / ESTIMATED_FIX_TIME),2) as DIVISION, prod_deployment_date ";
         $sql .= "FROM vw_24fitness_all_tickets WHERE ";
         $sql .= "IT_GROUP='BI' AND prod_deployment_date between ";
         $sql .= "to_date (?, 'yyyy/mm/dd') AND to_date (?, 'yyyy/mm/dd') and assigned_to='" . $assigned_to . "' ORDER BY ASSIGNED_TO";
     }
     $query = $this->db_tickets->query($sql, getFilter($selected_period));
     return $query->result();
 }
开发者ID:sholo,项目名称:dashboard,代码行数:36,代码来源:estimation_variance_bi_model.php


示例3: widget_goods

/**
 * ShopEx licence
 *
 * @copyright  Copyright (c) 2005-2010 ShopEx Technologies Inc. (http://www.shopex.cn)
 * @license  http://ecos.shopex.com/license/gpl GPL License
 */
function widget_goods(&$setting, &$render)
{
    $limit = intval($setting['limit']) > 0 ? intval($setting['limit']) : 6;
    $goods =& app::get('b2c')->model('goods');
    $goods->defaultCols = 'bn,name,cat_id,price,store,marketable,brand_id,weight,d_order,uptime,type_id';
    $goods->appendCols = 'goods_id,thumbnail_pic,brief,mktprice,image_default_id';
    $config = app::get('b2c')->getConf('site.save_price');
    $data['onSelect'] = $setting['onSelect'] ? $setting['onSelect'] : 0;
    $setting['max_length'] = $setting['max_length'] ? $setting['max_length'] : 35;
    $setting['view'] = app::get('b2c')->getConf('gallery.default_view');
    $imageDefault = app::get('image')->getConf('image.set');
    $search =& app::get('b2c')->model('search');
    $setting['str'] = $search->encode($filter);
    $setting['restrict'] = $setting['restrict'] ? $setting['restrict'] : 'on';
    $order = $setting['goods_orderby'] ? orderBy($setting['goods_orderby']) : null;
    if ($setting['columNum'] > 1) {
        for ($i = 0; $i < $setting['columNum']; $i++) {
            parse_str($setting['adjunct']['items'][$i], $filter[$i]);
            $filter[$i] = getFilter($filter[$i]);
            $result['link'][$i - 1] =& kernel::router()->gen_url(array('app' => 'b2c', 'ctl' => 'gallery', 'act' => $setting['view'], 'args' => array($str_cat_id, $search->encode($filter[$i]), $setting['goods_orderby'] ? $setting['goods_orderby'] : 0)));
            $result['goods'][] = $goods->getList(null, $filter[$i], 0, $limit, $order['sql']);
            $result['defaultImage'] = $imageDefault['S']['default_image'];
            unset($filter[$i]);
        }
        return $result;
    } else {
        parse_str($setting['adjunct']['items'][0], $filter);
        $filter = getFilter($filter);
        $result['link'] =& kernel::router()->gen_url(array('app' => 'b2c', 'ctl' => 'site_gallery', 'act' => $setting['view'], 'args' => array(implode(",", (array) $filter['cat_id']), $search->encode($filter), $setting['goods_orderby'] ? $setting['goods_orderby'] : 0)));
        $result['goods'] = $goods->getList('*', $filter, 0, $limit, $order['sql']);
        $result['defaultImage'] = $imageDefault['S']['default_image'];
        return $result;
    }
}
开发者ID:dalinhuang,项目名称:shopexts,代码行数:40,代码来源:widget_goods.php


示例4: get_defect_rate_detailed_data

 /**
  * Gets a collection of data relevant to each point of the graph, to show details of each ticket.
  *  
  * @param int $selectedPeriod period selected for display.
  * @param String $application Application to show detail..
  * @param String $target_release Target Release to show detail.
  * 
  * @return array Information relevant to the Defect Rate graph.
  * 
  */
 public function get_defect_rate_detailed_data($selected_period = "x", $application, $target_release)
 {
     $this->db_tickets = $this->load->database('oracle', TRUE);
     if ($selected_period == 'year') {
         //This is to rename the names of the months by digit, for the search in the query.
         $target_release == 'JANUARY' ? $month = 1 : '';
         $target_release == 'FEBRUARY' ? $month = 2 : '';
         $target_release == 'MARCH' ? $month = 3 : '';
         $target_release == 'APRIL' ? $month = 4 : '';
         $target_release == 'MAY' ? $month = 5 : '';
         $target_release == 'JUNE' ? $month = 6 : '';
         $target_release == 'JULY' ? $month = 7 : '';
         $target_release == 'AUGUST' ? $month = 8 : '';
         $target_release == 'SEPTEMBER' ? $month = 9 : '';
         $target_release == 'OCTOBER' ? $month = 10 : '';
         $target_release == 'NOVEMBER' ? $month = 11 : '';
         $target_release == 'DECEMBER' ? $month = 12 : '';
         $sql = "SELECT  ticket_id, title, APPLICATION, TARGET_RELEASE, SUM(CASE WHEN TYPE_24FITNESS = 'Defect' THEN 1 ELSE 0 END) AS DEFECTS, \n\t\t\tSUM(CASE WHEN TYPE_24FITNESS = 'Defect' OR TYPE_24FITNESS = 'Requirement' THEN 1 ELSE 0 END) AS TASKS, PROD_DEPLOYMENT_DATE \n\t\t\tFROM vw_24fitness_all_tickets where PROD_DEPLOYMENT_DATE between to_date (?, 'yyyy/mm/dd') AND \n\t\t\tto_date (?, 'yyyy/mm/dd') and EXTRACT(MONTH FROM PROD_DEPLOYMENT_DATE)=" . $month . " and it_group='BI' \n\t\t\tgroup by ticket_id , APPLICATION, TARGET_RELEASE, PROD_DEPLOYMENT_DATE, title order by prod_deployment_date";
     } else {
         $sql = "SELECT  ticket_id, title, APPLICATION, TARGET_RELEASE, SUM(CASE WHEN TYPE_24FITNESS = 'Defect' THEN 1 ELSE 0 END) AS DEFECTS, ";
         $sql .= "SUM(CASE WHEN TYPE_24FITNESS = 'Defect' OR TYPE_24FITNESS = 'Requirement' THEN 1 ELSE 0 END) AS TASKS, PROD_DEPLOYMENT_DATE ";
         $sql .= "FROM vw_24fitness_all_tickets where PROD_DEPLOYMENT_DATE between to_date (?, 'yyyy/mm/dd') AND ";
         $sql .= "to_date (?, 'yyyy/mm/dd') and application='" . $application . "' and target_release='" . $target_release . "' and it_group='BI' ";
         $sql .= "group by ticket_id , APPLICATION, TARGET_RELEASE, PROD_DEPLOYMENT_DATE, title order by application, target_release ";
     }
     $query = $this->db_tickets->query($sql, getFilter($selected_period));
     return $query->result();
 }
开发者ID:sholo,项目名称:dashboard,代码行数:38,代码来源:defect_rate_bi_model.php


示例5: get_number_of_cycles_detailed_data

 /**
  * Gets a collection of data relevant to each point of the graph, to show details of each ticket.
  *  
  * @param int $selectedPeriod period selected for display.
  * @param String $application Application to show detail.
  * @param String $target_release Target Release to show detail.
  * 
  * @return array Information relevant to the Number of Cycles graph.
  * 
  */
 public function get_number_of_cycles_detailed_data($selected_period = "x", $application, $target_release)
 {
     $this->db_tickets = $this->load->database('oracle', TRUE);
     if ($selected_period == 'year') {
         //This is to rename the names of the months by digit, for the search in the query.
         $target_release == 'JANUARY' ? $month = 1 : '';
         $target_release == 'FEBRUARY' ? $month = 2 : '';
         $target_release == 'MARCH' ? $month = 3 : '';
         $target_release == 'APRIL' ? $month = 4 : '';
         $target_release == 'MAY' ? $month = 5 : '';
         $target_release == 'JUNE' ? $month = 6 : '';
         $target_release == 'JULY' ? $month = 7 : '';
         $target_release == 'AUGUST' ? $month = 8 : '';
         $target_release == 'SEPTEMBER' ? $month = 9 : '';
         $target_release == 'OCTOBER' ? $month = 10 : '';
         $target_release == 'NOVEMBER' ? $month = 11 : '';
         $target_release == 'DECEMBER' ? $month = 12 : '';
         $sql = "SELECT TICKET_ID, TITLE, APPLICATION, TARGET_RELEASE, TARGET_CYCLE \n\t\t\tFROM vw_24fitness_all_tickets \n\t\t\tWHERE PROD_DEPLOYMENT_DATE between to_date (?, 'yyyy/mm/dd') AND \n\t\t\tto_date (?, 'yyyy/mm/dd') and it_group='DEV'\n\t\t\tand EXTRACT(MONTH FROM PROD_DEPLOYMENT_DATE)=" . $month . "\n\t\t\tORDER BY APPLICATION, TARGET_RELEASE, TARGET_CYCLE";
     } else {
         $sql = "SELECT TICKET_ID, TITLE, APPLICATION, TARGET_RELEASE, TARGET_CYCLE ";
         $sql .= "FROM vw_24fitness_all_tickets ";
         $sql .= "WHERE ";
         $sql .= "APPLICATION = '" . $application . "' AND ";
         $sql .= "TARGET_RELEASE = '" . $target_release . "' AND ";
         $sql .= "PROD_DEPLOYMENT_DATE between to_date (?, 'yyyy/mm/dd') AND ";
         $sql .= "to_date (?, 'yyyy/mm/dd') and it_group='DEV' ";
         $sql .= "ORDER BY APPLICATION, TARGET_RELEASE, TARGET_CYCLE ";
     }
     $query = $this->db_tickets->query($sql, getFilter($selected_period));
     return $query->result();
 }
开发者ID:sholo,项目名称:dashboard,代码行数:41,代码来源:number_of_cycles_dev_model.php


示例6: get_series

 public function get_series($selected_period = "x")
 {
     $series_data = NULL;
     $period = getFilter($selected_period);
     $query = $this->db->get_where('survey', array('period >=' => $period['start_date'], 'period <' => $period['end_date'], 'survey_type_id' => 2));
     $survey_id = $query->result();
     if ($survey_id != NULL) {
         for ($i = 0; $i < count($survey_id); $i++) {
             $query = $this->db->get_where('survey_question', array('survey_id' => $survey_id[$i]->id));
             $survey[] = $query->result();
             for ($j = 0; $j < count($this->get_questions()); $j++) {
                 if ($i == 0) {
                     if ($survey[0][$j]->answer_types_id != NULL) {
                         $MAX[] = $MIN[] = (int) $survey[0][$j]->answer_types_id;
                         $AVG[] = (double) $survey[0][$j]->answer_types_id;
                     }
                 } else {
                     if ($survey[$i][$j]->answer_types_id != NULL) {
                         $MAX[$j] < $survey[$i][$j]->answer_types_id ? $MAX[$j] = (int) $survey[$i][$j]->answer_types_id : (int) $MAX[$j];
                         $MIN[$j] > $survey[$i][$j]->answer_types_id ? $MIN[$j] = (int) $survey[$i][$j]->answer_types_id : (int) $MIN[$j];
                         $AVG[$j] += $survey[$i][$j]->answer_types_id;
                         if (count($survey_id) - 1 == $i) {
                             $AVG[$j] = (double) ($AVG[$j] / count($survey_id));
                         }
                     }
                 }
             }
         }
         $series_data[] = array('name' => 'Max', 'data' => $MAX);
         $series_data[] = array('name' => 'Average', 'data' => $AVG);
         $series_data[] = array('name' => 'Min', 'data' => $MIN);
     }
     return $series_data;
 }
开发者ID:sholo,项目名称:dashboard,代码行数:34,代码来源:performance_communication_feedback_model.php


示例7: get_utilization_detailed_data

 /**
  * Gets a collection of data relevant to each point of the graph, to show details of each ticket.
  *  
  * @param int $selectedPeriod period selected for display.
  * @param String $assigned_to User to show detail.
  * 
  * @return array Information relevant to the Utilization graph.
  * 
  */
 public function get_utilization_detailed_data($selected_period = "x", $assigned_to)
 {
     $this->db_tickets = $this->load->database('oracle', TRUE);
     if ($selected_period == 'year') {
         //This is to rename the names of the months by digit, for the search in the query.
         $assigned_to == 'JANUARY' ? $month = 1 : '';
         $assigned_to == 'FEBRUARY' ? $month = 2 : '';
         $assigned_to == 'MARCH' ? $month = 3 : '';
         $assigned_to == 'APRIL' ? $month = 4 : '';
         $assigned_to == 'MAY' ? $month = 5 : '';
         $assigned_to == 'JUNE' ? $month = 6 : '';
         $assigned_to == 'JULY' ? $month = 7 : '';
         $assigned_to == 'AUGUST' ? $month = 8 : '';
         $assigned_to == 'SEPTEMBER' ? $month = 9 : '';
         $assigned_to == 'OCTOBER' ? $month = 10 : '';
         $assigned_to == 'NOVEMBER' ? $month = 11 : '';
         $assigned_to == 'DECEMBER' ? $month = 12 : '';
         $sql = "SELECT  ticket_id, ASSIGNED_TO,  title, IT_GROUP,  ACTUAL_EFFORT, actual_finish_date \n\t\t\tFROM vw_24fitness_all_tickets \n\t\t\tWHERE (actual_finish_date between to_date (?, 'yyyy/mm/dd') AND to_date (?, 'yyyy/mm/dd')) AND IT_GROUP = 'DEV' \n\t\t\tand EXTRACT(MONTH FROM actual_finish_date)=" . $month . " order by actual_finish_date";
     } else {
         $sql = "SELECT  ticket_id, ASSIGNED_TO,  title, IT_GROUP,  ACTUAL_EFFORT, actual_finish_date ";
         $sql .= "FROM vw_24fitness_all_tickets ";
         $sql .= "WHERE (actual_finish_date between to_date (?, 'yyyy/mm/dd') AND to_date (?, 'yyyy/mm/dd')) AND IT_GROUP = 'DEV' ";
         $sql .= "and ASSIGNED_TO = '" . $assigned_to . "' order by assigned_to";
     }
     $query = $this->db_tickets->query($sql, getFilter($selected_period));
     return $query->result();
 }
开发者ID:sholo,项目名称:dashboard,代码行数:36,代码来源:utilization_dev_model.php


示例8: get_defect_rate_detailed_data

 public function get_defect_rate_detailed_data($selected_period = "x", $application, $target_release)
 {
     $this->db_tickets = $this->load->database('oracle', TRUE);
     $sql = "SELECT  ticket_id, title, APPLICATION, TARGET_RELEASE, SUM(CASE WHEN TYPE_24FITNESS = 'Defect' THEN 1 ELSE 0 END) AS DEFECTS, ";
     $sql .= "SUM(CASE WHEN TYPE_24FITNESS = 'Defect' OR TYPE_24FITNESS = 'Requirement' THEN 1 ELSE 0 END) AS TASKS, PROD_DEPLOYMENT_DATE ";
     $sql .= "FROM vw_24fitness_all_tickets where PROD_DEPLOYMENT_DATE between to_date (?, 'yyyy/mm/dd') AND ";
     $sql .= "to_date (?, 'yyyy/mm/dd') and application='" . $application . "' and target_release='" . $target_release . "' ";
     $sql .= "group by ticket_id , APPLICATION, TARGET_RELEASE, PROD_DEPLOYMENT_DATE, title order by application, target_release ";
     $query = $this->db_tickets->query($sql, getFilter($selected_period));
     return $query->result();
 }
开发者ID:sholo,项目名称:dashboard,代码行数:11,代码来源:defect_rate_model.php


示例9: get_efficiency_detailed_data

 public function get_efficiency_detailed_data($selected_period = "x", $assigned_to)
 {
     $this->db_tickets = $this->load->database('oracle', TRUE);
     $sql = "SELECT ticket_id , ASSIGNED_TO, title,  IT_GROUP, actual_effort, SCHED_FINISH_DATE ";
     $sql .= "FROM vw_24fitness_all_tickets WHERE IT_GROUP = 'DEV' and ";
     $sql .= "ACTUAL_EFFORT is not null and SCHED_FINISH_DATE between ";
     $sql .= "to_date (?, 'yyyy/mm/dd') AND to_date (?, 'yyyy/mm/dd')  and assigned_to='" . $assigned_to . "' ";
     $sql .= "GROUP BY  ticket_id, actual_effort, assigned_to, IT_GROUP, title, SCHED_FINISH_DATE ";
     $sql .= "ORDER BY assigned_to";
     $query = $this->db_tickets->query($sql, getFilter($selected_period));
     return $query->result();
 }
开发者ID:sholo,项目名称:dashboard,代码行数:12,代码来源:efficiency_model.php


示例10: get_total_effort_detailed_data

 /**
  * Gets a collection of data relevant to each point of the graph, to show details of each ticket.
  *  
  * @param int $selectedPeriod period selected for display.
  * @param String $application Application to show detail..
  * @param String $target_release Target Release to show detail.
  * 
  * @return array Information relevant to the Total Effort graph.
  * 
  */
 public function get_total_effort_detailed_data($selected_period = "x", $application, $target_release)
 {
     $this->db_tickets = $this->load->database('oracle', TRUE);
     $sql = "SELECT  ticket_id, TITLE, APPLICATION, TARGET_RELEASE,SUM(ESTIMATED_FIX_TIME) as TOTAL_EFFORT, ";
     $sql .= "PROD_DEPLOYMENT_DATE FROM vw_24fitness_all_tickets ";
     $sql .= "where PROD_DEPLOYMENT_DATE between to_date (?, 'yyyy/mm/dd') AND to_date (?, 'yyyy/mm/dd') ";
     $sql .= "AND target_release='" . $target_release . "' and application='" . $application . "' ";
     $sql .= "GROUP BY  ticket_id, TITLE, PROD_DEPLOYMENT_DATE, APPLICATION, TARGET_RELEASE ";
     $sql .= "ORDER BY target_release";
     $query = $this->db_tickets->query($sql, getFilter($selected_period));
     return $query->result();
 }
开发者ID:sholo,项目名称:dashboard,代码行数:22,代码来源:total_effort_qa_model.php


示例11: get_defect_leakage_detailed_data

 /**
  * Gets a collection of data relevant to each point of the graph, to show details of each ticket.
  *  
  * @param int $selectedPeriod period selected for display.
  * @param String $application Application to show detail..
  * @param String $target_release Target Release to show detail.
  * 
  * @return array Information relevant to the Defect Leakage and Defect Removal Rate graph.
  * 
  */
 public function get_defect_leakage_detailed_data($selected_period = "x", $application, $target_release)
 {
     $this->db_tickets = $this->load->database('oracle', TRUE);
     $sql = "SELECT ticket_id, title, APPLICATION, TARGET_RELEASE, prod_deployment_date, ";
     $sql .= "SUM(CASE WHEN TYPE_24FITNESS = 'Defect' AND (test_env like '%QA%' or test_env like '%ALL%') THEN 1 ELSE 0 END) AS DEFECT_QA, ";
     $sql .= "SUM(CASE WHEN TYPE_24FITNESS = 'Defect' AND (test_env like '%Prod%' or test_env like '%ALL%') THEN 1 ELSE 0 END) AS DEFECT_PROD ";
     $sql .= "FROM vw_24fitness_all_tickets ";
     $sql .= "WHERE (TYPE_24FITNESS = 'Defect' AND (test_env like '%QA%' or test_env like '%ALL%') OR TYPE_24FITNESS = 'Defect' AND (test_env like '%Prod%' or test_env like '%ALL%') AND ";
     $sql .= "prod_deployment_date between to_date (?, 'yyyy/mm/dd') AND ";
     $sql .= "to_date (?, 'yyyy/mm/dd')) AND target_release='" . $target_release . "' and application='" . $application . "' GROUP BY TYPE_24FITNESS, test_env, APPLICATION, TARGET_RELEASE, ticket_id, title, prod_deployment_date ";
     $query = $this->db_tickets->query($sql, getFilter($selected_period));
     return $query->result();
 }
开发者ID:sholo,项目名称:dashboard,代码行数:23,代码来源:defect_leakage_qa_model.php


示例12: get_defect_leakage_detailed_data

 public function get_defect_leakage_detailed_data($selected_period = "x", $application, $target_release)
 {
     $this->db_tickets = $this->load->database('oracle', TRUE);
     $sql = "SELECT ticket_id, title, APPLICATION, TARGET_RELEASE, PROD_DEPLOYMENT_DATE, ";
     $sql .= "SUM(CASE WHEN TYPE_24FITNESS = 'Defect' AND IT_GROUP = 'QA' THEN 1 ELSE 0 END) AS DEFECT_QA, ";
     $sql .= "SUM(CASE WHEN TYPE_24FITNESS = 'Defect' AND IT_GROUP = 'DEV' THEN 1 ELSE 0 END) AS DEFECT_PROD ";
     $sql .= "FROM vw_24fitness_all_tickets ";
     $sql .= "WHERE (TYPE_24FITNESS = 'Defect' and IT_GROUP = 'QA' OR TYPE_24FITNESS = 'Defect' AND IT_GROUP = 'DEV' AND ";
     $sql .= "TARGET_RELEASE <> 'NULL' AND ";
     $sql .= "PROD_DEPLOYMENT_DATE between to_date (?, 'yyyy/mm/dd') AND ";
     $sql .= "to_date (?, 'yyyy/mm/dd')) AND target_release='" . $target_release . "' and application='" . $application . "' GROUP BY TYPE_24FITNESS, IT_GROUP, APPLICATION, TARGET_RELEASE, ticket_id, title, PROD_DEPLOYMENT_DATE ";
     $query = $this->db_tickets->query($sql, getFilter($selected_period));
     return $query->result();
 }
开发者ID:sholo,项目名称:dashboard,代码行数:14,代码来源:defect_leakage_model.php


示例13: get_estimation_variance

 public function get_estimation_variance($selected_period = "x")
 {
     $this->db_tickets = $this->load->database('oracle', TRUE);
     $sql = "SELECT ASSIGNED_TO, ROUND(AVG((ACTUAL_EFFORT / ESTIMATED_FIX_TIME)),2) as ESTIMATION_VARIANCE ";
     $sql .= "FROM vw_24fitness_all_tickets ";
     $sql .= "WHERE ";
     $sql .= "ACTUAL_EFFORT IS NOT NULL AND ";
     $sql .= "ACTUAL_EFFORT !=0 AND ";
     $sql .= "ESTIMATED_FIX_TIME IS NOT NULL AND ";
     $sql .= "ESTIMATED_FIX_TIME !=0 AND ";
     $sql .= "IT_GROUP='BI' AND ";
     $sql .= "SCHED_FINISH_DATE IS NOT NULL AND ";
     $sql .= "SCHED_FINISH_DATE between to_date (?, 'yyyy/mm/dd') AND ";
     $sql .= "to_date (?, 'yyyy/mm/dd') ";
     $sql .= "GROUP BY ASSIGNED_TO ";
     $sql .= "ORDER BY ASSIGNED_TO";
     $query = $this->db_tickets->query($sql, getFilter($selected_period));
     return $query->result();
 }
开发者ID:sholo,项目名称:dashboard,代码行数:19,代码来源:performance_knowledge_management_model.php


示例14: get_release_size_detailed_data

 /**
  * Gets a collection of data relevant to each point of the graph, to show details of each ticket.
  *  
  * @param int $selectedPeriod period selected for display.
  * @param String $application Application to show detail..
  * @param String $target_release Target Release to show detail.
  * 
  * @return array Information relevant to the Release Size graph.
  * 
  */
 public function get_release_size_detailed_data($selected_period = "x", $application, $target_release)
 {
     $this->db_tickets = $this->load->database('oracle', TRUE);
     if ($selected_period == 'year') {
         //This is to rename the names of the months by digit, for the search in the query.
         $target_release == 'JANUARY' ? $month = 1 : '';
         $target_release == 'FEBRUARY' ? $month = 2 : '';
         $target_release == 'MARCH' ? $month = 3 : '';
         $target_release == 'APRIL' ? $month = 4 : '';
         $target_release == 'MAY' ? $month = 5 : '';
         $target_release == 'JUNE' ? $month = 6 : '';
         $target_release == 'JULY' ? $month = 7 : '';
         $target_release == 'AUGUST' ? $month = 8 : '';
         $target_release == 'SEPTEMBER' ? $month = 9 : '';
         $target_release == 'OCTOBER' ? $month = 10 : '';
         $target_release == 'NOVEMBER' ? $month = 11 : '';
         $target_release == 'DECEMBER' ? $month = 12 : '';
         $sql = "SELECT TICKET_ID, TITLE, APPLICATION, TARGET_RELEASE, assigned_to, PROD_DEPLOYMENT_DATE, SUM(actual_effort) as Release_Size \n\t\t\tFROM vw_24fitness_all_tickets \n\t\t\tWHERE PROD_DEPLOYMENT_DATE between to_date (?, 'yyyy/mm/dd') AND \n\t\t\tto_date (?, 'yyyy/mm/dd') and it_group='BI'\n\t\t\tand EXTRACT(MONTH FROM PROD_DEPLOYMENT_DATE)=" . $month . "\n      \t\tGROUP BY  ticket_id, TITLE, PROD_DEPLOYMENT_DATE, APPLICATION, TARGET_RELEASE, assigned_to, it_group";
     } else {
         $sql = "SELECT  ticket_id, title, application, target_release, assigned_to, PROD_DEPLOYMENT_DATE,\n\t\t\tit_group, SUM(actual_effort) as Release_Size, \n\t\t\tTO_CHAR(PROD_DEPLOYMENT_DATE, 'YYYY/MM') as ByYearMonth \n\t\t\tFROM vw_24fitness_all_tickets where PROD_DEPLOYMENT_DATE between to_date (?, 'yyyy/mm/dd') AND \n\t\t\tto_date (?, 'yyyy/mm/dd') and it_group='BI' AND target_release='" . $target_release . "' and \n\t\t\tapplication='" . $application . "'\n\t\t\tGROUP BY  ticket_id, TITLE, PROD_DEPLOYMENT_DATE, APPLICATION, TARGET_RELEASE, assigned_to, it_group";
     }
     $query = $this->db_tickets->query($sql, getFilter($selected_period));
     return $query->result();
 }
开发者ID:sholo,项目名称:dashboard,代码行数:34,代码来源:release_size_bi_model.php


示例15: getExpert

<?php

if (isset($_GET["expert"])) {
    $expertName = $_GET["expert"];
    $expert = getExpert($expertName);
    $expert = $expert->speaker;
} else {
    $experts = array();
    $currPage = isset($_GET["p"]) ? $_GET["p"] : 1;
    $keyword = isset($_GET["q"]) ? $_GET["q"] : "";
    $availability = isset($_GET["a"]) ? $_GET["a"] : "";
    $industry = isset($_GET["i"]) ? $_GET["i"] : "";
    $sort = isset($_GET["s"]) ? $_GET["s"] : "name";
    $pagesize = isset($_GET["n"]) ? $_GET["n"] : 10;
    $responseData = getResults($currPage, $keyword, $availability, $industry, $sort, $pagesize);
    $filters = getFilter($currPage, $keyword, $availability, $industry, $sort, $pagesize);
    $pagination = buildPagination($currPage, $responseData->total, $pagesize);
    $searchDetail = getSearchInfo($currPage, $responseData->total, $pagesize);
    $filterArray = array();
    if ($sort !== 'name') {
        $filterArray[] = 's=' . $sort;
    }
    if ($pagesize !== 10) {
        $filterArray[] = 'n=' . $pagesize;
    }
    if (!empty($filterArray)) {
        $filterString = implode('&', $filterArray);
    }
    $filter_availability = $availability;
    $filter_industry = $industry;
    $filter_keyword = $keyword;
开发者ID:wosevision,项目名称:expert-centre,代码行数:31,代码来源:_controller.php


示例16: gotoPath

/**
 * Go to a assigned path, and send the array of file objects with JSON format to client.
 * @param unknown_type $path
 */
function gotoPath($path)
{
    setCurrentPath($path);
    $file = @scandir($path);
    $files = array();
    $dotPattern = '/^(\\.){1,2}$/i';
    $suffixPattern = '/^[^\\.]\\S*(?<=\\.)(\\S+)$|^\\.\\S+(?<=\\.)(\\S+)$/i';
    //Add all files in the current path to the array $files
    foreach ($file as $val) {
        if (!preg_match($dotPattern, $val)) {
            $fullName = $path . '/' . $val;
            $f = new file();
            $f->name = $val;
            $f->type = filetype($fullName);
            $f->fileSize = filesize($fullName);
            $f->accessTime = fileatime($fullName);
            $f->modifyTime = filemtime($fullName);
            $matches = array();
            preg_match($suffixPattern, $val, $matches);
            $f->suffix = @$matches[count($matches) - 1];
            unset($matches);
            $files[] = $f;
        }
    }
    //filters
    //Search filter
    $fk = getSearchKeyword();
    $caseInsensitive = 'true' == $fk[1] ? true : false;
    $files = filtrateFileNameByKeyword($files, $fk[0], $caseInsensitive);
    //Sort filter
    $sc = getSortCriteria();
    $asc = 'true' == $sc[1] ? true : false;
    sortFiles($files, $sc[0], $asc);
    //Suffix and invisible filter
    $f = getFilter();
    $invisible = 'true' == $f[1] ? true : false;
    if (!$invisible) {
        $files = filtrateHidden($files);
    }
    $files = filtrateSuffix($files, $f[0]);
    //Send the file list to the client
    echo json_encode($files);
}
开发者ID:paul8263,项目名称:FileViewerPHPProject,代码行数:47,代码来源:fileViewerController.php


示例17: getFilterAll

<?php

$filterAlls = getFilterAll();
$filters = getFilter(Input::get('filter', array()));
$colum_number = count($filters);
if (!(in_array("Impressions", $filters) === false)) {
    $colum_number++;
}
if (!(in_array("Clicks", $filters) === false)) {
    $colum_number++;
}
?>
<!DOCTYPE html>
<html xmlns='http://www.w3.org/1999/xhtml'>
<head>
	<meta http-equiv='Content-Type' content='text/html; charset=utf-8' />
	{{ HTML::style("{$assetURL}css/excel.css") }}
</head>
<body>

<table>
	<tr class="mb12"><th colspan="{{($colum_number+1)}}"  class="brand" valign="middle">Yomedia Digital - Flight Report Summary</th></tr>
	<tr><th align="center">Campaign Name:</th><th  colspan="{{($colum_number)}}" align="center"  >{{$campaign->name}}</th></tr>
	<tr><th align="center">Duration:</th><th colspan="{{$colum_number}}" align="center">{{$campaign->dateRange}}</th></tr>
	<tr><th align="center">Advertise:</th><th colspan="{{$colum_number}}" align="center">{{$campaign->advertiser->name}}</th></tr>
	<tr><th align="center">Agency:</th><th colspan="{{$colum_number}}" align="center">{{$campaign->agency->name}}</th></tr>
</table>


@if(  !empty($listFlight) && $listFlight->count() )
	@foreach( $listFlight as $flight )
开发者ID:huycao,项目名称:yoplatform,代码行数:31,代码来源:reportExportWebsite.blade.php


示例18: getWhere

function getWhere($where)
{
    $clauses = array();
    $sql = '';
    if ($where) {
        foreach ($where as $w) {
            $clause = getFilter($w);
            if ($clause) {
                $clauses[] = $clause;
            }
        }
    }
    if ($clauses) {
        $sql = ' where ' . implode(' AND ', $clauses);
    }
    return $sql;
}
开发者ID:elislenio,项目名称:elislenio.github.io,代码行数:17,代码来源:get_phones.php


示例19: unset

    $params[$k] = ${$k};
    // unset key from params that are using default values. So URLs aren't
    // ridiculously long.
    if ($params[$k] == $v[1]) {
        unset($params[$k]);
    }
}
$vbar = ' class="vbar"';
$vwbar = ' class="vwbar"';
$vwlbar = ' class="vwlbar"';
$vbbar = ' class="vbbar"';
$vrbar = ' class="vrbar"';
$vgbar = ' class="vgbar"';
$xhprof_runs_impl = new XHProfRuns_Default();
$domainFilter = getFilter('domain_filter');
$serverFilter = getFilter('server_filter');
$domainsRS = $xhprof_runs_impl->getDistinct(array('column' => 'server_name'));
$domainFilterOptions = array("None");
while ($row = XHProfRuns_Default::getNextAssoc($domainsRS)) {
    $domainFilterOptions[] = $row['server_name'];
}
$serverRS = $xhprof_runs_impl->getDistinct(array('column' => 'server_id'));
$serverFilterOptions = array("None");
while ($row = XHProfRuns_Default::getNextAssoc($serverRS)) {
    $serverFilterOptions[] = $row['server_id'];
}
$criteria = array();
if (!is_null($domainFilter)) {
    $criteria['server_name'] = $domainFilter;
}
if (!is_null($serverFilter)) {
开发者ID:42mate,项目名称:xhprof,代码行数:31,代码来源:index.php


示例20: widget_goods

function widget_goods(&$setting, &$system)
{
    $o = $system->loadModel('goods/products');
    $limit = intval($setting['limit']) > 0 ? intval($setting['limit']) : 6;
    $config = $system->getConf('site.save_price');
    $setting['onSelect'] = $setting['onSelect'] ? $setting['onSelect'] : 0;
    $setting['max_length'] = $setting['max_length'] ? $setting['max_length'] : 35;
    $setting['view'] = $system->getConf('gallery.default_view');
    $search = $system->loadModel('goods/search');
    $setting['str'] = $search->encode($filter);
    $oSearch = $system->loadModel('goods/search');
    $output = $system->loadModel('system/frontend');
    if ($output->theme) {
        $theme_dir = $system->base_url() . 'themes/' . $output->theme;
    } else {
        $theme_dir = $system->base_url() . 'themes/' . $system->getConf('system.ui.current_theme');
    }
    $setting['titleImgSrc'] = $setting['titleImgSrc'] ? str_replace('%THEME%', $theme_dir, $setting['titleImgSrc']) : '';
    $setting['restrict'] = $setting['restrict'] ? $setting['restrict'] : 'on';
    $order = $setting['goods_orderby'] ? $o->orderBy($setting['goods_orderby']) : null;
    if ($setting['columNum'] > 1) {
        for ($i = 1; $i <= $setting['columNum']; $i++) {
            parse_str($setting['filter' . $i], $filter[$i]);
            $filter[$i] = getFilter($filter[$i]);
            if ($filter[$i]['cat_id']) {
                $setting['cat_id'] = implode(",", $filter[$i]['cat_id']);
            } else {
                $setting['cat_id'] = 0;
            }
            if ($filter[$i]['type_id'] && !is_array($filter[$i]['type_id'])) {
                $filter[$i]['type_id'] = array($filter[$i]['type_id']);
            }
            if ($filter[$i]['pricefrom']) {
                $filter[$i]['price'][0] = $filter[$i]['pricefrom'];
            }
            if ($filter[$i]['priceto']) {
                if (!$filter[$i]['price'][0]) {
                    $filter[$i]['price'][0] = 0;
                }
                $filter[$i]['price'][1] = $filter[$i]['priceto'];
            }
            $setting['link'][$i - 1] = $system->mkUrl('gallery', $setting['view'], array(implode(",", $filter[$i]['cat_id']), $oSearch->encode($filter[$i]), $setting['goods_orderby'] ? $setting['goods_orderby'] : 0));
            $result[] = $o->getList(null, $filter[$i], 0, $limit, $c, $order['sql']);
            unset($filter[$i]);
        }
        return $result;
    } else {
        parse_str($setting['filter1'], $filter);
        $filter = getFilter($filter);
        if (!is_array($filter['cat_id'])) {
            $filter['cat_id'] = array($filter['cat_id']);
        }
        if ($filter['type_id'] && !is_array($filter['type_id'])) {
            $filter['type_id'] = array($filter['type_id']);
        }
        if ($filter['pricefrom']) {
            $filter['price'][0] = $filter['pricefrom'];
        }
        if ($filter['priceto']) {
            if (!$filter['price'][0]) {
                $filter['price'][0] = 0;
            }
            $filter['price'][1] = $filter['priceto'];
        }
        $oSearch = $system->loadModel('goods/search');
        $setting['link'] = $system->mkUrl('gallery', $setting['view'], array(implode(",", $filter['cat_id']), $oSearch->encode($filter), $setting['goods_orderby'] ? $setting['goods_orderby'] : 0));
        $result = $o->getList(null, $filter, 0, $limit, $c, $order['sql']);
        return $result;
    }
}
开发者ID:dalinhuang,项目名称:shopexts,代码行数:70,代码来源:widget_goods.php



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


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP getFirstLetter函数代码示例发布时间:2022-05-15
下一篇:
PHP getFilesPath函数代码示例发布时间:2022-05-15
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap