Set the MINIUI Datagrid SetData errors JSON Error resolution method

Source: Internet
Author: User

background
The company purchased the MINIUI, when the existing Project table table, the official website API does not provide static data cases, resulting in various failures

Solution Solutions
The net forum, see someone said Grid.load () is relative to the URL to use, remove the good

How to use the correct SetData

     <div id= "DataGridTable"  class= "Mini-datagrid"  style= "width:100 %;min-height: 300px; "  allowresize= "true"  idfield= "id"  multiselect= "true"      showemptytext= "True"  emptytext= "Hello: System temporarily no data, please add!" ">        <div property=" >    "columns"          <div type= "Indexcolumn"  width= "ten"   headeralign= "center" > Serial number </div>                   <div field= "name"  width= " headeralign="   "center" Allowsort= "false" > name </div>             <div name= "Action"  width= " headeralign=", "Center"  align= "center"  renderer= " Onactionrenderer " cellstyle=" padding:0; " > Operation &LT;/DIV&GT;&NBSP;&NBsp;        </div>    </div>     var grid = mini.get ("DataGrid1");var data  = new  Array ();d Ata.push ({"Name": "Zhang San"});d Ata.push ({"Name": "John Doe"}); Grid.setdata ();


End

To complete the static setting, be careful not to use the load () method


Set the MINIUI Datagrid SetData errors JSON Error resolution method

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.