How to display sp-variable-editor using spModal

Ro5
Tera Expert

Hello.
I'm trying to create a gimmick that uses spModal to display sp-variable-editor when a button is clicked.
However, since I don't know how to pass data such as tables and sys_id, the sp-variable-editor widget does not display properly.

Where and how should I write it in the script to pass the data to sp-variable-editor?

 

HTML:
<div class="panel-body">
<button type="submit" ng-click="c.onWidget('sp-variable-editor')" class="btn btn-primary post-btn ng-scope">reopen</button>
</div>

 

Client controller:
api.controller=function(spModal) {
/* widget controller */
var c = this;
c.onWidget = function(widgetId, widgetInput) {
spModal.open({
title: 'Displaying widget' + widgetId,
widget: widgetId,
widgetInput: widgetInput || {}
}).then(function(){
console.log('widget dismissed');
})
}
};

 

Regards,
Ro

0 REPLIES 0