mirror of
https://github.com/itsdave-de/fusionpbx_connect.git
synced 2025-05-10 17:45:15 +02:00
set right modal size
This commit is contained in:
parent
b6dfc2fa25
commit
8705b6c65e
@ -8,7 +8,7 @@ function loadLeafletAndInitMap(frm, callback) {
|
|||||||
function create_dialog_and_init_map(frm) {
|
function create_dialog_and_init_map(frm) {
|
||||||
const dialog = new frappe.ui.Dialog({
|
const dialog = new frappe.ui.Dialog({
|
||||||
title: 'Show Route',
|
title: 'Show Route',
|
||||||
fields: [{ fieldtype: 'HTML', fieldname: 'map_html', label: 'Map', options: '<div id="map" style="height:calc(80vh - 20px);"></div>' }],
|
fields: [{ fieldtype: 'HTML', fieldname: 'map_html', label: 'Map', options: '<div id="map" style="height:calc(80vh - 50px);"></div>' }],
|
||||||
primary_action_label: 'Close',
|
primary_action_label: 'Close',
|
||||||
primary_action() {
|
primary_action() {
|
||||||
if (currentMap) {
|
if (currentMap) {
|
||||||
@ -20,15 +20,9 @@ function create_dialog_and_init_map(frm) {
|
|||||||
size: 'extra-large'
|
size: 'extra-large'
|
||||||
});
|
});
|
||||||
|
|
||||||
/*
|
|
||||||
// Adjust the size of the dialog dynamically to 80% of the browser window
|
// Adjust the size of the dialog dynamically to 80% of the browser window
|
||||||
const modalDialog = dialog.$wrapper.find('.modal-content');
|
dialog.$wrapper.find('.modal-dialog').css("max-width", "90%");
|
||||||
modalDialog.css({
|
dialog.$wrapper.find('.modal-dialog').css("width", "90%");
|
||||||
"width": "85vw",
|
|
||||||
"max-width": "85vw",
|
|
||||||
"margin-left": "-25vh"
|
|
||||||
});
|
|
||||||
*/
|
|
||||||
|
|
||||||
// Add hide event to reload the page when the dialog is closed
|
// Add hide event to reload the page when the dialog is closed
|
||||||
dialog.onhide = function () {
|
dialog.onhide = function () {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user