Commit c6152cd67bae24b7174b50530f3bca55969c97ea

Authored by Administrator
1 parent 07a132f4

VItaliy 25.11.2015

Showing 71 changed files with 973 additions and 889 deletions   Show diff stats
1 <IfModule mod_rewrite.c> 1 <IfModule mod_rewrite.c>
2 - 2 +AddDefaultCharset UTF-8
3 Options +FollowSymlinks 3 Options +FollowSymlinks
4 4
5 RewriteEngine On 5 RewriteEngine On
backend/assets/MyAsset.php
@@ -38,8 +38,6 @@ class MyAsset extends AssetBundle @@ -38,8 +38,6 @@ class MyAsset extends AssetBundle
38 'js/app.min.js', 38 'js/app.min.js',
39 'js/pages/dashboard.js', 39 'js/pages/dashboard.js',
40 'js/main.js', 40 'js/main.js',
41 - 'js/angular.js',  
42 - 'js/angular_js.js',  
43 'js/script.js', 41 'js/script.js',
44 42
45 ]; 43 ];
backend/components/ImgResizer.php renamed to backend/components/ImageResizer.php
@@ -9,7 +9,7 @@ use yii\imagine\Image; @@ -9,7 +9,7 @@ use yii\imagine\Image;
9 use Yii; 9 use Yii;
10 use Imagine\Gd\Imagine; 10 use Imagine\Gd\Imagine;
11 11
12 -class ImgResizer extends Widget 12 +class ImageResizer extends Widget
13 { 13 {
14 14
15 public $height; 15 public $height;
@@ -36,6 +36,10 @@ class ImgResizer extends Widget @@ -36,6 +36,10 @@ class ImgResizer extends Widget
36 36
37 $model->file = UploadedFile::getInstance($model, 'file'); 37 $model->file = UploadedFile::getInstance($model, 'file');
38 38
  39 + if(!$model->file){
  40 + return json_encode(["error"=>"Не указан файл"]);
  41 + }
  42 +
39 $md5_file = md5_file($model->file->tempName); 43 $md5_file = md5_file($model->file->tempName);
40 44
41 $imgDir = Yii::getAlias('@storage/'.$md5_file.'/'); 45 $imgDir = Yii::getAlias('@storage/'.$md5_file.'/');
backend/components/ImageSizer.php renamed to backend/components/ImageUploader.php
@@ -10,7 +10,7 @@ namespace backend\components; @@ -10,7 +10,7 @@ namespace backend\components;
10 use yii\base\Widget; 10 use yii\base\Widget;
11 11
12 12
13 -class ImageSizer extends Widget 13 +class ImageUploader extends Widget
14 { 14 {
15 public $height = 0; 15 public $height = 0;
16 public $width = 0; 16 public $width = 0;
backend/components/base/BaseController.php
@@ -17,7 +17,15 @@ use yii\imagine\Image; @@ -17,7 +17,15 @@ use yii\imagine\Image;
17 17
18 class BaseController extends Controller { 18 class BaseController extends Controller {
19 19
20 - 20 + public function isBigger($width,$height,$w,$h)
  21 + {
  22 + if($width>$w){
  23 + return true;
  24 + }else if($height >$h) {
  25 + return true;
  26 + }
  27 + return false;
  28 + }
21 29
22 private function resizeImg($w, $h, $imageAlias,$imageAliasSave){ 30 private function resizeImg($w, $h, $imageAlias,$imageAliasSave){
23 $img = Image::getImagine()->open(Yii::getAlias($imageAlias)); 31 $img = Image::getImagine()->open(Yii::getAlias($imageAlias));
@@ -27,17 +35,38 @@ class BaseController extends Controller { @@ -27,17 +35,38 @@ class BaseController extends Controller {
27 $width = $size->getWidth(); 35 $width = $size->getWidth();
28 $height = $size->getHeight(); 36 $height = $size->getHeight();
29 37
30 - if($width > $height) {  
31 - $y = 0;  
32 - $x = ($width - $height) / 2;  
33 - $smallestSide = $height; 38 + $e_width = $w/$h;
  39 + $e_height = $h/$w;
  40 +
  41 + $e1_width = $width/$height;
  42 + $e1_height = $height/$width;
  43 +
  44 +
  45 + if($this->isBigger($width,$height,$w,$h)){
  46 + if($e_width<$e1_width){
  47 +
  48 + $new_width = $width*($e_width/$e1_width);
  49 +
  50 + $y = 0;
  51 + $x = $width/ 2-($new_width/2);
  52 + $width = $new_width;
  53 +
  54 + }else {
  55 +
  56 + $new_height = $height*($e_height/$e1_height);
  57 + $x = 0;
  58 + $y = $height/2-($new_height/2);
  59 + $height = $new_height;
  60 + }
  61 +
  62 +
34 } else { 63 } else {
35 - $x = 0;  
36 - $y = ($height - $width) / 2;  
37 - $smallestSide = $width; 64 + $img->save($imageAliasSave, array('flatten' => false));
  65 + return true;
38 } 66 }
39 67
40 - Image::crop($imageAlias, $smallestSide, $smallestSide,[$x,$y]) 68 +
  69 + Image::crop($imageAlias, $width, $height,[$x,$y])
41 ->save(Yii::getAlias($imageAliasSave), ['quality' => 70 ->save(Yii::getAlias($imageAliasSave), ['quality' =>
42 100]); 71 100]);
43 72
@@ -49,8 +78,6 @@ class BaseController extends Controller { @@ -49,8 +78,6 @@ class BaseController extends Controller {
49 78
50 79
51 80
52 -  
53 -  
54 } 81 }
55 82
56 private function deleteImages($old_img){ 83 private function deleteImages($old_img){
@@ -75,11 +102,22 @@ class BaseController extends Controller { @@ -75,11 +102,22 @@ class BaseController extends Controller {
75 } 102 }
76 103
77 public function actionDeleteImage(){ 104 public function actionDeleteImage(){
78 - $old_img = Yii::$app->request->post('old_img');  
79 105
80 - if ($old_img) {  
81 - $this->deleteImages($old_img); 106 + $request = Yii::$app->request->post();
  107 +
  108 + if($request){
  109 + if ($request['old_img']) {
  110 + $this->deleteImages($request['old_img']);
  111 + }
  112 + if(isset($request['action']) && $request['action']=='save'){
  113 + $object = str_replace('-', '\\',$request['model']);
  114 + $model = new $object;
  115 + $model = $model->findOne($request['id']);
  116 + $model->$request['field'] = $request['new_url'];
  117 + $model->save();
  118 + }
82 } 119 }
  120 +
83 } 121 }
84 122
85 123
@@ -88,9 +126,8 @@ class BaseController extends Controller { @@ -88,9 +126,8 @@ class BaseController extends Controller {
88 126
89 $model = new ImageSizerForm(); 127 $model = new ImageSizerForm();
90 128
91 - if ($model->load(Yii::$app->request->post())) {  
92 -  
93 - $this->deleteImages($model->old_img); 129 + $request = Yii::$app->request->post();
  130 + if ($request) {
94 131
95 $model->file = UploadedFile::getInstance($model, 'file'); 132 $model->file = UploadedFile::getInstance($model, 'file');
96 133
@@ -106,13 +143,13 @@ class BaseController extends Controller { @@ -106,13 +143,13 @@ class BaseController extends Controller {
106 143
107 $model->file->saveAs($imageOrigAlias); 144 $model->file->saveAs($imageOrigAlias);
108 145
109 - if($model->width && $model->height){ 146 + if($request['width'] && $request['height']){
110 147
111 - $imageAlias = Yii::getAlias($imgDir.$model->width.'x'.$model->height.'.'.$model->file->extension); 148 + $imageAlias = Yii::getAlias($imgDir.$request['width'].'x'.$request['height'].'.'.$model->file->extension);
112 149
113 - $imageLink = '/storage/'.$md5_file.'/'.$model->width.'x'.$model->height.'.'.$model->file->extension; 150 + $imageLink = '/storage/'.$md5_file.'/'.$request['width'].'x'.$request['height'].'.'.$model->file->extension;
114 151
115 - $this->resizeImg($model->width, $model->height, $imageOrigAlias,$imageAlias); 152 + $this->resizeImg($request['width'], $request['height'], $imageOrigAlias,$imageAlias);
116 153
117 } else { 154 } else {
118 155
backend/components/views/image_sizer.php
@@ -11,39 +11,14 @@ $this-&gt;registerJsFile(&#39;@web/js/vendor/bower/jquery-file-upload/js/jquery.iframe- @@ -11,39 +11,14 @@ $this-&gt;registerJsFile(&#39;@web/js/vendor/bower/jquery-file-upload/js/jquery.iframe-
11 $this->registerJsFile('@web/js/vendor/bower/jquery-file-upload/js/jquery.fileupload.js'); 11 $this->registerJsFile('@web/js/vendor/bower/jquery-file-upload/js/jquery.fileupload.js');
12 12
13 ?> 13 ?>
14 -<style>  
15 - .gallery_image{  
16 -  
17 - position: relative;  
18 - margin-left: 20px;  
19 - margin-top: 20px;  
20 - display: inline-block;  
21 - }  
22 - .delete-gallery-item{  
23 - background-color: #fff;  
24 - opacity: 0.5;  
25 - font-size: 20px;  
26 - position: absolute;  
27 - top: 5px;  
28 - right: 5px;  
29 - cursor: pointer;  
30 - }  
31 -  
32 - .delete-field-item{  
33 - position: absolute;  
34 - top: 33%;  
35 - right: -35px;  
36 - font-size: 15px;  
37 - cursor: pointer;  
38 - }  
39 -</style> 14 +
40 <?php if(!$multi):?> 15 <?php if(!$multi):?>
41 <?= $form->field( new \backend\models\ImageSizerForm(), 'file')->fileInput(['id'=>$field, 'data-url'=>"/admin/site/download-photo" ]); ?> 16 <?= $form->field( new \backend\models\ImageSizerForm(), 'file')->fileInput(['id'=>$field, 'data-url'=>"/admin/site/download-photo" ]); ?>
42 17
43 <?= $form->field($model,$field)->hiddenInput(['id' => "{$field}_picture_link"]) ?> 18 <?= $form->field($model,$field)->hiddenInput(['id' => "{$field}_picture_link"]) ?>
44 - <input type="hidden" name="ImageSizerForm[width]" value="<?=$width?>"/>  
45 - <input type="hidden" name="ImageSizerForm[height]" value="<?=$height?>"/>  
46 - <input type="hidden" name="ImageSizerForm[old_img]" value="<?=$model->$field?>"/> 19 + <input type="hidden" id="<?=$field?>_old_img" name="ImageSizerForm[old_img]" value="<?=$model->$field?>"/>
  20 + <input type="hidden" id="<?=$field?>_new_img" name="ImageSizerForm[new_img]" value=""/>
  21 + <input type="hidden" id="<?=$field?>_row_id" name="ImageSizerForm[new_img]" value="<?=$model->id?>"/>
47 <div id="<?= $field?>_img_block"> 22 <div id="<?= $field?>_img_block">
48 <?= $model->$field ? Html::img($model->$field): '' ?> 23 <?= $model->$field ? Html::img($model->$field): '' ?>
49 </div> 24 </div>
@@ -53,16 +28,48 @@ $this-&gt;registerJsFile(&#39;@web/js/vendor/bower/jquery-file-upload/js/jquery.fileupl @@ -53,16 +28,48 @@ $this-&gt;registerJsFile(&#39;@web/js/vendor/bower/jquery-file-upload/js/jquery.fileupl
53 28
54 $("#<?= $field?>").fileupload({ 29 $("#<?= $field?>").fileupload({
55 dataType: 'json', 30 dataType: 'json',
  31 + formData: {width: <?=$width?>,height:<?=$height?>},
56 done: function (e, data) { 32 done: function (e, data) {
  33 + if($("#<?=$field?>_buttons_block").length){
  34 + $("#<?=$field?>_buttons_block").remove()
  35 + }
57 var host = window.location.host.toString(); 36 var host = window.location.host.toString();
58 - var img = '<img src="http://'+host+data.result.link+'">'; 37 + var img = '<img src="http://'+host+data.result.link+'">'+
  38 + '<div id="<?=$field?>_buttons_block">'+
  39 + '<button type="button" id="<?=$field?>_save_img" class="btn btn-success img-action-buttons" >Сохранить</button>'+
  40 + '<button type="button" id="<?=$field?>_remove_img" class="btn btn-danger img-action-buttons" >Отмена</button>'+
  41 + '</div>';
59 var block = $("#<?= $field?>_img_block"); 42 var block = $("#<?= $field?>_img_block");
60 block.find('img').remove(); 43 block.find('img').remove();
61 block.append(img); 44 block.append(img);
62 - $("#<?= $field?>_picture_link").val(data.result.link); 45 +
  46 + $("#<?=$field?>_new_img").val(data.result.link);
63 } 47 }
64 }); 48 });
65 49
  50 +
  51 + $('body').on('click', '#<?=$field?>_save_img',function(){
  52 + $("#<?=$field?>_buttons_block").remove();
  53 + var old_url = $('#<?=$field?>_old_img').val();
  54 + var new_url = $('#<?=$field?>_new_img').val();
  55 + var model = '<?=str_replace('\\', '-',$model::className());?>';
  56 + $.post( "/admin/site/delete-image",{new_url:new_url,old_img: old_url,model:model,field:"<?= $field?>", id:"<?=$model->id?>",action:'save'}, function() {
  57 + });
  58 + $("#<?=$field?>_picture_link").val(new_url);
  59 + });
  60 +
  61 + $('body').on('click', '#<?=$field?>_remove_img',function(){
  62 + $("#<?=$field?>_buttons_block").remove();
  63 + $("#<?=$field?>_buttons_block").remove();
  64 + var old_url = $('#<?=$field?>_old_img').val();
  65 + var new_url = $('#<?=$field?>_new_img').val();
  66 + $.post( "/admin/site/delete-image",{old_img: new_url}, function() {
  67 + });
  68 +
  69 + $('#<?= $field?>_img_block').find('img').attr('src',old_url);
  70 + });
  71 +
  72 +
66 }) 73 })
67 </script> 74 </script>
68 <?php else:?> 75 <?php else:?>
@@ -108,4 +115,4 @@ $this-&gt;registerJsFile(&#39;@web/js/vendor/bower/jquery-file-upload/js/jquery.fileupl @@ -108,4 +115,4 @@ $this-&gt;registerJsFile(&#39;@web/js/vendor/bower/jquery-file-upload/js/jquery.fileupl
108 115
109 }) 116 })
110 </script> 117 </script>
111 -<? endif;?>  
112 \ No newline at end of file 118 \ No newline at end of file
  119 +<?php endif;?>
113 \ No newline at end of file 120 \ No newline at end of file
backend/controllers/AccountsController.php
@@ -86,8 +86,7 @@ class AccountsController extends Controller @@ -86,8 +86,7 @@ class AccountsController extends Controller
86 $cities = DicCities::find()->all(); 86 $cities = DicCities::find()->all();
87 $margin = Margins::find()->all(); 87 $margin = Margins::find()->all();
88 $users = User::find()->all(); 88 $users = User::find()->all();
89 - $model->load(Yii::$app->request->post());  
90 - die( var_dump($model->validate())); 89 +
91 if ($model->load(Yii::$app->request->post()) && $model->save()) { 90 if ($model->load(Yii::$app->request->post()) && $model->save()) {
92 return $this->redirect(['view', 'id' => $model->id]); 91 return $this->redirect(['view', 'id' => $model->id]);
93 } else { 92 } else {
backend/controllers/NewsController.php
@@ -12,7 +12,7 @@ use yii\web\NotFoundHttpException; @@ -12,7 +12,7 @@ use yii\web\NotFoundHttpException;
12 use yii\filters\VerbFilter; 12 use yii\filters\VerbFilter;
13 use yii\filters\AccessControl; 13 use yii\filters\AccessControl;
14 use yii\web\UploadedFile; 14 use yii\web\UploadedFile;
15 -use backend\components\ImgResizer; 15 +use backend\components\ImageResizer;
16 16
17 /** 17 /**
18 * NewsController implements the CRUD actions for News model. 18 * NewsController implements the CRUD actions for News model.
@@ -146,7 +146,7 @@ class NewsController extends Controller @@ -146,7 +146,7 @@ class NewsController extends Controller
146 146
147 public function actionFileUpload(){ 147 public function actionFileUpload(){
148 148
149 - echo ImgResizer::widget(); 149 + echo ImageResizer::widget();
150 150
151 } 151 }
152 152
backend/models/Accounts.php
@@ -62,6 +62,7 @@ class Accounts extends \yii\db\ActiveRecord @@ -62,6 +62,7 @@ class Accounts extends \yii\db\ActiveRecord
62 { 62 {
63 $date = \DateTime::createFromFormat("Y.m.d" , $this->dt); 63 $date = \DateTime::createFromFormat("Y.m.d" , $this->dt);
64 $this->dt = $date->getTimestamp(); 64 $this->dt = $date->getTimestamp();
  65 + return true;
65 66
66 } 67 }
67 68
backend/views/accounts/_form.php
@@ -9,17 +9,20 @@ use yii\helpers\ArrayHelper; @@ -9,17 +9,20 @@ use yii\helpers\ArrayHelper;
9 /* @var $form yii\widgets\ActiveForm */ 9 /* @var $form yii\widgets\ActiveForm */
10 ?> 10 ?>
11 11
12 -<div ng-controller="SampleAppCtrl" class="Accounts-form"> 12 +<div class="Accounts-form">
13 13
14 <?php $form = ActiveForm::begin(); ?> 14 <?php $form = ActiveForm::begin(); ?>
15 <div > 15 <div >
16 - <button ng-repeat="item in buttons" ng-click="ShowMe(item)" type="button" ng-class="item.status ? 'btn btn-primary btn-lg active' : 'btn btn-default btn-lg'" class=>{{item.data}}</button> 16 + <div class="btn btn-primary btn-lg active main_user_info">Основные данные</div>
  17 + <div class="btn btn-default btn-lg entity">Юридическое лицо</div>
17 </div> 18 </div>
18 - <div ng-show="buttons[0].status" > 19 + <div id="main_user_info" >
19 <?= $form->field($model, 'if_manager')->checkbox() ?> 20 <?= $form->field($model, 'if_manager')->checkbox() ?>
20 21
21 <?= $form->field($model, 'email')->textInput(['maxlength' => true]) ?> 22 <?= $form->field($model, 'email')->textInput(['maxlength' => true]) ?>
22 23
  24 + <?= $form->field($model, 'is_firm')->hiddenInput(['value'=>'0'])->label(false) ?>
  25 +
23 <?= $form->field($model, 'phones')->textInput(['maxlength' => true]) ?> 26 <?= $form->field($model, 'phones')->textInput(['maxlength' => true]) ?>
24 27
25 <?= $form->field($model, 'pass')->passwordInput(['maxlength' => true]) ?> 28 <?= $form->field($model, 'pass')->passwordInput(['maxlength' => true]) ?>
@@ -49,8 +52,7 @@ use yii\helpers\ArrayHelper; @@ -49,8 +52,7 @@ use yii\helpers\ArrayHelper;
49 52
50 <?= $form->field($model, 'scode')->textInput() ?> 53 <?= $form->field($model, 'scode')->textInput() ?>
51 </div> 54 </div>
52 - <div ng-show="buttons[1].status">  
53 - <?= $form->field($model, 'is_firm')->textInput() ?> 55 + <div id="entity">
54 56
55 <?= $form->field($model, 'company')->textInput(['maxlength' => true]) ?> 57 <?= $form->field($model, 'company')->textInput(['maxlength' => true]) ?>
56 58
backend/views/accounts/index.php
@@ -64,6 +64,11 @@ $this-&gt;params[&#39;breadcrumbs&#39;][] = $this-&gt;title; @@ -64,6 +64,11 @@ $this-&gt;params[&#39;breadcrumbs&#39;][] = $this-&gt;title;
64 // 'company', 64 // 'company',
65 65
66 ['class' => 'yii\grid\ActionColumn'], 66 ['class' => 'yii\grid\ActionColumn'],
  67 +
  68 + ],
  69 + 'pager' => [
  70 + 'firstPageLabel' => '<<<',
  71 + 'lastPageLabel' => '>>>',
67 ], 72 ],
68 ]); ?> 73 ]); ?>
69 74
backend/views/layouts/main.php
@@ -9,7 +9,7 @@ use yii\helpers\Html; @@ -9,7 +9,7 @@ use yii\helpers\Html;
9 MyAsset::register($this); 9 MyAsset::register($this);
10 ?> 10 ?>
11 <?php $this->beginPage() ?> 11 <?php $this->beginPage() ?>
12 -<!DOCTYPE html><html lang="<?= Yii::$app->language ?>" ng-app="BackendApp" > 12 +<!DOCTYPE html><html lang="<?= Yii::$app->language ?>" >
13 <head> 13 <head>
14 <meta charset="<?= Yii::$app->charset ?>"> 14 <meta charset="<?= Yii::$app->charset ?>">
15 <meta name="viewport" content="width=device-width, initial-scale=1"> 15 <meta name="viewport" content="width=device-width, initial-scale=1">
backend/views/news/_form.php
@@ -77,9 +77,6 @@ use \yii\helpers\Url; @@ -77,9 +77,6 @@ use \yii\helpers\Url;
77 77
78 <?= $form->field(new \backend\models\ImageSizerForm(), 'price_list')->widget(FileInput::classname(), [ 78 <?= $form->field(new \backend\models\ImageSizerForm(), 'price_list')->widget(FileInput::classname(), [
79 'name' => 'file', 79 'name' => 'file',
80 - 'options' => [  
81 - ['accept' => 'image/*']  
82 - ],  
83 'pluginOptions' => [ 80 'pluginOptions' => [
84 'initialPreview'=>[ 81 'initialPreview'=>[
85 Html::img($model->price_list, ['class'=>'file-preview-image']), 82 Html::img($model->price_list, ['class'=>'file-preview-image']),
backend/views/news/index.php
@@ -25,20 +25,24 @@ $this-&gt;params[&#39;breadcrumbs&#39;][] = $this-&gt;title; @@ -25,20 +25,24 @@ $this-&gt;params[&#39;breadcrumbs&#39;][] = $this-&gt;title;
25 'columns' => [ 25 'columns' => [
26 ['class' => 'yii\grid\SerialColumn'], 26 ['class' => 'yii\grid\SerialColumn'],
27 27
28 - 'id', 28 + //'id',
29 'name', 29 'name',
30 - 'code',  
31 - 'brief:ntext',  
32 - 'content:ntext',  
33 - // 'sort_delete',  
34 - // 'title',  
35 - // 'kwords',  
36 - // 'descr',  
37 - // 'dt',  
38 - // 'is_active',  
39 - // 'mail_send',  
40 - // 'mails_count',  
41 - // 'img', 30 + //'code',
  31 + // 'brief:ntext',
  32 + //'content:ntext',
  33 + //'sort_delete',
  34 + //'title',
  35 + //'kwords',
  36 + //'descr',
  37 +
  38 + 'is_active',
  39 + //'mail_send',
  40 + 'mails_count',
  41 + [
  42 + 'attribute' => 'dt',
  43 + 'value' => 'date'
  44 + ],
  45 + //'img',
42 46
43 ['class' => 'yii\grid\ActionColumn'], 47 ['class' => 'yii\grid\ActionColumn'],
44 ], 48 ],
backend/views/team/_form.php
@@ -2,7 +2,8 @@ @@ -2,7 +2,8 @@
2 2
3 use yii\helpers\Html; 3 use yii\helpers\Html;
4 use yii\widgets\ActiveForm; 4 use yii\widgets\ActiveForm;
5 - 5 +use \yii\helpers\ArrayHelper;
  6 +use \common\models\TeamGroup;
6 /* @var $this yii\web\View */ 7 /* @var $this yii\web\View */
7 /* @var $model common\models\Team */ 8 /* @var $model common\models\Team */
8 /* @var $form yii\widgets\ActiveForm */ 9 /* @var $form yii\widgets\ActiveForm */
@@ -15,7 +16,7 @@ use yii\widgets\ActiveForm; @@ -15,7 +16,7 @@ use yii\widgets\ActiveForm;
15 <?= $form->field($model, 'email')->textInput(['maxlength' => true]) ?> 16 <?= $form->field($model, 'email')->textInput(['maxlength' => true]) ?>
16 17
17 <?= $form->field($model, 'group_id')->textInput() ?> 18 <?= $form->field($model, 'group_id')->textInput() ?>
18 - 19 + <?= $form->field($model, 'group_id')->dropDownList(ArrayHelper::map(TeamGroup::find()->all(), 'id', 'name'), ['prompt' => 'Выберие группу']) ?>
19 <?= $form->field($model, 'name')->textInput(['maxlength' => true]) ?> 20 <?= $form->field($model, 'name')->textInput(['maxlength' => true]) ?>
20 21
21 <?= $form->field($model, 'img')->textInput(['maxlength' => true]) ?> 22 <?= $form->field($model, 'img')->textInput(['maxlength' => true]) ?>
backend/views/team/index.php
@@ -27,7 +27,10 @@ $this-&gt;params[&#39;breadcrumbs&#39;][] = $this-&gt;title; @@ -27,7 +27,10 @@ $this-&gt;params[&#39;breadcrumbs&#39;][] = $this-&gt;title;
27 27
28 'id', 28 'id',
29 'email:email', 29 'email:email',
30 - 'group_id', 30 + [
  31 + 'attribute' => 'Группа',
  32 + 'value' => 'teamGroup.name'
  33 + ],
31 'name', 34 'name',
32 'img', 35 'img',
33 // 'phone', 36 // 'phone',
backend/views/user/_form.php
@@ -33,7 +33,15 @@ use yii\helpers\ArrayHelper; @@ -33,7 +33,15 @@ use yii\helpers\ArrayHelper;
33 ], 'id', 'name')) ?> 33 ], 'id', 'name')) ?>
34 34
35 35
36 - <?= \backend\components\ImageSizer::widget(['form'=>$form, 'model'=> $model, 'field'=>'photo','width'=>200,'height'=>200,'multi'=>false, 'gallery' =>$model->photo]); ?> 36 + <?= \backend\components\ImageUploader::widget([
  37 + 'form'=>$form,
  38 + 'model'=> $model,
  39 + 'field'=>'photo',
  40 + 'width'=>200,
  41 + 'height'=>200,
  42 + 'multi'=>false,
  43 + 'gallery' =>$model->photo
  44 + ]); ?>
37 45
38 <?= $form->field($model, 'contacts')->textInput(['maxlength' => true]) ?> 46 <?= $form->field($model, 'contacts')->textInput(['maxlength' => true]) ?>
39 47
backend/web/css/AdminLTE.css
@@ -13,6 +13,11 @@ @@ -13,6 +13,11 @@
13 html, 13 html,
14 body { 14 body {
15 min-height: 100%; 15 min-height: 100%;
  16 + min-width: 100%;
  17 +
  18 +}
  19 +.row{
  20 + margin: 0!important;
16 } 21 }
17 .layout-boxed html, 22 .layout-boxed html,
18 .layout-boxed body { 23 .layout-boxed body {
@@ -23,14 +28,13 @@ body { @@ -23,14 +28,13 @@ body {
23 -moz-osx-font-smoothing: grayscale; 28 -moz-osx-font-smoothing: grayscale;
24 font-family: 'Source Sans Pro', 'Helvetica Neue', Helvetica, Arial, sans-serif; 29 font-family: 'Source Sans Pro', 'Helvetica Neue', Helvetica, Arial, sans-serif;
25 font-weight: 400; 30 font-weight: 400;
26 - overflow-x: hidden;  
27 overflow-y: auto; 31 overflow-y: auto;
  32 + position: absolute;
28 } 33 }
29 /* Layout */ 34 /* Layout */
30 .wrapper { 35 .wrapper {
31 min-height: 100%; 36 min-height: 100%;
32 position: relative; 37 position: relative;
33 - overflow: hidden!important;  
34 } 38 }
35 .wrapper:before, 39 .wrapper:before,
36 .wrapper:after { 40 .wrapper:after {
@@ -688,7 +692,7 @@ a:focus { @@ -688,7 +692,7 @@ a:focus {
688 transition: right 0.3s ease-in-out; 692 transition: right 0.3s ease-in-out;
689 } 693 }
690 .control-sidebar { 694 .control-sidebar {
691 - position: absolute; 695 + position: fixed;
692 padding-top: 50px; 696 padding-top: 50px;
693 z-index: 1010; 697 z-index: 1010;
694 } 698 }
backend/web/css/site.css
@@ -146,4 +146,37 @@ a.desc:after { @@ -146,4 +146,37 @@ a.desc:after {
146 146
147 .ui-tooltip{ 147 .ui-tooltip{
148 display: none !important; 148 display: none !important;
  149 +}
  150 +
  151 +#entity{
  152 + display: none;
  153 +}
  154 +
  155 +.img-action-buttons{
  156 + margin: 5px;
  157 +}
  158 +
  159 +.gallery_image{
  160 +
  161 + position: relative;
  162 + margin-left: 20px;
  163 + margin-top: 20px;
  164 + display: inline-block;
  165 +}
  166 +.delete-gallery-item{
  167 + background-color: #fff;
  168 + opacity: 0.5;
  169 + font-size: 20px;
  170 + position: absolute;
  171 + top: 5px;
  172 + right: 5px;
  173 + cursor: pointer;
  174 +}
  175 +
  176 +.delete-field-item{
  177 + position: absolute;
  178 + top: 33%;
  179 + right: -35px;
  180 + font-size: 15px;
  181 + cursor: pointer;
149 } 182 }
150 \ No newline at end of file 183 \ No newline at end of file
backend/web/js/script.js
  1 +$( document ).ready(function() {
  2 + $('.main_user_info').click(function(){
  3 + if(!$(this).hasClass('active')){
  4 + $('#accounts-is_firm').val('1');
  5 +
  6 + $(this).removeClass('btn-default').addClass('active').addClass('btn-primary');
  7 + $('#main_user_info').css('display','block');
  8 +
  9 + $('.entity').removeClass('active').removeClass('btn-primary').addClass('btn-default');
  10 + $('#entity').css('display','none');
  11 +
  12 +
  13 + }
  14 + });
  15 +
  16 + $('.entity').click(function(){
  17 + if(!$(this).hasClass('active')){
  18 + $('#accounts-is_firm').val('0');
  19 + $(this).removeClass('btn-default').addClass('active').addClass('btn-primary');
  20 + $('#entity').css('display','block');
  21 +
  22 + $('.main_user_info').removeClass('active').removeClass('btn-primary').addClass('btn-default');
  23 + $('#main_user_info').css('display','none');
  24 +
  25 +
  26 + }
  27 + });
  28 +});
0 \ No newline at end of file 29 \ No newline at end of file
common/models/Accounts.php
@@ -3,7 +3,9 @@ @@ -3,7 +3,9 @@
3 namespace common\models; 3 namespace common\models;
4 4
5 use Yii; 5 use Yii;
6 - 6 +use yii\web\IdentityInterface;
  7 +use yii\base\NotSupportedException;
  8 +use yii\db\ActiveRecord;
7 /** 9 /**
8 * This is the model class for table "w_accounts". 10 * This is the model class for table "w_accounts".
9 * 11 *
@@ -45,12 +47,12 @@ use Yii; @@ -45,12 +47,12 @@ use Yii;
45 * @property string $firm_site 47 * @property string $firm_site
46 * @property string $company 48 * @property string $company
47 */ 49 */
48 -class Accounts extends \yii\db\ActiveRecord 50 +class Accounts extends ActiveRecord implements IdentityInterface
49 { 51 {
50 52
51 public $re_pass; 53 public $re_pass;
52 public $surname; 54 public $surname;
53 - public $verifyCode; 55 + public $country_region;
54 56
55 /** 57 /**
56 * @inheritdoc 58 * @inheritdoc
@@ -63,8 +65,8 @@ class Accounts extends \yii\db\ActiveRecord @@ -63,8 +65,8 @@ class Accounts extends \yii\db\ActiveRecord
63 65
64 public function beforeSave() 66 public function beforeSave()
65 { 67 {
66 - $date = \DateTime::createFromFormat("Y.m.d" , $this->dt);  
67 - $this->dt = $date->getTimestamp(); 68 + $this->dt = time();
  69 + return true;
68 70
69 } 71 }
70 72
@@ -87,7 +89,6 @@ class Accounts extends \yii\db\ActiveRecord @@ -87,7 +89,6 @@ class Accounts extends \yii\db\ActiveRecord
87 [['email'], 'unique'], 89 [['email'], 'unique'],
88 [['email'], 'email'], 90 [['email'], 'email'],
89 ['re_pass', 'compare', 'compareAttribute' => 'pass'], 91 ['re_pass', 'compare', 'compareAttribute' => 'pass'],
90 - ['verifyCode', 'captcha'],  
91 ['dt', 'date', 'format' => 'Y.m.d'] 92 ['dt', 'date', 'format' => 'Y.m.d']
92 ]; 93 ];
93 } 94 }
@@ -134,6 +135,152 @@ class Accounts extends \yii\db\ActiveRecord @@ -134,6 +135,152 @@ class Accounts extends \yii\db\ActiveRecord
134 'firm_mfo' => 'МФО', 135 'firm_mfo' => 'МФО',
135 'firm_site' => 'Сайт', 136 'firm_site' => 'Сайт',
136 'company' => 'Название фирмы', 137 'company' => 'Название фирмы',
  138 + 'country_region' => 'Регион'
137 ]; 139 ];
138 } 140 }
  141 +
  142 +
  143 + /**
  144 + * Signs user up.
  145 + *
  146 + * @return User|null the saved model or null if saving fails
  147 + */
  148 + public function signup()
  149 + {
  150 +
  151 + if ($this->validate()) {
  152 + $this->name = $this->surname.' '.$this->name;
  153 +
  154 + if( $this->is_firm ){
  155 + $this->if_manager = '0';
  156 + $this->margin_id = '1';
  157 + $this->address = '';
  158 + $this->comment = 'Новый пользователь';
  159 + $this->rating = '0';
  160 + $this->is_active = '1';
  161 + $this->last_loginin = '';
  162 + $this->firm_inn = '';
  163 + $this->firm_bank ='';
  164 + $this->balance ='0.00';
  165 + $this->office_id ='1';
  166 + $this->is_scribe ='1';
  167 + $this->set_manager_id ='0';
  168 + $this->phones2='';
  169 + $this->phones3 ='';
  170 + $this->snumb ='';
  171 + $this->firm_ur_adr ='';
  172 + $this->firm_fiz_adr = '';
  173 + $this->firm_code_eg = '';
  174 + $this->firm_rs = '';
  175 + $this->firm_mfo = '';
  176 + $this->firm_site = '';
  177 + }else{
  178 +
  179 + $this->if_manager = '0';
  180 + $this->margin_id = '1';
  181 + $this->address = '';
  182 + $this->comment = 'Новый пользователь';
  183 + $this->rating = '0';
  184 + $this->is_active = '1';
  185 + $this->last_loginin = '';
  186 + $this->firm_inn = '';
  187 + $this->firm_bank ='';
  188 + $this->balance ='0.00';
  189 + $this->office_id ='1';
  190 + $this->is_scribe ='1';
  191 + $this->set_manager_id ='0';
  192 + $this->phones2='';
  193 + $this->phones3 ='';
  194 + $this->snumb ='';
  195 + $this->firm_ur_adr ='';
  196 + $this->firm_fiz_adr = '';
  197 + $this->firm_code_eg = '';
  198 + $this->firm_rs = '';
  199 + $this->firm_mfo = '';
  200 + $this->firm_site = '';
  201 + }
  202 +
  203 + if ($this->save()) {
  204 + return $this;
  205 + }
  206 + }
  207 +
  208 + return null;
  209 + }
  210 + /**
  211 + * @inheritdoc
  212 + */
  213 + public static function findIdentity($id)
  214 + {
  215 + return static::findOne(['id' => $id]);
  216 + }
  217 +
  218 + /**
  219 + * @inheritdoc
  220 + */
  221 + public static function findIdentityByAccessToken($token, $type = null)
  222 + {
  223 + throw new NotSupportedException('"findIdentityByAccessToken" is not implemented.');
  224 + }
  225 +
  226 + /**
  227 + * Finds user by username
  228 + *
  229 + * @param string $username
  230 + * @return static|null
  231 + */
  232 + public static function findByUsername($username)
  233 + {
  234 + return static::findOne(['name' => $username]);
  235 + }
  236 +
  237 + /**
  238 + * @inheritdoc
  239 + */
  240 + public function getId()
  241 + {
  242 + return $this->getPrimaryKey();
  243 + }
  244 +
  245 + /**
  246 + * @inheritdoc
  247 + */
  248 + public function getAuthKey()
  249 + {
  250 + return $this->auth_key;
  251 + }
  252 +
  253 + /**
  254 + * @inheritdoc
  255 + */
  256 + public function validateAuthKey($authKey)
  257 + {
  258 + return $this->getAuthKey() === $authKey;
  259 + }
  260 +
  261 +
  262 +
  263 + /**
  264 + * Generates "remember me" authentication key
  265 + */
  266 + public function generateAuthKey()
  267 + {
  268 + $this->auth_key = Yii::$app->security->generateRandomString();
  269 + }
  270 +
  271 + /**
  272 + * Generates new password reset token
  273 + */
  274 + public function generatePasswordResetToken()
  275 + {
  276 + $this->password_reset_token = Yii::$app->security->generateRandomString() . '_' . time();
  277 + }
  278 +
  279 + /**
  280 + * Removes password reset token
  281 + */
  282 + public function removePasswordResetToken()
  283 + {
  284 + $this->password_reset_token = null;
  285 + }
139 } 286 }
common/models/AccountsForm.php 0 → 100644
  1 +<?php
  2 +
  3 +namespace common\models;
  4 +
  5 +use Yii;
  6 +use yii\web\IdentityInterface;
  7 +use yii\base\NotSupportedException;
  8 +use yii\db\ActiveRecord;
  9 +/**
  10 + * This is the model class for table "w_accounts".
  11 + *
  12 + *
  13 + * @property integer $id
  14 + * @property integer $if_manager
  15 + * @property string $email
  16 + * @property string $pass
  17 + * @property integer $margin_id
  18 + * @property string $name
  19 + * @property string $phones
  20 + * @property integer $country
  21 + * @property integer $city
  22 + * @property string $address
  23 + * @property string $comment
  24 + * @property integer $rating
  25 + * @property string $dt
  26 + * @property integer $is_active
  27 + * @property integer $is_firm
  28 + * @property string $last_loginin
  29 + * @property string $firm_inn
  30 + * @property string $firm_bank
  31 + * @property double $balance
  32 + * @property integer $office_id
  33 + * @property integer $is_scribe
  34 + * @property integer $set_manager_id
  35 + * @property string $phones2
  36 + * @property string $phones3
  37 + * @property integer $car
  38 + * @property integer $mod
  39 + * @property string $snumb
  40 + * @property integer $deliveries
  41 + * @property integer $scode
  42 + * @property string $firm_ur_adr
  43 + * @property string $firm_fiz_adr
  44 + * @property string $firm_code_eg
  45 + * @property string $firm_rs
  46 + * @property string $firm_mfo
  47 + * @property string $firm_site
  48 + * @property string $company
  49 + */
  50 +class AccountsForm extends ActiveRecord
  51 +{
  52 +
  53 + public $re_pass;
  54 + public $surname;
  55 + public $verifyCode;
  56 + public $country_region;
  57 +
  58 + /**
  59 + * @inheritdoc
  60 + */
  61 + public static function tableName()
  62 + {
  63 + return 'w_accounts';
  64 + }
  65 +
  66 +
  67 +
  68 + /**
  69 + * @inheritdoc
  70 + */
  71 + public function rules()
  72 + {
  73 + return [
  74 + [['if_manager', 'margin_id', 'country', 'city', 'rating', 'is_active', 'is_firm', 'office_id', 'is_scribe', 'set_manager_id', 'car', 'mod', 'deliveries', 'scode'], 'integer'],
  75 + [['company','email', 'pass', 'name','surname', 'phones',], 'required'],
  76 + [['comment'], 'string'],
  77 + [['balance'], 'number'],
  78 + [['email', 'name','surname', 'firm_site'], 'string', 'max' => 150],
  79 + [['pass','re_pass'], 'string', 'max' => 30],
  80 + [['phones', 'phones2', 'phones3'], 'string', 'max' => 50],
  81 + [['address', 'firm_inn', 'firm_bank'], 'string', 'max' => 254],
  82 + [['last_loginin'], 'string', 'max' => 15],
  83 + [['snumb', 'firm_ur_adr', 'firm_fiz_adr', 'firm_code_eg', 'firm_rs', 'firm_mfo', 'company'], 'string', 'max' => 255],
  84 + [['email'], 'unique'],
  85 + [['email'], 'email'],
  86 + ['re_pass', 'compare', 'compareAttribute' => 'pass'],
  87 + ['verifyCode', 'captcha'],
  88 + ['dt', 'date', 'format' => 'Y.m.d']
  89 + ];
  90 + }
  91 +
  92 + /**
  93 + * @inheritdoc
  94 + */
  95 + public function attributeLabels()
  96 + {
  97 + return [
  98 + 'id' => 'ID',
  99 + 'if_manager' => 'Статус менеджера',
  100 + 'email' => 'E-mail (Логин)',
  101 + 'pass' => 'Пароль',
  102 + 'margin_id' => 'Тип цены',
  103 + 'name' => 'Имя',
  104 + 'phones' => 'Телефоны',
  105 + 'country' => Yii::t('app', 'Country'),
  106 + 'city' =>'Город',
  107 + 'address' => 'Адрес',
  108 + 'comment' => 'Комментарий',
  109 + 'rating' => Yii::t('app', 'Rating'),
  110 + 'dt' =>'Дата регистрации',
  111 + 'is_active' => 'Активный',
  112 + 'is_firm' => 'Юридическое лицо',
  113 + 'last_loginin' => Yii::t('app', 'Last Loginin'),
  114 + 'firm_inn' => 'ИНН',
  115 + 'firm_bank' => 'Банк',
  116 + 'balance' => Yii::t('app', 'Balance'),
  117 + 'office_id' => Yii::t('app', 'Office ID'),
  118 + 'is_scribe' => 'Подписка',
  119 + 'set_manager_id' => 'Персональный менеджер',
  120 + 'phones2' => 'Телефоны 2',
  121 + 'phones3' => 'Телефоны 3',
  122 + 'car' => Yii::t('app', 'Car'),
  123 + 'mod' => Yii::t('app', 'Mod'),
  124 + 'snumb' => 'snumb',
  125 + 'deliveries' => Yii::t('app', 'Deliveries'),
  126 + 'scode' => 'Код в 1С',
  127 + 'firm_ur_adr' => 'Юридический адрес',
  128 + 'firm_fiz_adr' => 'Физический адрес',
  129 + 'firm_code_eg' => 'Код ЭГ',
  130 + 'firm_rs' => 'Расчётный счёт',
  131 + 'firm_mfo' => 'МФО',
  132 + 'firm_site' => 'Сайт',
  133 + 'company' => 'Название фирмы',
  134 + 'country_region' => 'Регион'
  135 + ];
  136 + }
  137 +
  138 +
  139 +}
common/models/DicCities.php
@@ -47,4 +47,8 @@ class DicCities extends \yii\db\ActiveRecord @@ -47,4 +47,8 @@ class DicCities extends \yii\db\ActiveRecord
47 'parent' => Yii::t('app', 'Parent'), 47 'parent' => Yii::t('app', 'Parent'),
48 ]; 48 ];
49 } 49 }
  50 +
  51 + public function getCitiesByRegion($region_id){
  52 + return self::find()->where(['parent'=>$region_id])->all();
  53 + }
50 } 54 }
common/models/Team.php
@@ -54,4 +54,9 @@ class Team extends \yii\db\ActiveRecord @@ -54,4 +54,9 @@ class Team extends \yii\db\ActiveRecord
54 'code' => 'Code', 54 'code' => 'Code',
55 ]; 55 ];
56 } 56 }
  57 +
  58 + public function getTeamGroup()
  59 + {
  60 + return $this->hasOne(TeamGroup::className(), ['id' => 'group_id']);
  61 + }
57 } 62 }
common/models/TeamGroup.php
@@ -41,4 +41,9 @@ class TeamGroup extends \yii\db\ActiveRecord @@ -41,4 +41,9 @@ class TeamGroup extends \yii\db\ActiveRecord
41 'name' => 'Name', 41 'name' => 'Name',
42 ]; 42 ];
43 } 43 }
  44 +
  45 + public function getTeam()
  46 + {
  47 + return $this->hasMany(Team::className(), ['group_id' => 'id']);
  48 + }
44 } 49 }
frontend/assets/InternalAsset.php
@@ -31,6 +31,7 @@ class InternalAsset extends AssetBundle @@ -31,6 +31,7 @@ class InternalAsset extends AssetBundle
31 'css/perfect-scrollbar/js/perfect-scrollbar.js', 31 'css/perfect-scrollbar/js/perfect-scrollbar.js',
32 'js/ital_auto.js', 32 'js/ital_auto.js',
33 'js/script.js', 33 'js/script.js',
  34 + 'js/main.js',
34 'js/selectize.js', 35 'js/selectize.js',
35 'js/select.js', 36 'js/select.js',
36 'js/validation/dist/jquery.validate.js', 37 'js/validation/dist/jquery.validate.js',
frontend/assets/OuterAsset.php
@@ -29,6 +29,7 @@ class OuterAsset extends AssetBundle @@ -29,6 +29,7 @@ class OuterAsset extends AssetBundle
29 'css/perfect-scrollbar/js/perfect-scrollbar.js', 29 'css/perfect-scrollbar/js/perfect-scrollbar.js',
30 'js/ital_auto.js', 30 'js/ital_auto.js',
31 'js/script.js', 31 'js/script.js',
  32 + 'js/main.js',
32 'js/selectize.js', 33 'js/selectize.js',
33 'js/select.js', 34 'js/select.js',
34 'js/validation/dist/jquery.validate.js' 35 'js/validation/dist/jquery.validate.js'
frontend/controllers/AjaxController.php 0 → 100644
  1 +<?php
  2 +/**
  3 + * Created by PhpStorm.
  4 + * User: vitaliy
  5 + * Date: 08.11.15
  6 + * Time: 22:06
  7 + */
  8 +
  9 +namespace frontend\controllers;
  10 +
  11 +use common\models\DicCities;
  12 +use Yii;
  13 +use yii\web\Controller;
  14 +
  15 +class AjaxController extends Controller {
  16 +
  17 +
  18 + public $enableCsrfValidation = false;
  19 +
  20 + public function actionGetCity($region_id){
  21 +
  22 + $model = new DicCities();
  23 + $cities = $model->getCitiesByRegion($region_id);
  24 + return $this->renderPartial('cities_list',[
  25 + 'cities' => $cities
  26 + ]);
  27 + }
  28 +
  29 + public function actionGetRegistrationForm($form){
  30 + return $this->renderPartial($form,[
  31 + ]);
  32 + }
  33 +
  34 +
  35 +}
0 \ No newline at end of file 36 \ No newline at end of file
frontend/controllers/SiteController.php
1 <?php 1 <?php
2 namespace frontend\controllers; 2 namespace frontend\controllers;
3 3
  4 +use common\models\Accounts;
  5 +use common\models\AccountsForm;
  6 +use common\models\Team;
  7 +use common\models\TeamGroup;
4 use Yii; 8 use Yii;
5 use common\models\LoginForm; 9 use common\models\LoginForm;
6 use frontend\models\PasswordResetRequestForm; 10 use frontend\models\PasswordResetRequestForm;
@@ -20,36 +24,7 @@ use common\components\MailWidget; @@ -20,36 +24,7 @@ use common\components\MailWidget;
20 class SiteController extends Controller 24 class SiteController extends Controller
21 { 25 {
22 26
23 - /**  
24 - * @inheritdoc  
25 - */  
26 - public function behaviors()  
27 - {  
28 - return [  
29 - 'access' => [  
30 - 'class' => AccessControl::className(),  
31 - 'only' => ['logout', 'signup'],  
32 - 'rules' => [  
33 - [  
34 - 'actions' => ['signup'],  
35 - 'allow' => true,  
36 - 'roles' => ['?'],  
37 - ],  
38 - [  
39 - 'actions' => ['logout'],  
40 - 'allow' => true,  
41 - 'roles' => ['@'],  
42 - ],  
43 - ],  
44 - ],  
45 - 'verbs' => [  
46 - 'class' => VerbFilter::className(),  
47 - 'actions' => [  
48 - 'logout' => ['post'],  
49 - ],  
50 - ],  
51 - ];  
52 - } 27 + // public $enableCsrfValidation = false;
53 28
54 /** 29 /**
55 * @inheritdoc 30 * @inheritdoc
@@ -193,10 +168,10 @@ class SiteController extends Controller @@ -193,10 +168,10 @@ class SiteController extends Controller
193 return $this->render('notepad'); 168 return $this->render('notepad');
194 } 169 }
195 170
196 - public function actionOptovikam() 171 + public function actionWholesalers()
197 { 172 {
198 $this->layout = '/internal'; 173 $this->layout = '/internal';
199 - return $this->render('optovikam'); 174 + return $this->render('wholesalers');
200 } 175 }
201 176
202 public function actionOriginalCatalog() 177 public function actionOriginalCatalog()
@@ -311,27 +286,18 @@ class SiteController extends Controller @@ -311,27 +286,18 @@ class SiteController extends Controller
311 return $this->goHome(); 286 return $this->goHome();
312 } 287 }
313 288
314 - /**  
315 - * Displays contact page.  
316 - *  
317 - * @return mixed  
318 - */  
319 - public function actionContact() 289 +
  290 + public function actionContacts()
320 { 291 {
321 - $model = new ContactForm();  
322 - if ($model->load(Yii::$app->request->post()) && $model->validate()) {  
323 - if ($model->sendEmail(Yii::$app->params['adminEmail'])) {  
324 - Yii::$app->session->setFlash('success', 'Thank you for contacting us. We will respond to you as soon as possible.');  
325 - } else {  
326 - Yii::$app->session->setFlash('error', 'There was an error sending email.');  
327 - } 292 + $this->layout = '/internal';
  293 + return $this->render('contacts');
  294 + }
328 295
329 - return $this->refresh();  
330 - } else {  
331 - return $this->render('contact', [  
332 - 'model' => $model,  
333 - ]);  
334 - } 296 +
  297 + public function actionPaymentDelivery()
  298 + {
  299 + $this->layout = '/internal';
  300 + return $this->render('payment_delivery');
335 } 301 }
336 302
337 /** 303 /**
@@ -341,8 +307,12 @@ class SiteController extends Controller @@ -341,8 +307,12 @@ class SiteController extends Controller
341 */ 307 */
342 public function actionAbout() 308 public function actionAbout()
343 { 309 {
  310 + $teamGroups = TeamGroup::find()->all();
  311 +
344 $this->layout = '/internal'; 312 $this->layout = '/internal';
345 - return $this->render('about'); 313 + return $this->render('about',[
  314 + 'teamGroups' => $teamGroups,
  315 + ]);
346 } 316 }
347 317
348 /** 318 /**
@@ -352,9 +322,12 @@ class SiteController extends Controller @@ -352,9 +322,12 @@ class SiteController extends Controller
352 */ 322 */
353 public function actionSignup() 323 public function actionSignup()
354 { 324 {
355 - $model = new SignupForm();  
356 - if ($model->load(Yii::$app->request->post())) { 325 + $model = new Accounts();
  326 +
  327 + if ($model->load(Yii::$app->request->post(),'AccountsForm')) {
  328 +
357 if ($user = $model->signup()) { 329 if ($user = $model->signup()) {
  330 +
358 if (Yii::$app->getUser()->login($user)) { 331 if (Yii::$app->getUser()->login($user)) {
359 return $this->goHome(); 332 return $this->goHome();
360 } 333 }
@@ -414,4 +387,5 @@ class SiteController extends Controller @@ -414,4 +387,5 @@ class SiteController extends Controller
414 'model' => $model, 387 'model' => $model,
415 ]); 388 ]);
416 } 389 }
  390 +
417 } 391 }
frontend/views/ajax/cities_list.php 0 → 100644
  1 +<?php foreach($cities as $city):?>
  2 + <option value="<?= $city->id ?>"><?= $city->name ?></option>
  3 +<?php endforeach?>
0 \ No newline at end of file 4 \ No newline at end of file
frontend/views/ajax/registration_for_company.php 0 → 100644
  1 +<?php
  2 +use yii\widgets\ActiveForm;
  3 +use \common\models\AccountsForm;
  4 +use \common\models\DicCities;
  5 +use \yii\helpers\ArrayHelper;
  6 +use \common\models\Deliveries;
  7 +use yii\captcha\Captcha;
  8 +?>
  9 +<div class="registration_for_company">
  10 + <?php $form = ActiveForm::begin(['options' => ['enctype'=> 'multipart/form-data'], 'method'=>'post','action' => 'site/signup']); ?>
  11 + <?= $form->field(new AccountsForm(), 'is_firm')->hiddenInput(['value'=>'1'])->label(false) ?>
  12 + <?= $form->field(new AccountsForm(), 'company')->textInput(['maxlength' => 45,'placeholder'=>'Компания'])->label(false) ?>
  13 + <?= $form->field(new AccountsForm(), 'name')->textInput(['maxlength' => 45,'placeholder'=>'Имя'])->label(false) ?>
  14 + <?= $form->field(new AccountsForm(), 'surname')->textInput(['maxlength' => 45,'placeholder'=>'Фамилия'])->label(false) ?>
  15 + <?= $form->field(new AccountsForm(), 'phones')->textInput(['maxlength' => 45,'placeholder'=>'Телефон'])->label(false) ?>
  16 +
  17 + <?= $form->field(new AccountsForm(), 'email')->textInput(['maxlength' => 45,'placeholder'=>'E-mail','class'=>'form-control telephone_registration'])->label(false) ?>
  18 +
  19 + <?= $form->field(new AccountsForm(), 'pass')->passwordInput(['maxlength' => 45,'placeholder'=>'Пароль','class'=>'form-control telephone_registration'])->label(false) ?>
  20 +
  21 + <?= $form->field(new AccountsForm(), 're_pass')->passwordInput(['maxlength' => 45,'placeholder'=>'Пароль','class'=>'form-control telephone_registration'])->label(false) ?>
  22 +
  23 + <?= $form->field(new AccountsForm(), 'country',['options'=>['class'=>'selectize_item2' ]])->dropDownList(
  24 + ArrayHelper::map(DicCities::find()->where(['parent' => 0])->all(), 'id', 'name'),
  25 + ['prompt' => 'Выберите область']
  26 + )->label(false);
  27 + ?>
  28 +
  29 + <?= $form->field(new AccountsForm(), 'city',['options'=>['class'=>'selectize_item2' ]])->dropDownList(
  30 + [],
  31 + ['prompt' => 'Выберите город']
  32 + )->label(false);
  33 + ?>
  34 +
  35 + <?= $form->field(new AccountsForm(), 'deliveries',['options'=>['class'=>'selectize_item2' ]])->dropDownList(
  36 + ArrayHelper::map(Deliveries::find()->all(), 'id', 'name'),
  37 + ['prompt' => 'Выберите тип перевозки']
  38 + )->label(false);
  39 + ?>
  40 +
  41 + <?= $form->field(new AccountsForm(), 'verifyCode')->widget(Captcha::className(), [
  42 + 'options'=>['placeholder'=>'Введите код' ],
  43 + 'template' => '<div>{input}</div><div class="row"><div class="col-lg-3">{image}</div></div>',
  44 + ])->label(false); ?>
  45 +
  46 + <button class="purple" type="submit" value="Submit">Зарегистрироваться</button>
  47 + <?php ActiveForm::end(); ?>
  48 +</div>
0 \ No newline at end of file 49 \ No newline at end of file
frontend/views/ajax/registration_for_person.php 0 → 100644
  1 +<?php
  2 +use yii\widgets\ActiveForm;
  3 +use \common\models\AccountsForm;
  4 +use \common\models\DicCities;
  5 +use \yii\helpers\ArrayHelper;
  6 +use \common\models\Deliveries;
  7 +use yii\captcha\Captcha;
  8 +?>
  9 +<div class="registration_for_person">
  10 + <?php $form = ActiveForm::begin(['options' => ['enctype'=> 'multipart/form-data'], 'method'=>'post','action' => 'site/signup']); ?>
  11 + <?= $form->field(new AccountsForm(), 'is_firm')->hiddenInput(['value'=>'0'])->label(false) ?>
  12 + <?= $form->field(new AccountsForm(), 'company')->hiddenInput(['value'=>'Частное лицо'])->label(false) ?>
  13 + <?= $form->field(new AccountsForm(), 'name')->textInput(['maxlength' => 45,'placeholder'=>'Имя'])->label(false) ?>
  14 + <?= $form->field(new AccountsForm(), 'surname')->textInput(['maxlength' => 45,'placeholder'=>'Фамилия'])->label(false) ?>
  15 + <?= $form->field(new AccountsForm(), 'phones')->textInput(['maxlength' => 45,'placeholder'=>'Телефон'])->label(false) ?>
  16 +
  17 + <?= $form->field(new AccountsForm(), 'email')->textInput(['maxlength' => 45,'placeholder'=>'E-mail','class'=>'form-control telephone_registration'])->label(false) ?>
  18 +
  19 + <?= $form->field(new AccountsForm(), 'pass')->passwordInput(['maxlength' => 45,'placeholder'=>'Пароль','class'=>'form-control telephone_registration'])->label(false) ?>
  20 +
  21 + <?= $form->field(new AccountsForm(), 're_pass')->passwordInput(['maxlength' => 45,'placeholder'=>'Пароль','class'=>'form-control telephone_registration'])->label(false) ?>
  22 +
  23 + <?= $form->field(new AccountsForm(), 'country',['options'=>['class'=>'selectize_item2' ]])->dropDownList(
  24 + ArrayHelper::map(DicCities::find()->where(['parent' => 0])->all(), 'id', 'name'),
  25 + ['prompt' => 'Выберите область']
  26 + )->label(false);
  27 + ?>
  28 +
  29 + <?= $form->field(new AccountsForm(), 'city',['options'=>['class'=>'selectize_item2' ]])->dropDownList(
  30 + [],
  31 + ['prompt' => 'Выберите город']
  32 + )->label(false);
  33 + ?>
  34 +
  35 + <?= $form->field(new AccountsForm(), 'deliveries',['options'=>['class'=>'selectize_item2' ]])->dropDownList(
  36 + ArrayHelper::map(Deliveries::find()->all(), 'id', 'name'),
  37 + ['prompt' => 'Выберите тип перевозки']
  38 + )->label(false);
  39 + ?>
  40 +
  41 + <?= $form->field(new AccountsForm(), 'verifyCode')->widget(Captcha::className(), [
  42 + 'options'=>['placeholder'=>'Введите код' ],
  43 + 'template' => '<div>{input}</div><div class="row"><div class="col-lg-3">{image}</div></div>',
  44 + ])->label(false); ?>
  45 +
  46 + <button class="purple" type="submit" value="Submit">Зарегистрироваться</button>
  47 + <?php ActiveForm::end(); ?>
  48 +</div>
0 \ No newline at end of file 49 \ No newline at end of file
frontend/views/cart/index.php
@@ -5,7 +5,7 @@ $this-&gt;registerCssFile(&#39;/css/style/busket.css&#39;); @@ -5,7 +5,7 @@ $this-&gt;registerCssFile(&#39;/css/style/busket.css&#39;);
5 $this->title = 'Корзина'; 5 $this->title = 'Корзина';
6 $this->params['breadcrumbs'][] = $this->title; 6 $this->params['breadcrumbs'][] = $this->title;
7 ?> 7 ?>
8 -<div class="vin"> 8 +<div class="main-vin">
9 <p class="vin_article">Корзина</p> 9 <p class="vin_article">Корзина</p>
10 <div class="choose_tovar"> 10 <div class="choose_tovar">
11 <p class="currency opposite" id="dollars">грн</p> 11 <p class="currency opposite" id="dollars">грн</p>
frontend/views/cart/step.php
@@ -7,7 +7,7 @@ $this-&gt;params[&#39;breadcrumbs&#39;][] = $this-&gt;title; @@ -7,7 +7,7 @@ $this-&gt;params[&#39;breadcrumbs&#39;][] = $this-&gt;title;
7 ?> 7 ?>
8 8
9 9
10 -<div class="vin"> 10 +<div class="main-vin">
11 <p class="vin_article">Корзина</p> 11 <p class="vin_article">Корзина</p>
12 <div class="choose_tovar"> 12 <div class="choose_tovar">
13 <form method="get" class="cmxform" action="" id="profile_form"> 13 <form method="get" class="cmxform" action="" id="profile_form">
frontend/views/layouts/main.php
@@ -14,6 +14,7 @@ use \yii\widgets\Menu; @@ -14,6 +14,7 @@ use \yii\widgets\Menu;
14 use \yii\helpers\Url; 14 use \yii\helpers\Url;
15 use common\models\Callback; 15 use common\models\Callback;
16 use \common\models\Accounts; 16 use \common\models\Accounts;
  17 +use \common\models\AccountsForm;
17 use \yii\helpers\ArrayHelper; 18 use \yii\helpers\ArrayHelper;
18 use \common\models\DicCities; 19 use \common\models\DicCities;
19 use \common\models\Deliveries; 20 use \common\models\Deliveries;
@@ -41,10 +42,10 @@ use yii\captcha\Captcha; @@ -41,10 +42,10 @@ use yii\captcha\Captcha;
41 'items' => [ 42 'items' => [
42 ['label' => 'О компании', 'url'=>Url::toRoute('/site/about')], 43 ['label' => 'О компании', 'url'=>Url::toRoute('/site/about')],
43 ['label' => 'Каталоги', 'url'=>'/page/FAQ'], 44 ['label' => 'Каталоги', 'url'=>'/page/FAQ'],
44 - ['label' => 'Оптовикам','url'=>'/events/index'],  
45 - ['label' => 'Поставщикам','url'=>'/articles/index'],  
46 - ['label' => 'Оплата и доставка', 'url'=>Url::toRoute('/site/contact')],  
47 - ['label' => 'Контакты', 'url'=>Url::toRoute('/site/contact')], 45 + ['label' => 'Оптовикам','url'=>'/site/wholesalers'],
  46 + ['label' => 'Поставщикам','url'=>'/site/provider'],
  47 + ['label' => 'Оплата и доставка', 'url'=>Url::toRoute('/site/payment-delivery')],
  48 + ['label' => 'Контакты', 'url'=>Url::toRoute('/site/contacts')],
48 ], 49 ],
49 ]); 50 ]);
50 ?> 51 ?>
@@ -399,73 +400,43 @@ use yii\captcha\Captcha; @@ -399,73 +400,43 @@ use yii\captcha\Captcha;
399 <div class="registration_holder"> 400 <div class="registration_holder">
400 401
401 <div class="registration_for_person"> 402 <div class="registration_for_person">
402 - <?php $form = ActiveForm::begin(['options' => ['enctype'=> 'multipart/form-data'], 'method'=>'post','action' => '/']); ?>  
403 - <?= $form->field(new Accounts(), 'name')->textInput(['maxlength' => 45,'placeholder'=>'Имя'])->label(false) ?>  
404 - <?= $form->field(new Accounts(), 'surname')->textInput(['maxlength' => 45,'placeholder'=>'Фамилия'])->label(false) ?> 403 + <?php $form = ActiveForm::begin(['options' => ['enctype'=> 'multipart/form-data'], 'method'=>'post','action' => 'site/signup']); ?>
405 404
406 - <?= $form->field(new Accounts(), 'email')->textInput(['maxlength' => 45,'placeholder'=>'E-mail','class'=>'form-control telephone_registration'])->label(false) ?> 405 + <?= $form->field(new AccountsForm(), 'is_firm')->hiddenInput(['value'=>'0'])->label(false) ?>
407 406
408 - <?= $form->field(new Accounts(), 'pass')->passwordInput(['maxlength' => 45,'placeholder'=>'Пароль','class'=>'form-control telephone_registration'])->label(false) ?> 407 + <?= $form->field(new AccountsForm(), 'company')->hiddenInput(['value'=>'Частное лицо'])->label(false) ?>
409 408
410 - <?= $form->field(new Accounts(), 're_pass')->passwordInput(['maxlength' => 45,'placeholder'=>'Пароль','class'=>'form-control telephone_registration'])->label(false) ?> 409 + <?= $form->field(new AccountsForm(), 'name')->textInput(['maxlength' => 45,'placeholder'=>'Имя'])->label(false) ?>
411 410
412 - <?= $form->field(new Accounts(), 'country',['options'=>['class'=>'selectize_item2' ]])->dropDownList(  
413 - ArrayHelper::map(DicCities::find()->where(['parent' => 0])->all(), 'id', 'name'),  
414 - ['prompt' => 'Выберите область']  
415 - )->label(false);  
416 - ?>  
417 -  
418 - <?= $form->field(new Accounts(), 'country',['options'=>['class'=>'selectize_item2' ]])->dropDownList(  
419 - [],  
420 - ['prompt' => 'Выберите город']  
421 - )->label(false);  
422 - ?>  
423 -  
424 - <?= $form->field(new Accounts(), 'country',['options'=>['class'=>'selectize_item2' ]])->dropDownList(  
425 - ArrayHelper::map(Deliveries::find()->all(), 'id', 'name'),  
426 - ['prompt' => 'Выберите тип перевозки']  
427 - )->label(false);  
428 - ?> 411 + <?= $form->field(new AccountsForm(), 'surname')->textInput(['maxlength' => 45,'placeholder'=>'Фамилия'])->label(false) ?>
429 412
430 - <?= $form->field(new Accounts(), 'verifyCode')->widget(Captcha::className(), [  
431 - 'options'=>['placeholder'=>'Введите код' ],  
432 - 'template' => '<div>{input}</div><div class="row"><div class="col-lg-3">{image}</div></div>',  
433 - ])->label(false); ?> 413 + <?= $form->field(new AccountsForm(), 'phones')->textInput(['maxlength' => 45,'placeholder'=>'Телефон'])->label(false) ?>
434 414
435 - <button class="purple" type="submit" value="Submit">Зарегистрироваться</button>  
436 - <?php ActiveForm::end(); ?>  
437 - </div>  
438 - <div class="registration_for_company">  
439 - <?php $form = ActiveForm::begin(['options' => ['enctype'=> 'multipart/form-data'], 'method'=>'post','action' => '/']); ?>  
440 - <?= $form->field(new Accounts(), 'company')->textInput(['maxlength' => 45,'placeholder'=>'Компания'])->label(false) ?>  
441 - <?= $form->field(new Accounts(), 'name')->textInput(['maxlength' => 45,'placeholder'=>'Имя'])->label(false) ?>  
442 - <?= $form->field(new Accounts(), 'surname')->textInput(['maxlength' => 45,'placeholder'=>'Фамилия'])->label(false) ?> 415 + <?= $form->field(new AccountsForm(), 'email')->textInput(['maxlength' => 45,'placeholder'=>'E-mail','class'=>'form-control telephone_registration'])->label(false) ?>
443 416
444 - <?= $form->field(new Accounts(), 'email')->textInput(['maxlength' => 45,'placeholder'=>'E-mail','class'=>'form-control telephone_registration'])->label(false) ?> 417 + <?= $form->field(new AccountsForm(), 'pass')->passwordInput(['maxlength' => 45,'placeholder'=>'Пароль','class'=>'form-control telephone_registration'])->label(false) ?>
445 418
446 - <?= $form->field(new Accounts(), 'pass')->passwordInput(['maxlength' => 45,'placeholder'=>'Пароль','class'=>'form-control telephone_registration'])->label(false) ?> 419 + <?= $form->field(new AccountsForm(), 're_pass')->passwordInput(['maxlength' => 45,'placeholder'=>'Пароль','class'=>'form-control telephone_registration'])->label(false) ?>
447 420
448 - <?= $form->field(new Accounts(), 're_pass')->passwordInput(['maxlength' => 45,'placeholder'=>'Пароль','class'=>'form-control telephone_registration'])->label(false) ?>  
449 -  
450 - <?= $form->field(new Accounts(), 'country',['options'=>['class'=>'selectize_item2' ]])->dropDownList( 421 + <?= $form->field(new AccountsForm(), 'country',['options'=>['class'=>'selectize_item2' ]])->dropDownList(
451 ArrayHelper::map(DicCities::find()->where(['parent' => 0])->all(), 'id', 'name'), 422 ArrayHelper::map(DicCities::find()->where(['parent' => 0])->all(), 'id', 'name'),
452 ['prompt' => 'Выберите область'] 423 ['prompt' => 'Выберите область']
453 )->label(false); 424 )->label(false);
454 ?> 425 ?>
455 426
456 - <?= $form->field(new Accounts(), 'country',['options'=>['class'=>'selectize_item2' ]])->dropDownList( 427 + <?= $form->field(new AccountsForm(), 'city',['options'=>['class'=>'selectize_item2' ]])->dropDownList(
457 [], 428 [],
458 ['prompt' => 'Выберите город'] 429 ['prompt' => 'Выберите город']
459 )->label(false); 430 )->label(false);
460 ?> 431 ?>
461 432
462 - <?= $form->field(new Accounts(), 'country',['options'=>['class'=>'selectize_item2' ]])->dropDownList( 433 + <?= $form->field(new AccountsForm(), 'deliveries',['options'=>['class'=>'selectize_item2' ]])->dropDownList(
463 ArrayHelper::map(Deliveries::find()->all(), 'id', 'name'), 434 ArrayHelper::map(Deliveries::find()->all(), 'id', 'name'),
464 ['prompt' => 'Выберите тип перевозки'] 435 ['prompt' => 'Выберите тип перевозки']
465 )->label(false); 436 )->label(false);
466 ?> 437 ?>
467 438
468 - <?= $form->field(new Accounts(), 'verifyCode')->widget(Captcha::className(), [ 439 + <?= $form->field(new AccountsForm(), 'verifyCode')->widget(Captcha::className(), [
469 'options'=>['placeholder'=>'Введите код' ], 440 'options'=>['placeholder'=>'Введите код' ],
470 'template' => '<div>{input}</div><div class="row"><div class="col-lg-3">{image}</div></div>', 441 'template' => '<div>{input}</div><div class="row"><div class="col-lg-3">{image}</div></div>',
471 ])->label(false); ?> 442 ])->label(false); ?>
@@ -473,6 +444,7 @@ use yii\captcha\Captcha; @@ -473,6 +444,7 @@ use yii\captcha\Captcha;
473 <button class="purple" type="submit" value="Submit">Зарегистрироваться</button> 444 <button class="purple" type="submit" value="Submit">Зарегистрироваться</button>
474 <?php ActiveForm::end(); ?> 445 <?php ActiveForm::end(); ?>
475 </div> 446 </div>
  447 +
476 </div> 448 </div>
477 </div> 449 </div>
478 450
frontend/views/news/index.php
@@ -18,7 +18,7 @@ $this-&gt;params[&#39;breadcrumbs&#39;][] = $this-&gt;title; @@ -18,7 +18,7 @@ $this-&gt;params[&#39;breadcrumbs&#39;][] = $this-&gt;title;
18 18
19 19
20 20
21 -<div class="vin"> 21 +<div class="main-vin">
22 <p class="vin_article">Новости</p> 22 <p class="vin_article">Новости</p>
23 <div class="choose_tovar"> 23 <div class="choose_tovar">
24 <?php 24 <?php
frontend/views/news/view.php
@@ -6,32 +6,33 @@ $this-&gt;title = $model-&gt;name; @@ -6,32 +6,33 @@ $this-&gt;title = $model-&gt;name;
6 $this->params['breadcrumbs'][] = ['label' => 'Новости', 'url' => ['index']]; 6 $this->params['breadcrumbs'][] = ['label' => 'Новости', 'url' => ['index']];
7 $this->params['breadcrumbs'][] = $this->title; 7 $this->params['breadcrumbs'][] = $this->title;
8 ?> 8 ?>
9 -<div class="vin"> 9 +<div class="main-vin">
10 <p class="vin_article"><?= $model->name ?></p> 10 <p class="vin_article"><?= $model->name ?></p>
11 - </div>  
12 -<div class="choose_tovar">  
13 -<img src="<?= $model->img ?>" class="big_article">  
14 -<div class="one_article">  
15 - <?= $model->content ?>  
16 -<div class="download_catalog">  
17 - <img src="/images/ico_exel.png">  
18 - <a href="<?= $model->price_list ?>">Скачать список товаров</a>  
19 -</div>  
20 -<div class='long_line'></div>  
21 -<div class="go_news">  
22 -<a href="">  
23 -<div class="back_news">  
24 - <p class='article'>Приход товара Mecarm</p>  
25 - <p class="short_news">На склад поступила очередная партия товара MecArm</p>  
26 -</div>  
27 -</a>  
28 -<a href="">  
29 -<div class="next_news">  
30 - <p class='article'>Приход товара Mecarm</p>  
31 - <p class="short_news">На склад поступила очередная партия товара MecArm</p>  
32 -</div>  
33 -</a>  
34 -</div>  
35 -</div>  
36 -<img src="/images/lonh_line.png" style="margin-top:-20px;opacity:0"> 11 +
  12 + <div class="choose_tovar">
  13 + <img src="<?= $model->img ?>" class="big_article">
  14 + <div class="one_article">
  15 + <?= $model->content ?>
  16 + <div class="download_catalog">
  17 + <img src="/images/ico_exel.png">
  18 + <a href="<?= $model->price_list ?>">Скачать список товаров</a>
  19 + </div>
  20 + <div class='long_line'></div>
  21 + <div class="go_news">
  22 + <a href="">
  23 + <div class="back_news">
  24 + <p class='article'>Приход товара Mecarm</p>
  25 + <p class="short_news">На склад поступила очередная партия товара MecArm</p>
  26 + </div>
  27 + </a>
  28 + <a href="">
  29 + <div class="next_news">
  30 + <p class='article'>Приход товара Mecarm</p>
  31 + <p class="short_news">На склад поступила очередная партия товара MecArm</p>
  32 + </div>
  33 + </a>
  34 + </div>
  35 + </div>
  36 + <img src="/images/lonh_line.png" style="margin-top:-20px;opacity:0">
  37 + </div>
37 </div> 38 </div>
frontend/views/site/about.php
1 <?php 1 <?php
2 -use yii\widgets\Menu;  
3 -  
4 -  
5 $this->registerCssFile('/css/about_company.css'); 2 $this->registerCssFile('/css/about_company.css');
6 3
7 $this->title = "О компании"; 4 $this->title = "О компании";
@@ -9,7 +6,7 @@ $this-&gt;params[&#39;breadcrumbs&#39;][] = $this-&gt;title; @@ -9,7 +6,7 @@ $this-&gt;params[&#39;breadcrumbs&#39;][] = $this-&gt;title;
9 ?> 6 ?>
10 7
11 8
12 -<div class="vin"> 9 +<div class="main-vin">
13 <p class="vin_article">О компании</p> 10 <p class="vin_article">О компании</p>
14 <div class='side_menu'> 11 <div class='side_menu'>
15 <ul class="side_menu-list" role="tablist"> 12 <ul class="side_menu-list" role="tablist">
@@ -27,197 +24,16 @@ $this-&gt;params[&#39;breadcrumbs&#39;][] = $this-&gt;title; @@ -27,197 +24,16 @@ $this-&gt;params[&#39;breadcrumbs&#39;][] = $this-&gt;title;
27 </p> 24 </p>
28 </div> 25 </div>
29 <div role="tabpanel" class="tab-pane" id="profile"> 26 <div role="tabpanel" class="tab-pane" id="profile">
30 - <table>  
31 - <tr>  
32 - <td class='team_header'>Руководитель</td>  
33 - </tr>  
34 - <tr>  
35 - <td class="personal_photo"><img src="/images/bershadskiy.png"></td>  
36 - </tr>  
37 - <tr>  
38 - <td class="personal_name">Олег Бершадский</td>  
39 - </tr>  
40 - <tr>  
41 - <td class='team_contacts'><a href=""><img src="/images/envelope.png">oleg@italauto.com.ua</a></td>  
42 - </tr>  
43 - <tr>  
44 - <td class='team_contacts'><a href=""><img src="/images/telephone_ico.png">044-593-9051 доб.4201</a></td>  
45 - </tr>  
46 - <tr>  
47 - <td class='team_contacts'><a href=""><img src="/images/skype.png">oleg-italauto</a></td>  
48 - </tr>  
49 -  
50 - </table>  
51 -  
52 - <table>  
53 - <tr>  
54 - <td class='team_header'>Продажи</td>  
55 - </tr>  
56 - <tr>  
57 - <td class="personal_photo"><img src="/images/ovcharenko.png"></td>  
58 - <td class="personal_photo"><img src="/images/ovcharenko1.png"></td>  
59 - <td class="personal_photo"><img src="/images/ovcharenko2.png"></td>  
60 - </tr>  
61 - <tr>  
62 - <td class="personal_name">Александр Васильев</td>  
63 - <td class="personal_name">Павел Овчаренко</td>  
64 - <td class="personal_name">Алексей Чельцов</td>  
65 - </tr>  
66 - <tr>  
67 - <td class='team_contacts'><a href=""><img src="/images/envelope.png">oleg@italauto.com.ua</a></td>  
68 - <td class='team_contacts'><a href=""><img src="/images/envelope.png">oleg@italauto.com.ua</a></td>  
69 - <td class='team_contacts'><a href=""><img src="/images/envelope.png">oleg@italauto.com.ua</a></td>  
70 - </tr>  
71 - <tr>  
72 - <td class='team_contacts'><a href=""><img src="/images/telephone_ico.png">044-593-9051 доб.4201</a></td>  
73 - <td class='team_contacts'><a href=""><img src="/images/telephone_ico.png">044-593-9051 доб.4201</a></td>  
74 - <td class='team_contacts'><a href=""><img src="/images/telephone_ico.png">044-593-9051 доб.4201</a></td>  
75 - </tr>  
76 - <tr>  
77 - <td class='team_contacts'><a href=""><img src="/images/skype.png">oleg-italauto</a></td>  
78 - <td class='team_contacts'><a href=""><img src="/images/skype.png">oleg-italauto</a></td>  
79 - <td class='team_contacts'><a href=""><img src="/images/skype.png">oleg-italauto</a></td>  
80 - </tr>  
81 -  
82 - </table>  
83 - <table>  
84 - <tr>  
85 - <td class='team_header'>Учет</td>  
86 - </tr>  
87 - <tr>  
88 - <td class="personal_photo"><img src="/images/nina.png"></td>  
89 - <td class="personal_photo"><img src="/images/tanya.png"></td>  
90 -  
91 - </tr>  
92 - <tr>  
93 - <td class="personal_name">Нина Носевич</td>  
94 - <td class="personal_name">Татьяна Михайленко</td>  
95 - </tr>  
96 - <tr>  
97 - <td class='team_contacts'><a href=""><img src="/images/envelope.png">oleg@italauto.com.ua</a></td>  
98 - <td class='team_contacts'><a href=""><img src="/images/envelope.png">oleg@italauto.com.ua</a></td>  
99 -  
100 - </tr>  
101 - <tr>  
102 - <td class='team_contacts'><a href=""><img src="/images/telephone_ico.png">044-593-9051 доб.4201</a></td>  
103 - <td class='team_contacts'><img src="/images/telephone_ico.png"><a href="">044-593-9051 доб.4201</a></td>  
104 -  
105 - </tr>  
106 - <tr>  
107 - <td class='team_contacts'><a href=""><img src="/images/skype.png">oleg-italauto</a></td>  
108 - <td class='team_contacts'><a href=""><img src="/images/skype.png">oleg-italauto</a></td>  
109 -  
110 - </tr>  
111 -  
112 - </table>  
113 - <table>  
114 - <tr>  
115 - <td class='team_header'>Склад</td>  
116 - </tr>  
117 - <tr>  
118 - <td class="personal_photo"><img src="/images/sklad1.png"></td>  
119 - <td class="personal_photo"><img src="/images/sklad2.png"></td>  
120 -  
121 - </tr>  
122 - <tr>  
123 - <td class="personal_name">Александр Буглак</td>  
124 - <td class="personal_name">Андрей Гаврилюк</td>  
125 - </tr>  
126 -  
127 - <tr>  
128 - <td class='team_contacts'><img src="/images/telephone_ico.png"><a href="">044-593-9051 доб.4201</a></td>  
129 - <td class='team_contacts'><a href=""><img src="/images/telephone_ico.png">044-593-9051 доб.4201</a></td>  
130 -  
131 - </tr>  
132 -  
133 -  
134 - </table>  
135 - <table>  
136 - <tr>  
137 - <td class='team_header'>Транспорт</td>  
138 - </tr>  
139 - <tr>  
140 - <td class="personal_photo"><img src="/images/transport.png"></td>  
141 - </tr>  
142 - <tr>  
143 - <td class="personal_name">Роман Ковтун</td>  
144 - </tr>  
145 - <tr>  
146 - <td class='team_contacts'><a href=""><img src="/images/envelope.png">oleg@italauto.com.ua</a></td>  
147 - </tr>  
148 - <tr>  
149 - <td class='team_contacts'><a href=""><img src="/images/telephone_ico.png">044-593-9051 доб.4201</a></td>  
150 - </tr>  
151 - <tr>  
152 - <td class='team_contacts'><a href=""><img src="/images/skype.png">oleg-italauto</a></td>  
153 - </tr>  
154 -  
155 - </table>  
156 - <table>  
157 - <tr>  
158 - <td class='team_header'>IT</td>  
159 - </tr>  
160 - <tr>  
161 - <td class="personal_photo"><img src="/images/transport.png"></td>  
162 - </tr>  
163 - <tr>  
164 - <td class="personal_name">Сергей Калиниченко</td>  
165 - </tr>  
166 - <tr>  
167 - <td class='team_contacts'><a href=""><img src="/images/envelope.png">oleg@italauto.com.ua</a></td>  
168 - </tr>  
169 - <tr>  
170 - <td class='team_contacts'><a href=""><img src="/images/telephone_ico.png">044-593-9051 доб.4201</a></td>  
171 - </tr>  
172 - <tr>  
173 - <td class='team_contacts'><a href=""><img src="/images/skype.png">oleg-italauto</a></td>  
174 - </tr>  
175 -  
176 - </table>  
177 - </div>  
178 - <div role="tabpanel" class="tab-pane" id="messages">  
179 - <div class="first_block">  
180 - <p style="font-size:19px; margin-bottom:20px;font-weight: normal">Контакты</p><br>  
181 - <p style="font-size:14px">г.Киев ул.Изюмская 5</p><br><br>  
182 - <div class="telephone">  
183 - <span><img src="/images/mts_contacts.png"></span>  
184 - <p>050-0400-192</p><br>  
185 - <span><img src="/images/kyiv_contacts.png"></span>  
186 - <p>097-0400-192</p><br>  
187 - <span><img src="/images/life_contacts.png"></span>  
188 - <p>093-0400-192</p><br>  
189 - </div>  
190 - <img src="/images/call_back.png">  
191 - <a href="" data-toggle="modal" data-target="#myModal">обратный звонок</a>  
192 - </div>  
193 - <div class="work_hours">  
194 - <p style="font-size:19px;font-weight: normal">График работы</p><br>  
195 - <p>Пн - Пт – с 9:00 до 18:00 (без перерыва)<br>  
196 - Сб - с 9:00 до 15:00<br>  
197 - Вс – выходной день</p>  
198 - </div>  
199 - <div class="block_contacts">  
200 - <p style="font-size:19px;font-weight: normal">Обратная связь</p><br>  
201 - <img src="/images/envelope.png">  
202 - <a href="">kiev@italauto.com.ua</a><br>  
203 - <img src="/images/skype.png">  
204 - <a href="">retror0107</a>  
205 -  
206 -  
207 - </div>  
208 - <iframe src="https://www.google.com/maps/embed?pb=!1m18!1m12!1m3!1d2542.5526259582884!2d30.51665609999999!3d50.4121746!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!3m3!1m2!1s0x40d4cf3af97c6063%3A0x29c06e78aacc11fc!2z0LLRg9C7LiDQhtC30Y7QvNGB0YzQutCwLCA1LCDQmtC40ZfQsg!5e0!3m2!1sru!2sua!4v1441100203696" width="880" height="297" frameborder="0" style="border:0" allowfullscreen=""></iframe>  
209 - </div>  
210 - <div role="tabpanel" class="tab-pane" id="settings">  
211 - <p class='payment'><span style="font-size:18px">Реквизиты для оплаты через "Приват Банк" на СПД Бершадский О. В.</span><br>  
212 -  
213 -ЄДРПОУ: 2690914236<br>  
214 -  
215 -Р/р: 26000060840517<br>  
216 -  
217 -Банк: ПАТ КБ "Приватбанк"<br>  
218 -  
219 -МФО: 300711</p> 27 + <?php foreach ($teamGroups as $group): ?>
  28 + <?=$this->render('team_list_layout', [
  29 + 'group' => $group
  30 + ]);?>
  31 + <?php endforeach; ?>
220 </div> 32 </div>
  33 + <?=$this->render('contacts_layout', [
  34 + ]);?>
  35 + <?=$this->render('payment_delivery_layout', [
  36 + ]);?>
221 </div> 37 </div>
222 </div> 38 </div>
223 <img src="/images/lonh_line.png" class='long_line'> 39 <img src="/images/lonh_line.png" class='long_line'>
frontend/views/site/contacts.php 0 → 100644
  1 +<?php
  2 +$this->registerCssFile('/css/about_company.css');
  3 +
  4 +$this->title = "Контакты";
  5 +$this->params['breadcrumbs'][] = $this->title;
  6 +?>
  7 +
  8 +<div class="main-vin">
  9 + <?=$this->render('contacts_layout', [
  10 + ]);?>
  11 +</div>
frontend/views/site/contacts_layout.php 0 → 100644
  1 +<div role="tabpanel" class="tab-pane" id="messages">
  2 + <div class="first_block">
  3 + <p style="font-size:19px; margin-bottom:20px;font-weight: normal">Контакты</p><br>
  4 + <p style="font-size:14px">г.Киев ул.Изюмская 5</p><br><br>
  5 + <div class="telephone">
  6 + <span><img src="/images/mts_contacts.png"></span>
  7 + <p>050-0400-192</p><br>
  8 + <span><img src="/images/kyiv_contacts.png"></span>
  9 + <p>097-0400-192</p><br>
  10 + <span><img src="/images/life_contacts.png"></span>
  11 + <p>093-0400-192</p><br>
  12 + </div>
  13 + <img src="/images/call_back.png">
  14 + <a href="" data-toggle="modal" data-target="#myModal">обратный звонок</a>
  15 + </div>
  16 + <div class="work_hours">
  17 + <p style="font-size:19px;font-weight: normal">График работы</p><br>
  18 + <p>Пн - Пт – с 9:00 до 18:00 (без перерыва)<br>
  19 + Сб - с 9:00 до 15:00<br>
  20 + Вс – выходной день</p>
  21 + </div>
  22 + <div class="block_contacts">
  23 + <p style="font-size:19px;font-weight: normal">Обратная связь</p><br>
  24 + <img src="/images/envelope.png">
  25 + <a href="">kiev@italauto.com.ua</a><br>
  26 + <img src="/images/skype.png">
  27 + <a href="">retror0107</a>
  28 +
  29 +
  30 + </div>
  31 + <div style="clear: both">
  32 + <iframe src="https://www.google.com/maps/embed?pb=!1m18!1m12!1m3!1d2542.5526259582884!2d30.51665609999999!3d50.4121746!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!3m3!1m2!1s0x40d4cf3af97c6063%3A0x29c06e78aacc11fc!2z0LLRg9C7LiDQhtC30Y7QvNGB0YzQutCwLCA1LCDQmtC40ZfQsg!5e0!3m2!1sru!2sua!4v1441100203696" width="880" height="297" frameborder="0" style="border:0" allowfullscreen=""></iframe>
  33 + </div>
  34 +</div>
frontend/views/site/payment_delivery.php 0 → 100644
  1 +<?php
  2 +$this->registerCssFile('/css/about_company.css');
  3 +
  4 +$this->title = "Оплата и доставка";
  5 +$this->params['breadcrumbs'][] = $this->title;
  6 +?>
  7 +
  8 +<div class="vin">
  9 + <p class="vin_article">Оплата и доставка</p>
  10 + <?=$this->render('payment_delivery_layout', [
  11 + ]);?>
  12 +</div>
frontend/views/site/payment_delivery_layout.php 0 → 100644
  1 +<div role="tabpanel" class="tab-pane" id="settings">
  2 + <p class='payment'><span style="font-size:18px">Реквизиты для оплаты через "Приват Банк" на СПД Бершадский О. В.</span><br>
  3 +
  4 + ЄДРПОУ: 2690914236<br>
  5 +
  6 + Р/р: 26000060840517<br>
  7 +
  8 + Банк: ПАТ КБ "Приватбанк"<br>
  9 +
  10 + МФО: 300711</p>
  11 +</div>
0 \ No newline at end of file 12 \ No newline at end of file
frontend/views/site/provider.php
1 <?php 1 <?php
2 2
3 $this->registerCssFile('/css/style/optovikam.css'); 3 $this->registerCssFile('/css/style/optovikam.css');
4 - 4 +$this->title = "Поставщикам";
5 $this->params['breadcrumbs'][] = $this->title; 5 $this->params['breadcrumbs'][] = $this->title;
6 ?> 6 ?>
7 7
@@ -9,12 +9,10 @@ $this-&gt;params[&#39;breadcrumbs&#39;][] = $this-&gt;title; @@ -9,12 +9,10 @@ $this-&gt;params[&#39;breadcrumbs&#39;][] = $this-&gt;title;
9 9
10 10
11 11
12 -<div class="vin">  
13 - <a href="" class="navigation">Италавто</a>  
14 - <img src="/images/arrow_dots.png" class='arrow_go'>  
15 - <span>Поставщикам</span> 12 +<div class="main-vin">
  13 +
16 <p class="vin_article">Поставщикам</p> 14 <p class="vin_article">Поставщикам</p>
17 - </div> 15 +
18 <div class="choose_tovar"> 16 <div class="choose_tovar">
19 <p class="choose_tovar-inviting">Приглашаем к сотрудничеству поставщиков товара.</p> 17 <p class="choose_tovar-inviting">Приглашаем к сотрудничеству поставщиков товара.</p>
20 18
@@ -64,83 +62,4 @@ $this-&gt;params[&#39;breadcrumbs&#39;][] = $this-&gt;title; @@ -64,83 +62,4 @@ $this-&gt;params[&#39;breadcrumbs&#39;][] = $this-&gt;title;
64 </tbody></table> 62 </tbody></table>
65 </div> 63 </div>
66 </div> 64 </div>
67 -  
68 -<div class="slider_block1">  
69 - <div class="tovars">  
70 - <p style="display:inline-block">Наши проекты</p>  
71 - <span><img src="/images/arrow_slider_back.png"></span>  
72 - <span class="number_of">1/</span>  
73 - <span class="general_number">5</span>  
74 - <span><img src="/images/arrow_slider_go.png"></span>  
75 - <div class="slider_tovars">  
76 -  
77 - <table class="block_project">  
78 - <tbody><tr><td>  
79 - <img src="/images/logo-lr-small.png">  
80 - </td></tr>  
81 - <tr><td>  
82 - <a href="">lr.italauto.com.ua</a>  
83 - </td></tr>  
84 - <tr><td>  
85 - <ul>  
86 - <h4>Запчасти на Land Rover<br> и Range Rover</h4>  
87 - <li>Оригинальные запчасти</li>  
88 - <li>Сертифицированый продавец</li>  
89 - <li>Более 300 000 товаров</li>  
90 - </ul>  
91 - </td></tr>  
92 - </tbody></table>  
93 - <table class="block_project">  
94 - <tbody><tr><td>  
95 - <img src="/images/logo-mersedes-small.png">  
96 - </td></tr>  
97 - <tr><td>  
98 - <a href="">lr.italauto.com.ua</a>  
99 - </td></tr>  
100 - <tr><td>  
101 - <ul>  
102 - <h4>Запчасти на<br> Mercedes Benz</h4>  
103 - <li>Оригинальные запчасти</li>  
104 - <li>Сертифицированый продавец</li>  
105 - <li>Более 300 000 товаров</li>  
106 - </ul>  
107 - </td></tr>  
108 - </tbody></table>  
109 - <table class="block_project">  
110 - <tbody><tr><td>  
111 - <img src="/images/logo-fiat-small.png">  
112 - </td></tr>  
113 - <tr><td>  
114 - <a href="">lr.italauto.com.ua</a>  
115 - </td></tr>  
116 - <tr><td>  
117 - <ul>  
118 - <h4>Запчасти на FIAT</h4>  
119 - <li>Оригинальные запчасти</li>  
120 - <li>Сертифицированый продавец</li>  
121 - <li>Более 300 000 товаров</li>  
122 - </ul>  
123 - </td></tr>  
124 - </tbody></table>  
125 - <table class="block_project">  
126 - <tbody><tr><td>  
127 - <img src="/images/logo-lr-small.png">  
128 - </td></tr>  
129 - <tr><td>  
130 - <a href="">lr.italauto.com.ua</a>  
131 - </td></tr>  
132 - <tr><td>  
133 - <ul>  
134 - <h4>Запчасти на Land Rover<br> и Range Rover</h4>  
135 - <li>Оригинальные запчасти</li>  
136 - <li>Сертифицированый продавец</li>  
137 - <li>Более 300 000 товаров</li>  
138 - </ul>  
139 - </td></tr>  
140 - </tbody></table>  
141 -  
142 - </div>  
143 -  
144 - </div>  
145 - </div>  
146 - 65 +</div>
frontend/views/site/team_list_layout.php 0 → 100644
  1 +<table>
  2 + <tr>
  3 + <td class='team_header'><?= $group->name ?></td>
  4 + </tr>
  5 + <tr>
  6 + <?php foreach($group->team as $team):?>
  7 + <td class="personal_photo"><img src="<?= $team->img ?>"></td>
  8 + <?php endforeach; ?>
  9 + </tr>
  10 + <tr>
  11 + <?php foreach($group->team as $team):?>
  12 + <td class="personal_name"><?= $team->name ?></td>
  13 + <?php endforeach; ?>
  14 + </tr>
  15 + <tr>
  16 + <?php foreach($group->team as $team):?>
  17 + <?php if( $team->email):?>
  18 + <td class='team_contacts'><a href=""><img src="/images/envelope.png"><?= $team->email ?></a></td>
  19 + <?php endif;?>
  20 + <?php endforeach; ?>
  21 + </tr>
  22 + <tr>
  23 + <?php foreach($group->team as $team):?>
  24 + <?php if( $team->phone):?>
  25 + <td class='team_contacts'><a href=""><img src="/images/telephone_ico.png"><?= $team->phone ?></a></td>
  26 + <?php endif;?>
  27 + <?php endforeach; ?>
  28 + </tr>
  29 + <tr>
  30 + <?php foreach($group->team as $team):?>
  31 + <?php if( $team->skype):?>
  32 + <td class='team_contacts'><a href=""><img src="/images/skype.png"><?= $team->skype ?></a></td>
  33 + <?php endif;?>
  34 + <?php endforeach; ?>
  35 + </tr>
  36 +
  37 +</table>
0 \ No newline at end of file 38 \ No newline at end of file
frontend/views/site/optovikam.php renamed to frontend/views/site/wholesalers.php
1 <?php 1 <?php
2 2
3 $this->registerCssFile('/css/style/optovikam.css'); 3 $this->registerCssFile('/css/style/optovikam.css');
4 - 4 +$this->title = "Оптовикам";
5 $this->params['breadcrumbs'][] = $this->title; 5 $this->params['breadcrumbs'][] = $this->title;
6 ?> 6 ?>
7 7
8 -<div class="vin">  
9 - <a href="" class="navigation">Италавто</a>  
10 - <img src="/images/arrow_dots.png" class='arrow_go'>  
11 - <span>Оптовикам</span> 8 +<div class="main-vin">
  9 +
12 <p class="vin_article">Оптовикам</p> 10 <p class="vin_article">Оптовикам</p>
13 - </div> 11 +
14 <div class="choose_tovar"> 12 <div class="choose_tovar">
15 <p class="choose_tovar-inviting">Приглашаем к сотрудничеству СТО, магазины и торгующие организации</p> 13 <p class="choose_tovar-inviting">Приглашаем к сотрудничеству СТО, магазины и торгующие организации</p>
16 14
@@ -51,81 +49,4 @@ $this-&gt;params[&#39;breadcrumbs&#39;][] = $this-&gt;title; @@ -51,81 +49,4 @@ $this-&gt;params[&#39;breadcrumbs&#39;][] = $this-&gt;title;
51 </div> 49 </div>
52 </div> 50 </div>
53 51
54 -<div class="slider_block1">  
55 - <div class="tovars">  
56 - <p style="display:inline-block">Наши проекты</p>  
57 - <span><img src="/images/arrow_slider_back.png"></span>  
58 - <span class="number_of">1/</span>  
59 - <span class="general_number">5</span>  
60 - <span><img src="/images/arrow_slider_go.png"></span>  
61 - <div class="slider_tovars">  
62 -  
63 - <table class="block_project">  
64 - <tbody><tr><td>  
65 - <img src="/images/logo-lr-small.png">  
66 - </td></tr>  
67 - <tr><td>  
68 - <a href="">lr.italauto.com.ua</a>  
69 - </td></tr>  
70 - <tr><td>  
71 - <ul>  
72 - <h4>Запчасти на Land Rover<br> и Range Rover</h4>  
73 - <li>Оригинальные запчасти</li>  
74 - <li>Сертифицированый продавец</li>  
75 - <li>Более 300 000 товаров</li>  
76 - </ul>  
77 - </td></tr>  
78 - </tbody></table>  
79 - <table class="block_project">  
80 - <tbody><tr><td>  
81 - <img src="/images/logo-mersedes-small.png">  
82 - </td></tr>  
83 - <tr><td>  
84 - <a href="">lr.italauto.com.ua</a>  
85 - </td></tr>  
86 - <tr><td>  
87 - <ul>  
88 - <h4>Запчасти на<br> Mercedes Benz</h4>  
89 - <li>Оригинальные запчасти</li>  
90 - <li>Сертифицированый продавец</li>  
91 - <li>Более 300 000 товаров</li>  
92 - </ul>  
93 - </td></tr>  
94 - </tbody></table>  
95 - <table class="block_project">  
96 - <tbody><tr><td>  
97 - <img src="/images/logo-fiat-small.png">  
98 - </td></tr>  
99 - <tr><td>  
100 - <a href="">lr.italauto.com.ua</a>  
101 - </td></tr>  
102 - <tr><td>  
103 - <ul>  
104 - <h4>Запчасти на FIAT</h4>  
105 - <li>Оригинальные запчасти</li>  
106 - <li>Сертифицированый продавец</li>  
107 - <li>Более 300 000 товаров</li>  
108 - </ul>  
109 - </td></tr>  
110 - </tbody></table>  
111 - <table class="block_project">  
112 - <tbody><tr><td>  
113 - <img src="/images/logo-lr-small.png">  
114 - </td></tr>  
115 - <tr><td>  
116 - <a href="">lr.italauto.com.ua</a>  
117 - </td></tr>  
118 - <tr><td>  
119 - <ul>  
120 - <h4>Запчасти на Land Rover<br> и Range Rover</h4>  
121 - <li>Оригинальные запчасти</li>  
122 - <li>Сертифицированый продавец</li>  
123 - <li>Более 300 000 товаров</li>  
124 - </ul>  
125 - </td></tr>  
126 - </tbody></table>  
127 -  
128 - </div>  
129 -  
130 - </div>  
131 - </div> 52 +</div>
132 \ No newline at end of file 53 \ No newline at end of file
frontend/web/css/BC2_catalog.css
@@ -33,10 +33,7 @@ @@ -33,10 +33,7 @@
33 display: inline-block; 33 display: inline-block;
34 margin-left: 15px; 34 margin-left: 15px;
35 } 35 }
36 -.vin{  
37 - width: 960px;  
38 - margin: 40px auto 12px;  
39 -} 36 +
40 37
41 #stone-filter-form ul{ 38 #stone-filter-form ul{
42 list-style-type: none; 39 list-style-type: none;
frontend/web/css/BC2_catalog_zapchasti.css
@@ -3,23 +3,11 @@ @@ -3,23 +3,11 @@
3 color: #828282; 3 color: #828282;
4 } 4 }
5 5
6 -.vin_article{  
7 - font-size:22px;  
8 - font-weight: 400;  
9 - margin-top:17px;  
10 - font-weight: 500;  
11 -}  
12 -  
13 .navigation{ 6 .navigation{
14 color: #6b84b5; 7 color: #6b84b5;
15 text-decoration: underline; 8 text-decoration: underline;
16 } 9 }
17 10
18 -.vin{  
19 - width: 960px!important;  
20 - margin: 34px auto;  
21 -}  
22 -  
23 .detail{ 11 .detail{
24 margin-top: -10px; 12 margin-top: -10px;
25 width: 460px; 13 width: 460px;
frontend/web/css/about_company.css
1 -.vin{  
2 - width:960px;  
3 - margin:0 auto;  
4 -}  
5 -  
6 .navigation { 1 .navigation {
7 color: #6b84b5; 2 color: #6b84b5;
8 text-decoration: underline; 3 text-decoration: underline;
9 } 4 }
10 5
11 -.vin {  
12 - margin-bottom: 19px!important;  
13 - width: 960px;  
14 - margin: 34px auto;  
15 -}  
16 6
17 -.vin_article {  
18 - border-bottom:1px solid #dfdfdf;  
19 - padding-bottom: 4px;  
20 - font-size: 22px;  
21 - font-weight: 500;  
22 - margin-top: 22px;  
23 -}  
24 7
25 8
26 .side_menu{ 9 .side_menu{
frontend/web/css/catalog_marok.css
1 -.vin {  
2 - margin-bottom: 19px!important;  
3 - width: 960px;  
4 - margin: 34px auto;  
5 - border-bottom: 1px solid #dfdfdf;  
6 -} 1 +
7 2
8 .vin_body { 3 .vin_body {
9 padding-bottom: 31px; 4 padding-bottom: 31px;
@@ -30,11 +25,6 @@ @@ -30,11 +25,6 @@
30 padding-bottom: 1px; 25 padding-bottom: 1px;
31 } 26 }
32 27
33 -.vin_article {  
34 - font-size: 22px;  
35 - font-weight: 500;  
36 - margin-top: 22px;  
37 -}  
38 28
39 .choose_catalog{ 29 .choose_catalog{
40 width: 960px; 30 width: 960px;
frontend/web/css/general_styles.css
@@ -730,29 +730,6 @@ @@ -730,29 +730,6 @@
730 cursor: pointer; 730 cursor: pointer;
731 } 731 }
732 732
733 -.registration_holder{  
734 - padding-top: 32px;  
735 - width: 432px;  
736 - height: auto;  
737 - border: 1px solid #c7c7c7;  
738 - border-radius: 0 0 12px 12px;  
739 - margin-bottom: 30px;  
740 - margin-top: -4px;  
741 -}  
742 -.modal-content1 {  
743 - position: relative;  
744 - background-color: #fff;  
745 - -webkit-background-clip: padding-box;  
746 - background-clip: padding-box;  
747 - border: 1px solid #999;  
748 - border: 1px solid rgba(0,0,0,.2);  
749 - outline: 0;  
750 - -webkit-box-shadow: 0 3px 9px rgba(0,0,0,.5);  
751 - box-shadow: 0 3px 9px rgba(0,0,0,.5);  
752 - border-bottom: 3px solid #dfdfdf!important;  
753 -  
754 -}  
755 -  
756 733
757 .first_block a:nth-child(12):hover { 734 .first_block a:nth-child(12):hover {
758 color: #8ca1c8; 735 color: #8ca1c8;
@@ -779,9 +756,6 @@ @@ -779,9 +756,6 @@
779 margin-right: 5px 756 margin-right: 5px
780 } 757 }
781 758
782 -.registration_for_company{  
783 - display: none;  
784 -}  
785 .registration_for_company a{ 759 .registration_for_company a{
786 float:right; 760 float:right;
787 color: #6b84b5; 761 color: #6b84b5;
@@ -2248,8 +2222,6 @@ left: -444px; @@ -2248,8 +2222,6 @@ left: -444px;
2248 2222
2249 2223
2250 2224
2251 -.vin_article{  
2252 -}  
2253 2225
2254 2226
2255 .number_of{ 2227 .number_of{
frontend/web/css/main.css
@@ -142,4 +142,43 @@ li a{ @@ -142,4 +142,43 @@ li a{
142 margin-bottom: 10px; 142 margin-bottom: 10px;
143 } 143 }
144 144
145 -div.required:after {content: " *"; color: #fec831;}  
146 \ No newline at end of file 145 \ No newline at end of file
  146 +div.required:after {content: " *"; color: #fec831;}
  147 +
  148 +.registration_holder{
  149 + padding-top: 32px;
  150 + width: 432px;
  151 + border: 1px solid #c7c7c7;
  152 + border-radius: 0 0 12px 12px;
  153 + margin-bottom: 30px;
  154 + margin-top: -4px;
  155 +}
  156 +.modal-content1 {
  157 + position: relative;
  158 + background-color: #fff;
  159 + -webkit-background-clip: padding-box;
  160 + background-clip: padding-box;
  161 + border: 1px solid #999;
  162 +
  163 + outline: 0;
  164 + -webkit-box-shadow: 0 3px 9px rgba(0,0,0,.5);
  165 + box-shadow: 0 3px 9px rgba(0,0,0,.5);
  166 + border-bottom: 3px solid #dfdfdf !important;
  167 +
  168 +}
  169 +.vin_article{
  170 + font-size: 22px;
  171 + font-weight: 500;
  172 + margin-top: 22px;
  173 + border-bottom: 1px solid #dfdfdf;
  174 + padding-bottom: 4px;
  175 +}
  176 +.main-vin{
  177 + width: 960px;
  178 + border-bottom: 1px solid #dfdfdf;
  179 + margin: 20px auto;
  180 +}
  181 +
  182 +.vin{
  183 + width: 960px;
  184 + margin: 20px auto;
  185 +}
147 \ No newline at end of file 186 \ No newline at end of file
frontend/web/css/news_all.css
@@ -2,14 +2,6 @@ p, a, label, span{ @@ -2,14 +2,6 @@ p, a, label, span{
2 font-family: "Ubuntu" 2 font-family: "Ubuntu"
3 } 3 }
4 4
5 -.vin {  
6 - margin-bottom: 19px!important;  
7 - width: 960px;  
8 - margin: 34px auto;  
9 - border-bottom: 1px solid #dfdfdf;  
10 -  
11 -}  
12 -  
13 .navigation:hover { 5 .navigation:hover {
14 color: #879cc3; 6 color: #879cc3;
15 } 7 }
@@ -27,11 +19,6 @@ p, a, label, span{ @@ -27,11 +19,6 @@ p, a, label, span{
27 padding-bottom: 1px; 19 padding-bottom: 1px;
28 } 20 }
29 21
30 -.vin_article {  
31 - font-size: 22px;  
32 - font-weight: 500;  
33 - margin-top: 22px;  
34 -}  
35 22
36 .choose_tovar{ 23 .choose_tovar{
37 width: 960px; 24 width: 960px;
frontend/web/css/not_found.css
@@ -2,13 +2,6 @@ @@ -2,13 +2,6 @@
2 padding-bottom: 1px; 2 padding-bottom: 1px;
3 } 3 }
4 4
5 -.vin{  
6 - padding-bottom: 38px;  
7 - width: 960px;  
8 - margin: 34px auto;  
9 - border-bottom: 1px solid #dfdfdf;  
10 -}  
11 -  
12 .vin img{ 5 .vin img{
13 margin-bottom: 1px; 6 margin-bottom: 1px;
14 } 7 }
@@ -17,12 +10,7 @@ @@ -17,12 +10,7 @@
17 text-decoration: underline; 10 text-decoration: underline;
18 } 11 }
19 12
20 -.vin_article{  
21 - font-size: 22px;  
22 - font-weight: 500;  
23 - margin-top: 22px;  
24 - border-bottom: 1px solid #dfdfdf;  
25 -} 13 +
26 .line{ 14 .line{
27 margin-bottom: 12px; 15 margin-bottom: 12px;
28 } 16 }
frontend/web/css/original_catalog.css
1 -.vin {  
2 - margin-bottom: 19px!important;  
3 - width: 960px;  
4 - margin: 34px auto;  
5 - border-bottom: 1px solid #dfdfdf;  
6 -}  
7 -  
8 .navigation { 1 .navigation {
9 color: #6b84b5; 2 color: #6b84b5;
10 text-decoration: underline; 3 text-decoration: underline;
@@ -14,11 +7,6 @@ @@ -14,11 +7,6 @@
14 margin-bottom: 1px; 7 margin-bottom: 1px;
15 } 8 }
16 9
17 -.vin_article {  
18 - font-size: 22px;  
19 - font-weight: 500;  
20 - margin-top: 22px;  
21 -}  
22 10
23 .choose_catalog{ 11 .choose_catalog{
24 width: 960px; 12 width: 960px;
frontend/web/css/search_filters.css
@@ -68,7 +68,6 @@ @@ -68,7 +68,6 @@
68 68
69 .choose_tovar{ 69 .choose_tovar{
70 margin-top: 30px; 70 margin-top: 30px;
71 - border-bottom: 1px solid #6b84b5;  
72 padding-bottom:21px; 71 padding-bottom:21px;
73 } 72 }
74 73
@@ -297,7 +296,6 @@ table.trackbar .r div { @@ -297,7 +296,6 @@ table.trackbar .r div {
297 table.trackbar { 296 table.trackbar {
298 width: 250px; 297 width: 250px;
299 margin: 10px 43px; 298 margin: 10px 43px;
300 - background: repeat-x url() top left;  
301 } 299 }
302 300
303 301
frontend/web/css/search_page.css
@@ -2,12 +2,6 @@ @@ -2,12 +2,6 @@
2 padding-bottom: 1px; 2 padding-bottom: 1px;
3 } 3 }
4 4
5 -.vin{  
6 - width: 960px;  
7 - margin: 34px auto;  
8 - border-bottom: 1px solid #dfdfdf;  
9 -}  
10 -  
11 .vin1{ 5 .vin1{
12 width: 960px; 6 width: 960px;
13 margin: 34px auto; 7 margin: 34px auto;
@@ -22,11 +16,6 @@ @@ -22,11 +16,6 @@
22 text-decoration: underline; 16 text-decoration: underline;
23 } 17 }
24 18
25 -.vin_article{  
26 - font-size:22px;  
27 - font-weight: 500;  
28 - margin-top:22px;  
29 -}  
30 .line{ 19 .line{
31 margin-bottom: 12px; 20 margin-bottom: 12px;
32 } 21 }
frontend/web/css/style.css
@@ -1419,15 +1419,6 @@ input{ @@ -1419,15 +1419,6 @@ input{
1419 cursor: pointer; 1419 cursor: pointer;
1420 } 1420 }
1421 1421
1422 -.registration_holder{  
1423 - padding-top: 32px;  
1424 - width: 432px;  
1425 - height: auto;  
1426 - border: 1px solid #c7c7c7;  
1427 - border-radius: 0 0 12px 12px;  
1428 - margin-bottom: 30px;  
1429 - margin-top: -4px;  
1430 -}  
1431 1422
1432 1423
1433 #modal_form_registration #code_input{ 1424 #modal_form_registration #code_input{
@@ -1449,19 +1440,13 @@ input{ @@ -1449,19 +1440,13 @@ input{
1449 margin-right: 5px 1440 margin-right: 5px
1450 } 1441 }
1451 1442
1452 -.registration_for_company{  
1453 - display: none;  
1454 -}  
1455 .registration_for_company a{ 1443 .registration_for_company a{
1456 float:right; 1444 float:right;
1457 color: #6b84b5; 1445 color: #6b84b5;
1458 margin-right: 5px 1446 margin-right: 5px
1459 } 1447 }
1460 1448
1461 -.registration_holder p{  
1462 - margin: 41px 0 0 51px;  
1463 - font-size: 18px;  
1464 -} 1449 +
1465 .code_generate{ 1450 .code_generate{
1466 float: right; 1451 float: right;
1467 margin: -55px 82px; 1452 margin: -55px 82px;
frontend/web/css/style/404.css
@@ -2,14 +2,6 @@ p, a, label, span{ @@ -2,14 +2,6 @@ p, a, label, span{
2 font-family: "Ubuntu" 2 font-family: "Ubuntu"
3 } 3 }
4 4
5 -.vin {  
6 - margin-bottom: 19px!important;  
7 - width: 960px;  
8 - margin: 34px auto;  
9 - border-bottom: 1px solid #dfdfdf;  
10 -  
11 -}  
12 -  
13 .navigation:hover { 5 .navigation:hover {
14 color: #879cc3; 6 color: #879cc3;
15 } 7 }
@@ -27,12 +19,6 @@ p, a, label, span{ @@ -27,12 +19,6 @@ p, a, label, span{
27 padding-bottom: 1px; 19 padding-bottom: 1px;
28 } 20 }
29 21
30 -.vin_article {  
31 - font-size: 22px;  
32 - font-weight: 500;  
33 - margin-top: 22px;  
34 -}  
35 -  
36 .choose_tovar{ 22 .choose_tovar{
37 width: 920px; 23 width: 920px;
38 margin: 121px auto 0; 24 margin: 121px auto 0;
frontend/web/css/style/brands.css
@@ -2,14 +2,6 @@ p, a, label, span{ @@ -2,14 +2,6 @@ p, a, label, span{
2 font-family: "Ubuntu" 2 font-family: "Ubuntu"
3 } 3 }
4 4
5 -.vin {  
6 - margin-bottom: 19px!important;  
7 - width: 960px;  
8 - margin: 34px auto;  
9 -  
10 -  
11 -}  
12 -  
13 .navigation:hover { 5 .navigation:hover {
14 color: #879cc3; 6 color: #879cc3;
15 } 7 }
@@ -27,13 +19,6 @@ p, a, label, span{ @@ -27,13 +19,6 @@ p, a, label, span{
27 padding-bottom: 1px; 19 padding-bottom: 1px;
28 } 20 }
29 21
30 -.vin_article {  
31 - font-size: 22px;  
32 - font-weight: 500;  
33 - margin-top: 22px;  
34 - border-bottom:1px solid #dfdfdf;  
35 - padding-bottom: 4px;  
36 -}  
37 22
38 .choose_tovar{ 23 .choose_tovar{
39 width: 960px; 24 width: 960px;
frontend/web/css/style/busket.css
@@ -2,14 +2,6 @@ p, a, label, span{ @@ -2,14 +2,6 @@ p, a, label, span{
2 font-family: "Ubuntu" 2 font-family: "Ubuntu"
3 } 3 }
4 4
5 -.vin {  
6 - margin-bottom: 19px!important;  
7 - width: 960px;  
8 - margin: 34px auto;  
9 - border-bottom: 1px solid #dfdfdf;  
10 -  
11 -}  
12 -  
13 .navigation:hover { 5 .navigation:hover {
14 color: #879cc3; 6 color: #879cc3;
15 } 7 }
@@ -27,11 +19,6 @@ p, a, label, span{ @@ -27,11 +19,6 @@ p, a, label, span{
27 padding-bottom: 1px; 19 padding-bottom: 1px;
28 } 20 }
29 21
30 -.vin_article {  
31 - font-size: 22px;  
32 - font-weight: 500;  
33 - margin-top: 22px;  
34 -}  
35 22
36 .choose_tovar{ 23 .choose_tovar{
37 width: 960px; 24 width: 960px;
frontend/web/css/style/my_profile.css
@@ -135,7 +135,6 @@ @@ -135,7 +135,6 @@
135 135
136 .choose_tovar{ 136 .choose_tovar{
137 width: 750px!important; 137 width: 750px!important;
138 - border-bottom: none!important;  
139 margin-left:-36px; 138 margin-left:-36px;
140 } 139 }
141 #notepad .tab-content_header{ 140 #notepad .tab-content_header{
@@ -219,11 +218,6 @@ cursor: pointer; @@ -219,11 +218,6 @@ cursor: pointer;
219 margin-right:69px; 218 margin-right:69px;
220 } 219 }
221 220
222 -.vin{  
223 - border-bottom: none!important;  
224 -}  
225 -  
226 -  
227 .search_input { 221 .search_input {
228 background-color: #7b91bd; 222 background-color: #7b91bd;
229 width: 286px; 223 width: 286px;
frontend/web/css/style/news_all.css
@@ -2,13 +2,6 @@ p, a, label, span{ @@ -2,13 +2,6 @@ p, a, label, span{
2 font-family: "Ubuntu" 2 font-family: "Ubuntu"
3 } 3 }
4 4
5 -.vin {  
6 - margin-bottom: 19px!important;  
7 - width: 960px;  
8 - margin: 34px auto;  
9 - border-bottom: 1px solid #dfdfdf;  
10 -  
11 -}  
12 5
13 .navigation:hover { 6 .navigation:hover {
14 color: #879cc3; 7 color: #879cc3;
@@ -27,11 +20,6 @@ p, a, label, span{ @@ -27,11 +20,6 @@ p, a, label, span{
27 padding-bottom: 1px; 20 padding-bottom: 1px;
28 } 21 }
29 22
30 -.vin_article {  
31 - font-size: 22px;  
32 - font-weight: 500;  
33 - margin-top: 22px;  
34 -}  
35 23
36 .choose_tovar{ 24 .choose_tovar{
37 width: 960px; 25 width: 960px;
frontend/web/css/style/notepad.css
1 -.vin {  
2 - margin-bottom: 19px!important;  
3 - width: 960px;  
4 - margin: 34px auto;  
5 - border-bottom: 1px solid #dfdfdf;  
6 -  
7 -}  
8 1
9 .navigation:hover { 2 .navigation:hover {
10 color: #879cc3; 3 color: #879cc3;
@@ -23,16 +16,11 @@ @@ -23,16 +16,11 @@
23 padding-bottom: 1px; 16 padding-bottom: 1px;
24 } 17 }
25 18
26 -.vin_article {  
27 - font-size: 22px;  
28 - font-weight: 500;  
29 - margin-top: 22px;  
30 -} 19 +
31 20
32 .choose_tovar{ 21 .choose_tovar{
33 width: 960px; 22 width: 960px;
34 margin: 20px auto; 23 margin: 20px auto;
35 - border-bottom:1px solid #dfdfdf;  
36 padding-bottom: 32px; 24 padding-bottom: 32px;
37 } 25 }
38 26
frontend/web/css/style/optovikam.css
1 -.vin {  
2 - margin-bottom: 19px!important;  
3 - width: 960px;  
4 - margin: 34px auto;  
5 - border-bottom: 1px solid #dfdfdf;  
6 -  
7 -}  
8 1
9 .navigation:hover { 2 .navigation:hover {
10 color: #879cc3; 3 color: #879cc3;
@@ -23,16 +16,10 @@ @@ -23,16 +16,10 @@
23 padding-bottom: 1px; 16 padding-bottom: 1px;
24 } 17 }
25 18
26 -.vin_article {  
27 - font-size: 22px;  
28 - font-weight: 500;  
29 - margin-top: 22px;  
30 -}  
31 19
32 .choose_tovar{ 20 .choose_tovar{
33 width: 960px; 21 width: 960px;
34 margin: 20px auto; 22 margin: 20px auto;
35 - border-bottom:1px solid #dfdfdf;  
36 } 23 }
37 .choose_tovar-list{ 24 .choose_tovar-list{
38 margin-bottom: 27px; 25 margin-bottom: 27px;
frontend/web/css/style/thanks.css
@@ -2,14 +2,6 @@ p, a, label, span{ @@ -2,14 +2,6 @@ p, a, label, span{
2 font-family: "Ubuntu" 2 font-family: "Ubuntu"
3 } 3 }
4 4
5 -.vin {  
6 - margin-bottom: 19px!important;  
7 - width: 960px;  
8 - margin: 34px auto;  
9 - border-bottom: 1px solid #dfdfdf;  
10 -  
11 -}  
12 -  
13 .navigation:hover { 5 .navigation:hover {
14 color: #879cc3; 6 color: #879cc3;
15 } 7 }
@@ -27,11 +19,6 @@ p, a, label, span{ @@ -27,11 +19,6 @@ p, a, label, span{
27 padding-bottom: 1px; 19 padding-bottom: 1px;
28 } 20 }
29 21
30 -.vin_article {  
31 - font-size: 22px;  
32 - font-weight: 500;  
33 - margin-top: 22px;  
34 -}  
35 22
36 .choose_tovar{ 23 .choose_tovar{
37 width: 920px; 24 width: 920px;
frontend/web/css/style_vin.css
1 1
2 -.vin{  
3 - width: 960px;  
4 - margin: 34px auto;  
5 -}  
6 -  
7 .vin img{ 2 .vin img{
8 margin-bottom: 1px; 3 margin-bottom: 1px;
9 } 4 }
@@ -12,11 +7,6 @@ @@ -12,11 +7,6 @@
12 text-decoration: underline; 7 text-decoration: underline;
13 } 8 }
14 9
15 -.vin_article {  
16 - font-size: 22px;  
17 - font-weight: 500;  
18 - margin-top: 22px;  
19 -}  
20 .line{ 10 .line{
21 margin-bottom: 12px; 11 margin-bottom: 12px;
22 } 12 }
frontend/web/js/main.js 0 → 100644
  1 +/**
  2 + * Created by vitaliy on 23.11.15.
  3 + */
  4 +$(document).ready(function(){
  5 + $('#accountsform-country').change(function(){
  6 + var region_id = $(this).val();
  7 + if(region_id){
  8 + $.get( "/ajax/get-city", {region_id:region_id}, function( data ) {
  9 + var $input = $('#accountsform-city');
  10 + $input.empty();
  11 + $input.append(data);
  12 + });
  13 + }
  14 + });
  15 +
  16 + $('#company').click(function(){
  17 +
  18 + $(this).addClass('active_button');
  19 + $('#person').removeClass('active_button');
  20 +
  21 + $('#accountsform-company').attr('type', 'text').attr('placeholder', 'Компания').val('');
  22 + $('.field-accountsform-company').css('display','block');
  23 + $('#accountsform-is_firm').val('1');
  24 +
  25 + });
  26 +
  27 + $('#person').click(function(){
  28 + $('#company').removeClass('active_button');
  29 + $(this).addClass('active_button');
  30 +
  31 + $('.field-accountsform-company').css('display','none');
  32 + $('#accountsform-company').attr('type', 'hidden').val('Частное лицо');
  33 + $('#accountsform-is_firm').val('0');
  34 +
  35 +
  36 + });
  37 +
  38 +});
0 \ No newline at end of file 39 \ No newline at end of file
frontend/web/js/script.js
@@ -271,21 +271,7 @@ $(&#39;.phone_control, .phone_placeholder&#39;).click( @@ -271,21 +271,7 @@ $(&#39;.phone_control, .phone_placeholder&#39;).click(
271 $('.input1').css({display:'block'}); 271 $('.input1').css({display:'block'});
272 $(this).css({display:'none'}); 272 $(this).css({display:'none'});
273 }); 273 });
274 - $('#company').click(function(){  
275 - $('.registration_for_person').css({display:'none'});  
276 - $('.registration_for_company').fadeIn(200).css({display:'block'});  
277 - $(this).addClass('active_button');  
278 - $('#person').removeClass('active_button');  
279 -  
280 - });  
281 - $('#person').click(function(){  
282 - $('#company').removeClass('active_button');  
283 - $('.registration_for_company').css({display:'none'});  
284 - $('.registration_for_person').fadeIn(200).css({display:'block'});  
285 - $(this).addClass('active_button');  
286 -  
287 -  
288 - }); 274 +
289 275
290 276
291 277
@@ -813,11 +799,7 @@ $(document).ready(function(){ @@ -813,11 +799,7 @@ $(document).ready(function(){
813 $('.menu_search_down').animate({height:'400px'}, 600, function(){}) 799 $('.menu_search_down').animate({height:'400px'}, 600, function(){})
814 800
815 }); 801 });
816 -});  
817 -  
818 -  
819 802
820 -$(document).ready(function(){  
821 $('html,body').click(function(){ 803 $('html,body').click(function(){
822 $('.phone_placeholder').removeClass('active_placeholder'); 804 $('.phone_placeholder').removeClass('active_placeholder');
823 $('.status').css({display:'none'}) 805 $('.status').css({display:'none'})
@@ -828,35 +810,30 @@ $(document).ready(function(){ @@ -828,35 +810,30 @@ $(document).ready(function(){
828 // Do something 810 // Do something
829 }); 811 });
830 812
831 - $( ".statusp" ).click(function( event ) {  
832 - event.stopPropagation();  
833 - // Do something  
834 - });  
835 -});  
836 813
837 - $(document).ready(function () {  
838 - $('input,textarea').focus(function(){  
839 - $(this).data('placeholder',$(this).attr('placeholder'))  
840 - $(this).attr('placeholder','');  
841 - });  
842 - $('input,textarea').blur(function(){  
843 - $(this).attr('placeholder',$(this).data('placeholder'));  
844 - });  
845 814
  815 + $('input,textarea').focus(function(){
  816 + $(this).data('placeholder',$(this).attr('placeholder'))
  817 + $(this).attr('placeholder','');
  818 + });
  819 + $('input,textarea').blur(function(){
  820 + $(this).attr('placeholder',$(this).data('placeholder'));
  821 + });
846 822
847 - $('.own_page3').click(function(){  
848 - $('#modal_form').css({'opacity': '0',  
849 - 'top': '45%',  
850 - 'display': 'none'});  
851 - $('#overlay').css({display:'none'})  
852 - });  
853 823
854 - $("#get_user_number").click(function(){  
855 - var inputdata = $("#get_telephone").val();  
856 - if(inputdata != ''){  
857 - $(".telephone_registration").val(inputdata);;  
858 - }  
859 -}); 824 + $('.own_page3').click(function(){
  825 + $('#modal_form').css({'opacity': '0',
  826 + 'top': '45%',
  827 + 'display': 'none'});
  828 + $('#overlay').css({display:'none'})
  829 + });
  830 +
  831 + $("#get_user_number").click(function(){
  832 + var inputdata = $("#get_telephone").val();
  833 + if(inputdata != ''){
  834 + $(".telephone_registration").val(inputdata);;
  835 + }
  836 + });
860 837
861 838
862 $('#go_project').click(function(){ 839 $('#go_project').click(function(){
@@ -874,13 +851,11 @@ $(document).ready(function(){ @@ -874,13 +851,11 @@ $(document).ready(function(){
874 // $('.menu_block_center1 .menu_search_down .input_search').find('input').css({display:'none'}) 851 // $('.menu_block_center1 .menu_search_down .input_search').find('input').css({display:'none'})
875 // }); 852 // });
876 853
877 -});  
878 -  
879 854
880 -$(document).ready(function(){  
881 $('#footer_third').find('a').attr('rel','external'); 855 $('#footer_third').find('a').attr('rel','external');
882 856
883 - $('.statusp').click(function(){ 857 + $('.statusp').click(function(event){
  858 + event.stopPropagation();
884 if( $(".status").css('display') == 'none'){ 859 if( $(".status").css('display') == 'none'){
885 $('.status').css({display:'block'}); 860 $('.status').css({display:'block'});
886 } 861 }
storage/c24c6caa693896710ec7a0934a911214/200x200.png

157 KB | W: | H:

73.8 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin
storage/dbd5c1a08753ca919151c7ac628e7df3/200x200.png deleted

334 KB

storage/dbd5c1a08753ca919151c7ac628e7df3/x.png deleted

334 KB