json and ajax for activities report viewer