php yii-jui-AutoComplete类(方法)实例源码

下面列出了php yii-jui-AutoComplete 类(方法)源码代码实例,从而了解它的用法。

作者:sea12    项目:kba   
<?php

use yii\widgets\ActiveForm;
use yii\helpers\Html;
$this->registerCss(".ui-menu .ui-menu-item:hover,.ui-menu .ui-state-active {background:#4f99c6}");
?>

<?php 
$form = ActiveForm::begin();
?>

<?php 
echo $form->field($model, 'name');
?>

<?php 
echo $form->field($model, 'description');
?>

<?php 
//echo $form->field($model, 'rule_name')
echo $form->field($model, 'rule_name')->widget(\yii\jui\AutoComplete::className(), ['clientOptions' => ['source' => array_keys(\Yii::$app->authManager->getRules())], 'options' => ['class' => 'form-control']]);
echo $form->field($model, 'data')->textarea(['rows' => 6]);
?>

<?php 
echo Html::submitButton('Save', ['class' => 'btn btn-success btn-block']);
?>

<?php 
ActiveForm::end();

作者:prasgem    项目:ca   
?>
    
		</div>
		<div class="col-sm-8">	
	
	<?php 
echo $form->field($model, 'tags')->widget(Select2::classname(), ['options' => ['placeholder' => Yii::t('app', 'Put additional tags, usefull for Helper Ledger ...')], 'data' => $model->getTags(), 'pluginOptions' => ['tags' => true, 'tokenSeparators' => [',', ' ']]]);
?>
			
		</div>
	</div>	
	
	<div class="row">	
		<div class="col-sm-9">			
	<?php 
echo $form->field($model, 'title')->widget(AutoComplete::classname(), ['clientOptions' => ['source' => Yii::$app->urlManager->createUrl("//cap/transaction/template")], 'clientEvents' => ['select' => 'function(event, ui) {																											
								var id = ui.item.value;								
								var url = "' . Yii::$app->urlManager->createUrl('//cap/transaction/template') . '?id="+id;
								$.ajax(url, {
									success: function (xhr) {										
										xhr = JSON.parse(xhr);									
										if (xhr != null)
										{											
											var t = JSON.parse(xhr.json);							
											
											var total = parseFloat($("#transaction-total").val());
																																	
											for (k in t)
											{
												if (k == "total")
												{

作者:highestgoodlikewate    项目:ye   
echo $form->field($model, 'status')->widget(Select2::classname(), ['data' => $model->itemAlias('status'), 'options' => ['placeholder' => Yii::t('app', 'Select shipping status...')], 'pluginOptions' => ['allowClear' => false], 'pluginEvents' => []]);
?>
				</div>		
			</div>
			<?php 
$field = $form->field($model, "city");
//$field->template = "{input}";
echo $field->widget(AutoComplete::classname(), ['clientOptions' => ['source' => Yii::$app->urlManager->createUrl("//yes/shipping/index?format=json&arraymap=city")], 'clientEvents' => ['select' => 'function(event, ui) {												
										console.log(event,ui,"tes");							
									}'], 'options' => ['class' => 'form-control required', 'maxlength' => 255, 'placeholder' => Yii::t('app', 'City name that use by shipping provider')]]);
?>
	
			<?php 
$field = $form->field($model, "area");
//$field->template = "{input}";
echo $field->widget(AutoComplete::classname(), ['clientOptions' => ['source' => Yii::$app->urlManager->createUrl("//yes/shipping/index?format=json&arraymap=area")], 'clientEvents' => ['select' => 'function(event, ui) {												
										console.log(event,ui,"tes");							
									}'], 'options' => ['class' => 'form-control required', 'maxlength' => 255, 'placeholder' => Yii::t('app', 'Wider area of the city like province and state, ex: Jakarta, Indonesia')]]);
?>
			
		</div>
		<div class="col-sm-6">
			<div class="well data">		
				<h4><?php 
echo Yii::t('app', 'Shipping Data');
?>
 <small class="pull-right"><?php 
echo Yii::t('app', 'list of carrier/provider that available to reach the city');
?>
  <a id="data-add" class="btn btn-sm btn-default">Add Data</a></small></h4>				
				<br>

作者:Rakeshdrupa    项目:yiifirstliveprojec   
echo Html::activeHiddenInput($modelMeetingSchedule, "[{$i}]id");
 echo Html::activeHiddenInput($modelMeetingSchedule, "[{$i}]congress_id");
 echo Html::activeHiddenInput($modelMeetingSchedule, "[{$i}]meeting_id");
 echo Html::activeHiddenInput($modelMeetingSchedule, "[{$i}]ol_attendee_id");
 ?>
                                     <?php 
 if (!is_object($modelMeetingSchedule->olattendee)) {
     $olAttendeeModel = new OlAttendees();
 } else {
     $olAttendeeModel = $modelMeetingSchedule->olattendee;
 }
 $atNameField = $form->field($olAttendeeModel, "[{$i}]name")->textInput(['maxlength' => true, 'readonly' => true]);
 ?>
                                     <?php 
 if ($modelMeetingSchedule->isNewRecord) {
     $atNameField->widget(\yii\jui\AutoComplete::classname(), ['options' => ['class' => 'form-control input'], 'clientOptions' => ['source' => "index.php?r=ajax/auto"]]);
 }
 echo $atNameField;
 ?>
                                     <div class="row">
                                         <div class="col-sm-6">
                                             <?php 
 echo $form->field($olAttendeeModel, "[{$i}]ol_phone_no")->textInput(['maxlength' => true, 'readonly' => true, 'class' => "form-control intp telnumber"]);
 ?>
                                         </div>
                                         <div class="col-sm-6">
                                             <?php 
 echo $form->field($olAttendeeModel, "[{$i}]ol_bio")->textInput(['maxlength' => true, 'readonly' => true]);
 ?>
                                         </div>
                                     </div><!--  .row  -->

作者:sergiimazuro    项目:koziuc   
echo $form->field($user, 'name');
?>

                        <label class="control-label" style="margin-top: 14px;">Email</label>
                        <?php 
echo $form->field($user, 'email');
?>


                        <label class="control-label" style="margin-top: 14px;">Тип користувача</label>
                        <?php 
echo $form->field($user, 'ac_type')->dropDownList(['0' => 'Користувач', '10' => 'Редактор', '11' => 'Адмін']);
?>
                        <label class="control-label" style="margin-top: 14px;">Країна</label>
                        <?php 
echo $form->field($user, 'country')->widget(\yii\jui\AutoComplete::classname(), ['name' => 'User[country]', 'id' => 'user-country', 'options' => ['class' => 'form-control'], 'clientOptions' => ['source' => $countries, 'autoFill' => true, 'minLength' => '2', 'style' => 'font-size: 0.8em']]);
?>
                        <label class="control-label" style="margin-top: 14px;">Місто</label>
                        <?php 
echo $form->field($user, 'city');
?>
                        <label class="control-label" style="margin-top: 14px;">Адреса</label>
                        <?php 
echo $form->field($user, 'address');
?>
                        <label class="control-label" style="margin-top: 14px;">Робота</label>
                        <?php 
echo $form->field($user, 'work');
?>

                        <label class="control-label" style="margin-top: 14px;">Стать</label>

作者:marsolty    项目:yii2use   
/**
  * @param ActiveRecord $model - profile model
  * @param $field - profile fields model item
  * @param $htmlOptions - htmlOptions
  * @return string
  */
 public function editAttribute($model, $field, $htmlOptions = [])
 {
     /** @var ActiveRecord $modelName */
     $modelName = $this->params['modelName'];
     $list = [];
     if (isset($this->params['emptyFieldValue'])) {
         $list[] = ['id' => $this->params['emptyFieldValue'], 'label' => $this->params['emptyFieldLabel']];
     }
     $models = $modelName->find()->all();
     foreach ($models as $m) {
         if ($this->params['optionName']) {
             $list[] = ['label' => $m->getAttribute($this->params['optionName']), 'id' => $m->id];
         } else {
             $list[] = ['label' => $m->id, 'id' => $m->id];
         }
     }
     if (!isset($htmlOptions['id'])) {
         $htmlOptions['id'] = $field->varname;
     }
     $id = $htmlOptions['id'];
     $relation = $this->params['relationName'];
     /** @var ActiveRecord $modelName */
     $modelName = $this->params['modelName'];
     if ($relation && method_exists($model, $relation)) {
         $m = $model->__get($this->params['relationName']);
     } else {
         $m = $modelName::findOne($model->getAttribute($field->varname));
     }
     if ($m) {
         $default_value = $this->params['optionName'] ? $m->getAttribute($this->params['optionName']) : $m->id;
     } else {
         $default_value = '';
     }
     $htmlOptions['value'] = $default_value;
     $options['source'] = $list;
     $options['minLength'] = $this->params['minLength'];
     //$options['showAnim'] = 'fold';
     $options['select'] = "js:function(event, ui) { \$('#" . get_class($model) . "_" . $field->varname . "').val(ui.item.id);}";
     $options = Json::encode($options);
     /** @var \yii\widgets\ActiveField $form */
     $form = $htmlOptions['formField'];
     unset($htmlOptions['formField']);
     $return = $form->widget(\yii\jui\AutoComplete::classname(), ['clientOptions' => $options]);
     return $return;
 }

作者:mlzharo    项目:intl-icu-data-table   
use yii\helpers\Html;
use yii\helpers\Url;
use yii\jui\AutoComplete;
$this->title = '';
if ($locale) {
    $this->title = \Locale::getDisplayName($locale, Yii::$app->language) . ', ' . Html::encode($locale) . ' - ';
}
$this->title .= 'PHP intl extension, ICU data tables';
?>

<?php 
echo Html::beginForm(['site/index'], 'get', ['class' => 'form-horizontal']);
?>
<div class="input-group">
    <?php 
echo AutoComplete::widget(['name' => 'locale', 'value' => $locale, 'options' => ['class' => 'form-control', 'placeholder' => 'Enter locale code such as "en" or "en_US"', 'autofocus' => true], 'clientOptions' => ['source' => Url::toRoute(['site/suggest-locale'])]]);
?>
    <span class="input-group-btn">
        <?php 
echo Html::submitButton('Find', ['class' => 'btn btn-primary']);
?>
    </span>
</div>
<?php 
echo Html::endForm();
?>

<?php 
if ($locale) {
    ?>

作者:bruno-mel    项目:component   
public function autocompleteJui($opts)
 {
     $id = $this->getInputId();
     $options = array_merge_recursive(['id' => $id . '_autoComplete', 'clientOptions' => ['select' => new JsExpression("function( event, ui ) { \$( '#{$id}' ).val( ui.item.id ); }"), 'change' => new JsExpression("function(){ if( \$( '#{$id}' ).val() <= 0 ){ \$(this).val(null); }}"), 'search' => new JsExpression("function(){ \$( '#{$id}' ).val(null); }")]], $opts);
     $hidden = Html::activeHiddenInput($this->model, $this->attribute);
     $autocomplete = AutoComplete::widget($options);
     Yii::$app->getView()->registerJs("\$('body').on('autocompletecreate', 'input', function(e, ui){" . "\$(this).addClass('form-control') });", View::POS_END, 'autocompletecreate');
     $this->parts['{input}'] = $hidden . $autocomplete;
     return $this;
 }

作者:Farysht    项目:yii2-jquery-tagsinpu   
/**
  * Register the js scripts including the required assets and the options in
  * `$clientOptions`
  */
 protected function registerScript()
 {
     $view = $this->getView();
     if (isset($this->clientOptions['autocomplete_url'])) {
         if (class_exists('yii\\jui\\AutoComplete')) {
             \yii\jui\AutoComplete::register($view);
         } else {
             throw new InvalidConfigException('To use autocomplete functionality you need to install the ' . ' JUI Extension for Yii 2. ' . 'http://www.yiiframework.com/doc-2.0/ext-jui-index.html');
         }
     }
     $clientOptions = empty($this->clientOptions) ? '' : Json::encode($this->clientOptions);
     JqueryTagsAsset::register($view);
     $view->registerJs("jQuery('#{$this->options["id"]}').tagsInput({$clientOptions});");
 }

作者:hendri3    项目:OpenPrin   
<?php 
$form = ActiveForm::begin(['action' => ['reportkpi'], 'method' => 'get']);
?>

    <div class="col-md-12">
        <?php 
/*echo $form->field($model, 'partner_id')->widget(Select2::classname(), [
      'data' => ArrayHelper::map(ResPartner::find()->all(),'id','display_name'),
      'options' => ['placeholder' => 'Filter as you type ...'],
  ])->label('Address Name')*/
?>
        <?php 
$data = ResPartner::find()->select(['display_name as value', 'display_name as  label', 'id as id'])->asArray()->all();
?>
        <?php 
echo $form->field($model, 'partner_id')->widget(\yii\jui\AutoComplete::classname(), ['clientOptions' => ['source' => $data]])->textInput()->label('Address Name');
?>
    </div>
    <div class="col-md-6">
        <?php 
echo $form->field($model, 'month_tanggal')->dropDownList(['1' => 'Januari', '2' => 'Februari', '3' => 'Maret', '4' => 'April', '5' => 'Mei', '6' => 'Juni', '7' => 'Juli', '8' => 'Agustus', '9' => 'September', '10' => 'Oktober', '11' => 'November', '12' => 'Desember'], ['prompt' => ''])->label('Bulan Kirim');
?>
    </div>
    <div class="col-md-6">
        <?php 
echo $form->field($model, 'year_tanggal')->textInput()->label('Tahun Kirim');
?>
    </div>
    <div class="col-md-6">
        <?php 
echo $form->field($model, 'month_po')->dropDownList(['1' => 'Januari', '2' => 'Februari', '3' => 'Maret', '4' => 'April', '5' => 'Mei', '6' => 'Juni', '7' => 'Juli', '8' => 'Agustus', '9' => 'September', '10' => 'Oktober', '11' => 'November', '12' => 'Desember'], ['prompt' => ''])->label('Bulan PO');

作者:nhatvuva    项目:yii2-widget   
_form_container" class="token-form <?php 
echo $this->context->getStatusIndicator($model);
?>
">

    <?php 
$form = (include \Yii::getAlias("@nitm/views/layouts/form/header.php"));
?>
		<?php 
echo Html::label('User', 'usersearch', []);
?>
		<?php 
if (!$model->isNewRecord) {
    echo Html::tag('h4', \nitm\module\models\User::getFullName($model->user_id));
} else {
    echo \yii\jui\AutoComplete::widget(['name' => 'name', 'attribute' => 'name', 'options' => ['class' => 'form-control', 'id' => 'usersearch', 'role' => 'autocompleteSelect', 'data-select' => \yii\helpers\Json::encode(["value" => "unique", "label" => "name", "container" => "token-user_id"])], 'clientOptions' => ['source' => '/autocomplete/user']]);
}
?>
		<?php 
echo Html::activeHiddenInput($model, 'user_id');
?>
		<?php 
echo $form->field($model, 'active')->checkbox();
?>

		<?php 
echo $form->field($model, 'revoked')->checkbox();
?>

		<?php 
echo $form->field($model, 'level')->dropDownList($model->getLevels());

作者:advance10    项目:sangkilbiz   
<?php 
echo Html::label('Print Count:');
?>
<br>
                            <?php 
echo Html::input('text', 'jml', '10', ['id' => 'jml', 'style' => 'width:80px;']);
?>
                        </td>
                    </tr>
                </tbody>
            </table>
        </div>
        <div class="form-group" style="padding: 15px; padding-top: 0px;">
            <label for="product">Product :</label>
            <?php 
echo AutoComplete::widget(['name' => 'product', 'id' => 'product', 'clientOptions' => ['source' => new JsExpression('yii.global.sourceProduct'), 'select' => new JsExpression('yii.master.onProductSelect'), 'delay' => 100], 'options' => ['class' => 'form-control', 'style' => 'width:60%;']]);
?>
            <?php 
echo Html::hiddenInput('barcodeValue', '', ['id' => 'barcodeValue']);
?>
        </div>
    </div>
    <div class="box-footer">
        <?php 
echo Html::button(' Generate', ['onclick' => 'generateBarcode();', 'class' => 'btn btn-warning fa fa-qrcode']);
?>
        <?php 
echo Html::button(' Print', ['onclick' => 'print();', 'class' => 'btn btn-info fa fa-print']);
?>
    </div>
</div>

作者:rvence    项目:tele_sep   
<div class="col-xs-3">
                <?php 
// Estado
$lista = ArrayHelper::map(\backend\models\Estado::find()->asArray()->all(), 'estadoid', 'estado');
echo $form->field($model, 'estado_id')->dropDownList($lista)->label('Estatus');
?>
            </div>
        </div>

        <div class="row">
            <div class="col-xs-3">
                <?php 
// Cuenta
$data = \backend\models\Cuentas::find()->select(['cuenta'])->distinct()->asArray()->createCommand()->queryColumn();
//echo $form->field($model, 'cuenta')->widget(\yii\jui\AutoComplete::className(), ['clientOptions' => ['source' => $data],]);
echo $form->field($model, 'cuenta')->widget(\yii\jui\AutoComplete::className(), ['options' => ['class' => 'form-control'], 'clientOptions' => ['source' => $data]])->label('Dependencia / Entidad');
?>
            </div>
        </div>

        <div class="row">
            <div class="col-xs-3">
                <?php 
// Siglas
echo $form->field($model, 'siglas')->textInput(['maxlength' => true])->textInput();
?>
            </div>
        </div>

作者:janist    项目:yii2-ycm-dem   
/**
  * Config for attribute widgets (ycm)
  *
  * @return array
  */
 public function attributeWidgets()
 {
     /**
      * You should configure attribute widget as: ['field', 'widget'].
      *
      * If you need to pass additional configuration to the widget, add them as: ['field', 'widget', 'key' => 'value'].
      * The first two items are sliced from the array, and then it's passed to the widget as: ['key' => 'value'].
      *
      * There are couple of exceptions to this slicing:
      * If you use 'hint', 'hintOptions', 'label' or 'labelOptions' the widget will render hint and/or label and
      * then it will unset those keys and pass the array to the widget.
      *
      * If you use 'widget', you must also set 'widgetClass'.
      *
      * Check each widget to see what options you can override/set.
      */
     // example data
     $data = ['One', 'Two', 'Three', 'Four', 'Five', 'Six', 'Seven', 'Eight', 'Nine', 'Ten'];
     return [['field_widget', 'widget', 'widgetClass' => \yii\jui\AutoComplete::classname(), 'options' => ['class' => 'form-control'], 'clientOptions' => ['source' => $data], 'hint' => 'Type: t', 'label' => 'Autocomplete'], ['field_wysiwyg', 'wysiwyg'], ['field_date', 'date'], ['field_time', 'time'], ['field_datetime', 'datetime'], ['field_select', 'select'], ['field_selectMultiple', 'selectMultiple'], ['field_image', 'image'], ['field_file', 'file'], ['field_text', 'text'], ['field_hidden', 'hidden'], ['field_password', 'password'], ['field_textarea', 'textarea'], ['field_radio', 'radio'], ['field_boolean', 'boolean'], ['field_checkbox', 'checkbox'], ['field_dropdown', 'dropdown'], ['field_listbox', 'listbox'], ['field_checkboxList', 'checkboxList'], ['field_radioList', 'radioList'], ['field_disabled', 'disabled'], ['field_hide', 'hide'], ['field_html5', 'text', 'input' => 'number', 'min' => 1, 'max' => 5, 'hint' => 'Number between 1 - 5.']];
 }

作者:nineto    项目:yii-classifiel   
<section class="content">
    <?php 
echo \common\widgets\Alert::widget();
?>
    <div class="box box-primary">
        <div class="box-body">
            <h1><?php 
echo Html::encode($this->title);
?>
</h1>

            <p>
                <?php 
if (\Yii::$app->user->can('create-product')) {
    ?>
                    <?php 
    echo Html::a(Yii::t('app', 'Create Product'), ['create'], ['class' => 'btn btn-success']);
    ?>
                <?php 
}
?>
            </p>
            <?php 
echo GridView::widget(['dataProvider' => $dataProvider, 'filterModel' => $searchModel, 'emptyText' => 'You don\'t have any products', 'columns' => [['class' => 'yii\\grid\\SerialColumn'], ['attribute' => 'title', 'filter' => AutoComplete::widget(['model' => $searchModel, 'attribute' => 'title', 'options' => ['class' => 'form-control'], 'clientOptions' => ['source' => Product::getAutoCompleteItems('title')]])], ['attribute' => 'ui', 'filter' => AutoComplete::widget(['model' => $searchModel, 'attribute' => 'ui', 'options' => ['class' => 'form-control'], 'clientOptions' => ['source' => Product::getAutoCompleteItems('ui')]])], ['class' => '\\pheme\\grid\\ToggleColumn', 'attribute' => 'active', 'enableAjax' => false, 'filter' => [1 => Yii::t('yii', 'Yes'), 0 => Yii::t('yii', 'No')]], ['class' => 'yii\\grid\\ActionColumn', 'template' => Product::getGridButtonsTemplate(), 'buttons' => ['delete' => function ($url, $model, $key) {
    $options = ['title' => Yii::t('yii', 'Delete'), 'aria-label' => Yii::t('yii', 'Delete'), 'data-confirm' => 'Are you sure you want to delete this item?', 'data-method' => 'post', 'data-pjax' => '0'];
    return Html::a('<span class="glyphicon glyphicon-trash"></span>', $url, $options);
}]]]]);
?>
        </div>
    </div>
</section>

作者:minppps    项目:rs   
</div>
    </div>

    <!-- VINCULACION CON LOS PLANES -->
    <div class="panel panel-primary">
        <div class="panel-heading">
            <span>VINCULACION CON LOS PLANES</span>
        </div>
        <div class="panel-body">
            <?php 
echo $form->field($model, 'objetivo_general')->hiddenInput();
?>

            <div class="form-group">
                <?php 
echo AutoComplete::widget(['model' => $model, 'name' => 'general', 'options' => ['class' => 'form-control', 'placeholder' => 'Escriba para buscar'], 'clientOptions' => ['source' => $objetivo_general, 'autoFill' => true, 'select' => new JsExpression("function(event, ui) {\n                                \$('#proyecto-objetivo_general').val(ui.item.id);\n                            }")]]);
?>
            </div>

            <?php 
echo $form->field($model, 'objetivo_estrategico_institucional')->textarea(['rows' => 6]);
?>
        </div>
    </div>

    <!-- LOCALIZACION DEL PROYECTO-->
    <div class="panel panel-primary">
        <div class="panel-heading">
            <span>LOCALIZACIÓN DEL PROYECTO</span>
        </div>
        <div class="panel-body">

作者:sangkilsof    项目:sangkilbiz-   
<?php

use yii\web\JsExpression;
use yii\jui\AutoComplete;
?>
<div class="box box-info">
    <div class="box-header">
        <div class="form-group" style="padding: 15px;">
            <label for="product">Product :</label>
            <?php 
echo AutoComplete::widget(['name' => 'product', 'id' => 'product', 'clientOptions' => ['source' => new JsExpression('yii.global.sourceProduct'), 'select' => new JsExpression('yii.pos.onSelectProduct'), 'delay' => 500], 'options' => ['class' => 'form-control']]);
?>
        </div>
        <div class="box-body" style="text-align: right; padding-top: 0px; padding-bottom: 0px;">        
            <input type="hidden" id="h-total-price"><h2>Rp<span id="total-price"></span></h2>
        </div>
    </div>
    <table id="detail-grid" class="table table-striped no-padding" style="padding: 0px;">
        <thead style="display: none">
            <tr>
                <td style="width: 50px">
                    <a data-action="delete" title="Delete" href="#"><span class="glyphicon glyphicon-trash"></span></a>
                    <input type="hidden" data-field="price"><input type="hidden" data-field="id_uom">
                    <input type="hidden" data-field="id_product">
                </td>
                <td>
                    <ul class="nav nav-list">
                        <li class="item">
                            <span data-text="nm_product"></span>
                        </li>
                        <li class="qty">

作者:zlapo    项目:sitev   
use app\models\Tour;
$this->title = 'Расширенный поиск';
$this->params['breadcrumbs'][] = ['label' => 'Туры', 'url' => ['index']];
$this->params['breadcrumbs'][] = $this->title;
$listdata = Tour::find()->select(['name as value', 'name as label'])->where(['status' => 1])->asArray()->all();
?>


<div class="add-tour">

    <?php 
$form = ActiveForm::begin(['action' => 'result', 'method' => 'get']);
?>

        <?php 
echo $form->field($model, 'search')->widget(AutoComplete::className(), ['clientOptions' => ['source' => $listdata], 'options' => ['class' => 'form-control']]);
?>
        <?php 
echo $form->field($model, 'category')->dropDownList(['name' => 'Название', 'org' => 'Организация', 'address' => 'Адрес', 'info' => 'Информация', 'tel' => 'Телефон']);
?>
        <?php 
echo $form->field($model, 'sort')->dropDownList(['name' => 'Названию', 'date' => 'Дате', 'address' => 'Адресу']);
?>




        <div class="form-group">
            <?php 
echo Html::submitButton('Поиск', ['class' => 'btn btn-primary']);
?>

作者:roman197    项目:li   
</div>
        <div class="col-lg-10">
            <?php 
$form = ActiveForm::begin(['options' => ['enctype' => 'multipart/form-data']]);
?>

            <?php 
echo $form->field($model, 'minititle')->textInput();
?>

            <?php 
echo $form->field($upload, 'file')->fileInput();
?>

            <?php 
echo $form->field($model, 'source_title')->widget(\yii\jui\AutoComplete::className(), ['clientOptions' => ['source' => $data, 'minLength' => '3', 'autoFill' => true], 'options' => ['class' => 'form-control']]);
?>
            <?php 
if (!$redactor) {
    ?>
                <?php 
    echo $form->field($model, 'body')->textarea(['rows' => 5, 'cols' => 5, 'id' => 'my-textarea-id']);
    ?>
            <?php 
} else {
    ?>

            <?php 
    echo $form->field($model, 'body')->widget(Widget::classname(), ['settings' => ['lang' => 'ru', 'minHeight' => 300, 'pastePlainText' => true, 'buttonSource' => true, 'plugins' => ['clips', 'fullscreen'], 'imageUpload' => Url::to(['/articles/image-upload'])]]);
    ?>

作者:sangkilsof    项目:sangkilbiz-   
<?php

use yii\web\JsExpression;
use yii\jui\AutoComplete;
use yii\helpers\Html;
use biz\models\TransferDtl;
use biz\tools\Helper;
?>
<div class="col-lg-9" style="padding-left: 0px;">
    <div class="panel panel-info">
        <div class="panel-heading">
            Product :
            <?php 
echo AutoComplete::widget(['name' => 'product', 'id' => 'product', 'clientOptions' => ['source' => new JsExpression('yii.global.sourceProduct'), 'select' => new JsExpression('yii.transfer.onProductSelect'), 'delay' => 100]]);
?>
        </div>
        <table id="detail-grid" class="table table-striped">
            <?php 
/**
 * 
 * @param TransferDtl $model
 * @param integer $index
 * @return string
 */
function renderRow($model, $index)
{
    ob_start();
    ob_implicit_flush(false);
    ?>
                <tr>
                    <td style="width: 50px">


问题


面经


文章

微信
公众号

扫码关注公众号