Sha256: 4bc8280940fc87e9cffc086dc742085dcd95180900852cd5648d1db8daea5d91
Contents?: true
Size: 696 Bytes
Versions: 5
Compression:
Stored size: 696 Bytes
Contents
angular.module('TryApi').directive 'paramsarray', [ '$filter' ($filter) -> link = (scope, element, attrs, ctrl) -> scope.parameter.values = [] scope.addItem = ()-> scope.parameter.values.push jQuery.extend(true, {}, scope.parameter.parameters) return { link: link restrict: 'A' require: 'ngModel' scope: parameter: '=ngModel' template: '' + '<div ng-repeat="value in parameter.values track by $index" style="border: 1px solid lightgray; margin: 1px 1px 1px 10px">' + ' <div params ng-model="value"></div>' + '</div>' + '<a class="btn btn-success btn-xs" ng-click="addItem()">+</a>' } ]
Version data entries
5 entries across 5 versions & 1 rubygems