Skip to content

Commit e27c9c3

Browse files
authored
Merge pull request #124 from psteiwer/dev
Dev
2 parents a7b780f + 30ee6de commit e27c9c3

9 files changed

Lines changed: 94 additions & 6 deletions

File tree

.vscode/settings.json

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
{
2+
"intersystems.servers": {
3+
"pivotsubscriptions": {
4+
"webServer": {
5+
"scheme": "http",
6+
"host": "localhost",
7+
"port": 61773
8+
},
9+
"username": "_system"
10+
}
11+
},
12+
"objectscript.conn": {
13+
"server": "pivotsubscriptions",
14+
"ns": "USER",
15+
"active": true
16+
}
17+
}

Dockerfile

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
ARG IMAGE=intersystemsdc/iris-community
2+
FROM $IMAGE
3+
4+
USER root
5+
WORKDIR /opt/irisapp
6+
RUN chown ${ISC_PACKAGE_MGRUSER}:${ISC_PACKAGE_IRISGROUP} /opt/irisapp
7+
8+
USER ${ISC_PACKAGE_MGRUSER}
9+
10+
# copy files
11+
COPY PivotSubscriptions PivotSubscriptions
12+
COPY Assets Assets
13+
COPY iris.script /tmp/iris.script
14+
COPY module.xml module.xml
15+
16+
# run iris and script
17+
RUN iris start IRIS \
18+
&& iris session IRIS < /tmp/iris.script \
19+
&& iris stop IRIS quietly
20+

PivotSubscriptions/Installer.cls

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ XData LocalInstall [ XMLNamespace = INSTALLER ]
2222
</Invoke>
2323
<Import File="${APPPATH}/PivotSubscriptions/" Flags="ck" Recurse="1"/>
2424
<Invoke Class="PivotSubscriptions.Installer" Method="ImportImage" CheckStatus="1">
25-
<Arg Value="${APPPATH}/Assets/PivotSubscriptions_BookCover.png"/>
25+
<Arg Value="${APPPATH}/Assets/PivotSubscriptions_Cover.png"/>
2626
</Invoke>
2727
<Invoke Class="PivotSubscriptions.Installer" Method="CreateBookCover" CheckStatus="1">
2828
</Invoke>
@@ -59,7 +59,7 @@ ClassMethod RunInstaller(pRootDir = "")
5959

6060
If pRootDir'="" {
6161
Do $system.OBJ.LoadDir(pRootDir_"/PivotSubscriptions","ck",,1)
62-
Set tSC=..ImportImage(pRootDir_"/Assets/PivotSubscriptions_BookCover.png")
62+
Set tSC=..ImportImage(pRootDir_"/Assets/PivotSubscriptions_Cover.png")
6363
If $$$ISERR(tSC) Quit
6464
}
6565

PivotSubscriptions/Utils.cls

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ Class PivotSubscriptions.Utils
33

44
ClassMethod GetVersion() As %String
55
{
6-
Quit "v1.8.0"
6+
Quit "v1.8.1"
77
}
88

99
/// Utility method for saving and updating global variables
@@ -390,9 +390,11 @@ ClassMethod ExecuteForSubscription(pMDX, pCustomFilter = "", ByRef pHasResults =
390390
Set tRS=##class(%DeepSee.ResultSet).%New()
391391
Do tRS.%PrepareMDX(pMDX)
392392
Do tRS.%Execute()
393-
Do tRS.%Print()
394393
If tRS.%Query.queryType="DRILLTHROUGH" {
395-
If tRS.listingRows>0 {
394+
// Workaround for 2024.1 bug
395+
Do tRS.%GetListingResultSet(.tListingRS)
396+
While tListingRS.%Next() {}
397+
If (tListingRS.%ROWCOUNT>0) {
396398
Set pHasResults=1
397399
}
398400
} Else {

README.md

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,17 @@ PivotSubsctions allows users to subscribe to a pivot table and recieve a schedul
66
Once installation is complete, a new "Pivot Subscriptions" Link will be added to the InterSystems IRIS Business Intelligence User Portal. The User Portal can be found at the Management Portal -> Analytics -> User Portal.
77

88
## Installation
9+
### ZPM Install
10+
1. ```zpm "install pivotsubscriptions"```
11+
2. Follow [Configuration Steps](#configuration-steps)
12+
13+
### Docker Install (for development)
14+
1. Clone Repo
15+
2. ```docker compose up -d --build```
16+
3. http://localhost:61773/csp/user/PivotSubscriptions.UI.SubscriptionManager.zen
17+
4. Follow [Configuration Steps](#configuration-steps)
18+
19+
### Manual Install
920
1. Use the Download ZIP option for this project
1021
2. Extract the files and copy path
1122
* This is the path to the directory that contains README.md and LICENSE
@@ -16,7 +27,7 @@ Once installation is complete, a new "Pivot Subscriptions" Link will be added to
1627
do $system.OBJ.Load(path_"/PivotSubscriptions/Installer.cls","ck",,1)
1728
do ##class(PivotSubscriptions.Installer).RunInstaller(path)
1829
```
19-
5. Follow the Configuration steps
30+
5. Follow [Configuration Steps](#configuration-steps)
2031

2132
## Configuration steps
2233
### Configure Task Manager Email Settings

docker-compose.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
version: '3.6'
2+
services:
3+
iris:
4+
build:
5+
context: .
6+
dockerfile: Dockerfile
7+
restart: unless-stopped
8+
ports:
9+
- 61972:1972
10+
- 61773:52773

iris.script

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
zn "%SYS"
2+
Do ##class(Security.Users).UnExpireUserPasswords("*")
3+
4+
zn "USER"
5+
do EnableDeepSee^%SYS.cspServer("/csp/user/")
6+
7+
; install samples-bi to have cubes with test data
8+
zpm "install samples-bi"
9+
10+
; load app
11+
zpm "load /opt/irisapp"

module.xml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<Export generator="Cache" version="25">
3+
<Document name="pivotsubscriptions.ZPM">
4+
<Module>
5+
<Name>pivotsubscriptions</Name>
6+
<Description>Sample portlets for implementing charts from third party libraries in IRIS BI</Description>
7+
<Version>1.8.1</Version>
8+
<Packaging>module</Packaging>
9+
<Resource Name="PivotSubscriptions.PKG"/>
10+
<FileCopy Name="Assets/PivotSubscriptions_Cover.png" Target="${cspdir}broker/covers/PivotSubscriptions_Cover.png"/>
11+
<Invokes>
12+
<Invoke Class="PivotSubscriptions.Installer" Method="RunInstaller">
13+
</Invoke>
14+
</Invokes>
15+
</Module>
16+
</Document>
17+
</Export>

0 commit comments

Comments
 (0)