fix(calculateDurationYmd):moment(endDate).startOf("day").add(1, "day");
This commit is contained in:
parent
8e1e5044c7
commit
f44076670f
2 changed files with 3 additions and 1 deletions
|
|
@ -946,7 +946,7 @@ export const useCounterMixin = defineStore("mixin", () => {
|
|||
if (!startDate || !endDate) return "";
|
||||
|
||||
let start = moment(startDate).startOf("day");
|
||||
let end = moment(endDate).startOf("day");
|
||||
let end = moment(endDate).startOf("day").add(1, "day");
|
||||
|
||||
// สลับค่าเพื่อให้ end มากกว่า start เสมอ
|
||||
if (start > end) [start, end] = [end, start];
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue