高校页面代码优化:1、中文国际化。2、写死的链接改为从配置中读取
This commit is contained in:
parent
d1a84305da
commit
e83ebedd00
|
@ -3,10 +3,6 @@
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
$(document).ready(function() {
|
$(document).ready(function() {
|
||||||
$("#province").html("<option value='0' selected = true style='display: none;'></option>");
|
$("#province").html("<option value='0' selected = true style='display: none;'></option>");
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
$.ajax({
|
$.ajax({
|
||||||
type :"POST",
|
type :"POST",
|
||||||
url :'/school/get_province',
|
url :'/school/get_province',
|
||||||
|
@ -43,7 +39,7 @@
|
||||||
|
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
function test(id){
|
function test(id){
|
||||||
location.href = encodeURI('http://course.trustie.net/?school_id='+id);
|
location.href = encodeURI('http://<%= Setting.host_course %>/?school_id='+id);
|
||||||
}
|
}
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
@ -55,7 +51,7 @@
|
||||||
//alert(value);
|
//alert(value);
|
||||||
if(value == "")
|
if(value == "")
|
||||||
{
|
{
|
||||||
alert("搜索条件不能为空");
|
alert("<%= l(:label_search_conditions_not_null) %>");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
//alert(province);
|
//alert(province);
|
||||||
|
@ -82,17 +78,17 @@
|
||||||
<div>
|
<div>
|
||||||
<p>
|
<p>
|
||||||
|
|
||||||
<%= link_to "全部学校",school_index_path %>
|
<%= link_to l(:label_all_schol),school_index_path %>
|
||||||
<% if User.current.logged? %>
|
<% if User.current.logged? %>
|
||||||
<a href="http://course.trustie.net">我的学校</a>
|
<a href="http://<%= Setting.host_course %>"><%= l(:label_my_school) %></a>
|
||||||
<% end %>
|
<% end %>
|
||||||
</p>
|
</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li style="width: 40%; float: left">请选择省份:
|
<li style="width: 40%; float: left"><%= l(:label_select_province) %>:
|
||||||
<select id="province" name="province" onchange="get_school(this.value)"></select>
|
<select id="province" name="province" onchange="get_school(this.value)"></select>
|
||||||
</li>
|
</li>
|
||||||
<li style="width: 50%; float: left"><input type="text" id="key_word" name="key_word" onkeydown="word_keydown(event);"/>
|
<li style="width: 50%; float: left"><input type="text" id="key_word" name="key_word" onkeydown="word_keydown(event);"/>
|
||||||
<input type="button" class="enterprise" value="搜索" onclick="ssearch()"></li>
|
<input type="button" class="enterprise" value="<%= l(:label_search) %>" onclick="ssearch()"></li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -1816,5 +1816,9 @@ en:
|
||||||
label_forums_max_length: Post Bar describing the maximum length of 65535 characters
|
label_forums_max_length: Post Bar describing the maximum length of 65535 characters
|
||||||
label_unknow_type: Unknow type
|
label_unknow_type: Unknow type
|
||||||
label_score_less_than_zero: Score less than 0, revised to 0
|
label_score_less_than_zero: Score less than 0, revised to 0
|
||||||
review_assignments: review assignments
|
review_assignments: Review assignments
|
||||||
label_private: private
|
label_private: private
|
||||||
|
label_my_school: My school
|
||||||
|
label_all_schol: All school
|
||||||
|
label_select_province: Please select the provinces
|
||||||
|
label_search_conditions_not_null: The search conditions can not be empty
|
|
@ -2119,3 +2119,7 @@ zh:
|
||||||
label_score_less_than_zero: 得分小于0,修正为0
|
label_score_less_than_zero: 得分小于0,修正为0
|
||||||
review_assignments: 评审任务
|
review_assignments: 评审任务
|
||||||
label_private: 私有
|
label_private: 私有
|
||||||
|
label_my_school: 我的学校
|
||||||
|
label_all_schol: 全部学校
|
||||||
|
label_select_province: 请选择省份
|
||||||
|
label_search_conditions_not_null: 搜索条件不能为空
|
Loading…
Reference in New Issue