This commit is contained in:
Your Name
2026-08-13 14:22:19 +08:00
parent 72a5300b08
commit cbe71905c0
16 changed files with 347 additions and 375 deletions
@@ -427,7 +427,7 @@ class AppointmentsPage(QWidget):
self.patient_input.returnPressed.connect(self._search)
layout.addWidget(self.patient_input)
self.doctor_input = QLineEdit()
self.doctor_input = QLineEdit(frame)
self.doctor_input.setPlaceholderText("医生")
self.doctor_input.setClearButtonEnabled(True)
self.doctor_input.setMaximumWidth(120)
@@ -572,7 +572,10 @@ class AppointmentsPage(QWidget):
*,
danger: bool = False,
) -> QPushButton:
button = QPushButton(label)
# Permission visibility is evaluated before the toolbar layout adopts
# the button. Give it a real owner up front so setVisible(True) cannot
# create a transient top-level HWND on Windows.
button = QPushButton(label, self)
button.setProperty("variant", "danger" if danger else "secondary")
button.setVisible(_canonical_allowed(self.permissions, permission, default=False))
button.setEnabled(False)