Hoppa till huvudinnehållet

Moving QuickStart Libraries (with custom modules) to an existing Viewer (v 2.5.2)

Kommentarer

4 kommentarer

  • Kevin Penner
    There are a few things you need to do.
    1. Move the library into a virtual directory. At Latitude, we generally put this into a viewers virtual dicrectoy within a site. Example: Sites/<SiteName>/Viewers/<HTML5Viewer>/VirtualDirectory/Resources/Compiled/MyLibrary.js
    2. Edit whichever shell configs you want to load the custom library (Desktop.json.js).
      1. Reference the library (MyLibrary.js) in the libraries array._img_ alt="Configure the library" src="https://latitudegeo--c.na53.content.force.com/servlet/rtaImage?eid=907600000004GCU&feoid=Body&refid=0EM600000004YAO" _/_img_The 'id' is important. To find the library id, open the MyLibrary.js file in a text editor and look at the last line. The ID will be in the notify library downloaded method.
      2. Configure the module. This is likely going to be a copy paste from the QuickStarts default.json.js file. This configuration varies depending on if you have views and viewmodels associated with your module. Be sure to tell the module which library it can find the namespaces in. This is specified by 'libraryId'. _img_ alt="User-added image" src="https://latitudegeo--c.na53.content.force.com/servlet/rtaImage?eid=907600000004GCU&feoid=Body&refid=0EM600000004YAT" _/_img_
    0
  • Kevin Penner
    The formatting was butchered there. Please let me know if you have any further questions on how to load a library into different viewers.
    0
  • Permanently deleted user
    Kevin,

     

    Thanks so much for the quick reply! I will investigate and follow-up asap.

     

    -David
    0
  • Permanently deleted user
    Kevin,

     

    These instructions were very good and this worked flawlessly. I have to ask this though-

     

    Is there a way to avoid having people edit this monster configuration file for an application? Are there any functions provided in the GeoCortex framework that will merge a custom configuration file I build with the active configuration file and result in a working custom module and application?

     

    I will look myself and try to understand ViewerLoader, I think it is, a bit better, but I didn't see anything off-hand. It does seem like you can use a collection of configuration files for the same application instance, but I also have not tried that yet. 
    0

Du måste logga in om du vill lämna en kommentar.