示例#1
0
 protected void guardar_Click(object sender, EventArgs e)
 {
     BSNLYR.bsnssEmployee emp = new BSNLYR.bsnssEmployee();
     emp.guardarEmpleado(int.Parse(lbCod.Text), txtNombre.Text, txtApellido.Text,
                         txtCedula.Text, txtExtension.Text, txtFlota.Text,
                         txtDept.SelectedIndex + 1);
     Response.Redirect("Mantenimiento.aspx");
 }
示例#2
0
 protected void guardar_Click(object sender, EventArgs e)
 {
     BSNLYR.bsnssEmployee emp = new BSNLYR.bsnssEmployee();
     emp.guardarEmpleado(int.Parse(lbCod.Text), txtNombre.Text, txtApellido.Text,
                         txtCedula.Text, txtExtension.Text, txtFlota.Text,
                         txtDept.SelectedIndex + 1);
     Response.Redirect("Mantenimiento.aspx");
 }
示例#3
0
        protected void Button2_Click(object sender, EventArgs e)
        {
            int       parametro = 8;
            DataTable dtTable   = new DataTable();

            BSNLYR.bsnssEmployee emp = new BSNLYR.bsnssEmployee();
            dtTable = emp.ConsultarCliente(txtDept.SelectedValue, parametro);
            GridView1.DataSource = dtTable;
            GridView1.DataBind();
        }
示例#4
0
        protected void Button1_Click(object sender, EventArgs e)
        {
            int parametro = 0;

            if (DropDownList1.SelectedItem.Text == "Nombre")
            {
                parametro = 1;
            }


            if (DropDownList1.SelectedItem.Text == "Apellido")
            {
                parametro = 2;
            }


            if (DropDownList1.SelectedItem.Text == "Cedula")
            {
                parametro = 3;
            }

            if (DropDownList1.SelectedItem.Text == "Codigo Departamento")
            {
                parametro = 4;
            }

            if (DropDownList1.SelectedItem.Text == "Extension")
            {
                parametro = 5;
            }

            if (DropDownList1.SelectedItem.Text == "Flota")
            {
                parametro = 6;
            }
            if (DropDownList1.SelectedItem.Text == "General")
            {
                parametro = 8;
            }
            DataTable dtTable = new DataTable();

            BSNLYR.bsnssEmployee emp = new BSNLYR.bsnssEmployee();
            dtTable = emp.ConsultarCliente(TextBox1.Text, parametro);
            GridView1.DataSource = dtTable;
            GridView1.DataBind();
        }
示例#5
0
        protected void Button1_Click(object sender, EventArgs e)
        {
            int parametro = 0;

            if (DropDownList1.SelectedItem.Text == "Nombre")
            {
                parametro = 1;
            }

            if (DropDownList1.SelectedItem.Text == "Apellido")
            {
                parametro = 2;
            }

            if (DropDownList1.SelectedItem.Text == "Cedula")
            {
                parametro = 3;
            }

            if (DropDownList1.SelectedItem.Text == "Codigo Departamento")
            {
                parametro = 4;
            }

            if (DropDownList1.SelectedItem.Text == "Extension")
            {
                parametro = 5;
            }

            if (DropDownList1.SelectedItem.Text == "Flota")
            {
                parametro = 6;
            }
            if (DropDownList1.SelectedItem.Text == "General")
            {
                parametro = 8;
            }
               DataTable dtTable = new DataTable();
               BSNLYR.bsnssEmployee emp = new BSNLYR.bsnssEmployee();
               dtTable = emp.ConsultarCliente(TextBox1.Text, parametro);
               GridView1.DataSource = dtTable;
               GridView1.DataBind();
        }
示例#6
0
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                DataTable dtTable = new DataTable();
                BSNLYR.bsnssDept emp2 = new BSNLYR.bsnssDept();
                dtTable = emp2.consultarDept();
                txtDept.DataSource = dtTable;
                txtDept.DataTextField = "Departamentos";
                txtDept.DataValueField = "Departamentos";
                txtDept.DataBind();

                BSNLYR.bsnssEmployee emp = new BSNLYR.bsnssEmployee();
                emp.selectEmployee(Request["id"], 7);
                txtNombre.Text = emp.emp_nombre;
                txtApellido.Text = emp.emp_apellido;
                txtCedula.Text = emp.emp_cedula;
                txtExtension.Text = emp.emp_ext;
                txtFlota.Text = emp.emp_flota;
                txtDept.SelectedValue = emp.dept_id;
                lbCod.Text = int.Parse(emp.emp_id).ToString();
            }
        }
示例#7
0
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                DataTable        dtTable = new DataTable();
                BSNLYR.bsnssDept emp2    = new BSNLYR.bsnssDept();
                dtTable                = emp2.consultarDept();
                txtDept.DataSource     = dtTable;
                txtDept.DataTextField  = "Departamentos";
                txtDept.DataValueField = "Departamentos";
                txtDept.DataBind();

                BSNLYR.bsnssEmployee emp = new BSNLYR.bsnssEmployee();
                emp.selectEmployee(Request["id"], 7);
                txtNombre.Text        = emp.emp_nombre;
                txtApellido.Text      = emp.emp_apellido;
                txtCedula.Text        = emp.emp_cedula;
                txtExtension.Text     = emp.emp_ext;
                txtFlota.Text         = emp.emp_flota;
                txtDept.SelectedValue = emp.dept_id;
                lbCod.Text            = int.Parse(emp.emp_id).ToString();
            }
        }
示例#8
0
 protected void eliminar_Click(object sender, EventArgs e)
 {
     BSNLYR.bsnssEmployee emp = new BSNLYR.bsnssEmployee();
     emp.eliminarEmpleado(int.Parse(lbCod.Text));
     Response.Redirect("Mantenimiento.aspx");
 }
示例#9
0
 protected void eliminar_Click(object sender, EventArgs e)
 {
     BSNLYR.bsnssEmployee emp = new BSNLYR.bsnssEmployee();
     emp.eliminarEmpleado(int.Parse(lbCod.Text));
     Response.Redirect("Mantenimiento.aspx");
 }