bajo cambios1123

This commit is contained in:
Michael Robles
2024-06-18 23:27:30 -07:00
14 changed files with 887 additions and 14 deletions
+2 -1
View File
@@ -1,8 +1,9 @@
{ {
"ExpandedNodes": [ "ExpandedNodes": [
"", "",
"\\admin",
"\\Ventas" "\\Ventas"
], ],
"SelectedNode": "\\Ventas\\Importe1.cs", "SelectedNode": "\\admin\\crud.cs",
"PreviewInSolutionExplorer": false "PreviewInSolutionExplorer": false
} }
Binary file not shown.
+478
View File
@@ -0,0 +1,478 @@
namespace compabetov2.Empleados
{
partial class EditarEmpleado1
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.txtNombre = new System.Windows.Forms.TextBox();
this.txtApellido = new System.Windows.Forms.TextBox();
this.label1 = new System.Windows.Forms.Label();
this.label2 = new System.Windows.Forms.Label();
this.txtCalle = new System.Windows.Forms.TextBox();
this.label3 = new System.Windows.Forms.Label();
this.txtColonia = new System.Windows.Forms.TextBox();
this.label4 = new System.Windows.Forms.Label();
this.txtCp = new System.Windows.Forms.TextBox();
this.label5 = new System.Windows.Forms.Label();
this.txtNoExt = new System.Windows.Forms.TextBox();
this.label6 = new System.Windows.Forms.Label();
this.txtNoInt = new System.Windows.Forms.TextBox();
this.txtReferencia = new System.Windows.Forms.TextBox();
this.label7 = new System.Windows.Forms.Label();
this.label8 = new System.Windows.Forms.Label();
this.dtFechaNac = new System.Windows.Forms.DateTimePicker();
this.label9 = new System.Windows.Forms.Label();
this.dtFechaCon = new System.Windows.Forms.DateTimePicker();
this.label10 = new System.Windows.Forms.Label();
this.txtTelefono = new System.Windows.Forms.TextBox();
this.label11 = new System.Windows.Forms.Label();
this.cbEstado = new System.Windows.Forms.ComboBox();
this.label12 = new System.Windows.Forms.Label();
this.pictureBox2 = new System.Windows.Forms.PictureBox();
this.pictureBox1 = new System.Windows.Forms.PictureBox();
this.lbImg = new System.Windows.Forms.Label();
this.button1 = new System.Windows.Forms.Button();
this.pictureBox3 = new System.Windows.Forms.PictureBox();
((System.ComponentModel.ISupportInitialize)(this.pictureBox2)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.pictureBox3)).BeginInit();
this.SuspendLayout();
//
// txtNombre
//
this.txtNombre.Font = new System.Drawing.Font("Poppins", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.txtNombre.Location = new System.Drawing.Point(23, 208);
this.txtNombre.Margin = new System.Windows.Forms.Padding(4);
this.txtNombre.Name = "txtNombre";
this.txtNombre.Size = new System.Drawing.Size(231, 37);
this.txtNombre.TabIndex = 2;
//
// txtApellido
//
this.txtApellido.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.txtApellido.Location = new System.Drawing.Point(328, 205);
this.txtApellido.Margin = new System.Windows.Forms.Padding(4);
this.txtApellido.Name = "txtApellido";
this.txtApellido.Size = new System.Drawing.Size(231, 42);
this.txtApellido.TabIndex = 3;
//
// label1
//
this.label1.AutoSize = true;
this.label1.BackColor = System.Drawing.Color.Transparent;
this.label1.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label1.ForeColor = System.Drawing.Color.Transparent;
this.label1.Location = new System.Drawing.Point(16, 164);
this.label1.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(128, 40);
this.label1.TabIndex = 4;
this.label1.Text = "Nombres:";
this.label1.Click += new System.EventHandler(this.label1_Click);
//
// label2
//
this.label2.AutoSize = true;
this.label2.BackColor = System.Drawing.Color.Transparent;
this.label2.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label2.ForeColor = System.Drawing.Color.Transparent;
this.label2.Location = new System.Drawing.Point(321, 164);
this.label2.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(128, 40);
this.label2.TabIndex = 5;
this.label2.Text = "Apellidos:";
//
// txtCalle
//
this.txtCalle.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.txtCalle.Location = new System.Drawing.Point(631, 205);
this.txtCalle.Margin = new System.Windows.Forms.Padding(4);
this.txtCalle.Name = "txtCalle";
this.txtCalle.Size = new System.Drawing.Size(231, 42);
this.txtCalle.TabIndex = 6;
//
// label3
//
this.label3.AutoSize = true;
this.label3.BackColor = System.Drawing.Color.Transparent;
this.label3.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label3.ForeColor = System.Drawing.Color.Transparent;
this.label3.Location = new System.Drawing.Point(624, 164);
this.label3.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label3.Name = "label3";
this.label3.Size = new System.Drawing.Size(113, 40);
this.label3.TabIndex = 7;
this.label3.Text = "Colonia:";
//
// txtColonia
//
this.txtColonia.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.txtColonia.Location = new System.Drawing.Point(23, 291);
this.txtColonia.Margin = new System.Windows.Forms.Padding(4);
this.txtColonia.Name = "txtColonia";
this.txtColonia.Size = new System.Drawing.Size(231, 42);
this.txtColonia.TabIndex = 8;
//
// label4
//
this.label4.AutoSize = true;
this.label4.BackColor = System.Drawing.Color.Transparent;
this.label4.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label4.ForeColor = System.Drawing.Color.Transparent;
this.label4.Location = new System.Drawing.Point(16, 249);
this.label4.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label4.Name = "label4";
this.label4.Size = new System.Drawing.Size(113, 40);
this.label4.TabIndex = 9;
this.label4.Text = "Colonia:";
//
// txtCp
//
this.txtCp.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.txtCp.Location = new System.Drawing.Point(328, 291);
this.txtCp.Margin = new System.Windows.Forms.Padding(4);
this.txtCp.Name = "txtCp";
this.txtCp.Size = new System.Drawing.Size(231, 42);
this.txtCp.TabIndex = 10;
//
// label5
//
this.label5.AutoSize = true;
this.label5.BackColor = System.Drawing.Color.Transparent;
this.label5.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label5.ForeColor = System.Drawing.Color.Transparent;
this.label5.Location = new System.Drawing.Point(321, 251);
this.label5.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label5.Name = "label5";
this.label5.Size = new System.Drawing.Size(184, 40);
this.label5.TabIndex = 11;
this.label5.Text = "Codigo Postal:";
//
// txtNoExt
//
this.txtNoExt.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.txtNoExt.Location = new System.Drawing.Point(631, 291);
this.txtNoExt.Margin = new System.Windows.Forms.Padding(4);
this.txtNoExt.Name = "txtNoExt";
this.txtNoExt.Size = new System.Drawing.Size(231, 42);
this.txtNoExt.TabIndex = 12;
//
// label6
//
this.label6.AutoSize = true;
this.label6.BackColor = System.Drawing.Color.Transparent;
this.label6.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label6.ForeColor = System.Drawing.Color.Transparent;
this.label6.Location = new System.Drawing.Point(624, 251);
this.label6.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label6.Name = "label6";
this.label6.Size = new System.Drawing.Size(142, 40);
this.label6.TabIndex = 13;
this.label6.Text = "No.Exterior:";
//
// txtNoInt
//
this.txtNoInt.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.txtNoInt.Location = new System.Drawing.Point(23, 377);
this.txtNoInt.Margin = new System.Windows.Forms.Padding(4);
this.txtNoInt.Name = "txtNoInt";
this.txtNoInt.Size = new System.Drawing.Size(231, 42);
this.txtNoInt.TabIndex = 14;
//
// txtReferencia
//
this.txtReferencia.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.txtReferencia.Location = new System.Drawing.Point(328, 377);
this.txtReferencia.Margin = new System.Windows.Forms.Padding(4);
this.txtReferencia.Name = "txtReferencia";
this.txtReferencia.Size = new System.Drawing.Size(231, 42);
this.txtReferencia.TabIndex = 15;
//
// label7
//
this.label7.AutoSize = true;
this.label7.BackColor = System.Drawing.Color.Transparent;
this.label7.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label7.ForeColor = System.Drawing.Color.Transparent;
this.label7.Location = new System.Drawing.Point(26, 337);
this.label7.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label7.Name = "label7";
this.label7.Size = new System.Drawing.Size(87, 40);
this.label7.TabIndex = 16;
this.label7.Text = "No.Int:";
//
// label8
//
this.label8.AutoSize = true;
this.label8.BackColor = System.Drawing.Color.Transparent;
this.label8.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label8.ForeColor = System.Drawing.Color.Transparent;
this.label8.Location = new System.Drawing.Point(321, 337);
this.label8.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label8.Name = "label8";
this.label8.Size = new System.Drawing.Size(146, 40);
this.label8.TabIndex = 17;
this.label8.Text = "Referencia:";
//
// dtFechaNac
//
this.dtFechaNac.CalendarFont = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.dtFechaNac.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.dtFechaNac.Location = new System.Drawing.Point(631, 377);
this.dtFechaNac.Margin = new System.Windows.Forms.Padding(4);
this.dtFechaNac.Name = "dtFechaNac";
this.dtFechaNac.Size = new System.Drawing.Size(231, 42);
this.dtFechaNac.TabIndex = 18;
//
// label9
//
this.label9.AutoSize = true;
this.label9.BackColor = System.Drawing.Color.Transparent;
this.label9.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label9.ForeColor = System.Drawing.Color.Transparent;
this.label9.Location = new System.Drawing.Point(624, 342);
this.label9.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label9.Name = "label9";
this.label9.Size = new System.Drawing.Size(269, 40);
this.label9.TabIndex = 19;
this.label9.Text = "Fecha de Nacimiento:";
//
// dtFechaCon
//
this.dtFechaCon.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.dtFechaCon.Location = new System.Drawing.Point(23, 467);
this.dtFechaCon.Margin = new System.Windows.Forms.Padding(4);
this.dtFechaCon.Name = "dtFechaCon";
this.dtFechaCon.Size = new System.Drawing.Size(231, 42);
this.dtFechaCon.TabIndex = 20;
//
// label10
//
this.label10.AutoSize = true;
this.label10.BackColor = System.Drawing.Color.Transparent;
this.label10.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label10.ForeColor = System.Drawing.Color.Transparent;
this.label10.Location = new System.Drawing.Point(16, 423);
this.label10.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label10.Name = "label10";
this.label10.Size = new System.Drawing.Size(290, 40);
this.label10.TabIndex = 21;
this.label10.Text = "Fecha de Contratación:";
//
// txtTelefono
//
this.txtTelefono.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.txtTelefono.Location = new System.Drawing.Point(328, 467);
this.txtTelefono.Margin = new System.Windows.Forms.Padding(4);
this.txtTelefono.Name = "txtTelefono";
this.txtTelefono.Size = new System.Drawing.Size(231, 42);
this.txtTelefono.TabIndex = 22;
//
// label11
//
this.label11.AutoSize = true;
this.label11.BackColor = System.Drawing.Color.Transparent;
this.label11.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label11.ForeColor = System.Drawing.Color.Transparent;
this.label11.Location = new System.Drawing.Point(321, 423);
this.label11.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label11.Name = "label11";
this.label11.Size = new System.Drawing.Size(121, 40);
this.label11.TabIndex = 23;
this.label11.Text = "Telefono:";
//
// cbEstado
//
this.cbEstado.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.cbEstado.FormattingEnabled = true;
this.cbEstado.Items.AddRange(new object[] {
"Activo",
"Inactivo"});
this.cbEstado.Location = new System.Drawing.Point(631, 461);
this.cbEstado.Margin = new System.Windows.Forms.Padding(4);
this.cbEstado.Name = "cbEstado";
this.cbEstado.Size = new System.Drawing.Size(231, 48);
this.cbEstado.TabIndex = 24;
this.cbEstado.Text = "Activo";
//
// label12
//
this.label12.AutoSize = true;
this.label12.BackColor = System.Drawing.Color.Transparent;
this.label12.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label12.ForeColor = System.Drawing.Color.Transparent;
this.label12.Location = new System.Drawing.Point(624, 423);
this.label12.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label12.Name = "label12";
this.label12.Size = new System.Drawing.Size(101, 40);
this.label12.TabIndex = 25;
this.label12.Text = "Estado:";
//
// pictureBox2
//
this.pictureBox2.BackColor = System.Drawing.Color.Transparent;
this.pictureBox2.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Center;
this.pictureBox2.Image = global::compabetov2.Properties.Resources.check1;
this.pictureBox2.Location = new System.Drawing.Point(353, 541);
this.pictureBox2.Name = "pictureBox2";
this.pictureBox2.Size = new System.Drawing.Size(100, 69);
this.pictureBox2.TabIndex = 27;
this.pictureBox2.TabStop = false;
this.pictureBox2.Click += new System.EventHandler(this.pictureBox2_Click);
//
// pictureBox1
//
this.pictureBox1.BackColor = System.Drawing.Color.Transparent;
this.pictureBox1.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Center;
this.pictureBox1.Image = global::compabetov2.Properties.Resources.cancel1;
this.pictureBox1.Location = new System.Drawing.Point(459, 541);
this.pictureBox1.Name = "pictureBox1";
this.pictureBox1.Size = new System.Drawing.Size(100, 69);
this.pictureBox1.TabIndex = 26;
this.pictureBox1.TabStop = false;
this.pictureBox1.Click += new System.EventHandler(this.pictureBox1_Click);
//
// lbImg
//
this.lbImg.AutoSize = true;
this.lbImg.BackColor = System.Drawing.Color.Transparent;
this.lbImg.Font = new System.Drawing.Font("Poppins", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.lbImg.ForeColor = System.Drawing.Color.Transparent;
this.lbImg.Location = new System.Drawing.Point(653, 530);
this.lbImg.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.lbImg.Name = "lbImg";
this.lbImg.Size = new System.Drawing.Size(113, 40);
this.lbImg.TabIndex = 28;
this.lbImg.Text = "Imagen:";
//
// button1
//
this.button1.Font = new System.Drawing.Font("Poppins", 10.2F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.button1.Location = new System.Drawing.Point(660, 564);
this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(103, 46);
this.button1.TabIndex = 29;
this.button1.Text = "Subir";
this.button1.UseVisualStyleBackColor = true;
this.button1.Click += new System.EventHandler(this.button1_Click);
//
// pictureBox3
//
this.pictureBox3.BackColor = System.Drawing.Color.Transparent;
this.pictureBox3.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Center;
this.pictureBox3.Image = global::compabetov2.Properties.Resources.check1;
this.pictureBox3.Location = new System.Drawing.Point(206, 135);
this.pictureBox3.Name = "pictureBox3";
this.pictureBox3.Size = new System.Drawing.Size(100, 69);
this.pictureBox3.TabIndex = 30;
this.pictureBox3.TabStop = false;
//
// EditarEmpleado1
//
this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 16F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(27)))), ((int)(((byte)(104)))), ((int)(((byte)(255)))));
this.BackgroundImage = global::compabetov2.Properties.Resources.Form;
this.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch;
this.ClientSize = new System.Drawing.Size(915, 622);
this.ControlBox = false;
this.Controls.Add(this.pictureBox3);
this.Controls.Add(this.button1);
this.Controls.Add(this.lbImg);
this.Controls.Add(this.pictureBox2);
this.Controls.Add(this.pictureBox1);
this.Controls.Add(this.cbEstado);
this.Controls.Add(this.txtTelefono);
this.Controls.Add(this.dtFechaCon);
this.Controls.Add(this.dtFechaNac);
this.Controls.Add(this.txtReferencia);
this.Controls.Add(this.txtNoInt);
this.Controls.Add(this.txtNoExt);
this.Controls.Add(this.txtCp);
this.Controls.Add(this.txtColonia);
this.Controls.Add(this.txtCalle);
this.Controls.Add(this.txtApellido);
this.Controls.Add(this.txtNombre);
this.Controls.Add(this.label12);
this.Controls.Add(this.label11);
this.Controls.Add(this.label10);
this.Controls.Add(this.label9);
this.Controls.Add(this.label8);
this.Controls.Add(this.label7);
this.Controls.Add(this.label6);
this.Controls.Add(this.label5);
this.Controls.Add(this.label4);
this.Controls.Add(this.label3);
this.Controls.Add(this.label2);
this.Controls.Add(this.label1);
this.DoubleBuffered = true;
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;
this.Name = "EditarEmpleado1";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Load += new System.EventHandler(this.EditarEmpleado1_Load);
((System.ComponentModel.ISupportInitialize)(this.pictureBox2)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.pictureBox3)).EndInit();
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.TextBox txtNombre;
private System.Windows.Forms.TextBox txtApellido;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.TextBox txtCalle;
private System.Windows.Forms.Label label3;
private System.Windows.Forms.TextBox txtColonia;
private System.Windows.Forms.Label label4;
private System.Windows.Forms.TextBox txtCp;
private System.Windows.Forms.Label label5;
private System.Windows.Forms.TextBox txtNoExt;
private System.Windows.Forms.Label label6;
private System.Windows.Forms.TextBox txtNoInt;
private System.Windows.Forms.TextBox txtReferencia;
private System.Windows.Forms.Label label7;
private System.Windows.Forms.Label label8;
private System.Windows.Forms.DateTimePicker dtFechaNac;
private System.Windows.Forms.Label label9;
private System.Windows.Forms.DateTimePicker dtFechaCon;
private System.Windows.Forms.Label label10;
private System.Windows.Forms.TextBox txtTelefono;
private System.Windows.Forms.Label label11;
private System.Windows.Forms.ComboBox cbEstado;
private System.Windows.Forms.Label label12;
private System.Windows.Forms.PictureBox pictureBox2;
private System.Windows.Forms.PictureBox pictureBox1;
private System.Windows.Forms.Label lbImg;
private System.Windows.Forms.Button button1;
private System.Windows.Forms.PictureBox pictureBox3;
}
}
+143
View File
@@ -0,0 +1,143 @@
using compabetov2.database.modelos;
using compabetov2.database;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace compabetov2.Empleados
{
public partial class EditarEmpleado1 : Form
{
private Empleado empleado;
private personal ventanaPadre;
private string imagePath;
public EditarEmpleado1(Empleado empleado, personal ventanaPadre)
{
InitializeComponent();
this.empleado = empleado;
this.ventanaPadre = ventanaPadre;
imagePath = Path.Combine(Application.StartupPath, "Resources", "usuarios", empleado.img);
llenarCampos();
txtCp.KeyPress += new KeyPressEventHandler(PermitirSoloNumeros);
// Suscribir al evento KeyPress para el TextBox txtNoExt
txtNoExt.KeyPress += new KeyPressEventHandler(PermitirSoloNumeros);
// Suscribir al evento KeyPress para el TextBox txtNoInt
txtNoInt.KeyPress += new KeyPressEventHandler(PermitirSoloNumeros);
// Suscribir al evento KeyPress para el TextBox txtNombre
txtNombre.KeyPress += new KeyPressEventHandler(PermitirSoloLetras);
// Suscribir al evento KeyPress para el TextBox txtApellido
txtApellido.KeyPress += new KeyPressEventHandler(PermitirSoloLetras);
}
private void llenarCampos()
{
txtNombre.Text = empleado.nombre;
txtApellido.Text = empleado.apellidos;
txtCalle.Text = empleado.calle;
txtColonia.Text = empleado.colonia;
txtCp.Text = empleado.cp;
txtNoExt.Text = empleado.no_ext;
txtNoInt.Text = empleado.no_int;
txtReferencia.Text = empleado.referencia;
txtTelefono.Text = empleado.telefono;
dtFechaCon.Text = empleado.fecha_contratacion;
dtFechaNac.Text = empleado.fecha_nac;
cbEstado.Text = empleado.estado;
lbImg.Text = $"Imagen: {Path.GetFileName(imagePath)}";
}
private void label1_Click(object sender, EventArgs e)
{
}
private void button1_Click(object sender, EventArgs e)
{
OpenFileDialog openFileDialog1 = new OpenFileDialog();
openFileDialog1.Filter = "Archivos de imagen (*.jpg, *.jpeg, *.png, *.bmp)|*.jpg;*.jpeg;*.png;*.bmp";
openFileDialog1.Title = "Seleccionar imagen";
if (openFileDialog1.ShowDialog() == DialogResult.OK)
{
imagePath = openFileDialog1.FileName;
lbImg.Text = $"Imagen: {Path.GetFileName(imagePath)}";
}
}
private void pictureBox2_Click(object sender, EventArgs e)
{
Empleado empleadoNuevo = new Empleado(
empleado.idempleado,
txtNombre.Text,
txtApellido.Text,
txtCalle.Text,
dtFechaCon.Text,
cbEstado.Text,
txtColonia.Text,
txtCp.Text,
txtNoExt.Text,
txtNoInt.Text,
txtReferencia.Text,
dtFechaNac.Text,
txtTelefono.Text,
Path.GetFileName(imagePath));
if (service.actualizarEmpleado(empleadoNuevo))
{
if (!empleado.img.Equals(empleadoNuevo.img))
{
string destinationFolder = Path.Combine(Application.StartupPath, "Resources", "usuarios");
string destinationFile = Path.Combine(destinationFolder, Path.GetFileName(imagePath));
File.Copy(imagePath, destinationFile, true);
}
ventanaPadre.llenarPanel();
Close();
}
}
private void EditarEmpleado1_Load(object sender, EventArgs e)
{
}
private void pictureBox1_Click(object sender, EventArgs e)
{
this.Close();
}
private void PermitirSoloNumeros(object sender, KeyPressEventArgs e)
{
// Verificar si la tecla presionada no es un número o la tecla de retroceso
if (!char.IsDigit(e.KeyChar) && e.KeyChar != 8)
{
e.Handled = true; // Ignorar la tecla presionada
// Mostrar un mensaje indicando que solo se permiten números
MessageBox.Show("Por favor, ingrese solo números.", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
}
}
private void PermitirSoloLetras(object sender, KeyPressEventArgs e)
{
// Verificar si la tecla presionada no es una letra o la tecla de retroceso
if (!char.IsLetter(e.KeyChar) && e.KeyChar != 8 && e.KeyChar != 32)
{
e.Handled = true; // Ignorar la tecla presionada
// Mostrar un mensaje indicando que solo se permiten letras
MessageBox.Show("Por favor, ingrese solo letras.", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
}
}
}
}
+120
View File
@@ -0,0 +1,120 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>
+25 -11
View File
@@ -35,7 +35,8 @@
this.button2 = new System.Windows.Forms.Button(); this.button2 = new System.Windows.Forms.Button();
this.button3 = new System.Windows.Forms.Button(); this.button3 = new System.Windows.Forms.Button();
this.button5 = new System.Windows.Forms.Button(); this.button5 = new System.Windows.Forms.Button();
this.stockPanel = new System.Windows.Forms.FlowLayoutPanel(); this.AdminPanel = new System.Windows.Forms.FlowLayoutPanel();
this.btnAgregar = new System.Windows.Forms.Button();
this.flowLayoutPanel1.SuspendLayout(); this.flowLayoutPanel1.SuspendLayout();
this.panel2.SuspendLayout(); this.panel2.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.pictureBox7)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.pictureBox7)).BeginInit();
@@ -149,22 +150,34 @@
this.button5.Text = "Salir"; this.button5.Text = "Salir";
this.button5.UseVisualStyleBackColor = false; this.button5.UseVisualStyleBackColor = false;
// //
// stockPanel // AdminPanel
// //
this.stockPanel.AutoScroll = true; this.AdminPanel.AutoScroll = true;
this.stockPanel.Location = new System.Drawing.Point(410, 233); this.AdminPanel.BackColor = System.Drawing.SystemColors.Control;
this.stockPanel.Margin = new System.Windows.Forms.Padding(4); this.AdminPanel.Location = new System.Drawing.Point(410, 233);
this.stockPanel.Name = "stockPanel"; this.AdminPanel.Margin = new System.Windows.Forms.Padding(4);
this.stockPanel.Size = new System.Drawing.Size(1109, 757); this.AdminPanel.Name = "AdminPanel";
this.stockPanel.TabIndex = 14; this.AdminPanel.Size = new System.Drawing.Size(1528, 757);
this.AdminPanel.TabIndex = 14;
//
// btnAgregar
//
this.btnAgregar.Font = new System.Drawing.Font("Microsoft Sans Serif", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnAgregar.Location = new System.Drawing.Point(1084, 154);
this.btnAgregar.Name = "btnAgregar";
this.btnAgregar.Size = new System.Drawing.Size(120, 44);
this.btnAgregar.TabIndex = 15;
this.btnAgregar.Text = "Agregar";
this.btnAgregar.UseVisualStyleBackColor = true;
// //
// crud // crud
// //
this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 16F); this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 16F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(1677, 1037); this.ClientSize = new System.Drawing.Size(1942, 1037);
this.ControlBox = false; this.ControlBox = false;
this.Controls.Add(this.stockPanel); this.Controls.Add(this.btnAgregar);
this.Controls.Add(this.AdminPanel);
this.Controls.Add(this.flowLayoutPanel1); this.Controls.Add(this.flowLayoutPanel1);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None; this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;
this.Name = "crud"; this.Name = "crud";
@@ -188,6 +201,7 @@
private System.Windows.Forms.Button button2; private System.Windows.Forms.Button button2;
private System.Windows.Forms.Button button3; private System.Windows.Forms.Button button3;
private System.Windows.Forms.Button button5; private System.Windows.Forms.Button button5;
private System.Windows.Forms.FlowLayoutPanel stockPanel; private System.Windows.Forms.FlowLayoutPanel AdminPanel;
private System.Windows.Forms.Button btnAgregar;
} }
} }
+117 -1
View File
@@ -1,9 +1,11 @@
using compabetov2.database.modelos; using compabetov2.database;
using compabetov2.database.modelos;
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.ComponentModel; using System.ComponentModel;
using System.Data; using System.Data;
using System.Drawing; using System.Drawing;
using System.IO;
using System.Linq; using System.Linq;
using System.Text; using System.Text;
using System.Threading.Tasks; using System.Threading.Tasks;
@@ -14,10 +16,124 @@ namespace compabetov2.admin
public partial class crud : Form public partial class crud : Form
{ {
private LoginModel loginPrincipal; private LoginModel loginPrincipal;
private List<Producto> productos = new List<Producto>();
public crud() public crud()
{ {
InitializeComponent(); InitializeComponent();
llenarLayout();
}
private void llenarLayout()
{
productos = service.conseguirProductos();
foreach (Producto producto in productos)
{
TableLayoutPanel filaLayout = new TableLayoutPanel();
filaLayout.RowCount = 1;
filaLayout.ColumnCount = 2;
filaLayout.Height = 100;
filaLayout.Width = 1115;
filaLayout.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 50F));
filaLayout.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 50F));
filaLayout.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
TableLayoutPanel informacionProducto = new TableLayoutPanel();
informacionProducto.RowCount = 1;
informacionProducto.ColumnCount = 2;
informacionProducto.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 20F));
informacionProducto.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 80F));
informacionProducto.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
informacionProducto.Dock = DockStyle.Fill;
Label idProducto = new Label();
idProducto.Text = producto.idProducto.ToString();
idProducto.BackColor = Color.FromArgb(82, 82, 82);
idProducto.ForeColor = Color.White;
idProducto.AutoSize = true;
idProducto.Dock = DockStyle.Left;
PictureBox imagen = new PictureBox();
string rutaImg = Path.Combine(Application.StartupPath, "Resources", producto.img);
imagen.Image = Image.FromFile(rutaImg);
imagen.Dock = DockStyle.Fill;
imagen.BackgroundImageLayout = ImageLayout.Stretch;
imagen.SizeMode = PictureBoxSizeMode.Zoom;
imagen.Controls.Add(idProducto);
Label nombreStock = new Label();
nombreStock.Text = producto.nombre;
nombreStock.Font = new Font(nombreStock.Font.FontFamily, 18);
nombreStock.Dock = DockStyle.Fill;
nombreStock.TextAlign = ContentAlignment.MiddleCenter;
//panel de agregar stock
TableLayoutPanel agregarPanel = new TableLayoutPanel();
agregarPanel.Dock = DockStyle.Fill;
agregarPanel.RowCount = 1;
agregarPanel.ColumnCount = 3;
agregarPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 33F));
agregarPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 33F));
agregarPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 33F));
agregarPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
Button btnEditar = new Button();
btnEditar.Text = "Editar";
btnEditar.Font = new Font(btnEditar.Font.FontFamily, 20);
btnEditar.ForeColor = Color.White;
btnEditar.FlatStyle = FlatStyle.Flat;
btnEditar.FlatAppearance.BorderSize = 0;
btnEditar.BackColor = Color.FromArgb(33, 90, 255);
btnEditar.Dock = DockStyle.Fill;
btnEditar.Click += new EventHandler(delegate (object sender, EventArgs e)
{
});
Button btnVariante = new Button();
btnVariante.Text = "Variante";
btnVariante.Width = 60;
btnVariante.Height = 60;
btnVariante.Font = new Font(btnVariante.Font.FontFamily, 20);
btnVariante.ForeColor = Color.Black;
btnVariante.BackColor = Color.Yellow;
btnVariante.FlatStyle = FlatStyle.Flat;
btnVariante.FlatAppearance.BorderSize = 0;
btnVariante.Dock = DockStyle.Fill;
btnVariante.Click += new EventHandler(delegate (object sender, EventArgs e)
{
});
Button btnEliminar = new Button();
btnEliminar.Text = "Eliminar";
btnEliminar.Font = new Font(btnEliminar.Font.FontFamily, 20);
btnEliminar.ForeColor = Color.White;
btnEliminar.FlatStyle = FlatStyle.Flat;
btnEliminar.FlatAppearance.BorderSize = 0;
btnEliminar.BackColor = Color.Red;
btnEliminar.Dock = DockStyle.Fill;
btnEliminar.Click += new EventHandler(delegate (object sender, EventArgs e)
{
});
informacionProducto.Controls.Add(imagen, 0, 0);
informacionProducto.Controls.Add(nombreStock, 1, 0);
agregarPanel.Controls.Add(btnEditar, 0, 0);
agregarPanel.Controls.Add(btnVariante, 1, 0);
agregarPanel.Controls.Add(btnEliminar, 2, 0);
filaLayout.Controls.Add(informacionProducto, 0, 0);
filaLayout.Controls.Add(agregarPanel, 1, 0);
AdminPanel.Controls.Add(filaLayout);
}
} }
private void crud_Load(object sender, EventArgs e) private void crud_Load(object sender, EventArgs e)
Binary file not shown.
Binary file not shown.
@@ -1 +1 @@
057a07ff8f8a6f35d17720e1156a8cbeaa37ba3ef371419afc7a5a193cc76c5e 79223065a562d51344b7320aac98712da31ef35fad93e21c7ea9a1c9b5a40da5
@@ -150,3 +150,4 @@ C:\Users\Googl\Source\Repos\aspermaster23yeh\compabetoOG\obj\Debug\compabet.5C4A
C:\Users\Googl\Source\Repos\aspermaster23yeh\compabetoOG\obj\Debug\compabetov2.exe C:\Users\Googl\Source\Repos\aspermaster23yeh\compabetoOG\obj\Debug\compabetov2.exe
C:\Users\Googl\Source\Repos\aspermaster23yeh\compabetoOG\obj\Debug\compabetov2.pdb C:\Users\Googl\Source\Repos\aspermaster23yeh\compabetoOG\obj\Debug\compabetov2.pdb
C:\Users\Googl\Source\Repos\aspermaster23yeh\compabetoOG\obj\Debug\compabetov2.admin.crud.resources C:\Users\Googl\Source\Repos\aspermaster23yeh\compabetoOG\obj\Debug\compabetov2.admin.crud.resources
C:\Users\carsu\source\repos\compabetoOG\obj\Debug\compabetov2.admin.crud.resources
Binary file not shown.
Binary file not shown.
Binary file not shown.