Assuming newtask is required, the following result was found.
v_ThisTimeZone); // // create the task at the same time as lead creation m_NewTask = Map(); m_NewTask.put("$se_module","Leads"); m_NewTask.put("Owner",r_LeadDetails.get("Owner").get("id")); m_NewTask.put("What_Id",p_LeadID);...