Announcement

Collapse
No announcement yet.

bonsai zoom function

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • hofedijw
    replied
    I've tried unsuccessfully to get the bonsai zoom feature working with centreon 2. I can't get the cursor to change or the zoom select box to draw. I am hoping that someone has tried to fix this feature as it is really useful.

    Any suggestions?

    Leave a comment:


  • breakintheweb
    replied
    Looks like the latest version of Centreon broke the zoom functionality. Follow the final install directions above and do the following to regain the zoom in Centreon 1.4.

    The fix:

    remove the following from graphODS/graphODSServiceZoom.php
    # include js for zoombox
    include('./include/views/graphs/graphODS/zoombox.php');
    include('./include/views/graphs/graphODS/javascript.php');

    Leave a comment:


  • kurty100
    replied
    You can add also :

    Code:
    INSERT INTO `topology_JS` (`id_t_js`, `id_page`, `o`, `PathName_js`, `Init`) VALUES ('', 402, 'vz', './include/common/javascript/zoom.js', 'initBonsai');
    
    INSERT INTO `topology_JS` (`id_t_js`, `id_page`, `o`, `PathName_js`, `Init`) VALUES ('', 40210, 'vz', './include/common/javascript/zoom.js', 'initBonsai');
    And don't forget to modify the rights and the owner of the files :

    chmod 775 /usr/local/oreon/www/include/common/javascript/zoom.js
    chown www-data:www-data /usr/local/oreon/www/include/common/javascript/zoom.js

    chmod 775 /usr/local/oreon/www/include/views/graphs/graphODS/graphODSServiceZoom.ihtml
    chown www-data:www-data /usr/local/oreon/www/include/views/graphs/graphODS/graphODSServiceZoom.ihtml

    ;-)
    Last edited by kurty100; 16 May 2007, 17:54.

    Leave a comment:


  • tbernard
    replied
    yes !! thk you. It's good

    Leave a comment:


  • breakintheweb
    replied
    I've just tested, and you are right. Add the following to sql to fix.
    Code:
    INSERT INTO `topology_JS` (`id_t_js`, `id_page`, `o`, `PathName_js`, `Init`) VALUES 
    ('', 40207, 'vz', './include/common/javascript/zoom.js', 'initBonsai');

    Leave a comment:


  • tbernard
    replied
    Again a small bug. The zoom works when we from "Oreon View"...but when we from "Monitoring / And click on graph icon"...it doesn't works after.

    Leave a comment:


  • breakintheweb
    replied
    In the sql insert statement, take the 166 out and replace it with ''. I edited my above post to reflect this.


    Originally posted by Menno View Post
    In my topology_JS file I already have an id_t_js 166. But even when I overwrite that or when I use the next free id_t_js (171) the zoom is not working. No cross, no zoomout with rightclick. Used IE6.1 and FF1.5.

    Regards
    Menno

    Leave a comment:


  • Menno
    replied
    In my topology_JS file I already have an id_t_js 166. But even when I overwrite that or when I use the next free id_t_js (171) the zoom is not working. No cross, no zoomout with rightclick. Used IE6.1 and FF1.5.

    Regards
    Menno

    Leave a comment:


  • breakintheweb
    replied
    Final Install Directions.

    First, Undo anything you've done above

    Next insert sql, statement

    Code:
    INSERT INTO `topology_JS` (`id_t_js`, `id_page`, `o`, `PathName_js`, `Init`) VALUES 
    ('', 4, 'vz', './include/common/javascript/zoom.js', 'initBonsai');
    
    INSERT INTO `topology_JS` (`id_t_js`, `id_page`, `o`, `PathName_js`, `Init`) VALUES 
    ('', 40207, 'vz', './include/common/javascript/zoom.js', 'initBonsai');
    Finally copy zoom.js into

    www/include/common/javascript/

    and copy graphODSServiceZoom.ihtml into:

    www/include/views/graphs/graphODS/
    Attached Files
    Last edited by breakintheweb; 16 May 2007, 16:36.

    Leave a comment:


  • breakintheweb
    replied
    The issue was with div values that didn't meet xhtml spec. Attached are the updated files.

    It now works in Firefox 2.0, IE6, IE7

    I will probably make one more post with the final package. I would like to follow oreon standards of calling .js files from the topology_js table as opposed to include file calls.

    Any feedback is appreciated.

    -Justin
    Attached Files
    Last edited by breakintheweb; 24 April 2007, 18:17.

    Leave a comment:


  • breakintheweb
    replied
    I'm not sure why it's not working in firefox. Javascript isn't a strong area for me. As for the ie6 issue, i have my gmt set to 0 and the zoom function is right. It might be a GMT issue.

    Thanks for giving feedback.

    Originally posted by Menno View Post
    That's a nice idea!
    Indeed in firefox it doesn't seem to work yet, the zoom-out (right-click) works, but zoom-in not (I don't get a cross cursor).
    In IE6 I have the effect that the zoom-function shows the graph 1 to 2 hours later then I selected. Maybe it has something to do with the GMT oreon option?

    Regards
    Menno

    Leave a comment:


  • Menno
    replied
    That's a nice idea!
    Indeed in firefox it doesn't seem to work yet, the zoom-out (right-click) works, but zoom-in not (I don't get a cross cursor).
    In IE6 I have the effect that the zoom-function shows the graph 1 to 2 hours later then I selected. Maybe it has something to do with the GMT oreon option?

    Regards
    Menno

    Leave a comment:


  • DonKiShoot
    replied
    Originally posted by breakintheweb View Post
    I got it working. I'll post the code after testing

    Leave a comment:


  • rom
    replied
    Great !! I'll test it in the morning !!!

    Leave a comment:


  • breakintheweb
    replied
    Originally posted by breakintheweb View Post
    I got it working. I'll post the code after testing it a bit more

    see attached image
    open the following file:
    /include/views/graphs/graphODS/graphODSServiceZoom.php

    Find the following at the begining:
    if (!isset($oreon))
    exit();

    add the following after the previos code
    # include js for zoombox
    include('zoombox.php');
    include('javascript.php');

    Copy zipped files into /include/views/graphs/graphODS/

    NOTE: I've only tested this code in IE7

    Questions or comments are welcomed.
    Attached Files

    Leave a comment:

Working...
X