I want to access object value(i.e rulenames-decline,postpone,warning...) in checkbox, using ng-repeat and also display checkbox as checked when value in object is 'Y' and unchecked when value is 'N'
<div class="form-group">
<label class="checkbox-inline" ng-repeat="rules in savedRulesData ">
<input type="checkbox" id="checkBoxed" value="">
</label>
</div>
Currently my checkbox is displayed as illustrated in image.
I open this model using editRules Function in my controller
[http://ift.tt/2qbfV3R] Image link
$scope.editRules = function(ruleTypes,client) {
var obj=new Object();
var self=this;
var clientId=client.clientId;
var responsePromise = $http.get("typesofSavedRules/"+clientId);
responsePromise.success(function(data, status, headers, config) {
self.savedRulesData=data.objList;
$scope.savedRulesData=self.savedRulesData;
});
responsePromise.error(function(data, status, headers, config) {
alert("AJAX failed!");
});
modalInstance = $modal.open({
templateUrl: 'myModalContent.html',
scope: $scope,
size:'lg'
});
};
Aucun commentaire:
Enregistrer un commentaire