29 lines
713 B
JavaScript
29 lines
713 B
JavaScript
// Generated by CoffeeScript 1.12.5
|
|
var businessDayComputations;
|
|
|
|
import Ember from 'ember';
|
|
|
|
import DS from 'ember-data';
|
|
|
|
businessDayComputations = function(target, prefix, options) {
|
|
if (options == null) {
|
|
options = {};
|
|
}
|
|
if (options.add_attributes) {
|
|
Ember.defineProperty(target, prefix + "_value", DS.attr('number', {
|
|
defaultValue: 0
|
|
}));
|
|
Ember.defineProperty(target, prefix + "_unit", DS.attr('string', {
|
|
defaultValue: options.default_unit || 'day'
|
|
}));
|
|
Ember.defineProperty(target, prefix + "_business_days", DS.attr({
|
|
defaultValue: function() {
|
|
return [1, 2, 3, 4, 5];
|
|
}
|
|
}));
|
|
}
|
|
return true;
|
|
};
|
|
|
|
export default businessDayComputations;
|