Exemplo n.º 1
0
    public iDelegate GetDelegate(string deptCode)
    {
        Delegation delegation = delegateAuthorityController.getDelegatedEmployeeForDept(deptCode);
        String     sDate      = delegation.StartDate.ToString();
        String     eDate      = delegation.EndDate.ToString();
        iDelegate  idelegate  = new iDelegate();

        DateTime s = (DateTime)delegation.StartDate;
        DateTime d = (DateTime)delegation.EndDate;



        idelegate.EmployeeID = delegation.EmployeeID;

        idelegate.EmployeeName = delegation.Employee.EmployeeName;
        idelegate.StartDate    = s.ToShortDateString().Replace("/", "-");
        idelegate.EndDate      = d.ToShortDateString().Replace("/", "-");

        return(idelegate);
    }