@pisell/pisellos 0.0.217 → 0.0.219
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/modules/Customer/constants.d.ts +1 -1
- package/dist/modules/Customer/constants.js +1 -1
- package/dist/solution/BookingByStep/utils/resources.js +4 -0
- package/lib/modules/Customer/constants.d.ts +1 -1
- package/lib/modules/Customer/constants.js +1 -1
- package/lib/solution/BookingByStep/utils/resources.js +4 -1
- package/package.json +1 -1
|
@@ -431,6 +431,10 @@ export var getTimeSlicesByResource = function getTimeSlicesByResource(_ref5) {
|
|
|
431
431
|
|
|
432
432
|
// 存储所有时间切片
|
|
433
433
|
var timeSlices = [];
|
|
434
|
+
// times 先以开始时间为准做个排序,时间早的先循环
|
|
435
|
+
times.sort(function (a, b) {
|
|
436
|
+
return dayjs(a.start_at).diff(dayjs(b.start_at), 'minute');
|
|
437
|
+
});
|
|
434
438
|
|
|
435
439
|
// 处理每个时间范围
|
|
436
440
|
times.forEach(function (time) {
|
|
@@ -345,8 +345,11 @@ var getTimeSlicesByResource = ({
|
|
|
345
345
|
operating_day_boundary,
|
|
346
346
|
maxBlockThreshold
|
|
347
347
|
}) => {
|
|
348
|
-
|
|
348
|
+
let { times } = resource;
|
|
349
349
|
const timeSlices = [];
|
|
350
|
+
times.sort((a, b) => {
|
|
351
|
+
return (0, import_dayjs.default)(a.start_at).diff((0, import_dayjs.default)(b.start_at), "minute");
|
|
352
|
+
});
|
|
350
353
|
times.forEach((time) => {
|
|
351
354
|
const startTime = (0, import_dayjs.default)(`${time.start_at}`);
|
|
352
355
|
const endTime = (0, import_dayjs.default)(`${time.end_at}`);
|