├── src ├── DotNetNuke.PowerBI │ ├── admin │ │ └── personaBar │ │ │ ├── css │ │ │ └── PBIEmbedded.css │ │ │ ├── PBIEmbedded.html │ │ │ └── scripts │ │ │ └── PBIEmbedded.js │ ├── Providers │ │ └── DataProviders │ │ │ └── SqlDataProvider │ │ │ ├── Uninstall.SqlDataProvider │ │ │ ├── 01.00.06.SqlDataProvider │ │ │ ├── 01.00.21.SqlDataProvider │ │ │ ├── 01.00.07.SqlDataProvider │ │ │ ├── 01.00.00.SqlDataProvider │ │ │ ├── 01.02.00.SqlDataProvider │ │ │ ├── 01.00.02.SqlDataProvider │ │ │ └── 01.00.04.SqlDataProvider │ ├── PBIEmbedded.Web │ │ ├── src │ │ │ ├── actions │ │ │ │ ├── index.js │ │ │ │ └── settings.js │ │ │ ├── components │ │ │ │ ├── permissions │ │ │ │ │ ├── index.jsx │ │ │ │ │ ├── permissions.less │ │ │ │ │ └── pbiObjectsListView │ │ │ │ │ │ └── style.less │ │ │ │ ├── general │ │ │ │ │ ├── index.jsx │ │ │ │ │ ├── img │ │ │ │ │ │ └── pbiembedded.png │ │ │ │ │ ├── generalSettings.less │ │ │ │ │ ├── workspaces │ │ │ │ │ │ ├── workspaceEditor │ │ │ │ │ │ │ └── style.less │ │ │ │ │ │ ├── workspaceRow │ │ │ │ │ │ │ ├── style.less │ │ │ │ │ │ │ └── index.jsx │ │ │ │ │ │ └── style.less │ │ │ │ │ └── generalSettings.jsx │ │ │ │ ├── style.less │ │ │ │ ├── svg │ │ │ │ │ └── error.svg │ │ │ │ └── App.jsx │ │ │ ├── constants │ │ │ │ └── actionTypes │ │ │ │ │ ├── index.js │ │ │ │ │ └── settings.js │ │ │ ├── containers │ │ │ │ ├── Root.js │ │ │ │ ├── Root.prod.js │ │ │ │ └── Root.dev.js │ │ │ ├── reducers │ │ │ │ ├── rootReducer.js │ │ │ │ └── settingsReducer.js │ │ │ ├── resources │ │ │ │ └── index.jsx │ │ │ ├── utils │ │ │ │ └── index.jsx │ │ │ ├── store │ │ │ │ └── configureStore.js │ │ │ ├── globals │ │ │ │ └── application.js │ │ │ ├── main.jsx │ │ │ └── services │ │ │ │ └── applicationService.js │ │ ├── .eslintignore │ │ ├── webpack.build.cmd │ │ ├── webpack.run.cmd │ │ ├── .npmrc │ │ ├── node_modules │ │ │ └── @dnnsoftware │ │ │ │ └── dnn-react-common │ │ │ │ ├── dist │ │ │ │ ├── rw-widgets.eot │ │ │ │ └── rw-widgets.ttf │ │ │ │ ├── jsconfig.json │ │ │ │ ├── LICENSE.txt │ │ │ │ ├── styles │ │ │ │ └── index.less │ │ │ │ ├── dist.webpack.config.js │ │ │ │ ├── WebpackExternals │ │ │ │ └── index.js │ │ │ │ ├── README.md │ │ │ │ └── package.json │ │ ├── jsconfig.json │ │ ├── .babelrc │ │ ├── .eslintrc.js │ │ ├── package.json │ │ ├── .eslintskipwords.js │ │ └── webpack.config.js │ ├── Views │ │ ├── Shared │ │ │ └── _Layout.cshtml │ │ ├── _ViewStart.cshtml │ │ ├── emailtemplate.cshtml │ │ └── ListView │ │ │ └── Index.cshtml │ ├── images │ │ ├── edit.png │ │ ├── chevron.png │ │ ├── delete.png │ │ ├── empty.png │ │ ├── powerbi.png │ │ ├── print.png │ │ ├── refresh.png │ │ ├── reload.png │ │ ├── bookmark.png │ │ ├── addbookmark.png │ │ ├── fullscreen.png │ │ ├── subscription.png │ │ ├── addsubscription.png │ │ ├── editsubscription.png │ │ ├── success.svg │ │ ├── error.svg │ │ ├── downloading.svg │ │ ├── export.svg │ │ ├── download.svg │ │ ├── pdf.svg │ │ ├── powerbi.svg │ │ ├── excel.svg │ │ ├── edit.svg │ │ └── powerpoint.svg │ ├── Models │ │ ├── TileEmbedConfig.cs │ │ ├── ExportedFile.cs │ │ ├── Workspace.cs │ │ ├── PowerBIApiExtensions.cs │ │ ├── PowerBIListView.cs │ │ ├── EmbedConfig.cs │ │ ├── PowerBICalendarView.cs │ │ └── PowerBIListViewExtensions.cs │ ├── Components │ │ ├── Culture.cs │ │ ├── RouteMapper.cs │ │ └── MenuController.cs │ ├── Data │ │ ├── Bookmarks │ │ │ ├── IBookmarksRepository.cs │ │ │ ├── Models │ │ │ │ └── Bookmark.cs │ │ │ └── BookmarksRepository.cs │ │ ├── Subscriptions │ │ │ ├── Models │ │ │ │ ├── SubscriptionSubscriber.cs │ │ │ │ └── Subscription.cs │ │ │ ├── ISubscriptionsRepository.cs │ │ │ ├── ISubscriptionsSubscribersRepository.cs │ │ │ ├── SubscriptionsSubscribersRepository.cs │ │ │ └── SubscriptionsRepository.cs │ │ ├── SharedSettings │ │ │ ├── ISharedSettingsRepository.cs │ │ │ ├── Models │ │ │ │ └── SharedSettings.cs │ │ │ └── SharedSettingsRepository.cs │ │ ├── IObjectPermissionsRepository.cs │ │ └── Models │ │ │ └── ObjectPermission.cs │ ├── Services │ │ ├── Models │ │ │ ├── SavePowerBiObjectsPermissionsInput.cs │ │ │ └── PBIPermissions.cs │ │ ├── IEmbedService.cs │ │ ├── ModuleSettingsController.cs │ │ └── BookmarksController.cs │ ├── package.json │ ├── web.Debug.config │ ├── License.txt │ ├── web.Release.config │ ├── Properties │ │ └── AssemblyInfo.cs │ ├── scripts │ │ ├── Common.js │ │ └── module-settings.js │ ├── Controllers │ │ ├── ListViewController.cs │ │ └── CalendarViewController.cs │ ├── packages.config │ ├── web.config │ └── BuildScripts │ │ └── watch.js ├── DotNetNuke.PowerBI.Extensibility │ ├── IRlsCustomExtension.cs │ ├── Properties │ │ └── AssemblyInfo.cs │ └── DotNetNuke.PowerBI.Extensibility.csproj ├── powershell │ └── file-watcher.ps1 └── DotNetNuke.PowerBI.sln ├── lib └── netstandard.dll ├── docs ├── images │ ├── Architecture.png │ ├── Screenshot1.png │ ├── Screenshot2.png │ ├── Screenshot3.png │ ├── Screenshot4.png │ └── ReleaseBadge.svg └── README.md ├── LICENSE ├── .gitignore └── README.md /src/DotNetNuke.PowerBI/admin/personaBar/css/PBIEmbedded.css: -------------------------------------------------------------------------------- 1 | body { 2 | } 3 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Providers/DataProviders/SqlDataProvider/Uninstall.SqlDataProvider: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /lib/netstandard.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/intelequia/dnn.powerbiembedded/HEAD/lib/netstandard.dll -------------------------------------------------------------------------------- /docs/images/Architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/intelequia/dnn.powerbiembedded/HEAD/docs/images/Architecture.png -------------------------------------------------------------------------------- /docs/images/Screenshot1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/intelequia/dnn.powerbiembedded/HEAD/docs/images/Screenshot1.png -------------------------------------------------------------------------------- /docs/images/Screenshot2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/intelequia/dnn.powerbiembedded/HEAD/docs/images/Screenshot2.png -------------------------------------------------------------------------------- /docs/images/Screenshot3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/intelequia/dnn.powerbiembedded/HEAD/docs/images/Screenshot3.png -------------------------------------------------------------------------------- /docs/images/Screenshot4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/intelequia/dnn.powerbiembedded/HEAD/docs/images/Screenshot4.png -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/actions/index.js: -------------------------------------------------------------------------------- 1 | import settings from "./settings"; 2 | 3 | export { 4 | settings 5 | }; -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Views/Shared/_Layout.cshtml: -------------------------------------------------------------------------------- 1 |
2 | @RenderBody() 3 |
4 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/admin/personaBar/PBIEmbedded.html: -------------------------------------------------------------------------------- 1 |
2 |
-------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/images/edit.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/intelequia/dnn.powerbiembedded/HEAD/src/DotNetNuke.PowerBI/images/edit.png -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/images/chevron.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/intelequia/dnn.powerbiembedded/HEAD/src/DotNetNuke.PowerBI/images/chevron.png -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/images/delete.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/intelequia/dnn.powerbiembedded/HEAD/src/DotNetNuke.PowerBI/images/delete.png -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/images/empty.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/intelequia/dnn.powerbiembedded/HEAD/src/DotNetNuke.PowerBI/images/empty.png -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/images/powerbi.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/intelequia/dnn.powerbiembedded/HEAD/src/DotNetNuke.PowerBI/images/powerbi.png -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/images/print.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/intelequia/dnn.powerbiembedded/HEAD/src/DotNetNuke.PowerBI/images/print.png -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/images/refresh.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/intelequia/dnn.powerbiembedded/HEAD/src/DotNetNuke.PowerBI/images/refresh.png -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/images/reload.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/intelequia/dnn.powerbiembedded/HEAD/src/DotNetNuke.PowerBI/images/reload.png -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/components/permissions/index.jsx: -------------------------------------------------------------------------------- 1 | import Permissions from "./permissions"; 2 | 3 | export default Permissions; -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/constants/actionTypes/index.js: -------------------------------------------------------------------------------- 1 | import settings from "./settings"; 2 | 3 | export { 4 | settings 5 | }; -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/images/bookmark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/intelequia/dnn.powerbiembedded/HEAD/src/DotNetNuke.PowerBI/images/bookmark.png -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Views/_ViewStart.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | Layout = "~/DesktopModules/MVC/PowerBIEmbedded/Views/Shared/_Layout.cshtml"; 3 | } 4 | 5 | 6 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/images/addbookmark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/intelequia/dnn.powerbiembedded/HEAD/src/DotNetNuke.PowerBI/images/addbookmark.png -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/images/fullscreen.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/intelequia/dnn.powerbiembedded/HEAD/src/DotNetNuke.PowerBI/images/fullscreen.png -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/images/subscription.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/intelequia/dnn.powerbiembedded/HEAD/src/DotNetNuke.PowerBI/images/subscription.png -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/components/general/index.jsx: -------------------------------------------------------------------------------- 1 | import GeneralSettings from "./generalSettings"; 2 | 3 | export default GeneralSettings; -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/.eslintignore: -------------------------------------------------------------------------------- 1 | src/components/contentTypeModal/fieldDefinitions/FileUpload/Dropzone.jsx 2 | /src/vendor/** 3 | /src/utils/masker.js -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/webpack.build.cmd: -------------------------------------------------------------------------------- 1 | cls 2 | set NODE_OPTIONS=--openssl-legacy-provider&&SET NODE_ENV=production&& webpack --mode=production 3 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/images/addsubscription.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/intelequia/dnn.powerbiembedded/HEAD/src/DotNetNuke.PowerBI/images/addsubscription.png -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/images/editsubscription.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/intelequia/dnn.powerbiembedded/HEAD/src/DotNetNuke.PowerBI/images/editsubscription.png -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/webpack.run.cmd: -------------------------------------------------------------------------------- 1 | cls 2 | set NODE_OPTIONS=--openssl-legacy-provider&&SET NODE_ENV=development&&SET CUSTOM_DEV=&& webpack-dev-server 3 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/.npmrc: -------------------------------------------------------------------------------- 1 | @dnnsoftware:registry=https://intelequia.pkgs.visualstudio.com/Dnn.React.Common/_packaging/dnn-public/npm/registry/ 2 | always-auth=true -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/components/general/img/pbiembedded.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/intelequia/dnn.powerbiembedded/HEAD/src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/components/general/img/pbiembedded.png -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/containers/Root.js: -------------------------------------------------------------------------------- 1 | /* eslint-disable no-undef */ 2 | if (process.env.NODE_ENV === "production") { 3 | module.exports = require("./Root.prod"); 4 | } else { 5 | module.exports = require("./Root.dev"); 6 | } 7 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/node_modules/@dnnsoftware/dnn-react-common/dist/rw-widgets.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/intelequia/dnn.powerbiembedded/HEAD/src/DotNetNuke.PowerBI/PBIEmbedded.Web/node_modules/@dnnsoftware/dnn-react-common/dist/rw-widgets.eot -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/node_modules/@dnnsoftware/dnn-react-common/dist/rw-widgets.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/intelequia/dnn.powerbiembedded/HEAD/src/DotNetNuke.PowerBI/PBIEmbedded.Web/node_modules/@dnnsoftware/dnn-react-common/dist/rw-widgets.ttf -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/reducers/rootReducer.js: -------------------------------------------------------------------------------- 1 | import { combineReducers } from "redux"; 2 | import settings from "./settingsReducer"; 3 | 4 | const rootReducer = combineReducers({ 5 | settings 6 | }); 7 | 8 | export default rootReducer; 9 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI.Extensibility/IRlsCustomExtension.cs: -------------------------------------------------------------------------------- 1 | using System.Web; 2 | 3 | namespace DotNetNuke.PowerBI.Extensibility 4 | { 5 | public interface IRlsCustomExtension 6 | { 7 | string GetRlsValue(HttpContext httpContext); 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Models/TileEmbedConfig.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace DotNetNuke.PowerBI.Models 4 | { 5 | [Serializable] 6 | public class TileEmbedConfig : EmbedConfig 7 | { 8 | public string dashboardId { get; set; } 9 | } 10 | } -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Components/Culture.cs: -------------------------------------------------------------------------------- 1 | namespace DotNetNuke.PowerBI.Components 2 | { 3 | public class Culture 4 | { 5 | public int LanguageId { get; set; } 6 | public string Code { get; set; } 7 | public string Name { get; set; } 8 | } 9 | } -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/resources/index.jsx: -------------------------------------------------------------------------------- 1 | import util from "../utils"; 2 | 3 | const resx = { 4 | get(key) { 5 | let moduleName = util.moduleName; 6 | return util.utilities.getResx(moduleName, key); 7 | } 8 | }; 9 | export default resx; -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/images/success.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/utils/index.jsx: -------------------------------------------------------------------------------- 1 | const utils = { 2 | init(utilities) { 3 | if (!utilities) { 4 | throw new Error("Utilities is undefined."); 5 | } 6 | this.utilities = utilities; 7 | }, 8 | utilities: null 9 | }; 10 | export default utils; -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Models/ExportedFile.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.IO; 4 | using System.Linq; 5 | using System.Web; 6 | 7 | namespace DotNetNuke.PowerBI.Models 8 | { 9 | public class ExportedFile 10 | { 11 | public Stream FileStream; 12 | public string FileSuffix; 13 | } 14 | } -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/images/error.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/containers/Root.prod.js: -------------------------------------------------------------------------------- 1 | import React, {Component} from "react"; 2 | import App from "../components/App"; 3 | 4 | class Root extends Component { 5 | render() { 6 | return ( 7 |
8 | 9 |
10 | ); 11 | } 12 | } 13 | 14 | export default Root; -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/jsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | // See https://go.microsoft.com/fwlink/?LinkId=759670 3 | // for the documentation about the jsconfig.json format 4 | "compilerOptions": { 5 | "target": "es6", 6 | "module": "commonjs", 7 | "allowSyntheticDefaultImports": true 8 | }, 9 | "exclude": [ 10 | "node_modules" 11 | ] 12 | } -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/containers/Root.dev.js: -------------------------------------------------------------------------------- 1 | import React, {Component} from "react"; 2 | import App from "../components/App"; 3 | 4 | class Root extends Component { 5 | render() { 6 | return ( 7 |
8 | 9 |
10 | ); 11 | } 12 | } 13 | 14 | export default Root; 15 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/node_modules/@dnnsoftware/dnn-react-common/jsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | // See https://go.microsoft.com/fwlink/?LinkId=759670 3 | // for the documentation about the jsconfig.json format 4 | "compilerOptions": { 5 | "target": "es6", 6 | "module": "commonjs", 7 | "allowSyntheticDefaultImports": true 8 | }, 9 | "exclude": [ 10 | "node_modules" 11 | ] 12 | } 13 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Providers/DataProviders/SqlDataProvider/01.00.06.SqlDataProvider: -------------------------------------------------------------------------------- 1 | IF (NOT EXISTS(SELECT * FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_NAME = '{objectQualifier}PBI_Settings' AND COLUMN_NAME='InheritPermissions')) 2 | BEGIN 3 | ALTER TABLE {databaseOwner}[{objectQualifier}PBI_Settings] ADD 4 | InheritPermissions bit NOT NULL CONSTRAINT DF_{objectQualifier}PBI_Settings_InheritPermissions DEFAULT (0) 5 | END 6 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/.babelrc: -------------------------------------------------------------------------------- 1 | { 2 | "presets": [ 3 | "@babel/preset-env", 4 | "@babel/preset-react" 5 | ], 6 | "plugins": [ 7 | "@babel/plugin-transform-react-jsx", 8 | "@babel/plugin-proposal-object-rest-spread", 9 | "react-hot-loader/babel" 10 | ], 11 | "env": { 12 | "production": { 13 | "plugins": [ 14 | "transform-react-remove-prop-types" 15 | ] 16 | } 17 | } 18 | } -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/components/style.less: -------------------------------------------------------------------------------- 1 | #PBIEmbeddedAppContainer { 2 | 3 | @primary-blue-color: #02a1e6; 4 | 5 | .dnn-persona-bar-page-body .persona-bar-page-body { 6 | 7 | .dnn-switch-container .dnn-switch.place-left { 8 | margin-left: 0px; 9 | } 10 | 11 | button.dnn-ui-common-button[role=primary] { 12 | margin-left: 10px; 13 | } 14 | } 15 | } -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Providers/DataProviders/SqlDataProvider/01.00.21.SqlDataProvider: -------------------------------------------------------------------------------- 1 | IF (NOT EXISTS(SELECT * FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_NAME = '{objectQualifier}PBI_Settings' AND COLUMN_NAME='DisabledCapacityMessage')) 2 | BEGIN 3 | ALTER TABLE {databaseOwner}[{objectQualifier}PBI_Settings] 4 | ADD DisabledCapacityMessage nvarchar(max) NOT NULL CONSTRAINT [DF_PBI_Settings_DisabledCapacityMessage] DEFAULT (('')) 5 | END 6 | 7 | 8 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/images/downloading.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 10 | 11 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/images/export.svg: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/images/download.svg: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Data/Bookmarks/IBookmarksRepository.cs: -------------------------------------------------------------------------------- 1 | using DotNetNuke.PowerBI.Data.Bookmarks.Models; 2 | using System.Collections.Generic; 3 | 4 | 5 | namespace DotNetNuke.PowerBI.Data.Bookmarks 6 | { 7 | public interface IBookmarksRepository 8 | { 9 | List GetBookmarks(string reportId, int currentPortalId); 10 | List GetBookmarksByUser(int portalId, string reportId, int userId); 11 | int SaveBookmark(Bookmark bookmark); 12 | bool DeleteBookmark(int bookmarkId); 13 | } 14 | } -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Models/Workspace.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Runtime.Serialization; 3 | 4 | namespace DotNetNuke.PowerBI.Models 5 | { 6 | [Serializable] 7 | [DataContract] 8 | public class Workspace 9 | { 10 | [DataMember] 11 | public string Id { get; set; } 12 | [DataMember] 13 | public string Name { get; set; } 14 | [DataMember] 15 | public int SettingsId { get; set; } 16 | [DataMember] 17 | public bool InheritPermissions { get; set; } 18 | } 19 | } -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Components/RouteMapper.cs: -------------------------------------------------------------------------------- 1 | using DotNetNuke.Web.Api; 2 | 3 | namespace DotNetNuke.PowerBI.Components 4 | { 5 | public class RouteMapper : IServiceRouteMapper 6 | { 7 | public void RegisterRoutes(IMapRoute routeManager) 8 | { 9 | routeManager.MapHttpRoute("PowerBI/UI", "default", "{controller}/{action}", new[] { "DotNetNuke.PowerBI.Controllers.Api.Admin" }); 10 | routeManager.MapHttpRoute("PowerBI/Services", "default", "{controller}/{action}", new[] { "DotNetNuke.PowerBI.Services" }); 11 | } 12 | 13 | } 14 | } -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/store/configureStore.js: -------------------------------------------------------------------------------- 1 | import { createStore, applyMiddleware, compose } from "redux"; 2 | import thunkMiddleware from "redux-thunk"; 3 | import reduxImmutableStateInvariant from "redux-immutable-state-invariant"; 4 | import rootReducer from "../reducers/rootReducer"; 5 | 6 | export default function configureStore(initialState) { 7 | const store = createStore( 8 | rootReducer, 9 | initialState, 10 | compose( 11 | applyMiddleware(thunkMiddleware, 12 | reduxImmutableStateInvariant()), 13 | ) 14 | ); 15 | return store; 16 | } 17 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Providers/DataProviders/SqlDataProvider/01.00.07.SqlDataProvider: -------------------------------------------------------------------------------- 1 | IF (NOT EXISTS(SELECT * FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_NAME = 'PBI_Bookmarks')) 2 | BEGIN 3 | CREATE TABLE {databaseOwner}[{objectQualifier}PBI_Bookmarks]( 4 | [Id] [int] IDENTITY(1,1) NOT NULL, 5 | [PortalId] [int] NOT NULL, 6 | [ReportId] [nvarchar](100) NOT NULL, 7 | [DisplayName] [nvarchar](100) NOT NULL, 8 | [Name] [nvarchar](100) NOT NULL, 9 | [State] [nvarchar](max) NOT NULL, 10 | [CreatedOn] [date] NOT NULL, 11 | [CreatedBy] [int] NOT NULL 12 | CONSTRAINT [PK_PBI_Bookmarks] PRIMARY KEY CLUSTERED 13 | ( 14 | [Id] ASC 15 | ) 16 | ) 17 | END 18 | 19 | 20 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Data/Subscriptions/Models/SubscriptionSubscriber.cs: -------------------------------------------------------------------------------- 1 | using DotNetNuke.ComponentModel.DataAnnotations; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Linq; 5 | using System.Web; 6 | 7 | namespace DotNetNuke.PowerBI.Data.Subscriptions.Models 8 | { 9 | [TableName("PBI_SubscriptionSubscribers")] 10 | [PrimaryKey("Id", AutoIncrement = true)] 11 | public class SubscriptionSubscriber 12 | { 13 | public int Id { get; set; } 14 | public int SubscriptionId { get; set; } 15 | public int? UserId { get; set; } 16 | public int? RoleId { get; set; } 17 | public DateTime CreatedOn { get; set; } 18 | public int CreatedBy { get; set; } 19 | } 20 | } -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/constants/actionTypes/settings.js: -------------------------------------------------------------------------------- 1 | const settingsActionTypes = { 2 | SWITCH_TAB: "SWITCH_TAB", 3 | UPDATED_WORKSPACE: "UPDATED_WORKSPACE", 4 | RETRIEVED_WORKSPACES: "RETRIEVED_WORKSPACES", 5 | CANCELLED_WORKSPACE_CLIENT_MODIFIED: "CANCELLED_WORKSPACE_CLIENT_MODIFIED", 6 | WORKSPACE_CLIENT_MODIFIED: "WORKSPACE_CLIENT_MODIFIED", 7 | PERMISSIONS_CLIENT_MODIFIED: "PERMISSIONS_CLIENT_MODIFIED", 8 | RETRIEVED_POWERBI_OBJECT_LIST: "RETRIEVED_POWERBI_OBJECT_LIST", 9 | SELECTED_POWERBI_OBJECT: "SELECTED_POWERBI_OBJECT", 10 | PERMISSIONS_CHANGED: "PERMISSIONS_CHANGED", 11 | INHERIT_PERMISSIONS_CHANGED: "INHERIT_PERMISSIONS_CHANGED" 12 | }; 13 | export default settingsActionTypes; -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/globals/application.js: -------------------------------------------------------------------------------- 1 | import utilities from "../utils"; 2 | const boilerPlate = { 3 | init() { 4 | // This setting is required and define the public path 5 | // to allow the web application to download assets on demand 6 | // eslint-disable-next-line no-undef 7 | // __webpack_public_path__ = options.publicPath; 8 | let options = window.dnn.initPbiEmbedded(); 9 | 10 | utilities.init(options.utility); 11 | utilities.moduleName = options.moduleName; 12 | 13 | }, 14 | dispatch() { 15 | throw new Error("dispatch method needs to be overwritten from the Redux store"); 16 | } 17 | }; 18 | 19 | 20 | export default boilerPlate; -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Services/Models/SavePowerBiObjectsPermissionsInput.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | 3 | namespace DotNetNuke.PowerBI.Services.Models 4 | { 5 | public class SavePowerBiObjectsPermissionsInput 6 | { 7 | public enum ObjectType 8 | { 9 | Report = 0, 10 | Dashboard = 1 11 | } 12 | public class PowerBiObject 13 | { 14 | public string Id; 15 | public string Name; 16 | public ObjectType PowerBiType; 17 | public PBIPermissions Permissions; 18 | } 19 | 20 | public int settingsId; 21 | public bool inheritPermissions; 22 | public List powerBiObjects; 23 | } 24 | } -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Models/PowerBIApiExtensions.cs: -------------------------------------------------------------------------------- 1 | namespace DotNetNuke.PowerBI.Models 2 | { 3 | using Microsoft.PowerBI.Api.Models; 4 | using System; 5 | 6 | public static class PowerBIApiExtensions 7 | { 8 | public static int ToInteger(this Days day) 9 | { 10 | if (day == Days.Monday) return 0; 11 | if (day == Days.Tuesday) return 1; 12 | if (day == Days.Wednesday) return 2; 13 | if (day == Days.Thursday) return 3; 14 | if (day == Days.Friday) return 4; 15 | if (day == Days.Saturday) return 5; 16 | if (day == Days.Sunday) return 6; 17 | throw new ArgumentOutOfRangeException(nameof(day)); 18 | } 19 | 20 | } 21 | } -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/main.jsx: -------------------------------------------------------------------------------- 1 | import React from "react"; 2 | import { render } from "react-dom"; 3 | import { Provider } from "react-redux"; 4 | import application from "./globals/application"; 5 | import configureStore from "./store/configureStore"; 6 | import Root from "./containers/Root"; 7 | 8 | let store = configureStore({enabled: false, instrumentationKey: ""}); 9 | 10 | application.dispatch = store.dispatch; 11 | 12 | const appContainer = document.getElementById("pbiEmbedded-container"); 13 | const initCallback = appContainer.getAttribute("data-init-callback"); 14 | application.init(initCallback); 15 | 16 | render( 17 | 18 | 19 | , 20 | appContainer 21 | ); 22 | 23 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Data/SharedSettings/ISharedSettingsRepository.cs: -------------------------------------------------------------------------------- 1 | using DotNetNuke.PowerBI.Data.Models; 2 | using System.Collections.Generic; 3 | 4 | namespace DotNetNuke.PowerBI.Data.SharedSettings 5 | { 6 | public interface ISharedSettingsRepository 7 | { 8 | PowerBISettings GetSettingsById(int settingId, int portalId); 9 | PowerBISettings GetSettingsByGroupId(string settingGroupId, int portalId); 10 | List GetSettings(int portalId); 11 | List GetAllSettings(); 12 | bool AddSettings(PowerBISettings setting, int portalId, int? userId); 13 | bool UpdateSettings(PowerBISettings settings, int portalId); 14 | bool DeleteSetting(int settingId, int portalId); 15 | } 16 | } -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Data/Subscriptions/ISubscriptionsRepository.cs: -------------------------------------------------------------------------------- 1 | using DotNetNuke.PowerBI.Data.Subscriptions.Models; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Linq; 5 | using System.Text; 6 | using System.Threading.Tasks; 7 | 8 | namespace DotNetNuke.PowerBI.Data.Subscriptions 9 | { 10 | public interface ISubscriptionsRepository 11 | { 12 | int AddSubscription(Subscription subscription); 13 | bool EditSubscription(Subscription subscription); 14 | bool DeleteSubscription(int subscriptionId); 15 | Subscription GetSubscriptionById(int subscriptionId); 16 | List GetSubscriptionsByReportId(string reportId, int currentPortalId); 17 | List GetSubscriptionsByWorkspaceId(string workspaceId, int currentPortalId); 18 | 19 | 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Data/Subscriptions/ISubscriptionsSubscribersRepository.cs: -------------------------------------------------------------------------------- 1 | using DotNetNuke.PowerBI.Data.Subscriptions.Models; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Linq; 5 | using System.Text; 6 | using System.Threading.Tasks; 7 | 8 | namespace DotNetNuke.PowerBI.Data.Subscriptions 9 | { 10 | public interface ISubscriptionsSubscribersRepository 11 | { 12 | bool AddSubscriptionSubscriber(SubscriptionSubscriber subscriptionSubscriber); 13 | bool EditSubscriptionSubscriber(SubscriptionSubscriber subscriptionSubscriber); 14 | bool DeleteSubscriptionSubscriber(int subscriptionSubscriberId); 15 | List GetSubscribersBySubscription(int subscriptionId); 16 | SubscriptionSubscriber GetSubscriptionSubscriberById(int subscriptionSubscriberId); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Models/PowerBIListView.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.PowerBI.Api.Models; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Runtime.Serialization; 5 | 6 | namespace DotNetNuke.PowerBI.Models 7 | { 8 | [Serializable] 9 | [DataContract] 10 | public class PowerBIListView 11 | { 12 | public PowerBIListView() 13 | { 14 | Reports = new List(); 15 | Dashboards = new List(); 16 | Workspaces = new List(); 17 | } 18 | [DataMember] 19 | public string WorkspaceId { get; set; } 20 | [DataMember] 21 | public List Reports { get; set; } 22 | [DataMember] 23 | public List Dashboards { get; set; } 24 | [DataMember] 25 | public List Workspaces { get; set; } 26 | } 27 | } -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Providers/DataProviders/SqlDataProvider/01.00.00.SqlDataProvider: -------------------------------------------------------------------------------- 1 | /************************************************************/ 2 | /***** SqlDataProvider *****/ 3 | /***** *****/ 4 | /***** *****/ 5 | /***** Note: To manually execute this script you must *****/ 6 | /***** perform a search and replace operation *****/ 7 | /***** for {databaseOwner} and {objectQualifier} *****/ 8 | /***** *****/ 9 | /************************************************************/ 10 | 11 | 12 | /************************************************************/ 13 | /***** SqlDataProvider *****/ 14 | /************************************************************/ -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/components/svg/error.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 5 | 8 | 12 | 13 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Services/IEmbedService.cs: -------------------------------------------------------------------------------- 1 | using DotNetNuke.PowerBI.Data.Models; 2 | using DotNetNuke.PowerBI.Models; 3 | using System.Threading.Tasks; 4 | 5 | namespace DotNetNuke.PowerBI.Services 6 | { 7 | public interface IEmbedService 8 | { 9 | EmbedConfig EmbedConfig { get; } 10 | TileEmbedConfig TileEmbedConfig { get; } 11 | PowerBISettings Settings { get; } 12 | 13 | Task GetContentListAsync(int userId); 14 | Task GetReportEmbedConfigAsync(int userId, string userName, string roles, string reportId, bool hasEditPermission); 15 | Task GetDashboardEmbedConfigAsync(int userId, string userName, string roles, string dashboardId, bool hasEditPermission); 16 | Task GetTileEmbedConfigAsync(int userId, string tileId, string dashboardId, bool hasEditPermission); 17 | } 18 | } -------------------------------------------------------------------------------- /docs/images/ReleaseBadge.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | release 14 | release 15 | v1.3.1 16 | v1.3.1 17 | 18 | 19 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "dotnetnuke.powerbi", 3 | "version": "00.00.00", 4 | "description": "DNN module", 5 | "author": "Intelequia", 6 | "license": "UNLICENSED", 7 | "keywords": [ 8 | "dnn", 9 | "module" 10 | ], 11 | "main": "index.js", 12 | "dnn": { 13 | "mode": "module", 14 | "copyBin": true, 15 | "localhost": "localhost", 16 | "dnnRoot": "C:/websites/localhost.dnndev.me", 17 | "assemblyName": "DotNetNuke.PowerBI", 18 | "folderName": "MVC/PowerBIEmbedded", 19 | "owner": { 20 | "name": "Intelequia", 21 | "organization": "Intelequia", 22 | "url": "https://intelequia.com", 23 | "email": "support@intelequia.com" 24 | } 25 | }, 26 | "scripts": { 27 | "test": "echo \"Error: no test specified\" && exit 1", 28 | "build": "", 29 | "watch": "concurrently \"yarn:watch-*\"", 30 | "watch-js": "node BuildScripts/watch.js" 31 | }, 32 | "devDependencies": { 33 | "chokidar": "^3.5.3", 34 | "concurrently": "^7.6.0", 35 | "fs-extra": "^11.1.0" 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2020 Intelequia Software Solutions 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | /src/.vs 2 | /src/bin 3 | /src/packages 4 | /src/DotNetNuke.PowerBI/obj 5 | /src/DotNetNuke.PowerBI/install 6 | /src/DotNetNuke.PowerBI/*.user 7 | /src/DotNetNuke.PowerBI/PBIEmbedded.Web/node_modules 8 | /src/Releases 9 | /src/DotNetNuke.PowerBI/PBIEmbedded.Web/package-lock.json 10 | /src/DotNetNuke.PowerBI/.vs/DotNetNuke.PowerBI/v16 11 | /src/DotNetNuke.PowerBI/.vs 12 | /src/DotNetNuke.PowerBI.sln.DotSettings.user 13 | /src/DotNetNuke.PowerBI.Extensibility/bin 14 | /src/DotNetNuke.PowerBI.Extensibility/obj 15 | *.user 16 | 17 | # User-specific files 18 | *.suo 19 | *.user 20 | *.userosscache 21 | *.sln.docstates 22 | 23 | # Build results 24 | [Dd]ebug/ 25 | [Dd]ebugPublic/ 26 | [Rr]elease/ 27 | [Rr]eleases/ 28 | [Xx]64/ 29 | [Xx]86/ 30 | [Bb]uild/ 31 | bld/ 32 | [Bb]in/ 33 | [Oo]bj/ 34 | [Dd]ist/ 35 | 36 | #Ignore Install folder 37 | [Ii]nstall/ 38 | 39 | #Ignore build files and folders 40 | [Rr]esources[Zz]ip/ 41 | [Ii]nstall[Pp]ackage/ 42 | 43 | #Ignore css map file 44 | *.css.map 45 | 46 | # Others 47 | ClientBin/ 48 | [Ss]tyle[Cc]op.* 49 | ~$* 50 | *~ 51 | *.dbmdl 52 | *.dbproj.schemaview 53 | *.pfx 54 | *.publishsettings 55 | node_modules/ 56 | orleans.codegen.cs 57 | .vs/ 58 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Models/EmbedConfig.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.PowerBI.Api.Models; 2 | using System; 3 | 4 | namespace DotNetNuke.PowerBI.Models 5 | { 6 | [Serializable] 7 | public class EmbedConfig 8 | { 9 | public EmbedConfig() 10 | { 11 | ContentType = "report"; 12 | ReportType = "PowerBIReport"; 13 | } 14 | public string Id { get; set; } 15 | public string EmbedUrl { get; set; } 16 | public EmbedToken EmbedToken { get; set; } 17 | public int MinutesToExpiration 18 | { 19 | get 20 | { 21 | var minutesToExpiration = EmbedToken.Expiration - DateTime.UtcNow; 22 | return (int)minutesToExpiration.TotalMinutes; 23 | } 24 | } 25 | public bool? IsEffectiveIdentityRolesRequired { get; set; } 26 | public bool? IsEffectiveIdentityRequired { get; set; } 27 | public bool EnableRLS { get; set; } 28 | public string Username { get; set; } 29 | public string Roles { get; set; } 30 | public string ErrorMessage { get; internal set; } 31 | public string ContentType { get; set; } 32 | public string ReportType { get; set; } 33 | public bool IsCapacityDisabled { get; set; } 34 | } 35 | } -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | "plugins": [ 3 | "react" 4 | ], 5 | "env": { 6 | "browser": true, 7 | "commonjs": true 8 | }, 9 | "extends": ["eslint:recommended", "plugin:react/recommended"], 10 | "settings": { 11 | "react": { 12 | "version": "16" 13 | } 14 | }, 15 | "parserOptions": { 16 | "ecmaFeatures": { 17 | "jsx": true 18 | }, 19 | "ecmaVersion": 2018, 20 | "sourceType": "module" 21 | }, 22 | "globals": { 23 | "__": false, 24 | "Promise": false, 25 | "VERSION": false 26 | }, 27 | "rules": { 28 | "semi": "error", 29 | "no-var": "error", 30 | "quotes": ["warn", "double" ], 31 | "indent": ["warn", 4, {"SwitchCase": 1}], 32 | "no-unused-vars": "warn", 33 | "no-console": "warn", 34 | "keyword-spacing": "warn", 35 | "eqeqeq": "warn", 36 | "space-before-function-paren": ["warn", { "anonymous": "always", "named": "never" }], 37 | "space-before-blocks": "warn", 38 | "no-multiple-empty-lines": "warn", 39 | "react/jsx-equals-spacing": ["warn", "never"], 40 | "id-match": ["error", "^([A-Za-z0-9_])+$", {"properties": true}] 41 | } 42 | }; 43 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Data/Bookmarks/Models/Bookmark.cs: -------------------------------------------------------------------------------- 1 | using DotNetNuke.ComponentModel.DataAnnotations; 2 | using DotNetNuke.PowerBI.Services; 3 | using System; 4 | 5 | namespace DotNetNuke.PowerBI.Data.Bookmarks.Models 6 | { 7 | [TableName("PBI_Bookmarks")] 8 | //setup the primary key for table 9 | [PrimaryKey("Id", AutoIncrement = true)] 10 | //scope the objects to the ModuleId of a module on a page (or copy of a module on a page) 11 | [Scope("PortalId")] 12 | public class Bookmark 13 | { 14 | public Bookmark() 15 | { 16 | } 17 | public Bookmark(BookmarksController.BookmarkViewModel bookmarkViewModel, int userId, int portalId) 18 | { 19 | Name = bookmarkViewModel.name; 20 | DisplayName = bookmarkViewModel.displayName; 21 | State = bookmarkViewModel.state; 22 | ReportId = bookmarkViewModel.reportId; 23 | PortalId = portalId; 24 | } 25 | public int Id { get; set; } 26 | public int PortalId { get; set; } 27 | public string ReportId { get; set; } 28 | public string DisplayName { get; set; } 29 | public string Name { get; set; } 30 | public string State { get; set; } 31 | public DateTime CreatedOn { get; set; } 32 | public int CreatedBy { get; set; } 33 | } 34 | } -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Data/IObjectPermissionsRepository.cs: -------------------------------------------------------------------------------- 1 | using DotNetNuke.Entities.Users; 2 | using DotNetNuke.PowerBI.Data.Models; 3 | using System.Linq; 4 | 5 | namespace DotNetNuke.PowerBI.Data 6 | { 7 | public interface IObjectPermissionsRepository 8 | { 9 | IQueryable GetObjectPermissions(string powerBiObjectId, int portalId); 10 | IQueryable GetObjectPermissionsExtended(string powerBiObjectId, int portalId); 11 | IQueryable GetObjectPermissionsByPortal(int portalId); 12 | IQueryable GetObjectPermissionsByPortalExtended(int portalId); 13 | ObjectPermission GetObjectPermission(string powerBiObjectId, int portalId, int permissionId); 14 | bool CreateObjectPermission(string powerBiObjectId, int permissionId, bool allowAccess, int portalId, int? roleId, int? userId); 15 | bool SaveObjectPermission(string powerBiObjectId, int permissionId, bool allowAccess, int portalId, int? roleId, int? userId); 16 | bool DeleteObjectPermission(string powerBiObjectId, int portalId, int permissionId); 17 | bool DeleteObjectPermissions(string powerBiObjectId, int portalId); 18 | bool DeleteObjectPermissions(int portalId); 19 | bool HasPermissions(string powerBiObjectId, int portalId, int permissionId, UserInfo user); 20 | } 21 | } -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/web.Debug.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 17 | 18 | 29 | 30 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/License.txt: -------------------------------------------------------------------------------- 1 |
2 |

License

3 |

4 | Intelequia https://intelequia.com
5 | Copyright (c) 2025
6 | by Intelequia
7 |

8 |

9 | Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated 10 | documentation files (the "Software"), to deal in the Software without restriction, including without limitation 11 | the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and 12 | to permit persons to whom the Software is furnished to do so, subject to the following conditions: 13 |

14 |

15 | The above copyright notice and this permission notice shall be included in all copies or substantial portions 16 | of the Software. 17 |

18 |

19 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 20 |

21 |
-------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/node_modules/@dnnsoftware/dnn-react-common/LICENSE.txt: -------------------------------------------------------------------------------- 1 |
2 |

License

3 |

4 | Copyright (c) .NET Foundation and Contributors
5 | All Rights Reserved 6 |

7 |

8 | Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated 9 | documentation files (the "Software"), to deal in the Software without restriction, including without limitation 10 | the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and 11 | to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 |

13 |

14 | The above copyright notice and this permission notice shall be included in all copies or substantial portions 15 | of the Software. 16 |

17 |

18 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 19 |

20 |
-------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/services/applicationService.js: -------------------------------------------------------------------------------- 1 | import util from "../utils"; 2 | class ApplicationService { 3 | getServiceFramework(controller) { 4 | let sf = util.utilities.sf; 5 | sf.controller = controller; 6 | return sf; 7 | } 8 | 9 | getWorkspaces(callback) { 10 | const sf = this.getServiceFramework("PBIEmbedded"); 11 | sf.get("GetWorkspaces", {}, callback); 12 | } 13 | 14 | updateWorkspace(payload, callback, failureCallback) { 15 | const sf = this.getServiceFramework("PBIEmbedded"); 16 | sf.post("UpdateWorkspace", payload, callback, failureCallback); 17 | } 18 | 19 | deleteWorkspace(payload, callback, failureCallback) { 20 | const sf = this.getServiceFramework("PBIEmbedded"); 21 | sf.post("DeleteWorkspace", payload, callback, failureCallback); 22 | } 23 | 24 | getPowerBiObjectList(settingsId, callback) { 25 | const sf = this.getServiceFramework("PBIEmbedded"); 26 | sf.get("GetPowerBiObjectList", {settingsId: settingsId}, callback); 27 | } 28 | 29 | updatePermissions(payload, callback, failureCallback) { 30 | const sf = this.getServiceFramework("PBIEmbedded"); 31 | sf.post("SavePowerBiObjectsPermissions", payload, callback, failureCallback); 32 | } 33 | } 34 | const applicationService = new ApplicationService(); 35 | export default applicationService; -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/web.Release.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 17 | 18 | 19 | 30 | 31 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/node_modules/@dnnsoftware/dnn-react-common/styles/index.less: -------------------------------------------------------------------------------- 1 | /* START EVOQ COLOR PALETTE */ 2 | 3 | @blackPearl: #0B1C24; 4 | @firefly: #0E2936; 5 | @astronautBlue: #1E485E; 6 | @matisse: #226F9B; 7 | @curiousBlue: #1E88C3; 8 | @curiousBlueSolid: rgba(30, 136, 195, 0.6); 9 | @curiousBlueWithOpacity: rgba(30, 136, 195, 0.6); 10 | @cerulean: #21A3DA; 11 | @seagull: #79BFDB; 12 | @nonPhotoBlue: #9FDBF0; 13 | @solitude: #EAF1FA; 14 | 15 | @gondola: #261516; 16 | @bulgarianRose: #46292B; 17 | 18 | @astral: #3C7A9A; 19 | @regentGray: #8191A4; 20 | 21 | @thunder: #4B4E4F; 22 | @rollingStone: #6F7273; 23 | @mountainMist: #959695; 24 | @alto: #C8C8C8; 25 | @mercury: #E5E7E6; 26 | @gallery: #EFF0F0; 27 | @alabaster: #FBFCFC; 28 | @white: #FFFFFF; 29 | 30 | /* END EVOQ COLOR PALETTE */ 31 | 32 | 33 | /* START ATTENTION COLORS */ 34 | 35 | @alizarinCrimson: #EA2134; 36 | @cranberry: #D9577A; 37 | 38 | @amazon: #368254; 39 | @mantis: #78C16B; 40 | 41 | /* END ATTENTION COLORS */ 42 | 43 | /* SVG HOVER STATES */ 44 | 45 | svg { 46 | fill: @alto; 47 | &:hover { 48 | fill: @rollingStone; 49 | } 50 | &:active { 51 | fill: @curiousBlue; 52 | } 53 | } 54 | 55 | /* END SVG HOVER STATES */ 56 | 57 | .prefixes(@property, @value) { 58 | -webkit-@{property}: @value; 59 | -khtml-@{property}: @value; 60 | -moz-@{property}: @value; 61 | -ms-@{property}: @value; 62 | @{property}: @value; 63 | } 64 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Data/Models/ObjectPermission.cs: -------------------------------------------------------------------------------- 1 | using DotNetNuke.ComponentModel.DataAnnotations; 2 | using System; 3 | using System.Web.Caching; 4 | 5 | namespace DotNetNuke.PowerBI.Data.Models 6 | { 7 | [TableName("PBI_ObjectPermission")] 8 | //setup the primary key for table 9 | [PrimaryKey("ID", AutoIncrement = false)] 10 | //configure caching using PetaPoco 11 | [Cacheable("PBI_ObjectPermissions", CacheItemPriority.Default, 20)] 12 | //scope the objects to the ModuleId of a module on a page (or copy of a module on a page) 13 | //[Scope("ModuleId")] 14 | public class ObjectPermission 15 | { 16 | public Guid ID { get; set; } // This field is here just because DAL2 doesn't support a primary key with multiple columns (in this table, the primary key should be PowerBiObjectID,PermissionID) 17 | public string PowerBiObjectID { get; set; } 18 | public int PermissionID { get; set; } 19 | public bool AllowAccess { get; set; } 20 | public int PortalID { get; set; } 21 | public int? RoleID { get; set; } 22 | public int? UserID { get; set; } 23 | public int CreatedByUserID { get; set; } 24 | public DateTime CreatedOnDate { get; set; } 25 | public int LastModifiedByUserID { get; set; } 26 | public DateTime LastModifiedOnDate { get; set; } 27 | [IgnoreColumn] 28 | public string UserDisplayName { get; set; } 29 | [IgnoreColumn] 30 | public string RoleName { get; set; } 31 | } 32 | } -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI.Extensibility/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.InteropServices; 3 | 4 | // General Information about an assembly is controlled through the following 5 | // set of attributes. Change these attribute values to modify the information 6 | // associated with an assembly. 7 | [assembly: AssemblyTitle("DotNetNuke.PowerBI.Extensibility")] 8 | [assembly: AssemblyDescription("")] 9 | [assembly: AssemblyConfiguration("")] 10 | [assembly: AssemblyCompany("")] 11 | [assembly: AssemblyProduct("DotNetNuke.PowerBI.Extensibility")] 12 | [assembly: AssemblyCopyright("Copyright © 2023 Intelequia")] 13 | [assembly: AssemblyTrademark("")] 14 | [assembly: AssemblyCulture("")] 15 | 16 | // Setting ComVisible to false makes the types in this assembly not visible 17 | // to COM components. If you need to access a type in this assembly from 18 | // COM, set the ComVisible attribute to true on that type. 19 | [assembly: ComVisible(false)] 20 | 21 | // The following GUID is for the ID of the typelib if this project is exposed to COM 22 | [assembly: Guid("9f36c975-b6b9-49e8-a98b-5085076e3206")] 23 | 24 | // Version information for an assembly consists of the following four values: 25 | // 26 | // Major Version 27 | // Minor Version 28 | // Build Number 29 | // Revision 30 | // 31 | // You can specify all the values or you can default the Build and Revision Numbers 32 | // by using the '*' as shown below: 33 | // [assembly: AssemblyVersion("1.0.*")] 34 | [assembly: AssemblyVersion("1.0.0.0")] 35 | [assembly: AssemblyFileVersion("1.0.0.0")] 36 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Data/Subscriptions/Models/Subscription.cs: -------------------------------------------------------------------------------- 1 | using DotNetNuke.ComponentModel.DataAnnotations; 2 | using DotNetNuke.Entities.Users; 3 | using DotNetNuke.Security.Roles; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.ComponentModel.DataAnnotations.Schema; 7 | using System.Linq; 8 | using System.Web; 9 | 10 | namespace DotNetNuke.PowerBI.Data.Subscriptions.Models 11 | { 12 | [TableName("PBI_Subscriptions")] 13 | [PrimaryKey("Id", AutoIncrement = true)] 14 | [Scope("PortalId")] 15 | public class Subscription 16 | { 17 | public int Id { get; set; } 18 | public int PortalId { get; set; } 19 | public string ReportId { get; set; } 20 | public string GroupId { get; set; } 21 | public int ModuleId { get; set; } 22 | public string Name { get; set; } 23 | public DateTime StartDate { get; set; } 24 | public DateTime EndDate { get; set; } 25 | public string RepeatPeriod { get; set; } 26 | public TimeSpan RepeatTime { get; set; } 27 | public string TimeZone { get; set; } 28 | public string EmailSubject { get; set; } 29 | public string Message { get; set; } 30 | public string ReportPages { get; set; } 31 | public bool Enabled { get; set; } 32 | public DateTime CreatedOn { get; set; } 33 | public int CreatedBy { get; set; } 34 | public DateTime? LastProcessedOn { get; set; } 35 | 36 | [IgnoreColumn] 37 | public string Users { get; set; } 38 | 39 | [IgnoreColumn] 40 | public string Roles { get; set; } 41 | } 42 | } 43 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Providers/DataProviders/SqlDataProvider/01.02.00.SqlDataProvider: -------------------------------------------------------------------------------- 1 | IF (NOT EXISTS(SELECT * FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_NAME = 'PBI_Subscriptions')) 2 | BEGIN 3 | CREATE TABLE {databaseOwner}[{objectQualifier}PBI_Subscriptions]( 4 | [Id] [int] IDENTITY(1,1) NOT NULL PRIMARY KEY, 5 | [PortalId] [int] NOT NULL, 6 | [ReportId] [varchar](38) NOT NULL, 7 | [GroupId] [varchar](38) NOT NULL, 8 | [ModuleId] [int] NOT NULL, 9 | [Name] [nvarchar](100) NOT NULL, 10 | [StartDate] [datetime] NOT NULL, 11 | [EndDate] [datetime] NOT NULL, 12 | [RepeatPeriod] [nvarchar](100) NOT NULL, 13 | [RepeatTime] [time] NOT NULL, 14 | [TimeZone] [nvarchar](100) NOT NULL, 15 | [EmailSubject] [nvarchar](100) NOT NULL, 16 | [Message] [nvarchar](500) NOT NULL, 17 | [ReportPages] [nvarchar](1000) NOT NULL, 18 | [Enabled] [bit] NOT NULL, 19 | [CreatedOn] [datetime] NOT NULL, 20 | [CreatedBy] [int] NOT NULL, 21 | [LastProcessedOn] [datetime] NULL, 22 | ) 23 | END 24 | IF (NOT EXISTS(SELECT * FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_NAME = 'PBI_SubscriptionSubscribers')) 25 | BEGIN 26 | CREATE TABLE {databaseOwner}[{objectQualifier}PBI_SubscriptionSubscribers]( 27 | [Id] [int] IDENTITY(1,1) NOT NULL PRIMARY KEY, 28 | [SubscriptionId] [int] NOT NULL, 29 | [UserId] [int] NULL, 30 | [RoleId] [int] NULL, 31 | [CreatedOn] [datetime] NOT NULL, 32 | [CreatedBy] [int] NOT NULL, 33 | CONSTRAINT FK_PBI_SubscriptionSubscribers_SubscriptionId FOREIGN KEY (SubscriptionId) 34 | REFERENCES {objectQualifier}PBI_Subscriptions(Id) 35 | ON DELETE CASCADE 36 | ) 37 | END -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/components/general/generalSettings.less: -------------------------------------------------------------------------------- 1 | @import "~@dnnsoftware/dnn-react-common/styles/index"; 2 | .dnn-pbiembedded-generalSettings { 3 | box-sizing: border-box; 4 | padding: 35px 25px; 5 | 6 | * { 7 | box-sizing: border-box; 8 | } 9 | h1 { 10 | margin-bottom: 15px; 11 | text-transform: uppercase; 12 | } 13 | .panel-description { 14 | margin-bottom: 30px; 15 | } 16 | .logo { 17 | float: right; 18 | background-image: url(img/pbiembedded.png); 19 | background-repeat: no-repeat; 20 | background-size: 120px; 21 | width: 120px; 22 | height: 120px; 23 | } 24 | p { 25 | margin-bottom: 20px; 26 | } 27 | .dnn-switch-container { 28 | width: 90%; 29 | } 30 | .directory-section { 31 | margin-top: 10px; 32 | } 33 | .editor-row { 34 | display: inline-block; 35 | width: 90%; 36 | } 37 | .input-full-row { 38 | width: 95%; 39 | } 40 | .dnn-single-line-input-with-error { 41 | width: 100%; 42 | padding-bottom: 15px; 43 | } 44 | .dnn-dropdown-with-error { 45 | width: 100%; 46 | padding-bottom: 15px; 47 | } 48 | .dnn-ui-common-single-line-input.small { 49 | margin-bottom: 0px!important; 50 | } 51 | .buttons-box { 52 | margin-top: 50px; 53 | margin-bottom: 30px; 54 | button.dnn-ui-common-button[role=primary] { 55 | margin-left: 10px; 56 | } 57 | } 58 | .dnn-ui-common-input-group .sectionLabel { 59 | border-top: 1px solid #C8C8C8; 60 | padding-top: 20px; 61 | margin-top: 20px; 62 | } 63 | 64 | 65 | } -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.InteropServices; 3 | 4 | // General Information about an assembly is controlled through the following 5 | // set of attributes. Change these attribute values to modify the information 6 | // associated with an assembly. 7 | [assembly: AssemblyTitle("DotNetNuke.PowerBI")] 8 | [assembly: AssemblyDescription("")] 9 | [assembly: AssemblyConfiguration("")] 10 | [assembly: AssemblyCompany("")] 11 | [assembly: AssemblyProduct("DotNetNuke.PowerBI")] 12 | [assembly: AssemblyCopyright("Copyright © 2025 Intelequia")] 13 | [assembly: AssemblyTrademark("")] 14 | [assembly: AssemblyCulture("")] 15 | 16 | // Setting ComVisible to false makes the types in this assembly not visible 17 | // to COM components. If you need to access a type in this assembly from 18 | // COM, set the ComVisible attribute to true on that type. 19 | [assembly: ComVisible(false)] 20 | 21 | // The following GUID is for the ID of the typelib if this project is exposed to COM 22 | [assembly: Guid("5ef01dd5-84a1-49f3-9232-067440288455")] 23 | 24 | // Version information for an assembly consists of the following four values: 25 | // 26 | // Major Version 27 | // Minor Version 28 | // Build Number 29 | // Revision 30 | // 31 | // You can specify all the values or you can default the Revision and Build Numbers 32 | // by using the '*' as shown below: 33 | [assembly: AssemblyVersion("01.04.00.00")] 34 | #pragma warning disable CS7035 // The specified version string does not conform to the recommended format - major.minor.build.revision 35 | [assembly: AssemblyFileVersion("01.04.00.00")] 36 | #pragma warning restore CS7035 // The specified version string does not conform to the recommended format - major.minor.build.revision 37 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/components/general/workspaces/workspaceEditor/style.less: -------------------------------------------------------------------------------- 1 | @import "~@dnnsoftware/dnn-react-common/styles/index.less"; 2 | .workspace-editor { 3 | float: left; 4 | margin: 20px 30px; 5 | padding-bottom: 40px; 6 | 7 | .topMessage { 8 | border: 1px solid @alto; 9 | padding: 10px 20px; 10 | background-color: @mercury; 11 | margin: 0 0 20px 0; 12 | } 13 | .dnn-ui-common-input-group { 14 | padding: 0 0 15px 0; 15 | label { 16 | font-weight: bolder; 17 | float: left; 18 | } 19 | .dnn-label { 20 | margin: 8px 0; 21 | } 22 | .dnn-dropdown,.dnn-dropdown-with-error 23 | { 24 | width: 100% !important; 25 | box-sizing: border-box; 26 | } 27 | .dnn-single-line-input-with-error { 28 | width: 100% !important; 29 | padding-bottom: 15px; 30 | } 31 | } 32 | .dnn-grid-system { 33 | .left-column { 34 | padding-right: 30px; 35 | border-right: 1px solid @alto; 36 | } 37 | .right-column { 38 | padding-left: 30px; 39 | border-left: 0 !important; 40 | } 41 | } 42 | .editor-buttons-box { 43 | width: 100%; 44 | text-align: center; 45 | float: left; 46 | margin: 30px 0 0 0; 47 | .dnn-ui-common-button { 48 | margin: 5px; 49 | } 50 | .edit-icon { 51 | margin: 0px 10px 20px 10px; 52 | float: right; 53 | svg { 54 | width: 16px; 55 | float: left; 56 | height: 16px; 57 | } 58 | } 59 | } 60 | } -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Services/Models/PBIPermissions.cs: -------------------------------------------------------------------------------- 1 | using Dnn.PersonaBar.Library.Dto; 2 | using Newtonsoft.Json; 3 | 4 | namespace DotNetNuke.PowerBI.Services.Models 5 | { 6 | [JsonObject] 7 | public class PBIPermissions : Permissions 8 | { 9 | public PBIPermissions(bool needDefinitions) : base(needDefinitions) 10 | { 11 | //var adminsRole = RoleController.Instance.GetRoleByName(portalId, "Administrators"); 12 | //var allUsersRole = RoleController.Instance.GetRoleByName(portalId, "All Users"); 13 | //var registeredUsersRole = RoleController.Instance.GetRoleByName(portalId, "Registered Users"); 14 | //this.EnsureRole(adminsRole, true, true); 15 | //this.EnsureRole(allUsersRole, false, true); 16 | //this.EnsureRole(registeredUsersRole, false, true); 17 | } 18 | 19 | [JsonProperty("objectId")] 20 | public int ObjectId { get; set; } 21 | 22 | protected override void LoadPermissionDefinitions() 23 | { 24 | PermissionDefinitions.Add(new Permission() 25 | { 26 | PermissionId = 1, 27 | PermissionName = "View", 28 | FullControl = false, 29 | View = true 30 | }); 31 | PermissionDefinitions.Add(new Permission() 32 | { 33 | PermissionId = 2, 34 | PermissionName = "Edit", 35 | FullControl = false, 36 | View = false 37 | }); 38 | PermissionDefinitions.Add(new Permission() 39 | { 40 | PermissionId = 3, 41 | PermissionName = "Download", 42 | FullControl = false, 43 | View = false 44 | }); 45 | } 46 | } 47 | } -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Services/ModuleSettingsController.cs: -------------------------------------------------------------------------------- 1 | using DotNetNuke.Instrumentation; 2 | using DotNetNuke.PowerBI.Controllers; 3 | using DotNetNuke.PowerBI.Models; 4 | using DotNetNuke.Security; 5 | using DotNetNuke.Web.Api; 6 | using System; 7 | using System.Net; 8 | using System.Net.Http; 9 | using System.Web.Http; 10 | 11 | namespace DotNetNuke.PowerBI.Services 12 | { 13 | [SupportedModules("PBIEmbedded,DotNetNuke.PowerBI.ListView,DotNetNuke.PowerBI.ContentView,DotNetNuke.PowerBI.CalendarView")] 14 | [DnnModuleAuthorize(AccessLevel = SecurityAccessLevel.View)] 15 | public class ModuleSettingsController : DnnApiController 16 | { 17 | private static readonly ILog Logger = LoggerSource.Instance.GetLogger(typeof(ModuleSettingsController)); 18 | 19 | [HttpGet] 20 | [DnnAuthorize] 21 | public HttpResponseMessage GetContentItemsByGroup(string groupId) 22 | { 23 | try 24 | { 25 | EmbedService embedService = new EmbedService(ActiveModule.PortalID, ActiveModule.TabModuleID, groupId); 26 | 27 | PowerBIListView contentItems = embedService.GetContentListAsync(PortalSettings.UserId).Result; 28 | if (contentItems != null) 29 | { 30 | // Remove other culture contents 31 | contentItems = contentItems.RemoveOtherCultureItems(); 32 | } 33 | 34 | return Request.CreateResponse(HttpStatusCode.OK, new 35 | { 36 | contentItems 37 | }); 38 | } 39 | catch (Exception ex) 40 | { 41 | Logger.Error(ex); 42 | return Request.CreateResponse(HttpStatusCode.InternalServerError); 43 | } 44 | } 45 | 46 | } 47 | } -------------------------------------------------------------------------------- /src/powershell/file-watcher.ps1: -------------------------------------------------------------------------------- 1 | <# 2 | Este lo uso para cuando edito ficheros en VS, que se copie en la carpeta que me interese (VS hace que se dispare el evento de los ficheros que estoy guardando) 3 | #> 4 | $searchPath = 'C:\dev\dnn.powerbiembedded\src\DotNetNuke.PowerBI' 5 | $destinationPath = 'C:\Websites\tmh2-admin.dnndev.me\DesktopModules\MVC\PowerBIEmbedded' 6 | $filters = @('*.ascx', '*.css', '*.js', '*.resx', '*.cshtml', '*.html', '*.svg') 7 | 8 | foreach ($filter in $filters) 9 | { 10 | $watcher = New-Object System.IO.FileSystemWatcher 11 | $watcher.Path = $searchPath 12 | $watcher.Filter = $filter 13 | $watcher.IncludeSubdirectories = $true 14 | $watcher.EnableRaisingEvents = $true 15 | 16 | $renamed = Register-ObjectEvent $watcher "renamed" -Action { 17 | $sourceFile = $eventArgs.FullPath 18 | $destinationFile = Join-Path $destinationPath $sourceFile.Substring($searchPath.Length) 19 | Copy-Item $sourceFile $destinationFile -Verbose 20 | } 21 | } 22 | 23 | $searchPath = 'C:\dev\dnn.powerbiembedded\src\DotNetNuke.PowerBI\admin\personaBar' 24 | $destinationPath = 'C:\Websites\tmh2-admin.dnndev.me\DesktopModules\Admin\Dnn.PersonaBar\Modules\Dnn.PowerBI' 25 | $filters = @('*.ascx', '*.css', '*.js', '*.resx', '*.cshtml', '*.html') 26 | 27 | foreach ($filter in $filters) 28 | { 29 | $watcher = New-Object System.IO.FileSystemWatcher 30 | $watcher.Path = $searchPath 31 | $watcher.Filter = $filter 32 | $watcher.IncludeSubdirectories = $true 33 | $watcher.EnableRaisingEvents = $true 34 | 35 | $renamed = Register-ObjectEvent $watcher "renamed" -Action { 36 | $sourceFile = $eventArgs.FullPath 37 | $destinationFile = Join-Path $destinationPath $sourceFile.Substring($searchPath.Length) 38 | Copy-Item $sourceFile $destinationFile -Verbose 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/components/general/generalSettings.jsx: -------------------------------------------------------------------------------- 1 | import React, {Component} from "react"; 2 | import PropTypes from "prop-types"; 3 | import { connect } from "react-redux"; 4 | import { GridSystem, GridCell } from "@dnnsoftware/dnn-react-common"; 5 | import Workspaces from "./workspaces"; 6 | import resx from "../../resources"; 7 | import "./generalSettings.less"; 8 | 9 | class GeneralSettings extends Component { 10 | 11 | constructor() { 12 | super(); 13 | 14 | this.state = { 15 | 16 | }; 17 | } 18 | /*UNSAFE_componentWillMount() { 19 | const {props} = this; 20 | }*/ 21 | 22 | /*UNSAFE_componentWillReceiveProps(nextProps) { 23 | const {state} = this; 24 | } */ 25 | 26 | 27 | render() { 28 | return ( 29 |
30 | 31 |

{resx.get("lblTabDescription")}

32 |
33 | 34 |
35 |
36 | 37 | 38 |

{resx.get("lblWorkspaceSettings")}

39 | 40 |
41 | 42 | 43 | 44 |
45 |
46 | ); 47 | } 48 | } 49 | 50 | GeneralSettings.propTypes = { 51 | dispatch: PropTypes.func.isRequired, 52 | 53 | }; 54 | 55 | 56 | function mapStateToProps( 57 | 58 | ) { 59 | return { 60 | 61 | }; 62 | } 63 | 64 | export default connect(mapStateToProps)(GeneralSettings); -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Models/PowerBICalendarView.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.PowerBI.Api.Models; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Runtime.Serialization; 5 | 6 | namespace DotNetNuke.PowerBI.Models 7 | { 8 | [Serializable] 9 | [DataContract] 10 | public class PowerBICalendarView 11 | { 12 | 13 | 14 | public PowerBICalendarView() 15 | { 16 | RefreshSchedules = new List(); 17 | History = new List(); 18 | Workspaces = new List(); 19 | } 20 | [DataMember] 21 | public List Workspaces { get; set; } 22 | [DataMember] 23 | public string ErrorMessage { get; set; } 24 | [DataMember] 25 | public List RefreshSchedules { get; set; } 26 | [DataMember] 27 | public List History { get; set; } 28 | 29 | public int CurrentPage { get; set; } = 1; 30 | public int Count { get; set; } 31 | public int PageSize { get; set; } = 10; 32 | 33 | public int TotalPages => (int)Math.Ceiling(decimal.Divide(Count, PageSize)); 34 | 35 | 36 | } 37 | 38 | public class CalendarItem 39 | { 40 | public string id { get; set; } 41 | public string resourceId { get; set; } 42 | public string start { get; set; } 43 | public string end { get; set; } 44 | public string title { get; set; } 45 | public string color { get; set; } 46 | public string description { get; set; } 47 | } 48 | 49 | public class Schedule 50 | { 51 | public string start { get; set; } 52 | public string end { get; set; } 53 | } 54 | 55 | public class RefreshedDataset : Refresh 56 | { 57 | public string Dataset { get; set; } 58 | public string WorkSpaceName { get; set; } 59 | public string CapacityName { get; set; } 60 | } 61 | } -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/components/permissions/permissions.less: -------------------------------------------------------------------------------- 1 | @import "~@dnnsoftware/dnn-react-common/styles/index"; 2 | .dnn-pbiembedded-permissions { 3 | box-sizing: border-box; 4 | padding: 35px 25px; 5 | * { 6 | box-sizing: border-box; 7 | } 8 | h1 { 9 | margin-top: 10px; 10 | margin-bottom: 10px; 11 | text-transform: uppercase; 12 | } 13 | p { 14 | margin-bottom: 20px; 15 | } 16 | .dnn-label label { 17 | font-weight: bold; 18 | } 19 | .dnn-switch-container { 20 | width: 90%; 21 | } 22 | .editor-row { 23 | display: inline-block; 24 | width: 90%; 25 | } 26 | .dnn-single-line-input-with-error { 27 | width: 100%; 28 | padding-bottom: 15px; 29 | } 30 | .dnn-dropdown-with-error { 31 | width: 100%; 32 | padding-bottom: 15px; 33 | } 34 | .dnn-ui-common-single-line-input.small { 35 | margin-bottom: 0px!important; 36 | } 37 | .buttons-box { 38 | margin-top: 50px; 39 | margin-bottom: 30px; 40 | button.dnn-ui-common-button[role=primary] { 41 | margin-left: 10px; 42 | } 43 | } 44 | .warning-container { 45 | width: 100%; 46 | float: left; 47 | margin: 10px 0 15px 0; 48 | font-weight: bolder; 49 | color: @alizarinCrimson; 50 | .collapsible-content { 51 | margin-top: 5px; 52 | > div { 53 | border: solid 1px; 54 | } 55 | } 56 | .warning-icon { 57 | > svg { 58 | width: 17px; 59 | float: left; 60 | height: 17px; 61 | margin: 0 10px 0 0; 62 | } 63 | } 64 | .warning-msg { 65 | margin-left: 30px; 66 | } 67 | } 68 | h1.spacer { 69 | margin-top: 25px; 70 | } 71 | } -------------------------------------------------------------------------------- /docs/README.md: -------------------------------------------------------------------------------- 1 | # DNN Power BI Embedded Documentation 2 | 3 | This directory contains comprehensive documentation for the DNN Power BI Embedded module. 4 | 5 | ## Available Documentation 6 | 7 | ### [RLS Configuration Guide](RLS-Configuration.md) 8 | Complete guide to configuring Role Level Security (RLS) in the Power BI Embedded module. This document covers: 9 | - Overview of RLS functionality 10 | - All 5 RLS configuration options (Username, Email, PowerBiGroup, Custom Profile Properties, Custom Extension Library) 11 | - Configuration steps for each option 12 | - Best practices and troubleshooting 13 | 14 | ### [RLS Custom Extension Examples](RLS-Examples.md) 15 | Practical examples and code samples for implementing custom RLS extensions. This document includes: 16 | - Complete example implementations for common scenarios 17 | - Department-based, multi-tenant, and role-based extensions 18 | - Database-driven RLS implementations 19 | - Deployment and testing guidance 20 | - Best practices for performance and security 21 | 22 | ## Quick Start 23 | 24 | 1. **Basic Setup**: Start with the [RLS Configuration Guide](RLS-Configuration.md) to understand the available options 25 | 2. **Simple Implementation**: Use Username or Email options for basic scenarios 26 | 3. **Advanced Implementation**: Use Custom Profile Properties or Custom Extension Library for complex business logic 27 | 4. **Development**: Refer to [RLS Examples](RLS-Examples.md) for code samples and patterns 28 | 29 | ## Getting Help 30 | 31 | - Check the [main project README](../README.md) for general information 32 | - Visit the [project Wiki](https://github.com/intelequia/dnn.powerbiembedded/wiki) for additional documentation 33 | - Review the [release notes](../src/DotNetNuke.PowerBI/ReleaseNotes.txt) for version-specific information 34 | 35 | ## Contributing 36 | 37 | To contribute to this documentation: 38 | 1. Follow the existing documentation style and structure 39 | 2. Include practical examples where appropriate 40 | 3. Update this index when adding new documentation files 41 | 4. Ensure all links are working and up-to-date -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Views/emailtemplate.cshtml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | DNN Website monitoring 7 | 53 | 54 | 55 |
56 |

[[SubscriptionName]]

57 |

[[EmailBody]]

58 |

You're receiving this email because you subscribed to the '[[SubscriptionName]]' page of the '[[ReportName]]' report. The file attached was generated at [[ReportDate]]

59 |
60 | 61 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/src/components/App.jsx: -------------------------------------------------------------------------------- 1 | import React, {Component} from "react"; 2 | import PropTypes from "prop-types"; 3 | import { connect } from "react-redux"; 4 | import {PersonaBarPage, PersonaBarPageHeader, PersonaBarPageBody, DnnTabs as Tabs} from "@dnnsoftware/dnn-react-common"; 5 | import SettingsActions from "../actions/settings"; 6 | import GeneralSettings from "./general"; 7 | import Permissions from "./permissions"; 8 | import resx from "../resources"; 9 | 10 | import "./style.less"; 11 | 12 | class App extends Component { 13 | 14 | constructor() { 15 | super(); 16 | this.onSelectTab = this.onSelectTab.bind(this); 17 | this.onSelectSubTab = this.onSelectSubTab.bind(this); 18 | } 19 | onSelectTab(index) { 20 | this.props.dispatch(SettingsActions.switchTab(index)); 21 | } 22 | onSelectSubTab(index) { 23 | this.props.dispatch(SettingsActions.switchMappingSubTab(index)); 24 | } 25 | 26 | render() { 27 | return ( 28 |
29 | 30 | 31 | 32 | 33 | 37 | 38 | 39 | 40 | 41 | 42 |
43 | ); 44 | } 45 | } 46 | 47 | App.propTypes = { 48 | dispatch: PropTypes.func.isRequired, 49 | selectedTab: PropTypes.number 50 | }; 51 | 52 | 53 | function mapStateToProps(state) { 54 | return { 55 | selectedTab: state.settings.selectedTab 56 | }; 57 | } 58 | 59 | export default connect(mapStateToProps)(App); -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/node_modules/@dnnsoftware/dnn-react-common/dist.webpack.config.js: -------------------------------------------------------------------------------- 1 | const webpack = require("webpack"); 2 | const path = require("path"); 3 | const packageJson = require("./package.json"); 4 | const nodeExternals = require("webpack-node-externals"); 5 | 6 | module.exports = { 7 | mode: "production", 8 | optimization: { 9 | minimize: true, 10 | }, 11 | entry: "./src/index.js", 12 | output: { 13 | path: path.resolve(__dirname, "dist"), 14 | filename: "dnn-react-common.min.js", 15 | library: "DnnReactCommon", 16 | libraryTarget: "umd", 17 | }, 18 | module: { 19 | rules: [ 20 | { test: /\.(js|jsx)$/, enforce: "pre", exclude: /node_modules/, loader: "eslint-loader", options: { fix: true } }, 21 | { test: /\.(js|jsx)$/, exclude: /node_modules/, loaders: ["babel-loader"] }, 22 | { test: /\.less$/, loader: "style-loader!css-loader!less-loader" }, 23 | { test: /\.(ttf|woff)$/, loader: "url-loader?limit=8192" }, 24 | { test: /\.css$/, loader: "style-loader!css-loader" }, 25 | { test: /\.(gif|png)$/, loader: "url-loader?mimetype=image/png" }, 26 | { test: /\.(svg)$/, loader: "raw-loader" }, 27 | { test: /\.woff(2)?(\?v=[0-9].[0-9].[0-9])?$/, loader: "url-loader?mimetype=application/font-woff" }, 28 | { test: /\.(ttf|eot)(\?v=[0-9].[0-9].[0-9])?$/, loader: "file-loader?name=[name].[ext]" } 29 | ] 30 | }, 31 | externals: ["react", "prop-types", nodeExternals()], // in order to ignore all modules in node_modules folder 32 | resolve: { 33 | extensions: [".js", ".json", ".jsx"], 34 | modules: [ 35 | path.resolve(__dirname, "./src"), // Look in src first 36 | path.resolve("./node_modules"), // Try local node_modules 37 | path.resolve("../../../node_modules") // Last fallback to workspaces node_modules 38 | ] 39 | }, 40 | plugins: [ 41 | new webpack.DefinePlugin({ 42 | VERSION: JSON.stringify(packageJson.version), 43 | "process.env": { 44 | "NODE_ENV": JSON.stringify("production") 45 | } 46 | }) 47 | ] 48 | }; -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/Providers/DataProviders/SqlDataProvider/01.00.02.SqlDataProvider: -------------------------------------------------------------------------------- 1 | IF (NOT EXISTS(SELECT * FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_NAME = 'PBI_ObjectPermission')) 2 | BEGIN 3 | CREATE TABLE {databaseOwner}[{objectQualifier}PBI_ObjectPermission]( 4 | [ID] [uniqueidentifier] NOT NULL, 5 | [PowerBiObjectID] [varchar](50) NOT NULL, 6 | [PermissionID] [int] NOT NULL, 7 | [AllowAccess] [bit] NOT NULL, 8 | [PortalID] [int] NOT NULL, 9 | [RoleID] [int] NULL, 10 | [UserID] [int] NULL, 11 | [CreatedByUserID] [int] NULL, 12 | [CreatedOnDate] [datetime] NULL, 13 | [LastModifiedByUserID] [int] NULL, 14 | [LastModifiedOnDate] [datetime] NULL, 15 | CONSTRAINT [PK_PBI_ObjectPermission] PRIMARY KEY CLUSTERED 16 | ( 17 | [ID] ASC 18 | ) 19 | ) 20 | 21 | ALTER TABLE {databaseOwner}[{objectQualifier}PBI_ObjectPermission] ADD CONSTRAINT [DF_PBI_ObjectPermission_AllowAccess] DEFAULT ((0)) FOR [AllowAccess] 22 | 23 | ALTER TABLE {databaseOwner}[{objectQualifier}PBI_ObjectPermission] WITH CHECK ADD CONSTRAINT [FK_PBI_ObjectPermission_Permission] FOREIGN KEY([PermissionID]) 24 | REFERENCES {databaseOwner}[Permission] ([PermissionID]) 25 | 26 | ALTER TABLE {databaseOwner}[{objectQualifier}PBI_ObjectPermission] CHECK CONSTRAINT [FK_PBI_ObjectPermission_Permission] 27 | 28 | ALTER TABLE {databaseOwner}[{objectQualifier}PBI_ObjectPermission] WITH CHECK ADD CONSTRAINT [FK_PBI_ObjectPermission_Portals] FOREIGN KEY([PortalID]) 29 | REFERENCES {databaseOwner}[Portals] ([PortalID]) 30 | 31 | ALTER TABLE {databaseOwner}[{objectQualifier}PBI_ObjectPermission] CHECK CONSTRAINT [FK_PBI_ObjectPermission_Portals] 32 | 33 | ALTER TABLE {databaseOwner}[{objectQualifier}PBI_ObjectPermission] WITH CHECK ADD CONSTRAINT [FK_PBI_ObjectPermission_Roles] FOREIGN KEY([RoleID]) 34 | REFERENCES {databaseOwner}[Roles] ([RoleID]) 35 | 36 | ALTER TABLE {databaseOwner}[{objectQualifier}PBI_ObjectPermission] CHECK CONSTRAINT [FK_PBI_ObjectPermission_Roles] 37 | 38 | ALTER TABLE {databaseOwner}[{objectQualifier}PBI_ObjectPermission] WITH CHECK ADD CONSTRAINT [FK_PBI_ObjectPermission_Users] FOREIGN KEY([UserID]) 39 | REFERENCES {databaseOwner}[Users] ([UserID]) 40 | 41 | ALTER TABLE {databaseOwner}[{objectQualifier}PBI_ObjectPermission] CHECK CONSTRAINT [FK_PBI_ObjectPermission_Users] 42 | END 43 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/scripts/Common.js: -------------------------------------------------------------------------------- 1 | var Common = (function () { 2 | 3 | var call = function (httpMethod, action, service, params, success, fail, always) { 4 | var jqxhr = $.ajax({ 5 | url: service.baseUrl + service.controller + "/" + action, 6 | beforeSend: service.framework.setModuleHeaders, 7 | type: httpMethod, 8 | async: true, 9 | data: httpMethod === "GET" ? params : JSON.stringify(params), 10 | dataType: httpMethod === "GET" ? "" : "json", 11 | contentType: httpMethod === "GET" ? "" : "application/json; charset=UTF-8" 12 | }).done(function (data) { 13 | if (typeof (success) === "function") { 14 | success(data); 15 | } 16 | }).fail(function (error, exception) { 17 | if (typeof (fail) === "function") { 18 | fail(error, exception); 19 | } 20 | }).always(function () { 21 | if (typeof (always) === "function") { 22 | always(); 23 | } 24 | }); 25 | }; 26 | 27 | var callOptions = function (httpMethod, action, service, params, options, success, fail, always) { 28 | var jqxhr = $.ajax({ 29 | url: service.baseUrl + service.controller + "/" + action, 30 | beforeSend: service.framework.setModuleHeaders, 31 | type: httpMethod, 32 | async: true, 33 | data: httpMethod === "GET" ? params : JSON.stringify(params), 34 | dataType: httpMethod === "GET" ? "" : "json", 35 | contentType: httpMethod === "GET" ? "" : "application/json; charset=UTF-8", 36 | headers: options.headers 37 | }).done(function (data) { 38 | if (typeof (success) === "function") { 39 | success(data); 40 | } 41 | }).fail(function (error, exception) { 42 | if (typeof (fail) === "function") { 43 | fail(error, exception); 44 | } 45 | }).always(function () { 46 | if (typeof (always) === "function") { 47 | always(); 48 | } 49 | }); 50 | } 51 | 52 | return { 53 | Call: call, 54 | CallWithOptions: callOptions 55 | } 56 | })(); 57 | 58 | 59 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/PBIEmbedded.Web/node_modules/@dnnsoftware/dnn-react-common/WebpackExternals/index.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | "react": "window.dnn.nodeModules.React", 3 | /** @deprecated for v.10 - will no longer be delivered. */ 4 | "react/lib/ReactMount": "window.dnn.nodeModules.ReactMount", 5 | /** @deprecated for v.10 - will no longer be delivered. */ 6 | "react/lib/ReactComponentWithPureRenderMixin": "window.dnn.nodeModules.ReactComponentWithPureRenderMixin", 7 | "redux": "window.dnn.nodeModules.Redux", 8 | "react-redux": "window.dnn.nodeModules.ReactRedux", 9 | "react-dom": "window.dnn.nodeModules.ReactDOM", 10 | /** @deprecated for v.10 - will no longer be lelivered. */ 11 | "react-tabs": "window.dnn.nodeModules.ReactTabs", 12 | /** @deprecated for v.10 - will no longer be lelivered. */ 13 | "redux-devtools": "window.dnn.nodeModules.ReduxDevTools", 14 | /** @deprecated for v.10 - will no longer be lelivered. */ 15 | "redux-devtools-dock-monitor": "window.dnn.nodeModules.ReduxDevToolsDockMonitor", 16 | /** @deprecated for v.10 - will no longer be lelivered. */ 17 | "redux-devtools-log-monitor": "window.dnn.nodeModules.ReduxDevToolsLogMonitor", 18 | "redux-immutable-state-invariant": "window.dnn.nodeModules.ReduxImmutableStateInvariant", 19 | "redux-thunk": "window.dnn.nodeModules.ReduxThunk", 20 | "react-collapse": "window.dnn.nodeModules.ReactCollapse", 21 | /** @deprecated for v.10 - will no longer be lelivered. */ 22 | "react-modal": "window.dnn.nodeModules.ReactModal", 23 | "react-custom-scrollbars": "window.dnn.nodeModules.ReactCustomScrollBars", 24 | /** @deprecated for v.10 - will no longer be lelivered. */ 25 | "react-tooltip": "window.dnn.nodeModules.ReactTooltip", 26 | "react-widgets": "window.dnn.nodeModules.ReactWidgets", 27 | /** @deprecated for v.10 - will no longer be lelivered. */ 28 | "throttle-debounce": "window.dnn.nodeModules.ThrottleDebounce", 29 | /** @deprecated for v.10 - moment JS will no longer be delivered - recommended to manage own packages moving forward */ 30 | "moment": "window.dnn.nodeModules.Moment", 31 | /** @deprecated for v.11 - will no longer be lelivered. */ 32 | "es6-promise": "window.dnn.nodeModules.Es6Promise", 33 | "@dnnsoftware/dnn-react-common": "window.dnn.nodeModules.CommonComponents" 34 | }; 35 | -------------------------------------------------------------------------------- /src/DotNetNuke.PowerBI/scripts/module-settings.js: -------------------------------------------------------------------------------- 1 | var app = app || {}; 2 | 3 | app.settings = function (context) { 4 | var that = this; 5 | this.service = { 6 | path: 'Bookmarks', 7 | controller: 'ModuleSettings', 8 | framework: $.ServicesFramework(context.ModuleId) 9 | }; 10 | this.service.baseUrl = that.service.framework.getServiceRoot(that.service.path); 11 | this.$workspaces; 12 | 13 | this.refreshContentItems = function (groupId) { 14 | let params = { 15 | groupId: groupId, 16 | }; 17 | 18 | $.ajax({ 19 | url: that.service.baseUrl + that.service.controller + '/GetContentItemsByGroup', 20 | type: 'GET', 21 | async: true, 22 | data: params, 23 | dataType: '', 24 | contentType: '', 25 | headers: { 26 | 'PortalId': context.PortalId, 27 | 'ModuleId': context.ModuleId, 28 | 'TabId': context.TabId, 29 | 'RequestVerificationToken': $.ServicesFramework().getAntiForgeryValue(), 30 | } 31 | }).done(function (data) { 32 | if(data.contentItems != null) { 33 | var $contentItems = $('#ContentItemId'); 34 | $contentItems.empty(); 35 | $contentItems.append($('