zoukankan      html  css  js  c++  java
  • angular下拉

    <div class="form-group col-sm-4">
    <label class="col-sm-5 control-label"><b class="text-danger"></b> 合同状态: </label>
    <div class="col-sm-7">
    <input type="hidden" name="contractStatus" id="contractStatus" value="$!contractDTO.contractStatus"/>
    <div class="demo-con" ng-controller="selectController">
    <ui-select ng-model="data.cuyStatusId" theme="select2" search-enabled="false" style="100%">
    <ui-select-match placeholder="请选择" style="padding:0 0 0 10px">{{$select.selected.name}}
    <input type="hidden" name="conStatus" id="conStatus" value="{{$select.selected.id}}"/>
    </ui-select-match>
    <ui-select-choices repeat="item.id as item in cuyType | filter: $select.search" onclick="getStuts();">
    <div ng-bind-html="item.name | highlight: $select.search"></div>
    </ui-select-choices>
    </ui-select>
    </div>
    </div>
    </div>

    angular.module('SelectApp', ['ngSanitize','ui.select'])
    .controller('selectController', ['$scope', function ($scope) {
    $scope.data= {
    cuyStatusId: '$!contractStatus'
    } ;
    // $scope.business = '';
    $scope.cuyType = [
    // {name: '起草中', id: '0'},
    {name: '审批中', id: '1'},
    {name: '待用印', id: '2'},
    {name: '待归档', id: '3'},
    {name: '已归档', id: '4'}
    ]
    }]);
    angular.bootstrap(document, ['SelectApp']);

  • 相关阅读:
    4月24日 PHP基础
    4月22日 常用函数
    4月22日 练习题
    PHP正则数组
    PHP基础函数应用
    数据库SQL语句
    高级查询
    mysql
    CSS样式表
    词汇
  • 原文地址:https://www.cnblogs.com/whb11/p/6243953.html
Copyright © 2011-2022 走看看