mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-06-01 22:47:19 +00:00
Merge branch 'seeddms-5.1.x' into seeddms-6.0.x
This commit is contained in:
commit
446f04c775
|
@ -75,6 +75,7 @@ $(document).ready( function() {
|
||||||
window.location.href = url;
|
window.location.href = url;
|
||||||
});
|
});
|
||||||
|
|
||||||
|
/*
|
||||||
$('#changeowner').on('click', function(e) {
|
$('#changeowner').on('click', function(e) {
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
var url = "";
|
var url = "";
|
||||||
|
@ -89,6 +90,70 @@ $(document).ready( function() {
|
||||||
url += '&'+$.param(values);
|
url += '&'+$.param(values);
|
||||||
window.location.href = url;
|
window.location.href = url;
|
||||||
});
|
});
|
||||||
|
*/
|
||||||
|
<?php if($this->getParam('theme') !== 'bootstrap4'): ?>
|
||||||
|
$('body').on('click', 'a.change-owner-btn', function(ev){
|
||||||
|
ev.preventDefault();
|
||||||
|
ev.stopPropagation();
|
||||||
|
confirmmsg = $(ev.currentTarget).attr('confirmmsg');
|
||||||
|
href = $(ev.currentTarget).attr('href');
|
||||||
|
bootbox.dialog(confirmmsg, [{
|
||||||
|
"label" : "<i class='fa fa-user'></i> <?= getMLText("batch_change_owner") ?>",
|
||||||
|
"class" : "btn-danger",
|
||||||
|
"callback": function() {
|
||||||
|
var url = "";
|
||||||
|
url = href+'&newowner='+($('#newowner').val());
|
||||||
|
var inputs = $('input[name^=\"marks\"]');
|
||||||
|
var values = {};
|
||||||
|
inputs.each(function() {
|
||||||
|
if(this.checked)
|
||||||
|
values[this.name] = 1;
|
||||||
|
});
|
||||||
|
url += '&'+$.param(values);
|
||||||
|
window.location.href = url;
|
||||||
|
}
|
||||||
|
}, {
|
||||||
|
"label" : "<?= getMLText("cancel") ?>",
|
||||||
|
"class" : "btn-cancel",
|
||||||
|
"callback": function() {
|
||||||
|
}
|
||||||
|
}]);
|
||||||
|
});
|
||||||
|
<?php else: ?>
|
||||||
|
$('body').on('click', 'a.change-owner-btn', function(ev){
|
||||||
|
ev.preventDefault();
|
||||||
|
ev.stopPropagation();
|
||||||
|
confirmmsg = $(ev.currentTarget).attr('confirmmsg');
|
||||||
|
href = $(ev.currentTarget).attr('href');
|
||||||
|
bootbox.confirm({
|
||||||
|
"message": confirmmsg,
|
||||||
|
"buttons": {
|
||||||
|
"confirm": {
|
||||||
|
"label" : "<i class='fa fa-user'></i> <?= getMLText("batch_change_owner") ?>",
|
||||||
|
"className" : "btn-danger",
|
||||||
|
},
|
||||||
|
"cancel": {
|
||||||
|
"label" : " <?= getMLText("cancel") ?>",
|
||||||
|
"className" : "btn-secondary",
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"callback": function(result) {
|
||||||
|
if(result) {
|
||||||
|
var url = "";
|
||||||
|
url = href+'&newowner='+($('#newowner').val());
|
||||||
|
var inputs = $('input[name^=\"marks\"]');
|
||||||
|
var values = {};
|
||||||
|
inputs.each(function() {
|
||||||
|
if(this.checked)
|
||||||
|
values[this.name] = 1;
|
||||||
|
});
|
||||||
|
url += '&'+$.param(values);
|
||||||
|
window.location.href = url;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
<?php endif; ?>
|
||||||
});
|
});
|
||||||
<?php
|
<?php
|
||||||
// $this->printFolderChooserJs("form1");
|
// $this->printFolderChooserJs("form1");
|
||||||
|
@ -857,9 +922,13 @@ function typeahead() { /* {{{ */
|
||||||
'class'=>'chzn-select',
|
'class'=>'chzn-select',
|
||||||
'options'=>$options,
|
'options'=>$options,
|
||||||
'placeholder'=>getMLText('select_users'),
|
'placeholder'=>getMLText('select_users'),
|
||||||
|
'attributes'=>array(array('style', 'width: 100%;'))
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
print $this->html_link('Search', array_merge($_GET, array('action'=>'changeowner')), array('class'=>'btn btn-primary', 'id'=>'changeowner'), "<i class=\"fa fa-user\"></i> ".getMLText("batch_change_owner"), false, true)."\n";
|
// print $this->html_link('Search', array_merge($_GET, array('action'=>'changeowner')), array('class'=>'btn btn-primary', 'id'=>'changeowner'), "<i class=\"fa fa-user\"></i> ".getMLText("batch_change_owner"), false, true)."\n";
|
||||||
|
|
||||||
|
print $this->html_link('Search', array_merge($_GET, array('action'=>'changeowner')), array('class'=>'btn btn-primary change-owner-btn mt-4', 'confirmmsg'=>htmlspecialchars(getMLText("confirm_change_owner", array ()), ENT_QUOTES)), "<i class=\"fa fa-user\"></i> ".getMLText("batch_change_owner"), false, true)."\n";
|
||||||
|
|
||||||
$content = ob_get_clean();
|
$content = ob_get_clean();
|
||||||
$this->printAccordion(getMLText('batch_change_owner'), $content);
|
$this->printAccordion(getMLText('batch_change_owner'), $content);
|
||||||
}
|
}
|
||||||
|
|
|
@ -62,7 +62,7 @@ function initMost() {
|
||||||
|
|
||||||
$(".chzn-select").select2({
|
$(".chzn-select").select2({
|
||||||
theme: "bootstrap4",
|
theme: "bootstrap4",
|
||||||
width: '100%',
|
width: 'resolve',
|
||||||
templateResult: chzn_template_func//,
|
templateResult: chzn_template_func//,
|
||||||
//templateSelection: chzn_template_func
|
//templateSelection: chzn_template_func
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue
Block a user