SmartIT_Extensions/BMC/smart-it-full-helix/scripts/app/change/change-wizard-tab-directive.js

31 lines
1.1 KiB
JavaScript

"use strict";
(function () {
'use strict';
angular.module('changeModule')
.directive('changeWizardTab', [
function () {
return {
restrict: 'E',
replace: true,
scope: {
tabid: '=',
title: '@',
icon: '@',
selectedtab: '=',
valid: '&'
},
templateUrl: 'views/change/change-wizard-tab.html',
controller: ['$scope', function ($scope) {
$scope.logInvalidFields = function () {
var arr = $('form[name=basics]').find('.ng-invalid').toArray();
console.log("Basic Form Invalid Fields ");
arr.forEach(function (field) {
console.log("Name: " + field.name + " ux-id: " + field.getAttribute('ux-id'));
});
};
}]
};
}
]);
})();