Exemple #1
0
        public HttpResponseMessage GetZonalManager([FromBody] ZonalManagerSearchViewModel za)
        {
            ObjectResult <SEC_USERS_GET_ZONAL_AGENT_Result> res = db.SEC_USERS_GET_ZONAL_AGENT(za.Zonal_Name,
                                                                                               za.Zonal_Hrid, za.Zonal_Username, za.Zonal_Mobile, za.Zonal_Email,
                                                                                               za.Zonal_Dept, za.Zonal_Desig, za.Zonal_Parent, za.Zonal_User_Type,
                                                                                               za.Zonal_Thana, za.Zilla_No, za.Division_No);

            var result = res.Select(z => new
            {
                zonalno     = z.USER_NO,
                zonalname   = z.USER_FULL_NAME,
                zonalmobile = z.USER_MOBILE,
                zonalemail  = z.USER_EMAIL,
                zonalhremp  = z.HR_EMP_ID
            });

            return(Request.CreateResponse(HttpStatusCode.OK, result));
        }