Fix formatting
This commit is contained in:
parent
af45438ba9
commit
48ea5ad5a2
27
src/index.js
27
src/index.js
@ -68,7 +68,14 @@ export default class Gantt {
|
|||||||
header_height: 50,
|
header_height: 50,
|
||||||
column_width: 30,
|
column_width: 30,
|
||||||
step: 24,
|
step: 24,
|
||||||
view_modes: ['Quarter Day', 'Half Day', 'Day', 'Week', 'Month', 'Year'],
|
view_modes: [
|
||||||
|
'Quarter Day',
|
||||||
|
'Half Day',
|
||||||
|
'Day',
|
||||||
|
'Week',
|
||||||
|
'Month',
|
||||||
|
'Year'
|
||||||
|
],
|
||||||
bar_height: 20,
|
bar_height: 20,
|
||||||
bar_corner_radius: 3,
|
bar_corner_radius: 3,
|
||||||
arrow_curve: 5,
|
arrow_curve: 5,
|
||||||
@ -244,7 +251,11 @@ export default class Gantt {
|
|||||||
} else if (this.view_is('Month')) {
|
} else if (this.view_is('Month')) {
|
||||||
cur_date = date_utils.add(cur_date, 1, 'month');
|
cur_date = date_utils.add(cur_date, 1, 'month');
|
||||||
} else {
|
} else {
|
||||||
cur_date = date_utils.add(cur_date, this.options.step, 'hour');
|
cur_date = date_utils.add(
|
||||||
|
cur_date,
|
||||||
|
this.options.step,
|
||||||
|
'hour'
|
||||||
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
this.dates.push(cur_date);
|
this.dates.push(cur_date);
|
||||||
@ -470,8 +481,16 @@ export default class Gantt {
|
|||||||
last_date = date_utils.add(date, 1, 'year');
|
last_date = date_utils.add(date, 1, 'year');
|
||||||
}
|
}
|
||||||
const date_text = {
|
const date_text = {
|
||||||
'Quarter Day_lower': date_utils.format(date, 'HH', this.options.language),
|
'Quarter Day_lower': date_utils.format(
|
||||||
'Half Day_lower': date_utils.format(date, 'HH', this.options.language),
|
date,
|
||||||
|
'HH',
|
||||||
|
this.options.language
|
||||||
|
),
|
||||||
|
'Half Day_lower': date_utils.format(
|
||||||
|
date,
|
||||||
|
'HH',
|
||||||
|
this.options.language
|
||||||
|
),
|
||||||
Day_lower:
|
Day_lower:
|
||||||
date.getDate() !== last_date.getDate()
|
date.getDate() !== last_date.getDate()
|
||||||
? date_utils.format(date, 'D', this.options.language)
|
? date_utils.format(date, 'D', this.options.language)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user