0

所以,这是我的代码:

var columns = [
    {
        label: 'Pic',
        field: 'filename',

    },
    {
        label: 'Pictype',
        field: 'filetype',
    },
    {
        label: 'Picsize', field: 'filesubtype',
    },
    {
        label: 'Price',
        field: 'picprice',

    },

];

ImageList = declare([Editor, ObjectStore, OndemandGrid, Selection], {
    columns: columns,
    getBeforePut: false,
    selectionMode: "none"
});
imageStore = new JsonRest({
    idProperty: "id",
    target:"somelink.php"
});
displayImages = function(collectionId, reload) {
    var query = {};
    var queryOptions = {};
    if ( ! imageList.store) {
        imageListPane.set('content', imageList);
        imageList.setStore(imageStore, query, queryOptions);
    } else {
        imageList.setQuery(query, queryOptions);
    }
    centerStack.selectChild(imageListPane);
}
parser.parse();
displayImages();

这段代码有什么问题?以前,我安装了 1.7,带有一个旧的 dgrid。我刚刚更新了所有内容。现在什么坏了?我什么都看不见...

我也有一些声明性的 dojo 代码:

<div
    data-dojo-type="dijit.MenuBar"
    data-dojo-props="region:'top', layoutPriority:2, style:'margin-top: 10px'">
        <div
            id="OrderButton"
            data-dojo-type="dijit.form.Button">
            <span>Post Order</span>
            <script type="dojo/on" data-dojo-event="Click">
                handleFinalizeOrder();
            </script>
        </div>
        <span class="right">Price</span><span id="results"></span>
</div>
<div
    data-dojo-id="centerStack"
    data-dojo-type="dijit.layout.StackContainer"
    data-dojo-props="style:'width:100%; height:100%'">
    <div
        data-dojo-id="dummyPane"
        data-dojo-type="dijit.layout.ContentPane"
        data-dojo-props="style:'width:100%; height:500px'">
    </div>
    <div
        data-dojo-id="imageListPane"
        data-dojo-type="dijit.layout.ContentPane">
        <div
            data-dojo-id="imageList"
            data-dojo-type="ImageList">
        </div>
    </div>
</div>
4

0 回答 0