Skip to content
Snippets Groups Projects
Commit 419b0009 authored by Raven Z.'s avatar Raven Z. :cat2:
Browse files

minor changes

parent 911383d3
No related branches found
No related tags found
No related merge requests found
...@@ -9,7 +9,8 @@ const tplText = fs.readFileSync(path.join(__dirname, 'mail.mustache'), 'utf-8') ...@@ -9,7 +9,8 @@ const tplText = fs.readFileSync(path.join(__dirname, 'mail.mustache'), 'utf-8')
//console.log('tpl: ', tplText) //console.log('tpl: ', tplText)
//console.log('data:', dataText) //console.log('data:', dataText)
const data = JSON.parse(dataText) const data = JSON.parse(dataText)
const dayData = data.days[moment().format('YYYY-MM-DD')] const dateParam = process.argv[2] || undefined
const dayData = data.days[moment(dateParam).format('YYYY-MM-DD')]
const usedAdditives = {} const usedAdditives = {}
dayData.menu.forEach(m => dayData.menu.forEach(m =>
m.description.forEach(d => m.description.forEach(d =>
......
...@@ -3,19 +3,19 @@ ...@@ -3,19 +3,19 @@
{{#today.menu}} {{#today.menu}}
{{ category }} ({{ price }}) {{#labels}}[{{.}}]{{/labels}}: {{ category }} ({{ price }}) {{#labels}}[{{.}}]{{/labels}}:
{{#description}} {{#description}}
- {{ text }} {{#notes}}[{{.}}]{{/notes}} - {{ &text }} {{#notes}}[{{.}}]{{/notes}}
{{/description}} {{/description}}
{{/today.menu}} {{/today.menu}}
{{#today.extras}} {{#today.extras}}
{{ category }}: {{ category }}:
{{#options}} {{#options}}
- {{#description}} {{text}} {{#notes}}[{{.}}]{{/notes}}{{/description}} - {{#description}} {{ &text }} {{#notes}}[{{.}}]{{/notes}}{{/description}}
{{/options}} {{/options}}
{{/today.extras}} {{/today.extras}}
Additives: Additives:
{{#additives}} {{#additives}}
[{{symbol}}]: {{text}} [{{symbol}}]: {{ &text }}
{{/additives}} {{/additives}}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment