Guest User

Untitled

a guest
Oct 17th, 2018
103
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.49 KB | None | 0 0
  1. #ifndef INTERVALOFECHAS_H
  2. #define INTERVALOFECHAS_H
  3.  
  4. #include "blcrear.h"
  5. #include "tsystem.h"
  6. #include "blhelp.h"
  7. #include "pdefs_plugin_pro.h"
  8. #include "ui_intervalo_fechasbase.h"
  9. #include "blgenericcomboboxdelegate.h"
  10. #include "blcomboboxdelegate.h"
  11.  
  12. class PLUGIN_PRO_EXPORT IntervaloFechas
  13. : public BlCrear
  14. , public Ui::IntervaloFechasBase
  15. {
  16. Q_OBJECT
  17. public:
  18. IntervaloFechas();
  19. ~IntervaloFechas();
  20. //void combo();
  21. void on_mui_aceptar_clicked();
  22. public slots:
  23. void imprimir_resumen_global();
  24.  
  25. private slots:
  26. void on_mui_cancelar_clicked();
  27. };
  28.  
  29. #endif
  30.  
  31. #include "intervalo_fechas.h"
  32.  
  33. IntervaloFechas::IntervaloFechas()
  34. {
  35. BL_FUNC_DEBUG;
  36. try{
  37.  
  38. setAttribute(Qt::WA_DeleteOnClose);
  39. setupUi(this);
  40.  
  41. mui_id_tipo_proto->setMainCompany(mainCompany());
  42. mui_id_tipo_proto->setQuery("SELECT id,concepto FROM pro.tipo_proto");
  43. mui_id_tipo_proto->setFieldId("id");
  44. mui_id_tipo_proto->m_valores["concepto"]= "";
  45. mui_id_tipo_proto->setAllowNull(true);
  46.  
  47. } catch(...) {
  48. g_s->msgError(_("No se pudo abrir la ventana %1.").arg(metaObject()->className()), this);
  49. }
  50.  
  51. }
  52.  
  53. IntervaloFechas::~IntervaloFechas()
  54. {
  55. BL_FUNC_DEBUG;
  56. // En el caso de querer usar esta venta para otros estados, seria ahcer un CASE y en el Ui, pasarle valor donde pone "Revisar" para que ponga el estado del case en el label.
  57.  
  58. }
  59. void IntervaloFechas::on_mui_aceptar_clicked()
  60. {
  61. g_s->msgError("generar informe");
  62. close();
  63. }
  64.  
  65.  
  66. void IntervaloFechas::on_mui_cancelar_clicked()
  67. {
  68. close();
  69. }
  70.  
  71. <item>
  72. <widget class="QLabel" name="label">
  73. <property name="maximumSize">
  74. <size>
  75. <width>50</width>
  76. <height>50</height>
  77. </size>
  78. </property>
  79. <property name="text">
  80. <string>Tipo</string>
  81. </property>
  82. </widget>
  83. </item>
  84. <item>
  85. <widget class="BlComboBox" name="mui_id_tipo_proto" native="true"/>
  86. </item>
  87. <item>
  88. <spacer name="horizontalSpacer_3">
  89. <property name="orientation">
  90. <enum>Qt::Horizontal</enum>
  91. </property>
  92. <property name="sizeType">
  93. <enum>QSizePolicy::Fixed</enum>
  94. </property>
  95. <property name="sizeHint" stdset="0">
  96. <size>
  97. <width>10</width>
  98. <height>20</height>
  99. </size>
  100. </property>
  101. </spacer>
  102. </item>
  103. </layout>
  104. </widget>
  105. </item>
Add Comment
Please, Sign In to add comment