/// <summary>
 /// To update the agent material percentage
 /// </summary>
 /// <param name="agentMaterialPercentageDetails"></param>
 /// <returns></returns>
 public int UpdateAgentPercentage(AgentMaterialPercentageDTO agentMaterialPercentageDetails)
 {
     agentmaterialpercentage agentMaterialPercentageEntity = new agentmaterialpercentage();
     AutoMapper.Mapper.Map(agentMaterialPercentageDetails, agentMaterialPercentageEntity);
     ESalesUnityContainer.Container.Resolve<IGenericRepository<agentmaterialpercentage>>()
         .Update(agentMaterialPercentageEntity);
     return agentMaterialPercentageEntity.AMP_Id;
 }
        /// <summary>
        /// To save the agent material percentage
        /// </summary>
        /// <param name="agentMaterialPercentageDetails"></param>
        public void SaveAgentMaterialPercentage(AgentMaterialPercentageDTO agentMaterialPercentageDetails)
        {
            agentmaterialpercentage agentMaterialPercentageEntity = new agentmaterialpercentage();
            AutoMapper.Mapper.Map(agentMaterialPercentageDetails, agentMaterialPercentageEntity);

            ESalesUnityContainer.Container.Resolve<IGenericRepository<agentmaterialpercentage>>()
                .Save(agentMaterialPercentageEntity);
        }