您好,
请参考以下代码:
- var designer = new GC.Spread.Sheets.Designer.Designer(document.getElementById("gc-designer-container"));
- var fileMenuPanelTemplate = GC.Spread.Sheets.Designer.getTemplate(GC.Spread.Sheets.Designer.TemplateNames.FileMenuPanelTemplate);
- fileMenuPanelTemplate.content[0].children[0].children[0].children[0].children[1].items.splice(0, 1)
- fileMenuPanelTemplate.content[0].children[0].children[1].children.splice(0, 1)
- fileMenuPanelTemplate.content[0].children[0].children[0].children[0].children[1].items[0].value = "New"
- fileMenuPanelTemplate.content[0].children[0].children[1].children[0].visibleWhen = "activeCategory_main=New"
- GC.Spread.Sheets.Designer.registerTemplate(GC.Spread.Sheets.Designer.TemplateNames.FileMenuPanelTemplate, fileMenuPanelTemplate);
复制代码
|