/**
  * {@inheritdoc}
  */
 public function run()
 {
     Pjax::begin($this->pjaxOptions);
     echo Progress::widget($this->progressOptions);
     $this->registerClientScript();
     Pjax::end();
 }
示例#2
0
use hipanel\modules\ticket\menus\TemplateDetailMenu;
use hipanel\modules\ticket\models\Template;
use hipanel\widgets\Box;
use hipanel\widgets\Pjax;
use hiqdev\menumanager\widgets\DetailMenu;
use yii\helpers\Html;
/**
 * @var Template $model
 */
$this->title = $model->name;
$this->params['breadcrumbs'][] = ['label' => Yii::t('hipanel:ticket', 'Answer templates'), 'url' => ['index']];
$this->params['breadcrumbs'][] = $this->title;
?>

<?php 
Pjax::begin(Yii::$app->params['pjax']);
?>

<div class="row">
    <div class="col-md-3">
        <?php 
Box::begin(['options' => ['class' => 'box-solid'], 'bodyOptions' => ['class' => 'no-padding']]);
?>
        <div class="profile-user-img text-center">
            <i class="fa fa-file-text-o fa-5x"></i>
        </div>
        <p class="text-center">
            <span class="profile-user-role"><?php 
echo $model->name;
?>
</span>
示例#3
0
<?php

use hipanel\modules\dns\grid\ZoneGridView;
use hipanel\widgets\IndexPage;
use hipanel\widgets\Pjax;
use yii\helpers\Html;
use yii\helpers\Url;
$this->title = Yii::t('hipanel:dns', 'DNS zones');
$this->params['subtitle'] = array_filter(Yii::$app->request->get($model->formName(), [])) ? Yii::t('hipanel', 'filtered list') : Yii::t('hipanel', 'full list');
$this->params['breadcrumbs'][] = $this->title;
?>

<?php 
Pjax::begin(array_merge(Yii::$app->params['pjax'], ['enablePushState' => true]));
?>
    <?php 
$page = IndexPage::begin(compact('model', 'dataProvider'));
?>

        <?php 
echo $page->setSearchFormData(compact([]));
?>

        <?php 
$page->beginContent('main-actions');
?>
        <?php 
$page->endContent();
?>

        <?php 
 * @var Thread
 */
$form = ConditionalFormWidget::begin(['form' => isset($form) ? $form : null, 'options' => ['id' => 'left-block-comment-form', 'action' => $action, 'options' => ['enctype' => 'multipart/form-data']]]);
?>
<div class="row page-ticket">
    <div class="col-md-12">
        <?php 
echo Html::a(Yii::t('hipanel:ticket', 'Back to index'), ['index'], ['class' => 'btn btn-primary btn-block btn-sm', 'style' => $model->isNewRecord ? 'margin-bottom: 20px;' : 'margin-bottom: 5px;']);
?>
        <?php 
if (!$model->isNewRecord) {
    ?>
            <?php 
    $openTicketText = Yii::t('hipanel:ticket', 'Open ticket');
    $closeTicketText = Yii::t('hipanel:ticket', 'Close ticket');
    Pjax::begin(array_merge(Yii::$app->params['pjax'], ['id' => 'stateTicketButton', 'enablePushState' => false, 'clientOptions' => ['type' => 'POST', 'data' => ["{$model->formName()}[id]" => $model->id]]]));
    ?>
            <?php 
    if ($model->state == Thread::STATE_CLOSE) {
        ?>
                <?php 
        echo Html::a($openTicketText, ['open'], HtmlHelper::loadingButtonOptions(['class' => 'btn btn-block btn-sm margin-bottom btn-warning']));
        ?>
            <?php 
    } else {
        ?>
                <?php 
        echo Html::a($closeTicketText, ['close'], HtmlHelper::loadingButtonOptions(['class' => 'btn btn-block btn-sm margin-bottom btn-danger']));
        ?>
            <?php 
    }
示例#5
0
use hipanel\modules\dns\models\Record;
use hipanel\modules\dns\models\Zone;
use hipanel\widgets\Pjax;
use yii\data\ArrayDataProvider;
use yii\helpers\Html;
use yii\web\View;
/*
 * @var $this View
 * @var $model Zone
 * @var $recordsDataProvider ArrayDataProvider
 */
$this->title = $model->domain;
$this->params['subtitle'] = Yii::t('hipanel:dns', 'DNS zone for domain {domain}', ['domain' => $model->domain]) . ' #' . $model->id;
$this->params['breadcrumbs'][] = ['label' => Yii::t('hipanel:dns', 'DNS'), 'url' => ['@dns/zone/index']];
$this->params['breadcrumbs'][] = $this->title;
Pjax::begin(['id' => 'dns_zone_view', 'enablePushState' => false]);
$records = $recordsDataProvider->getModels();
$ns_servers = [];
foreach ($records as $record) {
    if ($record->type === 'ns' && $record->service_id) {
        $ns_servers[] = $record['value'];
    }
}
\hipanel\helpers\ArrayHelper::multisort($ns_servers, 0);
?>

    <?php 
if ($model->is_served === false && count($ns_servers)) {
    ?>
        <div class="alert alert-warning alert-dismissible fade in" role="alert">
            <h4><i class="fa fa-warning-circle"></i>&nbsp;&nbsp;<?php 
<?php

/*
 * Domain plugin for HiPanel
 *
 * @link      https://github.com/hiqdev/hipanel-module-domain
 * @package   hipanel-module-domain
 * @license   BSD-3-Clause
 * @copyright Copyright (c) 2015-2016, HiQDev (http://hiqdev.com/)
 */
use hipanel\widgets\Pjax;
use yii\helpers\Html;
use yii\web\JsExpression;
Pjax::begin(array_merge(Yii::$app->params['pjax'], ['id' => 'domain-view-sync-button']));
echo Html::a('<i class="fa fa-fw fa-refresh"></i>&nbsp;' . Yii::t('hipanel:domain', 'Synchronize contacts'), ['sync', 'id' => $model->id], ['id' => 'test123', 'data' => ['pjax' => true, 'method' => 'post', 'params' => ["{$model->formName()}[id]" => $model->id], 'pjax-push-state' => false, 'pjax-container' => '#domain-view-sync-button', 'pjax-skip-outer-containers' => true], 'onClick' => new JsExpression("\$(this).html('<i class=\"fa fa-fw fa-refresh\">&nbsp;" . Yii::t('hipanel', 'loading...') . "');")]);
Pjax::end();
示例#7
0
use hipanel\widgets\DynamicFormWidget;
use hipanel\widgets\Pjax;
use hiqdev\combo\StaticCombo;
use yii\bootstrap\ActiveForm;
use yii\bootstrap\Html;
use yii\helpers\Url;
use yii\web\JsExpression;
// TODO: To delete this
NSyncPluginAsset::register($this);
/*
 * @var array|string $actionUrl url to send the form
 */
?>

<?php 
Pjax::begin(['id' => 'nss-pjax-container', 'enablePushState' => false, 'enableReplaceState' => false]);
$this->registerJs("\n\$('#nss-form-pjax').NSync();\n\n\$(document).on('pjax:send', function(event) {\n    event.preventDefault();\n    \$('#nss-save-button').button('loading');\n\n});\n\$(document).on('pjax:complete', function(event) {\n  event.preventDefault();\n  \$('#nss-save-button').button('reset');\n  \$('.modal').modal('hide');\n});\n");
$form = ActiveForm::begin(['id' => 'nss-form-pjax', 'action' => $actionUrl, 'enableAjaxValidation' => true, 'enableClientValidation' => true, 'validationUrl' => Url::toRoute(['validate-nss', 'scenario' => 'default']), 'options' => ['data-pjax' => true, 'data-pjaxPush' => false]]);
?>
    <?php 
if (!is_array($model)) {
    ?>
        <?php 
    echo Html::activeHiddenInput($model, 'id');
    ?>
        <?php 
    echo Html::activeHiddenInput($model, 'domain');
    ?>
    <?php 
} else {
    ?>
示例#8
0
use hipanel\modules\domain\grid\HostGridView;
use hipanel\modules\domain\menus\HostDetailMenu;
use hipanel\widgets\Box;
use hipanel\widgets\ClientSellerLink;
use hipanel\widgets\Pjax;
use hiqdev\menumanager\widgets\DetailMenu;
use yii\helpers\Html;
$this->title = Html::encode($model->host);
$this->params['subtitle'] = Yii::t('hipanel:domain', 'Name server detailed information') . ' #' . $model->id;
$this->params['breadcrumbs'][] = ['label' => Yii::t('hipanel:domain', 'Name Servers'), 'url' => ['index']];
$this->params['breadcrumbs'][] = $this->title;
?>

<?php 
Pjax::begin();
?>
    <div class="row" xmlns="http://www.w3.org/1999/html">
        <div class="col-md-3">
            <?php 
Box::begin(['options' => ['class' => 'box-solid'], 'bodyOptions' => ['class' => 'no-padding']]);
?>
                <div class="profile-user-img text-center">
                    <i class="fa fa-globe" style="font-size:7em"></i>
                </div>
                <p class="text-center">
                    <span class="profile-user-role"><?php 
echo $this->title;
?>
</span>
                    <br>