headerpane.hbs customize for account module.

Hello

How can i  modify headerpane.hbs for acccount module.

i tried to add check boxes in Headerpane part of the account module.

i tried custom/modules/Accounts/clients/base/views/headerpane/headerpane.hbs

<div class="headerpane">

    <h1>

        {{#each meta.fields}}

            <span class="record-cell" data-type="{{type}}" data-name="{{name}}">

                <span class="table-cell-wrapper">

                    <span class="index" data-fieldname="{{name}}" data-index="">

                        {{field ../this model=../this.model}}

                    </span>

                </span>

            </span>

        {{/each}}

        <div class="btn-toolbar pull-right dropdown">

            {{#each meta.buttons}}

                {{field ../this}}

            {{/each}}

        </div>

    </h1>

   

</div>

<table width="100%" cellspacing="0" cellpadding="0" border="0">

    <form>

    <tr>

    <td colspan=5> 

            <fieldset style="text-align:left;border-bottom: 1px solid #98C6EA;border:1px solid #98C6EA;width: 50%;">

               <table width="100%" cellspacing="0" cellpadding="0" border="0" >

                <tr><td >                  

                     Name  

                        <input type="checkbox" name="account_name" id="account_name" {php} if($account_name == "on"){echo "CHECKED";}{/php}/>                      

                        </td></tr>

                     </form>

    </table>

but it is not working.

Parents Reply
  • Hi Bhavin,

    Okay I checked for 7.6.2.1.

    In order the change the headerpane, you need to clone

    ./clients/base/views/record/record.hbs

    to

    custom/modules/Accounts/clients/base/views/record/record.hbs

    and modify in between <div class="headerpane"> </div> tags. Have a look at this sample code;

    {{!--
    /*
     * Your installation or use of this SugarCRM file is subject to the applicable
     * terms available at
     * support.sugarcrm.com/.../.
     * If you do not agree to all of the applicable terms or do not have the
     * authority to bind the entity as an authorized representative, then do not
     * install or use this SugarCRM file.
     *
     * Copyright (C) SugarCRM Inc. All rights reserved.
     */
    --}}
    <div>
    {{#if model.isNotEmpty}}
        {{#if enableHeaderPane}}
            <div class="headerpane">
                <h1>
                    HERE ARE YOUR CHANGES
                </h1>
            </div>
        {{/if}}
    
    
        {{#if meta.useTabsAndPanels}}
        {{! if the first panel uses panels, then the rest use panels, so don't use tabview }}
            <div class="record tab-layout">
            {{#if meta.firstPanelIsTab}}
    .
    .
    .
    .
    
    
    

    Hope this helps.

    Best Regards

    Tevfik Tümer

    Developer Support Engineer

Children