portainer/app/helpers/volumeHelper.js

16 lines
351 B
JavaScript

angular.module('portainer.helpers')
.factory('VolumeHelper', [function VolumeHelperFactory() {
'use strict';
var helper = {};
helper.createDriverOptions = function(optionArray) {
var options = {};
optionArray.forEach(function (option) {
options[option.name] = option.value;
});
return options;
};
return helper;
}]);