fix docs add optvalues
[roojs1] / docs / symbols / Roo.data.Record.json
index 2dc9847..88a981d 100644 (file)
@@ -25,7 +25,7 @@
     {
       "name" : "id",
       "type" : "Object",
-      "desc" : "(Optional) The id of the record. This id should be unique, and is used by the\n{@link Roo.data.Store} object which owns the Record to index its collection of Records. If\nnot specified an integer id is generated.",
+      "desc" : "The id of the record. This id should be unique, and is used by the\n{@link Roo.data.Store} object which owns the Record to index its collection of Records. If\nnot specified an integer id is generated.",
       "isOptional" : false
     }
   ],
         {
           "name" : "o",
           "type" : "Array",
-          "desc" : "An Array of field definition objects which specify field names, and optionally,\ndata types, and a mapping for an {@link Roo.data.Reader} to extract the field's value from a data object.\nEach field definition object may contain the following properties: <ul>\n<li><b>name</b> : String<p style=\"margin-left:1em\">The name by which the field is referenced within the Record. This is referenced by,\nfor example the <em>dataIndex</em> property in column definition objects passed to {@link Roo.grid.ColumnModel}</p></li>\n<li><b>mapping</b> : String<p style=\"margin-left:1em\">(Optional) A path specification for use by the {@link Roo.data.Reader} implementation\nthat is creating the Record to access the data value from the data object. If an {@link Roo.data.JsonReader}\nis being used, then this is a string containing the javascript expression to reference the data relative to \nthe record item's root. If an {@link Roo.data.XmlReader} is being used, this is an {@link Roo.DomQuery} path\nto the data item relative to the record element. If the mapping expression is the same as the field name,\nthis may be omitted.</p></li>\n<li><b>type</b> : String<p style=\"margin-left:1em\">(Optional) The data type for conversion to displayable value. Possible values are\n<ul><li>auto (Default, implies no conversion)</li>\n<li>string</li>\n<li>int</li>\n<li>float</li>\n<li>boolean</li>\n<li>date</li></ul></p></li>\n<li><b>sortType</b> : Mixed<p style=\"margin-left:1em\">(Optional) A member of {@link Roo.data.SortTypes}.</p></li>\n<li><b>sortDir</b> : String<p style=\"margin-left:1em\">(Optional) Initial direction to sort. \"ASC\" or \"DESC\"</p></li>\n<li><b>convert</b> : Function<p style=\"margin-left:1em\">(Optional) A function which converts the value provided\nby the Reader into an object that will be stored in the Record. It is passed the\nfollowing parameters:<ul>\n<li><b>v</b> : Mixed<p style=\"margin-left:1em\">The data value as read by the Reader.</p></li>\n</ul></p></li>\n<li><b>dateFormat</b> : String<p style=\"margin-left:1em\">(Optional) A format String for the Date.parseDate function.</p></li>\n</ul>\n<br>usage:<br><pre><code>\nvar TopicRecord = Roo.data.Record.create(\n    {name: 'title', mapping: 'topic_title'},\n    {name: 'author', mapping: 'username'},\n    {name: 'totalPosts', mapping: 'topic_replies', type: 'int'},\n    {name: 'lastPost', mapping: 'post_time', type: 'date'},\n    {name: 'lastPoster', mapping: 'user2'},\n    {name: 'excerpt', mapping: 'post_text'}\n);\n\nvar myNewRecord = new TopicRecord({\n    title: 'Do my job please',\n    author: 'noobie',\n    totalPosts: 1,\n    lastPost: new Date(),\n    lastPoster: 'Animal',\n    excerpt: 'No way dude!'\n});\nmyStore.add(myNewRecord);\n</code></pre>",
+          "desc" : "An Array of field definition objects which specify field names, and optionally,\ndata types, and a mapping for an {@link Roo.data.Reader} to extract the field's value from a data object.\nEach field definition object may contain the following properties: <ul>\n<li><b>name</b> : String<p style=\"margin-left:1em\">The name by which the field is referenced within the Record. This is referenced by,\nfor example the <em>dataIndex</em> property in column definition objects passed to {@link Roo.grid.ColumnModel}</p></li>\n<li><b>mapping</b> : String<p style=\"margin-left:1em\"> A path specification for use by the {@link Roo.data.Reader} implementation\nthat is creating the Record to access the data value from the data object. If an {@link Roo.data.JsonReader}\nis being used, then this is a string containing the javascript expression to reference the data relative to \nthe record item's root. If an {@link Roo.data.XmlReader} is being used, this is an {@link Roo.DomQuery} path\nto the data item relative to the record element. If the mapping expression is the same as the field name,\nthis may be omitted.</p></li>\n<li><b>type</b> : String<p style=\"margin-left:1em\"> The data type for conversion to displayable value. Possible values are\n<ul><li>auto (Default, implies no conversion)</li>\n<li>string</li>\n<li>int</li>\n<li>float</li>\n<li>boolean</li>\n<li>date</li></ul></p></li>\n<li><b>sortType</b> : Mixed<p style=\"margin-left:1em\"> A member of {@link Roo.data.SortTypes}.</p></li>\n<li><b>sortDir</b> : String<p style=\"margin-left:1em\"> Initial direction to sort. \"ASC\" or \"DESC\"</p></li>\n<li><b>convert</b> : Function<p style=\"margin-left:1em\"> A function which converts the value provided\nby the Reader into an object that will be stored in the Record. It is passed the\nfollowing parameters:<ul>\n<li><b>v</b> : Mixed<p style=\"margin-left:1em\">The data value as read by the Reader.</p></li>\n</ul></p></li>\n<li><b>dateFormat</b> : String<p style=\"margin-left:1em\"> A format String for the Date.parseDate function.</p></li>\n</ul>\n<br>usage:<br><pre><code>\nvar TopicRecord = Roo.data.Record.create(\n    {name: 'title', mapping: 'topic_title'},\n    {name: 'author', mapping: 'username'},\n    {name: 'totalPosts', mapping: 'topic_replies', type: 'int'},\n    {name: 'lastPost', mapping: 'post_time', type: 'date'},\n    {name: 'lastPoster', mapping: 'user2'},\n    {name: 'excerpt', mapping: 'post_text'}\n);\n\nvar myNewRecord = new TopicRecord({\n    title: 'Do my job please',\n    author: 'noobie',\n    totalPosts: 1,\n    lastPost: new Date(),\n    lastPoster: 'Animal',\n    excerpt: 'No way dude!'\n});\nmyStore.add(myNewRecord);\n</code></pre>",
           "isOptional" : false
         }
       ],