public ActionResult Update_AgentProfile(string Code) { Models.MaintenanceAgentProfile.AgentModel AgentModel = new Models.MaintenanceAgentProfile.AgentModel(); AgentModel.AgentProfile = setAgentProfile(service.getAgentProfilebyCode(Code)); var ID = AgentModel.AgentProfile.ID; AgentModel.AgentAddress = setAgentAddress(service.getAgentAddressByID(ID)); AgentModel.Gender = setGender(customerSvc.getGender()); AgentModel.CivilStatus = setCivilStatus(customerSvc.getCivilStatus()); AgentModel.District = setDistrict(customerSvc.getDistrict()); AgentModel.Organization = setOrganization(customerSvc.getOrganization()); AgentModel.Province = setProvince(customerSvc.getProvince()); AgentModel.City = setCity(service.getCity(ID)); AgentModel.AgentType = setAgentType(service.getAgentType()); AgentModel.HomeOwnership = setHomeOwnership(customerSvc.getHomeOwnership()); AgentModel.WithCashCard = setWithCashCard(); return(View(AgentModel)); }