Not able to show graph in md-dialog
-
I Want to show graph in md-dialog but not able to access data-points in dialog
My code is following... >>-->>
mydialog.html —>
<md-dialog class="fullscreen-dialogss" aria-label="Full Screen Dialog Test"> <div> <md-card> <md-card-content> <div><ma-point-values point-xid=“point_xid1” point="point1” values="point1" from="from" to="to" rollup="AVERAGE" auto-rollup-interval="true"></ma-point-values></div> <ma-serial-chart options="{theme:'black'}" style="height: 200px; width: 100%" series-1-values="point1" series-1-title="title1" series-1-type="line" series-1-color="#ff0000" legend="true" balloon="true"></ma-serial-chart> </md-card-content> </md-card> </div> </md-dialog>
And app.js —>
$mdDialog.show({ scope:$rootScope, preserveScope:false, templateUrl: 'views/mydialog.html’, targetEvent: ev, clickOutsideToClose:false, })
-
@ganeshvarahade This question doesn't really have anything to do with Mango and is more of a question about AngularJS Material, please be sure to read their documentation - https://material.angularjs.org/latest/
By passing
preserveScope:false
I believe you will destroy the root scope which is not desirable. Try usinglocals
instead. -
ok..Can we access datapoint values under app.js?
Because I am getting specific values of specific data points under pop-up but I am not able to get Chart or Graph related values under pop-up so what procedure I need to follow? -
@ganeshvarahade said in Not able to show graph in md-dialog:
ok..Can we access datapoint values under app.js?
Yes there are angular services which are documented. Go into the menu editor and enable the "API Docs" menu.
@ganeshvarahade said in Not able to show graph in md-dialog:
Because I am getting specific values of specific data points under pop-up but I am not able to get Chart or Graph related values under pop-up so what procedure I need to follow?
I really cannot even begin to suggest anything because you have provided me no information about your project. You will have to tell me if you are using the dashboard designer/custom pages or a whole custom app and post your HTML markup and app.js if relevant.
Did you address the issue with
preserveScope:false
?