Merge pull request #18494 from MauricioFauth/pma-fieldset-removal
Remove .pma-fieldset and related CSS classes
This commit is contained in:
commit
73356a20af
@ -168,11 +168,11 @@ AJAX.registerOnload('database/multi_table_query.js', function () {
|
||||
|
||||
$('#add_column_button').on('click', function () {
|
||||
columnCount++;
|
||||
var $newColumnDom = $($('#new_column_layout').html()).clone();
|
||||
var $newColumnDom = $('<div class="col"></div>').html($('#new_column_layout').html());
|
||||
$newColumnDom.find('.jsCriteriaButton').first().attr('data-bs-target', '#criteriaOptionsExtra' + columnCount.toString());
|
||||
$newColumnDom.find('.jsCriteriaButton').first().attr('aria-controls', 'criteriaOptionsExtra' + columnCount.toString());
|
||||
$newColumnDom.find('.jsCriteriaOptions').first().attr('id', 'criteriaOptionsExtra' + columnCount.toString());
|
||||
$('#add_column_button').parent().before($newColumnDom);
|
||||
$('#add_column_button').parent().siblings('.row').append($newColumnDom);
|
||||
addNewColumnCallbacks();
|
||||
});
|
||||
|
||||
@ -190,7 +190,7 @@ AJAX.registerOnload('database/multi_table_query.js', function () {
|
||||
|
||||
$('.jsRemoveColumn').each(function () {
|
||||
$(this).on('click', function () {
|
||||
$(this).parent().remove();
|
||||
$(this).parent().parent().parent().remove();
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
@ -2453,24 +2453,24 @@ function onloadEnumSetEditor (): void {
|
||||
/**
|
||||
* @var dialog HTML code for the ENUM/SET dialog
|
||||
*/
|
||||
var dialog = '<div id=\'enum_editor\'>' +
|
||||
'<fieldset class="pma-fieldset">' +
|
||||
'<legend>' + title + '</legend>' +
|
||||
var dialog = '<div id="enum_editor" class="card">' +
|
||||
'<div class="card-header">' + title + '</div>' +
|
||||
'<div class="card-body">' +
|
||||
'<p>' + getImageTag('s_notice') +
|
||||
window.Messages.enum_hint + '</p>' +
|
||||
'<table class="table table-borderless values">' + fields + '</table>' +
|
||||
'</fieldset><fieldset class="pma-fieldset tblFooters">' +
|
||||
'</div><div class="card-footer">' +
|
||||
'<table class="table table-borderless add"><tr><td>' +
|
||||
'<div class=\'slider\'></div>' +
|
||||
'<div class="slider"></div>' +
|
||||
'</td><td>' +
|
||||
'<form><div><input type=\'submit\' class=\'add_value btn btn-primary\' value=\'' +
|
||||
'<form><div><input type="submit" class="add_value btn btn-primary" value="' +
|
||||
window.sprintf(window.Messages.enum_addValue, 1) +
|
||||
'\'></div></form>' +
|
||||
'"></div></form>' +
|
||||
'</td></tr></table>' +
|
||||
'<input type=\'hidden\' value=\'' + // So we know which column's data is being edited
|
||||
'<input type="hidden" value="' + // So we know which column's data is being edited
|
||||
$(this).closest('td').find('input').attr('id') +
|
||||
'\'>' +
|
||||
'</fieldset>' +
|
||||
'">' +
|
||||
'</div>' +
|
||||
'</div>';
|
||||
$('#enumEditorGoButton').on('click', function () {
|
||||
// When the submit button is clicked,
|
||||
@ -2585,17 +2585,18 @@ function onloadEnumSetEditor (): void {
|
||||
|
||||
var seeMore = '';
|
||||
if (listSize > maxRows) {
|
||||
seeMore = '<fieldset class="pma-fieldset tblFooters text-center fw-bold">' +
|
||||
'<a href=\'#\' id=\'seeMore\'>' + window.Messages.seeMore + '</a></fieldset>';
|
||||
seeMore = '<div class="card-footer">' +
|
||||
'<button type="button" class="btn btn-secondary" id="seeMore">' +
|
||||
window.Messages.seeMore + '</button></div>';
|
||||
}
|
||||
|
||||
var centralColumnsDialog = '<div class=\'max_height_400\'>' +
|
||||
'<fieldset class="pma-fieldset">' +
|
||||
var centralColumnsDialog = '<div><div class="card">' +
|
||||
'<div class="card-body">' +
|
||||
searchIn +
|
||||
'<table id="col_list" class="table table-borderless values">' + fields + '</table>' +
|
||||
'</fieldset>' +
|
||||
'</div>' +
|
||||
seeMore +
|
||||
'</div>';
|
||||
'</div></div>';
|
||||
|
||||
var width = parseInt(
|
||||
((parseInt($('html').css('font-size'), 10) / 13) * 500).toString(),
|
||||
@ -2851,7 +2852,7 @@ function indexDialogModal (routeUrl, url, title, callbackSuccess, callbackFailur
|
||||
modal.find('.modal-body').first().html(data.message);
|
||||
$('#indexDialogModalLabel').first().text(title);
|
||||
Functions.verifyColumnsProperties();
|
||||
modal.find('.tblFooters').remove();
|
||||
modal.find('.card-footer').remove();
|
||||
Functions.showIndexEditDialog(modal);
|
||||
}); // end $.get()
|
||||
}
|
||||
|
||||
@ -428,16 +428,17 @@ var removeIndexOnChangeEvent = function () {
|
||||
* @param {string} colIndex Index of new column on form
|
||||
*/
|
||||
function indexTypeSelectionDialog (sourceArray, indexChoice, colIndex): void {
|
||||
var $singleColumnRadio = $('<input type="radio" id="single_column" name="index_choice"' +
|
||||
' checked="checked">' +
|
||||
'<label for="single_column">' + window.Messages.strCreateSingleColumnIndex + '</label>');
|
||||
var $compositeIndexRadio = $('<input type="radio" id="composite_index"' +
|
||||
' name="index_choice">' +
|
||||
'<label for="composite_index">' + window.Messages.strCreateCompositeIndex + '</label>');
|
||||
var $dialogContent = $('<fieldset class="pma-fieldset" id="advance_index_creator"></fieldset>');
|
||||
var $singleColumnRadio = $('<div class="form-check">' +
|
||||
'<input class="form-check-input" type="radio" id="single_column" name="index_choice" checked="checked">' +
|
||||
'<label class="form-check-label" for="single_column">' +
|
||||
window.Messages.strCreateSingleColumnIndex + '</label></div>');
|
||||
var $compositeIndexRadio = $('<div class="form-check">' +
|
||||
'<input class="form-check-input" type="radio" id="composite_index" name="index_choice">' +
|
||||
'<label class="form-check-label" for="composite_index">' +
|
||||
window.Messages.strCreateCompositeIndex + '</label></div>');
|
||||
var $dialogContent = $('<fieldset id="advance_index_creator"></fieldset>');
|
||||
$dialogContent.append('<legend>' + indexChoice.toUpperCase() + '</legend>');
|
||||
|
||||
|
||||
// For UNIQUE/INDEX type, show choice for single-column and composite index.
|
||||
$dialogContent.append($singleColumnRadio);
|
||||
$dialogContent.append($compositeIndexRadio);
|
||||
|
||||
@ -53,7 +53,7 @@ function goTo3NFStep1 (newTables) {
|
||||
'tables': tables,
|
||||
}, function (data) {
|
||||
$('#page_content').find('h3').html(window.Messages.str3NFNormalization);
|
||||
$('#mainContent').find('legend').html(data.legendText);
|
||||
$('#mainContent').find('.card-header').html(data.legendText);
|
||||
$('#mainContent').find('h4').html(data.headText);
|
||||
$('#mainContent').find('p').html(data.subText);
|
||||
$('#mainContent').find('#extra').html(data.extra);
|
||||
@ -65,7 +65,7 @@ function goTo3NFStep1 (newTables) {
|
||||
});
|
||||
|
||||
$('#mainContent').find('#newCols').html('');
|
||||
$('.tblFooters').html('');
|
||||
$('#mainContent .card-footer').html('');
|
||||
|
||||
if (data.subText !== '') {
|
||||
$('<input>')
|
||||
@ -77,7 +77,7 @@ function goTo3NFStep1 (newTables) {
|
||||
.on('click', function () {
|
||||
processDependencies('', true);
|
||||
})
|
||||
.appendTo('.tblFooters');
|
||||
.appendTo('#mainContent .card-footer');
|
||||
}
|
||||
}
|
||||
);
|
||||
@ -93,7 +93,7 @@ function goTo2NFStep1 () {
|
||||
'server': CommonParams.get('server'),
|
||||
}, function (data) {
|
||||
$('#page_content h3').html(window.Messages.str2NFNormalization);
|
||||
$('#mainContent legend').html(data.legendText);
|
||||
$('#mainContent .card-header').html(data.legendText);
|
||||
$('#mainContent h4').html(data.headText);
|
||||
$('#mainContent p').html(data.subText);
|
||||
$('#mainContent #extra').html(data.extra);
|
||||
@ -108,7 +108,7 @@ function goTo2NFStep1 () {
|
||||
.on('click', function () {
|
||||
processDependencies(data.primary_key);
|
||||
})
|
||||
.appendTo('.tblFooters');
|
||||
.appendTo('#mainContent .card-footer');
|
||||
} else {
|
||||
if (normalizeto === '3nf') {
|
||||
$('#mainContent #newCols').html(window.Messages.strToNextStep);
|
||||
@ -127,7 +127,7 @@ function goToFinish1NF () {
|
||||
return true;
|
||||
}
|
||||
|
||||
$('#mainContent legend').html(window.Messages.strEndStep);
|
||||
$('#mainContent .card-header').html(window.Messages.strEndStep);
|
||||
$('#mainContent h4').html(
|
||||
'<h3>' + window.sprintf(window.Messages.strFinishMsg, escapeHtml(CommonParams.get('table'))) + '</h3>'
|
||||
);
|
||||
@ -135,7 +135,7 @@ function goToFinish1NF () {
|
||||
$('#mainContent p').html('');
|
||||
$('#mainContent #extra').html('');
|
||||
$('#mainContent #newCols').html('');
|
||||
$('.tblFooters').html('');
|
||||
$('#mainContent .card-footer').html('');
|
||||
}
|
||||
|
||||
function goToStep4 () {
|
||||
@ -147,12 +147,12 @@ function goToStep4 () {
|
||||
'table': CommonParams.get('table'),
|
||||
'server': CommonParams.get('server'),
|
||||
}, function (data) {
|
||||
$('#mainContent legend').html(data.legendText);
|
||||
$('#mainContent .card-header').html(data.legendText);
|
||||
$('#mainContent h4').html(data.headText);
|
||||
$('#mainContent p').html(data.subText);
|
||||
$('#mainContent #extra').html(data.extra);
|
||||
$('#mainContent #newCols').html('');
|
||||
$('.tblFooters').html('');
|
||||
$('#mainContent .card-footer').html('');
|
||||
for (var pk in primaryKey) {
|
||||
$('#extra input[value=\'' + escapeJsString(primaryKey[pk]) + '\']').attr('disabled', 'disabled');
|
||||
}
|
||||
@ -179,12 +179,12 @@ function goToStep3 () {
|
||||
'table': CommonParams.get('table'),
|
||||
'server': CommonParams.get('server'),
|
||||
}, function (data) {
|
||||
$('#mainContent legend').html(data.legendText);
|
||||
$('#mainContent .card-header').html(data.legendText);
|
||||
$('#mainContent h4').html(data.headText);
|
||||
$('#mainContent p').html(data.subText);
|
||||
$('#mainContent #extra').html(data.extra);
|
||||
$('#mainContent #newCols').html('');
|
||||
$('.tblFooters').html('');
|
||||
$('#mainContent .card-footer').html('');
|
||||
primaryKey = JSON.parse(data.primary_key);
|
||||
for (var pk in primaryKey) {
|
||||
$('#extra input[value=\'' + escapeJsString(primaryKey[pk]) + '\']').attr('disabled', 'disabled');
|
||||
@ -202,11 +202,11 @@ function goToStep2 (extra = undefined) {
|
||||
'table': CommonParams.get('table'),
|
||||
'server': CommonParams.get('server')
|
||||
}, function (data) {
|
||||
$('#mainContent legend').html(data.legendText);
|
||||
$('#mainContent .card-header').html(data.legendText);
|
||||
$('#mainContent h4').html(data.headText);
|
||||
$('#mainContent p').html(data.subText);
|
||||
$('#mainContent #extra,#mainContent #newCols').html('');
|
||||
$('.tblFooters').html('');
|
||||
$('#mainContent .card-footer').html('');
|
||||
if (data.hasPrimaryKey === '1') {
|
||||
if (extra === 'goToStep3') {
|
||||
$('#mainContent h4').html(window.Messages.strPrimaryKeyAdded);
|
||||
@ -257,11 +257,11 @@ function goTo2NFFinish (pd) {
|
||||
return true;
|
||||
}
|
||||
|
||||
$('#mainContent legend').html(data.legendText);
|
||||
$('#mainContent .card-header').html(data.legendText);
|
||||
$('#mainContent h4').html(data.headText);
|
||||
$('#mainContent p').html('');
|
||||
$('#mainContent #extra').html('');
|
||||
$('.tblFooters').html('');
|
||||
$('#mainContent .card-footer').html('');
|
||||
} else {
|
||||
ajaxShowMessage(data.extra, false);
|
||||
}
|
||||
@ -299,11 +299,11 @@ function goTo3NFFinish (newTables) {
|
||||
success: function (data) {
|
||||
if (data.success === true) {
|
||||
if (data.queryError === false) {
|
||||
$('#mainContent legend').html(data.legendText);
|
||||
$('#mainContent .card-header').html(data.legendText);
|
||||
$('#mainContent h4').html(data.headText);
|
||||
$('#mainContent p').html('');
|
||||
$('#mainContent #extra').html('');
|
||||
$('.tblFooters').html('');
|
||||
$('#mainContent .card-footer').html('');
|
||||
} else {
|
||||
ajaxShowMessage(data.extra, false);
|
||||
}
|
||||
@ -320,7 +320,7 @@ var backup = '';
|
||||
|
||||
function goTo2NFStep2 (pd, primaryKey) {
|
||||
$('#newCols').html('');
|
||||
$('#mainContent legend').html(window.Messages.strStep + ' 2.2 ' + window.Messages.strConfirmPd);
|
||||
$('#mainContent .card-header').html(window.Messages.strStep + ' 2.2 ' + window.Messages.strConfirmPd);
|
||||
$('#mainContent h4').html(window.Messages.strSelectedPd);
|
||||
$('#mainContent p').html(window.Messages.strPdHintNote);
|
||||
var extra = '<div class="dependencies_box">';
|
||||
@ -360,7 +360,7 @@ function goTo2NFStep2 (pd, primaryKey) {
|
||||
}
|
||||
|
||||
$('#mainContent #extra').html(extra);
|
||||
$('.tblFooters').html('<input type="button" class="btn btn-primary" value="' + window.Messages.strBack + '" id="backEditPd"><input type="button" class="btn btn-primary" id="goTo2NFFinish" value="' + window.Messages.strGo + '">');
|
||||
$('#mainContent .card-footer').html('<input type="button" class="btn btn-primary" value="' + window.Messages.strBack + '" id="backEditPd"><input type="button" class="btn btn-primary" id="goTo2NFFinish" value="' + window.Messages.strGo + '">');
|
||||
$('#goTo2NFFinish').on('click', function () {
|
||||
goTo2NFFinish(pd);
|
||||
});
|
||||
@ -368,7 +368,7 @@ function goTo2NFStep2 (pd, primaryKey) {
|
||||
|
||||
function goTo3NFStep2 (pd, tablesTds) {
|
||||
$('#newCols').html('');
|
||||
$('#mainContent legend').html(window.Messages.strStep + ' 3.2 ' + window.Messages.strConfirmTd);
|
||||
$('#mainContent .card-header').html(window.Messages.strStep + ' 3.2 ' + window.Messages.strConfirmTd);
|
||||
$('#mainContent h4').html(window.Messages.strSelectedTd);
|
||||
$('#mainContent p').html(window.Messages.strPdHintNote);
|
||||
var extra = '<div class="dependencies_box">';
|
||||
@ -412,7 +412,7 @@ function goTo3NFStep2 (pd, tablesTds) {
|
||||
}
|
||||
|
||||
$('#mainContent #extra').html(extra);
|
||||
$('.tblFooters').html('<input type="button" class="btn btn-primary" value="' + window.Messages.strBack + '" id="backEditPd"><input type="button" class="btn btn-primary" id="goTo3NFFinish" value="' + window.Messages.strGo + '">');
|
||||
$('#mainContent .card-footer').html('<input type="button" class="btn btn-primary" value="' + window.Messages.strBack + '" id="backEditPd"><input type="button" class="btn btn-primary" id="goTo3NFFinish" value="' + window.Messages.strGo + '">');
|
||||
$('#goTo3NFFinish').on('click', function () {
|
||||
if (! pdFound) {
|
||||
goTo3NFFinish([]);
|
||||
@ -528,9 +528,9 @@ function moveRepeatingGroup (repeatingCols) {
|
||||
AJAX.registerTeardown('normalization.js', function () {
|
||||
$('#extra').off('click', '#selectNonAtomicCol');
|
||||
$('#splitGo').off('click');
|
||||
$('.tblFooters').off('click', '#saveSplit');
|
||||
$('#mainContent .card-footer').off('click', '#saveSplit');
|
||||
$('#extra').off('click', '#addNewPrimary');
|
||||
$('.tblFooters').off('click', '#saveNewPrimary');
|
||||
$('#mainContent .card-footer').off('click', '#saveNewPrimary');
|
||||
$('#extra').off('click', '#removeRedundant');
|
||||
$('#mainContent p').off('click', '#createPrimaryKey');
|
||||
$('#mainContent').off('click', '#backEditPd');
|
||||
@ -577,7 +577,7 @@ AJAX.registerOnload('normalization.js', function () {
|
||||
value: window.Messages.strSave,
|
||||
class: 'btn btn-primary'
|
||||
})
|
||||
.appendTo('.tblFooters');
|
||||
.appendTo('#mainContent .card-footer');
|
||||
|
||||
$('<input>')
|
||||
.attr({
|
||||
@ -590,7 +590,7 @@ AJAX.registerOnload('normalization.js', function () {
|
||||
$('#newCols').html('');
|
||||
$(this).parent().html('');
|
||||
})
|
||||
.appendTo('.tblFooters');
|
||||
.appendTo('#mainContent .card-footer');
|
||||
}
|
||||
}
|
||||
);
|
||||
@ -598,7 +598,7 @@ AJAX.registerOnload('normalization.js', function () {
|
||||
return false;
|
||||
});
|
||||
|
||||
$('.tblFooters').on('click', '#saveSplit', function () {
|
||||
$('#mainContent .card-footer').on('click', '#saveSplit', function () {
|
||||
window.centralColumnList = [];
|
||||
if ($('#newCols #field_0_1').val() === '') {
|
||||
$('#newCols #field_0_1').trigger('focus');
|
||||
@ -627,7 +627,7 @@ AJAX.registerOnload('normalization.js', function () {
|
||||
if (data.success === true) {
|
||||
appendHtmlColumnsList();
|
||||
$('#newCols').html('');
|
||||
$('.tblFooters').html('');
|
||||
$('#mainContent .card-footer').html('');
|
||||
} else {
|
||||
ajaxShowMessage(data.error, false);
|
||||
}
|
||||
@ -663,7 +663,7 @@ AJAX.registerOnload('normalization.js', function () {
|
||||
value: window.Messages.strSave,
|
||||
class: 'btn btn-primary'
|
||||
})
|
||||
.appendTo('.tblFooters');
|
||||
.appendTo('#mainContent .card-footer');
|
||||
|
||||
$('<input>')
|
||||
.attr({
|
||||
@ -676,7 +676,7 @@ AJAX.registerOnload('normalization.js', function () {
|
||||
$('#newCols').html('');
|
||||
$(this).parent().html('');
|
||||
})
|
||||
.appendTo('.tblFooters');
|
||||
.appendTo('#mainContent .card-footer');
|
||||
} else {
|
||||
ajaxShowMessage(data.error, false);
|
||||
}
|
||||
@ -686,7 +686,7 @@ AJAX.registerOnload('normalization.js', function () {
|
||||
return false;
|
||||
});
|
||||
|
||||
$('.tblFooters').on('click', '#saveNewPrimary', function () {
|
||||
$('#mainContent .card-footer').on('click', '#saveNewPrimary', function () {
|
||||
var datastring = $('#newCols :input').serialize();
|
||||
var argsep = CommonParams.get('arg_separator');
|
||||
datastring += argsep + 'field_key[0]=primary_0' + argsep + 'ajax_request=1' + argsep + 'do_save_data=1' + argsep + 'field_where=last';
|
||||
@ -696,7 +696,7 @@ AJAX.registerOnload('normalization.js', function () {
|
||||
$('#mainContent p').html(window.Messages.strToNextStep);
|
||||
$('#mainContent #extra').html('');
|
||||
$('#mainContent #newCols').html('');
|
||||
$('.tblFooters').html('');
|
||||
$('#mainContent .card-footer').html('');
|
||||
setTimeout(function () {
|
||||
goToStep3();
|
||||
}, 2000);
|
||||
@ -759,7 +759,7 @@ AJAX.registerOnload('normalization.js', function () {
|
||||
$('#newCols').html('');
|
||||
$('#extra input[type=checkbox]').prop('checked', false);
|
||||
})
|
||||
.appendTo('.tblFooters');
|
||||
.appendTo('#mainContent .card-footer');
|
||||
|
||||
$('<input>')
|
||||
.attr({
|
||||
@ -770,7 +770,7 @@ AJAX.registerOnload('normalization.js', function () {
|
||||
.on('click', function () {
|
||||
moveRepeatingGroup(repeatingCols);
|
||||
})
|
||||
.appendTo('.tblFooters');
|
||||
.appendTo('#mainContent .card-footer');
|
||||
}
|
||||
});
|
||||
|
||||
@ -791,7 +791,7 @@ AJAX.registerOnload('normalization.js', function () {
|
||||
// on success
|
||||
$('.sqlqueryresults').remove();
|
||||
$('.result_query').remove();
|
||||
$('.tblFooters').html('');
|
||||
$('#mainContent .card-footer').html('');
|
||||
goToStep2('goToStep3');
|
||||
});
|
||||
|
||||
|
||||
@ -1932,18 +1932,19 @@ AJAX.registerOnload('server/status/monitor.js', function () {
|
||||
/* Add filter options if more than a bunch of rows there to filter */
|
||||
if (logData.numRows > 12) {
|
||||
$('#logTable').prepend(
|
||||
'<fieldset class="pma-fieldset" id="logDataFilter">' +
|
||||
' <legend>' + window.Messages.strFiltersForLogTable + '</legend>' +
|
||||
' <div class="formelement">' +
|
||||
' <label for="filterQueryText">' + window.Messages.strFilterByWordRegexp + '</label>' +
|
||||
' <input name="filterQueryText" type="text" id="filterQueryText">' +
|
||||
'<div class="card mb-3">' +
|
||||
'<div class="card-header">' + window.Messages.strFiltersForLogTable + '</div>' +
|
||||
'<div class="card-body">' +
|
||||
' <div class="mb-3">' +
|
||||
' <label class="form-label" for="filterQueryText">' + window.Messages.strFilterByWordRegexp + '</label>' +
|
||||
' <input class="form-control" name="filterQueryText" type="text" id="filterQueryText">' +
|
||||
' </div>' +
|
||||
((logData.numRows > 250) ? ' <div class="formelement"><button class="btn btn-secondary" name="startFilterQueryText" id="startFilterQueryText">' + window.Messages.strFilter + '</button></div>' : '') +
|
||||
' <div class="formelement">' +
|
||||
' <input type="checkbox" id="noWHEREData" name="noWHEREData" value="1"> ' +
|
||||
' <label for="noWHEREData"> ' + window.Messages.strIgnoreWhereAndGroup + '</label>' +
|
||||
' </div' +
|
||||
'</fieldset>'
|
||||
' <div class="form-check">' +
|
||||
' <input class="form-check-input" type="checkbox" id="noWHEREData" name="noWHEREData" value="1"> ' +
|
||||
' <label class="form-check-label" for="noWHEREData"> ' + window.Messages.strIgnoreWhereAndGroup + '</label>' +
|
||||
' </div>' +
|
||||
((logData.numRows > 250) ? ' <div class="mt-3"><button class="btn btn-secondary" name="startFilterQueryText" id="startFilterQueryText">' + window.Messages.strFilter + '</button></div>' : '') +
|
||||
'</div></div>'
|
||||
);
|
||||
|
||||
$('#noWHEREData').on('change', function () {
|
||||
|
||||
@ -48,7 +48,7 @@ class DesignerController extends AbstractController
|
||||
} elseif ($dialog === 'export') {
|
||||
$html = $this->databaseDesigner->getHtmlForSchemaExport(
|
||||
$db,
|
||||
$request->getParsedBodyParam('selected_page'),
|
||||
(int) $request->getParsedBodyParam('selected_page'),
|
||||
);
|
||||
} elseif ($dialog === 'add_table') {
|
||||
// Pass the db and table to the getTablesInfo so we only have the table we asked for
|
||||
|
||||
@ -105,7 +105,7 @@ class HomeController extends AbstractController
|
||||
&& (count($GLOBALS['cfg']['Servers']) > 1
|
||||
|| ($GLOBALS['server'] == 0 && count($GLOBALS['cfg']['Servers']) === 1)));
|
||||
if ($hasServerSelection) {
|
||||
$serverSelection = Select::render(true, true);
|
||||
$serverSelection = Select::render(true);
|
||||
}
|
||||
|
||||
if ($GLOBALS['server'] > 0) {
|
||||
|
||||
@ -901,9 +901,9 @@ class Generator
|
||||
|
||||
$_SESSION['Import_message']['go_back_url'] = $backUrl;
|
||||
|
||||
$errorMessage .= '<fieldset class="pma-fieldset tblFooters">'
|
||||
$errorMessage .= '<div class="card"><div class="card-body">'
|
||||
. '[ <a href="' . $backUrl . '">' . __('Back') . '</a> ]'
|
||||
. '</fieldset>' . "\n\n";
|
||||
. '</div></div>' . "\n\n";
|
||||
}
|
||||
|
||||
$response->callExit($errorMessage);
|
||||
|
||||
@ -84,7 +84,7 @@ class Navigation
|
||||
}
|
||||
|
||||
if ($GLOBALS['cfg']['NavigationDisplayServers'] && count($GLOBALS['cfg']['Servers']) > 1) {
|
||||
$serverSelect = Select::render(true, true);
|
||||
$serverSelect = Select::render(true);
|
||||
}
|
||||
|
||||
if (! defined('PMA_DISABLE_NAVI_SETTINGS')) {
|
||||
|
||||
@ -193,11 +193,10 @@ class Normalization
|
||||
{
|
||||
$step = 1;
|
||||
$stepTxt = __('Make all columns atomic');
|
||||
$html = "<h3 class='text-center'>"
|
||||
. __('First step of normalization (1NF)') . '</h3>';
|
||||
$html .= "<div id='mainContent' data-normalizeto='" . $normalizedTo . "'>"
|
||||
. '<fieldset class="pma-fieldset">'
|
||||
. '<legend>' . __('Step 1.') . $step . ' ' . $stepTxt . '</legend>'
|
||||
$html = '<h3>' . __('First step of normalization (1NF)') . '</h3>';
|
||||
$html .= '<div class="card" id="mainContent" data-normalizeto="' . $normalizedTo . '">'
|
||||
. '<div class="card-header">' . __('Step 1.') . $step . ' ' . $stepTxt . '</div>'
|
||||
. '<div class="card-body">'
|
||||
. '<h4>' . __(
|
||||
'Do you have any column which can be split into more than one column?'
|
||||
. ' For example: address can be split into street, city, country and zip.',
|
||||
@ -225,8 +224,7 @@ class Normalization
|
||||
. "</span><input id='numField' type='number' value='2'>"
|
||||
. '<input type="submit" class="btn btn-primary" id="splitGo" value="' . __('Go') . '"></div>'
|
||||
. "<div id='newCols'></div>"
|
||||
. '</fieldset><fieldset class="pma-fieldset tblFooters">'
|
||||
. '</fieldset>'
|
||||
. '</div><div class="card-footer"></div>'
|
||||
. '</div>';
|
||||
|
||||
return $html;
|
||||
|
||||
@ -147,7 +147,7 @@ class AuthenticationConfig extends AuthenticationPlugin
|
||||
// offer a chance to login to other servers if the current one failed
|
||||
echo '<tr>' , "\n";
|
||||
echo ' <td>' , "\n";
|
||||
echo Select::render(true, true);
|
||||
echo Select::render(true);
|
||||
echo ' </td>' , "\n";
|
||||
echo '</tr>' , "\n";
|
||||
}
|
||||
|
||||
@ -138,7 +138,7 @@ class AuthenticationCookie extends AuthenticationPlugin
|
||||
$serversOptions = '';
|
||||
$hasServers = count($GLOBALS['cfg']['Servers']) > 1;
|
||||
if ($hasServers) {
|
||||
$serversOptions = Select::render(false, false);
|
||||
$serversOptions = Select::render(false);
|
||||
}
|
||||
|
||||
$formParams = [];
|
||||
|
||||
@ -22,9 +22,8 @@ class Select
|
||||
* Renders the server selection in list or selectbox form, or option tags only
|
||||
*
|
||||
* @param bool $notOnlyOptions whether to include form tags or not
|
||||
* @param bool $omitFieldset whether to omit fieldset tag or not
|
||||
*/
|
||||
public static function render(bool $notOnlyOptions, bool $omitFieldset): string
|
||||
public static function render(bool $notOnlyOptions): string
|
||||
{
|
||||
// Show as list?
|
||||
if ($notOnlyOptions) {
|
||||
@ -90,7 +89,6 @@ class Select
|
||||
|
||||
return $template->render('server/select/index', [
|
||||
'not_only_options' => $notOnlyOptions,
|
||||
'omit_fieldset' => $omitFieldset,
|
||||
'servers' => $servers,
|
||||
'form_action' => $formAction,
|
||||
]);
|
||||
|
||||
@ -777,7 +777,7 @@ parameters:
|
||||
|
||||
-
|
||||
message: "#^Cannot cast mixed to int\\.$#"
|
||||
count: 1
|
||||
count: 2
|
||||
path: libraries/classes/Controllers/Database/DesignerController.php
|
||||
|
||||
-
|
||||
@ -885,11 +885,6 @@ parameters:
|
||||
count: 1
|
||||
path: libraries/classes/Controllers/Database/DesignerController.php
|
||||
|
||||
-
|
||||
message: "#^Parameter \\#2 \\$page of method PhpMyAdmin\\\\Database\\\\Designer\\:\\:getHtmlForSchemaExport\\(\\) expects int, mixed given\\.$#"
|
||||
count: 1
|
||||
path: libraries/classes/Controllers/Database/DesignerController.php
|
||||
|
||||
-
|
||||
message: "#^Parameter \\#2 \\$table of method PhpMyAdmin\\\\Database\\\\Designer\\\\Common\\:\\:getTablesInfo\\(\\) expects string\\|null, mixed given\\.$#"
|
||||
count: 2
|
||||
|
||||
@ -1005,7 +1005,6 @@
|
||||
<code><![CDATA[$request->getParsedBodyParam('on_delete')]]></code>
|
||||
<code><![CDATA[$request->getParsedBodyParam('on_update')]]></code>
|
||||
<code><![CDATA[$request->getParsedBodyParam('selected_page')]]></code>
|
||||
<code><![CDATA[$request->getParsedBodyParam('selected_page')]]></code>
|
||||
<code><![CDATA[$request->getParsedBodyParam('selected_value')]]></code>
|
||||
<code><![CDATA[$request->getParsedBodyParam('selected_value')]]></code>
|
||||
<code><![CDATA[$request->getParsedBodyParam('selected_value')]]></code>
|
||||
|
||||
@ -287,23 +287,6 @@ fieldset {
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
&.simple {
|
||||
th {
|
||||
width: auto;
|
||||
min-width: 0;
|
||||
}
|
||||
|
||||
th,
|
||||
td {
|
||||
border-top: none;
|
||||
border-bottom: 1px #555 dotted;
|
||||
}
|
||||
|
||||
.lastrow {
|
||||
border: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.doc {
|
||||
margin-left: 1em;
|
||||
}
|
||||
|
||||
@ -20,38 +20,6 @@ textarea {
|
||||
}
|
||||
}
|
||||
|
||||
.pma-fieldset {
|
||||
margin-top: 1em;
|
||||
border-radius: 4px 4px 0 0;
|
||||
border: #aaa solid 1px;
|
||||
padding: 0.5em;
|
||||
background: #eee;
|
||||
text-shadow: 1px 1px 2px $white;
|
||||
box-shadow: 1px 1px 2px $white inset;
|
||||
}
|
||||
|
||||
.pma-fieldset {
|
||||
.pma-fieldset {
|
||||
margin: 0.8em;
|
||||
border: 1px solid #aaa;
|
||||
background: #e8e8e8;
|
||||
}
|
||||
|
||||
legend {
|
||||
float: none;
|
||||
font-weight: bold;
|
||||
color: #444;
|
||||
padding: 5px 10px;
|
||||
border-radius: 2px;
|
||||
border: 1px solid #aaa;
|
||||
background-color: $white;
|
||||
max-width: 100%;
|
||||
box-shadow: 3px 3px 15px #bbb;
|
||||
width: initial;
|
||||
font-size: 1em;
|
||||
}
|
||||
}
|
||||
|
||||
// 3.4
|
||||
.datatable {
|
||||
table-layout: fixed;
|
||||
@ -71,17 +39,6 @@ textarea {
|
||||
text-shadow: 0 1px 0 $black;
|
||||
}
|
||||
|
||||
.pma-fieldset.tblFooters {
|
||||
margin-top: 0;
|
||||
margin-bottom: 0.5em;
|
||||
// avoid a thick line since this should be used under another fieldset
|
||||
border-top: 0;
|
||||
text-align: right;
|
||||
float: none;
|
||||
clear: both;
|
||||
border-radius: 0 0 4px 4px;
|
||||
}
|
||||
|
||||
div.null_div {
|
||||
height: 20px;
|
||||
text-align: center;
|
||||
@ -102,20 +59,6 @@ div.null_div {
|
||||
}
|
||||
}
|
||||
|
||||
.pma-fieldset {
|
||||
.formelement {
|
||||
float: left;
|
||||
margin-right: 0.5em;
|
||||
// IE
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
// revert for Gecko
|
||||
div[class=formelement] {
|
||||
white-space: normal;
|
||||
}
|
||||
}
|
||||
|
||||
button.mult_submit {
|
||||
border: none;
|
||||
background-color: transparent;
|
||||
@ -227,11 +170,6 @@ td .icon {
|
||||
padding: 0 0.5em;
|
||||
}
|
||||
|
||||
.confirmation {
|
||||
color: $black;
|
||||
background-color: pink;
|
||||
}
|
||||
|
||||
// end messageboxes
|
||||
|
||||
.new_central_col {
|
||||
@ -244,39 +182,6 @@ td .icon {
|
||||
color: #009;
|
||||
}
|
||||
|
||||
.tblHeaders {
|
||||
font-weight: bold;
|
||||
color: $black;
|
||||
background: #d3dce3;
|
||||
}
|
||||
|
||||
.tblFooters {
|
||||
font-weight: normal;
|
||||
color: $black;
|
||||
background: #d3dce3;
|
||||
}
|
||||
|
||||
.tblHeaders a {
|
||||
&:link,
|
||||
&:active,
|
||||
&:visited {
|
||||
color: #00f;
|
||||
}
|
||||
}
|
||||
|
||||
.tblFooters a {
|
||||
&:link,
|
||||
&:active,
|
||||
&:visited {
|
||||
color: #00f;
|
||||
}
|
||||
}
|
||||
|
||||
.tblHeaders a:hover,
|
||||
.tblFooters a:hover {
|
||||
color: #f00;
|
||||
}
|
||||
|
||||
.error {
|
||||
border: 1px solid maroon !important;
|
||||
margin-left: 2px;
|
||||
@ -388,10 +293,6 @@ label.col-3.d-flex.align-items-center {
|
||||
color: gray;
|
||||
}
|
||||
|
||||
.max_height_400 {
|
||||
max-height: 400px;
|
||||
}
|
||||
|
||||
li.last.database {
|
||||
// Avoid having the last item of the tree hidden behind the scroll bar
|
||||
margin-bottom: 15px !important;
|
||||
@ -549,10 +450,6 @@ div#tablestatistics table {
|
||||
}
|
||||
}
|
||||
|
||||
#fieldset_user_global_rights .pma-fieldset {
|
||||
float: left;
|
||||
}
|
||||
|
||||
#fieldset_user_global_rights > legend input {
|
||||
margin-left: 2em;
|
||||
}
|
||||
@ -576,8 +473,7 @@ caption a.top {
|
||||
|
||||
div {
|
||||
&#serverstatus table {
|
||||
tbody td.descr a,
|
||||
.tblFooters a {
|
||||
tbody td.descr a {
|
||||
white-space: nowrap;
|
||||
}
|
||||
}
|
||||
@ -1321,22 +1217,6 @@ input#auto_increment_opt {
|
||||
}
|
||||
}
|
||||
|
||||
.doubleFieldset {
|
||||
.pma-fieldset {
|
||||
width: 48%;
|
||||
float: left;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
legend {
|
||||
margin-left: 1.5em;
|
||||
}
|
||||
|
||||
div.wrap {
|
||||
padding: 1.5em;
|
||||
}
|
||||
}
|
||||
|
||||
#table_name_col_no_outer {
|
||||
margin-top: 45px;
|
||||
}
|
||||
@ -1748,10 +1628,6 @@ body .ui-widget {
|
||||
font-size: 1em;
|
||||
}
|
||||
|
||||
.ui-dialog .pma-fieldset legend a {
|
||||
color: #235a81;
|
||||
}
|
||||
|
||||
.ui-draggable {
|
||||
z-index: 801;
|
||||
}
|
||||
@ -2513,31 +2389,6 @@ body .ui-dialog {
|
||||
}
|
||||
// end of styles for jQuery-ui to support rtl languages
|
||||
|
||||
/* templates/database/multi_table_query */
|
||||
|
||||
.multi_table_query_form {
|
||||
.query-form__tr--hide {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.query-form__fieldset--inline,
|
||||
.query-form__select--inline {
|
||||
display: inline;
|
||||
}
|
||||
|
||||
.query-form__tr--bg-none {
|
||||
background: none;
|
||||
}
|
||||
|
||||
.query-form__input--wide {
|
||||
width: 91%;
|
||||
}
|
||||
|
||||
.query-form__multi-sql-query {
|
||||
float: left;
|
||||
}
|
||||
}
|
||||
|
||||
// templates/database/designer
|
||||
// side menu
|
||||
#name-panel {
|
||||
@ -2587,10 +2438,6 @@ body .ui-dialog {
|
||||
}
|
||||
}
|
||||
|
||||
.doubleFieldset .pma-fieldset {
|
||||
width: 98%;
|
||||
}
|
||||
|
||||
.ui-dialog {
|
||||
margin: 1%;
|
||||
width: 95% !important;
|
||||
@ -2641,14 +2488,6 @@ body .ui-dialog {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
// Extra large devices (large desktops, 1200px and up)
|
||||
@include media-breakpoint-up(xl) {
|
||||
.pma-fieldset.tblFooters,
|
||||
.tblFooters {
|
||||
text-align: left;
|
||||
}
|
||||
}
|
||||
|
||||
.resize-vertical {
|
||||
resize: vertical;
|
||||
}
|
||||
|
||||
@ -440,11 +440,6 @@ a {
|
||||
}
|
||||
}
|
||||
|
||||
#foreignkeychk {
|
||||
text-align: left;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.side-menu {
|
||||
float: left;
|
||||
position: fixed;
|
||||
|
||||
@ -67,8 +67,7 @@ body#loginform {
|
||||
line-height: 2;
|
||||
}
|
||||
|
||||
a.logo,
|
||||
.pma-fieldset legend {
|
||||
a.logo {
|
||||
display: none;
|
||||
}
|
||||
|
||||
@ -137,8 +136,7 @@ body#loginform {
|
||||
}
|
||||
|
||||
.card,
|
||||
.card-footer,
|
||||
.pma-fieldset {
|
||||
.card-footer {
|
||||
border: none;
|
||||
color: var(--navi-color);
|
||||
padding: 0;
|
||||
@ -150,12 +148,6 @@ body#loginform {
|
||||
border-bottom: none;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
&.tblFooters {
|
||||
border: none;
|
||||
margin: 0;
|
||||
clear: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -314,20 +306,6 @@ textarea {
|
||||
background-color: $body-bg;
|
||||
}
|
||||
|
||||
.pma-fieldset {
|
||||
margin-top: 20px;
|
||||
border: 1px solid $border-color;
|
||||
padding: 20px;
|
||||
background-color: $th-background;
|
||||
|
||||
.pma-fieldset {
|
||||
margin: 20px;
|
||||
margin-bottom: 0;
|
||||
background-color: $body-bg;
|
||||
border: none;
|
||||
}
|
||||
}
|
||||
|
||||
legend {
|
||||
float: none;
|
||||
padding: 0 5px;
|
||||
@ -382,14 +360,6 @@ select {
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
|
||||
.pma-fieldset.tblFooters {
|
||||
margin-top: -1px;
|
||||
border-top: 0;
|
||||
text-align: right;
|
||||
float: none;
|
||||
clear: both;
|
||||
}
|
||||
|
||||
div.null_div {
|
||||
height: 20px;
|
||||
text-align: center;
|
||||
@ -410,18 +380,6 @@ div.null_div {
|
||||
}
|
||||
}
|
||||
|
||||
.pma-fieldset {
|
||||
.formelement {
|
||||
float: left;
|
||||
margin-right: 0.5em;
|
||||
}
|
||||
|
||||
/* revert for Gecko */
|
||||
div[class="formelement"] {
|
||||
white-space: normal;
|
||||
}
|
||||
}
|
||||
|
||||
button.mult_submit {
|
||||
border: none;
|
||||
background-color: transparent;
|
||||
@ -535,15 +493,6 @@ img.lightbulb {
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.confirmation {
|
||||
color: $button-color;
|
||||
background-color: var(--browse-warning-color);
|
||||
}
|
||||
|
||||
.pma-fieldset.confirmation legend {
|
||||
background-color: var(--browse-warning-color);
|
||||
}
|
||||
|
||||
.error {
|
||||
border: 1px solid var(--browse-warning-color) !important;
|
||||
padding: 5px;
|
||||
@ -568,34 +517,6 @@ img.lightbulb {
|
||||
color: #009;
|
||||
}
|
||||
|
||||
.tblHeaders {
|
||||
font-family: $font-family-bold;
|
||||
color: $th-color;
|
||||
background: $th-background;
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
.tblFooters {
|
||||
font-weight: normal;
|
||||
color: $th-color;
|
||||
background: $th-background;
|
||||
}
|
||||
|
||||
.tblHeaders,
|
||||
.tblFooters {
|
||||
a {
|
||||
&:link,
|
||||
&:active,
|
||||
&:visited {
|
||||
color: #00f;
|
||||
}
|
||||
|
||||
&:hover {
|
||||
color: #f00;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* disabled text */
|
||||
.disabled {
|
||||
color: #666;
|
||||
@ -786,10 +707,6 @@ div#tablestatistics table {
|
||||
}
|
||||
}
|
||||
|
||||
#fieldset_user_global_rights .pma-fieldset {
|
||||
float: left;
|
||||
}
|
||||
|
||||
/* END user privileges */
|
||||
|
||||
/* serverstatus */
|
||||
@ -810,8 +727,7 @@ caption a.top {
|
||||
|
||||
div {
|
||||
&#serverstatus table {
|
||||
tbody td.descr a,
|
||||
.tblFooters a {
|
||||
tbody td.descr a {
|
||||
white-space: nowrap;
|
||||
}
|
||||
}
|
||||
@ -1287,62 +1203,9 @@ table#index_columns {
|
||||
/* config forms */
|
||||
|
||||
.config-form {
|
||||
.pma-fieldset {
|
||||
margin-top: 0;
|
||||
padding: 0;
|
||||
clear: both;
|
||||
background: none;
|
||||
}
|
||||
|
||||
legend {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.pma-fieldset {
|
||||
p {
|
||||
margin: 0;
|
||||
padding: 10px;
|
||||
background: #fff;
|
||||
font-family: $font-family-light;
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
/* form error list */
|
||||
.errors {
|
||||
margin: 0 -2px 1em;
|
||||
padding: 0.5em 1.5em;
|
||||
background: #fbead9;
|
||||
border-color: #c83838;
|
||||
border-style: solid;
|
||||
border-width: 1px 0;
|
||||
list-style: none;
|
||||
font-family: sans-serif;
|
||||
font-size: small;
|
||||
}
|
||||
|
||||
/* field error list */
|
||||
.inline_errors {
|
||||
margin: 0.3em 0.3em 0.3em;
|
||||
margin-left: 0;
|
||||
padding: 0;
|
||||
list-style: none;
|
||||
color: #9a0000;
|
||||
font-size: small;
|
||||
}
|
||||
|
||||
table {
|
||||
background-color: #fff;
|
||||
}
|
||||
|
||||
label {
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
textarea {
|
||||
margin: 5px;
|
||||
padding: 5px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.insertRowTable textarea {
|
||||
@ -1439,18 +1302,6 @@ fieldset {
|
||||
}
|
||||
}
|
||||
|
||||
form {
|
||||
&.create_table_form .pma-fieldset.tblFooters,
|
||||
&#multi_edit_central_columns .pma-fieldset.tblFooters {
|
||||
background: none;
|
||||
border: none;
|
||||
}
|
||||
}
|
||||
|
||||
#db_or_table_specific_priv .tblFooters {
|
||||
margin-top: -68px;
|
||||
}
|
||||
|
||||
#edit_user_dialog,
|
||||
#add_user_dialog {
|
||||
margin: 20px !important;
|
||||
@ -1600,27 +1451,6 @@ input#auto_increment_opt {
|
||||
}
|
||||
}
|
||||
|
||||
.doubleFieldset {
|
||||
.pma-fieldset {
|
||||
width: 48%;
|
||||
float: left;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
legend {
|
||||
margin-left: 1.5em;
|
||||
}
|
||||
|
||||
div.wrap {
|
||||
padding: 1.5em;
|
||||
}
|
||||
}
|
||||
|
||||
form.append_fields_form .tblFooters {
|
||||
background: none;
|
||||
border: none;
|
||||
}
|
||||
|
||||
#table_columns {
|
||||
display: block;
|
||||
overflow: auto;
|
||||
@ -2032,10 +1862,6 @@ body #ui-datepicker-div {
|
||||
z-index: 9999 !important;
|
||||
}
|
||||
|
||||
.ui-dialog .pma-fieldset legend a {
|
||||
color: #235a81;
|
||||
}
|
||||
|
||||
div#page_content div {
|
||||
&#tableslistcontainer {
|
||||
margin-top: 1em;
|
||||
@ -2804,45 +2630,12 @@ body {
|
||||
vertical-align: baseline;
|
||||
}
|
||||
|
||||
/* templates/database/multi_table_query */
|
||||
|
||||
.multi_table_query_form {
|
||||
.query-form__tr--hide {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.query-form__fieldset--inline,
|
||||
.query-form__select--inline {
|
||||
display: inline;
|
||||
}
|
||||
|
||||
.query-form__tr--bg-none {
|
||||
background: none;
|
||||
}
|
||||
|
||||
.query-form__input--wide {
|
||||
width: 91%;
|
||||
}
|
||||
|
||||
.query-form__multi-sql-query {
|
||||
float: left;
|
||||
}
|
||||
}
|
||||
|
||||
// Enable scrollable blocks of code
|
||||
.pre-scrollable {
|
||||
max-height: 340px;
|
||||
overflow-y: scroll;
|
||||
}
|
||||
|
||||
// Extra large devices (large desktops, 1200px and up)
|
||||
@include media-breakpoint-up(xl) {
|
||||
.pma-fieldset.tblFooters,
|
||||
.tblFooters {
|
||||
text-align: left;
|
||||
}
|
||||
}
|
||||
|
||||
.resize-vertical {
|
||||
resize: vertical;
|
||||
}
|
||||
|
||||
@ -380,11 +380,6 @@ a {
|
||||
}
|
||||
}
|
||||
|
||||
#foreignkeychk {
|
||||
text-align: left;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.side-menu {
|
||||
float: left;
|
||||
position: fixed;
|
||||
|
||||
@ -60,26 +60,6 @@ textarea.charField {
|
||||
width: 95%;
|
||||
}
|
||||
|
||||
.pma-fieldset {
|
||||
margin-top: 1em;
|
||||
border: $main-color solid 1px;
|
||||
padding: 0.5em;
|
||||
background: $bg-one;
|
||||
|
||||
.pma-fieldset {
|
||||
margin: 0.8em;
|
||||
}
|
||||
|
||||
legend {
|
||||
float: none;
|
||||
font-weight: bold;
|
||||
color: #444;
|
||||
background-color: transparent;
|
||||
width: initial;
|
||||
font-size: 1em;
|
||||
}
|
||||
}
|
||||
|
||||
// buttons in some browsers (eg. Konqueror) are block elements, this breaks design
|
||||
button {
|
||||
display: inline;
|
||||
@ -101,17 +81,6 @@ button {
|
||||
padding-top: 1em;
|
||||
}
|
||||
|
||||
.pma-fieldset.tblFooters {
|
||||
margin-top: 0;
|
||||
margin-bottom: 0.5em;
|
||||
|
||||
/* avoid a thick line since this should be used under another fieldset */
|
||||
border-top: 0;
|
||||
text-align: right;
|
||||
float: none;
|
||||
clear: both;
|
||||
}
|
||||
|
||||
div.null_div {
|
||||
height: 20px;
|
||||
text-align: center;
|
||||
@ -132,19 +101,6 @@ div.null_div {
|
||||
}
|
||||
}
|
||||
|
||||
.pma-fieldset {
|
||||
.formelement {
|
||||
float: left;
|
||||
margin-right: 0.5em;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
// revert for Gecko
|
||||
div[class="formelement"] {
|
||||
white-space: normal;
|
||||
}
|
||||
}
|
||||
|
||||
button.mult_submit {
|
||||
border: none;
|
||||
background-color: transparent;
|
||||
@ -238,24 +194,6 @@ img.lightbulb {
|
||||
padding: 0 0.5em;
|
||||
}
|
||||
|
||||
.confirmation {
|
||||
background-color: #ffc;
|
||||
}
|
||||
|
||||
.pma-fieldset.confirmation {
|
||||
border: 0.1em solid #f00;
|
||||
|
||||
legend {
|
||||
border-left: 0.1em solid #f00;
|
||||
border-right: 0.1em solid #f00;
|
||||
font-weight: bold;
|
||||
background-image: url("../img/s_really.png");
|
||||
background-repeat: no-repeat;
|
||||
background-position: 5px 50% #{"/* rtl:97% 50% */"};
|
||||
padding: 0.2em 0.2em 0.2em 25px;
|
||||
}
|
||||
}
|
||||
|
||||
.error {
|
||||
background-color: #ffc;
|
||||
color: #f00;
|
||||
@ -278,42 +216,6 @@ label.error {
|
||||
color: #009;
|
||||
}
|
||||
|
||||
.tblHeaders {
|
||||
font-weight: bold;
|
||||
color: $th-color;
|
||||
background: $th-background;
|
||||
}
|
||||
|
||||
.tblFooters {
|
||||
font-weight: normal;
|
||||
color: $th-color;
|
||||
background: $th-background;
|
||||
}
|
||||
|
||||
.tblHeaders a {
|
||||
&:link,
|
||||
&:active,
|
||||
&:visited {
|
||||
color: #00f;
|
||||
}
|
||||
|
||||
&:hover {
|
||||
color: #f00;
|
||||
}
|
||||
}
|
||||
|
||||
.tblFooters a {
|
||||
&:link,
|
||||
&:active,
|
||||
&:visited {
|
||||
color: #00f;
|
||||
}
|
||||
|
||||
&:hover {
|
||||
color: #f00;
|
||||
}
|
||||
}
|
||||
|
||||
/* disabled text */
|
||||
|
||||
.disabled {
|
||||
@ -395,10 +297,6 @@ div.container.modal_form {
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
#login_form .pma-fieldset.tblFooters {
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
#login_form select#select_server {
|
||||
width: 100%;
|
||||
}
|
||||
@ -446,10 +344,6 @@ div#modalOverlay {
|
||||
color: gray;
|
||||
}
|
||||
|
||||
.max_height_400 {
|
||||
max-height: 400px;
|
||||
}
|
||||
|
||||
li.last.database {
|
||||
// Avoid having the last item of the tree hidden behind the scroll bar
|
||||
margin-bottom: 15px !important;
|
||||
@ -597,10 +491,6 @@ div#tablestatistics table {
|
||||
}
|
||||
}
|
||||
|
||||
#fieldset_user_global_rights .pma-fieldset {
|
||||
float: left;
|
||||
}
|
||||
|
||||
#fieldset_user_global_rights > legend input {
|
||||
margin-left: 2em;
|
||||
}
|
||||
@ -621,8 +511,7 @@ caption a.top {
|
||||
|
||||
div {
|
||||
&#serverstatus table {
|
||||
tbody td.descr a,
|
||||
.tblFooters a {
|
||||
tbody td.descr a {
|
||||
white-space: nowrap;
|
||||
}
|
||||
}
|
||||
@ -1308,22 +1197,6 @@ input#auto_increment_opt {
|
||||
}
|
||||
}
|
||||
|
||||
.doubleFieldset {
|
||||
.pma-fieldset {
|
||||
width: 48%;
|
||||
float: left;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
legend {
|
||||
margin-left: 0.5em;
|
||||
}
|
||||
|
||||
div.wrap {
|
||||
padding: 0.5em;
|
||||
}
|
||||
}
|
||||
|
||||
#table_name_col_no_outer {
|
||||
margin-top: 45px;
|
||||
}
|
||||
@ -1751,10 +1624,6 @@ body #ui-datepicker-div {
|
||||
z-index: 9999 !important;
|
||||
}
|
||||
|
||||
.ui-dialog .pma-fieldset legend a {
|
||||
color: #00f;
|
||||
}
|
||||
|
||||
.ui-draggable {
|
||||
z-index: 801;
|
||||
}
|
||||
@ -2515,31 +2384,6 @@ body {
|
||||
}
|
||||
}
|
||||
|
||||
/* templates/database/multi_table_query */
|
||||
|
||||
.multi_table_query_form {
|
||||
.query-form__tr--hide {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.query-form__fieldset--inline,
|
||||
.query-form__select--inline {
|
||||
display: inline;
|
||||
}
|
||||
|
||||
.query-form__tr--bg-none {
|
||||
background: none;
|
||||
}
|
||||
|
||||
.query-form__input--wide {
|
||||
width: 91%;
|
||||
}
|
||||
|
||||
.query-form__multi-sql-query {
|
||||
float: left;
|
||||
}
|
||||
}
|
||||
|
||||
/* templates/database/designer */
|
||||
|
||||
/* side menu */
|
||||
@ -2584,10 +2428,6 @@ body {
|
||||
}
|
||||
}
|
||||
|
||||
.doubleFieldset .pma-fieldset {
|
||||
width: 98%;
|
||||
}
|
||||
|
||||
.ui-dialog {
|
||||
margin: 1%;
|
||||
width: 95% !important;
|
||||
@ -2644,14 +2484,6 @@ body {
|
||||
overflow-y: scroll;
|
||||
}
|
||||
|
||||
// Extra large devices (large desktops, 1200px and up)
|
||||
@include media-breakpoint-up(xl) {
|
||||
.pma-fieldset.tblFooters,
|
||||
.tblFooters {
|
||||
text-align: left;
|
||||
}
|
||||
}
|
||||
|
||||
.resize-vertical {
|
||||
resize: vertical;
|
||||
}
|
||||
|
||||
@ -194,38 +194,6 @@ textarea {
|
||||
}
|
||||
}
|
||||
|
||||
.pma-fieldset {
|
||||
margin-top: 1em;
|
||||
border-radius: 4px 4px 0 0;
|
||||
border: #aaa solid 1px;
|
||||
padding: 0.5em;
|
||||
background: #eee;
|
||||
text-shadow: 1px 1px 2px #fff inset;
|
||||
box-shadow: 1px 1px 2px #fff inset;
|
||||
}
|
||||
|
||||
.pma-fieldset {
|
||||
.pma-fieldset {
|
||||
margin: 0.8em;
|
||||
border: 1px solid #aaa;
|
||||
background: #e8e8e8;
|
||||
}
|
||||
|
||||
legend {
|
||||
float: none;
|
||||
font-weight: bold;
|
||||
color: #444;
|
||||
padding: 5px 10px;
|
||||
border-radius: 2px;
|
||||
border: 1px solid #aaa;
|
||||
background-color: #fff;
|
||||
max-width: 100%;
|
||||
box-shadow: 3px 3px 15px #bbb;
|
||||
width: initial;
|
||||
font-size: 1em;
|
||||
}
|
||||
}
|
||||
|
||||
// buttons in some browsers (eg. Konqueror) are block elements, this breaks design
|
||||
button {
|
||||
display: inline;
|
||||
@ -278,17 +246,6 @@ select {
|
||||
text-shadow: 0 1px 0 #000;
|
||||
}
|
||||
|
||||
.pma-fieldset.tblFooters {
|
||||
margin-top: 0;
|
||||
margin-bottom: 0.5em;
|
||||
// avoid a thick line since this should be used under another fieldset
|
||||
border-top: 0;
|
||||
text-align: right;
|
||||
float: none;
|
||||
clear: both;
|
||||
border-radius: 0 0 4px 4px;
|
||||
}
|
||||
|
||||
div.null_div {
|
||||
height: 20px;
|
||||
text-align: center;
|
||||
@ -309,20 +266,6 @@ div.null_div {
|
||||
}
|
||||
}
|
||||
|
||||
.pma-fieldset {
|
||||
.formelement {
|
||||
float: left;
|
||||
margin-right: 0.5em;
|
||||
// IE
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
// revert for Gecko
|
||||
div[class=formelement] {
|
||||
white-space: normal;
|
||||
}
|
||||
}
|
||||
|
||||
button.mult_submit {
|
||||
border: none;
|
||||
background-color: transparent;
|
||||
@ -428,11 +371,6 @@ img.lightbulb {
|
||||
padding: 0 0.5em;
|
||||
}
|
||||
|
||||
.confirmation {
|
||||
color: #000;
|
||||
background-color: pink;
|
||||
}
|
||||
|
||||
.error {
|
||||
border: 1px solid maroon !important;
|
||||
padding: 0.27em;
|
||||
@ -452,39 +390,6 @@ img.lightbulb {
|
||||
color: #009;
|
||||
}
|
||||
|
||||
.tblHeaders {
|
||||
font-weight: bold;
|
||||
color: $th-color;
|
||||
background: $th-background;
|
||||
}
|
||||
|
||||
.tblFooters {
|
||||
font-weight: normal;
|
||||
color: $th-color;
|
||||
background: $th-background;
|
||||
}
|
||||
|
||||
.tblHeaders a {
|
||||
&:link,
|
||||
&:active,
|
||||
&:visited {
|
||||
color: #00f;
|
||||
}
|
||||
}
|
||||
|
||||
.tblFooters a {
|
||||
&:link,
|
||||
&:active,
|
||||
&:visited {
|
||||
color: #00f;
|
||||
}
|
||||
}
|
||||
|
||||
.tblHeaders a:hover,
|
||||
.tblFooters a:hover {
|
||||
color: #f00;
|
||||
}
|
||||
|
||||
// disabled text
|
||||
.disabled {
|
||||
color: #666;
|
||||
@ -586,10 +491,6 @@ label.col-3.d-flex.align-items-center {
|
||||
color: gray;
|
||||
}
|
||||
|
||||
.max_height_400 {
|
||||
max-height: 400px;
|
||||
}
|
||||
|
||||
li.last.database {
|
||||
// Avoid having the last item of the tree hidden behind the scroll bar
|
||||
margin-bottom: 15px !important;
|
||||
@ -735,10 +636,6 @@ div#tablestatistics table {
|
||||
}
|
||||
}
|
||||
|
||||
#fieldset_user_global_rights .pma-fieldset {
|
||||
float: left;
|
||||
}
|
||||
|
||||
#fieldset_user_global_rights > legend input {
|
||||
margin-left: 2em;
|
||||
}
|
||||
@ -762,8 +659,7 @@ caption a.top {
|
||||
|
||||
div {
|
||||
&#serverstatus table {
|
||||
tbody td.descr a,
|
||||
.tblFooters a {
|
||||
tbody td.descr a {
|
||||
white-space: nowrap;
|
||||
}
|
||||
}
|
||||
@ -1502,22 +1398,6 @@ input#auto_increment_opt {
|
||||
}
|
||||
}
|
||||
|
||||
.doubleFieldset {
|
||||
.pma-fieldset {
|
||||
width: 48%;
|
||||
float: left;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
legend {
|
||||
margin-left: 1.5em;
|
||||
}
|
||||
|
||||
div.wrap {
|
||||
padding: 1.5em;
|
||||
}
|
||||
}
|
||||
|
||||
#table_name_col_no_outer {
|
||||
margin-top: 45px;
|
||||
}
|
||||
@ -1933,10 +1813,6 @@ body #ui-datepicker-div {
|
||||
z-index: 9999 !important;
|
||||
}
|
||||
|
||||
.ui-dialog .pma-fieldset legend a {
|
||||
color: #235a81;
|
||||
}
|
||||
|
||||
.ui-draggable {
|
||||
z-index: 801;
|
||||
}
|
||||
@ -2651,31 +2527,6 @@ body .ui-dialog {
|
||||
}
|
||||
// end of styles for jQuery-ui to support rtl languages
|
||||
|
||||
/* templates/database/multi_table_query */
|
||||
|
||||
.multi_table_query_form {
|
||||
.query-form__tr--hide {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.query-form__fieldset--inline,
|
||||
.query-form__select--inline {
|
||||
display: inline;
|
||||
}
|
||||
|
||||
.query-form__tr--bg-none {
|
||||
background: none;
|
||||
}
|
||||
|
||||
.query-form__input--wide {
|
||||
width: 91%;
|
||||
}
|
||||
|
||||
.query-form__multi-sql-query {
|
||||
float: left;
|
||||
}
|
||||
}
|
||||
|
||||
// templates/database/designer
|
||||
// side menu
|
||||
#name-panel {
|
||||
@ -2719,10 +2570,6 @@ body .ui-dialog {
|
||||
}
|
||||
}
|
||||
|
||||
.doubleFieldset .pma-fieldset {
|
||||
width: 98%;
|
||||
}
|
||||
|
||||
.ui-dialog {
|
||||
margin: 1%;
|
||||
width: 95% !important;
|
||||
@ -2775,14 +2622,6 @@ body .ui-dialog {
|
||||
overflow-y: scroll;
|
||||
}
|
||||
|
||||
// Extra large devices (large desktops, 1200px and up)
|
||||
@include media-breakpoint-up(xl) {
|
||||
.pma-fieldset.tblFooters,
|
||||
.tblFooters {
|
||||
text-align: left;
|
||||
}
|
||||
}
|
||||
|
||||
.resize-vertical {
|
||||
resize: vertical;
|
||||
}
|
||||
|
||||
@ -441,11 +441,6 @@ a {
|
||||
}
|
||||
}
|
||||
|
||||
#foreignkeychk {
|
||||
text-align: left;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.side-menu {
|
||||
float: left;
|
||||
position: fixed;
|
||||
|
||||
@ -148,7 +148,8 @@
|
||||
</table>
|
||||
</div>
|
||||
{% endif %}
|
||||
<fieldset class="pma-fieldset tblFooters">
|
||||
<div class="card mt-3">
|
||||
<div class="card-body">
|
||||
{% if action == '/table/add-field' or action == '/table/structure/save' %}
|
||||
<input type="checkbox" name="online_transaction" value="ONLINE_TRANSACTION_ENABLED" />{% trans %}Online transaction{% context %}Online transaction part of the SQL DDL for InnoDB{% endtrans %}{{ show_mysql_docu('innodb-online-ddl') }}
|
||||
{% endif %}
|
||||
@ -157,7 +158,8 @@
|
||||
<input class="btn btn-primary" type="submit"
|
||||
name="do_save_data"
|
||||
value="{% trans 'Save' %}">
|
||||
</fieldset>
|
||||
</div>
|
||||
</div>
|
||||
<div id="properties_message"></div>
|
||||
{% if is_integers_length_restricted %}
|
||||
<div class="alert alert-primary" id="length_not_allowed" role="alert">
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
<div class="responsivetable">
|
||||
<table id="table_columns" class="table table-striped caption-top align-middle mb-0 noclick">
|
||||
<caption class="tblHeaders">
|
||||
<caption>
|
||||
{% trans 'Structure' %}
|
||||
{{ show_mysql_docu('CREATE_TABLE') }}
|
||||
</caption>
|
||||
|
||||
@ -1,13 +1,11 @@
|
||||
<form action="{{ url('/database/designer') }}" method="post" name="edit_delete_pages" id="edit_delete_pages" class="ajax">
|
||||
{{ get_hidden_inputs(db) }}
|
||||
<fieldset class="pma-fieldset" id="page_edit_delete_options">
|
||||
<input type="hidden" name="operation" value="{{ operation }}">
|
||||
<label for="selected_page">
|
||||
{{ operation == 'editPage' ? 'Page to open'|trans : 'Page to delete'|trans }}:
|
||||
</label>
|
||||
{% include 'database/designer/page_selector.twig' with {
|
||||
'pdfwork': pdfwork,
|
||||
'pages': pages
|
||||
} only %}
|
||||
</fieldset>
|
||||
{{ get_hidden_inputs(db) }}
|
||||
<input type="hidden" name="operation" value="{{ operation }}">
|
||||
<label for="selected_page">
|
||||
{{ operation == 'editPage' ? 'Page to open'|trans : 'Page to delete'|trans }}:
|
||||
</label>
|
||||
{% include 'database/designer/page_selector.twig' with {
|
||||
'pdfwork': pdfwork,
|
||||
'pages': pages
|
||||
} only %}
|
||||
</form>
|
||||
|
||||
@ -1,36 +1,34 @@
|
||||
<form action="{{ url('/database/designer') }}" method="post" name="save_as_pages" id="save_as_pages" class="ajax">
|
||||
{{ get_hidden_inputs(db) }}
|
||||
<fieldset class="pma-fieldset" id="page_save_as_options">
|
||||
<table class="table table-borderless">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>
|
||||
<input type="hidden" name="operation" value="savePage">
|
||||
{% include 'database/designer/page_selector.twig' with {
|
||||
'pdfwork': pdfwork,
|
||||
'pages': pages
|
||||
} only %}
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<div>
|
||||
<input type="radio" name="save_page" id="savePageSameRadio" value="same" checked>
|
||||
<label for="savePageSameRadio">{% trans 'Save to selected page' %}</label>
|
||||
</div>
|
||||
<div>
|
||||
<input type="radio" name="save_page" id="savePageNewRadio" value="new">
|
||||
<label for="savePageNewRadio">{% trans 'Create a page and save to it' %}</label>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<label for="selected_value">{% trans 'New page name' %}</label>
|
||||
<input type="text" name="selected_value" id="selected_value">
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</fieldset>
|
||||
{{ get_hidden_inputs(db) }}
|
||||
<table class="table table-borderless">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>
|
||||
<input type="hidden" name="operation" value="savePage">
|
||||
{% include 'database/designer/page_selector.twig' with {
|
||||
'pdfwork': pdfwork,
|
||||
'pages': pages
|
||||
} only %}
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<div>
|
||||
<input type="radio" name="save_page" id="savePageSameRadio" value="same" checked>
|
||||
<label for="savePageSameRadio">{% trans 'Save to selected page' %}</label>
|
||||
</div>
|
||||
<div>
|
||||
<input type="radio" name="save_page" id="savePageNewRadio" value="new">
|
||||
<label for="savePageNewRadio">{% trans 'Create a page and save to it' %}</label>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<label for="selected_value">{% trans 'New page name' %}</label>
|
||||
<input type="text" name="selected_value" id="selected_value">
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</form>
|
||||
|
||||
@ -1,14 +1,17 @@
|
||||
<form method="post" action="{{ url('/schema-export') }}" class="disableAjax" id="id_export_pages">
|
||||
<fieldset class="pma-fieldset">
|
||||
{{ get_hidden_inputs(db) }}
|
||||
<label for="plugins">{% trans 'Select Export Relational Type' %}</label>
|
||||
<select id="plugins" name="export_type">
|
||||
{% for option in plugins_choice %}
|
||||
<option value="{{ option.name }}"{{ option.is_selected ? ' selected' }}>{{ option.text }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
{{ get_hidden_inputs(db) }}
|
||||
<input type="hidden" name="page_number" value="{{ page }}">
|
||||
|
||||
<input type="hidden" name="page_number" value="{{ page }}">
|
||||
{{ options|raw }}
|
||||
</fieldset>
|
||||
<div class="mb-3">
|
||||
<label class="form-label" for="plugins">{% trans 'Select export relational type:' %}</label>
|
||||
<select class="form-select" id="plugins" name="export_type">
|
||||
{% for option in plugins_choice %}
|
||||
<option value="{{ option.name }}"{{ option.is_selected ? ' selected' }}>{{ option.text }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
{{ options|raw }}
|
||||
</div>
|
||||
</form>
|
||||
|
||||
@ -4,162 +4,168 @@
|
||||
</button>
|
||||
</div>
|
||||
<div class="collapse show mb-3" id="queryWindow">
|
||||
|
||||
<form action="" id="multi_table_query_form" class="multi_table_query_form query_form">
|
||||
<form action="">
|
||||
<input type="hidden" id="db_name" value="{{ db }}">
|
||||
<fieldset class="pma-fieldset">
|
||||
|
||||
<div class="card">
|
||||
<div class="card-body">
|
||||
{% for table in tables %}
|
||||
<div class="d-none" id="{{ table.hash }}">
|
||||
<option value="*">*</option>
|
||||
{% for column in table.columns %}
|
||||
<option value="{{ column }}">{{ column }}</option>
|
||||
{% endfor %}
|
||||
</div>
|
||||
<div class="d-none" id="{{ table.hash }}">
|
||||
<option value="*">*</option>
|
||||
{% for column in table.columns %}
|
||||
<option value="{{ column }}">{{ column }}</option>
|
||||
{% endfor %}
|
||||
</div>
|
||||
{% endfor %}
|
||||
|
||||
{% for id in 0..default_no_of_columns %}
|
||||
{% if id == 0 %}<div class="d-none" id="new_column_layout">{% endif %}
|
||||
<fieldset class="pma-fieldset column_details query-form__fieldset--inline position-relative">
|
||||
<select class="tableNameSelect query-form__select--inline">
|
||||
<div class="row g-3 mb-3">
|
||||
{% for id in 0..default_no_of_columns %}
|
||||
<div class="col{{ id == 0 ? ' d-none' }}"{{ id == 0 ? ' id="new_column_layout"' }}>
|
||||
<div class="card">
|
||||
<fieldset class="card-body">
|
||||
<select class="tableNameSelect">
|
||||
<option value="">{% trans 'select table' %}</option>
|
||||
{% for keyTableName, table in tables %}
|
||||
<option data-hash="{{ table.hash }}" value="{{ keyTableName }}">{{ keyTableName }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
<span>.</span>
|
||||
<select class="columnNameSelect query-form__select--inline">
|
||||
</select>
|
||||
<span>.</span>
|
||||
<select class="columnNameSelect">
|
||||
<option value="">{% trans 'select column' %}</option>
|
||||
</select>
|
||||
<br>
|
||||
<input type="checkbox" checked="checked" class="show_col">
|
||||
<span>{% trans 'Show' %}</span>
|
||||
<br>
|
||||
<input type="text" placeholder="{% trans 'Table alias' %}" class="table_alias">
|
||||
<input type="text" placeholder="{% trans 'Column alias' %}" class="col_alias">
|
||||
<br>
|
||||
<input type="checkbox"
|
||||
title="{% trans 'Use this column in criteria' %}"
|
||||
class="criteria_col">
|
||||
</select>
|
||||
<br>
|
||||
<input type="checkbox" checked="checked" class="show_col">
|
||||
<span>{% trans 'Show' %}</span>
|
||||
<br>
|
||||
<input type="text" placeholder="{% trans 'Table alias' %}" class="table_alias">
|
||||
<input type="text" placeholder="{% trans 'Column alias' %}" class="col_alias">
|
||||
<br>
|
||||
<input type="checkbox"
|
||||
title="{% trans 'Use this column in criteria' %}"
|
||||
class="criteria_col">
|
||||
|
||||
<button class="btn btn-link p-0 jsCriteriaButton" type="button" data-bs-toggle="collapse" data-bs-target="#criteriaOptions{{ id }}" aria-expanded="false" aria-controls="criteriaOptions{{ id }}">
|
||||
{% trans 'criteria' %}
|
||||
</button>
|
||||
<div class="collapse jsCriteriaOptions" id="criteriaOptions{{ id }}">
|
||||
<button class="btn btn-link p-0 jsCriteriaButton" type="button" data-bs-toggle="collapse" data-bs-target="#criteriaOptions{{ id }}" aria-expanded="false" aria-controls="criteriaOptions{{ id }}">
|
||||
{% trans 'criteria' %}
|
||||
</button>
|
||||
<div class="collapse jsCriteriaOptions" id="criteriaOptions{{ id }}">
|
||||
|
||||
<div>
|
||||
<table class="table table-sm table-borderless align-middle w-auto">
|
||||
<div>
|
||||
<table class="table table-sm table-borderless align-middle w-auto">
|
||||
|
||||
<tr class="sort_order query-form__tr--bg-none">
|
||||
<td>{% trans 'Sort' %}</td>
|
||||
<td><input type="radio" name="sort[{{ id }}]">{% trans 'Ascending' %}</td>
|
||||
<td><input type="radio" name="sort[{{ id }}]">{% trans 'Descending' %}</td>
|
||||
<tr class="sort_order">
|
||||
<td>{% trans 'Sort' %}</td>
|
||||
<td><input type="radio" name="sort[{{ id }}]">{% trans 'Ascending' %}</td>
|
||||
<td><input type="radio" name="sort[{{ id }}]">{% trans 'Descending' %}</td>
|
||||
</tr>
|
||||
|
||||
<tr class="logical_operator query-form__tr--bg-none query-form__tr--hide">
|
||||
<td>{% trans 'Add as' %}</td>
|
||||
<td>
|
||||
<input type="radio"
|
||||
name="logical_op[{{ id }}]"
|
||||
value="AND"
|
||||
class="logical_op"
|
||||
checked="checked">
|
||||
AND
|
||||
</td>
|
||||
<td>
|
||||
<input type="radio"
|
||||
name="logical_op[{{ id }}]"
|
||||
value="OR"
|
||||
class="logical_op">
|
||||
OR
|
||||
</td>
|
||||
<tr class="logical_operator">
|
||||
<td>{% trans 'Add as' %}</td>
|
||||
<td>
|
||||
<input type="radio"
|
||||
name="logical_op[{{ id }}]"
|
||||
value="AND"
|
||||
class="logical_op"
|
||||
checked="checked">
|
||||
AND
|
||||
</td>
|
||||
<td>
|
||||
<input type="radio"
|
||||
name="logical_op[{{ id }}]"
|
||||
value="OR"
|
||||
class="logical_op">
|
||||
OR
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr class="query-form__tr--bg-none">
|
||||
<td>Op </td>
|
||||
<td>
|
||||
<select class="criteria_op">
|
||||
<option value="=">=</option>
|
||||
<option value=">">></option>
|
||||
<option value=">=">>=</option>
|
||||
<option value="<"><</option>
|
||||
<option value="<="><=</option>
|
||||
<option value="!=">!=</option>
|
||||
<option value="LIKE">LIKE</option>
|
||||
<option value="LIKE %...%">LIKE %...%</option>
|
||||
<option value="NOT LIKE">NOT LIKE</option>
|
||||
<option value="NOT LIKE %...%">NOT LIKE %...%</option>
|
||||
<option value="IN (...)">IN (...)</option>
|
||||
<option value="NOT IN (...)">NOT IN (...)</option>
|
||||
<option value="BETWEEN">BETWEEN</option>
|
||||
<option value="NOT BETWEEN">NOT BETWEEN</option>
|
||||
<option value="IS NULL">IS NULL</option>
|
||||
<option value="IS NOT NULL">IS NOT NULL</option>
|
||||
<option value="REGEXP">REGEXP</option>
|
||||
<option value="REGEXP ^...$">REGEXP ^...$</option>
|
||||
<option value="NOT REGEXP">NOT REGEXP</option>
|
||||
</select>
|
||||
</td>
|
||||
<td>
|
||||
<select class="criteria_rhs">
|
||||
<option value="text">{% trans 'Text' %}</option>
|
||||
<option value="anotherColumn">{% trans 'Another column' %}</option>
|
||||
</select>
|
||||
</td>
|
||||
<tr>
|
||||
<td>Op</td>
|
||||
<td>
|
||||
<select class="criteria_op">
|
||||
<option value="=">=</option>
|
||||
<option value=">">></option>
|
||||
<option value=">=">>=</option>
|
||||
<option value="<"><</option>
|
||||
<option value="<="><=</option>
|
||||
<option value="!=">!=</option>
|
||||
<option value="LIKE">LIKE</option>
|
||||
<option value="LIKE %...%">LIKE %...%</option>
|
||||
<option value="NOT LIKE">NOT LIKE</option>
|
||||
<option value="NOT LIKE %...%">NOT LIKE %...%</option>
|
||||
<option value="IN (...)">IN (...)</option>
|
||||
<option value="NOT IN (...)">NOT IN (...)</option>
|
||||
<option value="BETWEEN">BETWEEN</option>
|
||||
<option value="NOT BETWEEN">NOT BETWEEN</option>
|
||||
<option value="IS NULL">IS NULL</option>
|
||||
<option value="IS NOT NULL">IS NOT NULL</option>
|
||||
<option value="REGEXP">REGEXP</option>
|
||||
<option value="REGEXP ^...$">REGEXP ^...$</option>
|
||||
<option value="NOT REGEXP">NOT REGEXP</option>
|
||||
</select>
|
||||
</td>
|
||||
<td>
|
||||
<select class="criteria_rhs">
|
||||
<option value="text">{% trans 'Text' %}</option>
|
||||
<option value="anotherColumn">{% trans 'Another column' %}</option>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr class="rhs_table query-form__tr--hide query-form__tr--bg-none">
|
||||
<td></td>
|
||||
<td>
|
||||
<select class="tableNameSelect">
|
||||
<option value="">{% trans 'select table' %}</option>
|
||||
{% for keyTableName, table in tables %}
|
||||
<option data-hash="{{ table.hash }}" value="{{ keyTableName }}">{{ keyTableName }}</option>
|
||||
{% endfor %}
|
||||
</select><span>.</span>
|
||||
</td>
|
||||
<td>
|
||||
<select class="columnNameSelect query-form__select--inline">
|
||||
<option value="">{% trans 'select column' %}</option>
|
||||
</select>
|
||||
</td>
|
||||
<tr>
|
||||
<td></td>
|
||||
<td>
|
||||
<select class="tableNameSelect">
|
||||
<option value="">{% trans 'select table' %}</option>
|
||||
{% for keyTableName, table in tables %}
|
||||
<option data-hash="{{ table.hash }}" value="{{ keyTableName }}">{{ keyTableName }}</option>
|
||||
{% endfor %}
|
||||
</select><span>.</span>
|
||||
</td>
|
||||
<td>
|
||||
<select class="columnNameSelect">
|
||||
<option value="">{% trans 'select column' %}</option>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr class="rhs_text query-form__tr--bg-none">
|
||||
<td></td>
|
||||
<td colspan="2">
|
||||
<input type="text"
|
||||
class="rhs_text_val query-form__input--wide"
|
||||
placeholder="{% trans 'Enter criteria as free text' %}">
|
||||
</td>
|
||||
<tr class="rhs_text">
|
||||
<td></td>
|
||||
<td colspan="2">
|
||||
<input type="text"
|
||||
class="rhs_text_val"
|
||||
placeholder="{% trans 'Enter criteria as free text' %}">
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<button type="button" class="btn-close position-absolute top-0 end-0 jsRemoveColumn" aria-label="{% trans 'Remove this column' %}"></button>
|
||||
</fieldset>
|
||||
{% if id == 0 %}</div>{% endif %}
|
||||
{% endfor %}
|
||||
</div>
|
||||
<button type="button" class="btn-close position-absolute top-0 end-0 jsRemoveColumn" aria-label="{% trans 'Remove this column' %}"></button>
|
||||
</fieldset>
|
||||
</div>
|
||||
</div>
|
||||
{% endfor %}
|
||||
</div>
|
||||
|
||||
<fieldset class="pma-fieldset query-form__fieldset--inline">
|
||||
<input class="btn btn-secondary" type="button" value="{% trans '+ Add column' %}" id="add_column_button">
|
||||
</fieldset>
|
||||
<div class="mb-3">
|
||||
<input class="btn btn-secondary" type="button" value="{% trans '+ Add column' %}" id="add_column_button">
|
||||
</div>
|
||||
|
||||
<fieldset class="pma-fieldset">
|
||||
{# Keep the block without a space between the open and close tag #}
|
||||
<textarea id="MultiSqlquery"
|
||||
class="query-form__multi-sql-query"
|
||||
<div>
|
||||
{# Keep the block without a space between the open and close tag #}
|
||||
<textarea id="MultiSqlquery"
|
||||
class="form-control"
|
||||
cols="80"
|
||||
rows="4"
|
||||
name="sql_query"
|
||||
dir="ltr"></textarea>
|
||||
</fieldset>
|
||||
</fieldset>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<fieldset class="pma-fieldset tblFooters">
|
||||
<div class="card-footer">
|
||||
<input class="btn btn-secondary" type="button" id="update_query_button" value="{% trans 'Update query' %}">
|
||||
<input class="btn btn-primary" type="button" id="submit_query" value="{% trans 'Submit query' %}">
|
||||
</fieldset>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
<div id="sql_results"></div>
|
||||
|
||||
@ -9,7 +9,7 @@
|
||||
<div class="card-body">
|
||||
<table class="table w-auto rte_table{{ not ajax ? ' caption-top' }}">
|
||||
{% if not ajax %}
|
||||
<caption class="tblHeaders">{% trans 'Routine parameters' %}</caption>
|
||||
<caption>{% trans 'Routine parameters' %}</caption>
|
||||
{% endif %}
|
||||
<tr>
|
||||
<th>{% trans 'Name' %}</th>
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
<table class="table table-striped caption-top w-auto">
|
||||
<caption class="tblHeaders">
|
||||
<caption>
|
||||
{{- 'Search results for "<em>%s</em>" %s:'|format(
|
||||
criteria_search_string|e,
|
||||
search_type_description
|
||||
|
||||
@ -203,73 +203,82 @@
|
||||
<div class="collapse mb-3{{ default_sliders_state == 'open' ? ' show' }}" id="extraOptions">
|
||||
{% endif %}
|
||||
|
||||
<fieldset class="pma-fieldset">
|
||||
<div class="formelement">
|
||||
<div>
|
||||
<input type="radio" name="pftext" id="partialFulltextRadioP{{ unique_id }}" value="P"{{ headers.options.pftext == 'P' ? ' checked' }}>
|
||||
<label for="partialFulltextRadioP{{ unique_id }}">{% trans 'Partial texts' %}</label>
|
||||
</div>
|
||||
<div>
|
||||
<input type="radio" name="pftext" id="partialFulltextRadioF{{ unique_id }}" value="F"{{ headers.options.pftext == 'F' ? ' checked' }}>
|
||||
<label for="partialFulltextRadioF{{ unique_id }}">{% trans 'Full texts' %}</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="card">
|
||||
<div class="card-body">
|
||||
<div class="row">
|
||||
<fieldset class="col-auto">
|
||||
<div class="form-check">
|
||||
<input class="form-check-input" type="radio" name="pftext" id="partialFulltextRadioP{{ unique_id }}" value="P"{{ headers.options.pftext == 'P' ? ' checked' }}>
|
||||
<label class="form-check-label" for="partialFulltextRadioP{{ unique_id }}">{% trans 'Partial texts' %}</label>
|
||||
</div>
|
||||
<div class="form-check">
|
||||
<input class="form-check-input" type="radio" name="pftext" id="partialFulltextRadioF{{ unique_id }}" value="F"{{ headers.options.pftext == 'F' ? ' checked' }}>
|
||||
<label class="form-check-label" for="partialFulltextRadioF{{ unique_id }}">{% trans 'Full texts' %}</label>
|
||||
</div>
|
||||
</fieldset>
|
||||
|
||||
{% if relwork and displaywork %}
|
||||
<div class="formelement">
|
||||
<div>
|
||||
<input type="radio" name="relational_display" id="relationalDisplayRadioK{{ unique_id }}" value="K"{{ headers.options.relational_display == 'K' ? ' checked' }}>
|
||||
<label for="relationalDisplayRadioK{{ unique_id }}">{% trans 'Relational key' %}</label>
|
||||
{% if relwork and displaywork %}
|
||||
<fieldset class="col-auto">
|
||||
<div class="form-check">
|
||||
<input class="form-check-input" type="radio" name="relational_display" id="relationalDisplayRadioK{{ unique_id }}" value="K"{{ headers.options.relational_display == 'K' ? ' checked' }}>
|
||||
<label class="form-check-label" for="relationalDisplayRadioK{{ unique_id }}">{% trans 'Relational key' %}</label>
|
||||
</div>
|
||||
<div class="form-check">
|
||||
<input class="form-check-input" type="radio" name="relational_display" id="relationalDisplayRadioD{{ unique_id }}" value="D"{{ headers.options.relational_display == 'D' ? ' checked' }}>
|
||||
<label class="form-check-label" for="relationalDisplayRadioD{{ unique_id }}">{% trans 'Display column for relationships' %}</label>
|
||||
</div>
|
||||
</fieldset>
|
||||
{% endif %}
|
||||
|
||||
<fieldset class="col-auto">
|
||||
<div class="form-check">
|
||||
<input class="form-check-input" type="checkbox" name="display_binary" id="display_binary_{{ unique_id }}"
|
||||
{{- headers.options.display_binary is not empty ? ' checked' }}>
|
||||
<label class="form-check-label" for="display_binary_{{ unique_id }}">{% trans 'Show binary contents' %}</label>
|
||||
</div>
|
||||
|
||||
<div class="form-check">
|
||||
<input class="form-check-input" type="checkbox" name="display_blob" id="display_blob_{{ unique_id }}"
|
||||
{{- headers.options.display_blob is not empty ? ' checked' }}>
|
||||
<label class="form-check-label" for="display_blob_{{ unique_id }}">{% trans 'Show BLOB contents' %}</label>
|
||||
</div>
|
||||
</fieldset>
|
||||
|
||||
{# I would have preferred to name this "display_transformation".
|
||||
This is the only way I found to be able to keep this setting sticky
|
||||
per SQL query, and at the same time have a default that displays
|
||||
the transformations. #}
|
||||
<div class="col-auto">
|
||||
<div class="form-check">
|
||||
<input class="form-check-input" type="checkbox" name="hide_transformation" id="hide_transformation_{{ unique_id }}"
|
||||
{{- headers.options.hide_transformation is not empty ? ' checked' }}>
|
||||
<label class="form-check-label" for="hide_transformation_{{ unique_id }}">{% trans 'Hide browser transformation' %}</label>
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<input type="radio" name="relational_display" id="relationalDisplayRadioD{{ unique_id }}" value="D"{{ headers.options.relational_display == 'D' ? ' checked' }}>
|
||||
<label for="relationalDisplayRadioD{{ unique_id }}">{% trans 'Display column for relationships' %}</label>
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
<div class="formelement">
|
||||
<input type="checkbox" name="display_binary" id="display_binary_{{ unique_id }}"
|
||||
{{- headers.options.display_binary is not empty ? ' checked' }}>
|
||||
<label for="display_binary_{{ unique_id }}">{% trans 'Show binary contents' %}</label>
|
||||
|
||||
<input type="checkbox" name="display_blob" id="display_blob_{{ unique_id }}"
|
||||
{{- headers.options.display_blob is not empty ? ' checked' }}>
|
||||
<label for="display_blob_{{ unique_id }}">{% trans 'Show BLOB contents' %}</label>
|
||||
</div>
|
||||
|
||||
{# I would have preferred to name this "display_transformation".
|
||||
This is the only way I found to be able to keep this setting sticky
|
||||
per SQL query, and at the same time have a default that displays
|
||||
the transformations. #}
|
||||
<div class="formelement">
|
||||
<input type="checkbox" name="hide_transformation" id="hide_transformation_{{ unique_id }}"
|
||||
{{- headers.options.hide_transformation is not empty ? ' checked' }}>
|
||||
<label for="hide_transformation_{{ unique_id }}">{% trans 'Hide browser transformation' %}</label>
|
||||
</div>
|
||||
|
||||
<div class="formelement">
|
||||
{% if headers.options.possible_as_geometry %}
|
||||
<div>
|
||||
<input type="radio" name="geoOption" id="geoOptionRadioGeom{{ unique_id }}" value="GEOM"{{ headers.options.geo_option == 'GEOM' ? ' checked' }}>
|
||||
<label for="geoOptionRadioGeom{{ unique_id }}">{% trans 'Geometry' %}</label>
|
||||
</div>
|
||||
{% endif %}
|
||||
<div>
|
||||
<input type="radio" name="geoOption" id="geoOptionRadioWkt{{ unique_id }}" value="WKT"{{ headers.options.geo_option == 'WKT' ? ' checked' }}>
|
||||
<label for="geoOptionRadioWkt{{ unique_id }}">{% trans 'Well Known Text' %}</label>
|
||||
</div>
|
||||
<div>
|
||||
<input type="radio" name="geoOption" id="geoOptionRadioWkb{{ unique_id }}" value="WKB"{{ headers.options.geo_option == 'WKB' ? ' checked' }}>
|
||||
<label for="geoOptionRadioWkb{{ unique_id }}">{% trans 'Well Known Binary' %}</label>
|
||||
<fieldset class="col-auto">
|
||||
{% if headers.options.possible_as_geometry %}
|
||||
<div class="form-check">
|
||||
<input class="form-check-input" type="radio" name="geoOption" id="geoOptionRadioGeom{{ unique_id }}" value="GEOM"{{ headers.options.geo_option == 'GEOM' ? ' checked' }}>
|
||||
<label class="form-check-label" for="geoOptionRadioGeom{{ unique_id }}">{% trans 'Geometry' %}</label>
|
||||
</div>
|
||||
{% endif %}
|
||||
<div class="form-check">
|
||||
<input class="form-check-input" type="radio" name="geoOption" id="geoOptionRadioWkt{{ unique_id }}" value="WKT"{{ headers.options.geo_option == 'WKT' ? ' checked' }}>
|
||||
<label class="form-check-label" for="geoOptionRadioWkt{{ unique_id }}">{% trans 'Well Known Text' %}</label>
|
||||
</div>
|
||||
<div class="form-check">
|
||||
<input class="form-check-input" type="radio" name="geoOption" id="geoOptionRadioWkb{{ unique_id }}" value="WKB"{{ headers.options.geo_option == 'WKB' ? ' checked' }}>
|
||||
<label class="form-check-label" for="geoOptionRadioWkb{{ unique_id }}">{% trans 'Well Known Binary' %}</label>
|
||||
</div>
|
||||
</fieldset>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clearfloat"></div>
|
||||
</fieldset>
|
||||
|
||||
<fieldset class="pma-fieldset tblFooters">
|
||||
<input class="btn btn-primary" type="submit" value="{% trans 'Go' %}">
|
||||
</fieldset>
|
||||
<div class="card-footer">
|
||||
<input class="btn btn-primary" type="submit" value="{% trans 'Go' %}">
|
||||
</div>
|
||||
</div>
|
||||
{% if default_sliders_state != 'disabled' %}
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
@ -1,3 +1,3 @@
|
||||
<fieldset class="pma-fieldset tblFooters">
|
||||
<div class="card"><div class="card-body">
|
||||
[ <a href="{{ go_back_url }}">{% trans 'Back' %}</a> ]
|
||||
</fieldset>
|
||||
</div></div>
|
||||
|
||||
@ -1,9 +1,10 @@
|
||||
<fieldset class="pma-fieldset index_info">
|
||||
<legend id="index_header">
|
||||
<div class="card index_info">
|
||||
<div class="card-header" id="index_header">
|
||||
{% trans 'Indexes' %}
|
||||
{{ show_mysql_docu('optimizing-database-structure') }}
|
||||
</legend>
|
||||
</div>
|
||||
|
||||
<div class="card-body">
|
||||
{% if indexes is not empty %}
|
||||
{{ indexes_duplicates|raw }}
|
||||
|
||||
@ -91,4 +92,5 @@
|
||||
{% else %}
|
||||
<div class="no_indexes_defined">{{ 'No index defined!'|trans|notice }}</div>
|
||||
{% endif %}
|
||||
</fieldset>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -1,29 +1,27 @@
|
||||
<form class="ajax" action="{{ url('/navigation') }}" method="post">
|
||||
<fieldset class="pma-fieldset">
|
||||
{{ get_hidden_inputs(database) }}
|
||||
{{ get_hidden_inputs(database) }}
|
||||
|
||||
{% for type, label in types %}
|
||||
{% if hidden[type] is iterable %}
|
||||
{{ not loop.first ? '<br>' }}
|
||||
<strong>{{ label }}</strong>
|
||||
<table class="table w-100">
|
||||
<tbody>
|
||||
{% for item in hidden[type] %}
|
||||
<tr>
|
||||
<td>{{ item }}</td>
|
||||
<td class="text-end">
|
||||
<a class="unhideNavItem ajax" href="{{ url('/navigation') }}" data-post="{{ get_common({
|
||||
'unhideNavItem': true,
|
||||
'itemType': type,
|
||||
'itemName': item,
|
||||
'dbName': database
|
||||
}, '', false) }}">{{ get_icon('show', 'Unhide'|trans) }}</a>
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
</fieldset>
|
||||
{% for type, label in types %}
|
||||
{% if hidden[type] is iterable %}
|
||||
{{ not loop.first ? '<br>' }}
|
||||
<strong>{{ label }}</strong>
|
||||
<table class="table w-100">
|
||||
<tbody>
|
||||
{% for item in hidden[type] %}
|
||||
<tr>
|
||||
<td>{{ item }}</td>
|
||||
<td class="text-end">
|
||||
<a class="unhideNavItem ajax" href="{{ url('/navigation') }}" data-post="{{ get_common({
|
||||
'unhideNavItem': true,
|
||||
'itemType': type,
|
||||
'itemName': item,
|
||||
'dbName': database
|
||||
}, '', false) }}">{{ get_icon('show', 'Unhide'|trans) }}</a>
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
</form>
|
||||
|
||||
@ -3,13 +3,11 @@
|
||||
{% trans 'Binary log' %}
|
||||
</h2>
|
||||
|
||||
<form action="{{ url('/server/binlog') }}" method="post">
|
||||
<form action="{{ url('/server/binlog') }}" method="post" class="card">
|
||||
{{ get_hidden_inputs(url_params) }}
|
||||
<fieldset class="pma-fieldset">
|
||||
<legend>
|
||||
{% trans 'Select binary log to view' %}
|
||||
</legend>
|
||||
<div class="card-header">{% trans 'Select binary log to view' %}</div>
|
||||
|
||||
<div class="card-body">
|
||||
{% set full_size = 0 %}
|
||||
<select name="log">
|
||||
{% for each_log in binary_logs %}
|
||||
@ -28,11 +26,11 @@
|
||||
{% if full_size > 0 %}
|
||||
{{ format_byte_down(full_size)|join(' ') }}
|
||||
{% endif %}
|
||||
</fieldset>
|
||||
</div>
|
||||
|
||||
<fieldset class="pma-fieldset tblFooters">
|
||||
<div class="card-footer">
|
||||
<input class="btn btn-primary" type="submit" value="{% trans 'Go' %}">
|
||||
</fieldset>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
{{ sql_message|raw }}
|
||||
|
||||
@ -1,9 +1,8 @@
|
||||
<div class="row">
|
||||
<div class="col-12">
|
||||
<fieldset class="pma-fieldset" id="fieldset_add_user">
|
||||
<legend>{% trans %}New{% context %}Create new user{% endtrans %}</legend>
|
||||
<a id="add_user_anchor" href="{{ url('/server/privileges', url_params) }}">
|
||||
{{ get_icon('b_usradd') }}{% trans 'Add user account' %}</a>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div class="card">
|
||||
<div class="card-header">{% trans %}New{% context %}Create new user{% endtrans %}</div>
|
||||
<div class="card-body" id="fieldset_add_user">
|
||||
<a id="add_user_anchor" href="{{ url('/server/privileges', url_params) }}">
|
||||
{{- get_icon('b_usradd', 'Add user account'|trans) -}}
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -16,14 +16,12 @@
|
||||
{% if users_overview is not empty %}
|
||||
{{- users_overview|raw -}}
|
||||
{% elseif is_createuser %}
|
||||
<div class="row">
|
||||
<div class="col-12">
|
||||
<fieldset class="pma-fieldset" id="fieldset_add_user">
|
||||
<legend>{% trans %}New{% context %}Create new user{% endtrans %}</legend>
|
||||
<a id="add_user_anchor" href="{{ url('/server/privileges', {'adduser': true}) }}">
|
||||
{{- get_icon('b_usradd', 'Add user account'|trans) -}}
|
||||
</a>
|
||||
</fieldset>
|
||||
<div class="card">
|
||||
<div class="card-header">{% trans %}New{% context %}Create new user{% endtrans %}</div>
|
||||
<div class="card-body" id="fieldset_add_user">
|
||||
<a id="add_user_anchor" href="{{ url('/server/privileges', {'adduser': true}) }}">
|
||||
{{- get_icon('b_usradd', 'Add user account'|trans) -}}
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
@ -1,10 +1,13 @@
|
||||
<form method="post" action="{{ url('/server/replication') }}">
|
||||
<form method="post" action="{{ url('/server/replication') }}" class="card">
|
||||
{{ get_hidden_inputs('', '') }}
|
||||
<fieldset class="pma-fieldset" id="fieldset_add_user_login">
|
||||
<legend>
|
||||
{% trans 'Replica configuration' %} -
|
||||
{% trans 'Change or reconfigure primary server' %}
|
||||
</legend>
|
||||
<input type="hidden" name="sr_take_action" value="true">
|
||||
<input type="hidden" name="{{ submit_name }}" value="1">
|
||||
|
||||
<div class="card-header">
|
||||
{% trans 'Replica configuration - Change or reconfigure primary server' %}
|
||||
</div>
|
||||
|
||||
<div class="card-body" id="fieldset_add_user_login">
|
||||
<p>
|
||||
{% trans 'Make sure you have a unique server-id in your configuration file (my.cnf). If not, please add the following line into [mysqld] section:' %}
|
||||
</p>
|
||||
@ -26,10 +29,9 @@
|
||||
<label for="text_port">{% trans 'Port:' %}</label>
|
||||
<input id="text_port" name="text_port" type="number" maxlength="6" value="3306" required>
|
||||
</div>
|
||||
</fieldset>
|
||||
<fieldset id="fieldset_user_privtable_footer" class="pma-fieldset tblFooters">
|
||||
<input type="hidden" name="sr_take_action" value="true">
|
||||
<input type="hidden" name="{{ submit_name }}" value="1">
|
||||
</div>
|
||||
|
||||
<div class="card-footer">
|
||||
<input class="btn btn-primary" type="submit" id="confreplica_submit" value="{% trans 'Go' %}">
|
||||
</fieldset>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
@ -1,16 +1,16 @@
|
||||
<div id="primary_addreplicauser_gui">
|
||||
<form action="{{ url('/server/privileges') }}" method="post" autocomplete="off" id="addUsersForm">
|
||||
<form action="{{ url('/server/privileges') }}" method="post" autocomplete="off" id="addUsersForm" class="card">
|
||||
{{ get_hidden_inputs('', '') }}
|
||||
<input type="hidden" name="grant_count" value="25">
|
||||
<input type="hidden" name="createdb" id="createdb_0" value="0">
|
||||
{# Needed for the replication replicas. #}
|
||||
<input type="hidden" name="Repl_slave_priv" id="checkbox_Repl_slave_priv" value="Y">
|
||||
<input type="hidden" name="sr_take_action" value="true">
|
||||
<input type="hidden" name="adduser_submit" value="1">
|
||||
|
||||
<fieldset class="pma-fieldset" id="fieldset_add_user_login">
|
||||
<legend>{% trans 'Add replica replication user' %}</legend>
|
||||
|
||||
<input type="hidden" name="grant_count" value="25">
|
||||
<input type="hidden" name="createdb" id="createdb_0" value="0">
|
||||
{# Needed for the replication replicas. #}
|
||||
<input type="hidden" name="Repl_slave_priv" id="checkbox_Repl_slave_priv" value="Y">
|
||||
<input type="hidden" name="sr_take_action" value="true">
|
||||
<div class="card-header">{% trans 'Add replica replication user' %}</div>
|
||||
|
||||
<div class="card-body" id="fieldset_add_user_login">
|
||||
<div class="item">
|
||||
<label for="select_pred_username">
|
||||
{% trans 'User name:' %}
|
||||
@ -74,11 +74,10 @@
|
||||
</span>
|
||||
<input type="text" name="generated_pw" id="generated_pw">
|
||||
</div>
|
||||
</fieldset>
|
||||
</div>
|
||||
|
||||
<fieldset id="fieldset_user_privtable_footer" class="pma-fieldset tblFooters">
|
||||
<input type="hidden" name="adduser_submit" value="1">
|
||||
<div class="card-footer">
|
||||
<input class="btn btn-primary" type="submit" id="adduser_submit" value="{% trans 'Go' %}">
|
||||
</fieldset>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
@ -1,32 +1,35 @@
|
||||
<fieldset class="pma-fieldset">
|
||||
<legend>{% trans 'Primary configuration' %}</legend>
|
||||
<p>
|
||||
{% trans %}
|
||||
This server is not configured as a primary server in a replication process. You can choose from either replicating all databases and ignoring some of them (useful if you want to replicate a majority of the databases) or you can choose to ignore all databases by default and allow only certain databases to be replicated. Please select the mode:
|
||||
{% endtrans %}
|
||||
</p>
|
||||
<select name="db_type" id="db_type">
|
||||
<option value="all">{% trans 'Replicate all databases; Ignore:' %}</option>
|
||||
<option value="ign">{% trans 'Ignore all databases; Replicate:' %}</option>
|
||||
</select>
|
||||
<p>{% trans 'Please select databases:' %}</p>
|
||||
{{ database_multibox|raw }}
|
||||
<p>
|
||||
{% trans %}
|
||||
Now, add the following lines at the end of [mysqld] section in your my.cnf and please restart the MySQL server afterwards.
|
||||
{% endtrans %}
|
||||
</p>
|
||||
<pre id="rep"></pre>
|
||||
<p>
|
||||
{% trans %}
|
||||
Once you restarted MySQL server, please click on Go button. Afterwards, you should see a message informing you, that this server <strong>is</strong> configured as primary.
|
||||
{% endtrans %}
|
||||
</p>
|
||||
</fieldset>
|
||||
<div class="card">
|
||||
<div class="card-header">{% trans 'Primary configuration' %}</div>
|
||||
|
||||
<fieldset class="pma-fieldset tblFooters">
|
||||
<form method="post" action="{{ url('/server/replication') }}">
|
||||
{{ get_hidden_inputs('', '') }}
|
||||
<input id="goButton" class="btn btn-primary" type="submit" value="{% trans 'Go' %}">
|
||||
</form>
|
||||
</fieldset>
|
||||
<div class="card-body">
|
||||
<p>
|
||||
{% trans %}
|
||||
This server is not configured as a primary server in a replication process. You can choose from either replicating all databases and ignoring some of them (useful if you want to replicate a majority of the databases) or you can choose to ignore all databases by default and allow only certain databases to be replicated. Please select the mode:
|
||||
{% endtrans %}
|
||||
</p>
|
||||
<select name="db_type" id="db_type">
|
||||
<option value="all">{% trans 'Replicate all databases; Ignore:' %}</option>
|
||||
<option value="ign">{% trans 'Ignore all databases; Replicate:' %}</option>
|
||||
</select>
|
||||
<p>{% trans 'Please select databases:' %}</p>
|
||||
{{ database_multibox|raw }}
|
||||
<p>
|
||||
{% trans %}
|
||||
Now, add the following lines at the end of [mysqld] section in your my.cnf and please restart the MySQL server afterwards.
|
||||
{% endtrans %}
|
||||
</p>
|
||||
<pre id="rep"></pre>
|
||||
<p>
|
||||
{% trans %}
|
||||
Once you restarted MySQL server, please click on Go button. Afterwards, you should see a message informing you, that this server <strong>is</strong> configured as primary.
|
||||
{% endtrans %}
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div class="card-footer">
|
||||
<form method="post" action="{{ url('/server/replication') }}">
|
||||
{{ get_hidden_inputs('', '') }}
|
||||
<input id="goButton" class="btn btn-primary" type="submit" value="{% trans 'Go' %}">
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -1,8 +1,5 @@
|
||||
{% if not_only_options %}
|
||||
<form class="disableAjax" method="post" action="{{ form_action|raw }}">
|
||||
{% if omit_fieldset == false %}
|
||||
<fieldset class="pma-fieldset">
|
||||
{% endif %}
|
||||
{{ get_hidden_fields([]) }}
|
||||
<label for="select_server" class="form-label">{% trans 'Current server:' %}</label>
|
||||
<select id="select_server" class="form-select autosubmit" name="server">
|
||||
@ -11,9 +8,6 @@
|
||||
<option value="{{ server.value }}"{{ server.selected ? ' selected' }}>{{ server.label }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
{% if omit_fieldset == false %}
|
||||
</fieldset>
|
||||
{% endif %}
|
||||
</form>
|
||||
{% elseif servers.list %}
|
||||
{% trans 'Current server:' %}<br>
|
||||
|
||||
@ -30,9 +30,10 @@
|
||||
</div>
|
||||
{% endfor %}
|
||||
|
||||
<fieldset class="pma-fieldset simple">
|
||||
<legend>{% trans 'Servers' %}</legend>
|
||||
<div class="card mb-3">
|
||||
<div class="card-header">{% trans 'Servers' %}</div>
|
||||
|
||||
<div class="card-body">
|
||||
<form method="get" action="../setup/{{ url('/setup') }}" class="config-form disableAjax">
|
||||
<input type="hidden" name="tab_hash" value="">
|
||||
{% if has_check_page_refresh %}
|
||||
@ -92,11 +93,13 @@
|
||||
</div>
|
||||
|
||||
</form>
|
||||
</fieldset>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<fieldset class="pma-fieldset simple">
|
||||
<legend>{% trans 'Configuration file' %}</legend>
|
||||
<div class="card">
|
||||
<div class="card-header">{% trans 'Configuration file' %}</div>
|
||||
|
||||
<div class="card-body">
|
||||
<form method="post" action="../setup/{{ url('/setup/show-config') }}" class="config-form disableAjax">
|
||||
<input type="hidden" name="tab_hash" value="">
|
||||
{% if has_check_page_refresh %}
|
||||
@ -169,7 +172,8 @@
|
||||
</table>
|
||||
|
||||
</form>
|
||||
</fieldset>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="footer">
|
||||
<a href="../{{ url('/url', {'url': 'https://www.phpmyadmin.net/'}) }}">{% trans 'phpMyAdmin homepage' %}</a>
|
||||
|
||||
@ -5,17 +5,19 @@
|
||||
{{ profiling_chart|raw }}
|
||||
|
||||
{% if not is_procedure %}
|
||||
<fieldset class="pma-fieldset mb-3 d-print-none">
|
||||
<legend>{% trans 'Query results operations' %}</legend>
|
||||
<span>
|
||||
{{ link_or_button(
|
||||
url('/view/create'),
|
||||
{'db': db, 'table': table, 'printview': '1', 'sql_query': sql_query},
|
||||
get_icon('b_view_add', 'Create view'|trans, true),
|
||||
{'class': 'create_view ajax btn'}
|
||||
) }}
|
||||
</span>
|
||||
</fieldset>
|
||||
<div class="card mb-3 d-print-none">
|
||||
<div class="card-header">{% trans 'Query results operations' %}</div>
|
||||
<div class="card-body">
|
||||
<span>
|
||||
{{ link_or_button(
|
||||
url('/view/create'),
|
||||
{'db': db, 'table': table, 'printview': '1', 'sql_query': sql_query},
|
||||
get_icon('b_view_add', 'Create view'|trans, true),
|
||||
{'class': 'create_view ajax btn'}
|
||||
) }}
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
{{ bookmark|raw }}
|
||||
|
||||
@ -1,32 +1,34 @@
|
||||
<form action="{{ url('/table/delete/rows') }}" method="post">
|
||||
{{ get_hidden_inputs({
|
||||
'db': db,
|
||||
'table': table,
|
||||
'selected': selected,
|
||||
'original_sql_query': sql_query,
|
||||
'fk_checks': '0'
|
||||
}) }}
|
||||
<div class="container">
|
||||
<form action="{{ url('/table/delete/rows') }}" method="post" class="card">
|
||||
{{ get_hidden_inputs({
|
||||
'db': db,
|
||||
'table': table,
|
||||
'selected': selected,
|
||||
'original_sql_query': sql_query,
|
||||
'fk_checks': '0'
|
||||
}) }}
|
||||
|
||||
<fieldset class="pma-fieldset confirmation">
|
||||
<legend>
|
||||
<div class="card-header">
|
||||
{{ get_icon('s_really') }}
|
||||
{% trans 'Do you really want to execute the following query?' %}
|
||||
</legend>
|
||||
|
||||
<ul>
|
||||
{% for row in selected %}
|
||||
<li><code>DELETE FROM {{ backquote(table) }} WHERE {{ row }};</code></li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
</fieldset>
|
||||
|
||||
<fieldset class="pma-fieldset tblFooters">
|
||||
<div id="foreignkeychk" class="float-start">
|
||||
<input type="checkbox" name="fk_checks" id="fk_checks" value="1"{{ is_foreign_key_check ? ' checked' }}>
|
||||
<label for="fk_checks">{% trans 'Enable foreign key checks' %}</label>
|
||||
</div>
|
||||
<div class="float-end">
|
||||
<input id="buttonYes" class="btn btn-secondary" type="submit" name="mult_btn" value="{% trans 'Yes' %}">
|
||||
|
||||
<div class="card-body">
|
||||
<ul class="mb-3">
|
||||
{% for row in selected %}
|
||||
<li><code>DELETE FROM {{ backquote(table) }} WHERE {{ row }};</code></li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
|
||||
<div class="form-check">
|
||||
<input class="form-check-input" type="checkbox" name="fk_checks" id="checkForeignKeyCheckbox" value="1"{{ is_foreign_key_check ? ' checked' }}>
|
||||
<label class="form-check-label" for="checkForeignKeyCheckbox">{% trans 'Enable foreign key checks' %}</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="card-footer">
|
||||
<input id="buttonYes" class="btn btn-danger" type="submit" name="mult_btn" value="{% trans 'Yes' %}">
|
||||
<input id="buttonNo" class="btn btn-secondary" type="submit" name="mult_btn" value="{% trans 'No' %}">
|
||||
</div>
|
||||
</fieldset>
|
||||
</form>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
@ -2,14 +2,14 @@
|
||||
method="post"
|
||||
name="index_frm"
|
||||
id="index_frm"
|
||||
class="ajax">
|
||||
class="card ajax">
|
||||
|
||||
{{ get_hidden_inputs(form_params) }}
|
||||
{% if is_from_nav %}
|
||||
<input type="hidden" name="do_save_data" value="1">
|
||||
{% endif %}
|
||||
|
||||
<fieldset class="pma-fieldset" id="index_edit_fields">
|
||||
<div class="card-body">
|
||||
<div class="index_info">
|
||||
<div>
|
||||
<div class="label">
|
||||
@ -238,13 +238,13 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</fieldset>
|
||||
</div>
|
||||
{# The modal already has buttons to execute and preview SQL #}
|
||||
{%- if not create_edit_table -%}
|
||||
<fieldset class="pma-fieldset tblFooters">
|
||||
<div class="card-footer">
|
||||
<button class="btn btn-primary" type="submit">{% trans 'Go' %}</button>
|
||||
<button class="btn btn-secondary" type="submit" id="preview_index_frm">{% trans 'Preview SQL' %}</button>
|
||||
</fieldset>
|
||||
</div>
|
||||
{%- endif -%}
|
||||
</form>
|
||||
{% if is_from_nav %}
|
||||
|
||||
@ -1,8 +1,8 @@
|
||||
<form action="{{ url('/table/indexes/rename') }}" method="post" name="index_frm" id="index_frm" class="ajax">
|
||||
<form action="{{ url('/table/indexes/rename') }}" method="post" name="index_frm" id="index_frm" class="card ajax">
|
||||
|
||||
{{ get_hidden_inputs(form_params) }}
|
||||
|
||||
<fieldset class="pma-fieldset" id="index_edit_fields">
|
||||
<div class="card-body">
|
||||
<div class="index_info">
|
||||
<div>
|
||||
<div class="label">
|
||||
@ -23,8 +23,8 @@
|
||||
onfocus="this.select()">
|
||||
</div>
|
||||
</div>
|
||||
</fieldset>
|
||||
<fieldset class="pma-fieldset tblFooters">
|
||||
</div>
|
||||
<div class="card-footer">
|
||||
<button class="btn btn-secondary" type="submit" id="preview_index_frm">{% trans 'Preview SQL' %}</button>
|
||||
</fieldset>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
@ -11,7 +11,7 @@
|
||||
</thead>
|
||||
<tfoot>
|
||||
<tr>
|
||||
<th colspan="5" class="tblFooters text-end">
|
||||
<th colspan="5" class="text-end">
|
||||
<input class="btn btn-primary" type="submit" value="{% trans 'Go' %}">
|
||||
</th>
|
||||
</tr>
|
||||
|
||||
@ -1,26 +1,28 @@
|
||||
<form method="post" action="{{ url('/normalization/1nf/step1') }}" name="normalize" id="normalizeTable">
|
||||
<form method="post" action="{{ url('/normalization/1nf/step1') }}" name="normalize" id="normalizeTable" class="card">
|
||||
{{ get_hidden_inputs(db, table) }}
|
||||
|
||||
<fieldset class="pma-fieldset">
|
||||
<legend>{{ 'Improve table structure (Normalization):'|trans }}</legend>
|
||||
<div class="card-header">{{ 'Improve table structure (Normalization):'|trans }}</div>
|
||||
|
||||
<h3>{{ 'Select up to what step you want to normalize'|trans }}</h3>
|
||||
<div class="card-body">
|
||||
<h3 class="card-title">{{ 'Select up to what step you want to normalize'|trans }}</h3>
|
||||
|
||||
<div>
|
||||
<input type="radio" name="normalizeTo" id="normalizeToRadio1" value="1nf" checked>
|
||||
<label for="normalizeToRadio1">{{ 'First step of normalization (1NF)'|trans }}</label>
|
||||
{{ 'Hint: Please follow the procedure carefully in order to obtain correct normalization'|trans|notice }}
|
||||
|
||||
<div class="form-check">
|
||||
<input class="form-check-input" type="radio" name="normalizeTo" id="normalizeToRadio1" value="1nf" checked>
|
||||
<label class="form-check-label" for="normalizeToRadio1">{{ 'First step of normalization (1NF)'|trans }}</label>
|
||||
</div>
|
||||
<div>
|
||||
<input type="radio" name="normalizeTo" id="normalizeToRadio2" value="2nf">
|
||||
<label for="normalizeToRadio2">{{ 'Second step of normalization (1NF+2NF)'|trans }}</label>
|
||||
<div class="form-check">
|
||||
<input class="form-check-input" type="radio" name="normalizeTo" id="normalizeToRadio2" value="2nf">
|
||||
<label class="form-check-label" for="normalizeToRadio2">{{ 'Second step of normalization (1NF+2NF)'|trans }}</label>
|
||||
</div>
|
||||
<div>
|
||||
<input type="radio" name="normalizeTo" id="normalizeToRadio3" value="3nf">
|
||||
<label for="normalizeToRadio3">{{ 'Third step of normalization (1NF+2NF+3NF)'|trans }}</label>
|
||||
<div class="form-check">
|
||||
<input class="form-check-input" type="radio" name="normalizeTo" id="normalizeToRadio3" value="3nf">
|
||||
<label class="form-check-label" for="normalizeToRadio3">{{ 'Third step of normalization (1NF+2NF+3NF)'|trans }}</label>
|
||||
</div>
|
||||
</fieldset>
|
||||
<fieldset class="pma-fieldset tblFooters">
|
||||
<span class="float-start">{{ 'Hint: Please follow the procedure carefully in order to obtain correct normalization'|trans }}</span>
|
||||
</div>
|
||||
|
||||
<div class="card-footer">
|
||||
<input class="btn btn-primary" type="submit" name="submit_normalize" value="{{ 'Go'|trans }}">
|
||||
</fieldset>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
@ -1,194 +1,200 @@
|
||||
{% extends 'table/page_with_secondary_tabs.twig' %}
|
||||
|
||||
{% block content %}
|
||||
<form method="post" action="{{ url('/table/relation') }}">
|
||||
{{ get_hidden_inputs(db, table) }}
|
||||
{# InnoDB #}
|
||||
{% if is_foreign_key_supported %}
|
||||
<fieldset class="pma-fieldset mb-3">
|
||||
<legend>{% trans 'Foreign key constraints' %}</legend>
|
||||
<div class="table-responsive-md jsresponsive">
|
||||
<div class="container">
|
||||
<form method="post" action="{{ url('/table/relation') }}">
|
||||
{{ get_hidden_inputs(db, table) }}
|
||||
{# InnoDB #}
|
||||
{% if is_foreign_key_supported %}
|
||||
<div class="card mb-3">
|
||||
<div class="card-header">{% trans 'Foreign key constraints' %}</div>
|
||||
<div class="card-body">
|
||||
<div class="table-responsive-md jsresponsive">
|
||||
<table class="relationalTable table table-striped w-auto">
|
||||
<thead>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{% trans 'Actions' %}</th>
|
||||
<th>{% trans 'Constraint properties' %}</th>
|
||||
{% if tbl_storage_engine|upper == 'INNODB' %}
|
||||
<th>
|
||||
{% trans 'Column' %}
|
||||
{{ show_hint('Creating a foreign key over a non-indexed column would automatically create an index on it. Alternatively, you can define an index below, before creating the foreign key.'|trans) }}
|
||||
</th>
|
||||
{% else %}
|
||||
<th>
|
||||
{% trans 'Column' %}
|
||||
{{ show_hint('Only columns with index will be displayed. You can define an index below.'|trans) }}
|
||||
</th>
|
||||
{% endif %}
|
||||
<th colspan="3">
|
||||
{% trans 'Foreign key constraint' %}
|
||||
({{ tbl_storage_engine }})
|
||||
</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<th></th>
|
||||
<th></th>
|
||||
<th></th>
|
||||
<th>{% trans 'Database' %}</th>
|
||||
<th>{% trans 'Table' %}</th>
|
||||
<th>{% trans 'Column' %}</th>
|
||||
</tr></thead>
|
||||
{{ foreign_key_row|raw }}
|
||||
<tr>
|
||||
<th colspan="6">
|
||||
<a class="formelement clearfloat add_foreign_key" href="">
|
||||
{% trans '+ Add constraint' %}
|
||||
</a>
|
||||
</th>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</fieldset>
|
||||
{% endif %}
|
||||
|
||||
{% if relation_parameters.relationFeature is not null %}
|
||||
{% if default_sliders_state != 'disabled' and is_foreign_key_supported %}
|
||||
<div class="mb-3">
|
||||
<button class="btn btn-sm btn-secondary" type="button" data-bs-toggle="collapse" data-bs-target="#internalRelationships" aria-expanded="{{ default_sliders_state == 'open' ? 'true' : 'false' }}" aria-controls="internalRelationships">
|
||||
{% trans 'Internal relationships' %}
|
||||
</button>
|
||||
</div>
|
||||
<div class="collapse mb-3{{ default_sliders_state == 'open' ? ' show' }}" id="internalRelationships">
|
||||
{% endif %}
|
||||
|
||||
<fieldset class="pma-fieldset">
|
||||
<legend>
|
||||
{% trans 'Internal relationships' %}
|
||||
{{ show_docu('config', 'cfg_Servers_relation') }}
|
||||
</legend>
|
||||
<table class="relationalTable table table-striped table-hover table-sm w-auto">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{% trans 'Column' %}</th>
|
||||
<th>{% trans 'Actions' %}</th>
|
||||
<th>{% trans 'Constraint properties' %}</th>
|
||||
{% if tbl_storage_engine|upper == 'INNODB' %}
|
||||
<th>
|
||||
{% trans 'Internal relation' %}
|
||||
{% if is_foreign_key_supported %}
|
||||
{{ show_hint('An internal relation is not necessary when a corresponding FOREIGN KEY relation exists.'|trans) }}
|
||||
{% endif %}
|
||||
{% trans 'Column' %}
|
||||
{{ show_hint('Creating a foreign key over a non-indexed column would automatically create an index on it. Alternatively, you can define an index below, before creating the foreign key.'|trans) }}
|
||||
</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% set saved_row_cnt = save_row|length - 1 %}
|
||||
{% for i in 0..saved_row_cnt %}
|
||||
{% set myfield = save_row[i]['Field'] %}
|
||||
{# Use an md5 as array index to avoid having special characters
|
||||
in the name attribute (see bug #1746964 ) #}
|
||||
{% set myfield_md5 = column_hash_array[myfield] %}
|
||||
|
||||
{% set foreign_table = false %}
|
||||
{% set foreign_column = false %}
|
||||
|
||||
{# Database dropdown #}
|
||||
{% if existrel[myfield] is defined %}
|
||||
{% set foreign_db = existrel[myfield]['foreign_db'] %}
|
||||
{% else %}
|
||||
{% set foreign_db = db %}
|
||||
{% endif %}
|
||||
|
||||
{# Table dropdown #}
|
||||
{% set tables = [] %}
|
||||
{% if foreign_db %}
|
||||
{% if existrel[myfield] is defined %}
|
||||
{% set foreign_table = existrel[myfield]['foreign_table'] %}
|
||||
{% endif %}
|
||||
{% set tables = dbi.getTables(foreign_db) %}
|
||||
{% endif %}
|
||||
|
||||
{# Column dropdown #}
|
||||
{% set unique_columns = [] %}
|
||||
{% if foreign_db and foreign_table %}
|
||||
{% if existrel[myfield] is defined %}
|
||||
{% set foreign_column = existrel[myfield]['foreign_field'] %}
|
||||
{% endif %}
|
||||
{% set table_obj = table_get(foreign_table, foreign_db, dbi) %}
|
||||
{% set unique_columns = table_obj.getUniqueColumns(false, false) %}
|
||||
{% endif %}
|
||||
|
||||
<tr>
|
||||
<td class="align-middle">
|
||||
<strong>{{ myfield }}</strong>
|
||||
<input type="hidden" name="fields_name[{{ myfield_md5 }}]"
|
||||
value="{{ myfield }}">
|
||||
</td>
|
||||
|
||||
<td>
|
||||
{% include 'table/relation/relational_dropdown.twig' with {
|
||||
'name': 'destination_db[' ~ myfield_md5 ~ ']',
|
||||
'title': 'Database'|trans,
|
||||
'values': databases,
|
||||
'foreign': foreign_db
|
||||
} only %}
|
||||
|
||||
{% include 'table/relation/relational_dropdown.twig' with {
|
||||
'name': 'destination_table[' ~ myfield_md5 ~ ']',
|
||||
'title': 'Table'|trans,
|
||||
'values': tables,
|
||||
'foreign': foreign_table
|
||||
} only %}
|
||||
|
||||
{% include 'table/relation/relational_dropdown.twig' with {
|
||||
'name': 'destination_column[' ~ myfield_md5 ~ ']',
|
||||
'title': 'Column'|trans,
|
||||
'values': unique_columns,
|
||||
'foreign': foreign_column
|
||||
} only %}
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
{% else %}
|
||||
<th>
|
||||
{% trans 'Column' %}
|
||||
{{ show_hint('Only columns with index will be displayed. You can define an index below.'|trans) }}
|
||||
</th>
|
||||
{% endif %}
|
||||
<th colspan="3">
|
||||
{% trans 'Foreign key constraint' %}
|
||||
({{ tbl_storage_engine }})
|
||||
</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<th></th>
|
||||
<th></th>
|
||||
<th></th>
|
||||
<th>{% trans 'Database' %}</th>
|
||||
<th>{% trans 'Table' %}</th>
|
||||
<th>{% trans 'Column' %}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
{{ foreign_key_row|raw }}
|
||||
<tr>
|
||||
<th colspan="6">
|
||||
<a class="clearfloat add_foreign_key" href="">
|
||||
{% trans '+ Add constraint' %}
|
||||
</a>
|
||||
</th>
|
||||
</tr>
|
||||
</table>
|
||||
</fieldset>
|
||||
{% if default_sliders_state != 'disabled' and is_foreign_key_supported %}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
{% if relation_parameters.relationFeature is not null %}
|
||||
{% if default_sliders_state != 'disabled' and is_foreign_key_supported %}
|
||||
<div class="mb-3">
|
||||
<button class="btn btn-sm btn-secondary" type="button" data-bs-toggle="collapse" data-bs-target="#internalRelationships" aria-expanded="{{ default_sliders_state == 'open' ? 'true' : 'false' }}" aria-controls="internalRelationships">
|
||||
{% trans 'Internal relationships' %}
|
||||
</button>
|
||||
</div>
|
||||
<div class="collapse mb-3{{ default_sliders_state == 'open' ? ' show' }}" id="internalRelationships">
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
|
||||
{% if relation_parameters.displayFeature is not null %}
|
||||
<fieldset class="pma-fieldset">
|
||||
<label>{% trans 'Choose column to display:' %}</label>
|
||||
<select name="display_field">
|
||||
<option value="">---</option>
|
||||
{% for row in save_row %}
|
||||
<option value="{{ row['Field'] }}"
|
||||
{%- if display_field is defined and row['Field'] == display_field %}
|
||||
selected="selected"
|
||||
{%- endif %}>
|
||||
{{ row['Field'] }}
|
||||
</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</fieldset>
|
||||
{% endif %}
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
{% trans 'Internal relationships' %}
|
||||
{{ show_docu('config', 'cfg_Servers_relation') }}
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<table class="relationalTable table table-striped table-hover table-sm w-auto">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{% trans 'Column' %}</th>
|
||||
<th>
|
||||
{% trans 'Internal relation' %}
|
||||
{% if is_foreign_key_supported %}
|
||||
{{ show_hint('An internal relation is not necessary when a corresponding FOREIGN KEY relation exists.'|trans) }}
|
||||
{% endif %}
|
||||
</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% set saved_row_cnt = save_row|length - 1 %}
|
||||
{% for i in 0..saved_row_cnt %}
|
||||
{% set myfield = save_row[i]['Field'] %}
|
||||
{# Use an md5 as array index to avoid having special characters in the name attribute (see bug #1746964 ) #}
|
||||
{% set myfield_md5 = column_hash_array[myfield] %}
|
||||
|
||||
<fieldset class="pma-fieldset tblFooters">
|
||||
{% set foreign_table = false %}
|
||||
{% set foreign_column = false %}
|
||||
|
||||
{# Database dropdown #}
|
||||
{% if existrel[myfield] is defined %}
|
||||
{% set foreign_db = existrel[myfield]['foreign_db'] %}
|
||||
{% else %}
|
||||
{% set foreign_db = db %}
|
||||
{% endif %}
|
||||
|
||||
{# Table dropdown #}
|
||||
{% set tables = [] %}
|
||||
{% if foreign_db %}
|
||||
{% if existrel[myfield] is defined %}
|
||||
{% set foreign_table = existrel[myfield]['foreign_table'] %}
|
||||
{% endif %}
|
||||
{% set tables = dbi.getTables(foreign_db) %}
|
||||
{% endif %}
|
||||
|
||||
{# Column dropdown #}
|
||||
{% set unique_columns = [] %}
|
||||
{% if foreign_db and foreign_table %}
|
||||
{% if existrel[myfield] is defined %}
|
||||
{% set foreign_column = existrel[myfield]['foreign_field'] %}
|
||||
{% endif %}
|
||||
{% set table_obj = table_get(foreign_table, foreign_db, dbi) %}
|
||||
{% set unique_columns = table_obj.getUniqueColumns(false, false) %}
|
||||
{% endif %}
|
||||
|
||||
<tr>
|
||||
<td class="align-middle">
|
||||
<strong>{{ myfield }}</strong>
|
||||
<input type="hidden" name="fields_name[{{ myfield_md5 }}]"
|
||||
value="{{ myfield }}">
|
||||
</td>
|
||||
|
||||
<td>
|
||||
{% include 'table/relation/relational_dropdown.twig' with {
|
||||
'name': 'destination_db[' ~ myfield_md5 ~ ']',
|
||||
'title': 'Database'|trans,
|
||||
'values': databases,
|
||||
'foreign': foreign_db
|
||||
} only %}
|
||||
|
||||
{% include 'table/relation/relational_dropdown.twig' with {
|
||||
'name': 'destination_table[' ~ myfield_md5 ~ ']',
|
||||
'title': 'Table'|trans,
|
||||
'values': tables,
|
||||
'foreign': foreign_table
|
||||
} only %}
|
||||
|
||||
{% include 'table/relation/relational_dropdown.twig' with {
|
||||
'name': 'destination_column[' ~ myfield_md5 ~ ']',
|
||||
'title': 'Column'|trans,
|
||||
'values': unique_columns,
|
||||
'foreign': foreign_column
|
||||
} only %}
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
{% if default_sliders_state != 'disabled' and is_foreign_key_supported %}
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
|
||||
{% if relation_parameters.displayFeature is not null %}
|
||||
<div class="mb-3">
|
||||
<label class="form-label" for="displayFieldSelect">{% trans 'Choose column to display:' %}</label>
|
||||
<select class="form-select" name="display_field" id="displayFieldSelect">
|
||||
<option value="">---</option>
|
||||
{% for row in save_row %}
|
||||
<option value="{{ row['Field'] }}"
|
||||
{%- if display_field is defined and row['Field'] == display_field %}
|
||||
selected="selected"
|
||||
{%- endif %}>
|
||||
{{ row['Field'] }}
|
||||
</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
<div>
|
||||
<input class="btn btn-secondary preview_sql" type="button" value="{% trans 'Preview SQL' %}">
|
||||
<input class="btn btn-primary" type="submit" value="{% trans 'Save' %}">
|
||||
</fieldset>
|
||||
</form>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
<div class="modal fade" id="previewSqlModal" tabindex="-1" aria-labelledby="previewSqlModalLabel" aria-hidden="true">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<h5 class="modal-title" id="previewSqlModalLabel">{% trans 'Loading' %}</h5>
|
||||
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="{% trans 'Close' %}"></button>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-secondary" id="previewSQLCloseButton" data-bs-dismiss="modal">{% trans 'Close' %}</button>
|
||||
<div class="modal fade" id="previewSqlModal" tabindex="-1" aria-labelledby="previewSqlModalLabel" aria-hidden="true">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<h5 class="modal-title" id="previewSqlModalLabel">{% trans 'Loading' %}</h5>
|
||||
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="{% trans 'Close' %}"></button>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-secondary" id="previewSQLCloseButton" data-bs-dismiss="modal">{% trans 'Close' %}</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{% endblock %}
|
||||
|
||||
@ -27,7 +27,7 @@
|
||||
{% endif %}
|
||||
</td>
|
||||
<td>
|
||||
<span class="formelement clearfloat">
|
||||
<span class="clearfloat">
|
||||
<input type="text" name="constraint_name[{{ i }}]" value="
|
||||
{{- one_key['constraint'] is defined ? one_key['constraint'] -}}
|
||||
" placeholder="{% trans 'Constraint name' %}" maxlength="64">
|
||||
@ -40,7 +40,7 @@
|
||||
? one_key['on_delete'] : 'RESTRICT' %}
|
||||
{% set on_update = one_key['on_update'] is defined
|
||||
? one_key['on_update'] : 'RESTRICT' %}
|
||||
<span class="formelement">
|
||||
<span>
|
||||
{% include 'table/relation/dropdown_generate.twig' with {
|
||||
'dropdown_question': 'ON DELETE',
|
||||
'select_name': 'on_delete[' ~ i ~ ']',
|
||||
@ -48,7 +48,7 @@
|
||||
'selected_value': on_delete
|
||||
} only %}
|
||||
</span>
|
||||
<span class="formelement">
|
||||
<span>
|
||||
{% include 'table/relation/dropdown_generate.twig' with {
|
||||
'dropdown_question': 'ON UPDATE',
|
||||
'select_name': 'on_update[' ~ i ~ ']',
|
||||
@ -61,7 +61,7 @@
|
||||
<td>
|
||||
{% if one_key['index_list'] is defined %}
|
||||
{% for key, column in one_key['index_list'] %}
|
||||
<span class="formelement clearfloat">
|
||||
<span class="clearfloat">
|
||||
{% include 'table/relation/dropdown_generate.twig' with {
|
||||
'dropdown_question': '',
|
||||
'select_name': 'foreign_key_fields_name[' ~ i ~ '][]',
|
||||
@ -71,7 +71,7 @@
|
||||
</span>
|
||||
{% endfor %}
|
||||
{% else %}
|
||||
<span class="formelement clearfloat">
|
||||
<span class="clearfloat">
|
||||
{% include 'table/relation/dropdown_generate.twig' with {
|
||||
'dropdown_question': '',
|
||||
'select_name': 'foreign_key_fields_name[' ~ i ~ '][]',
|
||||
@ -80,13 +80,13 @@
|
||||
} only %}
|
||||
</span>
|
||||
{% endif %}
|
||||
<a class="formelement clearfloat add_foreign_key_field" data-index="
|
||||
<a class="clearfloat add_foreign_key_field" data-index="
|
||||
{{- i }}" href="">
|
||||
{% trans '+ Add column' %}
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<span class="formelement clearfloat">
|
||||
<span class="clearfloat">
|
||||
{% include 'table/relation/relational_dropdown.twig' with {
|
||||
'name': 'destination_foreign_db[' ~ i ~ ']',
|
||||
'title': 'Database'|trans,
|
||||
@ -97,7 +97,7 @@
|
||||
</span>
|
||||
</td>
|
||||
<td>
|
||||
<span class="formelement clearfloat">
|
||||
<span class="clearfloat">
|
||||
{% include 'table/relation/relational_dropdown.twig' with {
|
||||
'name': 'destination_foreign_table[' ~ i ~ ']',
|
||||
'title': 'Table'|trans,
|
||||
@ -109,7 +109,7 @@
|
||||
<td>
|
||||
{% if foreign_db and foreign_table %}
|
||||
{% for foreign_column in one_key['ref_index_list'] %}
|
||||
<span class="formelement clearfloat">
|
||||
<span class="clearfloat">
|
||||
{% include 'table/relation/relational_dropdown.twig' with {
|
||||
'name': 'destination_foreign_column[' ~ i ~ '][]',
|
||||
'title': 'Column'|trans,
|
||||
@ -119,7 +119,7 @@
|
||||
</span>
|
||||
{% endfor %}
|
||||
{% else %}
|
||||
<span class="formelement clearfloat">
|
||||
<span class="clearfloat">
|
||||
{% include 'table/relation/relational_dropdown.twig' with {
|
||||
'name': 'destination_foreign_column[' ~ i ~ '][]',
|
||||
'title': 'Column'|trans,
|
||||
|
||||
@ -1,120 +1,122 @@
|
||||
<!-- CREATE VIEW options -->
|
||||
<div id="div_view_options">
|
||||
<form method="post" action="{{ url('/view/create') }}">
|
||||
<form method="post" action="{{ url('/view/create') }}" class="card">
|
||||
{{ get_hidden_inputs(url_params) }}
|
||||
<fieldset class="pma-fieldset">
|
||||
<legend>
|
||||
{% if ajax_dialog %}
|
||||
{% trans 'Details' %}
|
||||
{% else %}
|
||||
{% if view['operation'] == 'create' %}
|
||||
{% trans 'Create view' %}
|
||||
{% else %}
|
||||
{% trans 'Edit view' %}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
</legend>
|
||||
<table class="table align-middle rte_table">
|
||||
{% if view['operation'] == 'create' %}
|
||||
<tr>
|
||||
<td class="text-nowrap"><label for="or_replace">OR REPLACE</label></td>
|
||||
<td>
|
||||
<input type="checkbox" name="view[or_replace]" id="or_replace"
|
||||
{% if (view['or_replace']) %} checked="checked" {% endif %}
|
||||
value="1">
|
||||
</td>
|
||||
</tr>
|
||||
{% endif %}
|
||||
<input type="hidden" name="ajax_request" value="1">
|
||||
<input type="hidden" name="{{ (view['operation'] == 'create') ? 'createview' : 'alterview' }}" value="1">
|
||||
<input type="hidden" name="ajax_dialog" value="1">
|
||||
|
||||
<tr>
|
||||
<td class="text-nowrap"><label for="algorithm">ALGORITHM</label></td>
|
||||
<td>
|
||||
<select name="view[algorithm]" id="algorithm">
|
||||
{% for option in view_algorithm_options %}
|
||||
<option value="{{ option }}"
|
||||
{% if view['algorithm'] == option %}
|
||||
selected="selected"
|
||||
{% endif %}
|
||||
>{{ option }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<div class="card-header">
|
||||
{% if ajax_dialog %}
|
||||
{% trans 'Details' %}
|
||||
{% else %}
|
||||
{% if view['operation'] == 'create' %}
|
||||
{% trans 'Create view' %}
|
||||
{% else %}
|
||||
{% trans 'Edit view' %}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
<tr>
|
||||
<td class="text-nowrap">{% trans 'Definer' %}</td>
|
||||
<td><input type="text" maxlength="100" size="50" name="view[definer]" value="{{ view['definer'] }}"></td>
|
||||
</tr>
|
||||
<div class="card-body">
|
||||
<table class="table align-middle rte_table">
|
||||
{% if view['operation'] == 'create' %}
|
||||
<tr>
|
||||
<td class="text-nowrap"><label for="or_replace">OR REPLACE</label></td>
|
||||
<td>
|
||||
<input type="checkbox" name="view[or_replace]" id="or_replace"
|
||||
{% if (view['or_replace']) %} checked="checked" {% endif %}
|
||||
value="1">
|
||||
</td>
|
||||
</tr>
|
||||
{% endif %}
|
||||
|
||||
<tr>
|
||||
<td class="text-nowrap">SQL SECURITY</td>
|
||||
<td>
|
||||
<select name="view[sql_security]">
|
||||
<option value=""></option>
|
||||
{% for option in view_security_options %}
|
||||
<option value="{{ option }}"
|
||||
{% if option == view['sql_security'] %} selected="selected" {% endif %}
|
||||
>{{ option }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="text-nowrap"><label for="algorithm">ALGORITHM</label></td>
|
||||
<td>
|
||||
<select name="view[algorithm]" id="algorithm">
|
||||
{% for option in view_algorithm_options %}
|
||||
<option value="{{ option }}"
|
||||
{% if view['algorithm'] == option %}
|
||||
selected="selected"
|
||||
{% endif %}
|
||||
>{{ option }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
{% if view['operation'] == 'create' %}
|
||||
<tr>
|
||||
<td class="text-nowrap">{% trans 'VIEW name' %}</td>
|
||||
<td>
|
||||
<input type="text" size="20" name="view[name]" onfocus="this.select()" maxlength="64" value="{{ view['name'] }}">
|
||||
</td>
|
||||
</tr>
|
||||
{% else %}
|
||||
<tr>
|
||||
<td>
|
||||
<input type="hidden" name="view[name]" value="{{ view['name'] }}">
|
||||
</td>
|
||||
</tr>
|
||||
{% endif %}
|
||||
<tr>
|
||||
<td class="text-nowrap">{% trans 'Definer' %}</td>
|
||||
<td><input type="text" maxlength="100" size="50" name="view[definer]" value="{{ view['definer'] }}"></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td class="text-nowrap">{% trans 'Column names' %}</td>
|
||||
<td>
|
||||
<input type="text" maxlength="100" size="50" name="view[column_names]" onfocus="this.select()" value="{{ view['column_names'] }}">
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="text-nowrap">SQL SECURITY</td>
|
||||
<td>
|
||||
<select name="view[sql_security]">
|
||||
<option value=""></option>
|
||||
{% for option in view_security_options %}
|
||||
<option value="{{ option }}"
|
||||
{% if option == view['sql_security'] %} selected="selected" {% endif %}
|
||||
>{{ option }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td class="text-nowrap">AS</td>
|
||||
<td>
|
||||
<textarea name="view[as]" id="view_as" rows="15" cols="40" dir="{{ text_dir }}">{{ view['as'] }}</textarea><br>
|
||||
<input type="button" value="Format" id="format" class="btn btn-secondary button sqlbutton">
|
||||
<span id="querymessage"></span>
|
||||
</td>
|
||||
</tr>
|
||||
{% if view['operation'] == 'create' %}
|
||||
<tr>
|
||||
<td class="text-nowrap">{% trans 'VIEW name' %}</td>
|
||||
<td>
|
||||
<input type="text" size="20" name="view[name]" onfocus="this.select()" maxlength="64" value="{{ view['name'] }}">
|
||||
</td>
|
||||
</tr>
|
||||
{% else %}
|
||||
<tr>
|
||||
<td>
|
||||
<input type="hidden" name="view[name]" value="{{ view['name'] }}">
|
||||
</td>
|
||||
</tr>
|
||||
{% endif %}
|
||||
|
||||
<tr>
|
||||
<td class="text-nowrap">WITH CHECK OPTION</td>
|
||||
<td>
|
||||
<select name="view[with]">
|
||||
<option value=""></option>
|
||||
{% for option in view_with_options %}
|
||||
<option value="{{ option }}"
|
||||
{% if option == view['with'] %} selected="selected" {% endif %}
|
||||
>{{ option }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="text-nowrap">{% trans 'Column names' %}</td>
|
||||
<td>
|
||||
<input type="text" maxlength="100" size="50" name="view[column_names]" onfocus="this.select()" value="{{ view['column_names'] }}">
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
</fieldset>
|
||||
<tr>
|
||||
<td class="text-nowrap">AS</td>
|
||||
<td>
|
||||
<textarea name="view[as]" id="view_as" rows="15" cols="40" dir="{{ text_dir }}">{{ view['as'] }}</textarea><br>
|
||||
<input type="button" value="Format" id="format" class="btn btn-secondary button sqlbutton">
|
||||
<span id="querymessage"></span>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<input type="hidden" name="ajax_request" value="1" />
|
||||
<input type="hidden" name="{{ (view['operation'] == 'create') ? 'createview' : 'alterview' }}" value="1" />
|
||||
<tr>
|
||||
<td class="text-nowrap">WITH CHECK OPTION</td>
|
||||
<td>
|
||||
<select name="view[with]">
|
||||
<option value=""></option>
|
||||
{% for option in view_with_options %}
|
||||
<option value="{{ option }}"
|
||||
{% if option == view['with'] %} selected="selected" {% endif %}
|
||||
>{{ option }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
</div>
|
||||
|
||||
{% if ajax_dialog == false %}
|
||||
<input type="hidden" name="ajax_dialog" value="1" />
|
||||
<input type="submit" class="btn btn-primary" name="" value="{% trans 'Go' %}" />
|
||||
<div class="card-footer">
|
||||
<input type="submit" class="btn btn-primary" name="" value="{% trans 'Go' %}">
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
</form>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
@ -57,7 +57,7 @@ class FirstStepControllerTest extends AbstractTestCase
|
||||
$output = $response->getHTMLResult();
|
||||
$this->assertStringContainsString('First step of normalization (1NF)', $output);
|
||||
$this->assertStringContainsString(
|
||||
'<div id=\'mainContent\' data-normalizeto=\'' . $expectedNormalizeTo . '\'>',
|
||||
'<div class="card" id="mainContent" data-normalizeto="' . $expectedNormalizeTo . '">',
|
||||
$output,
|
||||
);
|
||||
$this->assertStringContainsString('<option value=\'no_such_col\'>No such column</option>', $output);
|
||||
|
||||
@ -167,7 +167,7 @@ class DesignerTest extends AbstractTestCase
|
||||
|
||||
$result = $this->designer->getHtmlForSchemaExport($db, $page);
|
||||
// export type
|
||||
$this->assertStringContainsString('<select id="plugins" name="export_type">', $result);
|
||||
$this->assertStringContainsString('<select class="form-select" id="plugins" name="export_type">', $result);
|
||||
|
||||
// hidden field
|
||||
$this->assertStringContainsString('<input type="hidden" name="page_number" value="' . $page . '">', $result);
|
||||
|
||||
@ -149,13 +149,9 @@ class NormalizationTest extends AbstractTestCase
|
||||
$table = 'PMA_table';
|
||||
$normalizedTo = '1nf';
|
||||
$result = $this->normalization->getHtmlFor1NFStep1($db, $table, $normalizedTo);
|
||||
$this->assertStringContainsString(
|
||||
"<h3 class='text-center'>"
|
||||
. __('First step of normalization (1NF)') . '</h3>',
|
||||
$result,
|
||||
);
|
||||
$this->assertStringContainsString("<div id='mainContent'", $result);
|
||||
$this->assertStringContainsString('<legend>' . __('Step 1.'), $result);
|
||||
$this->assertStringContainsString('<h3>' . __('First step of normalization (1NF)') . '</h3>', $result);
|
||||
$this->assertStringContainsString('<div class="card" id="mainContent"', $result);
|
||||
$this->assertStringContainsString('<div class="card-header">' . __('Step 1.'), $result);
|
||||
|
||||
$this->assertStringContainsString('<h4', $result);
|
||||
|
||||
|
||||
@ -1527,7 +1527,7 @@ class PrivilegesTest extends AbstractTestCase
|
||||
$html,
|
||||
);
|
||||
$this->assertStringContainsString(
|
||||
Generator::getIcon('b_usradd'),
|
||||
Generator::getIcon('b_usradd', 'Add user account'),
|
||||
$html,
|
||||
);
|
||||
$this->assertStringContainsString(
|
||||
|
||||
@ -64,20 +64,16 @@ class SelectTest extends AbstractTestCase
|
||||
* Test for Select::render
|
||||
*/
|
||||
#[DataProvider('renderDataProvider')]
|
||||
public function testRender(bool $notOnlyOptions, bool $omitFieldset): void
|
||||
public function testRender(bool $notOnlyOptions): void
|
||||
{
|
||||
if ($notOnlyOptions) {
|
||||
$GLOBALS['cfg']['DisplayServersList'] = null;
|
||||
}
|
||||
|
||||
$html = Select::render($notOnlyOptions, $omitFieldset);
|
||||
$html = Select::render($notOnlyOptions);
|
||||
$server = $GLOBALS['cfg']['Servers']['0'];
|
||||
|
||||
if ($notOnlyOptions) {
|
||||
if (! $omitFieldset) {
|
||||
$this->assertStringContainsString('</fieldset>', $html);
|
||||
}
|
||||
|
||||
$this->assertStringContainsString(
|
||||
Util::getScriptNameForOption(
|
||||
$GLOBALS['cfg']['DefaultTabServer'],
|
||||
@ -107,9 +103,8 @@ class SelectTest extends AbstractTestCase
|
||||
public static function renderDataProvider(): array
|
||||
{
|
||||
return [
|
||||
'only options, don\'t omit fieldset' => [false, false],
|
||||
'not only options, omits fieldset' => [true, true],
|
||||
'not only options, don\'t omit fieldset' => [true, false],
|
||||
'only options' => [false],
|
||||
'not only options' => [true],
|
||||
];
|
||||
}
|
||||
}
|
||||
|
||||
@ -64,7 +64,7 @@ class ProceduresTest extends TestBase
|
||||
$this->waitForElement('id', 'extraOptionsButton')->click();
|
||||
$this->waitForElement('cssSelector', '#extraOptions.collapse.show');
|
||||
$this->waitForElement('xpath', '//label[contains(., "Full texts")]')->click();
|
||||
$this->waitForElement('cssSelector', '.collapse .tblFooters input[type=submit]')->click();
|
||||
$this->waitForElement('cssSelector', '.collapse .card-footer input[type=submit]')->click();
|
||||
$this->waitAjax();
|
||||
sleep(2);// Waitfor the new results
|
||||
$this->assertTrue($this->isElementPresent('className', 'table_results'));
|
||||
|
||||
@ -44,9 +44,6 @@ class NormalizationTest extends TestBase
|
||||
#[Group('large')]
|
||||
public function testNormalizationTo1NF(): void
|
||||
{
|
||||
$this->assertTrue(
|
||||
$this->isElementPresent('cssSelector', 'fieldset'),
|
||||
);
|
||||
$this->assertEquals(
|
||||
'First step of normalization (1NF)',
|
||||
$this->byCssSelector('label[for=normalizeToRadio1]')->getText(),
|
||||
@ -83,12 +80,6 @@ class NormalizationTest extends TestBase
|
||||
'#mainContent #newCols',
|
||||
),
|
||||
);
|
||||
$this->assertTrue(
|
||||
$this->isElementPresent(
|
||||
'cssSelector',
|
||||
'.tblFooters',
|
||||
),
|
||||
);
|
||||
$this->assertTrue(
|
||||
$this->isElementPresent(
|
||||
'cssSelector',
|
||||
@ -113,12 +104,12 @@ class NormalizationTest extends TestBase
|
||||
'no_such_col',
|
||||
);
|
||||
|
||||
$this->waitForElement('xpath', "//legend[contains(., 'Step 1.2 Have a primary key')]");
|
||||
$this->waitForElement('xpath', "//div[contains(., 'Step 1.2 Have a primary key')]");
|
||||
$text = $this->byCssSelector('#mainContent h4')->getText();
|
||||
$this->assertStringContainsString('Primary key already exists.', $text);
|
||||
$this->waitForElement('xpath', "//legend[contains(., 'Step 1.3 Move repeating groups')]");
|
||||
$this->waitForElement('xpath', "//div[contains(., 'Step 1.3 Move repeating groups')]");
|
||||
$this->byCssSelector('input[value="No repeating group"]')->click();
|
||||
$this->waitForElement('xpath', "//legend[contains(., 'Step 1.4 Remove redundant columns')]");
|
||||
$this->waitForElement('xpath', "//div[contains(., 'Step 1.4 Remove redundant columns')]");
|
||||
$this->assertTrue(
|
||||
$this->isElementPresent(
|
||||
'cssSelector',
|
||||
@ -139,7 +130,7 @@ class NormalizationTest extends TestBase
|
||||
);
|
||||
$this->byCssSelector('#extra input[value=val][type=checkbox]')->click();
|
||||
$this->byCssSelector('#removeRedundant')->click();
|
||||
$this->waitForElement('xpath', "//legend[contains(., 'End of step')]");
|
||||
$this->waitForElement('xpath', "//div[contains(., 'End of step')]");
|
||||
$this->assertStringContainsString(
|
||||
"The first step of normalization is complete for table 'test_table'.",
|
||||
$this->byCssSelector('#mainContent h4')->getText(),
|
||||
|
||||
@ -303,9 +303,8 @@ class BrowseTest extends TestBase
|
||||
$this->byId('id_rows_to_delete2_left')->click();
|
||||
|
||||
$this->byCssSelector('button[value=delete]')->click();
|
||||
$this->waitForElement('cssSelector', 'fieldset.confirmation');
|
||||
|
||||
$this->byId('buttonYes')->click();
|
||||
$this->waitForElement('id', 'buttonYes')->click();
|
||||
|
||||
$this->waitAjax();
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user