本文整理汇总了PHP中fRecordSet::tally方法的典型用法代码示例。如果您正苦于以下问题:PHP fRecordSet::tally方法的具体用法?PHP fRecordSet::tally怎么用?PHP fRecordSet::tally使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类fRecordSet
的用法示例。
在下文中一共展示了fRecordSet::tally方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: testTallyWithWhereConditionInvalidColumn
public function testTallyWithWhereConditionInvalidColumn()
{
$this->setExpectedException('fProgrammerException');
$set = fRecordSet::tally('User', array('email=' => 'will@flourishlib.com'));
}
示例2: hasAnswers
protected function hasAnswers()
{
if ($this->buildGlobalAnswers()->count() > 0) {
return true;
}
// Find both global and individual answers
$questionIds = fRecordSet::build('WpTesting_Model_Question', array('test_id=' => $this->getId()))->getPrimaryKeys();
return fRecordSet::tally('WpTesting_Model_Answer', array('question_id=' => $questionIds)) > 0;
}
示例3: countAllByFilter
public static function countAllByFilter($graph_id, $filter)
{
return fRecordSet::tally(__CLASS__, array('graph_id=' => $graph_id, 'target|alias~' => $filter));
}
示例4: countAllByFilter
public static function countAllByFilter($dashboard_id, $filter)
{
return fRecordSet::tally(__CLASS__, array('dashboard_id=' => $dashboard_id, 'name|vtitle|description~' => $filter));
}