У меня есть приложение для пациента с врачом, и я пытаюсь получить календарь, чтобы отображаться в одной его части, используя Calendar.js. Я попробовал множество решений и не смог получить события для появления.import { Calendar } from '@fullcalendar/core';import dayGridPlugin from '@fullcalendar/daygrid';
import timeGridPlugin from '@fullcalendar/timegrid';
import listPlugin from '@fullcalendar/list';
document.addEventListener('DOMContentLoaded', function () {
const calendarEl = document.getElementById('calendar');
const calendar = new Calendar(calendarEl, {
plugins: [dayGridPlugin, timeGridPlugin, listPlugin],
initialView: 'dayGridMonth',
headerToolbar: {
left: 'prev, next today',
center: 'title',
right: 'dayGridMonth, timeGridWeek, listWeek'
},
events: [
{
title: "Record a video for Marisa",
start: "2025-06-20"
},
],
});
calendar.render()
});
< /code>
Вот страница show.cshtml, на которой я вызываю файл календаря из: < /p>
@using planMyMDVisit.Utilities
@model planMyMDVisit.Models.ViewModels.PatientEventViewModel
#calendar-container {
width: 80%;
height: 500px;
margin-left: auto;
margin-right: auto;
margin-top: -30px;
}
#calendar {
height: 100%;
width: 100%;
}
a.btn {
margin-bottom: 5px;
}
Coronavirus/COVID-19 Alert
If you have been in close contact with someone with coronavirus (COVID-19) and have experienced any of the following: fever, cough, diarrhea, cold/flu-like symptoms or have concerns that your current symptoms are related to COVID-19, please contact your doctor's office or local public health department for further direction.
plan my MD visit is not for use in emergencies or for messages that require immediate attention. For medical or psychiatric emergencies, call 911 or go to the nearest hospital.
Schedule an Appointment
View All
Your Care Team
@foreach (var hct in Helpers.TwoLatestCareTeams(Model.Patient))
{
@hct.Doctor.Specialty
@hct.Doctor.FullName()
}
< /code>
Я попробовал его с этим файлом, сидя над вышеизложенным: < /p>
< /code>
Я также попробовал его с удаленной части типа = "модуля". Я много читал из Docs of Calendar.js и использовал CHATGPT. Ничто не получает это событие «Запишите видео с Марисой» даже для появления ......... любая помощь ценится.
Подробнее здесь: https://stackoverflow.com/questions/796 ... razor-page
Не могу получить календарь календаря. ⇐ C#
-
- Похожие темы
- Ответы
- Просмотры
- Последнее сообщение