Ejemplo n.º 1
0
        public void addEmployee(Eployee ep, string name, string salary, string department)
        {
            var cm = new ServiceReference1.Employee
            {
                Id         = ep.ID,
                Name       = ep.Name,
                Salary     = ep.Salary,
                Department = ep.Department,
            };

            client.AddEmployee(cm, name, salary, department);
        }
Ejemplo n.º 2
0
        private void button1_Click(object sender, EventArgs e)
        {
            int eid = Login.sessionId;

            Debug.WriteLine("+++" + eid);
            ServiceReference1.Leave    leave = new ServiceReference1.Leave();
            ServiceReference1.Employee emp   = client.GetEmployee(eid);
            leave.Type        = comboBox1.Text;
            leave.Description = des.Text;
            leave.Status      = "Pending...";
            if (client.ReqLeave(leave, eid))
            {
                label3.Text = "Leave requested";
            }
            else
            {
                label3.Text = "Something went wrong.";
            }
        }
Ejemplo n.º 3
0
 public System.Threading.Tasks.Task UpdateUserAsync(ServiceReference1.Employee emp)
 {
     return(base.Channel.UpdateUserAsync(emp));
 }
Ejemplo n.º 4
0
 public void UpdateUser(ServiceReference1.Employee emp)
 {
     base.Channel.UpdateUser(emp);
 }
Ejemplo n.º 5
0
 public ActionResult DeleteEmployee(string employeeId)
 {
     ServiceReference1.Employee employee = client.RetreiveEmployees(employeeId);
     return(View(employee));
 }
Ejemplo n.º 6
0
 public ActionResult EditEmployee(ServiceReference1.Employee employee)
 {
     client.UpdateEmployee(employee);
     return(RedirectToAction("ShowAllEmployeee"));
 }
Ejemplo n.º 7
0
 public ActionResult SaveEmployee(ServiceReference1.Employee employee)
 {
     client.AddEmployee(employee);
     return(View());
 }