-
Notifications
You must be signed in to change notification settings - Fork 0
/
frmMenuPrincipal.frm
300 lines (268 loc) · 7.96 KB
/
frmMenuPrincipal.frm
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
VERSION 5.00
Begin VB.Form frmMenuPrincipal
BorderStyle = 4 'Fixed ToolWindow
Caption = "Menú Principal"
ClientHeight = 8370
ClientLeft = 45
ClientTop = 615
ClientWidth = 11175
LinkTopic = "Form1"
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 8370
ScaleWidth = 11175
StartUpPosition = 1 'CenterOwner
Begin VB.CommandButton cmdProveedores
Caption = "Proveedores"
BeginProperty Font
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 2415
Left = 6240
Picture = "frmMenuPrincipal.frx":0000
Style = 1 'Graphical
TabIndex = 5
Top = 600
Width = 2775
End
Begin VB.CommandButton cmdTubos
Caption = "Tubos"
BeginProperty Font
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 2415
Left = 360
Picture = "frmMenuPrincipal.frx":19D5
Style = 1 'Graphical
TabIndex = 4
Top = 3240
Width = 2655
End
Begin VB.CommandButton cmdClientes
Caption = "Clientes"
BeginProperty Font
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 2415
Left = 3360
Picture = "frmMenuPrincipal.frx":334A
Style = 1 'Graphical
TabIndex = 3
Top = 600
Width = 2655
End
Begin VB.CommandButton cmdSalir
Caption = "Salir"
Height = 1215
Left = 9360
Picture = "frmMenuPrincipal.frx":4EDA
Style = 1 'Graphical
TabIndex = 2
Top = 6960
Width = 1455
End
Begin VB.CommandButton Command1
Caption = "Artículos"
BeginProperty Font
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 2415
Left = 360
Picture = "frmMenuPrincipal.frx":57A4
Style = 1 'Graphical
TabIndex = 1
Top = 600
Width = 2655
End
Begin VB.CommandButton cmdFacturador
Caption = "Facturación"
BeginProperty Font
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 2415
Left = 3360
Picture = "frmMenuPrincipal.frx":6EC1
Style = 1 'Graphical
TabIndex = 0
Top = 3240
Width = 2655
End
Begin VB.Menu mnArticulos
Caption = "Artículos"
Begin VB.Menu mnAbmArticulos
Caption = "ABM Artículos"
End
End
Begin VB.Menu mnVentas
Caption = "Ventas"
Begin VB.Menu mnClientes
Caption = "Clientes"
End
Begin VB.Menu mnFacturador
Caption = "Facturador"
End
End
Begin VB.Menu mnCompras
Caption = "Compras"
Index = 0
Begin VB.Menu mnProveedores
Caption = "Proveedores"
End
Begin VB.Menu mnRegistrar
Caption = "Registrar"
Enabled = 0 'False
Index = 0
Visible = 0 'False
End
End
Begin VB.Menu mnInformes
Caption = "Informes"
Begin VB.Menu mnHistorialDeCajas
Caption = "Historial de Cajas"
End
Begin VB.Menu mnConsultaComprobantes
Caption = "Consulta de Ventas"
End
Begin VB.Menu mnConsultaDeCompras
Caption = "Consulta de Compras"
End
Begin VB.Menu mnDetalleDeTotales
Caption = "Detalle de Totales"
End
Begin VB.Menu mnListadoStockyPrecios
Caption = "Listado de Stock y Precios"
End
End
Begin VB.Menu mnConfiguracion
Caption = "Configuración"
Begin VB.Menu mnUsuariosYpermisos
Caption = "Usuarios y Permisos"
End
Begin VB.Menu mnCambiarClave
Caption = "Cambiar mi Clave"
End
Begin VB.Menu mnParametros
Caption = "Parámetros"
End
End
End
Attribute VB_Name = "frmMenuPrincipal"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Dim rs As New ADODB.Recordset
Private Sub cmdClientes_Click()
mnClientes_Click
End Sub
Private Sub cmdFacturador_Click()
mnFacturador_Click
End Sub
Private Sub cmdProveedores_Click()
mnProveedores_Click
End Sub
Private Sub cmdSalir_Click()
Unload Me
End Sub
Private Sub cmdTubos_Click()
frmTubos.Show 1
End Sub
Private Sub Command1_Click()
mnAbmArticulos_Click
End Sub
Private Sub Form_Load()
cn.Open
Set rs = cn.Execute("VerPermsisosDeUsuario " & idUsuario)
If rs!EstablecerUsuariosyPermisos = 1 Then
mnUsuariosYpermisos.Visible = True
Else
mnUsuariosYpermisos.Visible = False
End If
If rs!VerInformes = 1 Then
mnInformes.Visible = True
Else
mnInformes.Visible = False
End If
cn.Close
End Sub
Private Sub mnAbmArticulos_Click()
cn.Open
Set rs = cn.Execute("VerPermsisosDeUsuario " & idUsuario)
If rs!ModificarArticulos = 0 Then MsgBox ("Función no permitida"): cn.Close: Exit Sub
cn.Close
frmArticulos.Show 1
End Sub
Private Sub mnCambiarClave_Click()
frmCambiarClave.Show 1
End Sub
Private Sub mnClientes_Click()
cn.Open
Set rs = cn.Execute("VerPermsisosDeUsuario " & idUsuario)
If rs!ModificarClientes = 0 Then MsgBox ("Función no permitida"): cn.Close: Exit Sub
cn.Close
frmClientes.Show 1
End Sub
Private Sub mnConsultaComprobantes_Click()
frmConsultaComprobantes.Show 1
End Sub
Private Sub mnConsultaDeCompras_Click()
frmInformesDeCompras.Show 1
End Sub
Private Sub mnDetalleDeTotales_Click()
frmDetalleDeVentas.Show 1
End Sub
Private Sub mnFacturador_Click()
cn.Open
Set rs = cn.Execute("VerPermsisosDeUsuario " & idUsuario)
If rs!Facturar = 0 Then MsgBox ("Función no permitida"): cn.Close: Exit Sub
cn.Close
frmFacturador.Show 1
End Sub
Private Sub mnHistorialDeCajas_Click()
frmHistoricoDeCajas.Show 1
End Sub
Private Sub mnListadoStockyPrecios_Click()
frmListadoStockyPrecios.Show 1
End Sub
Private Sub mnParametros_Click()
frmParametros.Show 1
End Sub
Private Sub mnProveedores_Click()
frmProveedores.Show 1
End Sub
Private Sub mnRegistrar_Click(Index As Integer)
frmCompras.Show 1
End Sub
Private Sub mnUsuariosYpermisos_Click()
frmUsuarios.Show 1
End Sub