Merge branch 'seeddms-5.1.x' into seeddms-6.0.x

This commit is contained in:
Uwe Steinmann 2023-02-28 14:21:46 +01:00
commit 61b7620ab0
5 changed files with 20 additions and 2 deletions

View File

@ -122,3 +122,9 @@ application/csv
application/vnd.wordperfect
unoconv -d document -e PageRange=1 -f pdf --stdout -v '%f' | gs -dBATCH -dNOPAUSE -sDEVICE=pngalpha -dPDFFitPage -r72x72 -sOutputFile=- -dFirstPage=1 -dLastPage=1 -q - | convert -resize %wx png:- 'png:%o'
video/webm
video/mp4
This will take 12th frame of a video and converts into a png. It requires
ffmpeg to be installed.
convert -resize %wx '%f[12]' 'png:%o'

View File

@ -189,6 +189,10 @@ class UI extends UI_Default {
static function exitError($pagetitle, $error, $noexit=false, $plain=false) {
global $theme, $dms, $user, $settings;
$view = UI::factory($theme, 'ErrorDlg');
$request = $view->getParam('request');
if($request) {
$request->query->set('action', 'show');
}
$view->setParam('dms', $dms);
$view->setParam('user', $user);
$view->setParam('pagetitle', $pagetitle);

View File

@ -277,10 +277,10 @@ foreach($users as $user) {
$mail_params = array();
if($settings->_smtpServer) {
$mail_params['host'] = $settings->_smtpServer;
if($settings->smtpPort) {
if($settings->_smtpPort) {
$mail_params['port'] = $settings->_smtpPort;
}
if($settings->smtpUser) {
if($settings->_smtpUser) {
$mail_params['auth'] = true;
$mail_params['username'] = $settings->_smtpUser;
$mail_params['password'] = $settings->_smtpPassword;

View File

@ -1243,17 +1243,21 @@ background-image: linear-gradient(to bottom, #882222, #111111);;
} elseif(is_array($value)) {
switch($value['element']) {
case 'select':
$allowempty = empty($value['allow_empty']) ? false : $value['allow_empty'];
echo '<select'.
(!empty($value['id']) ? ' id="'.$value['id'].'"' : '').
(!empty($value['name']) ? ' name="'.$value['name'].'"' : '').
(!empty($value['class']) ? ' class="'.$value['class'].'"' : '').
(!empty($value['placeholder']) ? ' data-placeholder="'.$value['placeholder'].'"' : '').
($allowempty ? ' data-allow-clear="true"' : '').
(!empty($value['multiple']) ? ' multiple' : '');
if(!empty($value['attributes']) && is_array($value['attributes']))
foreach($value['attributes'] as $a)
echo ' '.$a[0].'="'.$a[1].'"';
echo ">";
if(isset($value['options']) && is_array($value['options'])) {
if($allowempty)
echo "<option value=\"\"></option>";
foreach($value['options'] as $val) {
if(is_string($val)) {
echo '<optgroup label="'.$val.'">';

View File

@ -1149,17 +1149,21 @@ background-image: linear-gradient(to bottom, #882222, #111111);;
} elseif(is_array($value)) {
switch($value['element']) {
case 'select':
$allowempty = empty($value['allow_empty']) ? false : $value['allow_empty'];
echo '<select'.
(!empty($value['id']) ? ' id="'.$value['id'].'"' : '').
(!empty($value['name']) ? ' name="'.$value['name'].'"' : '').
(empty($value['class']) ? ' class="form-control"' : ' class="form-control '.$value['class'].'"').
(!empty($value['placeholder']) ? ' data-placeholder="'.$value['placeholder'].'"' : '').
($allowempty ? ' data-allow-clear="true"' : '').
(!empty($value['multiple']) ? ' multiple' : '');
if(!empty($value['attributes']) && is_array($value['attributes']))
foreach($value['attributes'] as $a)
echo ' '.$a[0].'="'.$a[1].'"';
echo ">";
if(isset($value['options']) && is_array($value['options'])) {
if($allowempty)
echo "<option value=\"\"></option>";
foreach($value['options'] as $val) {
if(is_string($val)) {
echo '<optgroup label="'.$val.'">';