2英尺之间的离子切换

时间:2016-10-19 02:01:00

标签: angularjs ionic-framework footer

我在页脚中有这个:

<div class="bar bar-footer bar-assertive" ng-show="withdarawStatus">
    <button class="button button-assertive" id="applyButton" ng-click="withdraw()">
        Successfully Applied! Withdraw? 
    </button>
</div>    

<div class="bar bar-footer bar-positive" ng-show="!withdarawStatus" >
    <p id="applyButton" >Application Withdrawn</p>
</div>

我想写一个函数,当我点击withdraw()时,页脚会变为“Application Withdraw”页脚。

我尝试了这个,但它没有用,除非我重新加载整个页面。

$scope.withdraw = function() {
    $scope.withdrawStatus = true;
}

1 个答案:

答案 0 :(得分:1)

您的HTML ng-show="!withdarawStatus"中的拼写错误应为ng-show="!withdrawStatus"。这应该可以解决问题。

编辑:这是一个有效的codepen