selectvalueform.h 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. #ifndef SELECTVALUEFORM_H
  2. #define SELECTVALUEFORM_H
  3. #include <QWidget>
  4. #include "configinfo.h"
  5. #include "handle/httprequest.h"
  6. namespace Ui {
  7. class SelectValueForm;
  8. }
  9. //TODO: 小宋 从GlobalInfo::this_()->project().values() 取出所有,保存,然后自己保存下标在上层做分页
  10. class SelectValueForm : public QWidget
  11. {
  12. Q_OBJECT
  13. public:
  14. explicit SelectValueForm(QWidget *parent = nullptr);
  15. ~SelectValueForm();
  16. void getInfo(int page, int pageListNum = 20);
  17. inline void setStatus(int staus){status = staus;}
  18. signals:
  19. void back();
  20. private slots:
  21. void result(int code, const QJsonObject & body);
  22. void refPage();
  23. void parseObject(const QJsonObject & obj);
  24. void on_pushPrev_clicked();
  25. void on_pushNext_clicked();
  26. void on_pushButton_2_clicked();
  27. void on_pushButton_3_clicked();
  28. private:
  29. Ui::SelectValueForm *ui;
  30. int nowPage;
  31. int pageListNum;
  32. int totlePage;
  33. int totleNum;
  34. HttpRequest _request;
  35. int status;
  36. };
  37. #endif // SELECTVALUEFORM_H