isFromPreviousMonth shown in yellow

This commit is contained in:
Dobromir Popov
2024-02-28 23:47:36 +02:00
parent 7ebf442adc
commit 7dba304f25

View File

@ -56,7 +56,7 @@ export default function AvailabilityList({ publisher, showNew }) {
</thead>
<tbody>
{items?.sort((a, b) => new Date(a.startTime) - new Date(b.startTime)).map(item => (
<tr key={item.id} availability={item} disabled={!item.isactive} >
<tr key={item.id} availability={item} disabled={!item.isactive} className={`${item.isFromPreviousMonth ? 'bg-yellow-200' : ''} ${!item.isactive ? 'opacity-50' : ''}`}>
<td className="px-6 py-4 whitespace-nowrap">
{item.dayOfMonth ? `${common.getDateFormated(new Date(item.startTime))}` : `Всеки(Всяка) ${common.getDayOfWeekName(new Date(item.startTime))}`}
{/* {common.getDateFormated(new Date(item.startTime))} */}