-
Notifications
You must be signed in to change notification settings - Fork 190
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
d9dc929 OS-3669. Update booking labels cddcc0a OS-4151. Re-request resources after applying force assignment rules ad8ab1e OS-4548. Fixed missing organization_id field in saving_spike task 0222966 OS-5101. Fixed showing deleted env resources in pool api
- Loading branch information
Showing
17 changed files
with
205 additions
and
76 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
35 changes: 35 additions & 0 deletions
35
ngui/ui/src/components/CurrentBooking/AvailableIn/AvailableIn.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
import KeyValueLabel from "components/KeyValueLabel/KeyValueLabel"; | ||
import { useFormatIntervalDuration } from "hooks/useFormatIntervalDuration"; | ||
import { INTERVAL_DURATION_VALUE_TYPES } from "utils/datetime"; | ||
|
||
type AvailableInProps = { | ||
remained: { | ||
weeks: number; | ||
days: number; | ||
hours: number; | ||
minutes: number; | ||
seconds: number; | ||
milliseconds: number; | ||
}; | ||
}; | ||
|
||
const AvailableIn = ({ remained }: AvailableInProps) => { | ||
const formatInterval = useFormatIntervalDuration(); | ||
|
||
return ( | ||
<KeyValueLabel | ||
keyMessageId="availableIn" | ||
value={formatInterval({ | ||
formatTo: [ | ||
INTERVAL_DURATION_VALUE_TYPES.WEEKS, | ||
INTERVAL_DURATION_VALUE_TYPES.DAYS, | ||
INTERVAL_DURATION_VALUE_TYPES.HOURS, | ||
INTERVAL_DURATION_VALUE_TYPES.MINUTES | ||
], | ||
duration: remained | ||
})} | ||
/> | ||
); | ||
}; | ||
|
||
export default AvailableIn; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
import AvailableIn from "./AvailableIn"; | ||
|
||
export default AvailableIn; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
29 changes: 0 additions & 29 deletions
29
ngui/ui/src/components/UpcomingBooking/BookingTimeMeasure/BookingTimeMeasure.tsx
This file was deleted.
Oops, something went wrong.
3 changes: 0 additions & 3 deletions
3
ngui/ui/src/components/UpcomingBooking/BookingTimeMeasure/index.ts
This file was deleted.
Oops, something went wrong.
35 changes: 35 additions & 0 deletions
35
ngui/ui/src/components/UpcomingBooking/Duration/Duration.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
import KeyValueLabel from "components/KeyValueLabel/KeyValueLabel"; | ||
import { useFormatIntervalDuration } from "hooks/useFormatIntervalDuration"; | ||
import { INTERVAL_DURATION_VALUE_TYPES } from "utils/datetime"; | ||
|
||
type DurationProps = { | ||
duration: { | ||
weeks: number; | ||
days: number; | ||
hours: number; | ||
minutes: number; | ||
seconds: number; | ||
milliseconds: number; | ||
}; | ||
}; | ||
|
||
const Duration = ({ duration }: DurationProps) => { | ||
const formatInterval = useFormatIntervalDuration(); | ||
|
||
return ( | ||
<KeyValueLabel | ||
keyMessageId="duration" | ||
value={formatInterval({ | ||
formatTo: [ | ||
INTERVAL_DURATION_VALUE_TYPES.WEEKS, | ||
INTERVAL_DURATION_VALUE_TYPES.DAYS, | ||
INTERVAL_DURATION_VALUE_TYPES.HOURS, | ||
INTERVAL_DURATION_VALUE_TYPES.MINUTES | ||
], | ||
duration | ||
})} | ||
/> | ||
); | ||
}; | ||
|
||
export default Duration; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
import Duration from "./Duration"; | ||
|
||
export default Duration; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
import BookingTimeMeasure from "./BookingTimeMeasure"; | ||
import UpcomingBooking, { getBookingTimeMeasuresDefinition } from "./UpcomingBooking"; | ||
|
||
export { BookingTimeMeasure, getBookingTimeMeasuresDefinition }; | ||
export { getBookingTimeMeasuresDefinition }; | ||
export default UpcomingBooking; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.