move dateRange from constants to utils

This commit is contained in:
anandsahil 2019-08-01 14:14:30 +02:00
parent 5ff3147124
commit aa761cf7ad
7 changed files with 23 additions and 18 deletions

View File

@ -10,22 +10,9 @@ const orderOperations = {
download: 'DOWNLOAD',
};
const dateRange = (start, end) => {
if (start && end)
return {
DateRange: {
Start: start,
End: end,
},
};
return {};
};
module.exports = {
name,
version,
orderOperations,
productString: `${name} ${version}`,
dateRange,
};

View File

@ -1,6 +1,6 @@
'use strict';
const utils = require('../consts');
const utils = require('../utils');
module.exports = (start = null, end = null) => ({
version: 'h004',

View File

@ -1,6 +1,6 @@
'use strict';
const utils = require('../consts');
const utils = require('../utils');
module.exports = (start = null, end = null) => ({
version: 'h004',

View File

@ -1,6 +1,6 @@
'use strict';
const utils = require('../consts');
const utils = require('../utils');
module.exports = (start = null, end = null) => ({
version: 'h004',

View File

@ -1,6 +1,6 @@
'use strict';
const utils = require('../consts');
const utils = require('../utils');
module.exports = (start = null, end = null) => ({
version: 'h004',

View File

@ -1,6 +1,6 @@
'use strict';
const utils = require('../consts');
const utils = require('../utils');
module.exports = (start = null, end = null) => ({
version: 'h004',

18
lib/utils.js Normal file
View File

@ -0,0 +1,18 @@
'use strict';
const dateRange = (start, end) => {
if (start && end)
return {
DateRange: {
Start: start,
End: end,
},
};
return {};
};
module.exports = {
dateRange,
};