AngularJS Select默认值??

AngularJS Select绑定的是对象:

$scope.cars = { car01 : {brand : "Ford", model : "Mustang", color : "red"}, car02 : {brand : "Fiat", model : "500", color : "white"}, car03 : {brand : "Volvo", model : "XC90", color : "black"} };

<select ng-model<爱尬聊_让生活聊出新高度>="selectedCar" ng-options="y.brand for (x, y) in cars"></select>

现在想给select一个默认值怎么设置呢?


Dark0613 19小时前

<option>--please select--</option>


编辑 举报 2023-04-10 12:15

0个评论

暂无评论...
验证码 换一张
相关内容