示例#1
0
    $options = array_merge(['title' => Yii::t('google_analytics', 'Update'), 'aria-label' => Yii::t('google_analytics', 'Update'), 'data-pjax' => '0'], []);
    return '<li>' . Html::a('<span class="glyphicon glyphicon-pencil"></span> ' . Yii::t('google_analytics', 'Update'), $url, $options) . '</li>';
}, 'delete' => function ($url) {
    $options = array_merge(['title' => Yii::t('google_analytics', 'Delete'), 'aria-label' => Yii::t('google_analytics', 'Delete'), 'data-confirm' => Yii::t('google_analytics', 'Are you sure you want to delete this tracking configuration? All data related to this item will be deleted. This action cannot be undone.'), 'data-method' => 'post', 'data-pjax' => '0'], []);
    return '<li>' . Html::a('<span class="glyphicon glyphicon-bin"></span> ' . Yii::t('google_analytics', 'Delete'), $url, $options) . '</li>';
}]]];
?>
<div class="google-analytics-index">
    <div class="row">
        <div class="col-md-12">
            <?php 
echo GridView::widget(['id' => 'google-analytics-grid', 'dataProvider' => $dataProvider, 'columns' => $gridColumns, 'resizableColumns' => false, 'pjax' => false, 'export' => false, 'responsive' => true, 'bordered' => false, 'striped' => true, 'panelTemplate' => '<div class="panel {type}">
                    {panelHeading}
                    {panelBefore}
                    {items}
                    <div style="text-align: center">{pager}</div>
                </div>', 'panel' => ['type' => GridView::TYPE_INFO, 'heading' => Yii::t('google_analytics', 'Google Analytics') . ' <small class="panel-subtitle hidden-xs">' . Yii::t('google_analytics', 'Start Tracking!') . '</small>', 'footer' => false, 'before' => !empty(Yii::$app->user) && Yii::$app->user->can("admin") ? ActionBar::widget(['grid' => 'google-analytics-grid', 'templates' => ['{create}' => ['class' => 'col-xs-6 col-md-8'], '{bulk-actions}' => ['class' => 'col-xs-6 col-md-2 col-md-offset-2']], 'elements' => ['create' => Html::a('<span class="glyphicon glyphicon-plus"></span> ' . Yii::t('google_analytics', 'Create Form Tracking'), ['create'], ['class' => 'btn btn-primary']) . Html::a(Html::tag('span', '', ['class' => 'glyphicon glyphicon-question-sign', 'style' => 'font-size: 18px; color: #6e8292; vertical-align: -3px']), false, ['data-toggle' => 'tooltip', 'data-placement' => 'top', 'title' => Yii::t('google_analytics', "With this add-on, Google Analytics will be added directly to your form to track successful submissions and provide more insights on your form's performance."), 'class' => 'text hidden-xs hidden-sm'])], 'bulkActionsItems' => [Yii::t('google_analytics', 'Update Status') => ['status-active' => Yii::t('google_analytics', 'Active'), 'status-inactive' => Yii::t('google_analytics', 'Inactive')], 'General' => ['general-delete' => 'Delete']], 'bulkActionsOptions' => ['options' => ['status-active' => ['url' => Url::toRoute(['update-status', 'status' => 1])], 'status-inactive' => ['url' => Url::toRoute(['update-status', 'status' => 0])], 'general-delete' => ['url' => Url::toRoute('delete-multiple'), 'data-confirm' => Yii::t('google_analytics', 'Are you sure you want to delete these tracking configurations? All data related to each item will be deleted. This action cannot be undone.')]], 'class' => 'form-control']]) : null], 'toolbar' => false]);
?>
        </div>
    </div>
</div>
<?php 
$js = <<<'SCRIPT'

$(function () {
    $("[data-toggle='tooltip']").tooltip();
});;

SCRIPT;
// Register tooltip/popover initialization javascript
$this->registerJs($js);
示例#2
0
$this->title = $categoryModel->name . ' ' . Yii::t('app', 'Templates');
$this->params['breadcrumbs'][] = ['label' => Yii::t('app', 'Templates'), 'url' => ['index']];
$this->params['breadcrumbs'][] = ['label' => Yii::t('app', 'Categories'), 'url' => ['/categories']];
$this->params['breadcrumbs'][] = $this->title;
Carbon::setLocale(substr(Yii::$app->language, 0, 2));
// eg. en-US to en
?>
<div class="template-index">

    <?php 
echo GridView::widget(['id' => 'template-grid', 'dataProvider' => $dataProvider, 'resizableColumns' => false, 'pjax' => false, 'export' => false, 'responsive' => true, 'bordered' => false, 'striped' => true, 'panelTemplate' => '<div class="panel {type}">
            {panelHeading}
            {panelBefore}
            {items}
            <div style="text-align: center">{pager}</div>
        </div>', 'panel' => ['type' => GridView::TYPE_INFO, 'heading' => Html::encode($categoryModel->name) . ' <small class="panel-subtitle hidden-xs">' . Yii::t('app', 'Templates') . '</small>', 'footer' => false, 'before' => ActionBar::widget(['grid' => 'template-grid', 'templates' => ['{create}' => ['class' => 'col-xs-6 col-md-8'], '{bulk-actions}' => ['class' => 'col-xs-6 col-md-2 col-md-offset-2']], 'elements' => ['create' => Html::a('<span class="glyphicon glyphicon-plus"></span> ' . Yii::t('app', 'Create Template'), ['create'], ['class' => 'btn btn-primary']) . ' ' . Html::a(Yii::t('app', 'Why to promote a Template?'), ['/categories'], ['data-toggle' => 'tooltip', 'data-placement' => 'top', 'title' => Yii::t('app', 'The promoted templates will appear next "Create Form" button in the Form Manager.
                                    You can create forms based on these templates with one click!'), 'class' => 'text hidden-xs hidden-sm'])], 'bulkActionsItems' => [Yii::t('app', 'Update Promotion') => ['promoted' => Yii::t('app', 'Promoted'), 'non-promoted' => Yii::t('app', 'Non-Promoted')], Yii::t('app', 'General') => ['general-delete' => Yii::t('app', 'Delete')]], 'bulkActionsOptions' => ['options' => ['promoted' => ['url' => Url::toRoute(['update-promotion', 'promoted' => 1])], 'non-promoted' => ['url' => Url::toRoute(['update-promotion', 'promoted' => 0])], 'general-delete' => ['url' => Url::toRoute('delete-multiple'), 'data-confirm' => Yii::t('app', 'Are you sure you want to delete these templates? All data related to each item will be deleted. This action cannot be undone.')]], 'class' => 'form-control'], 'class' => 'form-control'])], 'toolbar' => false, 'columns' => [['class' => '\\kartik\\grid\\CheckboxColumn', 'headerOptions' => ['class' => 'kartik-sheet-style'], 'rowSelectedClass' => GridView::TYPE_WARNING], ['attribute' => 'name', 'format' => 'raw', 'value' => function ($model) {
    return Html::a(Html::encode($model->name), ['templates/view', 'id' => $model->id]);
}], ['class' => 'kartik\\grid\\BooleanColumn', 'attribute' => 'promoted', 'trueIcon' => '<span class="glyphicon glyphicon-star text-success"></span>', 'falseIcon' => '<span class="glyphicon glyphicon-star-empty text-default"></span>', 'vAlign' => 'middle'], ['attribute' => 'author', 'value' => 'author.username', 'label' => Yii::t('app', 'Created by')], ['attribute' => 'updated_at', 'value' => function ($model) {
    if (isset($model->updated_at)) {
        return Carbon::createFromTimestampUTC($model->updated_at)->diffForHumans();
    }
    return null;
}, 'label' => Yii::t('app', 'Updated')], ['class' => 'kartik\\grid\\ActionColumn', 'dropdown' => true, 'dropdownButton' => ['class' => 'btn btn-primary'], 'dropdownOptions' => ['class' => 'pull-right'], 'buttons' => ['update' => function ($url) {
    $options = array_merge(['title' => Yii::t('app', 'Update'), 'aria-label' => Yii::t('app', 'Update'), 'data-pjax' => '0'], []);
    return '<li>' . Html::a('<span class="glyphicon glyphicon-pencil"></span> ' . Yii::t('app', 'Update'), $url, $options) . '</li>';
}, 'settings' => function ($url) {
    return '<li>' . Html::a('<span class="glyphicon glyphicon-cogwheel"> </span> ' . Yii::t('app', 'Settings'), $url, ['title' => Yii::t('app', 'Settings')]) . '</li>';
}, 'createForm' => function ($url) {
    return '<li>' . Html::a('<span class="glyphicon glyphicon-plus"> </span> ' . Yii::t('app', 'Create Form'), $url, ['title' => Yii::t('app', 'Create Form')]) . '</li>';
}, 'view' => function ($url) {
    $options = array_merge(['title' => Yii::t('app', 'View Record'), 'aria-label' => Yii::t('app', 'View Record'), 'data-pjax' => '0'], []);
示例#3
0
/* @var $dataProvider yii\data\ActiveDataProvider */
$this->title = Yii::t('app', 'Templates By Categories');
$this->params['breadcrumbs'][] = ['label' => Yii::t('app', 'Templates'), 'url' => ['/templates']];
$this->params['breadcrumbs'][] = $this->title;
Carbon::setLocale(substr(Yii::$app->language, 0, 2));
// eg. en-US to en
?>
<div class="template-category-index">

    <?php 
echo GridView::widget(['id' => 'template-category-grid', 'dataProvider' => $dataProvider, 'resizableColumns' => false, 'pjax' => false, 'export' => false, 'responsive' => true, 'bordered' => false, 'striped' => true, 'panelTemplate' => '<div class="panel {type}">
            {panelHeading}
            {panelBefore}
            {items}
            <div style="text-align: center">{pager}</div>
        </div>', 'panel' => ['type' => GridView::TYPE_INFO, 'heading' => Yii::t('app', 'Templates') . ' <small class="panel-subtitle hidden-xs">' . Yii::t('app', 'By Categories') . '</small>', 'footer' => false, 'before' => ActionBar::widget(['grid' => 'template-category-grid', 'templates' => ['{create}' => ['class' => 'col-xs-6 col-md-8'], '{bulk-actions}' => ['class' => 'col-xs-6 col-md-2 col-md-offset-2']], 'bulkActionsItems' => [Yii::t('app', 'General') => ['general-delete' => Yii::t('app', 'Delete')]], 'bulkActionsOptions' => ['options' => ['general-delete' => ['url' => Url::toRoute('delete-multiple'), 'data-confirm' => Yii::t('app', 'Are you sure you want to delete these template categories? All data related to each item will be deleted. This action cannot be undone.')]], 'class' => 'form-control'], 'elements' => ['create' => Html::a('<span class="glyphicon glyphicon-plus"></span> ' . Yii::t('app', 'Create Category'), ['create'], ['class' => 'btn btn-primary']) . ' ' . Html::a(Yii::t('app', 'Need to extend the app functionality?'), ['/addons'], ['data-toggle' => 'tooltip', 'data-placement' => 'top', 'title' => Yii::t('app', 'With our add-ons you can add great features and integrations to your forms. Try them now!'), 'class' => 'text hidden-xs hidden-sm'])], 'class' => 'form-control'])], 'toolbar' => false, 'columns' => [['class' => '\\kartik\\grid\\CheckboxColumn', 'headerOptions' => ['class' => 'kartik-sheet-style'], 'rowSelectedClass' => GridView::TYPE_WARNING], ['attribute' => 'name', 'format' => 'raw', 'value' => function ($model) {
    return Html::a(Html::encode($model->name), ['templates/category', 'id' => $model->id]);
}], ['attribute' => 'description', 'value' => function ($model) {
    if (isset($model->description)) {
        return StringHelper::truncateWords(Html::encode($model->description), 15);
    }
    return null;
}], ['attribute' => 'updated_at', 'value' => function ($model) {
    if (isset($model->updated_at)) {
        return Carbon::createFromTimestampUTC($model->updated_at)->diffForHumans();
    }
    return null;
}, 'label' => Yii::t('app', 'Last updated')], ['class' => 'kartik\\grid\\ActionColumn', 'dropdown' => true, 'dropdownButton' => ['class' => 'btn btn-primary'], 'dropdownOptions' => ['class' => 'pull-right'], 'buttons' => ['view' => function ($url) {
    $options = array_merge(['title' => Yii::t('app', 'View'), 'aria-label' => Yii::t('app', 'View'), 'data-pjax' => '0'], []);
    return '<li>' . Html::a('<span class="glyphicon glyphicon-eye-open"></span> ' . Yii::t('app', 'View Record'), $url, $options) . '</li>';
}, 'update' => function ($url) {
示例#4
0
    $options = array_merge(['title' => Yii::t('webhooks', 'Update'), 'aria-label' => Yii::t('webhooks', 'Update'), 'data-pjax' => '0'], []);
    return '<li>' . Html::a('<span class="glyphicon glyphicon-pencil"></span> ' . Yii::t('webhooks', 'Update'), $url, $options) . '</li>';
}, 'delete' => function ($url) {
    $options = array_merge(['title' => Yii::t('webhooks', 'Delete'), 'aria-label' => Yii::t('webhooks', 'Delete'), 'data-confirm' => Yii::t('webhooks', 'Are you sure you want to delete this webhook? All data related to this item will be deleted. This action cannot be undone.'), 'data-method' => 'post', 'data-pjax' => '0'], []);
    return '<li>' . Html::a('<span class="glyphicon glyphicon-bin"></span> ' . Yii::t('webhooks', 'Delete'), $url, $options) . '</li>';
}]]];
?>
    <div class="google-analytics-index">
        <div class="row">
            <div class="col-md-12">
                <?php 
echo GridView::widget(['id' => 'webhooks-grid', 'dataProvider' => $dataProvider, 'columns' => $gridColumns, 'resizableColumns' => false, 'pjax' => false, 'export' => false, 'responsive' => true, 'bordered' => false, 'striped' => true, 'panelTemplate' => '<div class="panel {type}">
                    {panelHeading}
                    {panelBefore}
                    {items}
                    <div style="text-align: center">{pager}</div>
                </div>', 'panel' => ['type' => GridView::TYPE_INFO, 'heading' => Yii::t('webhooks', 'Webhooks') . ' <small class="panel-subtitle hidden-xs">' . Yii::t('webhooks', 'Send notifications to another server') . '</small>', 'footer' => false, 'before' => !empty(Yii::$app->user) && Yii::$app->user->can("admin") ? ActionBar::widget(['grid' => 'webhooks-grid', 'templates' => ['{create}' => ['class' => 'col-xs-6 col-md-8'], '{bulk-actions}' => ['class' => 'col-xs-6 col-md-2 col-md-offset-2']], 'elements' => ['create' => Html::a('<span class="glyphicon glyphicon-plus"></span> ' . Yii::t('webhooks', 'Create a WebHook'), ['create'], ['class' => 'btn btn-primary']) . Html::a(Html::tag('span', '', ['class' => 'glyphicon glyphicon-question-sign', 'style' => 'font-size: 18px; color: #6e8292; vertical-align: -3px']), false, ['data-toggle' => 'tooltip', 'data-placement' => 'top', 'title' => Yii::t('webhooks', "A WebHook is just a push notification from us to another server every time someone submits a form."), 'class' => 'text hidden-xs hidden-sm'])], 'bulkActionsItems' => [Yii::t('webhooks', 'Update Status') => ['status-active' => Yii::t('webhooks', 'Active'), 'status-inactive' => Yii::t('webhooks', 'Inactive')], 'General' => ['general-delete' => 'Delete']], 'bulkActionsOptions' => ['options' => ['status-active' => ['url' => Url::toRoute(['update-status', 'status' => 1])], 'status-inactive' => ['url' => Url::toRoute(['update-status', 'status' => 0])], 'general-delete' => ['url' => Url::toRoute('delete-multiple'), 'data-confirm' => Yii::t('webhooks', 'Are you sure you want to delete these webhooks? All data related to each item will be deleted. This action cannot be undone.')]], 'class' => 'form-control']]) : null], 'toolbar' => false]);
?>
            </div>
        </div>
    </div>
<?php 
$js = <<<'SCRIPT'

$(function () {
    $("[data-toggle='tooltip']").tooltip();
});;

SCRIPT;
// Register tooltip/popover initialization javascript
$this->registerJs($js);
示例#5
0
}, 'update' => function ($url) {
    $options = array_merge(['title' => Yii::t('app', 'Update'), 'aria-label' => Yii::t('app', 'Update'), 'data-pjax' => '0'], []);
    return '<li>' . Html::a('<span class="glyphicon glyphicon-pencil"></span> ' . Yii::t('app', 'Update'), $url, $options) . '</li>';
}, 'delete' => function ($url) {
    $options = array_merge(['title' => Yii::t('app', 'Delete'), 'aria-label' => Yii::t('app', 'Delete'), 'data-confirm' => Yii::t('app', 'Are you sure you want to delete this user? All data related to this item will be deleted. This action cannot be undone.'), 'data-method' => 'post', 'data-pjax' => '0'], []);
    return '<li>' . Html::a('<span class="glyphicon glyphicon-bin"></span> ' . Yii::t('app', 'Delete'), $url, $options) . '</li>';
}]]];
?>

<div class="user-index">

    <?php 
echo GridView::widget(['id' => 'user-grid', 'dataProvider' => $dataProvider, 'columns' => $gridColumns, 'resizableColumns' => false, 'pjax' => false, 'export' => false, 'responsive' => true, 'bordered' => false, 'striped' => true, 'panelTemplate' => '<div class="panel {type}">
            {panelHeading}
            {panelBefore}
            {items}
            <div style="text-align: center">{pager}</div>
        </div>', 'panel' => ['type' => GridView::TYPE_INFO, 'heading' => Yii::t('app', 'Users') . '<small class="panel-subtitle hidden-xs">' . Yii::t('app', 'Securely Access to each Form') . '</small>', 'footer' => false, 'before' => ActionBar::widget(['grid' => 'user-grid', 'templates' => ['{create}' => ['class' => 'col-xs-6'], '{help}' => ['class' => 'col-xs-6']], 'elements' => ['create' => Html::a('<span class="glyphicon glyphicon-plus"></span> ' . Yii::t('app', 'Create User'), ['create'], ['class' => 'btn btn-primary']), 'help' => '<div class="pull-right">' . $this->render('_search', ['model' => $searchModel]) . '</div>'], 'class' => 'form-control'])], 'toolbar' => false]);
?>

</div>
<?php 
$js = <<<'SCRIPT'

$(function () {
    $("[data-toggle='tooltip']").tooltip();
});;

SCRIPT;
// Register tooltip/popover initialization javascript
$this->registerJs($js);
示例#6
0
    $options = array_merge(['title' => Yii::t('app', 'View'), 'aria-label' => Yii::t('app', 'View'), 'data-pjax' => '0'], []);
    return '<li>' . Html::a('<span class="glyphicon glyphicon-eye-open"></span> ' . Yii::t('app', 'View Record'), $url, $options) . '</li>';
}, 'update' => function ($url) {
    $options = array_merge(['title' => Yii::t('app', 'Update'), 'aria-label' => Yii::t('app', 'Update'), 'data-pjax' => '0'], []);
    return '<li>' . Html::a('<span class="glyphicon glyphicon-pencil"></span> ' . Yii::t('app', 'Update'), $url, $options) . '</li>';
}, 'delete' => function ($url) {
    $options = array_merge(['title' => Yii::t('app', 'Delete'), 'aria-label' => Yii::t('app', 'Delete'), 'data-confirm' => Yii::t('app', 'Are you sure you want to delete this theme? All data related to this item will be deleted. This action cannot be undone.'), 'data-method' => 'post', 'data-pjax' => '0'], []);
    return '<li>' . Html::a('<span class="glyphicon glyphicon-bin"></span> ' . Yii::t('app', 'Delete'), $url, $options) . '</li>';
}]]];
?>

    <?php 
echo GridView::widget(['id' => 'theme-grid', 'dataProvider' => $dataProvider, 'columns' => $gridColumns, 'resizableColumns' => false, 'pjax' => false, 'export' => false, 'responsive' => true, 'bordered' => false, 'striped' => true, 'panelTemplate' => '<div class="panel {type}">
            {panelHeading}
            {panelBefore}
            {items}
            <div style="text-align: center">{pager}</div>
        </div>', 'panel' => ['type' => GridView::TYPE_INFO, 'heading' => Yii::t('app', 'Themes') . ' <small class="panel-subtitle hidden-xs">' . Yii::t('app', 'Style & brand your online forms') . '</small>', 'footer' => false, 'before' => ActionBar::widget(['grid' => 'theme-grid', 'templates' => ['{create}' => ['class' => 'col-xs-6 col-md-8'], '{bulk-actions}' => ['class' => 'col-xs-6 col-md-2 col-md-offset-2']], 'bulkActionsItems' => ['General' => ['general-delete' => Yii::t('app', 'Delete')]], 'bulkActionsOptions' => ['options' => ['general-delete' => ['url' => Url::toRoute('delete-multiple'), 'data-confirm' => Yii::t('app', 'Are you sure you want to delete these themes? All data related to each item will be deleted. This action cannot be undone.')]], 'class' => 'form-control'], 'elements' => ['create' => Html::a('<span class="glyphicon glyphicon-plus"></span> ' . Yii::t('app', 'Create Theme'), ['create'], ['class' => 'btn btn-primary']) . ' ' . Html::a(Yii::t('app', 'Do you know how to customize your form?'), ['/form'], ['data-toggle' => 'tooltip', 'data-placement' => 'top', 'title' => Yii::t('app', 'It’s very easy. Just go to Form Manager, then click on the form Settings to customize and click on the UI Settings tab. Finally choose your theme.'), 'class' => 'text hidden-xs hidden-sm'])], 'class' => 'form-control'])], 'toolbar' => false]);
?>

</div>
<?php 
$js = <<<'SCRIPT'

$(function () {
    $("[data-toggle='tooltip']").tooltip();
});

SCRIPT;
// Register tooltip/popover initialization javascript
$this->registerJs($js);
示例#7
0
    if ($model->installed && $model->status) {
        return Html::a(Html::encode($model->name), ['/addons/' . $model->id]);
    }
    return $model->name;
}], ['attribute' => 'version', 'value' => 'version'], ['class' => 'kartik\\grid\\BooleanColumn', 'attribute' => 'installed', 'trueIcon' => '<span class="glyphicon glyphicon-ok text-success"></span>', 'falseIcon' => '<span class="glyphicon glyphicon-remove text-danger"></span>', 'vAlign' => 'middle'], ['class' => 'kartik\\grid\\BooleanColumn', 'attribute' => 'status', 'trueIcon' => '<span class="glyphicon glyphicon-ok text-success"></span>', 'falseIcon' => '<span class="glyphicon glyphicon-remove text-danger"></span>', 'vAlign' => 'middle'], ['attribute' => 'description', 'value' => 'description']];
?>
<div class="addons-index">
    <div class="row">
        <div class="col-md-12">
            <?php 
echo GridView::widget(['id' => 'addons-grid', 'dataProvider' => $dataProvider, 'columns' => $gridColumns, 'resizableColumns' => false, 'pjax' => false, 'export' => false, 'responsive' => true, 'bordered' => false, 'striped' => true, 'panelTemplate' => '<div class="panel {type}">
                    {panelHeading}
                    {panelBefore}
                    {items}
                    <div style="text-align: center">{pager}</div>
                </div>', 'panel' => ['type' => GridView::TYPE_INFO, 'heading' => Yii::t('addon', 'Add-ons') . ' <small class="panel-subtitle hidden-xs">' . Yii::t('addon', 'Extend and Expand the functionality of your forms') . '</small>', 'footer' => false, 'before' => !empty(Yii::$app->user) && Yii::$app->user->can("admin") ? ActionBar::widget(['grid' => 'addons-grid', 'templates' => ['{refresh}' => ['class' => 'col-xs-6 col-md-8'], '{bulk-actions}' => ['class' => 'col-xs-6 col-md-2 col-md-offset-2']], 'bulkActionsItems' => [Yii::t('addon', 'Update Status') => ['status-active' => Yii::t('addon', 'Active'), 'status-inactive' => Yii::t('addon', 'Inactive')], Yii::t('addon', 'General') => ['install' => Yii::t('addon', 'Install'), 'uninstall' => Yii::t('addon', 'Uninstall')]], 'bulkActionsOptions' => ['options' => ['status-active' => ['url' => Url::toRoute(['update-status', 'status' => 1])], 'status-inactive' => ['url' => Url::toRoute(['update-status', 'status' => 0])], 'install' => ['url' => Url::toRoute(['install'])], 'uninstall' => ['url' => Url::toRoute(['uninstall']), 'data-confirm' => Yii::t('addon', 'Are you sure you want to uninstall these add-ons? All data related to each item will be deleted. This action cannot be undone.')]], 'class' => 'form-control'], 'elements' => ['refresh' => Html::a(Html::tag('span', '', ['class' => 'glyphicon glyphicon-refresh']) . ' ' . Yii::t('addon', 'Refresh'), ['refresh'], ['class' => 'btn btn-primary']) . Html::a(Html::tag('span', '', ['class' => 'glyphicon glyphicon-question-sign', 'style' => 'font-size: 18px; color: #6e8292; vertical-align: -3px']), false, ['data-toggle' => 'tooltip', 'data-placement' => 'top', 'title' => Yii::t('addon', 'Use the “Refresh” button to see new Add-ons, after upload
                                                or delete add-on’s files.'), 'class' => 'text hidden-xs hidden-sm'])], 'class' => 'form-control']) : null], 'toolbar' => false]);
?>
        </div>
    </div>
</div>
<?php 
$js = <<<'SCRIPT'

$(function () {
    $("[data-toggle='tooltip']").tooltip();
});;

SCRIPT;
// Register tooltip/popover initialization javascript
$this->registerJs($js);
示例#8
0
    return '';
}, 'template' => '{update} {settings} {rules} {view} {share} {submissions} {report} {analytics} {delete}']];
?>

<div class="form-index">
    <div class="row">
        <div class="col-md-12">
            <?php 
echo GridView::widget(['id' => 'form-grid', 'dataProvider' => $dataProvider, 'columns' => $gridColumns, 'resizableColumns' => false, 'pjax' => false, 'export' => false, 'responsive' => true, 'bordered' => false, 'striped' => true, 'panelTemplate' => '<div class="panel {type}">
                    {panelHeading}
                    {panelBefore}
                    {items}
                    <div style="text-align: center">{pager}</div>
                </div>', 'panel' => ['type' => GridView::TYPE_INFO, 'heading' => Yii::t('app', 'Forms') . ' <small class="panel-subtitle hidden-xs">' . Yii::t('app', 'Build any type of online form') . '</small>', 'footer' => false, 'before' => !empty(Yii::$app->user) && Yii::$app->user->can("admin") ? ActionBar::widget(['grid' => 'form-grid', 'templates' => ['{create}' => ['class' => 'col-xs-6 col-md-8'], '{bulk-actions}' => ['class' => 'col-xs-6 col-md-2 col-md-offset-2']], 'elements' => ['create' => '<div class="btn-group">' . Html::a('<span class="glyphicon glyphicon-plus"></span> ' . Yii::t('app', 'Create Form'), ['create'], ['class' => 'btn btn-primary']) . '<button type="button" class="btn btn-primary dropdown-toggle"
                                        data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
                                            <span class="caret"></span>
                                            <span class="sr-only">Toggle Dropdown</span>
                                        </button>' . Dropdown::widget(['items' => $templateItems]) . '</div> ' . Html::a(Yii::t('app', 'Do you want to customize your forms?'), ['/theme'], ['data-toggle' => 'tooltip', 'data-placement' => 'top', 'title' => Yii::t('app', 'No problem at all. With a theme, you can easily add custom CSS styles to your forms, to customize colors, field sizes, backgrounds, fonts, and more.'), 'class' => 'text hidden-xs hidden-sm'])], 'bulkActionsItems' => [Yii::t('app', 'Update Status') => ['status-active' => Yii::t('app', 'Active'), 'status-inactive' => Yii::t('app', 'Inactive')], Yii::t('app', 'General') => ['general-delete' => Yii::t('app', 'Delete')]], 'bulkActionsOptions' => ['options' => ['status-active' => ['url' => Url::toRoute(['update-status', 'status' => 1])], 'status-inactive' => ['url' => Url::toRoute(['update-status', 'status' => 0])], 'general-delete' => ['url' => Url::toRoute('delete-multiple'), 'data-confirm' => Yii::t('app', 'Are you sure you want to delete these forms? All stats, submissions, conditional rules and reports data related to each item will be deleted. This action cannot be undone.')]], 'class' => 'form-control'], 'class' => 'form-control']) : null], 'toolbar' => false]);
?>
        </div>
    </div>
</div>
<?php 
$js = <<<'SCRIPT'

$(function () {
    $("[data-toggle='tooltip']").tooltip();
});

SCRIPT;
// Register tooltip/popover initialization javascript