Quantcast
Channel: Ionic Framework - Ionic Forum
Viewing all articles
Browse latest Browse all 49220

ngClick never works with ionic

$
0
0

@dfghj44444 wrote:

this is whole of the html:
<ion-view title="recor">
<ion-content overflow-scroll="true" padding="true" class="has-header">
<button type="button" class="button" ng-click="recordNew()" >test</button>
<button id="page9-button4" type="button" class="button button-stable button-block" ng-click="recordNew()" >complete完成</button>
</ion-content>
</ion-view>

the botton is in tyep button and not inside label,but just dont work,and here's the js in controller.js:

.controller('NewScoreCtrl', function($scope) {
    $scope.recordNew = function() {
             //   console.log("拨打:");
            alert("2");
            //$scope.tab = item;
            //Your other logic for soothe
            }
})

no erros or ouptut

Posts: 2

Participants: 1

Read full topic


Viewing all articles
Browse latest Browse all 49220

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>