parroquia 1.1.3 → 1.1.5

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 692250fd1b03fa8e718584fd63a2aca515f1739b5d8c59c29e3b8a9f8ea8e7cd
4
- data.tar.gz: 43ed8f1753dfcdfaa27ef32ccd4b1feffd7bd8417e191ac0fa927cf35aa4c548
3
+ metadata.gz: 3c355e9569574dcec94e51cd790cb525615d4a12f7fc60fbc7d753460caa5ecc
4
+ data.tar.gz: 4b21e4d758c92536cae7962cbd97f74ef931982626d6b5d7957c8367f7062b8d
5
5
  SHA512:
6
- metadata.gz: f77e3690105d8f505525939f9136e2667fc5d87d0cf0e2d56c45c32800d72e734488f8f5aa1408dc7e6e787ae30dfde278c05e5d8ed8ed408e721be55915e48c
7
- data.tar.gz: c63c4ac12a68d9b4775000f01328b0781786dd3a8a0b0a56bf68c0c017f136bf05bcfe6304b0c5080718549543810b4e438a2c93f6b9a029120dc2e95f594e87
6
+ metadata.gz: 507f513f0e3e40d16325ef5bb36fa27d11543c6e7b3b9eaaf3d60513d6593249da8748b67813df2eb591d9615caa8a3c2e5f0a7c2180d3c1b5eaf288ffd6c8e9
7
+ data.tar.gz: 61cfb50a96de02f83b8101e682102e0123de84629a8bfb9bdd62febf7e2fda1192dd394e9d423b48877dd4a500076ebf1fdd972d01e54e9fe226fa987b57fdd6
Binary file
@@ -4,7 +4,7 @@ include Fox
4
4
 
5
5
  class Consulta < FXMainWindow
6
6
  def initialize(app)
7
- super(app, "Parroquia San Judas Tadeo", :width => 700, :height => 500)
7
+ super(app, "Parroquia San Judas Tadeo", :width => 700, :height => 380)
8
8
  @app = app
9
9
  self.backColor = FXRGB(3,187,133)
10
10
 
@@ -75,7 +75,6 @@ class Consulta < FXMainWindow
75
75
  sql += " AND sacramentos.fecha >= '#{fecha_desde}'" unless fecha_desde.empty?
76
76
  sql += " AND sacramentos.fecha <= '#{fecha_hasta}'" unless fecha_hasta.empty?
77
77
  sql += " AND sacramentos.sacramento = '#{sacramento}'" unless sacramento.empty?
78
- puts sql
79
78
  $conn.exec(sql) do |result|
80
79
  if result.values.empty?
81
80
  FXMessageBox.information(self, MBOX_OK, "Información", "No se encontraron registros")
@@ -2,14 +2,7 @@ require 'pg'
2
2
  require 'fox16'
3
3
  include Fox
4
4
 
5
- $conn = PG.connect(host: 'localhost', port: '5432', dbname: 'sacramentos', user: 'postgres', password: 'postgres')
6
- # Comprobar conexión con la base de datos
7
- if $conn.status != PG::CONNECTION_OK
8
- puts "Error de conexión con la base de datos"
9
- exit
10
- end
11
-
12
- class Home < FXMainWindow
5
+ class Parroquia::Main < FXMainWindow
13
6
  def initialize(app)
14
7
  super(app, "Parroquia San Judas Tadeo", :width => 700, :height => 500)
15
8
  @app = app
@@ -126,8 +119,15 @@ class Home < FXMainWindow
126
119
  end
127
120
  end
128
121
 
122
+ $conn = PG.connect(host: 'localhost', port: '5432', dbname: 'sacramentos', user: 'postgres', password: 'postgres')
123
+ # Comprobar conexión con la base de datos
124
+ if $conn.status != PG::CONNECTION_OK
125
+ puts "Error de conexión con la base de datos"
126
+ exit
127
+ end
128
+
129
129
  app = FXApp.new
130
- vtnhome = Home.new(app)
130
+ vtnhome = Parroquia::Main.new(app)
131
131
  app.create
132
132
  app.run
133
133
 
@@ -5,7 +5,7 @@ include Fox
5
5
 
6
6
  class ResultadosConsulta < FXMainWindow
7
7
  def initialize(app, result_data)
8
- super(app, "Resultados de la Consulta", :width => 800, :height => 600)
8
+ super(app, "Resultados de la Consulta", :width => 800, :height => 480)
9
9
  @app = app
10
10
 
11
11
  @result_data = result_data # Los datos de resultados que se pasan a esta clase
@@ -120,10 +120,9 @@ class ResultadosConsulta < FXMainWindow
120
120
  end
121
121
 
122
122
  # create buttons
123
- @btnprint = FXButton.new(self, "Imprimir", :opts => LAYOUT_EXPLICIT | BUTTON_NORMAL, :width => 100, :height => 30, :x => 10, :y => 430)
124
- @btnedit = FXButton.new(self, "Editar", :opts => LAYOUT_EXPLICIT | BUTTON_NORMAL, :width => 100, :height => 30, :x => 120, :y => 430)
125
- @btndelete = FXButton.new(self, "Eliminar", :opts => LAYOUT_EXPLICIT | BUTTON_NORMAL, :width => 100, :height => 30, :x => 230, :y => 430)
126
- @btncancel = FXButton.new(self, "Cancelar", :opts => LAYOUT_EXPLICIT | BUTTON_NORMAL, :width => 100, :height => 30, :x => 340, :y => 430)
123
+ @btnprint = FXButton.new(self, "Exportar PDF", :opts => LAYOUT_EXPLICIT | BUTTON_NORMAL, :width => 100, :height => 30, :x => 460, :y => 430)
124
+ @btnedit = FXButton.new(self, "Editar", :opts => LAYOUT_EXPLICIT | BUTTON_NORMAL, :width => 100, :height => 30, :x => 570, :y => 430)
125
+ @btndelete = FXButton.new(self, "Eliminar", :opts => LAYOUT_EXPLICIT | BUTTON_NORMAL, :width => 100, :height => 30, :x => 680, :y => 430)
127
126
 
128
127
  # connect buttons
129
128
  @btnprint.connect(SEL_COMMAND) do
@@ -405,11 +404,6 @@ class ResultadosConsulta < FXMainWindow
405
404
  end
406
405
  end
407
406
  end
408
-
409
- @btncancel.connect(SEL_COMMAND) do
410
- # cerrar ventana
411
- close
412
- end
413
407
  end
414
408
 
415
409
  def create
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: parroquia
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.3
4
+ version: 1.1.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Francisco Javier Borja Lobato