2
0
mirror of https://github.com/tenrok/vue-ganttastic.git synced 2026-06-20 03:00:33 +03:00

Added prop for specifying minimum gap between bars in minutes

Bumped version

Merge branch 'master' of https://github.com/InfectoOne/vue-ganttastic
This commit is contained in:
zunicma
2021-01-11 16:23:22 +01:00
4 changed files with 8 additions and 8 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "vue-ganttastic",
"version": "0.9.24",
"version": "0.9.3",
"lockfileVersion": 1,
"requires": true,
"dependencies": {
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "vue-ganttastic",
"version": "0.9.25",
"version": "0.9.3",
"description": "A simple and customizable Gantt chart component for Vue.js",
"repository": {
"type": "git",
+4 -4
View File
@@ -303,13 +303,13 @@ export default {
switch(overlapType){
case "left":
minuteDiff = overlapEndMoment.diff(currentStartMoment, "minutes", true) + this.getMinGapBetweenBars()
overlapBar[this.barEnd] = moment(currentBar[this.barStart]).subtract(this.getMinGapBetweenBars(), "minutes", true)
overlapBar[this.barStart] = overlapStartMoment.subtract(minuteDiff, "minutes", true)
overlapBar[this.barEnd] = currentStartMoment.subtract(this.getMinGapBetweenBars(), "minutes", true).format("YYYY-MM-DD HH:mm:ss")
overlapBar[this.barStart] = overlapStartMoment.subtract(minuteDiff, "minutes", true).format("YYYY-MM-DD HH:mm:ss")
break
case "right":
minuteDiff = currentEndMoment.diff(overlapStartMoment, "minutes", true) + this.getMinGapBetweenBars()
overlapBar[this.barStart] = moment(currentBar[this.barEnd]).add(this.getMinGapBetweenBars(), "minutes", true)
overlapBar[this.barEnd] = overlapEndMoment.add(minuteDiff, "minutes", true)
overlapBar[this.barStart] = currentEndMoment.add(this.getMinGapBetweenBars(), "minutes", true).format("YYYY-MM-DD HH:mm:ss")
overlapBar[this.barEnd] = overlapEndMoment.add(minuteDiff, "minutes", true).format("YYYY-MM-DD HH:mm:ss")
break
default:
// eslint-disable-next-line
+2 -2
View File
@@ -52,8 +52,8 @@ export default {
rowLabelWidth: {type: String, default: "10%"},
rowHeight: {type: Number, default: 40},
locale: {type: String, default: "en"},
theme: String,
grid: Boolean,
theme: {type: String},
grid: {type: Boolean},
highlightedHours: {type: Array, default: () => []},
width: {type: String, default: "100%"}, // the total width of the entire ganttastic component in %
pushOnOverlap: {type: Boolean},