JS Hide or Display the Parameter Panel

  • Last update:  2020-12-16
  • I. Overview

    1.1 Requirement

    How to display the parameter pane when switching to the first sheet and hide it when switching to other sheets?

    1.gif

     

    1.2 Solution

    $(".parameter-container-collapseimg-up").trigger("click");// Trigger the fold function to hide the parameter pane
    $(".parameter-container-collapseimg-down").trigger("click");}// Trigger the drop-down function to display the parameter pane
    You will learn
    • Sample

      • Steps

      • Preview

    • Download the template

    II. Sample

    2.1 Steps

    1)In the report design interface, add a button and create four sheets in the parameter pane, as shown below:

    2.png

    2) Click [Template]-[Web Attributes]-[Data Entry Settings] to add a Load End event:

    3.png 

    Input the following JavaScript codes:

    $(".fr-sheetbutton-container").click(function()//When switch between sheets
    {var a=contentPane.$contentPane.data('TabPane').tabBtns[contentPane.selectedIndex].options.name;// Get sheets’ names
    if(a=="Anna")
    {  
        $(".parameter-container-collapseimg-down").trigger("click");// Trigger the drop-down function to display the parameter pane
    }
    else{
        $(".parameter-container-collapseimg-up").trigger("click");//Trigger the fold function to hide the parameter pane
    }
    });

     

    2.2 Preview

    Save the template and click [Data Entry Preview]. The preview effect on a PC is shown as below:

    4.gif

     

    III. Download the template

    Attachment List


    Theme: Data Entry
    • Helpful
    • Not helpful
    • Only read

    滑鼠選中內容,快速回饋問題

    滑鼠選中存在疑惑的內容,即可快速回饋問題,我們將會跟進處理。

    不再提示

    10s後關閉

    Get
    Help
    Online Support
    Professional technical support is provided to quickly help you solve problems.
    Online support is available from 9:00-12:00 and 13:30-17:30 on weekdays.
    Page Feedback
    You can provide suggestions and feedback for the current web page.
    Pre-Sales Consultation
    Business Consultation
    Business: international@fanruan.com
    Support: support@fanruan.com
    Page Feedback
    *Problem Type
    Cannot be empty
    Problem Description
    0/1000
    Cannot be empty

    Submitted successfully

    Network busy