@ -12,8 +12,6 @@
);
);
</script>
</script>
<script type="text/javascript">
<script type="text/javascript">
function get_options(value) {
function get_options(value) {
$.ajax({
$.ajax({
@ -21,17 +19,12 @@
url: '/school/get_options/' + encodeURIComponent(value),
url: '/school/get_options/' + encodeURIComponent(value),
data: 'text',
data: 'text',
success: function (data) {
success: function (data) {
$("#province").val(value)
$("#province").val(value)
$("#schoollist").html(data);
$("#schoollist").html(data);
}
}
});
});
}
}
</script>
</script>
<div class="contextual" style="padding-right: 10px;">
<div class="contextual" style="padding-right: 10px;">
<%= link_to(l(:button_change_password), {:action => 'password'}, :class => 'icon icon-passwd') if @user.change_password_allowed? %>
<%= link_to(l(:button_change_password), {:action => 'password'}, :class => 'icon icon-passwd') if @user.change_password_allowed? %>
<%= call_hook(:view_my_account_contextual, :user => @user) %>
<%= call_hook(:view_my_account_contextual, :user => @user) %>
@ -39,9 +32,7 @@
<h3 style="padding-left: 10px;"><%= l(:label_my_account) %></h3>
<h3 style="padding-left: 10px;"><%= l(:label_my_account) %></h3>
<%= error_messages_for 'user' %>
<%= error_messages_for 'user' %>
<fieldset class="box" style="margin:10px;">
<fieldset class="box" style="margin:10px;">
<%= labelled_form_for :user, @user,
<%= labelled_form_for :user, @user,
:url => {:action => "account"},
:url => {:action => "account"},
:html => {:id => 'my_account_form',
:html => {:id => 'my_account_form',
@ -70,7 +61,6 @@
<div>
<div>
<span id='name' style='display:none'>
<span id='name' style='display:none'>
<p style="width:530px;padding-left: 26px;">
<p style="width:530px;padding-left: 26px;">
<%= f.text_field :lastname, :required => true %>
<%= f.text_field :lastname, :required => true %>
<span class='font_lighter'><%= l(:field_lastname_eg) %></span>
<span class='font_lighter'><%= l(:field_lastname_eg) %></span>
@ -82,7 +72,8 @@
</span>
</span>
<span id='enterprise' style='display:none'>
<span id='enterprise' style='display:none'>
<p style="width:400px;padding-left: 26px;"><%= l(:label_company_name)%><%= text_field_tag :enterprise_name, @user.firstname %>
<p style="width:400px;padding-left: 26px;">
<%= l(:label_company_name)%><%= text_field_tag :enterprise_name, @user.firstname %>
</p>
</p>
</span>
</span>
@ -107,12 +98,11 @@
<% end %>
<% end %>
<% end %>
<% end %>
</span>
</span>
<!-- added by Wen -->
<!-- added by Wen -->
<p style="padding-left: 26px;">
<p style="padding-left: 26px;">
<% if User.current.user_extensions.school.nil? %>
<% if User.current.user_extensions.school.nil? %>
<%= l(:field_occupation) %> <span class="required">*</span>
<%= l(:field_occupation) %>
<span class="required">*</span>
<input id="province" name="province" type="text" value="请单击选择省份及学校" readonly>
<input id="province" name="province" type="text" value="请单击选择省份及学校" readonly>
<input id="occupation" name="occupation" type="hidden"/>
<input id="occupation" name="occupation" type="hidden"/>
<input id="occupation_name" type="text" readonly/>
<input id="occupation_name" type="text" readonly/>
@ -126,8 +116,7 @@
<div id="WOpenWindow">
<div id="WOpenWindow">
<a class="modal_close" href="#"></a>
<a class="modal_close" href="#"></a>
<h2><%= l(:lable_school_list)%></h2>
<h2>学校列表</h2>
<div class="pcontent">
<div class="pcontent">
<ul id="provincelist" class="school_list">
<ul id="provincelist" class="school_list">
@ -255,7 +244,9 @@
<% end %>
<% end %>
<!-- end -->
<!-- end -->
</span>
</span>
</p>
<% else %>
<% else %>
<p>
<span style="display:none">
<span style="display:none">
<select onchange="showtechnical_title(this.value, document.getElementById('userTechnical_title'));" name="identity" id="userIdentity" class="location">
<select onchange="showtechnical_title(this.value, document.getElementById('userTechnical_title'));" name="identity" id="userIdentity" class="location">
<option value=""><%= l(:label_account_identity_choose) %></option>
<option value=""><%= l(:label_account_identity_choose) %></option>
@ -263,7 +254,6 @@
<option value="1"><%= l(:label_account_identity_student) %></option>
<option value="1"><%= l(:label_account_identity_student) %></option>
<option value="2"><%= l(:label_account_identity_enterprise) %></option>
<option value="2"><%= l(:label_account_identity_enterprise) %></option>
<option value="3"><%= l(:label_account_identity_developer) %></option>
<option value="3"><%= l(:label_account_identity_developer) %></option>
</select>
</select>
</span>
</span>
</p>
</p>