【发布时间】:2018-12-28 03:09:07
【问题描述】:
我有一个下拉声,我想检测到所有事件,即使它们是相同的,即使选择自定义时期,显示模态,但我需要用户能够通过他想要的所有次数使用这个模态,即使被选中,这里是代码:
<div class="form-group">
<select width="'100%'" ng-model="selection.date.mode"
class="form-control input-sm" ng-change="setDateMode()">
<option value="d" ng-show="visible.date.d" >Day</option>
<option value="w" ng-show="visible.date.d" >Week</option>
<option value="m" ng-show="visible.date.d" >Month</option>
<option value="y" ng-show="visible.date.d">Year to Date</option>
<option value="c" ng-show="visible.date.d" >Custom</option>
<option value="l" ng-show="visible.date.d" >Last 30 days</option>
</select>
AngularJS 函数:
function setDateMode() {
$scope.selection.date.mode === "c" ? clickCustomInput() : dateSelected();
}
【问题讨论】:
标签: html angularjs select dropdown