ProfessionInfo.h 942 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. #ifndef PROFESSION_H
  2. #define PROFESSION_H
  3. #include <QDialog>
  4. #include <QDateTime>
  5. class QFUser;
  6. namespace Ui {
  7. class ProfessionalInfo;
  8. }
  9. class ProfessionalInfo : public QDialog
  10. {
  11. Q_OBJECT
  12. public:
  13. explicit ProfessionalInfo(QWidget *parent = nullptr);
  14. ~ProfessionalInfo();
  15. bool completeIt();
  16. void setCompleteIt(bool complete);
  17. void setPerson(const QFUser &person);
  18. void setSureButtonVisible();
  19. void setDetailButtonVisible();
  20. signals:
  21. void addNewPro(QString name);
  22. void saveNewUser();
  23. private slots:
  24. void on_saveBtn_clicked();
  25. void on_clearBtn_clicked();
  26. void textChanged(const QString &text);
  27. void on_sureButton_clicked();
  28. private:
  29. Ui::ProfessionalInfo *ui;
  30. bool m_completeIt; // 是否需要完善信息
  31. int m_userId = -1;
  32. bool m_done;
  33. // QWidget interface
  34. protected:
  35. void closeEvent(QCloseEvent *event) Q_DECL_OVERRIDE;
  36. };
  37. #endif // PROFESSION_H