= $this->render('_alert.php') ?>
user->id == $model->user_id) || Yii::$app->user->can('admin'))
{
ActiveForm::begin([
'action' => ['/lots/auction', 'id' => $model->id, 'type' => 1],
'id' => 'lot-form',
]); ?>
= DetailView::widget([
'options' => [
'class' => 'table table-striped table-bordered detail-view'
],
'model' => $serialize_data,
'attributes' =>
[
[
<<<<<<< HEAD
'label' => 'Організатор аукціону',
'value' => isset($model->auction) ? $model->auction->user->at_org : $model->user->at_org,
'format' => 'raw',
],
[
=======
>>>>>>> 5bd9408fb32cecb076e639952fbeaaed915e69ce
'label' => 'Тип аукціону',
'value' => function ($model){
if($model->type == 1){
return 'Підвищення';
}
if($model->type == 2){
return 'Голландський';
}
if($model->type == 3){
return 'Банкрутство';
}
},
'format' => 'raw',
],
[
'label' => 'Дата закінчення',
'value' => $serialize_data->date_stop,
'format' => 'raw',
],
[
'label' => 'Час продовження, хв',
'value' => explode(":",$serialize_data->time_cont)[1]." хв",
'format' => 'raw',
],
],
]); ?>
type == 2): ?>
= DetailView::widget([
'options' => [
'class' => 'table table-striped table-bordered detail-view'
],
'model' => $serialize_data,
'attributes' =>
[
[
'label' => 'Крок',
'value' => $serialize_data->step_change,
'format' => 'raw',
<<<<<<< HEAD
],
[
'label' => 'Час',
'value' => $timeStepFormat,
'format' => 'raw',
],
=======
],
[
'label' => 'Час',
'value' => $timeStepFormat,
'format' => 'raw',
],
>>>>>>> 5bd9408fb32cecb076e639952fbeaaed915e69ce
],
]); ?>
user->can('admin')): ?>
= $status; ?>
= Html::submitButton(Yii::t('app', 'Підтвердити / Створити'), ['class' => 'btn btn-success']); ?>
Yii::$app->user->id,
'type' => 'bid',
'lot_id' => $model->id,
]))) {
$bidding = new \app\models\Bidding();
$form = ActiveForm::begin([
'action' => Url::to(['/auctions/bid', 'id' => $model->auction->id]),
]); ?>
= $form->field($bidding, 'special_price'); ?>
= Html::submitButton(Yii::t('app', 'Submit'), ['class' => 'btn btn-success']); ?>
= Html::a(Yii::t('app', 'Download file'), ["/files/download", 'id' => $file->id], ['class' => 'btn btn-warning']); ?>
['enctype' => 'multipart/form-data'] // important
]);
echo $form->field($files, 'file')->widget(FileInput::classname(), [
'options' => ['multiple' => true],
'pluginOptions' => [
'initialCaption' => 'файл типу: doc, docx, pdf, jpg, png, zip, rar (розмiр не бiльше 40Мб)',
'showPreview' => true,
'overwriteInitial' => false,
'pluginLoading' => true,
'initialPreviewAsData' => true,
'uploadClass' => 'btn btn-danger',
'removeIcon' => '
',
],
])->label(Yii::t('app', 'DownloadMemeberDoc ID'));
ActiveForm::end();
}
}
?>
= DetailView::widget([
'model' => $model,
'attributes' =>
[
// [
// 'label' => Yii::t('app', 'Circle ID'),
// 'value' => $circle_down . Html::tag('span', $model->step_down, ['class' => 'lead']) . $circle_up . $circle_change . $time_change . $model->time_step_down,
// 'format' => 'raw',
// ],
'aukname',
'name',
'categoryName',
'description',
'auction_date',
'bidding_date',
[
'attribute' => 'start_price',
'value' => $price_nds,
],
[
'attribute' => 'count',
'value' => $model->count,
'visible' => $model->count,
],
[
'attribute' => 'price_per_one',
'value' => $model->unitId ? ($model->start_price / $model->count) : '',
'visible' => $model->unitId ? true : false,
],
[
'attribute' => 'unitName',
'value' => $model->unit ? $model->unit->name : '',
'visible' => $model->unitId ? true : false,
],
'step',
[
'attribute' => 'docs_id',
'value' => $docs,
'format' => 'raw',
],
'address',
'member_require',
'payment_term',
'notes',
[
'attribute' => 'dogovor_id',
'value' => $dogovor,
'format' => 'raw',
],
[
'attribute' => Yii::t('app', 'Registration fee'),
'value' =>
Html::a('
Завантажити рахунок ',
[
'/bills/download-requisites',
'id' => $model->getBillPayDocument(),
],
[
'target' => '_blank',
'title' => Yii::t('app', 'Download bill')
]
) . $registration_fee,
'format' => 'raw',
],
[
'attribute' => Yii::t('app', 'Guaranteed payment'),
'value' => function($model) use ($guarantee_fee){
$id = $model->getBillPayDocument("guarantee");
if(!$id){
return Html::a(
'
Завантажити рахунок ', '#', [
'title' => 'Завантажити рахунок',
'onclick' => "alert('Для завантаження рахунку, треба подати заявку на лот/аукціон'); return false;",
]) . $guarantee_fee . 'грн ' . Yii::t('app', 'zNDS ID');
} else {
return Html::a('
Завантажити рахунок ',
[
'/bills/download-requisites',
'id' => $id,
],
[
'target' => '_blank',
'title' => 'Завантажити рахунок'
]
) . $guarantee_fee . 'грн ' . Yii::t('app', 'zNDS ID');
}
},
'format' => 'raw',
],
// [
// 'attribute' => Yii::t('app', 'Guaranteed payment'),
// 'value' => $guarantee_fee .
// Html::a('
',
// [
// '/bills/download-requisites',
// 'id' => $model->getBillPayDocument("guarantee"),
// ],
// [
// 'target' => '_blank',
// 'title' => Yii::t('app', 'Download bill')
// ]
// ),
// 'format' => 'raw',
// ],
],
]) ?>