SPForm with DashBoard

Hi!
I have a DateTime control on my SPForm form.
I Add to this form the DashBoard, which has been built on SharePoint list. So i got a CAML like this


2015-12-05T00:00:00.000Z






<GroupBy GroupLimit="30" Collapse="TRUE">
  <FieldRef Name="Author" />
</GroupBy>
<OrderBy>
  <FieldRef Name="ID" />
</OrderBy>
3000

How could i add the CAML to dashboard, using the Javascript, for rebuilding the dash dynamically?
Could you show some examples with javascript functions for rebuliding the dash?

Tnx

Hi,
Sure, here is an example where the CAML-query changes dynamically from JS-code:
http://www.spchart.com/demo/helpdesk-dashboard
http://www.spchart.com/demo/helpdesk-dashboard/config