Skip to content

Commit

Permalink
Bugfixing
Browse files Browse the repository at this point in the history
  • Loading branch information
APEXGru committed Oct 21, 2018
1 parent 1f1aaf5 commit 2c4bf95
Show file tree
Hide file tree
Showing 4 changed files with 60 additions and 61 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ Region Plugin to show one or more Status Meter Gauges based on a SQL statement.

## Changelog

#### 1.2.1 - Fix to show the Value in the centre and use the Percentage for the coloring
#### 1.2.0 - Fix for APEX 18.1 / JET 4.2
#### 1.1.0 - Added a "Tooltip" column
#### 1.0.0 - Initial Release
Expand Down
2 changes: 1 addition & 1 deletion apexplugin.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name" : "JET StatusMeterGauge",
"version" : "1.2.0",
"version" : "1.2.1",
"description" : "Region Plugin to show one or more Status Meter Gauges based on a SQL statement.",
"keywords" : ["JET","chart"],
"homepage" : "https://github.com/APEXGru/JET-StatusMeterGauge",
Expand Down
117 changes: 57 additions & 60 deletions region_type_plugin_com_apexconsulting_apex_jet_gauge.sql
Original file line number Diff line number Diff line change
Expand Up @@ -6,25 +6,25 @@ whenever sqlerror exit sql.sqlcode rollback
-- ORACLE Application Express (APEX) export file
--
-- You should run the script connected to SQL*Plus as the Oracle user
-- APEX_180100 or as the owner (parsing schema) of the application.
-- APEX_180200 or as the owner (parsing schema) of the application.
--
-- NOTE: Calls to apex_application_install override the defaults below.
--
--------------------------------------------------------------------------------
begin
wwv_flow_api.import_begin (
p_version_yyyy_mm_dd=>'2018.04.04'
,p_release=>'18.1.0.00.45'
,p_default_workspace_id=>1832690300009983
,p_default_application_id=>119
,p_default_owner=>'DEMO'
p_version_yyyy_mm_dd=>'2018.05.24'
,p_release=>'18.2.0.00.12'
,p_default_workspace_id=>17760818290854663
,p_default_application_id=>84207
,p_default_owner=>'ROEL'
);
end;
/
prompt --application/shared_components/plugins/region_type/com_apexconsulting_apex_jet_gauge
begin
wwv_flow_api.create_plugin(
p_id=>wwv_flow_api.id(91906449042210448)
p_id=>wwv_flow_api.id(5230230853435403177)
,p_plugin_type=>'REGION TYPE'
,p_name=>'COM.APEXCONSULTING.APEX.JET.GAUGE'
,p_display_name=>'JET Status Meter Gauge'
Expand Down Expand Up @@ -243,12 +243,12 @@ wwv_flow_api.create_plugin(
,p_standard_attributes=>'SOURCE_SQL:AJAX_ITEMS_TO_SUBMIT:ESCAPE_OUTPUT'
,p_substitute_attributes=>false
,p_subscribe_plugin_settings=>true
,p_version_identifier=>'1.2.0'
,p_files_version=>186
,p_version_identifier=>'1.2.1'
,p_files_version=>194
);
wwv_flow_api.create_plugin_attribute(
p_id=>wwv_flow_api.id(38842982298300276)
,p_plugin_id=>wwv_flow_api.id(91906449042210448)
p_id=>wwv_flow_api.id(5177167386691493005)
,p_plugin_id=>wwv_flow_api.id(5230230853435403177)
,p_attribute_scope=>'COMPONENT'
,p_attribute_sequence=>1
,p_display_sequence=>10
Expand All @@ -261,8 +261,8 @@ wwv_flow_api.create_plugin_attribute(
,p_help_text=>'Select the column from the region SQL Query that holds the shown value for the gauge.'
);
wwv_flow_api.create_plugin_attribute(
p_id=>wwv_flow_api.id(38843549872304111)
,p_plugin_id=>wwv_flow_api.id(91906449042210448)
p_id=>wwv_flow_api.id(5177167954265496840)
,p_plugin_id=>wwv_flow_api.id(5230230853435403177)
,p_attribute_scope=>'COMPONENT'
,p_attribute_sequence=>2
,p_display_sequence=>20
Expand All @@ -275,8 +275,8 @@ wwv_flow_api.create_plugin_attribute(
,p_help_text=>'Select the column from the region SQL Query that holds the percentage for the gauge.'
);
wwv_flow_api.create_plugin_attribute(
p_id=>wwv_flow_api.id(38844185871308585)
,p_plugin_id=>wwv_flow_api.id(91906449042210448)
p_id=>wwv_flow_api.id(5177168590264501314)
,p_plugin_id=>wwv_flow_api.id(5230230853435403177)
,p_attribute_scope=>'COMPONENT'
,p_attribute_sequence=>3
,p_display_sequence=>30
Expand All @@ -289,8 +289,8 @@ wwv_flow_api.create_plugin_attribute(
,p_help_text=>'Select the column from the region SQL Query that holds the label value for the gauge.'
);
wwv_flow_api.create_plugin_attribute(
p_id=>wwv_flow_api.id(38844846828311150)
,p_plugin_id=>wwv_flow_api.id(91906449042210448)
p_id=>wwv_flow_api.id(5177169251221503879)
,p_plugin_id=>wwv_flow_api.id(5230230853435403177)
,p_attribute_scope=>'COMPONENT'
,p_attribute_sequence=>4
,p_display_sequence=>40
Expand All @@ -303,8 +303,8 @@ wwv_flow_api.create_plugin_attribute(
,p_help_text=>'Select the column from the region SQL Query that holds the color for the gauge.'
);
wwv_flow_api.create_plugin_attribute(
p_id=>wwv_flow_api.id(38845512264316924)
,p_plugin_id=>wwv_flow_api.id(91906449042210448)
p_id=>wwv_flow_api.id(5177169916657509653)
,p_plugin_id=>wwv_flow_api.id(5230230853435403177)
,p_attribute_scope=>'COMPONENT'
,p_attribute_sequence=>5
,p_display_sequence=>50
Expand All @@ -316,8 +316,8 @@ wwv_flow_api.create_plugin_attribute(
,p_help_text=>'Enter a target page to be called when the user clicks a gauge.'
);
wwv_flow_api.create_plugin_attribute(
p_id=>wwv_flow_api.id(39118402260492593)
,p_plugin_id=>wwv_flow_api.id(91906449042210448)
p_id=>wwv_flow_api.id(5177442806653685322)
,p_plugin_id=>wwv_flow_api.id(5230230853435403177)
,p_attribute_scope=>'COMPONENT'
,p_attribute_sequence=>6
,p_display_sequence=>60
Expand All @@ -330,22 +330,22 @@ wwv_flow_api.create_plugin_attribute(
,p_lov_type=>'STATIC'
);
wwv_flow_api.create_plugin_attr_value(
p_id=>wwv_flow_api.id(39119619432493291)
,p_plugin_attribute_id=>wwv_flow_api.id(39118402260492593)
p_id=>wwv_flow_api.id(5177444023825686020)
,p_plugin_attribute_id=>wwv_flow_api.id(5177442806653685322)
,p_display_sequence=>10
,p_display_value=>'Horizontal'
,p_return_value=>'Horizontal'
);
wwv_flow_api.create_plugin_attr_value(
p_id=>wwv_flow_api.id(39119936353494098)
,p_plugin_attribute_id=>wwv_flow_api.id(39118402260492593)
p_id=>wwv_flow_api.id(5177444340746686827)
,p_plugin_attribute_id=>wwv_flow_api.id(5177442806653685322)
,p_display_sequence=>20
,p_display_value=>'Vertical'
,p_return_value=>'Vertical'
);
wwv_flow_api.create_plugin_attribute(
p_id=>wwv_flow_api.id(39214088679948978)
,p_plugin_id=>wwv_flow_api.id(91906449042210448)
p_id=>wwv_flow_api.id(5177538493073141707)
,p_plugin_id=>wwv_flow_api.id(5230230853435403177)
,p_attribute_scope=>'COMPONENT'
,p_attribute_sequence=>7
,p_display_sequence=>70
Expand All @@ -360,8 +360,8 @@ wwv_flow_api.create_plugin_attribute(
,p_is_translatable=>false
);
wwv_flow_api.create_plugin_attribute(
p_id=>wwv_flow_api.id(19931171406937339)
,p_plugin_id=>wwv_flow_api.id(91906449042210448)
p_id=>wwv_flow_api.id(5158255575800130068)
,p_plugin_id=>wwv_flow_api.id(5230230853435403177)
,p_attribute_scope=>'COMPONENT'
,p_attribute_sequence=>8
,p_display_sequence=>80
Expand All @@ -380,8 +380,8 @@ wwv_flow_api.create_plugin_attribute(
'Leave empty for no automatic refresh.'))
);
wwv_flow_api.create_plugin_attribute(
p_id=>wwv_flow_api.id(20606287057873724)
,p_plugin_id=>wwv_flow_api.id(91906449042210448)
p_id=>wwv_flow_api.id(5158930691451066453)
,p_plugin_id=>wwv_flow_api.id(5230230853435403177)
,p_attribute_scope=>'COMPONENT'
,p_attribute_sequence=>9
,p_display_sequence=>35
Expand All @@ -394,8 +394,8 @@ wwv_flow_api.create_plugin_attribute(
,p_help_text=>'The column that contains the tooltip value.'
);
wwv_flow_api.create_plugin_std_attribute(
p_id=>wwv_flow_api.id(38804082748853424)
,p_plugin_id=>wwv_flow_api.id(91906449042210448)
p_id=>wwv_flow_api.id(5177128487142046153)
,p_plugin_id=>wwv_flow_api.id(5230230853435403177)
,p_name=>'SOURCE_SQL'
,p_sql_min_column_count=>1
,p_examples=>wwv_flow_string.join(wwv_flow_t_varchar2(
Expand Down Expand Up @@ -435,37 +435,34 @@ wwv_flow_api.g_varchar2_table(15) := '2020202020202428222322202B2067617567654469
wwv_flow_api.g_varchar2_table(16) := '61756765446976290A20202020202020202020202020202020202020202020202020202020202020202020202E6F6A5374617475734D657465724761756765287B20226F7269656E746174696F6E2220202020202020202020203A202263697263756C61';
wwv_flow_api.g_varchar2_table(17) := '72222C0A20202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202022616E696D6174696F6E4F6E446973706C617922202020203A20226175746F222C0A2020202020';
wwv_flow_api.g_varchar2_table(18) := '2020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202022616E696D6174696F6E4F6E446174614368616E676522203A20226175746F222C0A2020202020202020202020202020';
wwv_flow_api.g_varchar2_table(19) := '202020202020202020202020202020202020202020202020202020202020202020202020202020202020202276616C75652220202020202020202020202020202020203A206974656D2E76616C75652C0A2F2F2020202020202020202020202020202020';
wwv_flow_api.g_varchar2_table(20) := '20202020202020202020202020202020202020202020202020202020202020202020202020202020226D65747269634C6162656C2220202020202020202020203A207B20227465787422203A206974656D2E6D65747269634C6162656C2E74657874207D';
wwv_flow_api.g_varchar2_table(21) := '2C0A2F2F202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020226C6162656C2220202020202020202020202020202020203A207B20227465787422203A206974';
wwv_flow_api.g_varchar2_table(22) := '656D2E6C6162656C2E74657874207D2C0A2F2F202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020227469746C65222020202020202020202020202020202020';
wwv_flow_api.g_varchar2_table(23) := '3A207B20227465787422203A20222022207D2C0A20202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202022636F6C6F722220202020202020202020202020202020';
wwv_flow_api.g_varchar2_table(24) := '203A206974656D2E636F6C6F722C0A20202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202022636C6173732220202020202020202020202020202020203A202261';
wwv_flow_api.g_varchar2_table(25) := '2D4A45542D7374617475734D657465724761756765222C0A20202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202022746F6F6C7469702220202020202020202020';
wwv_flow_api.g_varchar2_table(26) := '20202020203A207B202272656E646572657222203A2066756E6374696F6E282064617461436F6E74657874297B0A202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020';
wwv_flow_api.g_varchar2_table(27) := '202020202020202020202020202020202020202020202020202020202020202076617220746F6F6C746970203D20646F63756D656E742E637265617465456C656D656E74282264697622293B0A2020202020202020202020202020202020202020202020';
wwv_flow_api.g_varchar2_table(28) := '20202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202076617220746F6F6C74697054657874203D20646F63756D656E742E637265617465456C656D';
wwv_flow_api.g_varchar2_table(29) := '656E7428227370616E22293B0A202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202074';
wwv_flow_api.g_varchar2_table(30) := '6F6F6C746970546578742E74657874436F6E74656E74203D200A2020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020';
wwv_flow_api.g_varchar2_table(31) := '20202020202020202020202020206974656D2E746F6F6C746970207C7C206974656D2E6C6162656C2E74657874202B2022203A2022202B206974656D2E6D65747269634C6162656C2E746578743B0A202020202020202020202020202020202020202020';
wwv_flow_api.g_varchar2_table(32) := '202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020746F6F6C7469702E617070656E644368696C642820746F6F6C';
wwv_flow_api.g_varchar2_table(33) := '7469705465787420293B0A2020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020';
wwv_flow_api.g_varchar2_table(34) := '2020202020202072657475726E20746F6F6C7469703B0A2020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020';
wwv_flow_api.g_varchar2_table(35) := '2020202020202020202020202020202020207D0A2020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020';
wwv_flow_api.g_varchar2_table(36) := '202020207D0A2020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020207D293B0A202020202020202020202020202020202020202020202020202020207D293B0A20202020';
wwv_flow_api.g_varchar2_table(37) := '202020202020202020202020202020207D0A202020202020202020202020202020207D293B0A2020202020202020202020207D293B0A20202020202020207D2C0A2020202020202020726566726573683A2066756E6374696F6E202870526567696F6E49';
wwv_flow_api.g_varchar2_table(38) := '642C20704865696768742C20704F7269656E746174696F6E2C207041706578416A61784964656E74696669657229207B0A202020202020202020202020696E69742870526567696F6E49642C20704865696768742C20704F7269656E746174696F6E2C20';
wwv_flow_api.g_varchar2_table(39) := '7041706578416A61784964656E746966696572293B0A20202020202020207D0A202020207D0A7D2877696E646F772E6A6574203D2077696E646F772E6A6574207C7C207B7D2C20617065782E6A51756572792C20617065782E7365727665722C20617065';
wwv_flow_api.g_varchar2_table(40) := '782E7574696C2C20617065782E6465627567293B';
wwv_flow_api.g_varchar2_table(19) := '202020202020202020202020202020202020202020202020202020202020202020202020202020202020202276616C75652220202020202020202020202020202020203A206974656D2E76616C75652C0A20202020202020202020202020202020202020';
wwv_flow_api.g_varchar2_table(20) := '202020202020202020202020202020202020202020202020202020202020202020202020202022636F6C6F722220202020202020202020202020202020203A206974656D2E636F6C6F722C0A202020202020202020202020202020202020202020202020';
wwv_flow_api.g_varchar2_table(21) := '202020202020202020202020202020202020202020202020202020202020202020226D65747269634C6162656C22202020202020202020203A207B20227465787422203A206974656D2E6D65747269634C6162656C2E74657874207D2C0A202020202020';
wwv_flow_api.g_varchar2_table(22) := '20202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202022636C6173732220202020202020202020202020202020203A2022612D4A45542D7374617475734D657465724761756765';
wwv_flow_api.g_varchar2_table(23) := '222C0A20202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202022746F6F6C746970222020202020202020202020202020203A207B202272656E646572657222203A';
wwv_flow_api.g_varchar2_table(24) := '2066756E6374696F6E282064617461436F6E74657874297B0A202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020';
wwv_flow_api.g_varchar2_table(25) := '202020202020202020202076617220746F6F6C746970203D20646F63756D656E742E637265617465456C656D656E74282264697622293B0A2020202020202020202020202020202020202020202020202020202020202020202020202020202020202020';
wwv_flow_api.g_varchar2_table(26) := '20202020202020202020202020202020202020202020202020202020202020202020202020202020202076617220746F6F6C74697054657874203D20646F63756D656E742E637265617465456C656D656E7428227370616E22293B0A2020202020202020';
wwv_flow_api.g_varchar2_table(27) := '202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020746F6F6C746970546578742E74657874436F6E74656E';
wwv_flow_api.g_varchar2_table(28) := '74203D200A202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020206974656D2E746F';
wwv_flow_api.g_varchar2_table(29) := '6F6C746970207C7C206974656D2E6C6162656C2E74657874202B2022203A2022202B206974656D2E6D65747269634C6162656C2E746578743B0A202020202020202020202020202020202020202020202020202020202020202020202020202020202020';
wwv_flow_api.g_varchar2_table(30) := '202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020746F6F6C7469702E617070656E644368696C642820746F6F6C7469705465787420293B0A20202020202020202020';
wwv_flow_api.g_varchar2_table(31) := '202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202072657475726E20746F6F6C746970';
wwv_flow_api.g_varchar2_table(32) := '3B0A20202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020207D0A20';
wwv_flow_api.g_varchar2_table(33) := '20202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020207D0A202020202020202020202020202020';
wwv_flow_api.g_varchar2_table(34) := '2020202020202020202020202020202020202020202020202020202020202020202020202020207D293B0A202020202020202020202020202020202020202020202020202020207D293B0A20202020202020202020202020202020202020207D0A202020';
wwv_flow_api.g_varchar2_table(35) := '202020202020202020202020207D293B0A2020202020202020202020207D293B0A20202020202020207D2C0A2020202020202020726566726573683A2066756E6374696F6E202870526567696F6E49642C20704865696768742C20704F7269656E746174';
wwv_flow_api.g_varchar2_table(36) := '696F6E2C207041706578416A61784964656E74696669657229207B0A202020202020202020202020696E69742870526567696F6E49642C20704865696768742C20704F7269656E746174696F6E2C207041706578416A61784964656E746966696572293B';
wwv_flow_api.g_varchar2_table(37) := '0A20202020202020207D0A202020207D0A7D2877696E646F772E6A6574203D2077696E646F772E6A6574207C7C207B7D2C20617065782E6A51756572792C20617065782E7365727665722C20617065782E7574696C2C20617065782E6465627567293B';
null;
end;
/
begin
wwv_flow_api.create_plugin_file(
p_id=>wwv_flow_api.id(38646191484036755)
,p_plugin_id=>wwv_flow_api.id(91906449042210448)
p_id=>wwv_flow_api.id(5176970595877229484)
,p_plugin_id=>wwv_flow_api.id(5230230853435403177)
,p_file_name=>'gaugeChart.js'
,p_mime_type=>'application/javascript'
,p_mime_type=>'text/javascript'
,p_file_charset=>'utf-8'
,p_file_content=>wwv_flow_api.varchar2_to_blob(wwv_flow_api.g_varchar2_table)
);
Expand All @@ -482,8 +479,8 @@ end;
/
begin
wwv_flow_api.create_plugin_file(
p_id=>wwv_flow_api.id(39124091944558188)
,p_plugin_id=>wwv_flow_api.id(91906449042210448)
p_id=>wwv_flow_api.id(5177448496337750917)
,p_plugin_id=>wwv_flow_api.id(5230230853435403177)
,p_file_name=>'gaugeChart.css'
,p_mime_type=>'text/css'
,p_file_charset=>'utf-8'
Expand Down
1 change: 1 addition & 0 deletions server/js/gaugeChart.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
"animationOnDataChange" : "auto",
"value" : item.value,
"color" : item.color,
"metricLabel" : { "text" : item.metricLabel.text },
"class" : "a-JET-statusMeterGauge",
"tooltip" : { "renderer" : function( dataContext){
var tooltip = document.createElement("div");
Expand Down

0 comments on commit 2c4bf95

Please sign in to comment.