Skip to content
This repository has been archived by the owner on Oct 8, 2019. It is now read-only.

BlackWolfDEsign/apex-openstreetmap-plugin

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

edited by BlackWolfDEsign

Oracle APEX OpenStreetMap Plugin

Oracle APEX Plugin for OpenStreetMap maps

GitHub Logo

Assets

JavaScript

This plugin uses Leaflet 1.4.0 lib for interactive maps. This lib is integrated into the plugin as two files:

assets/js/leaflet/leaflet.js
assets/js/leaflet/leaflet.css

The main map rendering script map.js is integrated into the plugin as well.

assets/js/map.js

Map markers

To support different color markers the leaflet-color-markers were integrated into the plugin:

assets/markers/

Plugin attributes

Name Type Required Default Value
Height Text Yes 700px
Source SQL Code Yes Described below
Center Text Yes
Zoom Text Yes
Max_Zoom Text Yes

The Source attribute should contain an SQL statement like :

-- marker_type: markers or polygons
-- loc_type: point or points
-- lat and lng for marker
-- [lat,lng],[lat,lng],[lat,lng] in loc for polygons
select marker_type as src_marker_type, loc_type as src_loc_type, lat as src_lat, lng as src_lng, loc as src_loc, color as src_color, label as src_label from src_table

DB-Columns and JSON

"markers" and "polygons" = src_marker_type, "point" and "points" = src_lat,src_lng or src_loc

{
  "markers": [
    {
      "point": [50.45, 30.523333],
      "color": "red",
      "text": "Red marker text"
    }
  ],
  "polygons": [
    {
      "color": "blue",
      "text": "Blue polygon text",
      "points": [
        [50.45, 30.523333],
        [50.4, 30.53],
        [50.41, 30.5],
      ]
    },
    {
      "color": "red",
      "text": "Red polygon text",
      "points": [
        [50.55, 30.523333],
        [50.5, 30.53],
        [50.51, 30.5],
      ]
    },
    ...
      ]
    }
  ]
}

DB-SQL

CREATE TABLE  "TEST" 
   (	"MARKER_TYPE" VARCHAR2(80), 
	"LAT" NUMBER(10,8), 
	"LNG" NUMBER(10,8), 
	"LOC_TYPE" VARCHAR2(80), 
	"COLOR" VARCHAR2(80), 
	"LABEL" VARCHAR2(4000), 
	"LOC" VARCHAR2(4000)
   )

About

Oracle Apex Plugin for OpenStreetMap maps

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • PLSQL 99.7%
  • JavaScript 0.3%