seminar/app/views/seminars/con_login.html.erb

61 lines
2.3 KiB
Plaintext
Raw Normal View History

2016-06-29 06:57:45 +00:00
<% # encoding: utf-8 %>
<%
data = action_data
@seminar = data["seminar"]
@time_now = data["time_now"]
%>
2022-10-22 10:43:36 +00:00
<style type="text/css">
.alert-error{
color: red;
}
</style>
2021-07-14 04:57:47 +00:00
<% if (@seminar.contribute_start_date <= @time_now && (@seminar.contribute_end_date.nil? or @seminar.contribute_end_date+1 >= @time_now ) rescue false) %>
2016-06-29 06:57:45 +00:00
<section id="main-wrap">
<div class="sign-in have-other-sign-in">
<% flash.each do |key, msg| %>
<%= content_tag :p, msg, :class => [key, "alert alert-error in fade"] %>
<% end %>
<div class="form">
<h2><%= @seminar.title %></h2>
<h3 class="login-logo"><%= t('seminar_signup.con_login') %></h3>
<div>
<input name="utf8" type="hidden" value="" />
<input name="authenticity_token" type="hidden" value="" />
</div>
<div class="form-block">
<div class="form-list clearfix">
<%= form_tag con_login_proc_seminars_path, :class => 'content' do %>
<div class="control-group clear">
<label for="user_email">
<i class="icon-user"></i><%=t('seminar_signup.email_address')%>
2016-06-29 06:57:45 +00:00
</label>
<%= text_field_tag :user_name, params[:user_name], :placeholder => t('seminar_signup.email_address'), :id=>"user_email" %>
2016-06-29 06:57:45 +00:00
</div>
<div class="control-group clear">
<label for="user_password">
<i class="icon-lock"></i><%=t("seminar_signup._password")%>
2016-06-29 06:57:45 +00:00
</label>
<%= password_field_tag :password, nil, :placeholder => t(:dots), :id=>"user_password" %>
</div>
<br/>
<input type="hidden" name="referer_url" value="<%= request.original_url.split(request.env["HTTP_HOST"]).last.split('?').first %>">
<input type="hidden" name="seminar_signup[seminar_main_id]" value="<%= @seminar.id %>">
<button class="btn btn-primary" name="button" type="submit"><%= t('seminar_signup.login') %></button>
2016-06-29 06:57:45 +00:00
<% end %>
</div>
</div>
<br/>
</div>
</div>
</section>
<% else %>
2021-07-14 04:57:47 +00:00
<%= t("seminar.out_of_date") %>
<% end %>
<script type="text/javascript">
$(document).ready(function(){
var max_width = Math.max.apply(null, $(".form .control-group label").map(function(i,el){return $(el).width()}));
$(".form .control-group label").width(max_width);
})
</script>