forked from Gitlink/forgeplus
增加导航条index的输入限制
This commit is contained in:
parent
19c8587723
commit
b080b8fca5
|
@ -1,7 +1,7 @@
|
|||
<tr>
|
||||
<td><%= text_field_tag('navbar[][name]', "", id: nil, class: 'form-control', placeholder: "导航名称") %></td>
|
||||
<td><%= text_field_tag('navbar[][link]', "", id: nil, class: 'form-control', placeholder: "导航链接") %></td>
|
||||
<td><%= number_field_tag('navbar[][index]', "", id: nil, class: 'form-control', placeholder: "顺序") %></td>
|
||||
<td><%= number_field_tag('navbar[][index]', "1", id: nil, class: 'form-control',min:0, max:99999, placeholder: "顺序", title:"请输入正整数 范围 0-99999", pattern:'^\d+')%></td>
|
||||
<td class="text-center">
|
||||
<%= check_box_tag('navbar[][hidden]', 0, false, id: nil, class: 'font-16') %>
|
||||
</td>
|
||||
|
|
|
@ -158,8 +158,8 @@
|
|||
<thead class="thead-light">
|
||||
<tr>
|
||||
<th width="30%">导航名称</th>
|
||||
<th width="50%">导航链接</th>
|
||||
<th width="5%">顺序</th>
|
||||
<th width="30%">导航链接</th>
|
||||
<th width="15%">顺序</th>
|
||||
<th width="5%" class="text-center">是否展示</th>
|
||||
<th width="10%" class="text-center">操作</th>
|
||||
</tr>
|
||||
|
@ -169,7 +169,7 @@
|
|||
<tr>
|
||||
<td><%= text_field_tag('navbar[][name]', nav['name'], id: nil, class: 'form-control') %></td>
|
||||
<td><%= text_field_tag('navbar[][link]', nav['link'], id: nil, class: 'form-control') %></td>
|
||||
<td><%= number_field_tag('navbar[][index]', nav['index'], id: nil, class: 'form-control') %></td>
|
||||
<td><%= number_field_tag('navbar[][index]', nav['index'].to_i, id: nil, class: 'form-control',min:0,max:99999, title:"请输入正整数 范围 0-99999", pattern:'^\d+')%></td>
|
||||
<td class="text-center">
|
||||
<%= check_box_tag('navbar[][hidden]', 0, !nav['hidden'], id: nil, class: 'font-16') %>
|
||||
</td>
|
||||
|
|
Loading…
Reference in New Issue