^1640742919378
@
sname
GuideViewer
slabel
GuideViewer
sdescriptors
xworker.web.ControlSet
  @/@guideViewer
  sname
  guideViewer
  sdescriptors
  xworker.web.ControlSet/@SimpleControl
  sid
  guideViewer
    @/@guideViewer/@view
    sname
    view
    sbelongToHtml
    true
    stitle
    向导
    sstyle
    default
    shasHead
    false
    shasBottom
    false
    SotherHeads
#$@text#$@
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<script type="text/javascript" src="js/xworker/InnerBrowserUtil.js"></script>
<style type="text/css">
    #all-demos {

    }
    #all-demos dd {
        float:left;
        width: 200px;
        height:100px;
        margin:5px 5px 5px 10px;
        cursor:pointer;
        zoom:1;
    }
    #all-demos dd img {
        width:80px;
        height:90px;
        margin:5px 0 0 5px;
        float:left;
    }

    #all-demos dd div {
        float:left;
        width:110px;
        margin-top:10px;
    }

    #all-demos dd h4 {
        font-family:tahoma,arial,san-serif;
        color:#555;
        font-size:11px;
        font-weight:bold;
    }
    #all-demos dd p {
        color:#777;
        font-size:11px;
    }
    #all-demos dd.over {
        background: #F5FDE3 url(shared/extjs/images/sample-over.gif) no-repeat;
    }
    #loading-mask{
        position:absolute;
        left:0;
        top:0;
        width:100%;
        height:100%;
        z-index:20000;
        background-color:white;
    }
    #loading{
        position:absolute;
        left:45%;
        top:40%;
        padding:2px;
        z-index:20001;
        height:auto;
    }
    #loading a {
        color:#225588;
    }
    #loading .loading-indicator{
        background:white;
        color:#444;
        font:bold 13px tahoma,arial,helvetica;
        padding:10px;
        margin:0;
        height:auto;
    }
    #loading-msg {
        font: normal 10px arial,tahoma,sans-serif;
    }

    #all-demos .x-panel-body {
        background-color:#fff;
        border:1px solid;
        border-color:#fafafa #fafafa #fafafa #fafafa;
    }
    #sample-ct {
        border:1px solid;
        border-color:#dadada #ebebeb #ebebeb #dadada;
        padding:2px;
    }

    #all-demos h2 {
        border-bottom: 2px solid #99bbe8;
        cursor:pointer;
        padding-top:6px;
    }
    #all-demos h2 div {
        background:transparent url(../resources/images/default/grid/group-expand-sprite.gif) no-repeat 3px -47px;
        padding:4px 4px 4px 17px;
        color:#3764a0;
        font:bold 11px tahoma, arial, helvetica, sans-serif;
    }
    #all-demos .collapsed h2 div {
        background-position: 3px 3px;
    }
    #all-demos .collapsed dl {
        display:none;
    }
    .x-window {
        text-align:left;
    }
    #all-demos dd h4 span.new-sample{
        color: red;
    }

    #all-demos dd h4 span.updated-sample{
        color: blue;
    }

    #all-demos h5{
        cursor:pointer;
        padding-top:6px;
        font-size:11px;
    }
    </style>
#$@text#$@
    sdescriptors
    xworker.web.controls.SimpleControl/@view
    sid
    view
      @/@guideViewer/@view/@ExtJs
      sname
      ExtJs
      sdescriptors
      xworker.extjs.ExtHtmlWidgtes/@ExtJs
      sid
      ExtJs
        @/@guideViewer/@view/@ExtJs/@Code
        sname
        Code
        sdescriptors
        xworker.extjs.Items/@Code
        sid
        Code
        @/@guideViewer/@view/@ExtJs/@JsonStore
        sname
        JsonStore
        sdescriptors
        xworker.extjs.Stores/@JsonStore
        sid
        JsonStore
          @/@guideViewer/@view/@ExtJs/@JsonStore/@fields
          sname
          fields
          sdescriptors
          xworker.extjs.Ext.data.DataReader/@24399
          sid
          fields
        @/@guideViewer/@view/@ExtJs/@Viewport
        sname
        Viewport
        sdescriptors
        xworker.extjs.Items/@Viewport
        sid
        Viewport
          @/@guideViewer/@view/@ExtJs/@Viewport/@items
          sname
          items
          sdescriptors
          xworker.extjs.Ext.Container/@24354
          sid
          items
            @/@guideViewer/@view/@ExtJs/@Viewport/@items/@Panel
            sname
            Panel
            sdescriptors
            xworker.extjs.Items/@Panel
            sid
            Panel
              @/@guideViewer/@view/@ExtJs/@Viewport/@items/@Panel/@items
              sname
              items
              sdescriptors
              xworker.extjs.Ext.Container/@24354
              sid
              items
                @/@guideViewer/@view/@ExtJs/@Viewport/@items/@Panel/@items/@DataView1
                sname
                DataView
                slabel
                listDataView
                sdescriptors
                xworker.extjs.Items/@DataView
                sid
                DataView1
                  @/@guideViewer/@view/@ExtJs/@Viewport/@items/@Panel/@items/@DataView1/@tpl
                  sname
                  tpl
                  sdescriptors
                  xworker.extjs.Ext.DataView/@24535
                  sid
                  tpl
                    @/@guideViewer/@view/@ExtJs/@Viewport/@items/@Panel/@items/@DataView1/@tpl/@html
                    sname
                    html
                    sdescriptors
                    xworker.extjs.Ext.Template/@code1
                    sid
                    html
                  @/@guideViewer/@view/@ExtJs/@Viewport/@items/@Panel/@items/@DataView1/@store
                  sname
                  store
                  sdescriptors
                  xworker.extjs.Ext.DataView/@24534
                  sid
                  store
                @/@guideViewer/@view/@ExtJs/@Viewport/@items/@Panel/@items/@DataView
                sname
                DataView
                slabel
                girdDataView
                sdescriptors
                xworker.extjs.Items/@DataView
                sid
                DataView
                  @/@guideViewer/@view/@ExtJs/@Viewport/@items/@Panel/@items/@DataView/@tpl
                  sname
                  tpl
                  sdescriptors
                  xworker.extjs.Ext.DataView/@24535
                  sid
                  tpl
                    @/@guideViewer/@view/@ExtJs/@Viewport/@items/@Panel/@items/@DataView/@tpl/@html
                    sname
                    html
                    sdescriptors
                    xworker.extjs.Ext.Template/@code1
                    sid
                    html
                  @/@guideViewer/@view/@ExtJs/@Viewport/@items/@Panel/@items/@DataView/@store
                  sname
                  store
                  sdescriptors
                  xworker.extjs.Ext.DataView/@24534
                  sid
                  store
                  @/@guideViewer/@view/@ExtJs/@Viewport/@items/@Panel/@items/@DataView/@onClick
                  sname
                  onClick
                  sdescriptors
                  xworker.extjs.ExtThing/@thing
                  sid
                  onClick
              @/@guideViewer/@view/@ExtJs/@Viewport/@items/@Panel/@buttons
              sname
              buttons
              sdescriptors
              xworker.extjs.Ext.Panel/@25325
              sid
              buttons
                @/@guideViewer/@view/@ExtJs/@Viewport/@items/@Panel/@buttons/@Button1
                sname
                Button
                sdescriptors
                xworker.extjs.Items/@Button
                sid
                Button1
                  @/@guideViewer/@view/@ExtJs/@Viewport/@items/@Panel/@buttons/@Button1/@handler
                  sname
                  handler
                  sdescriptors
                  xworker.extjs.Ext.Button/@24224
                  sid
                  handler
                @/@guideViewer/@view/@ExtJs/@Viewport/@items/@Panel/@buttons/@Button3
                sname
                Button
                sdescriptors
                xworker.extjs.Items/@Button
                sid
                Button3
                  @/@guideViewer/@view/@ExtJs/@Viewport/@items/@Panel/@buttons/@Button3/@handler
                  sname
                  handler
                  sdescriptors
                  xworker.extjs.Ext.Button/@24224
                  sid
                  handler
                @/@guideViewer/@view/@ExtJs/@Viewport/@items/@Panel/@buttons/@Button
                sname
                Button
                sdescriptors
                xworker.extjs.Items/@Button
                sid
                Button
                  @/@guideViewer/@view/@ExtJs/@Viewport/@items/@Panel/@buttons/@Button/@handler
                  sname
                  handler
                  sdescriptors
                  xworker.extjs.Ext.Button/@24224
                  sid
                  handler
                @/@guideViewer/@view/@ExtJs/@Viewport/@items/@Panel/@buttons/@Button2
                sname
                Button
                sdescriptors
                xworker.extjs.Items/@Button
                sid
                Button2
                  @/@guideViewer/@view/@ExtJs/@Viewport/@items/@Panel/@buttons/@Button2/@handler
                  sname
                  handler
                  sdescriptors
                  xworker.extjs.Ext.Button/@24224
                  sid
                  handler
        @/@guideViewer/@view/@ExtJs/@Code1
        sname
        Code
        sdescriptors
        xworker.extjs.Items/@Code
        sid
        Code1
      @/@guideViewer/@view/@code
      sname
      code
      Scode
#$@text#$@
<div id="all-demos">
<script language="javascript">
function initPath(store){
    <#if requestBean.path?exists>
    store.load({params:{path:'${requestBean.path?if_exists}'}});
    <#else>
    store.load({params:{path:''}});
    </#if>
}
</script>
#$@text#$@
      sdescriptors
      xworker.html.base.container.childs/@code
      sid
      code
    @/@guideViewer/@success
    sname
    success
    stype
    form
    scontentType
    text/html;charset=UTF-8
    svalue
    xworker.ide.guide.functionsGuide.webControl.GuideViewer/@guideViewer/@view
    sdescriptors
    xworker.web.controls.SimpleControl/@result
    sid
    success
  @/@getGuideData
  sname
  getGuideData
  sdescriptors
  xworker.web.ControlSet/@SimpleControl
  sid
  getGuideData
    @/@getGuideData/@actions
    sname
    actions
    sdescriptors
    xworker.web.controls.SimpleControl/@actions
    sid
    actions
      @/@getGuideData/@actions/@doAction
      sname
      doAction
      sisSynchronized
      false
      sthrowException
      true
      suseOtherAction
      false
      svarScope
      Global
      sdisableGlobalContext
      false
      Scode
#$@text#$@
def path = requestBean.path;
nodes = [];
def fthing = world.getThing(path);

if(fthing == null){
    //XWorker/Core的优先先显示    
    def p = world.getThing("xworker.ide.config.functions");
    if(p != null){
        def node = ["childs":[], "id":"xworker_core"];
        node.title = p.metadata.label;            	  

        initNodeChild(p, node);
        nodes.add(node);
    }
    
    for(thingManager in world.getThingManagers()){
        def rootCategory = thingManager.getCategory(null);
        for(lv1Category in rootCategory.getCategorys()){
            for(lv2Category in rootCategory.getCategorys()){
                String categoryName = lv1Category.getSimpleName() + "." + lv2Category.getSimpleName();
                p = world.getThing(categoryName + ".config.functions");
                if(p != null){
                    def node = ["childs":[], "id":project.name + "_" + manager.getName()];
                    node.title = p.metadata.label;            	  
            
                    initNodeChild(p, node);
                    nodes.add(node);
                }
            }
        }
    }
}else{ 
    def node = ["title":fthing.metadata.label, "childs":[], "id":fthing.metadata.label];
    for(child in fthing.getAllChilds()){
        if(child.thingName != "node"){
            def item = [:];
            item.text = child.metadata.label;
            item.url = "action:xworker.swt.ide.worldexplorer.swt.functions.FunctionManager/@shell/@mainComposite/@actions/@execute?path=" + child.metadata.path;
            if(child.icon == null || child.icon == ""){
                item.icon = "file.gif";
            }else{
                item.icon = child.icon;
            }
            item.desc = child.metadata.description;
            item.isNode = "false";
            node.childs.add(item);
        }
    }
    nodes.add(node);
    
    //返回上级
    /*
    def item = [:];
    item.text = "返回上级";
    def parent = fthing.getParent();
    if(parent != null){
        item.url = parent.metadata.path;
    }else{
        item.url = "";
    }
    item.icon = "desktop.gif";
    item.isNode = "true";
    node.childs.add(item);
    */
    for(child in fthing.getAllChilds()){
        if(child.thingName == "node"){
            def cnode = ["title":child.metadata.label, "childs":[], "id":child.metadata.label];
            nodes.add(cnode);
            initNodeChild(child, cnode);
        }
    }
}

def initNodeChild(thing, node){
    for(child in thing.getAllChilds()){
        def item = [:];
        item.text = child.metadata.label;
        item.url = "action:xworker.swt.ide.worldexplorer.swt.functions.FunctionManager/@shell/@mainComposite/@actions/@execute?path=" + child.metadata.path;
        
        item.desc = child.metadata.description;
        if(child.thingName == "node"){
            item.isNode = "true";
            item.url = child.metadata.path;
            if(child.icon == null || child.icon == ""){
                item.icon = "folder.gif";
            }else{
                item.icon = child.icon;
            }
        }else{
            item.isNode = "false";
            if(child.icon == null || child.icon == ""){
                item.icon = "file.gif";
            }else{
                item.icon = child.icon;
            }
        }
        
        node.childs.add(item);
    }
}
#$@text#$@
      sinterpretationType
      Action
      sdescriptors
      xworker.lang.actions.Actions/@GroovyAction
      sid
      doAction
    @/@getGuideData/@view
    sname
    view
    sbelongToHtml
    false
    sstyle
    default
    shasHead
    false
    shasBottom
    false
    sotherHeads
    <meta http-equiv="content-type" content="text/html; charset=utf-8">
    sdescriptors
    xworker.web.controls.SimpleControl/@view
    sid
    view
      @/@getGuideData/@view/@code
      sname
      code
      Scode
#$@text#$@
[
<#list nodes as node>
{
    title: '${(node.title?js_string)?if_exists}',
    id: '${(node.id?js_string)?if_exists}',
    samples: [
    <#list node.childs as child>
    {
        text: '${(child.text?js_string)?if_exists}',
        url:  '${(child.url?js_string)?if_exists}',
        icon: '${(child.icon?js_string)?if_exists}',
        isNode: '${(child.isNode?js_string)?if_exists}',
        desc: '${(child.desc?js_string)?if_exists}'
    }<#if child_has_next>,</#if>
    </#list>
    ]
}<#if node_has_next>,</#if>
</#list>
]
#$@text#$@
      sdescriptors
      xworker.html.base.container.childs/@code
      sid
      code
    @/@getGuideData/@success
    sname
    success
    stype
    form
    scontentType
    text/plain;charset=utf-8
    svalue
    xworker.ide.guide.functionsGuide.webControl.GuideViewer/@getGuideData/@view
    sdescriptors
    xworker.web.controls.SimpleControl/@result
    sid
    success
  @/@test
  sname
  test
  sdescriptors
  xworker.web.ControlSet/@SimpleControl
  sid
  test
    @/@test/@view
    sname
    view
    sbelongToHtml
    false
    stitle
    测试
    sstyle
    default
    shasHead
    false
    shasBottom
    false
    sotherHeads
    <meta http-equiv="content-type" content="text/html; charset=utf-8">
    sdescriptors
    xworker.web.controls.SimpleControl/@view
    sid
    view
      @/@test/@view/@code
      sname
      code
      Scode
#$@text#$@
<html>
<head><title>向导</title>

<meta http-equiv="content-type" content="text/html; charset=utf-8">
    <style type="text/css">
    #all-demos {

    }
    #all-demos dd {
        float:left;
        width:300px;
        height:100px;
        margin:5px 5px 5px 10px;
        cursor:pointer;
        zoom:1;
    }
    #all-demos dd img {
        width:120px;
        height:90px;
        margin:5px 0 0 5px;
        float:left;
    }

    #all-demos dd div {
        float:left;
        width:160px;
        margin-left:10px;
    }

    #all-demos dd h4 {
        font-family:tahoma,arial,san-serif;
        color:#555;
        font-size:11px;
        font-weight:bold;
    }
    #all-demos dd p {
        color:#777;
    }
    #all-demos dd.over {
        background: #F5FDE3 url(shared/extjs/images/sample-over.gif) no-repeat;
    }
    #loading-mask{
        position:absolute;
        left:0;
        top:0;
        width:100%;
        height:100%;
        z-index:20000;
        background-color:white;
    }
    #loading{
        position:absolute;
        left:45%;
        top:40%;
        padding:2px;
        z-index:20001;
        height:auto;
    }
    #loading a {
        color:#225588;
    }
    #loading .loading-indicator{
        background:white;
        color:#444;
        font:bold 13px tahoma,arial,helvetica;
        padding:10px;
        margin:0;
        height:auto;
    }
    #loading-msg {
        font: normal 10px arial,tahoma,sans-serif;
    }

    #all-demos .x-panel-body {
        background-color:#fff;
        border:1px solid;
        border-color:#fafafa #fafafa #fafafa #fafafa;
    }
    #sample-ct {
        border:1px solid;
        border-color:#dadada #ebebeb #ebebeb #dadada;
        padding:2px;
    }

    #all-demos h2 {
        border-bottom: 2px solid #99bbe8;
        cursor:pointer;
        padding-top:6px;
    }
    #all-demos h2 div {
        background:transparent url(../resources/images/default/grid/group-expand-sprite.gif) no-repeat 3px -47px;
        padding:4px 4px 4px 17px;
        color:#3764a0;
        font:bold 11px tahoma, arial, helvetica, sans-serif;
    }
    #all-demos .collapsed h2 div {
        background-position: 3px 3px;
    }
    #all-demos .collapsed dl {
        display:none;
    }
    .x-window {
        text-align:left;
    }
    #all-demos dd h4 span.new-sample{
        color: red;
    }

    #all-demos dd h4 span.updated-sample{
        color: blue;
    }
    </style>
<link rel="stylesheet" type="text/css" href="${request.contextPath}/js/extjs/resources/css/ext-all.css">
<script type="text/javascript" src="${request.contextPath}/js/extjs/adapter/ext/ext-base.js"></script>
<script type="text/javascript" src="${request.contextPath}/js/extjs/ext-all-debug.js"></script>
<link rel="stylesheet" type="text/css" href="${request.contextPath}/js/extjs/ux/css/ux-all.css">
<script type="text/javascript" src="${request.contextPath}/js/extjs/ux/ux-all-debug.js"></script>        
<script type="text/javascript" src="${request.contextPath}/do?sc=xworker.ide.guide.functionsGuide.webControl.GuideViewer/@guideViewer/@view/@ExtJs"></script>
<script type="text/javascript" src="${request.contextPath}/do?sc=xworker.extjs.xw.remote.XorkerUtil"></script>
</head>
<body >
<div id="all-demos">
        </div>
    </body>
</html>
#$@text#$@
      sdescriptors
      xworker.html.base.container.childs/@code
      sid
      code
    @/@test/@success
    sname
    success
    stype
    form
    scontentType
    text/html;charset=UTF-8
    svalue
    xworker.ide.guide.functionsGuide.webControl.GuideViewer/@test/@view
    sdescriptors
    xworker.web.controls.SimpleControl/@result
    sid
    success
  @/@getParentPath
  sname
  getParentPath
  sdescriptors
  xworker.web.ControlSet/@SimpleControl
  sid
  getParentPath
    @/@getParentPath/@actions
    sname
    actions
    sdescriptors
    xworker.web.controls.SimpleControl/@actions
    sid
    actions
      @/@getParentPath/@actions/@doAction
      sname
      doAction
      sisSynchronized
      false
      sthrowException
      true
      suseOtherAction
      false
      svarScope
      Global
      sdisableGlobalContext
      false
      Scode
#$@text#$@
response.setContentType("text/plain; charset=utf-8");
def path = requestBean.path;
def thing = world.getThing(path);
def parent = null;
if(thing != null){
    parent = thing.getParent();
    if(parent != null){
        parent = parent.getParent();
    }
}
if(thing == null || parent == null || parent == thing){
    response.writer.print("");
}else{
    response.writer.print(parent.metadata.path);
}
#$@text#$@
      sdescriptors
      xworker.lang.actions.Actions/@GroovyAction
      sid
      doAction
