Commit b70239a0d0d3ea21e255c83b1762620625be8cfe

Authored by Виталий
1 parent 71e78660

tokar commit

frontend/controllers/SiteController.php
@@ -99,11 +99,6 @@ class SiteController extends Controller @@ -99,11 +99,6 @@ class SiteController extends Controller
99 return $this->renderAjax('forms-modal-fav', []); 99 return $this->renderAjax('forms-modal-fav', []);
100 } 100 }
101 101
102 - public function actionFormsModalHelp()  
103 - {  
104 - return $this->renderAjax('forms-modal-help', []);  
105 - }  
106 -  
107 public function actionFormsModalOffer() 102 public function actionFormsModalOffer()
108 { 103 {
109 return $this->renderAjax('forms-modal-offer', []); 104 return $this->renderAjax('forms-modal-offer', []);
frontend/views/site/forms-modal-contacts.php
1 -<script>alert('no-contacts')</script>  
2 \ No newline at end of file 1 \ No newline at end of file
  2 +<div id="modal_form_question">
  3 + <div class="closed-form"></div>
  4 + <div class="form-resume-wr question">
  5 + <div class="form-resume-sub style">Задать вопрос МФП(контакты)</div>
  6 + <form action="" class="question-project">
  7 + <label for="qst_name">Ваши имя и фамилия</label><input id="qst_name" name="" type="text">
  8 +
  9 + <label for="qst_phone">Контактный телефон</label><input id="qst_phone" name="" type="text">
  10 +
  11 + <label for="qst_text">Вопрос</label><textarea id="qst_text" name=""></textarea>
  12 +
  13 + <input id="qst_submit" type="submit" value="Отправить">
  14 + </form>
  15 + <div class="res_form_line"></div>
  16 + </div>
  17 +</div>
3 \ No newline at end of file 18 \ No newline at end of file
frontend/views/site/forms-modal-help.php
1 <div id="modal_form_question"> 1 <div id="modal_form_question">
2 - <div class="closed-form"></div>  
3 - <div class="form-resume-wr question">  
4 - <div class="form-resume-sub style">Задать вопрос МФП</div>  
5 - <form action="" class="question-project">  
6 - <label for="qst_name">Ваши имя и фамилия</label><input id="qst_name" name="" type="text">  
7 -  
8 - <label for="qst_phone">Контактный телефон</label><input id="qst_phone" name="" type="text">  
9 -  
10 - <label for="qst_text">Вопрос</label><textarea id="qst_text" name=""></textarea>  
11 -  
12 - <input id="qst_submit" type="submit" value="Отправить">  
13 - </form>  
14 - <div class="res_form_line"></div>  
15 - </div> 2 + пусто
16 </div> 3 </div>
17 \ No newline at end of file 4 \ No newline at end of file
frontend/web/js/forms.js
@@ -67,8 +67,8 @@ $(document).ready(function(){ @@ -67,8 +67,8 @@ $(document).ready(function(){
67 67
68 68
69 69
70 - function addQuestions() {  
71 - $.post("site/forms-modal-help", function (data) { 70 + function addContacts() {
  71 + $.post("/site/forms-modal-contacts", function (data) {
72 $('.forms-modal-hide').append(data) 72 $('.forms-modal-hide').append(data)
73 }) 73 })
74 .fail(function(){ 74 .fail(function(){
@@ -87,10 +87,10 @@ $(document).ready(function(){ @@ -87,10 +87,10 @@ $(document).ready(function(){
87 } 87 }
88 88
89 89
90 - $('a.contactsLinkModal').click(function(e){ 90 + $('a.contactsLinkModalFirst').click(function(e){
91 e.preventDefault() 91 e.preventDefault()
92 addRemoveBlocks() 92 addRemoveBlocks()
93 - addQuestions(); 93 + addContacts();
94 }) 94 })
95 95
96 clocseModalForms() 96 clocseModalForms()