// Если в popup есть место для отображения ФИО
const doctorName = document.querySelector('#selected-doctor');
if (doctorName) {
doctorName.textContent = doctor;
}
// Открываем popup
const popupLink = document.createElement('a');
popupLink.href = '#popup:appointment';
popupLink.style.display = 'none';
document.body.appendChild(popupLink);
popupLink.click();
popupLink.remove();
});
});