Help new

This sub-forum is for discussing all topics related to AppGini Helper JavaScript Library, provided by bizzworxx as a third-party AppGini plugin.
Post Reply
pasbonte
Veteran Member
Posts: 162
Joined: 2013-02-06 09:49

Help new

Post by pasbonte » 2021-04-02 17:09

I just bought the java library.
I have deposited the AppGiniHelper.m.jsin file in HOOKS, I have created a DEBIT_HSE-dv.js file for example in hooks with as code:
// file: hooks / TABLENAME-tv.js
jQuery (document) .ready (function () {
AppGiniHelper.TV.addTitle (": This is custom text");
});

and nothing happens ..

User avatar
jsetzer
AppGini Super Hero
AppGini Super Hero
Posts: 1807
Joined: 2018-07-06 06:03
Location: Kiel, Germany
Contact:

Re: Help new

Post by jsetzer » 2021-04-02 18:21

  1. I just bought the java library
    I'm sure you mean Javascript, not Java, which is something completely different.
  2. I have deposited the AppGiniHelper.m.jsin file in HOOKS
    It should be AppGiniHelper.min.js by default.
    As a beginner, please don't rename the script-file unless you know what you are doing.
  3. Place that file in hooks-directory, don't rename hooks into HOOKS because changing the letter casing may lead to subsequent errors especially in LINUX environments.
  4. Did you include the script in hooks/header-extras.php?

    Code: Select all

    <script src="hooks/AppGiniHelper.min.js"></script>
    
  5. Don't forget to clear browser cache on reload because otherwise your browser may use an old (outdated) version of javascript or css files instead of reloading the latest version from the server.
    See troubleshooting guide (link below)
  6. Watch out for (red) errors in console tab of your browser's development tools.
    See troubleshooting guide (link below)

More help here

Get started:
https://appgini.bizzworxx.de/products/j ... etstarted/

Add title to TV:
https://appgini.bizzworxx.de/products/j ... add-title/

Troubleshooting guide:
https://appgini.bizzworxx.de/support/troubleshooting/
Kind regards,
<js />

My AppGini Blog:
https://appgini.bizzworxx.de/blog

You can help us helping you:
Please always put code fragments inside [code]...[/code] blocks for better readability

AppGini 24.10 Revision 1579 + all AppGini Helper tools

pasbonte
Veteran Member
Posts: 162
Joined: 2013-02-06 09:49

Re: Help new

Post by pasbonte » 2021-04-03 08:10

Hello
No I have all the files I have not changed the names ...
Do I need to create an additional file?
Ex:
// file: hooks / TABLENAME-tv.js
jQuery (document) .ready (function () {
AppGiniHelper.TV.addTitleHtml (": This is custom <b> HTML </b> text");
});
TABLENAME-tv.js ?

User avatar
onoehring
AppGini Super Hero
AppGini Super Hero
Posts: 1156
Joined: 2019-05-21 22:42
Location: Germany
Contact:

Re: Help new

Post by onoehring » 2021-04-03 08:58

Hi,
see Jans's point 4 above. You need to add that code into the existing file - as he described.

Olaf

pasbonte
Veteran Member
Posts: 162
Joined: 2013-02-06 09:49

Re: Help new

Post by pasbonte » 2021-04-03 11:47

Hello I did point 4

User avatar
aarlauskas
Veteran Member
Posts: 127
Joined: 2019-04-28 18:03
Location: Medway, UK

Re: Help new

Post by aarlauskas » 2021-04-03 20:21

Hi, yes the code goes into your TABLENAME-tv.js DON’T put this code into your TABLENAME-dv.js (DEBIT_HSE-dv.js) as the code you trying to run is for Table View, not detail VIEW. If you don’t have TABLENAME-tv.js then create one.

Code: Select all

//Custom Text
jQuery(document).ready(function() {
  AppGiniHelper.TV.addTitleHtml(": This is custom <b>HTML</b> text");
});
custome_name.JPG
custome_name.JPG (21.65 KiB) Viewed 2140 times

pasbonte
Veteran Member
Posts: 162
Joined: 2013-02-06 09:49

Re: Help new

Post by pasbonte » 2021-04-04 09:57

Bonjour !!!!
Merci merci !!!

I understood the difference between TV and DV T-TABLE, D-DETAIL

NOW,
How did we fit two functions?

file: hooks/TABLENAME-tv.js
jQuery (document).ready (function)
AppGiniHelper.TV.addTitle (": Table of HSE PONSARD");

var dv - new AppGiniDetailView();
var actionbuttons - dv.actionbuttons;
var grp - actionbuttons .addGroup ("Kalkulation," "cog");
var id - dv.getSelectedId();
var href - "calculations_tree.php? SelectedID" - id;

grp.addLink ("PDF," href, Variation.primary, "align-left");

});

jQuery (function)
var tv - new AppGiniTableView();
tv.addButton (function (id)
{
alert ("User clicked" - id);
"flash," "My function");
"flash" is the name of the glyphicon
"My function" is the button text

User avatar
onoehring
AppGini Super Hero
AppGini Super Hero
Posts: 1156
Joined: 2019-05-21 22:42
Location: Germany
Contact:

Re: Help new

Post by onoehring » 2021-04-05 06:57

Hi pasbonte,

please use the [ code ] tag to write code, it makes it much easier to read.
Your last code is missing a closing } (and may contain more syntax errors) or it was just forgotten? Please be very precise when posting code that does not work - a single missing } might make a huge difference.

Did you check your console window (F12) for any errors?

Olaf

Post Reply