public JsonResult CheckDuplicateAgentName(string AgentName)
        {
            bool flag;

            flag = _agentProvider.CheckDuplicateAgentname(AgentName);

            JsonResult res = new JsonResult
            {
                Data = flag
            };

            return(res);
        }