diff --git a/src/apps/diy.php b/src/apps/diy.php index 1e130860..3c4236bd 100755 --- a/src/apps/diy.php +++ b/src/apps/diy.php @@ -74,7 +74,7 @@ if ($action == 'post') { $goto = !empty($cfg_cmspath) ? $cfg_cmspath : '/'; $bkmsg = '发布成功,请等待管理员处理'; //提交后返回提交页面 - echo""; + ShowMsg('提交成功', '-1'); exit; } ShowMsg($bkmsg, $goto); diff --git a/src/static/web/js/diy.js b/src/static/web/js/diy.js index 56332efd..cdee70e5 100644 --- a/src/static/web/js/diy.js +++ b/src/static/web/js/diy.js @@ -35,4 +35,32 @@ function SelectImage(sform, stype) { }); }) } -} \ No newline at end of file +} +$(document).ready(function () { + $('.datepicker').daterangepicker({ + "singleDatePicker": true, + "autoApply": true, + "showDropdowns": true, + "linkedCalendars": false, + "timePicker": true, + "timePicker24Hour": true, + //"timePickerSeconds": true, + "showCustomRangeLabel": false, + ranges: { + '今日': [moment(), moment()], + '昨日': [moment().subtract(1, 'days'), moment().subtract(1, 'days')], + '本月': [moment().startOf('month'), moment().startOf('month')], + '上月': [moment().subtract(1, 'month').startOf('month'), moment().subtract(1, 'month').startOf('month')] + }, + "locale": { + format: 'YYYY-MM-DD HH:mm', + applyLabel: '确定', + cancelLabel: '取消', + daysOfWeek: ['日', '一', '二', '三', '四', '五', '六'], + monthNames: ['一月', '二月', '三月', '四月', '五月', '六月', '七月', '八月', '九月', '十月', '十一月', '十二月'], + firstDay: 1 + } + }, function (start) { + $(this).val(start.format("YYYY-MM-DD HH:mm")); + }); +}) \ No newline at end of file diff --git a/src/system/common.inc.php b/src/system/common.inc.php index f59a1788..71ee3b4c 100755 --- a/src/system/common.inc.php +++ b/src/system/common.inc.php @@ -7,7 +7,7 @@ * @link https://www.dedebiz.com */ //系统默认运行模式为安全模式,模板管理、标签管理、数据库管理、模块管理等功能已暂停,如果您需要这些功能,DEDEBIZ_SAFE_MODE后面值`TRUE`改为`FALSE`恢复使用 -define('DEDEBIZ_SAFE_MODE', FALSE); +define('DEDEBIZ_SAFE_MODE', TRUE); //生产环境使用`production`,如果采用`dev`模式,会有一些php的报错信息提示,用于开发调试 if (!defined('DEDE_ENVIRONMENT')) { define('DEDE_ENVIRONMENT', 'production'); diff --git a/src/system/customfields.func.php b/src/system/customfields.func.php index f1e450df..ab94fcf6 100755 --- a/src/system/customfields.func.php +++ b/src/system/customfields.func.php @@ -102,7 +102,7 @@ function GetFormItem($ctag, $admintype = 'admin') $innertext = ""; } else if ($fieldType == "datetime") { $nowtime = GetDateTimeMk(time()); - $innertext = ""; + $innertext = ""; } else if ($fieldType == 'img') { $fname = defined('DEDEADMIN')? 'form1' : 'addcontent'; $innertext = " "; diff --git a/src/theme/apps/post_diyform.htm b/src/theme/apps/post_diyform.htm index 32ada0ec..3296faf3 100644 --- a/src/theme/apps/post_diyform.htm +++ b/src/theme/apps/post_diyform.htm @@ -6,8 +6,11 @@