{assign var="update_action" value="onchange=\"project_directory_structure.tree.load()\""}

<form action="" method="post" class="ui-corner-all" style="clear:both;">
    <fieldset class="ui-widget-header ui-corner-all noborder">
        {include file='r/select.tpl' title="masterdatamanagement_project_structure"
            name="project_structure" filter_extra=$update_action
            list=$structure_list id="id" text="name" noempty=TRUE
            add_icons_file="add_new_project_directory_structure"
            default=$project_default_always}   
    </fieldset>
    {if count($structure_list) > 0}
        <fieldset <fieldset class="noborder">
            <a onclick="project_directory_structure.copy($('#project_structure').val());" class="dialog_make_text_btn ui-corner-all" style="line-height:100%;">
                <span class="dialog_make_btn16 ok ui-corner-all"></span>{$i.masterdatamanagement_project_dir_duplicate}
            </a>
        </fieldset>
    {/if}
</form>

{include file='r_forms/editable_popform.tpl' id="project_directory_structure"}
        {include file='Masterdatamanagement/projectadmin/edit_popform.tpl'}
    </div>
</form>

<div id="project_structure_tree" style="margin-top:20px">
</div>

{include file='r_forms/editable_popform.tpl' id="tree_node" js_object="project_directory_structure.tree"}
        {include file='Masterdatamanagement/projectadmin/edit_popform_tree_node.tpl'}
    </div>
</form>