<ul>
    {if isset($add2inforightbtns) && $add2inforightbtns === 'info_right_offers_management_button'}
        {* ------------------------------------------------------------------------------------------- *}
        {* ------------------------------------- Offer / Angebot ------------------------------------- *}
        {* ------------------------------------------------------------------------------------------- *}
        {if $offer->offer_type==1 || $offer->offer_type==3}
            {if !$offer->is_calcexp && $can_add_edit_del}
                {include file="r_basic/functionmenuitem.tpl" title=$i.offers_management_duplicate_component
                    icon="copy" action="offers_management.duplicate('{$offer->id}');"}                        
            {/if}
        
            {if !empty($offer->related_offer)}
                {if $offer->related_offer->status==20 && $has_calcexp_right}
                    {include file="r_basic/functionmenuhrefitem.tpl" title=$i.projectadmin_collective_calcexp_level_of_completion icon="calc_from_expenses_hon"
                        action={site_url url="start/open/calculateaccordingexpenditure/index/`$xjxcookie`/level_of_completion/`$project->id`/`$offer->related_offer->id`"}}
                {/if}
                {if $has_calcexp_right}
                    {include file="r_basic/functionmenuitem.tpl" title=$i.projectadmin_view_open_calcexp_for_collective_offer
                        icon="calc_from_expenses_hon" action="javascript:fullPopup.view('projectadmin_offers_management', 'view_open_calcexp', {$offer->related_offer->id})"}
                    {include file="r_basic/functionmenuitem.tpl" title=$i.projectadmin_view_closed_calcexp_for_collective_offer
                        icon="calc_from_expenses_hon" action="javascript:fullPopup.view('projectadmin_offers_management', 'view_closed_calcexp', {$offer->related_offer->id})"}
                {/if}
                {include file="r_basic/functionmenuhrefitem.tpl" title=$i.offers_management_offer_component2corr
                    icon="correspondence" action={site_url url="start/open/correspondence/index/`$xjxcookie`/offer_component2corr/`$offer->id`"}}
                {include file="r_basic/functionmenuhrefitem.tpl" title=$i.offers_management_collective_offer2corr
                    icon="correspondence" action={site_url url="start/open/correspondence/index/`$xjxcookie`/collective_offer2corr/`$offer->related_offer->id`"}}
            {else}
                {include file="r_basic/functionmenuhrefitem.tpl" title=$i.offers_management_offer_component2corr
                    icon="correspondence" action={site_url url="start/open/correspondence/index/`$xjxcookie`/offer_component2corr/`$offer->id`"}}
            {/if}
            
        {else}
            {if !$offer->is_calcexp && $can_add_edit_del}
                {include file="r_basic/functionmenuitem.tpl" title=$i.offers_management_duplicate
                    icon="copy" action="offers_management.duplicate('{$offer->id}');"}                        
            {/if}

            {if $offer->status==20 && $has_calcexp_right}
                {include file="r_basic/functionmenuhrefitem.tpl" title=$i.projectadmin_calcexp_level_of_completion icon="calc_from_expenses_hon"
                    action={site_url url="start/open/calculateaccordingexpenditure/index/`$xjxcookie`/level_of_completion/`$project->id`/`$offer->id`"}}
            {/if}
            {if $has_calcexp_right}
                {include file="r_basic/functionmenuitem.tpl" title=$i.projectadmin_view_open_calcexp_for_offer
                    icon="calc_from_expenses_hon" action="javascript:fullPopup.view('projectadmin_offers_management', 'view_open_calcexp', {$offer->id})"}
                {include file="r_basic/functionmenuitem.tpl" title=$i.projectadmin_view_closed_calcexp_for_offer
                    icon="calc_from_expenses_hon" action="javascript:fullPopup.view('projectadmin_offers_management', 'view_closed_calcexp', {$offer->id})"}
            {/if}

            {if empty({$offer->address_id})}
                {include file="r_basic/functionmenuitem.tpl" title=$i.offers_management_offer2corr
                    icon="correspondence" action="alert('`$i.offers_management_no_address`');"}
            {else}
                {include file="r_basic/functionmenuhrefitem.tpl" title=$i.offers_management_offer2corr
                    icon="correspondence" action={site_url url="start/open/correspondence/index/`$xjxcookie`/offer2corr/`$offer->id`"}}
                {if $offer->offer_type==2}
                    {include file="r_basic/functionmenuhrefitem.tpl" title=$i.offers_management_collective_offer2corr
                        icon="correspondence" action={site_url url="start/open/correspondence/index/`$xjxcookie`/collective_offer2corr/`$offer->id`"}}
                {/if}
            {/if}
        {/if}
        
        {if isset($hoai_butler_action)}
            {include file="r_basic/functionmenuitem.tpl" title="`$i.basic_portlets`: {if isset($i.com_untermstrich_hoai_title)}{$i.com_untermstrich_hoai_title}{else}HOAI{/if}"
            icon="" action=$hoai_butler_action}
        {/if}
        
        <li style="margin-top: 1px; margin-bottom: 1px;"><hr /></li>

        {* ------------------------------------------------------------------------------------------- *}
        {* ------------------------------------ Project / Projekt ------------------------------------ *}
        {* ------------------------------------------------------------------------------------------- *}
        {if $has_admin_medium_right}
            {include file="r_basic/functionmenuitem.tpl" title=$i.projectadmin_edit
                icon="edit" action="projectadmin.open({$project->id}, false, '');"}
        {/if}
    {/if}

    {if $has_admin_medium_right || $allow_addi_edit_no_right}
        {include file="r_basic/functionmenuitem.tpl" title=$i.basic_edit_addi
            icon="edit_simple" action="basicForm.edit_addi.open('projectadmin', '{$project->id}');"}
    {/if}
    
    {if $has_mgmt_right}
        {include file="r_basic/functionmenuitem.tpl" title=$i.projectadmin_work_package_record
            icon="work_area_overview" action="javascript:fullPopup.view('work_packages', 'index', {$project->id})"}

        {include file="r_basic/functionmenuitem.tpl" title=$i.projectadmin_quick_interface
            icon="work_area_overview" action="projectadmin.open_quick_interface({$project->id});"}
    {/if}

    {if !isset($add2inforightbtns) || $add2inforightbtns !== 'info_right_offers_management_button'}
        {if $has_mgmt_right}
            {include file="r_basic/functionmenuitem.tpl" title=$i.offers_management_offers_management
                icon="" action="projectadmin.load_offers_management({$project->id});" class="change_to_project_offers_button"}
        {/if}    
    {/if}
    
    {include file="r_basic/functionmenuitem.tpl" title=$i.projectadmin_level_of_completion
        icon="percent" action="projectadmin.open_level_of_completion({$project->id});"}
    
    {include file="r_basic/functionmenuitem.tpl" title=$i.projectadmin_staff_projects
        icon="staffadmin" action="staff_projects.open({$project->id});"}
        
    {include file="r_basic/functionmenuitem.tpl" title=$i.projectadmin_participants2
        icon="addresses" action="projectadmin.open_participants({$project->id});"}
        
    {include file="r_basic/functionmenuitem.tpl" title=$i.projectadmin_task_descriptions_destinations
        icon="" action="task_descriptions_destinations.open({$project->id});"}

    {if $has_admin_right}
        {include file="r_basic/functionmenuitem.tpl" title=$i.projectadmin_measurements
            icon="" action="projectadmin_measurements.open({$project->id});"}
    {/if}

    {if $has_mgmt_right}
        {include file="r_basic/functionmenuitem.tpl" title=$i.projectadmin_is_calc_from_expenses
            icon="is_calc_from_expenses" action="projectadmin.open_calc_from_expenses({$project->id});"}
    {/if}
    {*        
    {include file="r_basic/functionmenuitem.tpl" title=$i.projectadmin_tab_fee_allocation
        icon="fee_allocations" action="projectadmin.open_fee_allocation({$project->id});"}

    {if $has_admin_medium_right}
        {include file="r_basic/functionmenuitem.tpl" title=$i.projectadmin_work_area_overview
            icon="work_area_overview" action="projectadmin.load_work_area_overview({$project->id});"}
    {/if}*}

    {*{if $has_mgmt_right}
        {include file="r_basic/functionmenuitem.tpl" title=$i.projectadmin_budget_plan
            icon="budget_plan" action="projectadmin.open_budget_plan({$project->id});"}
    {/if}*}
    {if $has_resource_planner_right}
        {include file="r_basic/functionmenuitem.tpl" title=$i.projectadmin_resource_planner
            icon="resplaner" action="javascript:fullPopup.view('resource_planner', 'index', {$project->id})"}
    {/if}
    
    {if $has_admin_medium_right}
        {include file="r_basic/functionmenuitem.tpl" title=$i.projectadmin_project_mail
            icon="" action="projectadmin_projectmail.open({$project->id});"}
    {/if}

    {if $user_can_allocate_companies}
        {include file="r_basic/functionmenuitem.tpl" title=$i.projectadmin_project_allocation
            action="projectadmin.load_project_allocation({$project->id});"}
    {/if}                 

    {if isset($add2inforightbtns) && $add2inforightbtns === 'info_right_offers_management_button'}
        {assign var="duplicate_lang" value="projectadmin_duplicate_project"}
    {else}    
        {assign var="duplicate_lang" value="projectadmin_duplicate"}
    {/if}    
    {if $is_project_favourite}
        {assign var="project_fav_lang" value="projectadmin_delete_from_favourites"}
        {assign var="project_fav_icon" value="favourite_list false"}
        {assign var="project_fav_func" value="delete({$project->id}, this)"}
    {else}    
        {assign var="project_fav_lang" value="projectadmin_add_to_favourites"}
        {assign var="project_fav_icon" value="favourite_list true"}
        {assign var="project_fav_func" value="save('', {$project->id}, true, this)"}
    {/if}    

    {if $has_admin_right}    
        {include file="r_basic/functionmenuitem.tpl" title=$i.$duplicate_lang
            icon="copy" action="projectadmin.duplicate({$project->id});"}                    
    {/if}   

    {if $has_admin_medium_right && !$filter_project_manager && !$filter_division_manager}
        {include file="r_basic/functionmenuitem.tpl" title=$i.projectadmin_add_to_project_group
            icon="" action="project_group_dialogs.view_add_proj_to_grp({$project->id});"}
    {/if}
    
    {include file="r_basic/functionmenuitem.tpl" title=$i.{$project_fav_lang}
        icon=$project_fav_icon action="manageProjects.$project_fav_func;"}

    {include file="r_basic/functionmenuhrefitem.tpl" title=$i.projectadmin_add_task_for_project icon="opentasks"
        action={site_url url="start/open/opentasks/index/`$xjxcookie`/add_for_project/`$project->id`"}}

    {include file="r_basic/functionmenuhrefitem.tpl" title=$i.projectadmin_add_perapp_for_project icon="personalappointmentplaner"
        action={site_url url="start/open/personalappointmentplaner/index/`$xjxcookie`/add_for_project/`$project->id`"}}

    {if $user_can_datacollection}
        {include file="r_basic/functionmenuitem.tpl" title=$i.projectadmin_project_info icon="datacollection"
            action=$datacollection_action}
    {/if}                    
</ul>
