This commit is contained in:
caishi 2018-02-07 17:26:09 +08:00
parent 65e2433592
commit 4645bddd1c
4 changed files with 36 additions and 3409 deletions

View File

@ -15,6 +15,7 @@
<div class="field line_field">
<label><span>*</span>数据名称:</label>
<%= f.text_field :name, :class => "wb85" %>
<p class="cl" style="padding-left: 10%;color: red;height: 20px"><span id="input_name_notice" class="none">请输入数据名称</span></p>
</div>
<div class="field line_field">
<label><span>*</span>数据分类:</label>
@ -34,6 +35,7 @@
<!--</ul>-->
<!--</div>-->
<p class="cl" style="padding-left: 10%;color: red;height: 20px"><span id="input_cate_notice" class="none">请选择数据分类</span></p>
</div>
<div class="field line_field">
<label>数据描述:</label>
@ -60,15 +62,29 @@
</div>
<div class="actions cl mb20">
<%#= f.submit %>
<a class="blue_btn_big c_white fr mr45" onclick="$('#create_new_statis').submit()">保存</a>
<a href="javascript:void(0)" class="blue_btn_big c_white fr mr45" onclick="submit_cate();">保存</a>
<!--<input type="submit" class="blue_btn_big c_white fr mr45" value="保存" onclick="$('#create_new_statis').submit()"/>-->
<%= link_to '取消', statistics_path ,:class=>"grey_btn_big fr c_white mr10" %>
</div>
<% end %>
</div>
<script>
function submit_cate(){
var name=$("#statistic_name").val();
var cate=$("#statistic_main_category_id option:selected").text();
if(name == ""){
$("#input_name_notice").removeClass("none");
return;
}
if(cate == ""){
$("#input_cate_notice").removeClass("none");
return;
}
$("#new_statistic").submit();
}
// 获取子类别
function get_sub_category(id) {
function get_sub_category(id){
alert(id);
$.ajax({
url: <%= get_sub_category_statistics_path %>,

File diff suppressed because it is too large Load Diff

View File

@ -954,7 +954,7 @@ a.syllabusbox_a_blue{ color:#3b94d6;}
#create_new_statis form div.field{clear: both;zoom: 1;}
#create_new_statis form label{float: left;width: 10%;text-align: center;font-size: 14px;height: 35px;line-height: 35px;}
#create_new_statis form label span{color: red}
#create_new_statis .line_field input,#create_new_statis .line_field select{float: left;height: 35px;line-height: 35px;border-radius: 4px;margin-bottom: 15px;}
#create_new_statis .line_field input,#create_new_statis .line_field select{float: left;height: 35px;line-height: 35px;border-radius: 4px;}
.input_tag{height: 30px!important;border-radius: 3px!important;width: 160px}
.tag_modal span{display: inline-block;border-radius: 3px;border:1px solid #dddddd;background: #FFFFFF;padding: 3px 7px;margin-right: 5px ;margin-top: 3px}
.tag_del{cursor: pointer}
@ -988,4 +988,14 @@ a.syllabusbox_a_blue{ color:#3b94d6;}
.data_info span:nth-child(2){width:26% }
span.down{display: block;position: absolute;top: 13px;right: 4px;width: 12px;height: 10px;background: url(/images/user/icons_user_leftnav.png) -3px -347px no-repeat;}
.submit_btn{padding-bottom: 5px;
width: 50px;box-sizing: border-box;
height: 30px;
font-family: '微软雅黑',Arial,Helvetica,sans-serif;
font-size: 12px;
color: #fff;
padding: 3px 9px;
background: #269ac9;
border-radius: 4px;
border: 1px solid #269ac9;color: #fff!important;align-items: flex-start;
cursor: pointer;}

View File

@ -280,7 +280,6 @@ a:hover.blue_btn{ background:#329cbd;}
a.orange_btn{ background:#ff5722;color:#fff; font-weight:normal; padding:2px 10px; text-align:center; }
a:hover.orange_btn{ background:#d63502;}
.blue_btn_big{ background:#64bdd9; color:#fff; font-weight:normal;padding:5px 8px; text-align:center;}
.green_u_btn{border:1px solid #3cb761; padding:2px 10px; color:#3cb761;}
a.green_u_btn{border:1px solid #3cb761; padding:2px 10px; color:#3cb761;}
a:hover.green_u_btn{ background:#3cb761; color:#fff;}