merma completa

This commit is contained in:
carlos
2024-01-18 23:17:35 -06:00
parent a438eb1914
commit f084bb8e20
24 changed files with 895 additions and 33 deletions
+23 -2
View File
@@ -1,4 +1,6 @@
using System;
using compabetov2.database;
using compabetov2.database.modelos;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
@@ -12,9 +14,28 @@ namespace compabetov2
{
public partial class agregarmermas : Form
{
public agregarmermas()
private mermas ventanaPadre;
public agregarmermas(mermas ventanaPadre)
{
InitializeComponent();
this.ventanaPadre = ventanaPadre;
}
private void label2_Click(object sender, EventArgs e)
{
}
private void btnAgregar_Click(object sender, EventArgs e)
{
string descripcion = txtDescripcion.Text;
string fecha = dtFecha.Text;
string responsable = txtResponsable.Text;
Merma merma = new Merma(-1,fecha,responsable,descripcion);
if (service.insertarMerma(merma)) {
ventanaPadre.llenarPanel();
Close();
}
}
}
}