fix error
This commit is contained in:
parent
1142ed9ab4
commit
ffff41153c
|
@ -5,6 +5,7 @@ class AsksController < ApplicationController
|
|||
include ActionView::Helpers::FormOptionsHelper
|
||||
helper ActionView::Helpers::UrlHelper
|
||||
include ActionController::RequestForgeryProtection
|
||||
include RuCaptcha::ViewHelpers
|
||||
def widget
|
||||
subpart = OrbitHelper.get_current_widget
|
||||
case subpart.widget_type
|
||||
|
@ -89,6 +90,7 @@ class AsksController < ApplicationController
|
|||
def initialize
|
||||
super
|
||||
@app_title = 'ask'
|
||||
self.request = OrbitHelper.request
|
||||
end
|
||||
def show
|
||||
ask_question = AskQuestion.where(id: @params['item']).first
|
||||
|
@ -307,7 +309,7 @@ class AsksController < ApplicationController
|
|||
when 'appointment'
|
||||
f1['content'] = "<div class=\"default_picker\">#{text_field_tag(field_name,nil,placeholder:@default_ask_setting.field_name("#{field}"))}</div>"
|
||||
when 'recaptcha'
|
||||
f1['content'] = "{{gotcha_error}}{{gotcha}}"
|
||||
f1['content'] = "#{gotcha_error}#{gotcha}"
|
||||
when 'usage_rule'
|
||||
next if ask_setting.usage_rule.blank?
|
||||
f1['content'] = ask_setting.usage_rule
|
||||
|
|
|
@ -99,11 +99,7 @@
|
|||
<%= javascript_include_tag 'validator' %>
|
||||
<link href="/assets/ask/ask.css" media="screen" rel="stylesheet">
|
||||
<div id="new-ask-question" class="ask-question">
|
||||
<%
|
||||
tmp_gotcha_error = gotcha_error
|
||||
tmp_gotcha = gotcha
|
||||
%>
|
||||
<%= @switch_form.gsub("{{gotcha_error}}",tmp_gotcha_error).gsub("{{gotcha}}",tmp_gotcha).html_safe %>
|
||||
<%= @switch_form.html_safe %>
|
||||
</div>
|
||||
|
||||
<script type='text/javascript'>
|
||||
|
|
Loading…
Reference in New Issue