Base solution for your next web application
Ends in:
01 DAYS
01 HRS
01 MIN
01 SEC
Open Closed

How do i pass data to a modal so what it can use that data #3511


User avatar
0
NPECAdmin created

The below code in my index.js opens the modal Balloon1Modal when the button with id="Balloon1ModalButton" is clicked. I need to pass some data from my index.js to my modal so that it can use that data to populate the table inside my modal. What additions can i make to the below code so that i can pass a variable as a parameter?

(function () {
            var _balloon1Modal = new app.ModalManager({
                viewUrl: abp.appPath + 'Mpa/DealerDashboard/Balloon1Modal',
                scriptUrl: abp.appPath + 'Areas/Mpa/Views/DealerDashboard/_Balloon1Modal.js',
                modalClass: 'Balloon1Modal'
            });

            $('#Balloon1ModalButton').click(function (e) {
                e.preventDefault();
                _balloon1Modal.open();
            });
        })();

Thank you


1 Answer(s)