Skip to content

Commit

Permalink
Refactor reservation helper to include volume information in periodicals
Browse files Browse the repository at this point in the history
  • Loading branch information
Adamik10 committed Sep 17, 2024
1 parent bf2239e commit ecf0c74
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/components/reservation/helper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,10 @@ export const getFutureDateStringISO = (num: number) => {
return futureDate;
};

type Periodical = Pick<PeriodicalEdition, "volumeNumber" | "volumeYear">;
type Periodical = Pick<
PeriodicalEdition,
"volumeNumber" | "volumeYear" | "volume"
>;

const constructReservation = ({
manifestation: { pid },
Expand Down Expand Up @@ -116,6 +119,7 @@ export const constructReservationData = ({
...(periodical
? {
periodical: {
volume: periodical.volume,
volumeNumber: periodical.volumeNumber,
volumeYear: periodical.volumeYear
}
Expand Down

0 comments on commit ecf0c74

Please sign in to comment.