Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

JS code collects data

2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >

Share

Shulou(Shulou.com)06/03 Report--

I am a bird of interest to JS code, but sometimes I must use it to make FR reports, otherwise it will not achieve the desired results. Now I organize the code used for a rainy day.

1. Make a folding effect in the report interface. For example, there is a text-calculation description. When you click on the calculation description, you will expand the specific calculation method for users' reference. If you click on it again, you will put it away, as shown in the following picture:

JS code

$("# r toggle 1-0"). Toggle (); $("# r toggle 2-0"). Toggle (); if (contentPane.curLGP.$editor) {contentPane.curLGP.$editor.toggle ();}

There is no need to write the js method, as shown below:

In C1 cell, use the formula = if ($toggle! = null & & $toggle = "fold", "expand", "fold")

Then add a hyperlink-> dynamic parameter to C1, passing a parameter name toggle with a value of formula $

Then add a conditional attribute to the cell that needs to be hidden. The row height is zero and the condition is set to the formula $toggle! = null & & $toggle = "fold".

2. Submit event _ g ('${sessionID}'). VerifyAndWriteReport () after verification

3. Print _ g ('${sessionID}') .flashPrint ()

4. Output _ g ('${sessionID}') .exportReportToExcel ()

5. Email _ g ('${sessionID}') .emailReport ()

6. Call the second query

Var a=contentPane.curLGP.getCellValue ("F2"); if (aversion 6) {window.form = this.options.form; / / assign the form of the parameter interface to the global variable var $iframe = $(""); / / the naming of the iframe parameter and the width and height $iframe.attr ("src", "${servletURL}? reportlet=wuliaorenwen.cpt&op=write") / / the second template .cpt for the above click select button, quote js and pop up a dialog box, the dialog box embedded drop-down option template var o = {title: "^ _ ^ Please select the item with the cursor first, and then click OK." , width: 650 o.width height: 550}; FR.showDialog (o.title, o.width, o.height, $iframe,o); / / first pop-up dialog box} else {alert ("Please put the cursor over the item code line and click to see!") }

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Internet Technology

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report