工作总结 下拉单选 下拉多选

<tr>
                                <th>
                                    @LangResources.Resource.City:
                                </th>
                                <td>
                                    <select id="citysel" name="citysel" style="width:150px;height:30px;">
                                        <option value="">@LangResources.Resource.Info_All</option>
                                        @foreach (SelectListItem item in ViewBag.cityList)
                                        {
                                            <option value="@item.Value">@item.Text</option>
                                        }
                                    </select>
                                </td>
                                <th style="width:100px;">
                                    @LangResources.Resource.PictureQuery_JobDate:
                                </th>
                                <td>
                                    <table>
                                        <tr>
                                            <td style="border-bottom: 0px solid #e6e6e6;">
                                                <div class="input-group date" style="width:150px;">
                                                    <span class="input-group-addon"><i class="fa fa-calendar"></i></span>
                                                    <input id="startdate" name="" value="@ViewBag.Date" type="text" class="form-control">
                                                </div>
                                            </td>
                                        </tr>
                                    </table>
                                </td>
                                <th>
                                    @LangResources.Resource.AtmCustomer:
                                </th>
                                <td>
                                    <select id="Cartype" class="chosen-select" name="Cartype" multiple="multiple" style="width:150px;height:30px;">
                                        @foreach (SelectListItem item in ViewBag.Type)
                                        {
                                            <option value="@item.Value">@item.Text</option>
                                        }
                                    </select>
                                </td>
                                @*<th>@LangResources.Resource.bank</th>
                                    <td>
                                        <select id="Textkh" class="form-control" style="width:150px;height:30px;"></select>
                                    </td>*@
                            </tr>

 

$("#citysel").chosen(); 

下拉单选

 

<td>
                                    <select id="Cartype" class="chosen-select" name="Cartype" multiple="multiple" style="width:150px;height:30px;">
                                        @foreach (SelectListItem item in ViewBag.Type)
                                        {
                                            <option value="@item.Value">@item.Text</option>
                                        }
                                    </select>
                                </td>

$("#Cartype").attr("data-placeholder", "ALL");
$("#Cartype").chosen();

下拉多选

 

posted @ 2018-07-19 15:13  ~雨落忧伤~  阅读(58)  评论(0编辑  收藏  举报