Jump to content
Greg.Buerk

Introduction to Custom Tabs

Recommended Posts

OverView

The CustomTabs plugin will allow you to add new tabs to most of labtechs screens. It can add multiple Tabs of information, webpages and dataviews.

 

Features

• Webbrowser , EDF, Lists and Dataview Tab Types.

• Replacements available for Parameters and commands.

• Add Multiple Commands to a Tab.

• Commands can be URL, Executable, LTCommand, SQL or LTScripts.

• Tabs Fully Brandable with Icons, Colors, Titles and Pictures.

• Tabs can be exported and shared.

• Permissions on Configurations, Tabs and commands.

 

 

 

Documenation

LOL, there is no Docs, ;)

 

Its pretty simple but like anything labtech very powerfull. First get it installed, then go to the CustomTabs in the Dashboard integrations. Click Add New Tab and start making a tab, when you are done you click Add New tab at the bottom. At this time the TABS are all reloaded so if you open the item that contains a tab, for example the computer screen, the NEW tab will be displayed. Remember you must REOPEN the item for it to update.

 

Creating a New Tab is easy aswell. you will only really need to pick a few things and be done. You need to Fill in the Tab Text(this is the Text of the new Tab), The Title and SubTitle text, Tab Placement(this is the screen the tab will go to), Tab Type and the Tab types configuration setting. This is It Nothing more is needed.

 

 

Tab Types

Web Page will show a embedded IE browser. The URL must be supplied. Press F2 to get a list of replacements for any of these values. PostData and headers are RAW input and are passed to the webserver as is.

 

EDF Field List will show the Info tab looking list of EDFs. The EDF List is either a Section Name or a Comma seperated list of EDF Guids. All Edfs must be from the same thing, so if this tab is a on a computer only computer EDFs will be allowed. ALSO this tab will NOT work anywhere that does not already have a INFO tab.

 

Data List is a List view of the columns supplied by a SQL query. The SQL Query is Required and is used to format the list. The First Column of the query will be not shown and used as the ID of the row, it must be a number. The rest of the columns are shown in the list with the column names used exactly as they appear in the SQL. Press F2 to get a list of replacements to use in the SQL.

 

Dataview is a LabTech Dataview. You select the dataview to show and optionaly you enter the additional Where. The additional Where is used to limit the dataview to show only the items you want, an example would be "Clients.ClientID=%ClientID%". You can use the replacements here as well.

 

 

Commands

You do not need to add any commands to a Tab but you can. To add a command clear the command area and enter a Name(displayed to the user), the type, and the parameters. Then click add, the command will enter the list, repeat for as many commands as you want. They will be save when you click SAVE TAB CONFIG.

 

Commands can each have an Icon and Permissions. Permissions determine who can see and use the new button. The Commands are shown in a Tool Strip command bar and this can be set to the top or bottom of the screen, it can also be turned OFF. If the Tab Type is a Data List you can tell the commands to be Menus and they will be right click menus on the list. When in this mode you can access the List Items ID and each column with replacements.

 

All Command parameters accept replacements press F2 to see.

 

Command Types

Run Command - Runs a Labtech Command, specify the CommandID and the Parameters.

Run Script- Queues a Labtech Script, specify the Script GUID and the Parameters.

Execute SQL - Runs the SQL Statement on the LT server, multiple statements seperated with ;

Run Executable - Runs the EXE on the Control Center Computer.

Open URL - Navigates to the URL, if this is a WebPage Tab then it uses the control to navigate, if it is not then it uses the builtin labtech browser to navigate. If the Use External is Checked it uses the Default browser on the computer.

 

The Command and Script command Types will run on a predetermined computer based on the tab type and the command location. So if its on a computer screen then the command will run on that computer. If the command is on a LIST then the comamnd will run on the ListItems ID, yes it uses the ID of the list item as a computerID, this is the FIRST column in your sql query. If the ComputerID Parameter is greater than 0 it will use this value instead. Otherwise the tablocation determines how its ran:

 

Commands

Computer Tab - Runs on that computer

From List View - Runs on that List Items ID

Anywhere else - Does NOT RUN.

 

Scripts

Computer Tab - Runs on that computer.

Locations Tab - Runs as Client script on that location.(can not be a computer script)

Clients Tab - Runs as Client Script on that Client.(can not be a computer script)

Groups Tab - Runs as Computer Script on that Group.

NetworkDevice Tab - Runs as Computer Script on the Probe.

From List View - Runs on that List Items ID as a computer script.

Anywhere else - Runs as a Maintenance Script with no association to client or Computer.(can not be a computer script)

 

 

Tab Sections

Tabs are seperated into sections and there is 6 sections. If a section has only ONE tab in it then the section is not shown and the tab is placed on the Top Level. If the section has more than one tab in it, then it will show the Section Tab with the section text and Icon and under it all the tabs will be located. If a tab is by itself and the Sort ORder of the Tab is set to 10 then the Section will be shown anyways.

 

 

 

 

Plugin v1.3.5

 

 

Changes

v1.3.5

Tested in 10.5

Fixed Script GUID Lookup

Added Error Messages to The Webpage Browse Events, helps in setting of urls and error reporting

Fixed Message when system has not been configured and dbagent needs restarted.

v1.3.4

Fixed Replacements in the SQL Fill for EDFS

v1.3.3

Fixed the Hide Address bar checkbox

The EDFS and Upper lever replacements are now available

Added Scrollbars to the EDF screens

Fixed the SQL Replacement type.

A Few various other fixes

v1.3.1

Script Guid will now work and accept both a GUID or an ID.

Script and Commands can now specify the ComputerID.

Added new Replacement, $SQL$$selectstatement$ , this will select a value and replace it.

Fixed the EDF Height not showing in the Split Type.

Extended Size of all parameters to 2048 characters.

v1.3

Added New MultiColumn EDF Tab.

Added New Multicolumn EDF tab with a Webpage on it.

Changed the behavior of the Webpage tab to allow pops for login but supress errors

Added option to WebPage Tab to Show a Address Bar.

Added User Agent to the URL request of the WebPage

Installer will now work remotely using http to connect.

v1.2.1

I guess i screwed the version up and jumped a whole minor version number.;)

Fixed the EDFS updating with a ZERO instead of the ID. So i effect it was setting the DEFAULT value for the EDF. You can see these and delete em from the dashboard\additional field defaults

Removed Script Error messages from the Webbrowser control

Section Config will handle a GDI image error and sdave nothing

v1.1

Fixed the Dataview and added the Where condition to the Query.

Configuration screen checks for tables to exist and warns you when its not there.

v1.0

Added an EDF Selector screen

Added more user variables to the replacements.

59ec942c2312d_6-18-201312-30-52PM.png.d1fb0a58736e89ca4769ace441bde2bb.png

59ec942c269d5_6-18-201312-37-36PM.png.8d97bb64d225bba2f9e90e6ce4492637.png

59ec942cc6fe6_8-6-201311-58-16AM.png.488f2aaa65439fe0f72e43e4dffec9ad.png

CustomTabsInstaller.zip

Edited by Guest

Share this post


Link to post
Share on other sites

Here it is Guys. And man its freaking awesome.

 

 

 

Tips:

Replacements are available, Press F2

Use Command Execute and use "Message:" as the Program, It will pop up a messagebox with the arguments replaced with variables, this helps in testing.

Its @ID@ for the ID of the item you are on(client,computer,etc)

All the TabData is Preloaded in memory, so changes are not noticed until the plugin reloads its cache.

When you save a Tab Configuration it will reload all the tab cache so you can open the item and immediatly see the new tab.

EDF Tabs have a section name or comma seperated list a GUIDs to display.

Some Picture type can cause the Windows GDI to crash so if you are having problems saving a picture then change its format to png.

The Export and Import are simple SQL Files so you can edit them and create larger imports, the import will take multipule tabs and process them correctly, the order of items in this file matters.

Share this post


Link to post
Share on other sites

So I couldn't wait. I installed on my 2012.1...and no dice at all. On my 2013, the integration tab is present, but just a gray screen. Let me know if there is any troubleshooting steps I can do. Thanks.

 

Jeff

Share this post


Link to post
Share on other sites

OK, Guys Sorry bout that. Its was compiled for 2013. I recompiled it and it works for 2012 as well. Also It did not create the proper tables.

 

If you enabled it and already got a Plugin_Labtech_CustomTabs table then you will either need to delete them all or add the one thats missing.

 

CREATE TABLE `plugin_labtech_customtabs_tabs` ( `TabID` INT(11) NOT NULL AUTO_INCREMENT, `TabText` VARCHAR(255) NOT NULL, `TabTitle` VARCHAR(255) NOT NULL, `TabSubtitle` VARCHAR(255) NOT NULL, `TabPlacement` INT(11) NOT NULL, `TabType` INT(11) NOT NULL, `TabSort` INT(11) NOT NULL, `BackColor` INT(11) NOT NULL, `ForeColor` INT(11) NOT NULL, `HighLightColor` INT(11) NOT NULL, `CommandBarAlign` INT(11) NOT NULL, `CommandBarShow` INT(11) NOT NULL, `CommandBarMenu` INT(11) NOT NULL, `ShowHeader` INT(11) NOT NULL, `TabImage` BLOB NOT NULL, `TabIcon` BLOB NOT NULL, `Permissions` VARCHAR(255) NOT NULL, `Parameter1` VARCHAR(1024) NOT NULL, `Parameter2` VARCHAR(255) NOT NULL, `Parameter3` VARCHAR(255) NOT NULL, `Parameter4` VARCHAR(255) NOT NULL, `TabSection` INT(11) NOT NULL, PRIMARY KEY (`TabID`)) ENGINE=INNODB DEFAULT CHARSET=utf8

Share this post


Link to post
Share on other sites
CREATE TABLE `plugin_labtech_customtabs_tabs` ( `TabID` INT(11) NOT NULL AUTO_INCREMENT, `TabText` VARCHAR(255) NOT NULL, `TabTitle` VARCHAR(255) NOT NULL, `TabSubtitle` VARCHAR(255) NOT NULL, `TabPlacement` INT(11) NOT NULL, `TabType` INT(11) NOT NULL, `TabSort` INT(11) NOT NULL, `BackColor` INT(11) NOT NULL, `ForeColor` INT(11) NOT NULL, `HighLightColor` INT(11) NOT NULL, `CommandBarAlign` INT(11) NOT NULL, `CommandBarShow` INT(11) NOT NULL, `CommandBarMenu` INT(11) NOT NULL, `ShowHeader` INT(11) NOT NULL, `TabImage` BLOB NOT NULL, `TabIcon` BLOB NOT NULL, `Permissions` VARCHAR(255) NOT NULL, `Parameter1` VARCHAR(1024) NOT NULL, `Parameter2` VARCHAR(255) NOT NULL, `Parameter3` VARCHAR(255) NOT NULL, `Parameter4` VARCHAR(255) NOT NULL, `TabSection` INT(11) NOT NULL, PRIMARY KEY (`TabID`)) ENGINE=INNODB DEFAULT CHARSET=utf8

 

Fantastic! It worked! :)

Share this post


Link to post
Share on other sites

Man, i am having problems keeping all these plugins straight. Ok the file is working now and is the current updated one. I tested the download to my server and the DLL included is 2012\2013 compatible and installs all 3 tables correctly.

Share this post


Link to post
Share on other sites

Updated Plugin to v1.1

Changes:

Added EDF Selector to configuration

Added more User variables to replacements.

Share this post


Link to post
Share on other sites

Greg,

 

The Export button on the Configuration tab for Export Section does not work. I am able to use the Export Tab on each tab individually without issue though.

 

Would be nice to be able to create a Website Tab for the Client Tab Placement that would allow us to call the client's website. Perhaps and EDF value that we specify on each client :D

 

I'm still figuring out the best way to take advantage of this tool, but liking what I'm seeing so far.

 

Good job Greg! Thanks.

Share this post


Link to post
Share on other sites

you guys can already do this in the plugin. the Replacements are available to all the parameters. so you can use variables as the URLS. So not only can you pass @ID@ but you can do %clientname% and %locationaddress%. Then you can also use the EDFS so if you have a edf on the client called website, the replacement would be %ecwebsite%.

 

PRESS F2 in the URL field, the list will appear, make sure you are on a placement that would have computer\client\location values.

 

ALSO The Export Section is not working yet, will complete soon, You can take a bunch of single tab exports and merge them in one file and the import will work.

 

This plugin will allow you to build bridges and integrations with other apps that are webages, remember you can add commands that call urls and pass replacements. You can GET or POST values to the sites as well.

Share this post


Link to post
Share on other sites

Thanks for the clarification Greg. I was able to resolve this on the Website per client tab. I am however, unable to get Dataviews to be client specific. As an example, I am trying to create a tab that shows offline agents for a specified client using the built in DV called Status/Offline Computers. Whenever I create the tab and specify the dataview, I am also specifying Additional Where arguements and have been unsuccessful. I have tried creating this with multiple dataviews with same results. Any suggestions or is this a bug. Thanks.

Share this post


Link to post
Share on other sites

Ok, II added a Computer Chassis Dataview to the Client Tab. And i Used this as an addtional condition.

Computers.ClientID=@ID@

 

And it just lists the clients computers.

 

Remember it depends on where you put the Tab on what replacements are available.

Also you MUST specify the table name when doing additonal conditions.

Share this post


Link to post
Share on other sites

Thanks Greg. I was able to get the DataView Offline Computers to show computers for the client site only using the Computers.ClientID=@ID@ as you suggested, however, the DataView is actually showing all computers for site, both online and offline. This is not the case when looking at the DataView itself. Do we need to pass additional MySQL statements to dataviews to narrow results when accessing through these custom tabs?

Share this post


Link to post
Share on other sites

Ohh i see to limit to just online or offlien you want to add

 

AND Date_add(NOW(),interval -10 minute)>Computers.LastContact

 

So complete it would be

Computers.ClientID=@ID@ AND Date_add(NOW(),interval -10 minute)>Computers.LastContact

Share this post


Link to post
Share on other sites

Thanks, you found a bug, I will get it updated real soon. The dataview part does not include the where part of the dataview. So they will look broken. YOu can supply the rest of the where or you can wait till i get it recompiled(as its already fixed)

Share this post


Link to post
Share on other sites

Thanks for all your hard work Greg. I appreciate all your efforts and helping me make the most of my LT Deployment. I do have one pimped LT server now. SWEEEET!

 

Adding in the full statement "Computers.ClientID=@ID@ AND Date_add(NOW(),interval -10 minute)>Computers.LastContact" for the additional WHERE did resolve my immediate issue. Thanks.

Share this post


Link to post
Share on other sites

As i said i will get this updated real soon so you do not have to do this. And maybe get the Section Export to work as well.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×