本文整理匯總了PHP中GO\Base\Db\FindParams::debugSql方法的典型用法代碼示例。如果您正苦於以下問題:PHP FindParams::debugSql方法的具體用法?PHP FindParams::debugSql怎麽用?PHP FindParams::debugSql使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類GO\Base\Db\FindParams
的用法示例。
在下文中一共展示了FindParams::debugSql方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: beforeStoreStatement
protected function beforeStoreStatement(array &$response, array &$params, \GO\Base\Data\AbstractStore &$store, \GO\Base\Db\FindParams $storeParams)
{
$storeParams->debugSql();
$multiSel = new \GO\Base\Component\MultiSelectGrid('books', "GO\\Addressbook\\Model\\Addressbook", $store, $params, true);
$multiSel->setFindParamsForDefaultSelection($storeParams);
$multiSel->formatCheckedColumn();
return parent::beforeStoreStatement($response, $params, $store, $storeParams);
}
示例2: beforeHandleAdvancedQuery
protected function beforeHandleAdvancedQuery($advQueryRecord, \GO\Base\Db\FindCriteria &$criteriaGroup, \GO\Base\Db\FindParams &$storeParams)
{
$storeParams->debugSql();
switch ($advQueryRecord['field']) {
case 'employees.name':
$storeParams->join(\GO\Addressbook\Model\Contact::model()->tableName(), \GO\Base\Db\FindCriteria::newInstance()->addRawCondition('`t`.`id`', '`employees' . $advQueryRecord['id'] . '`.`company_id`'), 'employees' . $advQueryRecord['id']);
$criteriaGroup->addRawCondition('CONCAT_WS(\' \',`employees' . $advQueryRecord['id'] . '`.`first_name`,`employees' . $advQueryRecord['id'] . '`.`middle_name`,`employees' . $advQueryRecord['id'] . '`.`last_name`)', ':employee' . $advQueryRecord['id'], $advQueryRecord['comparator'], $advQueryRecord['andor'] == 'AND');
$criteriaGroup->addBindParameter(':employee' . $advQueryRecord['id'], $advQueryRecord['value']);
return false;
break;
default:
return true;
break;
}
}