-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #54 from psteiwer/dev-eventviewer
Dev eventviewer
- Loading branch information
Showing
3 changed files
with
100 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
Class PivotSubscriptions.UI.EventLogViewer Extends PivotSubscriptions.UI.Template | ||
{ | ||
|
||
/// Displayed name of this page. | ||
Parameter PAGENAME = "Event Log Viewer"; | ||
|
||
/// This XML block defines the contents of this pane. | ||
XData contentPane [ XMLNamespace = "http://www.intersystems.com/zen" ] | ||
{ | ||
<pane xmlns="http://www.intersystems.com/zen"> | ||
<hgroup valign="top" > | ||
<spacer width="20" /> | ||
<vgroup valign="top" > | ||
<spacer height="20" /> | ||
<tableNavigatorBar id="tableNavigator" tablePaneId="tablePane" showPageSize="true" /> | ||
<tablePane id="tablePane" | ||
cellSpacing="2" | ||
fixedHeaders="false" | ||
queryClass="PivotSubscriptions.UI.EventLogViewer" | ||
queryName="GetEvents" | ||
useSnapshot="true" | ||
showQuery="false" | ||
showZebra="true" | ||
showRowNumbers="false" | ||
pageSize="100" | ||
maxRows="1000" | ||
> | ||
</tablePane> | ||
</vgroup> | ||
</hgroup> | ||
</pane> | ||
} | ||
|
||
/// Get the (localized) title string for the page. | ||
Method %OnGetTitle() As %String [ Internal ] | ||
{ | ||
Quit $$$Text("Event Log Viewer","PivotSubscriptions") | ||
} | ||
|
||
/// Get the (localized) name of the page. | ||
Method %OnGetPageName() As %String [ Internal ] | ||
{ | ||
Quit $$$Text("Event Log Viewer","PivotSubscriptions") | ||
} | ||
|
||
Query GetEvents() As %SQLQuery | ||
{ | ||
SELECT StartTime,EndTime,EventType,Name,Pivot,UserName,DayOfWeek,Format,"Hour","Minute",Emails,Status | ||
FROM PivotSubscriptions.EventLog | ||
ORDER BY ID DESC | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,38 +1,42 @@ | ||
Class PivotSubscriptions.UI.Template Extends %DeepSee.UI.standardPage | ||
{ | ||
|
||
Parameter DOMAIN = "PivotSubscriptions"; | ||
|
||
/// Get information to display in the ribbon bar. | ||
Method OnGetRibbonInfo(Output pDisplay As %Boolean, Output pViewIcons As %List, Output pSortOptions As %List, Output pSearchBox As %Boolean, Output pRibbonTitle As %String, Output pCommands As %List) As %Status | ||
{ | ||
Set pDisplay=1 | ||
Set pSearchBox=0 | ||
Set pRibbonTitle=$$$Text(..#PAGENAME) | ||
|
||
Set pCommands($I(pCommands))=$LB("subscriptionManager",$$$Text("Subscription Manager"),$$$Text("Manage Pivot Subscriptions"),"zenPage.navigate('subscriptionManager');") | ||
Set pCommands($I(pCommands))=$LB("pivotList",$$$Text("Pivot List"),$$$Text("View All Pivot Tables"),"zenPage.navigate('pivotList');") | ||
Set pCommands($I(pCommands))=$LB("configurationPage",$$$Text("Configuration Page"),$$$Text("Configure Settings"),"zenPage.navigate('configurationPage');") | ||
|
||
Quit $$$OK | ||
} | ||
|
||
ClientMethod navigate(pageName) [ Language = javascript ] | ||
{ | ||
var location="" | ||
if (pageName=='subscriptionManager') { | ||
location="./PivotSubscriptions.UI.SubscriptionManager.zen" | ||
} else if (pageName=='pivotList') { | ||
location="./PivotSubscriptions.UI.PivotList.zen" | ||
} else if (pageName=='configurationPage') { | ||
location="./PivotSubscriptions.UI.ConfigurationPage.zen" | ||
} else { | ||
// Invalid page name | ||
} | ||
|
||
if (location!="") { | ||
window.location.href=location; | ||
} | ||
} | ||
|
||
} | ||
Class PivotSubscriptions.UI.Template Extends %DeepSee.UI.standardPage | ||
{ | ||
|
||
Parameter DOMAIN = "PivotSubscriptions"; | ||
|
||
/// Get information to display in the ribbon bar. | ||
Method OnGetRibbonInfo(Output pDisplay As %Boolean, Output pViewIcons As %List, Output pSortOptions As %List, Output pSearchBox As %Boolean, Output pRibbonTitle As %String, Output pCommands As %List) As %Status | ||
{ | ||
Set pDisplay=1 | ||
Set pSearchBox=0 | ||
Set pRibbonTitle=$$$Text(..#PAGENAME) | ||
|
||
Set pCommands($I(pCommands))=$LB("subscriptionManager",$$$Text("Subscription Manager"),$$$Text("Manage Pivot Subscriptions"),"zenPage.navigate('subscriptionManager');") | ||
Set pCommands($I(pCommands))=$LB("pivotList",$$$Text("Pivot List"),$$$Text("View All Pivot Tables"),"zenPage.navigate('pivotList');") | ||
// Check for additional permissions? | ||
Set pCommands($I(pCommands))=$LB("configurationPage",$$$Text("Configuration Page"),$$$Text("Configure Settings"),"zenPage.navigate('configurationPage');") | ||
Set pCommands($I(pCommands))=$LB("eventLogViewer",$$$Text("Event Log Viewer"),$$$Text("Event Log Viewer"),"zenPage.navigate('eventLogViewer');") | ||
|
||
Quit $$$OK | ||
} | ||
|
||
ClientMethod navigate(pageName) [ Language = javascript ] | ||
{ | ||
var location="" | ||
if (pageName=='subscriptionManager') { | ||
location="./PivotSubscriptions.UI.SubscriptionManager.zen" | ||
} else if (pageName=='pivotList') { | ||
location="./PivotSubscriptions.UI.PivotList.zen" | ||
} else if (pageName=='configurationPage') { | ||
location="./PivotSubscriptions.UI.ConfigurationPage.zen" | ||
} else if (pageName='eventLogViewer') { | ||
location="./PivotSubscriptions.UI.EventLogViewer.zen" | ||
} else { | ||
// Invalid page name | ||
} | ||
|
||
if (location!="") { | ||
window.location.href=location; | ||
} | ||
} | ||
|
||
} |