本文整理汇总了PHP中Project::getAjaxResponse方法的典型用法代码示例。如果您正苦于以下问题:PHP Project::getAjaxResponse方法的具体用法?PHP Project::getAjaxResponse怎么用?PHP Project::getAjaxResponse使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Project
的用法示例。
在下文中一共展示了Project::getAjaxResponse方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: ChangeState
public function ChangeState($info)
{
$response = Project::getAjaxResponse();
$this->set($info);
$this->setTemplate($this->_dir, 'city_list.tpl.php');
$response->block('city_div', true, $this->parse());
}
示例2: AjaxChangeBranch
function AjaxChangeBranch($info = array())
{
$response = Project::getAjaxResponse();
$this->set($info);
$this->setTemplate($this->_dir, 'post_tag.tpl.php');
$response->block('tag_list', true, $this->parse());
}
示例3: AjaxAddPage
public function AjaxAddPage($data)
{
$this->setTemplate(null, 'page_article.tpl.php');
$this->set($data);
$response = Project::getAjaxResponse();
$response->block('pages', true, $this->parse());
//TODO: addBlock
}
示例4: AjaxSectionList
public function AjaxSectionList($data)
{
$response = Project::getAjaxResponse();
$this->setTemplate($this->_dir, 'tree.tpl.php');
$response->clearBlock('edit_block');
$response->hide('edit_block');
$this->set($data);
$response->block('list_block', true, $this->parse());
}
示例5: EditQuestion
public function EditQuestion($data)
{
$response = Project::getAjaxResponse();
$response->save();
$response->clearBlock($this->_flesh_messages_block);
$response->hide('edit_block');
$response->enable('list_block');
$data['cancel_param'] = $response->getResponse();
$response->restore();
$this->set($data);
$this->setTemplate($this->_dir, 'edit_question.tpl.php');
$response->block('edit_block', true, $this->parse());
$response->disable('list_block');
}
示例6: ReloadDropDowns
public function ReloadDropDowns($depends)
{
$response = Project::getAjaxResponse();
if (in_array('country', $depends)) {
$response->block('country_block', true, $this->_dropdown('country', 'выберите тип', '- выберите страну -', $this->countries));
}
if (in_array('city', $depends)) {
$response->block('city_block', true, $this->_dropdown('city', 'выберите страну', '- выберите город -', $this->cities));
}
if (in_array('geo_subtype', $depends)) {
$response->block('geo_subtype_block', true, $this->_dropdown('geo_subtype', 'выберите город', '- выберите тип -', $this->geo_subtypes));
}
if (in_array('geo_place', $depends)) {
$response->block('geo_place_block', true, $this->_dropdown('geo_place', 'выберите тип', '- выберите место -', $this->geo_places));
}
}
示例7: AjaxActionList
function AjaxActionList($info)
{
$response = Project::getAjaxResponse();
$response->save();
$response->hide('action_list_' . $info['controller_id']);
//$response -> enable('list_block');
$info['cancel_param'] = $response->getResponse();
$response->restore();
$number = 1;
foreach ($info['actions_list'] as &$item) {
$item['number'] = $number;
$item['change_access_link'] = AjaxRequest::getJsonParam($info['change_access_controller'], $info['change_access_action'], array('id' => $item['id'], 'gid' => $info['user_type_id'], 'cid' => $info['controller_id']));
$number++;
}
$this->set($info);
$this->setTemplate($this->_dir, 'action_list.tpl.php');
$response->block('action_list_' . $info['controller_id'], true, $this->parse());
//$response -> disable('list_block');
}
示例8: clearFlashMessages
function clearFlashMessages()
{
Project::getAjaxResponse()->clearBlock($this->_flesh_messages_block);
}
示例9: returnCorrespondentPage
function returnCorrespondentPage($message)
{
$response = Project::getAjaxResponse();
$htmlMess = "";
$i = 1;
foreach ($message['aMessages'] as $userMessage) {
if ($i / 2 == 1) {
$i = 1;
} else {
$i++;
}
$htmlMess .= '
<div class="cmod_tab' . $i . '">
<h3>' . $userMessage['author_login'] . '</h3>, <h3>' . $userMessage['header'] . '</h3>, ' . $userMessage['send_date'] . '
';
if ($userMessage['author_id'] != $this->user_id) {
$htmlMess .= '
<a href="' . Project::getRequest()->createUrl('Messages', 'SendMessage') . '/message_action:reply/mess_id:' . $userMessage['id'] . '"><b>написать сообщение</b></a> |
<a onclick="return DelMessageCorrespondence(' . $userMessage['messages_id'] . ', ' . $message['corr_user_id'] . ');" href="javascript: void(0);"><b>удалить</b></a>';
}
$htmlMess .= '
<p>
' . $userMessage['m_text'] . '
</p>
</div>';
}
$response->block('cmod_messages', true, $htmlMess);
}
示例10: ChangeStatesAction
public function ChangeStatesAction()
{
$request = Project::getRequest();
$state_id = $request->getKeyByNumber(0);
if ($state_id) {
$info = array();
$state_model = new CityModel();
$info['city_list'] = $state_model->loadByState($state_id);
$this->_view->ChangeState($info);
$this->_view->ajax();
} else {
$response = Project::getAjaxResponse();
$response->block('city_div', true, '');
$this->_view->ajax();
}
}
示例11: returnTabs
function returnTabs($message)
{
$response = Project::getAjaxResponse();
$tabs_map = $message['tabs_map'];
$htmlTopTabs = $this->getTabsNames($tabs_map, $message['user_id']);
$htmlInputs = $this->getAddTabsInputs($tabs_map);
$response->block('top_tabs', true, $htmlTopTabs);
$response->block('AddTabsInputs', true, $htmlInputs);
$response->runFunction('CloseAllTabs(1)');
}
示例12: ChangeNewsFavorite
function ChangeNewsFavorite($message)
{
$response = Project::getAjaxResponse();
if ($message['val']) {
$starGif = "star_on.gif";
} else {
$starGif = "star_off.gif";
}
$response->attribute('imgstar' . $message['newsId'], 'src', $message['imgUrl'] . $starGif);
//print_r($response -> getResponse());
}
示例13: returnArbitrationAdded
/**
* AJAX Functions
*
*/
function returnArbitrationAdded($message)
{
$response = Project::getAjaxResponse();
$response->block('complaintArbitration' . $message['item_id'], true, "Жалоба отправлена");
}
示例14: Change
function Change($info = array())
{
$response = Project::getAjaxResponse();
$response->effect("ch_" . $info['id'], 'revert');
}
示例15: helperCansay
function helperCansay($message)
{
$response = Project::getAjaxResponse();
$response->hide($message['elementId']);
}