diff --git a/src/showplanner/Item.tsx b/src/showplanner/Item.tsx index 527d4f4..5b8e9b5 100644 --- a/src/showplanner/Item.tsx +++ b/src/showplanner/Item.tsx @@ -52,6 +52,7 @@ export const Item = memo(function Item({ event: e, props: { id, + trackid: x.trackid, title: x.title, artist: x.artist, }, diff --git a/src/showplanner/index.tsx b/src/showplanner/index.tsx index a673c18..c42843f 100644 --- a/src/showplanner/index.tsx +++ b/src/showplanner/index.tsx @@ -10,11 +10,12 @@ import { FaTrash, FaUpload, FaCircleNotch, + FaPencilAlt, } from "react-icons/fa"; import { VUMeter } from "../optionsMenu/helpers/VUMeter"; import Stopwatch from "react-stopwatch"; -import { TimeslotItem } from "../api"; +import { MYRADIO_NON_API_BASE, TimeslotItem } from "../api"; import appLogo from "../assets/images/webstudio.svg"; import { @@ -451,6 +452,21 @@ const Showplanner: React.FC<{ timeslotId: number }> = function({ timeslotId }) { > Mark Unplayed + { + if ("trackid" in (args.props as any)) { + window.open( + MYRADIO_NON_API_BASE + + "/Library/editTrack?trackid=" + + (args.props as any).trackid + ); + } else { + alert("Sorry, editing tracks is only possible right now."); + } + }} + > + Edit Item +