From 15d93075c3b21af552f8a27f09bbe722e07583ef Mon Sep 17 00:00:00 2001 From: conory Date: Mon, 21 Dec 2015 15:36:05 +0900 Subject: [PATCH 01/86] =?UTF-8?q?php7=20=EC=A7=80=EC=9B=90=ED=95=98?= =?UTF-8?q?=EC=A7=80=EC=95=8A=EB=8A=94=20e=EC=98=B5=EC=85=98=20=EB=8C=80?= =?UTF-8?q?=EC=B2=B4=20=EC=B6=94=EA=B0=80=EB=90=9C=20=EA=B0=80=EC=9E=85?= =?UTF-8?q?=ED=8F=BC=20=EB=82=98=EC=98=A4=EC=A7=80=EC=95=8A=EB=8A=94=20?= =?UTF-8?q?=EB=AC=B8=EC=A0=9C=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/member/member.admin.view.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/member/member.admin.view.php b/modules/member/member.admin.view.php index f6a59dadb..b25579b82 100644 --- a/modules/member/member.admin.view.php +++ b/modules/member/member.admin.view.php @@ -615,7 +615,7 @@ class memberAdminView extends member } $replace = array_merge($extentionReplace, $replace); - $inputTag = preg_replace('@%(\w+)%@e', '$replace[$1]', $template); + $inputTag = preg_replace_callback('@%(\w+)%@', function($n) { return $replace[$n[1]]; }, $template); if($extendForm->description) $inputTag .= '

'.$extendForm->description.'

'; From 3d4883ef798be971b72c8712ba872a6fcb3c0aaf Mon Sep 17 00:00:00 2001 From: conory Date: Mon, 21 Dec 2015 16:17:31 +0900 Subject: [PATCH 02/86] =?UTF-8?q?php7=EB=A5=BC=20=EC=9C=84=ED=95=9C=20phpm?= =?UTF-8?q?ailer=20=EC=88=98=EC=A0=95=20(=EC=B6=94=ED=9B=84=20phpmailer=20?= =?UTF-8?q?=EC=97=85=EB=8D=B0=EC=9D=B4=ED=8A=B8=EB=A5=BC=20=ED=95=98?= =?UTF-8?q?=EB=A9=B4=20=EC=A2=8B=EA=B2=A0=EC=9D=8C)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- libs/phpmailer/phpmailer.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libs/phpmailer/phpmailer.php b/libs/phpmailer/phpmailer.php index c36f7c9d8..9ac3ffde5 100644 --- a/libs/phpmailer/phpmailer.php +++ b/libs/phpmailer/phpmailer.php @@ -1724,10 +1724,10 @@ class PHPMailer { switch (strtolower($position)) { case 'phrase': - $encoded = preg_replace("/([^A-Za-z0-9!*+\/ -])/e", "'='.sprintf('%02X', ord('\\1'))", $encoded); + $encoded = preg_replace_callback('/([^A-Za-z0-9!*+\/ -])/', function($n) { return '='.sprintf('%02X', ord('\\1')); }, $encoded); break; case 'comment': - $encoded = preg_replace("/([\(\)\"])/e", "'='.sprintf('%02X', ord('\\1'))", $encoded); + $encoded = preg_replace_callback('/([\(\)\"])/', function($n) { return '='.sprintf('%02X', ord('\\1')); }, $encoded); case 'text': default: // Replace every high ascii, control =, ? and _ characters From dc4c22d64a5de39b677ae704e6e81177fdca91b0 Mon Sep 17 00:00:00 2001 From: conory Date: Fri, 18 Dec 2015 18:45:12 +0900 Subject: [PATCH 03/86] =?UTF-8?q?=EB=8B=A4=EC=8B=9C=20=EB=82=98=ED=83=80?= =?UTF-8?q?=EB=82=9C=20HTTP=5FRAW=5FPOST=5FDATA=20=20=EB=AC=B8=EC=A0=9C=20?= =?UTF-8?q?=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- classes/context/Context.class.php | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/classes/context/Context.class.php b/classes/context/Context.class.php index 01e46b7db..2ad94ef30 100644 --- a/classes/context/Context.class.php +++ b/classes/context/Context.class.php @@ -201,9 +201,12 @@ class Context function init() { // fix missing HTTP_RAW_POST_DATA in PHP 5.6 and above - if(!isset($GLOBALS['HTTP_RAW_POST_DATA']) && version_compare(PHP_VERSION, '5.6.0', '>=') === true) { + if(!isset($GLOBALS['HTTP_RAW_POST_DATA']) && version_compare(PHP_VERSION, '5.6.0', '>=') === TRUE) + { $GLOBALS['HTTP_RAW_POST_DATA'] = file_get_contents("php://input"); - if(!preg_match('/^[<\{\[]/', $GLOBALS['HTTP_RAW_POST_DATA'])) + + // If content is not XML JSON, unset + if(!preg_match('/^[\<\{\[]/', $GLOBALS['HTTP_RAW_POST_DATA']) && strpos($_SERVER['CONTENT_TYPE'], 'json') === FALSE && strpos($_SERVER['HTTP_CONTENT_TYPE'], 'json') === FALSE) { unset($GLOBALS['HTTP_RAW_POST_DATA']); } From d52ac010cd55333db82f17987bea76a0407d66f2 Mon Sep 17 00:00:00 2001 From: conory Date: Thu, 24 Dec 2015 11:15:54 +0900 Subject: [PATCH 04/86] Creating default object from empty value --- modules/editor/editor.admin.controller.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/modules/editor/editor.admin.controller.php b/modules/editor/editor.admin.controller.php index 659132bea..baf7750a3 100644 --- a/modules/editor/editor.admin.controller.php +++ b/modules/editor/editor.admin.controller.php @@ -144,7 +144,8 @@ class editorAdminController extends editor { $oModuleController = getController('module'); $configVars = Context::getRequestVars(); - + + $config = new stdClass; if($configVars->font_defined != 'Y') $config->font_defined = $configVars->font_defined = 'N'; else $config->font_defined = 'Y'; From 803c5943d0c906af5e6174b43962487f789fe221 Mon Sep 17 00:00:00 2001 From: bnu Date: Mon, 18 Jan 2016 11:11:31 +0900 Subject: [PATCH 05/86] =?UTF-8?q?forum=20chak=20=EC=A0=9C=EA=B1=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/addon/tpl/addon_list.html | 2 - modules/addon/tpl/setup_addon.html | 2 - modules/admin/tpl/_dashboard_default.html | 1 + modules/admin/tpl/_header.html | 2 - modules/admin/tpl/admin_setup.html | 2 - modules/admin/tpl/config_ftp.html | 2 - modules/admin/tpl/config_general.html | 1 - modules/admin/tpl/css/admin.css | 33 --------- modules/admin/tpl/img/chak_c.png | Bin 5176 -> 0 bytes modules/admin/tpl/js/admin.js | 64 ------------------ modules/autoinstall/tpl/index.html | 2 - modules/autoinstall/tpl/list.html | 18 +++++ modules/comment/tpl/comment_list.html | 2 - modules/comment/tpl/declared_list.html | 4 +- modules/document/tpl/declared_list.html | 4 +- modules/document/tpl/document_list.html | 2 - modules/editor/tpl/admin_index.html | 1 - modules/file/tpl/adminConfig.html | 2 - modules/file/tpl/file_list.html | 2 - modules/importer/tpl/index.html | 2 - modules/layout/tpl/installed_layout_list.html | 2 - .../layout/tpl/layout_all_instance_list.html | 2 - modules/layout/tpl/layout_edit.html | 2 - modules/layout/tpl/layout_instance_list.html | 2 - modules/layout/tpl/layout_modify.html | 2 - modules/member/tpl/default_config.html | 2 - modules/member/tpl/design_config.html | 2 - modules/member/tpl/group_list.html | 2 - modules/member/tpl/insert_member.html | 2 - modules/member/tpl/login_config.html | 2 - modules/member/tpl/member_list.html | 2 - modules/member/tpl/signup_config.html | 2 - modules/menu/tpl/sitemap.html | 5 -- modules/module/tpl/adminFileBox.html | 2 - modules/module/tpl/category_list.html | 2 - modules/module/tpl/category_update_form.html | 1 - modules/module/tpl/module_list.html | 4 +- modules/point/tpl/config.html | 4 +- modules/point/tpl/member_list.html | 2 - modules/point/tpl/module_config.html | 2 - modules/poll/tpl/poll_list.html | 2 - modules/rss/tpl/rss_admin_index.html | 2 - modules/spamfilter/tpl/footer.html | 1 - modules/trash/tpl/trash_list.html | 2 - modules/trash/tpl/trash_view.html | 1 - .../widget/tpl/downloaded_widget_list.html | 2 - modules/widget/tpl/widget_generate_code.html | 2 - 47 files changed, 23 insertions(+), 183 deletions(-) delete mode 100644 modules/admin/tpl/img/chak_c.png diff --git a/modules/addon/tpl/addon_list.html b/modules/addon/tpl/addon_list.html index 018fedb5e..7ce073955 100644 --- a/modules/addon/tpl/addon_list.html +++ b/modules/addon/tpl/addon_list.html @@ -61,5 +61,3 @@ - -
diff --git a/modules/addon/tpl/setup_addon.html b/modules/addon/tpl/setup_addon.html index 3922f27b2..399936fa6 100644 --- a/modules/addon/tpl/setup_addon.html +++ b/modules/addon/tpl/setup_addon.html @@ -120,5 +120,3 @@ }); })(jQuery); - -
diff --git a/modules/admin/tpl/_dashboard_default.html b/modules/admin/tpl/_dashboard_default.html index 32e4ae3e2..1028cc468 100644 --- a/modules/admin/tpl/_dashboard_default.html +++ b/modules/admin/tpl/_dashboard_default.html @@ -63,3 +63,4 @@

{$lang->more}

+ diff --git a/modules/admin/tpl/_header.html b/modules/admin/tpl/_header.html index ef2f95953..34b083724 100644 --- a/modules/admin/tpl/_header.html +++ b/modules/admin/tpl/_header.html @@ -1,7 +1,5 @@ - -

{$lang->skip_to_content}

diff --git a/modules/admin/tpl/admin_setup.html b/modules/admin/tpl/admin_setup.html index 758739f5c..a75dfc524 100644 --- a/modules/admin/tpl/admin_setup.html +++ b/modules/admin/tpl/admin_setup.html @@ -114,5 +114,3 @@ .adminMap .parent>.side{right:30px} .adminMap .placeholder{background:#000;border-radius:5px} - -
diff --git a/modules/admin/tpl/config_ftp.html b/modules/admin/tpl/config_ftp.html index 22e2c0a67..4208abd88 100644 --- a/modules/admin/tpl/config_ftp.html +++ b/modules/admin/tpl/config_ftp.html @@ -124,5 +124,3 @@ jQuery(function($){ }); }); - -
diff --git a/modules/admin/tpl/config_general.html b/modules/admin/tpl/config_general.html index 9ae57ce97..3ec964fd8 100644 --- a/modules/admin/tpl/config_general.html +++ b/modules/admin/tpl/config_general.html @@ -314,4 +314,3 @@ function doSubmitConfig() -
diff --git a/modules/admin/tpl/css/admin.css b/modules/admin/tpl/css/admin.css index 1de422984..674e20d79 100644 --- a/modules/admin/tpl/css/admin.css +++ b/modules/admin/tpl/css/admin.css @@ -908,9 +908,6 @@ margin-bottom: 10px; text-decoration: none; color: #666; } -.x>.header>.account>ul>li.forum-chak>a { - color: #FFF; -} .x>.header>.account>ul>li>a:hover, .x>.header>.account>ul>li>a:focus { text-decoration: underline; @@ -2390,33 +2387,3 @@ html[lang="mn"] .x .g11n.active>[disabled], height: 1px; overflow: hidden; } - - -.admin-forum-container { - clear: both; - margin: 10px 5px; - border: 0 solid #ddd; -} -.admin-forum-container.activated-forum { - margin-top: 30px; - padding: 15px; - background-color: #fbfbfb; - border-width: 3px 0; -} -.admin-forum-container .open-forum { - display: inline-block; - padding: 15px; - padding-left: 60px; - color: #0088cc; - font-size: 14px; - height: 20px; - line-height: 20px; - text-decoration: none; - background-image: url('../img/chak_c.png'); - background-repeat: no-repeat; - background-position: center left; -} -.admin-forum-container .open-forum:hover, -.admin-forum-container .open-forum:active { - text-decoration: underline; -} diff --git a/modules/admin/tpl/img/chak_c.png b/modules/admin/tpl/img/chak_c.png deleted file mode 100644 index c0ea44130ce82d62518e652917ad1c132ff6feb2..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 5176 zcmeHLdo+~m9{$EIm2}n3j$@(=rZIPOX-q^(8HLGZcQa;;ennTIY|m*0I*ieDl7)=Xu`W`@Fy3yvv@I zE{@~$e%1p3V4TxZ2RG=G0KKM+)`i}Y)8sYK2TbbbxClroGI|4jfwPvn(E(uNTmT5! z2>_kYP)Gv+$k71s)&~G6F#s@Kd@RG23Qdd=FZGrJz*qzI3kDoHHUoNi$76WOyy(sp zmPla5WQ%-3D}_J|MFRj;L4h6xpo|Gu2>3!NMPXyAiJ(Bw>S2^AToWSOU}Ne4!t#Y)t)RGBE{(3JMCc3c^{5BwQ4ROeUkySQHkE zgd&jAV4;kuKnkU1eI#Fb96%{c!V}AQA|YJO%k&k=Wj3a!YN3I@zIDoYoIxd_v_CB< zL6mw1g|R}ThJuOxL^6@oPb3~#0t>#1#cK#^~|s^HfumoESK;#o5E(HKt3n{ zg)%9G!wk7z$eaP-H!D>z#lwn0AUgeD!vumM<)pI3fzXEc8#tt(lo2cjQEs4AB$u$j z#evZB2VI0rqN?|wqMql=)kdxo@?wL;q^YY0?zGt68bh|WMq;fXjv?cQ z_#KJ81ccyP6eJ{u%)mkv7z&Q4&7u|g9S5}kJWj9{$1uwn4Ev5iLoJdpL?S-TPTlI@ zE5DXJ+}<7z<%Wlw)0r%uP~8VC`m)jnealCuQUII<(~Yt_xyvh!tuY%<0djYN|`HWH5~V4<>u-q2VU4owDGSdcZa|61_jHTnzeKR2$g z6u)hYnhrZ;8>K>tKod?sHk7}Y*$?o+%=)RJy91XeWbz$EEV=rg)!(z&f4gV(Nen^r zgOrv;-~E{_VnH&4*AEv=WvAFv7h4l|Q zp2qa%y*!`GKF?jUPvjE&q*XZ=8_)Ipn6hwblI6VWt6#RvcUy<*JZuhgdvx`wOZer} z=VN+0W~9yfwCePRjxRYmIr7Vx^Li&eQUceXtv}yX_U7zFT^Rn=VwXm}o<`m||VjCZ|6W3vl6sW}Y|e!p8bA1%3g>U@G%gVPQFh*)}EY0UDY)ROg_ zx^2GRGasyL$i_uHn+966oZ`CaI9z$Q=P4;9D?GO*B=Ud=6A`8x>G|yWb5ZR%*L+5@ zzRRyi_+_f|O@=zgfAUq1+zE#H5%jpmi}gjoV{iN8JH*es)2g$!)I`&z)$L_EnG6?& zQ`r4^(f7NFY!>T6mlt>nu1L8yg$_RPp6pYN~W$ z*Q{kls(J9`A2KH!&YX$xF!ZkVdcWgBR$gd>XT_RbXCw_*?%%(^SeB8L8c?(3jhs4p z^oiT2y0&L@W}&Znr3c@;ka-y=05}TfoL3VwV!WjZ9T}f@j?kT!wvlzNt*vdsr7J$i zYu{C*wpixX)zw{2oNGqH7k1}46K|dHvuZ3ZEtRhRo#B7x?AfD6CMN4;`l^Jf`DvmT z)ltrKpKpi9)P&ciw_hqDVK4!Nq9~I_{0N4jN*HnN`Q(GD2(J%^-Q%YhMHd#92216R zmSK<9C6mezUXQ-ky3;UihEZGouFoDPzBol0MNWeGPF2=kx_kkN1Q8Ji*IX|z{8OOZ zXO4IVGwimq>zMQz5u!NsqP{1!`0xRzoR-=3b972{-nTf9TdLYMGPyP_Ee&r+8ljBB zrYh5-JQt2FaC*42EKySGZ1JZJvgD859>Dv&moIM?y@^{8bOvXAqIC|>bC;JtY|nf+ zLZ-OTa&ckkp^Yq)+M89kJ4vniK){Lz8vrrzY&vPHs$)xg>+D0@dXL@}`idA^<{w@F z-Zf9&XU30CKKL^7Ncugm3S#{FB*cfrgBQAz8Y9ZAuG-+b-nFb@uRF5LIoLQD7us`R z(hlh?U53ls@LvDB=~$oF6Ah2dMHGnTRQ=E`Mp-7gBJ;SQOXD#w#=f|ZDaAKp{_4>S z-RT$5F|t8g>#UpLxRoc7eEKOP|F})#uWeycMtkt`sKTU*j^vjQle(Y8C)q2NsfF$j z17DBQaT=Z3HKCa5cQoMP{hT6`@}Wp{ne zoxoEg8@qFwtLNfXkp&E3PW|N-wwnn?m*GIcm5jKtmW6q%fa3)ZTGkMcKUA9CZXA^+ zhFi{`N{?JBD5^4ly!P%U>-Vq{T~}TfaIr_?GrpYN7J|6-RqIaAZYBH~P|@{{ynnFV)5-nto!TlW5zUE6*!T_$@N z-xBWbzP{*lJ1uT@)oIsGi+wh>W2pI?CxC5ffwZ)c>joE5E9Z{d^VT}pcH$I$@OJpy zQ3k;`SCm;;WKJiU*f*g+HLr9$PAQJYO;x z{mW*^K4hY<>zkXW%ns!ceJG*H5kDP@s<8<09Cat{BW=61zNj0SEqSi#9XZSd2-wa@1wPGlp9vV7r& zt_*2}Cl3>0Qkx|1H}%wW2H&)j8Oe^a+mt6c%A~6aoWmq?IjvH#T$W|xyqJbRos1a wyL6xOW@_fMXGNL2N7wxFGAyjOBA@O51eR-%J^%m! diff --git a/modules/admin/tpl/js/admin.js b/modules/admin/tpl/js/admin.js index 1f3a60d20..0eee8ae5b 100644 --- a/modules/admin/tpl/js/admin.js +++ b/modules/admin/tpl/js/admin.js @@ -2471,67 +2471,3 @@ jQuery(function($){ } }); }); - - - -// Forum Chak -(function($){ - var chak = { - elClass: 'chak-comment', - group_id: 'xe1_official', - apikey: 'xe17935b49af5435d37f1cde130363db-forum' - }; - - $(function(){ - var $chakContainer = $('.admin-forum-container'); - - if($chakContainer.length) { - var $forumOpen = $('이 페이지에 대한 포럼 보기'); - var $headerButton = $('
  • Forum
  • '); - var $headerMenu = $('header.header .account ul'); - - (function(){var s=document.createElement('script');s.type='text/javascript';s.src='//chak.it/static/service.js';s.async=true;(document.getElementsByTagName('head')[0]||document.getElementsByTagName('body')[0]).appendChild(s);})(); - - $chakContainer.each(function(idx){ - var $el = $(this); - var elData = $el.data(); - elData.count = 0; - var $opener = $forumOpen.clone(); - var $button = $headerButton.clone(); - var forumId = 'inline-forum-' + idx; - - $el.append($opener); - - $button.find('a') - .attr('href', '#' + forumId) - .on('click', function(){ - var $target = $($.attr(this, 'href')); - $('html, body').animate({ - scrollTop: $target.offset().top - 20 - }, 500); - return false; - }) - .one('click', function() { - var $target = $($.attr(this, 'href')); - $target.find('a').click(); - }); - - $headerMenu.append($button); - $el.attr('id', forumId); - - $el.find('a').on('click', function(){ - var div = document.createElement("div"); - div.setAttribute("data-chak-apikey", chak.apikey); - div.setAttribute("data-chak-categories", elData.chakCategories); - - $opener.after(div); - $chakContainer.addClass('activated-forum'); - - manuallySetChakService(div); - - $opener.remove(); - }); - }); - } - }); -})(jQuery); diff --git a/modules/autoinstall/tpl/index.html b/modules/autoinstall/tpl/index.html index f40c74b3d..cb29354da 100644 --- a/modules/autoinstall/tpl/index.html +++ b/modules/autoinstall/tpl/index.html @@ -25,5 +25,3 @@ --> - -
    diff --git a/modules/autoinstall/tpl/list.html b/modules/autoinstall/tpl/list.html index b34fc9423..3004245cd 100644 --- a/modules/autoinstall/tpl/list.html +++ b/modules/autoinstall/tpl/list.html @@ -45,6 +45,16 @@

    {$item->category} {$item->title}

    +

    + + package_voted/$item->package_voter*20)}%">{sprintf("%0.1f",$item->package_voted/$item->package_voter*2)}{sprintf($lang->rate, $item->package_start)} + {sprintf("%0.1f",$item->package_voted/$item->package_voter*2)}/{number_format($item->package_voter)} + + + 0 + 0/0 + +

    {$lang->installed} {$lang->install} @@ -90,6 +100,14 @@

    {$item->category} {$item->title}

    {cut_str($item->package_description,200)}

    + + package_voted/$item->package_voter*20)}%">{sprintf("%0.1f",$item->package_voted/$item->package_voter*2)}{sprintf($lang->rate, $item->package_start)} + {sprintf("%0.1f",$item->package_voted/$item->package_voter*2)}/{number_format($item->package_voter)} + + + 0 + 0/0 + {$lang->package_update}: | {$lang->package_downloaded_count}: {number_format($item->package_downloaded)} diff --git a/modules/comment/tpl/comment_list.html b/modules/comment/tpl/comment_list.html index 7104adeb5..40f8be128 100644 --- a/modules/comment/tpl/comment_list.html +++ b/modules/comment/tpl/comment_list.html @@ -199,5 +199,3 @@ jQuery(function($){ }); }); - -

    diff --git a/modules/comment/tpl/declared_list.html b/modules/comment/tpl/declared_list.html index 9c627d151..34aa58508 100644 --- a/modules/comment/tpl/declared_list.html +++ b/modules/comment/tpl/declared_list.html @@ -115,6 +115,4 @@ jQuery(function($){ } }).change(); }); - - -
    + \ No newline at end of file diff --git a/modules/document/tpl/declared_list.html b/modules/document/tpl/declared_list.html index 0019b45f5..b9e94aeb6 100644 --- a/modules/document/tpl/declared_list.html +++ b/modules/document/tpl/declared_list.html @@ -200,6 +200,4 @@ jQuery(function($){ } }); }); - - -
    + \ No newline at end of file diff --git a/modules/document/tpl/document_list.html b/modules/document/tpl/document_list.html index ea13dc025..d9eca400e 100644 --- a/modules/document/tpl/document_list.html +++ b/modules/document/tpl/document_list.html @@ -216,5 +216,3 @@ jQuery(function($){ }); }); - -
    diff --git a/modules/editor/tpl/admin_index.html b/modules/editor/tpl/admin_index.html index 2cf340627..00d055ab5 100644 --- a/modules/editor/tpl/admin_index.html +++ b/modules/editor/tpl/admin_index.html @@ -213,4 +213,3 @@ jQuery(function($){ }); -
    diff --git a/modules/file/tpl/adminConfig.html b/modules/file/tpl/adminConfig.html index 6ae5cb121..1d4bd8782 100644 --- a/modules/file/tpl/adminConfig.html +++ b/modules/file/tpl/adminConfig.html @@ -56,5 +56,3 @@
    - -
    diff --git a/modules/file/tpl/file_list.html b/modules/file/tpl/file_list.html index 1f00e2e6e..a11f42b82 100644 --- a/modules/file/tpl/file_list.html +++ b/modules/file/tpl/file_list.html @@ -207,5 +207,3 @@ jQuery(function($){ }); }); - -
    diff --git a/modules/importer/tpl/index.html b/modules/importer/tpl/index.html index ab917cb21..cac85a045 100644 --- a/modules/importer/tpl/index.html +++ b/modules/importer/tpl/index.html @@ -105,5 +105,3 @@ jQuery('a.modalAnchor') return false; }); - -
    diff --git a/modules/layout/tpl/installed_layout_list.html b/modules/layout/tpl/installed_layout_list.html index efbb71cd4..2916eb953 100644 --- a/modules/layout/tpl/installed_layout_list.html +++ b/modules/layout/tpl/installed_layout_list.html @@ -52,5 +52,3 @@ - -
    diff --git a/modules/layout/tpl/layout_all_instance_list.html b/modules/layout/tpl/layout_all_instance_list.html index a6782fc14..bcc8394e3 100644 --- a/modules/layout/tpl/layout_all_instance_list.html +++ b/modules/layout/tpl/layout_all_instance_list.html @@ -43,5 +43,3 @@ - -
    diff --git a/modules/layout/tpl/layout_edit.html b/modules/layout/tpl/layout_edit.html index c180bf573..86a0f5690 100644 --- a/modules/layout/tpl/layout_edit.html +++ b/modules/layout/tpl/layout_edit.html @@ -94,5 +94,3 @@ - -
    diff --git a/modules/layout/tpl/layout_instance_list.html b/modules/layout/tpl/layout_instance_list.html index b67cbdc8d..702ea4fca 100644 --- a/modules/layout/tpl/layout_instance_list.html +++ b/modules/layout/tpl/layout_instance_list.html @@ -105,5 +105,3 @@ xe.lang.confirm_delete = '{$lang->confirm_delete}'; - -
    diff --git a/modules/layout/tpl/layout_modify.html b/modules/layout/tpl/layout_modify.html index 71b925a05..279f8196a 100644 --- a/modules/layout/tpl/layout_modify.html +++ b/modules/layout/tpl/layout_modify.html @@ -1,5 +1,3 @@ {$content} - -
    diff --git a/modules/member/tpl/default_config.html b/modules/member/tpl/default_config.html index 595d52b6f..d04032437 100644 --- a/modules/member/tpl/default_config.html +++ b/modules/member/tpl/default_config.html @@ -80,5 +80,3 @@ - -
    diff --git a/modules/member/tpl/design_config.html b/modules/member/tpl/design_config.html index f1f37e83f..a656e75fb 100644 --- a/modules/member/tpl/design_config.html +++ b/modules/member/tpl/design_config.html @@ -50,5 +50,3 @@ - -
    diff --git a/modules/member/tpl/group_list.html b/modules/member/tpl/group_list.html index 410ca70c6..93e6305c7 100644 --- a/modules/member/tpl/group_list.html +++ b/modules/member/tpl/group_list.html @@ -103,5 +103,3 @@

    {$lang->add_group_image_mark}: {$lang->link_file_box}

    - -
    diff --git a/modules/member/tpl/insert_member.html b/modules/member/tpl/insert_member.html index 2d39c5305..0991f6adc 100644 --- a/modules/member/tpl/insert_member.html +++ b/modules/member/tpl/insert_member.html @@ -129,5 +129,3 @@ }); })(jQuery); - -
    diff --git a/modules/member/tpl/login_config.html b/modules/member/tpl/login_config.html index 7daba7170..4a7d811d4 100644 --- a/modules/member/tpl/login_config.html +++ b/modules/member/tpl/login_config.html @@ -62,5 +62,3 @@ jQuery(function($){ }).change(); }); - -
    diff --git a/modules/member/tpl/member_list.html b/modules/member/tpl/member_list.html index 59380a2ac..921a188b3 100644 --- a/modules/member/tpl/member_list.html +++ b/modules/member/tpl/member_list.html @@ -202,5 +202,3 @@ jQuery(function($){ }); }); - -
    diff --git a/modules/member/tpl/signup_config.html b/modules/member/tpl/signup_config.html index d4da6731f..3694ba5b6 100644 --- a/modules/member/tpl/signup_config.html +++ b/modules/member/tpl/signup_config.html @@ -198,5 +198,3 @@ #userDefine{max-width:60%;margin-left:-30%} } - -
    diff --git a/modules/menu/tpl/sitemap.html b/modules/menu/tpl/sitemap.html index 1528c6204..f5fa8a25b 100644 --- a/modules/menu/tpl/sitemap.html +++ b/modules/menu/tpl/sitemap.html @@ -352,8 +352,6 @@ - - @@ -4122,6 +4120,3 @@ jQuery.extend({ }); //]]> - -
    -
    diff --git a/modules/module/tpl/adminFileBox.html b/modules/module/tpl/adminFileBox.html index ff209ea07..7173737a2 100644 --- a/modules/module/tpl/adminFileBox.html +++ b/modules/module/tpl/adminFileBox.html @@ -116,5 +116,3 @@ - -
    diff --git a/modules/module/tpl/category_list.html b/modules/module/tpl/category_list.html index 4a25830aa..91c15adf3 100644 --- a/modules/module/tpl/category_list.html +++ b/modules/module/tpl/category_list.html @@ -58,5 +58,3 @@ - -
    diff --git a/modules/module/tpl/category_update_form.html b/modules/module/tpl/category_update_form.html index deb204e85..a91f3ad73 100644 --- a/modules/module/tpl/category_update_form.html +++ b/modules/module/tpl/category_update_form.html @@ -20,4 +20,3 @@ -
    diff --git a/modules/module/tpl/module_list.html b/modules/module/tpl/module_list.html index fcd075303..bbb989d8d 100644 --- a/modules/module/tpl/module_list.html +++ b/modules/module/tpl/module_list.html @@ -59,6 +59,4 @@ jQuery(function($){ $('.dsTg>tbody>tr[data-type1]').prependTo('tbody'); $('.dsTg>tbody>tr[data-type2]').prependTo('tbody'); }); - - -
    + \ No newline at end of file diff --git a/modules/point/tpl/config.html b/modules/point/tpl/config.html index da251cb0e..b9a79cb68 100644 --- a/modules/point/tpl/config.html +++ b/modules/point/tpl/config.html @@ -190,6 +190,4 @@ jQuery(function($){ } }); }); - - -
    + \ No newline at end of file diff --git a/modules/point/tpl/member_list.html b/modules/point/tpl/member_list.html index 0228696fc..447944c6d 100644 --- a/modules/point/tpl/member_list.html +++ b/modules/point/tpl/member_list.html @@ -145,5 +145,3 @@ - -
    diff --git a/modules/point/tpl/module_config.html b/modules/point/tpl/module_config.html index 5f30be3f7..07ee02cba 100644 --- a/modules/point/tpl/module_config.html +++ b/modules/point/tpl/module_config.html @@ -37,5 +37,3 @@ - -
    diff --git a/modules/poll/tpl/poll_list.html b/modules/poll/tpl/poll_list.html index 91e8f4aae..b0aae9a12 100644 --- a/modules/poll/tpl/poll_list.html +++ b/modules/poll/tpl/poll_list.html @@ -124,5 +124,3 @@ jQuery(function($){ }); }); - -
    diff --git a/modules/rss/tpl/rss_admin_index.html b/modules/rss/tpl/rss_admin_index.html index 4342492c6..9055e894e 100644 --- a/modules/rss/tpl/rss_admin_index.html +++ b/modules/rss/tpl/rss_admin_index.html @@ -122,5 +122,3 @@ jQuery(function($){ }); }); - -
    diff --git a/modules/spamfilter/tpl/footer.html b/modules/spamfilter/tpl/footer.html index 30961915b..e69de29bb 100644 --- a/modules/spamfilter/tpl/footer.html +++ b/modules/spamfilter/tpl/footer.html @@ -1 +0,0 @@ -
    diff --git a/modules/trash/tpl/trash_list.html b/modules/trash/tpl/trash_list.html index 04b66db88..802f5b69e 100644 --- a/modules/trash/tpl/trash_list.html +++ b/modules/trash/tpl/trash_list.html @@ -165,5 +165,3 @@ jQuery(function($){ }); }); - -
    diff --git a/modules/trash/tpl/trash_view.html b/modules/trash/tpl/trash_view.html index 64c29d652..b1292c1a9 100644 --- a/modules/trash/tpl/trash_view.html +++ b/modules/trash/tpl/trash_view.html @@ -75,4 +75,3 @@ -
    diff --git a/modules/widget/tpl/downloaded_widget_list.html b/modules/widget/tpl/downloaded_widget_list.html index 920ed0f10..d33afbe22 100644 --- a/modules/widget/tpl/downloaded_widget_list.html +++ b/modules/widget/tpl/downloaded_widget_list.html @@ -39,5 +39,3 @@ - -
    diff --git a/modules/widget/tpl/widget_generate_code.html b/modules/widget/tpl/widget_generate_code.html index c9e400ec9..044278e22 100644 --- a/modules/widget/tpl/widget_generate_code.html +++ b/modules/widget/tpl/widget_generate_code.html @@ -17,5 +17,3 @@

    - -

    From 32aa19e6f2771d6c6c6f12fe33f277a930109654 Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Wed, 17 Feb 2016 15:10:47 +0900 Subject: [PATCH 06/86] Remove unnecessary sitelock template --- common/tpl/sitelock.html | 48 ---------------------------------------- 1 file changed, 48 deletions(-) delete mode 100644 common/tpl/sitelock.html diff --git a/common/tpl/sitelock.html b/common/tpl/sitelock.html deleted file mode 100644 index ca4a4f981..000000000 --- a/common/tpl/sitelock.html +++ /dev/null @@ -1,48 +0,0 @@ - - - - - <?php echo _XE_SITELOCK_TITLE_?> - - - - -
    -
    -

    -

     

    -
    -
    - - From 65517735e0c4f666e365ccdf61dcd8174e984f37 Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Wed, 17 Feb 2016 16:20:57 +0900 Subject: [PATCH 07/86] Clean up common_layout.html and merge with mobile_layout.html --- classes/context/Context.class.php | 4 ++ classes/display/HTMLDisplayHandler.php | 6 +- common/js/common.js | 2 +- common/js/xml_handler.js | 6 +- common/lang/ko.php | 6 +- common/tpl/common_layout.html | 83 +++++++++++++------------- common/tpl/mobile_layout.html | 73 ---------------------- modules/admin/tpl/_footer.html | 6 -- modules/admin/tpl/_header.html | 9 +++ modules/menu/tpl/sitemap.html | 2 + 10 files changed, 65 insertions(+), 132 deletions(-) delete mode 100644 common/tpl/mobile_layout.html diff --git a/classes/context/Context.class.php b/classes/context/Context.class.php index 1479efabe..e128a5dce 100644 --- a/classes/context/Context.class.php +++ b/classes/context/Context.class.php @@ -2032,6 +2032,10 @@ class Context { return self::$_instance->ssl_actions; } + else + { + return array(); + } } /** diff --git a/classes/display/HTMLDisplayHandler.php b/classes/display/HTMLDisplayHandler.php index 0373d5510..2254c2694 100644 --- a/classes/display/HTMLDisplayHandler.php +++ b/classes/display/HTMLDisplayHandler.php @@ -223,17 +223,17 @@ class HTMLDisplayHandler // convert the final layout Context::set('content', $output); + Context::set('m', $is_mobile = Mobile::isFromMobilePhone() ? 1 : 0); $oTemplate = TemplateHandler::getInstance(); - if(Mobile::isFromMobilePhone()) + if($is_mobile) { $this->_loadMobileJSCSS(); - $output = $oTemplate->compile('./common/tpl', 'mobile_layout'); } else { $this->_loadDesktopJSCSS(); - $output = $oTemplate->compile('./common/tpl', 'common_layout'); } + $output = $oTemplate->compile('./common/tpl', 'common_layout'); // replace the user-defined-language $oModuleController = getController('module'); diff --git a/common/js/common.js b/common/js/common.js index ab14e21c7..08b0d6688 100644 --- a/common/js/common.js +++ b/common/js/common.js @@ -933,7 +933,7 @@ function getCookie(name) { } function is_def(v) { - return (typeof(v)!='undefined'); + return typeof(v) != 'undefined' && v !== null; } function ucfirst(str) { diff --git a/common/js/xml_handler.js b/common/js/xml_handler.js index 5e2ee7f8e..2b049bdfe 100644 --- a/common/js/xml_handler.js +++ b/common/js/xml_handler.js @@ -54,7 +54,7 @@ waiting_obj.css("opacity", 0.0); var wfsr_timeout = setTimeout(function() { if (show_waiting_message) { - waiting_obj.css("opacity", "").html(waiting_message).show(); + waiting_obj.css("opacity", "").show(); } }, 1000); @@ -175,7 +175,7 @@ waiting_obj.css("opacity", 0.0); var wfsr_timeout = setTimeout(function() { if (show_waiting_message) { - waiting_obj.css("opacity", "").html(waiting_message).show(); + waiting_obj.css("opacity", "").show(); } }, 1000); @@ -270,7 +270,7 @@ waiting_obj.css("opacity", 0.0); var wfsr_timeout = setTimeout(function() { if (show_waiting_message) { - waiting_obj.css("opacity", "").html(waiting_message).show(); + waiting_obj.css("opacity", "").show(); } }, 1000); diff --git a/common/lang/ko.php b/common/lang/ko.php index 69835c2fd..0e6e43253 100644 --- a/common/lang/ko.php +++ b/common/lang/ko.php @@ -203,10 +203,10 @@ $lang->about_tag = '쉼표(,)를 이용하여 복수 등록'; $lang->about_layout = '레이아웃은 콘텐츠의 겉모습을 꾸며줍니다. 상단 레이아웃 메뉴에서 관리할 수 있습니다.'; $lang->about_ipaddress_input = 'IP주소 입력형식
    1. 와일드카드(*) 사용가능(예: 192.168.0.*)
    2. 하이픈(-)을 사용하여 대역으로 입력가능
    (단, 대역폭으로 입력할 경우 와일드카드 사용불가. 예: 192.168.0.1-192.168.0.254)
    3.여러개의 항목은 줄을 바꾸어 입력하세요'; $lang->msg_invalid_ip = '잘못된 IP주소 형식입니다.'; -$lang->msg_no_root = '루트는 선택 할 수 없습니다.'; -$lang->msg_no_shortcut = '바로가기는 선택 할 수 없습니다.'; +$lang->msg_no_root = '루트는 선택할 수 없습니다.'; +$lang->msg_no_shortcut = '바로가기는 선택할 수 없습니다.'; $lang->msg_select_menu = '대상 메뉴 선택'; -$lang->msg_call_server = '서버에 요청 중입니다. 잠시만 기다려주세요.'; +$lang->msg_call_server = '서버에 요청 중입니다. 잠시만 기다려 주십시오...'; $lang->msg_db_not_setted = 'DB 설정이 되어 있지 않습니다.'; $lang->msg_dbconnect_failed = 'DB 접속 오류가 발생했습니다. DB정보를 다시 확인해주세요.'; $lang->msg_invalid_queryid = 'Query ID값이 잘못 지정되었습니다.'; diff --git a/common/tpl/common_layout.html b/common/tpl/common_layout.html index c68945e8f..264683074 100644 --- a/common/tpl/common_layout.html +++ b/common/tpl/common_layout.html @@ -1,33 +1,31 @@ -{@ - $db_info = Context::getDBInfo(); - $lang_type = Context::getLangType(); - $ssl_actions = Context::getSSLActions(); - $css_files = Context::getCssFile(); - $js_files = Context::getJsFile(); -} - + + - + + + {Context::getBrowserTitle()} + - + - +{"\n"} + - + - +{"\n"} @@ -35,48 +33,47 @@ - + + -{Context::getHtmlHeader()} - -{@$isAdminKind = false} - -{@$isAdminKind = true} - + + + + {Context::getBodyHeader()} {$content} {Context::getHtmlFooter()} + -
    +
    {$lang->msg_call_server}
    -{@ $js_body_files = Context::getJsFile('body') } - - + + + +{"\n"} diff --git a/common/tpl/mobile_layout.html b/common/tpl/mobile_layout.html deleted file mode 100644 index f957cc7ef..000000000 --- a/common/tpl/mobile_layout.html +++ /dev/null @@ -1,73 +0,0 @@ -{@ - $lang_type = Context::getLangType(); - $ssl_actions = Context::getSSLActions(); - $css_files=Context::getCssFile(); - $js_files=Context::getJsFile(); -} - - - - - - - - - -{Context::getBrowserTitle()} - - - - - - - - - - - - - - - - - - - - - - - - - - -{Context::getHtmlHeader()} - - - -{Context::getBodyHeader()} -{$content} -{Context::getHtmlFooter()} -
    -
    - -{@ $js_body_files = Context::getJsFile('body') } - - - - - - - diff --git a/modules/admin/tpl/_footer.html b/modules/admin/tpl/_footer.html index a5689eb6c..e60075e64 100644 --- a/modules/admin/tpl/_footer.html +++ b/modules/admin/tpl/_footer.html @@ -16,11 +16,5 @@

    - diff --git a/modules/admin/tpl/_header.html b/modules/admin/tpl/_header.html index bb50a84f1..e1d0fe4dd 100644 --- a/modules/admin/tpl/_header.html +++ b/modules/admin/tpl/_header.html @@ -1,5 +1,14 @@ +

    {$lang->skip_to_content}

    diff --git a/modules/menu/tpl/sitemap.html b/modules/menu/tpl/sitemap.html index eb0515cf1..5f68736fe 100644 --- a/modules/menu/tpl/sitemap.html +++ b/modules/menu/tpl/sitemap.html @@ -685,6 +685,8 @@ - -
    diff --git a/modules/admin/tpl/_dashboard_default.html b/modules/admin/tpl/_dashboard_default.html index 32e4ae3e2..1028cc468 100644 --- a/modules/admin/tpl/_dashboard_default.html +++ b/modules/admin/tpl/_dashboard_default.html @@ -63,3 +63,4 @@

    {$lang->more}

    + diff --git a/modules/admin/tpl/_header.html b/modules/admin/tpl/_header.html index ef2f95953..34b083724 100644 --- a/modules/admin/tpl/_header.html +++ b/modules/admin/tpl/_header.html @@ -1,7 +1,5 @@ - -

    {$lang->skip_to_content}

    diff --git a/modules/admin/tpl/admin_setup.html b/modules/admin/tpl/admin_setup.html index 758739f5c..a75dfc524 100644 --- a/modules/admin/tpl/admin_setup.html +++ b/modules/admin/tpl/admin_setup.html @@ -114,5 +114,3 @@ .adminMap .parent>.side{right:30px} .adminMap .placeholder{background:#000;border-radius:5px} - -
    diff --git a/modules/admin/tpl/config_ftp.html b/modules/admin/tpl/config_ftp.html index 22e2c0a67..4208abd88 100644 --- a/modules/admin/tpl/config_ftp.html +++ b/modules/admin/tpl/config_ftp.html @@ -124,5 +124,3 @@ jQuery(function($){ }); }); - -
    diff --git a/modules/admin/tpl/config_general.html b/modules/admin/tpl/config_general.html index 9ae57ce97..3ec964fd8 100644 --- a/modules/admin/tpl/config_general.html +++ b/modules/admin/tpl/config_general.html @@ -314,4 +314,3 @@ function doSubmitConfig() -
    diff --git a/modules/admin/tpl/css/admin.css b/modules/admin/tpl/css/admin.css index 1de422984..674e20d79 100644 --- a/modules/admin/tpl/css/admin.css +++ b/modules/admin/tpl/css/admin.css @@ -908,9 +908,6 @@ margin-bottom: 10px; text-decoration: none; color: #666; } -.x>.header>.account>ul>li.forum-chak>a { - color: #FFF; -} .x>.header>.account>ul>li>a:hover, .x>.header>.account>ul>li>a:focus { text-decoration: underline; @@ -2390,33 +2387,3 @@ html[lang="mn"] .x .g11n.active>[disabled], height: 1px; overflow: hidden; } - - -.admin-forum-container { - clear: both; - margin: 10px 5px; - border: 0 solid #ddd; -} -.admin-forum-container.activated-forum { - margin-top: 30px; - padding: 15px; - background-color: #fbfbfb; - border-width: 3px 0; -} -.admin-forum-container .open-forum { - display: inline-block; - padding: 15px; - padding-left: 60px; - color: #0088cc; - font-size: 14px; - height: 20px; - line-height: 20px; - text-decoration: none; - background-image: url('../img/chak_c.png'); - background-repeat: no-repeat; - background-position: center left; -} -.admin-forum-container .open-forum:hover, -.admin-forum-container .open-forum:active { - text-decoration: underline; -} diff --git a/modules/admin/tpl/img/chak_c.png b/modules/admin/tpl/img/chak_c.png deleted file mode 100644 index c0ea44130ce82d62518e652917ad1c132ff6feb2..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 5176 zcmeHLdo+~m9{$EIm2}n3j$@(=rZIPOX-q^(8HLGZcQa;;ennTIY|m*0I*ieDl7)=Xu`W`@Fy3yvv@I zE{@~$e%1p3V4TxZ2RG=G0KKM+)`i}Y)8sYK2TbbbxClroGI|4jfwPvn(E(uNTmT5! z2>_kYP)Gv+$k71s)&~G6F#s@Kd@RG23Qdd=FZGrJz*qzI3kDoHHUoNi$76WOyy(sp zmPla5WQ%-3D}_J|MFRj;L4h6xpo|Gu2>3!NMPXyAiJ(Bw>S2^AToWSOU}Ne4!t#Y)t)RGBE{(3JMCc3c^{5BwQ4ROeUkySQHkE zgd&jAV4;kuKnkU1eI#Fb96%{c!V}AQA|YJO%k&k=Wj3a!YN3I@zIDoYoIxd_v_CB< zL6mw1g|R}ThJuOxL^6@oPb3~#0t>#1#cK#^~|s^HfumoESK;#o5E(HKt3n{ zg)%9G!wk7z$eaP-H!D>z#lwn0AUgeD!vumM<)pI3fzXEc8#tt(lo2cjQEs4AB$u$j z#evZB2VI0rqN?|wqMql=)kdxo@?wL;q^YY0?zGt68bh|WMq;fXjv?cQ z_#KJ81ccyP6eJ{u%)mkv7z&Q4&7u|g9S5}kJWj9{$1uwn4Ev5iLoJdpL?S-TPTlI@ zE5DXJ+}<7z<%Wlw)0r%uP~8VC`m)jnealCuQUII<(~Yt_xyvh!tuY%<0djYN|`HWH5~V4<>u-q2VU4owDGSdcZa|61_jHTnzeKR2$g z6u)hYnhrZ;8>K>tKod?sHk7}Y*$?o+%=)RJy91XeWbz$EEV=rg)!(z&f4gV(Nen^r zgOrv;-~E{_VnH&4*AEv=WvAFv7h4l|Q zp2qa%y*!`GKF?jUPvjE&q*XZ=8_)Ipn6hwblI6VWt6#RvcUy<*JZuhgdvx`wOZer} z=VN+0W~9yfwCePRjxRYmIr7Vx^Li&eQUceXtv}yX_U7zFT^Rn=VwXm}o<`m||VjCZ|6W3vl6sW}Y|e!p8bA1%3g>U@G%gVPQFh*)}EY0UDY)ROg_ zx^2GRGasyL$i_uHn+966oZ`CaI9z$Q=P4;9D?GO*B=Ud=6A`8x>G|yWb5ZR%*L+5@ zzRRyi_+_f|O@=zgfAUq1+zE#H5%jpmi}gjoV{iN8JH*es)2g$!)I`&z)$L_EnG6?& zQ`r4^(f7NFY!>T6mlt>nu1L8yg$_RPp6pYN~W$ z*Q{kls(J9`A2KH!&YX$xF!ZkVdcWgBR$gd>XT_RbXCw_*?%%(^SeB8L8c?(3jhs4p z^oiT2y0&L@W}&Znr3c@;ka-y=05}TfoL3VwV!WjZ9T}f@j?kT!wvlzNt*vdsr7J$i zYu{C*wpixX)zw{2oNGqH7k1}46K|dHvuZ3ZEtRhRo#B7x?AfD6CMN4;`l^Jf`DvmT z)ltrKpKpi9)P&ciw_hqDVK4!Nq9~I_{0N4jN*HnN`Q(GD2(J%^-Q%YhMHd#92216R zmSK<9C6mezUXQ-ky3;UihEZGouFoDPzBol0MNWeGPF2=kx_kkN1Q8Ji*IX|z{8OOZ zXO4IVGwimq>zMQz5u!NsqP{1!`0xRzoR-=3b972{-nTf9TdLYMGPyP_Ee&r+8ljBB zrYh5-JQt2FaC*42EKySGZ1JZJvgD859>Dv&moIM?y@^{8bOvXAqIC|>bC;JtY|nf+ zLZ-OTa&ckkp^Yq)+M89kJ4vniK){Lz8vrrzY&vPHs$)xg>+D0@dXL@}`idA^<{w@F z-Zf9&XU30CKKL^7Ncugm3S#{FB*cfrgBQAz8Y9ZAuG-+b-nFb@uRF5LIoLQD7us`R z(hlh?U53ls@LvDB=~$oF6Ah2dMHGnTRQ=E`Mp-7gBJ;SQOXD#w#=f|ZDaAKp{_4>S z-RT$5F|t8g>#UpLxRoc7eEKOP|F})#uWeycMtkt`sKTU*j^vjQle(Y8C)q2NsfF$j z17DBQaT=Z3HKCa5cQoMP{hT6`@}Wp{ne zoxoEg8@qFwtLNfXkp&E3PW|N-wwnn?m*GIcm5jKtmW6q%fa3)ZTGkMcKUA9CZXA^+ zhFi{`N{?JBD5^4ly!P%U>-Vq{T~}TfaIr_?GrpYN7J|6-RqIaAZYBH~P|@{{ynnFV)5-nto!TlW5zUE6*!T_$@N z-xBWbzP{*lJ1uT@)oIsGi+wh>W2pI?CxC5ffwZ)c>joE5E9Z{d^VT}pcH$I$@OJpy zQ3k;`SCm;;WKJiU*f*g+HLr9$PAQJYO;x z{mW*^K4hY<>zkXW%ns!ceJG*H5kDP@s<8<09Cat{BW=61zNj0SEqSi#9XZSd2-wa@1wPGlp9vV7r& zt_*2}Cl3>0Qkx|1H}%wW2H&)j8Oe^a+mt6c%A~6aoWmq?IjvH#T$W|xyqJbRos1a wyL6xOW@_fMXGNL2N7wxFGAyjOBA@O51eR-%J^%m! diff --git a/modules/admin/tpl/js/admin.js b/modules/admin/tpl/js/admin.js index 1f3a60d20..0eee8ae5b 100644 --- a/modules/admin/tpl/js/admin.js +++ b/modules/admin/tpl/js/admin.js @@ -2471,67 +2471,3 @@ jQuery(function($){ } }); }); - - - -// Forum Chak -(function($){ - var chak = { - elClass: 'chak-comment', - group_id: 'xe1_official', - apikey: 'xe17935b49af5435d37f1cde130363db-forum' - }; - - $(function(){ - var $chakContainer = $('.admin-forum-container'); - - if($chakContainer.length) { - var $forumOpen = $('이 페이지에 대한 포럼 보기'); - var $headerButton = $('
  • Forum
  • '); - var $headerMenu = $('header.header .account ul'); - - (function(){var s=document.createElement('script');s.type='text/javascript';s.src='//chak.it/static/service.js';s.async=true;(document.getElementsByTagName('head')[0]||document.getElementsByTagName('body')[0]).appendChild(s);})(); - - $chakContainer.each(function(idx){ - var $el = $(this); - var elData = $el.data(); - elData.count = 0; - var $opener = $forumOpen.clone(); - var $button = $headerButton.clone(); - var forumId = 'inline-forum-' + idx; - - $el.append($opener); - - $button.find('a') - .attr('href', '#' + forumId) - .on('click', function(){ - var $target = $($.attr(this, 'href')); - $('html, body').animate({ - scrollTop: $target.offset().top - 20 - }, 500); - return false; - }) - .one('click', function() { - var $target = $($.attr(this, 'href')); - $target.find('a').click(); - }); - - $headerMenu.append($button); - $el.attr('id', forumId); - - $el.find('a').on('click', function(){ - var div = document.createElement("div"); - div.setAttribute("data-chak-apikey", chak.apikey); - div.setAttribute("data-chak-categories", elData.chakCategories); - - $opener.after(div); - $chakContainer.addClass('activated-forum'); - - manuallySetChakService(div); - - $opener.remove(); - }); - }); - } - }); -})(jQuery); diff --git a/modules/autoinstall/tpl/index.html b/modules/autoinstall/tpl/index.html index f40c74b3d..cb29354da 100644 --- a/modules/autoinstall/tpl/index.html +++ b/modules/autoinstall/tpl/index.html @@ -25,5 +25,3 @@ --> - -
    diff --git a/modules/autoinstall/tpl/list.html b/modules/autoinstall/tpl/list.html index b34fc9423..3004245cd 100644 --- a/modules/autoinstall/tpl/list.html +++ b/modules/autoinstall/tpl/list.html @@ -45,6 +45,16 @@

    {$item->category} {$item->title}

    +

    + + package_voted/$item->package_voter*20)}%">{sprintf("%0.1f",$item->package_voted/$item->package_voter*2)}{sprintf($lang->rate, $item->package_start)} + {sprintf("%0.1f",$item->package_voted/$item->package_voter*2)}/{number_format($item->package_voter)} + + + 0 + 0/0 + +

    {$lang->installed} {$lang->install} @@ -90,6 +100,14 @@

    {$item->category} {$item->title}

    {cut_str($item->package_description,200)}

    + + package_voted/$item->package_voter*20)}%">{sprintf("%0.1f",$item->package_voted/$item->package_voter*2)}{sprintf($lang->rate, $item->package_start)} + {sprintf("%0.1f",$item->package_voted/$item->package_voter*2)}/{number_format($item->package_voter)} + + + 0 + 0/0 + {$lang->package_update}: | {$lang->package_downloaded_count}: {number_format($item->package_downloaded)} diff --git a/modules/comment/tpl/comment_list.html b/modules/comment/tpl/comment_list.html index 7104adeb5..40f8be128 100644 --- a/modules/comment/tpl/comment_list.html +++ b/modules/comment/tpl/comment_list.html @@ -199,5 +199,3 @@ jQuery(function($){ }); }); - -

    diff --git a/modules/comment/tpl/declared_list.html b/modules/comment/tpl/declared_list.html index 9c627d151..34aa58508 100644 --- a/modules/comment/tpl/declared_list.html +++ b/modules/comment/tpl/declared_list.html @@ -115,6 +115,4 @@ jQuery(function($){ } }).change(); }); - - -
    + \ No newline at end of file diff --git a/modules/document/tpl/declared_list.html b/modules/document/tpl/declared_list.html index 0019b45f5..b9e94aeb6 100644 --- a/modules/document/tpl/declared_list.html +++ b/modules/document/tpl/declared_list.html @@ -200,6 +200,4 @@ jQuery(function($){ } }); }); - - -
    + \ No newline at end of file diff --git a/modules/document/tpl/document_list.html b/modules/document/tpl/document_list.html index ea13dc025..d9eca400e 100644 --- a/modules/document/tpl/document_list.html +++ b/modules/document/tpl/document_list.html @@ -216,5 +216,3 @@ jQuery(function($){ }); }); - -
    diff --git a/modules/editor/tpl/admin_index.html b/modules/editor/tpl/admin_index.html index 2cf340627..00d055ab5 100644 --- a/modules/editor/tpl/admin_index.html +++ b/modules/editor/tpl/admin_index.html @@ -213,4 +213,3 @@ jQuery(function($){ }); -
    diff --git a/modules/file/tpl/adminConfig.html b/modules/file/tpl/adminConfig.html index 6ae5cb121..1d4bd8782 100644 --- a/modules/file/tpl/adminConfig.html +++ b/modules/file/tpl/adminConfig.html @@ -56,5 +56,3 @@
    - -
    diff --git a/modules/file/tpl/file_list.html b/modules/file/tpl/file_list.html index 1f00e2e6e..a11f42b82 100644 --- a/modules/file/tpl/file_list.html +++ b/modules/file/tpl/file_list.html @@ -207,5 +207,3 @@ jQuery(function($){ }); }); - -
    diff --git a/modules/importer/tpl/index.html b/modules/importer/tpl/index.html index ab917cb21..cac85a045 100644 --- a/modules/importer/tpl/index.html +++ b/modules/importer/tpl/index.html @@ -105,5 +105,3 @@ jQuery('a.modalAnchor') return false; }); - -
    diff --git a/modules/layout/tpl/installed_layout_list.html b/modules/layout/tpl/installed_layout_list.html index efbb71cd4..2916eb953 100644 --- a/modules/layout/tpl/installed_layout_list.html +++ b/modules/layout/tpl/installed_layout_list.html @@ -52,5 +52,3 @@ - -
    diff --git a/modules/layout/tpl/layout_all_instance_list.html b/modules/layout/tpl/layout_all_instance_list.html index a6782fc14..bcc8394e3 100644 --- a/modules/layout/tpl/layout_all_instance_list.html +++ b/modules/layout/tpl/layout_all_instance_list.html @@ -43,5 +43,3 @@ - -
    diff --git a/modules/layout/tpl/layout_edit.html b/modules/layout/tpl/layout_edit.html index c180bf573..86a0f5690 100644 --- a/modules/layout/tpl/layout_edit.html +++ b/modules/layout/tpl/layout_edit.html @@ -94,5 +94,3 @@ - -
    diff --git a/modules/layout/tpl/layout_instance_list.html b/modules/layout/tpl/layout_instance_list.html index b67cbdc8d..702ea4fca 100644 --- a/modules/layout/tpl/layout_instance_list.html +++ b/modules/layout/tpl/layout_instance_list.html @@ -105,5 +105,3 @@ xe.lang.confirm_delete = '{$lang->confirm_delete}'; - -
    diff --git a/modules/layout/tpl/layout_modify.html b/modules/layout/tpl/layout_modify.html index 71b925a05..279f8196a 100644 --- a/modules/layout/tpl/layout_modify.html +++ b/modules/layout/tpl/layout_modify.html @@ -1,5 +1,3 @@ {$content} - -
    diff --git a/modules/member/tpl/default_config.html b/modules/member/tpl/default_config.html index 595d52b6f..d04032437 100644 --- a/modules/member/tpl/default_config.html +++ b/modules/member/tpl/default_config.html @@ -80,5 +80,3 @@ - -
    diff --git a/modules/member/tpl/design_config.html b/modules/member/tpl/design_config.html index f1f37e83f..a656e75fb 100644 --- a/modules/member/tpl/design_config.html +++ b/modules/member/tpl/design_config.html @@ -50,5 +50,3 @@ - -
    diff --git a/modules/member/tpl/group_list.html b/modules/member/tpl/group_list.html index 410ca70c6..93e6305c7 100644 --- a/modules/member/tpl/group_list.html +++ b/modules/member/tpl/group_list.html @@ -103,5 +103,3 @@

    {$lang->add_group_image_mark}: {$lang->link_file_box}

    - -
    diff --git a/modules/member/tpl/insert_member.html b/modules/member/tpl/insert_member.html index 2d39c5305..0991f6adc 100644 --- a/modules/member/tpl/insert_member.html +++ b/modules/member/tpl/insert_member.html @@ -129,5 +129,3 @@ }); })(jQuery); - -
    diff --git a/modules/member/tpl/login_config.html b/modules/member/tpl/login_config.html index 7daba7170..4a7d811d4 100644 --- a/modules/member/tpl/login_config.html +++ b/modules/member/tpl/login_config.html @@ -62,5 +62,3 @@ jQuery(function($){ }).change(); }); - -
    diff --git a/modules/member/tpl/member_list.html b/modules/member/tpl/member_list.html index 59380a2ac..921a188b3 100644 --- a/modules/member/tpl/member_list.html +++ b/modules/member/tpl/member_list.html @@ -202,5 +202,3 @@ jQuery(function($){ }); }); - -
    diff --git a/modules/member/tpl/signup_config.html b/modules/member/tpl/signup_config.html index d4da6731f..3694ba5b6 100644 --- a/modules/member/tpl/signup_config.html +++ b/modules/member/tpl/signup_config.html @@ -198,5 +198,3 @@ #userDefine{max-width:60%;margin-left:-30%} } - -
    diff --git a/modules/menu/tpl/sitemap.html b/modules/menu/tpl/sitemap.html index 1528c6204..f5fa8a25b 100644 --- a/modules/menu/tpl/sitemap.html +++ b/modules/menu/tpl/sitemap.html @@ -352,8 +352,6 @@ - - @@ -4122,6 +4120,3 @@ jQuery.extend({ }); //]]> - -
    -
    diff --git a/modules/module/tpl/adminFileBox.html b/modules/module/tpl/adminFileBox.html index ff209ea07..7173737a2 100644 --- a/modules/module/tpl/adminFileBox.html +++ b/modules/module/tpl/adminFileBox.html @@ -116,5 +116,3 @@ - -
    diff --git a/modules/module/tpl/category_list.html b/modules/module/tpl/category_list.html index 4a25830aa..91c15adf3 100644 --- a/modules/module/tpl/category_list.html +++ b/modules/module/tpl/category_list.html @@ -58,5 +58,3 @@ - -
    diff --git a/modules/module/tpl/category_update_form.html b/modules/module/tpl/category_update_form.html index deb204e85..a91f3ad73 100644 --- a/modules/module/tpl/category_update_form.html +++ b/modules/module/tpl/category_update_form.html @@ -20,4 +20,3 @@ -
    diff --git a/modules/module/tpl/module_list.html b/modules/module/tpl/module_list.html index fcd075303..bbb989d8d 100644 --- a/modules/module/tpl/module_list.html +++ b/modules/module/tpl/module_list.html @@ -59,6 +59,4 @@ jQuery(function($){ $('.dsTg>tbody>tr[data-type1]').prependTo('tbody'); $('.dsTg>tbody>tr[data-type2]').prependTo('tbody'); }); - - -
    + \ No newline at end of file diff --git a/modules/point/tpl/config.html b/modules/point/tpl/config.html index da251cb0e..b9a79cb68 100644 --- a/modules/point/tpl/config.html +++ b/modules/point/tpl/config.html @@ -190,6 +190,4 @@ jQuery(function($){ } }); }); - - -
    + \ No newline at end of file diff --git a/modules/point/tpl/member_list.html b/modules/point/tpl/member_list.html index 0228696fc..447944c6d 100644 --- a/modules/point/tpl/member_list.html +++ b/modules/point/tpl/member_list.html @@ -145,5 +145,3 @@ - -
    diff --git a/modules/point/tpl/module_config.html b/modules/point/tpl/module_config.html index 5f30be3f7..07ee02cba 100644 --- a/modules/point/tpl/module_config.html +++ b/modules/point/tpl/module_config.html @@ -37,5 +37,3 @@ - -
    diff --git a/modules/poll/tpl/poll_list.html b/modules/poll/tpl/poll_list.html index 91e8f4aae..b0aae9a12 100644 --- a/modules/poll/tpl/poll_list.html +++ b/modules/poll/tpl/poll_list.html @@ -124,5 +124,3 @@ jQuery(function($){ }); }); - -
    diff --git a/modules/rss/tpl/rss_admin_index.html b/modules/rss/tpl/rss_admin_index.html index 4342492c6..9055e894e 100644 --- a/modules/rss/tpl/rss_admin_index.html +++ b/modules/rss/tpl/rss_admin_index.html @@ -122,5 +122,3 @@ jQuery(function($){ }); }); - -
    diff --git a/modules/spamfilter/tpl/footer.html b/modules/spamfilter/tpl/footer.html index 30961915b..e69de29bb 100644 --- a/modules/spamfilter/tpl/footer.html +++ b/modules/spamfilter/tpl/footer.html @@ -1 +0,0 @@ -
    diff --git a/modules/trash/tpl/trash_list.html b/modules/trash/tpl/trash_list.html index 04b66db88..802f5b69e 100644 --- a/modules/trash/tpl/trash_list.html +++ b/modules/trash/tpl/trash_list.html @@ -165,5 +165,3 @@ jQuery(function($){ }); }); - -
    diff --git a/modules/trash/tpl/trash_view.html b/modules/trash/tpl/trash_view.html index 64c29d652..b1292c1a9 100644 --- a/modules/trash/tpl/trash_view.html +++ b/modules/trash/tpl/trash_view.html @@ -75,4 +75,3 @@ -
    diff --git a/modules/widget/tpl/downloaded_widget_list.html b/modules/widget/tpl/downloaded_widget_list.html index 920ed0f10..d33afbe22 100644 --- a/modules/widget/tpl/downloaded_widget_list.html +++ b/modules/widget/tpl/downloaded_widget_list.html @@ -39,5 +39,3 @@ - -
    diff --git a/modules/widget/tpl/widget_generate_code.html b/modules/widget/tpl/widget_generate_code.html index c9e400ec9..044278e22 100644 --- a/modules/widget/tpl/widget_generate_code.html +++ b/modules/widget/tpl/widget_generate_code.html @@ -17,5 +17,3 @@

    - -

    From e85e6a5266cc1641d97670654584466a9d7deb0b Mon Sep 17 00:00:00 2001 From: bnu Date: Thu, 18 Feb 2016 18:06:53 +0900 Subject: [PATCH 24/86] version 1.8.16 --- config/config.inc.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config/config.inc.php b/config/config.inc.php index 775cd5b26..7d9a78dcf 100644 --- a/config/config.inc.php +++ b/config/config.inc.php @@ -29,7 +29,7 @@ define('__ZBXE__', __XE__); /** * Display XE's full version. */ -define('__XE_VERSION__', '1.8.15'); +define('__XE_VERSION__', '1.8.16'); define('__XE_VERSION_ALPHA__', (stripos(__XE_VERSION__, 'alpha') !== false)); define('__XE_VERSION_BETA__', (stripos(__XE_VERSION__, 'beta') !== false)); define('__XE_VERSION_RC__', (stripos(__XE_VERSION__, 'rc') !== false)); From 3f604c7f591a56f298bd2a514d741eccf104c9d4 Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Thu, 18 Feb 2016 20:10:08 +0900 Subject: [PATCH 25/86] Fix unit tests --- tests/unit/classes/ValidatorTest.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/tests/unit/classes/ValidatorTest.php b/tests/unit/classes/ValidatorTest.php index c947ccfbd..de4202704 100644 --- a/tests/unit/classes/ValidatorTest.php +++ b/tests/unit/classes/ValidatorTest.php @@ -4,8 +4,15 @@ class ValidatorTest extends \Codeception\TestCase\Test { public function _before() { + $ob_level = ob_get_level(); + $oContext = Context::getInstance(); $oContext->init(); + + while (ob_get_level() > $ob_level) + { + ob_end_clean(); + } } public function testRequired() From 397a1e163b7689363370fc8d0f8b9e7a0a9bef00 Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Fri, 19 Feb 2016 14:14:19 +0900 Subject: [PATCH 26/86] Fix #293 Incompatible use of set_to_get_vars in Context::set() --- classes/context/Context.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/classes/context/Context.class.php b/classes/context/Context.class.php index 6cbf5476a..4d444d157 100644 --- a/classes/context/Context.class.php +++ b/classes/context/Context.class.php @@ -1884,7 +1884,7 @@ class Context self::$_user_vars->{$key} = $val; self::$_instance->{$key} = $val; - if($set_to_get_vars) + if($set_to_get_vars || isset(self::$_instance->get_vars->{$key})) { if($val === NULL || $val === '') { From 9703b1268d61eda53c7269e97a98a0964eb1b9ea Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Fri, 19 Feb 2016 15:36:08 +0900 Subject: [PATCH 27/86] Fix multidimensional array handling in Context::_filterRequestVar() --- classes/context/Context.class.php | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/classes/context/Context.class.php b/classes/context/Context.class.php index 4d444d157..ba3fa0393 100644 --- a/classes/context/Context.class.php +++ b/classes/context/Context.class.php @@ -1377,10 +1377,21 @@ class Context if($do_stripslashes && version_compare(PHP_VERSION, '5.4.0', '<') && get_magic_quotes_gpc()) { - $result[$k] = stripslashes($result[$k]); + if (is_array($result[$k])) + { + array_walk_recursive($result[$k], function(&$val) { $val = stripslashes($val); }); + } + else + { + $result[$k] = stripslashes($result[$k]); + } } - if(!is_array($result[$k])) + if(is_array($result[$k])) + { + array_walk_recursive($result[$k], function(&$val) { $val = trim($val); }); + } + else { $result[$k] = trim($result[$k]); } From 8ee10fe9b291f0fbde4590d0446cbedf357342e4 Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Fri, 19 Feb 2016 15:44:26 +0900 Subject: [PATCH 28/86] Fix division by zero during page calculation in DocumentModel --- modules/document/document.model.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/document/document.model.php b/modules/document/document.model.php index c353a33a4..2420eebb0 100644 --- a/modules/document/document.model.php +++ b/modules/document/document.model.php @@ -621,7 +621,7 @@ class documentModel extends document $this->_setSearchOption($opt, $args, $query_id, $use_division); - if($sort_check->isExtraVars) + if($sort_check->isExtraVars || !$opt->list_count) { return 1; } From ec685c16069002a34a15fd8696e63eac95b45cf6 Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Fri, 19 Feb 2016 16:36:37 +0900 Subject: [PATCH 29/86] Fix non-ASCII characters being incorrectly escaped in array keys --- classes/context/Context.class.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/classes/context/Context.class.php b/classes/context/Context.class.php index ba3fa0393..d3f6914ea 100644 --- a/classes/context/Context.class.php +++ b/classes/context/Context.class.php @@ -1182,7 +1182,7 @@ class Context { continue; } - $key = htmlentities($key); + $key = escape($key); $val = $this->_filterRequestVar($key, $val); if($requestMethod == 'GET' && isset($_GET[$key])) @@ -1358,7 +1358,7 @@ class Context $result = array(); foreach($val as $k => $v) { - $k = htmlentities($k); + $k = escape($k); if($key === 'page' || $key === 'cpage' || substr_compare($key, 'srl', -3) === 0) { $result[$k] = !preg_match('/^[0-9,]+$/', $v) ? (int) $v : $v; From 0b53a1c115eab4c438d9b673e4f3911572a428be Mon Sep 17 00:00:00 2001 From: bjrambo Date: Fri, 19 Feb 2016 18:00:42 +0900 Subject: [PATCH 30/86] =?UTF-8?q?=EB=B3=80=EC=88=98=20=EC=B4=88=EA=B8=B0?= =?UTF-8?q?=ED=99=94=20=EC=95=88=EB=90=9C=EA=B2=83=20=EC=B4=88=EA=B8=B0?= =?UTF-8?q?=ED=99=94?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/document/document.admin.controller.php | 1 + 1 file changed, 1 insertion(+) diff --git a/modules/document/document.admin.controller.php b/modules/document/document.admin.controller.php index 6e624491b..8e6de0410 100644 --- a/modules/document/document.admin.controller.php +++ b/modules/document/document.admin.controller.php @@ -92,6 +92,7 @@ class documentAdminController extends document $obj = $oDocument->getObjectVars(); // ISSUE https://github.com/xpressengine/xe-core/issues/32 + $args_doc_origin = new stdClass(); $args_doc_origin->document_srl = $document_srl; $output_ori = executeQuery('document.getDocument', $args_doc_origin, array('content')); $obj->content = $output_ori->data->content; From de682772d425d37d98c4b1c82cb2022231c0049f Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Fri, 19 Feb 2016 18:05:31 +0900 Subject: [PATCH 31/86] Fix #297 member extra info on signup form --- modules/member/member.admin.view.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/member/member.admin.view.php b/modules/member/member.admin.view.php index ca4318ce1..21e3d6ba8 100644 --- a/modules/member/member.admin.view.php +++ b/modules/member/member.admin.view.php @@ -631,7 +631,7 @@ class memberAdminView extends member } $replace = array_merge($extentionReplace, $replace); - $inputTag = preg_replace_callback('@%(\w+)%@', function($n) { return $replace[$n[1]]; }, $template); + $inputTag = preg_replace_callback('@%(\w+)%@', function($n) use($replace) { return $replace[$n[1]]; }, $template); if($extendForm->description) $inputTag .= '

    '.$extendForm->description.'

    '; From 68ceadb90c55b041f697da0a610ec216d8fd334a Mon Sep 17 00:00:00 2001 From: bnu Date: Fri, 19 Feb 2016 18:35:20 +0900 Subject: [PATCH 32/86] =?UTF-8?q?#1861=20=ED=9A=8C=EC=9B=90=EC=84=A4?= =?UTF-8?q?=EC=A0=95=EC=97=90=EC=84=9C=20=EC=82=AC=EC=9A=A9=EC=9E=90=20?= =?UTF-8?q?=EC=A0=95=EC=9D=98=20=ED=95=AD=EB=AA=A9=EC=9D=84=20=EC=82=AC?= =?UTF-8?q?=EC=9A=A9=ED=95=A0=20=EB=95=8C=20=ED=9A=8C=EC=9B=90=20=EA=B0=80?= =?UTF-8?q?=EC=9E=85=20=EB=98=90=EB=8A=94=20=EC=A0=95=EB=B3=B4=EC=88=98?= =?UTF-8?q?=EC=A0=95=EC=9D=84=20=ED=95=A0=20=EC=88=98=20=EC=97=86=EB=8A=94?= =?UTF-8?q?=20=EB=AC=B8=EC=A0=9C=20=EA=B3=A0=EC=B9=A8=20-=20@kijin=20?= =?UTF-8?q?=EB=8B=98=EC=9D=B4=20=EB=AC=B8=EC=A0=9C=EB=A5=BC=20=ED=95=B4?= =?UTF-8?q?=EA=B2=B0=ED=95=B4=EC=A3=BC=EC=85=A8=EC=8A=B5=EB=8B=88=EB=8B=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/member/member.admin.view.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/member/member.admin.view.php b/modules/member/member.admin.view.php index b25579b82..2409e225e 100644 --- a/modules/member/member.admin.view.php +++ b/modules/member/member.admin.view.php @@ -615,7 +615,7 @@ class memberAdminView extends member } $replace = array_merge($extentionReplace, $replace); - $inputTag = preg_replace_callback('@%(\w+)%@', function($n) { return $replace[$n[1]]; }, $template); + $inputTag = preg_replace_callback('@%(\w+)%@', function($n) use($replace) { return $replace[$n[1]]; }, $template); if($extendForm->description) $inputTag .= '

    '.$extendForm->description.'

    '; From c234634029620b3c959d24330829796bbae63427 Mon Sep 17 00:00:00 2001 From: bnu Date: Fri, 19 Feb 2016 18:36:00 +0900 Subject: [PATCH 33/86] version 1.8.17 --- config/config.inc.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config/config.inc.php b/config/config.inc.php index 7d9a78dcf..88c2e510d 100644 --- a/config/config.inc.php +++ b/config/config.inc.php @@ -29,7 +29,7 @@ define('__ZBXE__', __XE__); /** * Display XE's full version. */ -define('__XE_VERSION__', '1.8.16'); +define('__XE_VERSION__', '1.8.17'); define('__XE_VERSION_ALPHA__', (stripos(__XE_VERSION__, 'alpha') !== false)); define('__XE_VERSION_BETA__', (stripos(__XE_VERSION__, 'beta') !== false)); define('__XE_VERSION_RC__', (stripos(__XE_VERSION__, 'rc') !== false)); From 055fd49e4062ce46341ce800f32a4df5050bf7ec Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Sun, 21 Feb 2016 15:08:55 +0900 Subject: [PATCH 34/86] Fix undefined array in ExtraItem class --- classes/extravar/Extravar.class.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/classes/extravar/Extravar.class.php b/classes/extravar/Extravar.class.php index 224de5255..3960d4d94 100644 --- a/classes/extravar/Extravar.class.php +++ b/classes/extravar/Extravar.class.php @@ -224,6 +224,10 @@ class ExtraItem { $values = explode(',', $value); } + else + { + $values = array($value); + } $values = array_values($values); for($i = 0, $c = count($values); $i < $c; $i++) From fab9e43c16b4fb8653f054beeec497374fea2346 Mon Sep 17 00:00:00 2001 From: MinSoo Kim Date: Tue, 23 Feb 2016 01:15:13 +0900 Subject: [PATCH 35/86] Clean up admin i18n css MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit element has the lang attribute as a default. so, we can clean up css files. 요소는 lang 속성을 가지고 있습니다. 이를 이용하면 css 파일을 정리할 수 있습니다. {$lang_type} 에 따른 css 를 불러오도록 HTMLDisplayHandler.php 에 정의되어 있지만, 한국어, 영어 외에는 파일이 존재하지 않습니다. (일본어도 _ja.css 파일은 부재) 언어별로 파일을 만들지 않아도 충분히 표현할 수 있기 때문에 이를 하나의 파일로 합칩니다. --- classes/display/HTMLDisplayHandler.php | 1 - modules/admin/tpl/css/admin.css | 33 +++++++++++++++++++ modules/admin/tpl/css/admin_en.css | 5 --- modules/admin/tpl/css/admin_jp.css | 5 --- modules/admin/tpl/css/admin_ko.css | 5 --- .../tpl/widget_generate_code_in_page.html | 2 -- .../widget_style_generate_code_in_page.html | 2 -- 7 files changed, 33 insertions(+), 20 deletions(-) delete mode 100644 modules/admin/tpl/css/admin_en.css delete mode 100644 modules/admin/tpl/css/admin_jp.css delete mode 100644 modules/admin/tpl/css/admin_ko.css diff --git a/classes/display/HTMLDisplayHandler.php b/classes/display/HTMLDisplayHandler.php index 2254c2694..cf2556c27 100644 --- a/classes/display/HTMLDisplayHandler.php +++ b/classes/display/HTMLDisplayHandler.php @@ -394,7 +394,6 @@ class HTMLDisplayHandler if(Context::get('module') == 'admin' || strpos(Context::get('act'), 'Admin') > 0) { Context::loadFile(array('./modules/admin/tpl/css/admin.css', '', '', 10), true); - Context::loadFile(array("./modules/admin/tpl/css/admin_{$lang_type}.css", '', '', 10), true); Context::loadFile(array("./modules/admin/tpl/css/admin.iefix.css", '', 'ie', 10), true); Context::loadFile('./modules/admin/tpl/js/admin.js', true); Context::loadFile(array('./modules/admin/tpl/css/admin.bootstrap.css', '', '', 1), true); diff --git a/modules/admin/tpl/css/admin.css b/modules/admin/tpl/css/admin.css index b0180e4c0..efe7a46fd 100644 --- a/modules/admin/tpl/css/admin.css +++ b/modules/admin/tpl/css/admin.css @@ -2389,3 +2389,36 @@ html[lang="mn"] .x .g11n.active>[disabled], height: 1px; overflow: hidden; } + +/* language specific styles */ +/* English admin_en.css */ +html:lang(en) body>.x, +html:lang(en) .x table, +html:lang(en) .x input, +html:lang(en) .x textarea, +html:lang(en) .x select, +html:lang(en) .x button{font-family:Arial,Helvetica,sans-serif} +@media all and (max-width:980px){ + html:lang(en) body>.x, + html:lang(en) .x table, + html:lang(en) .x input, + html:lang(en) .x textarea, + html:lang(en) .x select, + html:lang(en) .x button{font-family:sans-serif} +} + +/* Korean admin_ko.css */ +html:lang(ko) body>.x, +html:lang(ko) .x table, +html:lang(ko) .x input, +html:lang(ko) .x textarea, +html:lang(ko) .x select, +html:lang(ko) .x button{font-family:'나눔고딕',NanumGothic,'맑은 고딕','Apple SD Gothic Neo','돋움',Dotum,Arial,Helvetica,sans-serif} + +/* Japanese admin_jp.css */ +html:lang(ja) body>.x, +html:lang(ja) .x table, +html:lang(ja) .x input, +html:lang(ja) .x textarea, +html:lang(ja) .x select, +html:lang(ja) .x button{font-family:'ヒラギノ角ゴ Pro W3','Hiragino Kaku Gothic Pro','メイリオ',Meiryo,'MS Pゴシック',sans-serif} \ No newline at end of file diff --git a/modules/admin/tpl/css/admin_en.css b/modules/admin/tpl/css/admin_en.css deleted file mode 100644 index 6cbb6efe0..000000000 --- a/modules/admin/tpl/css/admin_en.css +++ /dev/null @@ -1,5 +0,0 @@ -@charset "utf-8"; -body>.x,.x table,.x input,.x textarea,.x select,.x button{font-family:Arial,Helvetica,sans-serif} -@media all and (max-width:980px){ -body>.x,.x table,.x input,.x textarea,.x select,.x button{font-family:sans-serif} -} \ No newline at end of file diff --git a/modules/admin/tpl/css/admin_jp.css b/modules/admin/tpl/css/admin_jp.css deleted file mode 100644 index 178114846..000000000 --- a/modules/admin/tpl/css/admin_jp.css +++ /dev/null @@ -1,5 +0,0 @@ -@charset "utf-8"; -body>.x,.x table,.x input,.x textarea,.x select,.x button{font-family:'ヒラギノ角ゴ Pro W3','Hiragino Kaku Gothic Pro','メイリオ',Meiryo,'MS Pゴシック',sans-serif} -@media all and (max-width:980px){ -body>.x,.x table,.x input,.x textarea,.x select,.x button{font-family:'ヒラギノ角ゴ Pro W3','Hiragino Kaku Gothic Pro','メイリオ',Meiryo,'MS Pゴシック',sans-serif} -} \ No newline at end of file diff --git a/modules/admin/tpl/css/admin_ko.css b/modules/admin/tpl/css/admin_ko.css deleted file mode 100644 index d16de3ca5..000000000 --- a/modules/admin/tpl/css/admin_ko.css +++ /dev/null @@ -1,5 +0,0 @@ -@charset "utf-8"; -body>.x,.x table,.x input,.x textarea,.x select,.x button{font-family:나눔고딕,NanumGothic,돋움,Dotum,Arial,Helvetica,sans-serif} -@media all and (max-width:980px){ -body>.x,.x table,.x input,.x textarea,.x select,.x button{font-family:sans-serif} -} \ No newline at end of file diff --git a/modules/widget/tpl/widget_generate_code_in_page.html b/modules/widget/tpl/widget_generate_code_in_page.html index 1780a887d..d6cf20908 100644 --- a/modules/widget/tpl/widget_generate_code_in_page.html +++ b/modules/widget/tpl/widget_generate_code_in_page.html @@ -1,7 +1,5 @@ - - diff --git a/modules/widget/tpl/widget_style_generate_code_in_page.html b/modules/widget/tpl/widget_style_generate_code_in_page.html index ab3d1327e..25c6b0f01 100644 --- a/modules/widget/tpl/widget_style_generate_code_in_page.html +++ b/modules/widget/tpl/widget_style_generate_code_in_page.html @@ -1,7 +1,5 @@ - - From e335aa477e7f35826fb90b25a691b6c5af19bf6b Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Tue, 23 Feb 2016 21:37:44 +0900 Subject: [PATCH 36/86] Initial implementation of blacklist function --- classes/context/Context.class.php | 25 +++++++++++++++++++++++++ common/defaults/blacklist.php | 11 +++++++++++ 2 files changed, 36 insertions(+) create mode 100644 common/defaults/blacklist.php diff --git a/classes/context/Context.class.php b/classes/context/Context.class.php index d3f6914ea..19e321bce 100644 --- a/classes/context/Context.class.php +++ b/classes/context/Context.class.php @@ -157,6 +157,11 @@ class Context */ public $isSuccessInit = TRUE; + /** + * Plugin blacklist cache + */ + private static $_blacklist = null; + /** * Singleton instance * @var object @@ -2566,6 +2571,26 @@ class Context return self::$_instance->allow_rewrite; } + /** + * Check whether an addon, module, or widget is blacklisted + * + * @param string $plugin_name + * @return bool + */ + public static function isBlacklistedPlugin($plugin_name) + { + if (self::$_blacklist === null) + { + self::$_blacklist = (include RX_BASEDIR . 'common/defaults/blacklist.php'); + if (!is_array(self::$_blacklist)) + { + self::$_blacklist = array(); + } + } + + return isset(self::$_blacklist[$plugin_name]); + } + /** * Converts a local path into an URL * diff --git a/common/defaults/blacklist.php b/common/defaults/blacklist.php new file mode 100644 index 000000000..ce91d5571 --- /dev/null +++ b/common/defaults/blacklist.php @@ -0,0 +1,11 @@ + true, + 'zipperupper' => true, +); From e0dba3a340dd05c28bb7ab82f42778eee24c52ea Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Tue, 23 Feb 2016 21:51:18 +0900 Subject: [PATCH 37/86] Do not activate blacklisted addons --- modules/addon/addon.admin.model.php | 14 ++++++++++++-- modules/addon/addon.class.php | 1 - modules/addon/addon.controller.php | 2 +- modules/addon/tpl/addon_list.html | 18 ++++++++++++------ 4 files changed, 25 insertions(+), 10 deletions(-) diff --git a/modules/addon/addon.admin.model.php b/modules/addon/addon.admin.model.php index c49dbabd1..15ae24c50 100644 --- a/modules/addon/addon.admin.model.php +++ b/modules/addon/addon.admin.model.php @@ -46,13 +46,23 @@ class addonAdminModel extends addon $oAutoinstallModel = getModel('autoinstall'); foreach($addonList as $key => $addon) { + // check blacklist + $addonList[$key]->isBlacklisted = Context::isBlacklistedPlugin($addon->addon); + // get easyinstall remove url $packageSrl = $oAutoinstallModel->getPackageSrlByPath($addon->path); $addonList[$key]->remove_url = $oAutoinstallModel->getRemoveUrlByPackageSrl($packageSrl); // get easyinstall need update - $package = $oAutoinstallModel->getInstalledPackages($packageSrl); - $addonList[$key]->need_update = $package[$packageSrl]->need_update; + if($addonList[$key]->isBlacklisted) + { + $addonList[$key]->need_update = 'N'; + } + else + { + $package = $oAutoinstallModel->getInstalledPackages($packageSrl); + $addonList[$key]->need_update = $package[$packageSrl]->need_update; + } // get easyinstall update url if($addonList[$key]->need_update == 'Y') diff --git a/modules/addon/addon.class.php b/modules/addon/addon.class.php index bb605cd77..8eb142106 100644 --- a/modules/addon/addon.class.php +++ b/modules/addon/addon.class.php @@ -19,7 +19,6 @@ class addon extends ModuleObject $oAddonController = getAdminController('addon'); $oAddonController->doInsert('autolink', 0, 'site', 'Y'); $oAddonController->doInsert('blogapi'); - $oAddonController->doInsert('member_communication', 0, 'site', 'Y'); $oAddonController->doInsert('member_extra_info', 0, 'site', 'Y'); $oAddonController->doInsert('mobile', 0, 'site', 'Y'); $oAddonController->doInsert('resize_image', 0, 'site', 'Y'); diff --git a/modules/addon/addon.controller.php b/modules/addon/addon.controller.php index d647f62a2..2fd699187 100644 --- a/modules/addon/addon.controller.php +++ b/modules/addon/addon.controller.php @@ -84,7 +84,7 @@ class addonController extends addon $addon_list = $oAddonModel->getInsertedAddons($site_srl, $gtype); foreach($addon_list as $addon => $val) { - if($val->addon == "smartphone" + if($val->addon == "smartphone" || Context::isBlacklistedPlugin($addon) || ($type == "pc" && $val->is_used != 'Y') || ($type == "mobile" && $val->is_used_m != 'Y') || ($gtype == 'global' && $val->is_fixed != 'Y') diff --git a/modules/addon/tpl/addon_list.html b/modules/addon/tpl/addon_list.html index 11d746c9e..bed17e82a 100644 --- a/modules/addon/tpl/addon_list.html +++ b/modules/addon/tpl/addon_list.html @@ -34,23 +34,29 @@ -

    {$addon->title}

    +

    {$addon->title}

    {$addon->description}

    {$lang->msg_avail_easy_update} {$lang->msg_do_you_like_update}

    - {$addon->version} + {$addon->version} {$author->name} {$author->name} - {$addon->path} - {$lang->cmd_setup} - - + {$addon->path} + + + {$lang->cmd_setup} + + {$lang->cmd_setup} + + + + {$lang->cmd_delete} From 38b7a9201587bc3a033ae186d7c01fec98554564 Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Tue, 23 Feb 2016 21:52:08 +0900 Subject: [PATCH 38/86] Remove [DEPRECATED] message from member_communication addon --- addons/member_communication/conf/info.xml | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/addons/member_communication/conf/info.xml b/addons/member_communication/conf/info.xml index d9419aec7..3ae24aac0 100644 --- a/addons/member_communication/conf/info.xml +++ b/addons/member_communication/conf/info.xml @@ -1,16 +1,16 @@ - [DEPRECATED] 커뮤니케이션 - [DEPRECATED] コミュニケーション - [DEPRECATED] 会员交流 - [DEPRECATED] Communication - [DEPRECATED] Truyền thông - [DEPRECATED] Communication - [DEPRECATED] Communication - [DEPRECATED] Общение - [DEPRECATED] 交流 + 커뮤니케이션 + コミュニケーション + 会员交流 + Communication + Truyền thông + Communication + Communication + Общение + 交流 - [DEPRECATED] 이 애드온은 빈 애드온입니다. 모든 기능은 커뮤니케이션 모듈로 이전되었습니다. + 이 애드온은 빈 애드온입니다. 모든 기능은 커뮤니케이션 모듈로 이전되었습니다. 1.7 2013-11-27 @@ -28,4 +28,4 @@ - \ No newline at end of file + From 18c57787891b1362b84002131bbd4d6e588052f3 Mon Sep 17 00:00:00 2001 From: MinSoo Kim Date: Tue, 23 Feb 2016 21:58:59 +0900 Subject: [PATCH 39/86] =?UTF-8?q?=ED=95=9C=EA=B5=AD=EC=96=B4=20=EA=B8=80?= =?UTF-8?q?=EA=BC=B4=20=EC=9D=B4=EB=A6=84=EC=9D=84=20=EC=95=8C=ED=8C=8C?= =?UTF-8?q?=EB=B2=B3=20=EC=9D=B4=EB=A6=84=EC=9C=BC=EB=A1=9C=20=EB=B3=80?= =?UTF-8?q?=EA=B2=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/admin/tpl/css/admin.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/admin/tpl/css/admin.css b/modules/admin/tpl/css/admin.css index efe7a46fd..a0d16fea2 100644 --- a/modules/admin/tpl/css/admin.css +++ b/modules/admin/tpl/css/admin.css @@ -2413,7 +2413,7 @@ html:lang(ko) .x table, html:lang(ko) .x input, html:lang(ko) .x textarea, html:lang(ko) .x select, -html:lang(ko) .x button{font-family:'나눔고딕',NanumGothic,'맑은 고딕','Apple SD Gothic Neo','돋움',Dotum,Arial,Helvetica,sans-serif} +html:lang(ko) .x button{font-family: 'NanumGothic', 'Malgun Gothic', 'Apple SD Gothic Neo', 'Dotum', Arial, Helvetica, sans-serif} /* Japanese admin_jp.css */ html:lang(ja) body>.x, From 87a3128af643790ddb4465fbdd33d41abfe5284d Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Wed, 24 Feb 2016 09:58:47 +0900 Subject: [PATCH 40/86] Fix #303 Unable to disable rewrite --- classes/context/Context.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/classes/context/Context.class.php b/classes/context/Context.class.php index d3f6914ea..a7f99da66 100644 --- a/classes/context/Context.class.php +++ b/classes/context/Context.class.php @@ -482,7 +482,7 @@ class Context // Copy to old format for backward compatibility. self::$_instance->db_info = self::convertDBInfo($config); - self::$_instance->allow_rewrite = self::$_instance->db_info->use_rewrite; + self::$_instance->allow_rewrite = self::$_instance->db_info->use_rewrite === 'Y'; self::set('_http_port', self::$_instance->db_info->http_port ?: null); self::set('_https_port', self::$_instance->db_info->https_port ?: null); self::set('_use_ssl', self::$_instance->db_info->use_ssl); From 0b339a94502d52cd5f42e8a27394b715320a4fb0 Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Wed, 24 Feb 2016 10:37:16 +0900 Subject: [PATCH 41/86] Fix #277 Incorrect priority when loading old lang files --- common/framework/compat/langparser.php | 2 +- common/framework/lang.php | 12 ++++-------- 2 files changed, 5 insertions(+), 9 deletions(-) diff --git a/common/framework/compat/langparser.php b/common/framework/compat/langparser.php index 6f4c299da..582019c81 100644 --- a/common/framework/compat/langparser.php +++ b/common/framework/compat/langparser.php @@ -70,7 +70,7 @@ class LangParser unset($xml); // Save the array as a cache file. - $buff = " $value) { if (is_array($value)) diff --git a/common/framework/lang.php b/common/framework/lang.php index ae6021a1b..ffbaa86cb 100644 --- a/common/framework/lang.php +++ b/common/framework/lang.php @@ -102,25 +102,21 @@ class Lang { $filename = $dir . '/' . $this->_language . '.php'; } - elseif (file_exists($dir . '/' . ($this->_language === 'ja' ? 'jp' : $this->_language) . '.lang.php')) - { - $filename = $dir . '/' . ($this->_language === 'ja' ? 'jp' : $this->_language) . '.lang.php'; - } elseif (($hyphen = strpos($this->_language, '-')) !== false) { if (file_exists($dir . '/' . substr($this->_language, 0, $hyphen) . '.php')) { $filename = $dir . '/' . substr($this->_language, 0, $hyphen) . '.php'; } - elseif (file_exists($dir . '/' . substr($this->_language, 0, $hyphen) . '.lang.php')) - { - $filename = $dir . '/' . substr($this->_language, 0, $hyphen) . '.lang.php'; - } } elseif (file_exists("$dir/lang.xml")) { $filename = Compat\LangParser::compileXMLtoPHP("$dir/lang.xml", $this->_language === 'ja' ? 'jp' : $this->_language); } + elseif (file_exists($dir . '/' . ($this->_language === 'ja' ? 'jp' : $this->_language) . '.lang.php')) + { + $filename = $dir . '/' . ($this->_language === 'ja' ? 'jp' : $this->_language) . '.lang.php'; + } // Load the language file. if ($filename) From d4a7b921d0ecc667a720ab75952420251180d2f9 Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Thu, 25 Feb 2016 11:26:00 +0900 Subject: [PATCH 42/86] Do not call trigger for blacklisted modules --- classes/module/ModuleHandler.class.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/classes/module/ModuleHandler.class.php b/classes/module/ModuleHandler.class.php index 1567df78b..9feee0660 100644 --- a/classes/module/ModuleHandler.class.php +++ b/classes/module/ModuleHandler.class.php @@ -1191,6 +1191,12 @@ class ModuleHandler extends Handler $type = $item->type; $called_method = $item->called_method; + // do not call if module is blacklisted + if (Context::isBlacklistedPlugin($module)) + { + continue; + } + // todo why don't we call a normal class object ? $oModule = getModule($module, $type); if(!$oModule || !method_exists($oModule, $called_method)) From ac1e86cf3992a224ed96a66de899a6d727ab5347 Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Thu, 25 Feb 2016 14:26:00 +0900 Subject: [PATCH 43/86] Fix incorrect passing of SSL action list --- common/tpl/common_layout.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/tpl/common_layout.html b/common/tpl/common_layout.html index 264683074..d2859c612 100644 --- a/common/tpl/common_layout.html +++ b/common/tpl/common_layout.html @@ -51,7 +51,7 @@ var http_port = {Context::get("_http_port") ?: 'null'}; var https_port = {Context::get("_https_port") ?: 'null'}; var enforce_ssl = {Context::get('_use_ssl') === 'always' ? 'true' : 'false'}; - var ssl_actions = {json_encode(array_values(Context::getSSLActions()))}; + var ssl_actions = {json_encode(array_keys(Context::getSSLActions()))}; var xeVid = {json_encode($vid ?: null)}; From b94027bf1c451857d915fd2fdc4d3d6f78f670af Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Thu, 25 Feb 2016 14:52:07 +0900 Subject: [PATCH 44/86] Display more information if an AJAX request fails --- common/js/xml_handler.js | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/common/js/xml_handler.js b/common/js/xml_handler.js index 2b049bdfe..5d0d9a940 100644 --- a/common/js/xml_handler.js +++ b/common/js/xml_handler.js @@ -134,8 +134,13 @@ // Hide the waiting message and display an error notice. clearTimeout(wfsr_timeout); waiting_obj.hide().trigger("cancel_confirm"); - var error_info = xhr.status + " " + xhr.statusText + " (" + textStatus + ")"; - alert("AJAX communication error while requesting " + params.module + "." + params.act + "\n\n" + error_info); + if ($(".x_modal-body").size()) { + var error_info = xhr.status + " " + xhr.statusText + " (" + textStatus + ")" + "

    " + xhr.responseText + "
    "; + alert("AJAX communication error while requesting " + params.module + "." + params.act + "

    " + error_info); + } else { + var error_info = xhr.status + " " + xhr.statusText + " (" + textStatus + ")" + "\n\n" + xhr.responseText; + alert("AJAX communication error while requesting " + params.module + "." + params.act + "\n\n" + error_info); + } }; // Send the AJAX request. From 4b81e32e22e028e9c76958ae400942e40afb3b45 Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Thu, 25 Feb 2016 15:05:30 +0900 Subject: [PATCH 45/86] Do not display alert if Virtual XML request was successful --- classes/display/VirtualXMLDisplayHandler.php | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/classes/display/VirtualXMLDisplayHandler.php b/classes/display/VirtualXMLDisplayHandler.php index aa67ee21d..0d41f8bbe 100644 --- a/classes/display/VirtualXMLDisplayHandler.php +++ b/classes/display/VirtualXMLDisplayHandler.php @@ -24,11 +24,6 @@ class VirtualXMLDisplayHandler if($error === 0) { - if($message != 'success') - { - $output->message = $message; - } - if($redirect_url) { $output->url = $redirect_url; @@ -40,10 +35,7 @@ class VirtualXMLDisplayHandler } else { - if($message != 'fail') - { - $output->message = $message; - } + $output->message = $message; } $html = array(); @@ -52,12 +44,12 @@ class VirtualXMLDisplayHandler if($output->message) { - $html[] = 'alert("' . $output->message . '");'; + $html[] = 'alert(' . json_encode($output->message) . ');'; } if($output->url) { - $url = preg_replace('/#(.+)$/i', '', $output->url); + $url = preg_replace('/#(.+)$/', '', $output->url); $html[] = 'self.location.href = "' . $request_url . 'common/tpl/redirect.html?redirect_url=' . urlencode($url) . '";'; } $html[] = '//]]>'; From 892aa58540d2480180086ca1cfde9424f0bbe432 Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Thu, 25 Feb 2016 15:11:51 +0900 Subject: [PATCH 46/86] Eliminate redundant redirect through redirect.html --- classes/display/VirtualXMLDisplayHandler.php | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/classes/display/VirtualXMLDisplayHandler.php b/classes/display/VirtualXMLDisplayHandler.php index 0d41f8bbe..124818aaa 100644 --- a/classes/display/VirtualXMLDisplayHandler.php +++ b/classes/display/VirtualXMLDisplayHandler.php @@ -39,8 +39,9 @@ class VirtualXMLDisplayHandler } $html = array(); - $html[] = ''; - + $html[] = ''; + return join(PHP_EOL, $html); } From 134c6f6ec130c36f123ba904f546dd2d939df569 Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Thu, 25 Feb 2016 15:34:02 +0900 Subject: [PATCH 47/86] Fix jshint warnings and also apply patches to exec_json() --- common/js/xml_handler.js | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/common/js/xml_handler.js b/common/js/xml_handler.js index 5d0d9a940..c5a54d6d5 100644 --- a/common/js/xml_handler.js +++ b/common/js/xml_handler.js @@ -134,11 +134,13 @@ // Hide the waiting message and display an error notice. clearTimeout(wfsr_timeout); waiting_obj.hide().trigger("cancel_confirm"); + var error_info; + if ($(".x_modal-body").size()) { - var error_info = xhr.status + " " + xhr.statusText + " (" + textStatus + ")" + "

    " + xhr.responseText + "
    "; + error_info = xhr.status + " " + xhr.statusText + " (" + textStatus + ")" + "

    " + xhr.responseText + "
    "; alert("AJAX communication error while requesting " + params.module + "." + params.act + "

    " + error_info); } else { - var error_info = xhr.status + " " + xhr.statusText + " (" + textStatus + ")" + "\n\n" + xhr.responseText; + error_info = xhr.status + " " + xhr.statusText + " (" + textStatus + ")" + "\n\n" + xhr.responseText; alert("AJAX communication error while requesting " + params.module + "." + params.act + "\n\n" + error_info); } }; @@ -232,8 +234,15 @@ var errorHandler = function(xhr, textStatus) { clearTimeout(wfsr_timeout); waiting_obj.hide().trigger("cancel_confirm"); - var error_info = xhr.status + " " + xhr.statusText + " (" + textStatus + ")"; - alert("AJAX communication error while requesting " + params.module + "." + params.act + "\n\n" + error_info); + var error_info; + + if ($(".x_modal-body").size()) { + error_info = xhr.status + " " + xhr.statusText + " (" + textStatus + ")" + "

    " + xhr.responseText + "
    "; + alert("AJAX communication error while requesting " + params.module + "." + params.act + "

    " + error_info); + } else { + error_info = xhr.status + " " + xhr.statusText + " (" + textStatus + ")" + "\n\n" + xhr.responseText; + alert("AJAX communication error while requesting " + params.module + "." + params.act + "\n\n" + error_info); + } }; // Send the AJAX request. From fd690059ab8413a7b406726954fbf9c030e098c0 Mon Sep 17 00:00:00 2001 From: BJRambo Date: Thu, 25 Feb 2016 16:31:33 +0900 Subject: [PATCH 48/86] =?UTF-8?q?$lang=5Fcode=5Fargs=20=EC=B4=88=EA=B8=B0?= =?UTF-8?q?=ED=99=94=20=ED=95=98=EC=A7=80=20=EC=95=8A=EC=9D=80=20=EB=AC=B8?= =?UTF-8?q?=EC=A0=9C=EC=A0=90=20=EA=B0=9C=EC=84=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/document/document.controller.php | 1 + 1 file changed, 1 insertion(+) diff --git a/modules/document/document.controller.php b/modules/document/document.controller.php index 569cbc022..9b4146aa8 100644 --- a/modules/document/document.controller.php +++ b/modules/document/document.controller.php @@ -647,6 +647,7 @@ class documentController extends document // Change not extra vars but language code of the original document if document's lang_code doesn't exist. if(!$source_obj->get('lang_code')) { + $lang_code_args = new stdClass(); $lang_code_args->document_srl = $source_obj->get('document_srl'); $lang_code_args->lang_code = Context::getLangType(); $output = executeQuery('document.updateDocumentsLangCode', $lang_code_args); From 3d2b3792bff1d489d700c31d879cb4a9cd755bf4 Mon Sep 17 00:00:00 2001 From: BJRambo Date: Thu, 25 Feb 2016 22:32:41 +0900 Subject: [PATCH 49/86] =?UTF-8?q?=EB=B2=88=EC=97=AD=20=EC=98=A4=EB=A5=98?= =?UTF-8?q?=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/member/lang/en.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/member/lang/en.php b/modules/member/lang/en.php index f4c4940cd..e98843ecc 100644 --- a/modules/member/lang/en.php +++ b/modules/member/lang/en.php @@ -206,7 +206,7 @@ $lang->about_profile_image = 'Members will be able to use profile images'; $lang->about_signature_max_height = 'You can limit the signature max height. Set this as 0 or leave it blank not to limit it.'; $lang->about_accept_agreement = 'I have read the agreement and agree with it'; $lang->about_member_default = 'It will be set as the default group on sign up'; -$lang->about_find_member_account = 'lease input the email address you have entered during the registration and we will send your account info to this email address.'; +$lang->about_find_member_account = 'Please input the email address you have entered during the registration and we will send your account info to this email address.'; $lang->about_ssl_port = 'Please enter if you are using non-default SSL port'; $lang->about_resend_auth_mail = 'You can request for the activation email if you have not activated yet.'; $lang->no_article = 'No articles'; From e4077ad324e959a413fed2a4c672043215a840f2 Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Fri, 26 Feb 2016 09:20:35 +0900 Subject: [PATCH 50/86] Add 'smartphone' add-on to common blacklist --- common/defaults/blacklist.php | 1 + modules/addon/addon.controller.php | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/common/defaults/blacklist.php b/common/defaults/blacklist.php index ce91d5571..bcbe7904f 100644 --- a/common/defaults/blacklist.php +++ b/common/defaults/blacklist.php @@ -7,5 +7,6 @@ */ return array( 'member_communication' => true, + 'smartphone' => true, 'zipperupper' => true, ); diff --git a/modules/addon/addon.controller.php b/modules/addon/addon.controller.php index 2fd699187..3eceacc89 100644 --- a/modules/addon/addon.controller.php +++ b/modules/addon/addon.controller.php @@ -1,4 +1,4 @@ - */ /** @@ -84,7 +84,7 @@ class addonController extends addon $addon_list = $oAddonModel->getInsertedAddons($site_srl, $gtype); foreach($addon_list as $addon => $val) { - if($val->addon == "smartphone" || Context::isBlacklistedPlugin($addon) + if(Context::isBlacklistedPlugin($addon) || ($type == "pc" && $val->is_used != 'Y') || ($type == "mobile" && $val->is_used_m != 'Y') || ($gtype == 'global' && $val->is_fixed != 'Y') From 26db6901c30ca642d87647b881301b28286fe57b Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Fri, 26 Feb 2016 09:28:49 +0900 Subject: [PATCH 51/86] Fix typo --- modules/addon/addon.controller.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/addon/addon.controller.php b/modules/addon/addon.controller.php index 3eceacc89..c66e74338 100644 --- a/modules/addon/addon.controller.php +++ b/modules/addon/addon.controller.php @@ -1,4 +1,4 @@ -s */ /** From 74fcee987e31ce7582045fc67c3c572544a78c2d Mon Sep 17 00:00:00 2001 From: BJRambo Date: Fri, 26 Feb 2016 12:01:32 +0900 Subject: [PATCH 52/86] =?UTF-8?q?=EA=B2=8C=EC=8B=9C=EA=B8=80=20=EC=88=98?= =?UTF-8?q?=EC=A0=95=EB=82=B4=EC=97=AD=EC=9D=84=20=EC=A0=80=EC=9E=A5?= =?UTF-8?q?=ED=95=98=EB=8F=84=EB=A1=9D=20=EA=B0=9C=EC=84=A0.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/board/board.controller.php | 5 ++++ modules/board/board.view.php | 18 +++++++++++++ modules/board/conf/module.xml | 1 + modules/board/lang/ko.php | 2 ++ modules/board/skins/xedition/_read.html | 3 ++- modules/board/tpl/board_insert.html | 6 +++++ modules/document/document.controller.php | 26 +++++++++++++++++++ modules/document/queries/insertUpdateLog.xml | 21 +++++++++++++++ .../document/schemas/document_update_list.xml | 16 ++++++++++++ 9 files changed, 97 insertions(+), 1 deletion(-) create mode 100644 modules/document/queries/insertUpdateLog.xml create mode 100644 modules/document/schemas/document_update_list.xml diff --git a/modules/board/board.controller.php b/modules/board/board.controller.php index e1646246c..40fa93cd1 100644 --- a/modules/board/board.controller.php +++ b/modules/board/board.controller.php @@ -147,6 +147,11 @@ class boardController extends board $obj->update_order = $obj->list_order = (getNextSequence() * -1); } + if($this->module_info->update_log == 'Y') + { + $obj->update_log_setting = 'Y'; + } + $output = $oDocumentController->updateDocument($oDocument, $obj); $msg_code = 'success_updated'; diff --git a/modules/board/board.view.php b/modules/board/board.view.php index 015241e69..6cb76b237 100644 --- a/modules/board/board.view.php +++ b/modules/board/board.view.php @@ -1140,6 +1140,24 @@ class boardView extends board $this->setTemplateFile('message'); } + function dispBoardUpdateLog() + { + $document_srl = Context::get('document_srl'); + $logged_info = Context::get('logged_info'); + $oDocumentModel = getModel('document'); + $oDocument = $oDocumentModel->getDocument($document_srl); + + if($logged_info->member_srl != $oDocument->get('member_srl') || !$this->grant->manager) + { + return new Object(-1, 'msg_not_permitted'); + } + + $updatelog = $oDocumentModel->getDocumentUpdateLog($document_srl); + Context::set('updatelog', $updatelog); + + $this->setTemplateFile('update_list'); + } + /** * @brief the method for displaying the warning messages * display an error message if it has not a special design diff --git a/modules/board/conf/module.xml b/modules/board/conf/module.xml index 72002fed7..30e6b92d7 100644 --- a/modules/board/conf/module.xml +++ b/modules/board/conf/module.xml @@ -63,6 +63,7 @@ + diff --git a/modules/board/lang/ko.php b/modules/board/lang/ko.php index ce76b6e86..cc9b914c7 100644 --- a/modules/board/lang/ko.php +++ b/modules/board/lang/ko.php @@ -14,6 +14,7 @@ $lang->consultation = '상담 기능'; $lang->secret = '비밀글 기능'; $lang->thisissecret = '비밀글입니다.'; $lang->admin_mail = '관리자 메일'; +$lang->update_log = '게시글 수정 내역'; $lang->cmd_board_list = '게시판 목록'; $lang->cmd_module_config = '게시판 공통 설정'; $lang->cmd_board_info = '게시판 정보'; @@ -31,6 +32,7 @@ $lang->about_admin_mail = '글이나 댓글이 등록될때 등록된 메일주 $lang->about_list_config = '게시판의 목록형식 사용시 원하는 항목들로 배치를 할 수 있습니다. 단 스킨에서 지원하지 않는 경우 불가능합니다. 대상항목/ 표시항목의 항목을 더블클릭하면 추가/ 제거가 됩니다.'; $lang->about_use_status = '글 작성 시 선택할 수 있는 상태를 지정해주세요.'; $lang->about_protect_comment = '댓글의 댓글이 있을경우 해당댓글을 삭제 및 수정을 할 수 없도록 합니다.'; +$lang->about_update_log = '게시글을 수정할 경우 수정한 내역을 저장하도록 합니다.'; $lang->msg_not_enough_point = '포인트가 부족합니다'; $lang->write_comment = '댓글 쓰기'; $lang->msg_not_allow_comment = '해당 글의 댓글 쓰기가 잠겨있습니다.'; diff --git a/modules/board/skins/xedition/_read.html b/modules/board/skins/xedition/_read.html index 7c3e6030b..4a8cfa54e 100644 --- a/modules/board/skins/xedition/_read.html +++ b/modules/board/skins/xedition/_read.html @@ -114,7 +114,8 @@ Profile
    {$oDocument->getSignature()}
    -
    +
    + {$lang->update_log} {$lang->cmd_modify} {$lang->cmd_delete} diff --git a/modules/board/tpl/board_insert.html b/modules/board/tpl/board_insert.html index ad2e7c176..03e2d7762 100644 --- a/modules/board/tpl/board_insert.html +++ b/modules/board/tpl/board_insert.html @@ -199,6 +199,12 @@
    +
    + +
    + +
    +
    diff --git a/modules/document/document.controller.php b/modules/document/document.controller.php index 569cbc022..34a8baa36 100644 --- a/modules/document/document.controller.php +++ b/modules/document/document.controller.php @@ -683,6 +683,32 @@ class documentController extends document $oDB->rollback(); return $output; } + // update Document Log + else + { + if($obj->update_log_setting === 'Y') + { + $update_args = new stdClass(); + $update_args->document_srl = $obj->document_srl; + $update_args->member_srl = $source_obj->get('member_srl'); + $update_args->module_srl = $source_obj->get('module_srl'); + $update_args->update_member_srl = $logged_info->member_srl; + $update_args->nick_name = $source_obj->get('nick_name'); + $update_args->title = $obj->title; + $update_args->title_bold = $obj->title_bold; + $update_args->title_color = $obj->title_color; + $update_args->content = $obj->content; + $update_args->update_nick_name = $logged_info->nick_name; + $update_args->tags = $obj->tags; + $update_args->extra_vars = $obj->extra_vars; + $update_output = executeQuery('document.insertUpdateLog', $update_args); + if(!$update_output->toBool()) + { + $oDB->rollback(); + return $update_output; + } + } + } // Remove all extra variables if(Context::get('act')!='procFileDelete') { diff --git a/modules/document/queries/insertUpdateLog.xml b/modules/document/queries/insertUpdateLog.xml new file mode 100644 index 000000000..b6a471d84 --- /dev/null +++ b/modules/document/queries/insertUpdateLog.xml @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/modules/document/schemas/document_update_list.xml b/modules/document/schemas/document_update_list.xml new file mode 100644 index 000000000..8aa0cb9d1 --- /dev/null +++ b/modules/document/schemas/document_update_list.xml @@ -0,0 +1,16 @@ +
    + + + + + + + + + + + + + + +
    From 9a60af1871ed71413c36ca71eb6cdd7c00db8dcc Mon Sep 17 00:00:00 2001 From: BJRambo Date: Fri, 26 Feb 2016 13:10:25 +0900 Subject: [PATCH 53/86] =?UTF-8?q?=EB=82=B4=EC=97=AD=EC=9D=84=20=ED=99=95?= =?UTF-8?q?=EC=9D=B8=ED=95=A0=20=EC=88=98=20=EC=9E=88=EB=8F=84=EB=A1=9D=20?= =?UTF-8?q?=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../board/skins/xedition/board.default.css | 13 +++++++++++ modules/board/skins/xedition/update_list.html | 23 +++++++++++++++++++ modules/document/document.controller.php | 10 +++++++- modules/document/document.model.php | 10 ++++++++ .../document/queries/getDocumentUpdateLog.xml | 11 +++++++++ ...ateLog.xml => insertDocumentUpdateLog.xml} | 3 ++- .../document/schemas/document_update_list.xml | 1 + 7 files changed, 69 insertions(+), 2 deletions(-) create mode 100644 modules/board/skins/xedition/update_list.html create mode 100644 modules/document/queries/getDocumentUpdateLog.xml rename modules/document/queries/{insertUpdateLog.xml => insertDocumentUpdateLog.xml} (89%) diff --git a/modules/board/skins/xedition/board.default.css b/modules/board/skins/xedition/board.default.css index 866a9f86f..30022f34c 100644 --- a/modules/board/skins/xedition/board.default.css +++ b/modules/board/skins/xedition/board.default.css @@ -263,6 +263,16 @@ right:0; border-radius: 0 2px 2px 0; } + +.update-log { + width:100%; + border-bottom:1px solid #dbdbdb; + margin: 5px auto 5px auto; + + padding:5px; + +} + /* Board Write */ /* write_form.html */ @@ -463,6 +473,9 @@ white-space: nowrap; color : #666; } +.update-log .read_header .meta { + border-bottom:0; +} .read_header .meta > span { margin-left: 8px ;} .read_header .meta > span:first-child {margin-left:0;} .read_header .meta:after { diff --git a/modules/board/skins/xedition/update_list.html b/modules/board/skins/xedition/update_list.html new file mode 100644 index 000000000..41ab36ec2 --- /dev/null +++ b/modules/board/skins/xedition/update_list.html @@ -0,0 +1,23 @@ + +
    +
    + +
    +

    + {$category_list[$val->category_srl]->title} + {$val->title} +

    +

    + + {zdate($val->regdate,'Y.m.d H:i:s')} + +

    +
    + + +
    + {$val->content} +
    + +
    +
    diff --git a/modules/document/document.controller.php b/modules/document/document.controller.php index 34a8baa36..040891fad 100644 --- a/modules/document/document.controller.php +++ b/modules/document/document.controller.php @@ -689,6 +689,14 @@ class documentController extends document if($obj->update_log_setting === 'Y') { $update_args = new stdClass(); + if($obj->category_srl) + { + $update_args->category_srl = $obj->category_srl; + } + else + { + $update_args->category_srl = $source_obj->get('category_srl'); + } $update_args->document_srl = $obj->document_srl; $update_args->member_srl = $source_obj->get('member_srl'); $update_args->module_srl = $source_obj->get('module_srl'); @@ -701,7 +709,7 @@ class documentController extends document $update_args->update_nick_name = $logged_info->nick_name; $update_args->tags = $obj->tags; $update_args->extra_vars = $obj->extra_vars; - $update_output = executeQuery('document.insertUpdateLog', $update_args); + $update_output = executeQuery('document.insertDocumentUpdateLog', $update_args); if(!$update_output->toBool()) { $oDB->rollback(); diff --git a/modules/document/document.model.php b/modules/document/document.model.php index 2420eebb0..d99046470 100644 --- a/modules/document/document.model.php +++ b/modules/document/document.model.php @@ -1548,6 +1548,16 @@ class documentModel extends document return $document_list; } + + function getDocumentUpdateLog($document_srl) + { + $args = new stdClass(); + $args->document_srl = $document_srl; + $output = executeQueryArray('document.getDocumentUpdateLog', $args); + $update_list = $output->data; + + return $update_list; + } } /* End of file document.model.php */ /* Location: ./modules/document/document.model.php */ diff --git a/modules/document/queries/getDocumentUpdateLog.xml b/modules/document/queries/getDocumentUpdateLog.xml new file mode 100644 index 000000000..379a56e51 --- /dev/null +++ b/modules/document/queries/getDocumentUpdateLog.xml @@ -0,0 +1,11 @@ + + + + + + + + + + + diff --git a/modules/document/queries/insertUpdateLog.xml b/modules/document/queries/insertDocumentUpdateLog.xml similarity index 89% rename from modules/document/queries/insertUpdateLog.xml rename to modules/document/queries/insertDocumentUpdateLog.xml index b6a471d84..c90d898b0 100644 --- a/modules/document/queries/insertUpdateLog.xml +++ b/modules/document/queries/insertDocumentUpdateLog.xml @@ -1,4 +1,4 @@ - +
    @@ -7,6 +7,7 @@ + diff --git a/modules/document/schemas/document_update_list.xml b/modules/document/schemas/document_update_list.xml index 8aa0cb9d1..1a944e88d 100644 --- a/modules/document/schemas/document_update_list.xml +++ b/modules/document/schemas/document_update_list.xml @@ -3,6 +3,7 @@ + From 301861e35a69a6bf6db786ee99495dd9845ca4a8 Mon Sep 17 00:00:00 2001 From: BJRambo Date: Fri, 26 Feb 2016 13:35:41 +0900 Subject: [PATCH 54/86] =?UTF-8?q?=EA=B2=8C=EC=8B=9C=EA=B8=80=20=EB=93=B1?= =?UTF-8?q?=EB=A1=9D=EC=8B=9C=EC=97=90=20=EC=9B=90=EB=B3=B8=EA=B8=80?= =?UTF-8?q?=EC=9D=84=20=EB=93=B1=EB=A1=9D=ED=95=98=EB=8F=84=EB=A1=9D=20?= =?UTF-8?q?=EA=B0=9C=EC=84=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/board/board.controller.php | 10 ++++----- modules/board/lang/ko.php | 3 ++- modules/document/document.controller.php | 27 ++++++++++++++++++++++++ 3 files changed, 34 insertions(+), 6 deletions(-) diff --git a/modules/board/board.controller.php b/modules/board/board.controller.php index 40fa93cd1..f84555fbd 100644 --- a/modules/board/board.controller.php +++ b/modules/board/board.controller.php @@ -106,6 +106,11 @@ class boardController extends board } } + if($this->module_info->update_log == 'Y') + { + $obj->update_log_setting = 'Y'; + } + // update the document if it is existed if($is_update) { @@ -147,11 +152,6 @@ class boardController extends board $obj->update_order = $obj->list_order = (getNextSequence() * -1); } - if($this->module_info->update_log == 'Y') - { - $obj->update_log_setting = 'Y'; - } - $output = $oDocumentController->updateDocument($oDocument, $obj); $msg_code = 'success_updated'; diff --git a/modules/board/lang/ko.php b/modules/board/lang/ko.php index cc9b914c7..91060481e 100644 --- a/modules/board/lang/ko.php +++ b/modules/board/lang/ko.php @@ -54,4 +54,5 @@ $lang->msg_admin_comment_no_modify = '최고관리자의 댓글을 수정할 권 $lang->msg_board_delete_protect_comment = '댓글이 작성된 댓글의 글을 삭제할 수 없습니다.'; $lang->msg_board_update_protect_comment = '댓글이 작성된 댓글의 글을 수정할 수 없습니다.'; $lang->msg_protect_regdate_document = '%s일 이전의 게시글은 수정 또는 삭제 할 수 없습니다.'; -$lang->msg_protect_regdate_comment = '%s일 이전의 댓글은 수정 또는 삭제 할 수 없습니다.'; \ No newline at end of file +$lang->msg_protect_regdate_comment = '%s일 이전의 댓글은 수정 또는 삭제 할 수 없습니다.'; +$lang->original_letter = '원본글'; \ No newline at end of file diff --git a/modules/document/document.controller.php b/modules/document/document.controller.php index 040891fad..31ce0a961 100644 --- a/modules/document/document.controller.php +++ b/modules/document/document.controller.php @@ -438,6 +438,33 @@ class documentController extends document $oDB->rollback(); return $output; } + // update Document Log + else + { + if($obj->update_log_setting === 'Y') + { + $update_args = new stdClass(); + $update_args->category_srl = $obj->category_srl; + $update_args->document_srl = $obj->document_srl; + $update_args->member_srl = $obj->member_srl; + $update_args->module_srl = $obj->module_srl; + $update_args->update_member_srl = $logged_info->member_srl; + $update_args->nick_name = $obj->nick_name; + $update_args->title = $obj->title; + $update_args->title_bold = $obj->title_bold; + $update_args->title_color = $obj->title_color; + $update_args->content = $obj->content.'

    '.Context::getLang('original_letter'); + $update_args->update_nick_name = $logged_info->nick_name; + $update_args->tags = $obj->tags; + $update_args->extra_vars = $obj->extra_vars; + $update_output = executeQuery('document.insertDocumentUpdateLog', $update_args); + if(!$update_output->toBool()) + { + $oDB->rollback(); + return $update_output; + } + } + } // Insert extra variables if the document successfully inserted. $extra_keys = $oDocumentModel->getExtraKeys($obj->module_srl); if(count($extra_keys)) From 16f7a76471e60dfd860cfd1d33c23b9db83502ae Mon Sep 17 00:00:00 2001 From: BJRambo Date: Fri, 26 Feb 2016 13:54:09 +0900 Subject: [PATCH 55/86] =?UTF-8?q?=EC=97=85=EB=8D=B0=EC=9D=B4=ED=8A=B8=20?= =?UTF-8?q?=EC=A0=80=EC=9E=A5=EA=B8=B0=EB=A1=9D=EC=9D=B4=20=EC=97=86?= =?UTF-8?q?=EC=9D=84=EA=B2=BD=EC=9A=B0=20=EC=97=86=EB=8B=A4=EA=B3=A0=20?= =?UTF-8?q?=EC=95=8C=EB=A6=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/board/lang/ko.php | 3 ++- modules/board/skins/xedition/update_list.html | 6 +++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/modules/board/lang/ko.php b/modules/board/lang/ko.php index 91060481e..608af476c 100644 --- a/modules/board/lang/ko.php +++ b/modules/board/lang/ko.php @@ -55,4 +55,5 @@ $lang->msg_board_delete_protect_comment = '댓글이 작성된 댓글의 글을 $lang->msg_board_update_protect_comment = '댓글이 작성된 댓글의 글을 수정할 수 없습니다.'; $lang->msg_protect_regdate_document = '%s일 이전의 게시글은 수정 또는 삭제 할 수 없습니다.'; $lang->msg_protect_regdate_comment = '%s일 이전의 댓글은 수정 또는 삭제 할 수 없습니다.'; -$lang->original_letter = '원본글'; \ No newline at end of file +$lang->msg_dont_have_update_log = '업데이트 로그가 기록되어 있지 않은 게시글입니다.'; +$lang->original_letter = '원본글'; diff --git a/modules/board/skins/xedition/update_list.html b/modules/board/skins/xedition/update_list.html index 41ab36ec2..7d0556244 100644 --- a/modules/board/skins/xedition/update_list.html +++ b/modules/board/skins/xedition/update_list.html @@ -1,5 +1,5 @@ -
    +
    @@ -21,3 +21,7 @@
    + +
    + {$lang->msg_dont_have_update_log} +
    \ No newline at end of file From 940862312011fcca74dbc67630c02ad4c9f97c4d Mon Sep 17 00:00:00 2001 From: BJRambo Date: Fri, 26 Feb 2016 13:54:38 +0900 Subject: [PATCH 56/86] =?UTF-8?q?=EA=B2=8C=EC=8B=9C=EA=B8=80=EC=9D=84=20?= =?UTF-8?q?=EC=82=AD=EC=A0=9C=ED=95=A0=20=EB=95=8C=20=EC=A0=80=EC=9E=A5?= =?UTF-8?q?=EA=B8=B0=EB=A1=9D=EB=8F=84=20=ED=95=A8=EA=BB=98=20=EC=82=AD?= =?UTF-8?q?=EC=A0=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/document/document.controller.php | 6 ++++++ modules/document/queries/deleteDocumentUpdateLog.xml | 8 ++++++++ 2 files changed, 14 insertions(+) create mode 100644 modules/document/queries/deleteDocumentUpdateLog.xml diff --git a/modules/document/document.controller.php b/modules/document/document.controller.php index 31ce0a961..4624d4e01 100644 --- a/modules/document/document.controller.php +++ b/modules/document/document.controller.php @@ -890,6 +890,7 @@ class documentController extends document $this->_deleteDeclaredDocuments($args); $this->_deleteDocumentReadedLog($args); $this->_deleteDocumentVotedLog($args); + $this->_deleteDocumentUpdateLog($args); // Remove the thumbnail file FileHandler::removeDir(sprintf('files/thumbnails/%s',getNumberingPath($document_srl, 3))); @@ -939,6 +940,11 @@ class documentController extends document executeQuery('document.deleteDocumentVotedLog', $documentSrls); } + function _deleteDocumentUpdateLog($document_srl) + { + executeQuery('document.deleteDocumentUpdateLog', $document_srl); + } + /** * Move the doc into the trash * @param object $obj diff --git a/modules/document/queries/deleteDocumentUpdateLog.xml b/modules/document/queries/deleteDocumentUpdateLog.xml new file mode 100644 index 000000000..8856a7712 --- /dev/null +++ b/modules/document/queries/deleteDocumentUpdateLog.xml @@ -0,0 +1,8 @@ + + +
    + + + + + From b392ba70f9bcfaf80228034d223283ad5d2b18ed Mon Sep 17 00:00:00 2001 From: BJRambo Date: Fri, 26 Feb 2016 14:53:50 +0900 Subject: [PATCH 57/86] rename to update log --- .../queries/deleteDocumentUpdateLog.xml | 2 +- .../document/queries/getDocumentUpdateLog.xml | 2 +- .../queries/insertDocumentUpdateLog.xml | 2 +- .../document/schemas/document_update_list.xml | 17 ----------------- .../document/schemas/document_update_log.xml | 17 +++++++++++++++++ 5 files changed, 20 insertions(+), 20 deletions(-) delete mode 100644 modules/document/schemas/document_update_list.xml create mode 100644 modules/document/schemas/document_update_log.xml diff --git a/modules/document/queries/deleteDocumentUpdateLog.xml b/modules/document/queries/deleteDocumentUpdateLog.xml index 8856a7712..6f0ee246c 100644 --- a/modules/document/queries/deleteDocumentUpdateLog.xml +++ b/modules/document/queries/deleteDocumentUpdateLog.xml @@ -1,6 +1,6 @@ -
    +
    diff --git a/modules/document/queries/getDocumentUpdateLog.xml b/modules/document/queries/getDocumentUpdateLog.xml index 379a56e51..161d87b55 100644 --- a/modules/document/queries/getDocumentUpdateLog.xml +++ b/modules/document/queries/getDocumentUpdateLog.xml @@ -1,6 +1,6 @@ -
    +
    diff --git a/modules/document/queries/insertDocumentUpdateLog.xml b/modules/document/queries/insertDocumentUpdateLog.xml index c90d898b0..eef2045ba 100644 --- a/modules/document/queries/insertDocumentUpdateLog.xml +++ b/modules/document/queries/insertDocumentUpdateLog.xml @@ -1,6 +1,6 @@ -
    +
    diff --git a/modules/document/schemas/document_update_list.xml b/modules/document/schemas/document_update_list.xml deleted file mode 100644 index 1a944e88d..000000000 --- a/modules/document/schemas/document_update_list.xml +++ /dev/null @@ -1,17 +0,0 @@ -
    - - - - - - - - - - - - - - - -
    diff --git a/modules/document/schemas/document_update_log.xml b/modules/document/schemas/document_update_log.xml new file mode 100644 index 000000000..92a84f284 --- /dev/null +++ b/modules/document/schemas/document_update_log.xml @@ -0,0 +1,17 @@ + + + + + + + + + + + + + + + + +
    From 379bed000d22304b2a363d08a36c4a656ddc155c Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Fri, 26 Feb 2016 14:58:42 +0900 Subject: [PATCH 58/86] Fix JSON encoding to be fully XE-compatible --- classes/display/JSONDisplayHandler.php | 37 +++++++++++++++++++------- common/js/xml_handler.js | 6 +---- 2 files changed, 28 insertions(+), 15 deletions(-) diff --git a/classes/display/JSONDisplayHandler.php b/classes/display/JSONDisplayHandler.php index 069b6464e..3be23d3d7 100644 --- a/classes/display/JSONDisplayHandler.php +++ b/classes/display/JSONDisplayHandler.php @@ -15,20 +15,37 @@ class JSONDisplayHandler $variables['error'] = $oModule->getError(); $variables['message'] = $oModule->getMessage(); - $temp = array(); - foreach ($variables as $key => $value) + self::_convertCompat($variables, Context::getRequestMethod()); + return json_encode($variables); + } + + /** + * Convert arrays in a format that is compatible with XE. + * + * @param array $array + * @param string $compat_type + * @return array + */ + protected static function _convertCompat(&$array, $compat_type = 'JSON') + { + foreach ($array as $key => &$value) { - if (self::_isNumericArray($value)) + if (is_array($value)) { - $temp[$key] = array_values($value); - } - else - { - $temp[$key] = $value; + self::_convertCompat($value, $compat_type); + if (self::_isNumericArray($value)) + { + if ($compat_type === 'XMLRPC') + { + $value = array('item' => array_values($value)); + } + else + { + $value = array_values($value); + } + } } } - - return json_encode($temp); } /** diff --git a/common/js/xml_handler.js b/common/js/xml_handler.js index c5a54d6d5..0b4f03775 100644 --- a/common/js/xml_handler.js +++ b/common/js/xml_handler.js @@ -69,11 +69,7 @@ var result = {}; $.each(data, function(key, val) { if ($.inArray(key, ["error", "message", "act", "redirect_url"]) >= 0 || $.inArray(key, return_fields) >= 0) { - if ($.isArray(val)) { - result[key] = { item: val }; - } else { - result[key] = val; - } + result[key] = val; } }); From 66b8268df962d3f403f46db7265e6274a2cbd90f Mon Sep 17 00:00:00 2001 From: BJRambo Date: Fri, 26 Feb 2016 15:09:23 +0900 Subject: [PATCH 59/86] add auto_increment db column --- modules/document/schemas/document_update_log.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/modules/document/schemas/document_update_log.xml b/modules/document/schemas/document_update_log.xml index 92a84f284..b0cead1ca 100644 --- a/modules/document/schemas/document_update_log.xml +++ b/modules/document/schemas/document_update_log.xml @@ -1,4 +1,5 @@ + From b3e5596934209f007c4ce4c6c02ad05c899b6ed7 Mon Sep 17 00:00:00 2001 From: BJRambo Date: Fri, 26 Feb 2016 15:14:07 +0900 Subject: [PATCH 60/86] rename update id column --- modules/document/schemas/document_update_log.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/document/schemas/document_update_log.xml b/modules/document/schemas/document_update_log.xml index b0cead1ca..546735298 100644 --- a/modules/document/schemas/document_update_log.xml +++ b/modules/document/schemas/document_update_log.xml @@ -1,5 +1,5 @@
    - + From 226d70a304476d2ecf05c0c598cd62e18ad2a2a3 Mon Sep 17 00:00:00 2001 From: BJRambo Date: Fri, 26 Feb 2016 15:27:35 +0900 Subject: [PATCH 61/86] =?UTF-8?q?=EC=98=A4=ED=83=80=EC=88=98=EC=A0=95.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/member/queries/getMemberModifyNickName.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/member/queries/getMemberModifyNickName.xml b/modules/member/queries/getMemberModifyNickName.xml index 3dea7f6bb..c3162f109 100644 --- a/modules/member/queries/getMemberModifyNickName.xml +++ b/modules/member/queries/getMemberModifyNickName.xml @@ -12,6 +12,6 @@ - + \ No newline at end of file From 705ad34c49bb4f3efa18bbb7fc47780bc2d35046 Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Sat, 27 Feb 2016 14:27:46 +0900 Subject: [PATCH 62/86] Also fix JSON encoding when the result contains objects not arrays --- classes/display/JSONDisplayHandler.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/classes/display/JSONDisplayHandler.php b/classes/display/JSONDisplayHandler.php index 3be23d3d7..7e7fc61a1 100644 --- a/classes/display/JSONDisplayHandler.php +++ b/classes/display/JSONDisplayHandler.php @@ -30,6 +30,10 @@ class JSONDisplayHandler { foreach ($array as $key => &$value) { + if (is_object($value)) + { + $value = get_object_vars($value); + } if (is_array($value)) { self::_convertCompat($value, $compat_type); From 60c46901c6f4ce4e1e64a0d0ac1d2ee621a1fb9b Mon Sep 17 00:00:00 2001 From: conory Date: Mon, 29 Feb 2016 15:53:28 +0900 Subject: [PATCH 63/86] =?UTF-8?q?=EC=95=84=EC=9D=B4=EC=BD=98=20=EC=A4=91?= =?UTF-8?q?=EB=B3=B5=20=EC=84=A4=EC=A0=95=EC=9D=84=20=EC=98=AC=EB=B0=94?= =?UTF-8?q?=EB=A5=B4=EA=B2=8C=20=EA=B3=A0=EC=B9=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- addons/point_level_icon/conf/info.xml | 24 ++++++------------- .../point_level_icon/point_level_icon.lib.php | 8 +++---- 2 files changed, 11 insertions(+), 21 deletions(-) diff --git a/addons/point_level_icon/conf/info.xml b/addons/point_level_icon/conf/info.xml index 6bbe48857..3597262b9 100644 --- a/addons/point_level_icon/conf/info.xml +++ b/addons/point_level_icon/conf/info.xml @@ -62,25 +62,15 @@ - 아이콘 중복 설정 - 아이콘 중복 설정을 적용할 경우 그룹아이콘이 있을때 포인트 레벨 아이콘은 띄우지 않도록 합니다. + 아이콘 중복 방지 + 그룹아이콘이 있을 경우 중복으로 레벨 아이콘을 달지 않습니다. - 적용하지 않음 - 不启用 - 적용하지 않음 - 關閉 - Not apply - Not apply - Không áp dụng + 사용함 + Enabled - - 적용 - 启用 - 적용 - 開啟 - Apply - Apply - Áp dụng + + 사용하지 않음 + Disabled diff --git a/addons/point_level_icon/point_level_icon.lib.php b/addons/point_level_icon/point_level_icon.lib.php index f72b46359..2e6c6ff7c 100644 --- a/addons/point_level_icon/point_level_icon.lib.php +++ b/addons/point_level_icon/point_level_icon.lib.php @@ -13,18 +13,18 @@ function pointLevelIconTrans($matches, $addon_info) return $matches[0]; } - $orig_text = preg_replace('/' . preg_quote($matches[5], '/') . '<\/' . $matches[6] . '>$/', '', $matches[0]); - - if($addon_info->icon_duplication != 'Y') + if($addon_info->icon_duplication != 'N') { // Check Group Image Mark $oMemberModel = getModel('member'); if($oMemberModel->getGroupImageMark($member_srl)) { - return $orig_text . $matches[5] . ''; + return $matches[0]; } } + $orig_text = preg_replace('/' . preg_quote($matches[5], '/') . '<\/' . $matches[6] . '>$/', '', $matches[0]); + if(!isset($GLOBALS['_pointLevelIcon'][$member_srl])) { // Get point configuration From 08f2dcb0be18234dcb42c98ed7ba2642d4f0acbf Mon Sep 17 00:00:00 2001 From: BJRambo Date: Fri, 26 Feb 2016 15:26:49 +0900 Subject: [PATCH 64/86] Add page navigation --- modules/document/queries/getDocumentUpdateLog.xml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/modules/document/queries/getDocumentUpdateLog.xml b/modules/document/queries/getDocumentUpdateLog.xml index 161d87b55..e48e787ee 100644 --- a/modules/document/queries/getDocumentUpdateLog.xml +++ b/modules/document/queries/getDocumentUpdateLog.xml @@ -8,4 +8,10 @@ + + + + + + From 7fa5684af69dd425ab714fa336a7686f80183704 Mon Sep 17 00:00:00 2001 From: BJRambo Date: Tue, 1 Mar 2016 09:50:09 +0900 Subject: [PATCH 65/86] member srl column deleted --- modules/document/queries/insertDocumentUpdateLog.xml | 1 - modules/document/schemas/document_update_log.xml | 1 - 2 files changed, 2 deletions(-) diff --git a/modules/document/queries/insertDocumentUpdateLog.xml b/modules/document/queries/insertDocumentUpdateLog.xml index eef2045ba..087c9150c 100644 --- a/modules/document/queries/insertDocumentUpdateLog.xml +++ b/modules/document/queries/insertDocumentUpdateLog.xml @@ -4,7 +4,6 @@ - diff --git a/modules/document/schemas/document_update_log.xml b/modules/document/schemas/document_update_log.xml index 546735298..aeb89bafe 100644 --- a/modules/document/schemas/document_update_log.xml +++ b/modules/document/schemas/document_update_log.xml @@ -1,7 +1,6 @@
    - From 577ea49b926f958dc3dced5d84fe6ca728ef9b53 Mon Sep 17 00:00:00 2001 From: BJRambo Date: Tue, 1 Mar 2016 09:51:17 +0900 Subject: [PATCH 66/86] add insertDocumentUpdateLog Method --- modules/document/document.controller.php | 79 +++++++++++++----------- 1 file changed, 42 insertions(+), 37 deletions(-) diff --git a/modules/document/document.controller.php b/modules/document/document.controller.php index 4624d4e01..8d9d3bec4 100644 --- a/modules/document/document.controller.php +++ b/modules/document/document.controller.php @@ -443,21 +443,7 @@ class documentController extends document { if($obj->update_log_setting === 'Y') { - $update_args = new stdClass(); - $update_args->category_srl = $obj->category_srl; - $update_args->document_srl = $obj->document_srl; - $update_args->member_srl = $obj->member_srl; - $update_args->module_srl = $obj->module_srl; - $update_args->update_member_srl = $logged_info->member_srl; - $update_args->nick_name = $obj->nick_name; - $update_args->title = $obj->title; - $update_args->title_bold = $obj->title_bold; - $update_args->title_color = $obj->title_color; - $update_args->content = $obj->content.'

    '.Context::getLang('original_letter'); - $update_args->update_nick_name = $logged_info->nick_name; - $update_args->tags = $obj->tags; - $update_args->extra_vars = $obj->extra_vars; - $update_output = executeQuery('document.insertDocumentUpdateLog', $update_args); + $update_output = $this->insertDocumentUpdateLog($obj); if(!$update_output->toBool()) { $oDB->rollback(); @@ -715,28 +701,7 @@ class documentController extends document { if($obj->update_log_setting === 'Y') { - $update_args = new stdClass(); - if($obj->category_srl) - { - $update_args->category_srl = $obj->category_srl; - } - else - { - $update_args->category_srl = $source_obj->get('category_srl'); - } - $update_args->document_srl = $obj->document_srl; - $update_args->member_srl = $source_obj->get('member_srl'); - $update_args->module_srl = $source_obj->get('module_srl'); - $update_args->update_member_srl = $logged_info->member_srl; - $update_args->nick_name = $source_obj->get('nick_name'); - $update_args->title = $obj->title; - $update_args->title_bold = $obj->title_bold; - $update_args->title_color = $obj->title_color; - $update_args->content = $obj->content; - $update_args->update_nick_name = $logged_info->nick_name; - $update_args->tags = $obj->tags; - $update_args->extra_vars = $obj->extra_vars; - $update_output = executeQuery('document.insertDocumentUpdateLog', $update_args); + $update_output = $this->insertDocumentUpdateLog($obj, $source_obj); if(!$update_output->toBool()) { $oDB->rollback(); @@ -807,6 +772,46 @@ class documentController extends document return $output; } + function insertDocumentUpdateLog($obj, $source_obj = null) + { + $update_args = new stdClass(); + $logged_info = Context::get('logged_info'); + if($source_obj === null) + { + $update_args->category_srl = $obj->category_srl; + $update_args->member_srl = $logged_info->member_srl; + $update_args->module_srl = $obj->module_srl; + $update_args->nick_name = $obj->nick_name; + } + else + { + if($obj->category_srl) + { + $update_args->category_srl = $obj->category_srl; + } + else + { + $update_args->category_srl = $source_obj->get('category_srl'); + } + $update_args->member_srl = $source_obj->get('member_srl'); + $update_args->module_srl = $source_obj->get('module_srl'); + $update_args->nick_name = $source_obj->get('nick_name'); + } + + $update_args->document_srl = $obj->document_srl; + $update_args->update_member_srl = $logged_info->member_srl; + $update_args->title = $obj->title; + $update_args->title_bold = $obj->title_bold; + $update_args->title_color = $obj->title_color; + $update_args->content = $obj->content; + $update_args->update_nick_name = $logged_info->nick_name; + $update_args->tags = $obj->tags; + $update_args->extra_vars = $obj->extra_vars; + $update_output = executeQuery('document.insertDocumentUpdateLog', $update_args); + + return $update_output; + } + /** * Deleting Documents * @param int $document_srl From e7b8c1d1df5d42df4f71eb4df8a727c8420752a2 Mon Sep 17 00:00:00 2001 From: BJRambo Date: Tue, 1 Mar 2016 11:04:48 +0900 Subject: [PATCH 67/86] modify DB Queries --- modules/board/board.view.php | 6 +- modules/board/lang/ko.php | 1 + modules/board/skins/xedition/update_list.html | 65 ++++++++++++------- modules/document/document.model.php | 3 +- .../document/queries/getDocumentUpdateLog.xml | 7 +- 5 files changed, 53 insertions(+), 29 deletions(-) diff --git a/modules/board/board.view.php b/modules/board/board.view.php index 6cb76b237..07fd2d8f8 100644 --- a/modules/board/board.view.php +++ b/modules/board/board.view.php @@ -1147,12 +1147,16 @@ class boardView extends board $oDocumentModel = getModel('document'); $oDocument = $oDocumentModel->getDocument($document_srl); - if($logged_info->member_srl != $oDocument->get('member_srl') || !$this->grant->manager) + if($logged_info->member_srl != $oDocument->get('member_srl') && $this->grant->manager !== true) { return new Object(-1, 'msg_not_permitted'); } $updatelog = $oDocumentModel->getDocumentUpdateLog($document_srl); + Context::set('total_count', $updatelog->page_navigation->total_count); + Context::set('total_page', $updatelog->page_navigation->total_page); + Context::set('page', $updatelog->page); + Context::set('page_navigation', $updatelog->page_navigation); Context::set('updatelog', $updatelog); $this->setTemplateFile('update_list'); diff --git a/modules/board/lang/ko.php b/modules/board/lang/ko.php index 608af476c..d29eec6be 100644 --- a/modules/board/lang/ko.php +++ b/modules/board/lang/ko.php @@ -15,6 +15,7 @@ $lang->secret = '비밀글 기능'; $lang->thisissecret = '비밀글입니다.'; $lang->admin_mail = '관리자 메일'; $lang->update_log = '게시글 수정 내역'; +$lang->last_updater = '수정한사람'; $lang->cmd_board_list = '게시판 목록'; $lang->cmd_module_config = '게시판 공통 설정'; $lang->cmd_board_info = '게시판 정보'; diff --git a/modules/board/skins/xedition/update_list.html b/modules/board/skins/xedition/update_list.html index 7d0556244..b629c6bcb 100644 --- a/modules/board/skins/xedition/update_list.html +++ b/modules/board/skins/xedition/update_list.html @@ -1,27 +1,42 @@ -
    -
    - -
    -

    - {$category_list[$val->category_srl]->title} - {$val->title} -

    -

    - - {zdate($val->regdate,'Y.m.d H:i:s')} - -

    -
    - - -
    - {$val->content} -
    - -
    +
    +
    + + + + + + + + + + + + + + + + + + + + + +
    {$lang->title}{$lang->writer}{$lang->last_updater}{$lang->last_post}
    + {$val->title} + + {$val->update_nick_name} + + {$val->nick_name} + + {zdate($val->regdate, 'Y.m.d H:i:s')} +
    {$lang->msg_dont_have_update_log}
    +
    + - -
    - {$lang->msg_dont_have_update_log} -
    \ No newline at end of file diff --git a/modules/document/document.model.php b/modules/document/document.model.php index d99046470..8c7668804 100644 --- a/modules/document/document.model.php +++ b/modules/document/document.model.php @@ -1554,9 +1554,8 @@ class documentModel extends document $args = new stdClass(); $args->document_srl = $document_srl; $output = executeQueryArray('document.getDocumentUpdateLog', $args); - $update_list = $output->data; - return $update_list; + return $output; } } /* End of file document.model.php */ diff --git a/modules/document/queries/getDocumentUpdateLog.xml b/modules/document/queries/getDocumentUpdateLog.xml index e48e787ee..c7ceeedc0 100644 --- a/modules/document/queries/getDocumentUpdateLog.xml +++ b/modules/document/queries/getDocumentUpdateLog.xml @@ -3,7 +3,12 @@ - + + + + + + From 1dcf523450595764ebbf62928efaf65b18242735 Mon Sep 17 00:00:00 2001 From: BJRambo Date: Tue, 1 Mar 2016 11:48:40 +0900 Subject: [PATCH 68/86] add modify permissions --- modules/board/board.view.php | 6 ++---- modules/board/conf/module.xml | 3 +++ 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/modules/board/board.view.php b/modules/board/board.view.php index 07fd2d8f8..22740fa6d 100644 --- a/modules/board/board.view.php +++ b/modules/board/board.view.php @@ -1142,12 +1142,10 @@ class boardView extends board function dispBoardUpdateLog() { - $document_srl = Context::get('document_srl'); - $logged_info = Context::get('logged_info'); $oDocumentModel = getModel('document'); - $oDocument = $oDocumentModel->getDocument($document_srl); + $document_srl = Context::get('document_srl'); - if($logged_info->member_srl != $oDocument->get('member_srl') && $this->grant->manager !== true) + if($this->grant->update_view !== true) { return new Object(-1, 'msg_not_permitted'); } diff --git a/modules/board/conf/module.xml b/modules/board/conf/module.xml index 30e6b92d7..2069ad1e8 100644 --- a/modules/board/conf/module.xml +++ b/modules/board/conf/module.xml @@ -21,6 +21,9 @@ 檢視 görüş + + 수정내역 조회 + 글 작성 发表新主题 From 5d550920ee2edbe6ce217f40756feb085c3c23b8 Mon Sep 17 00:00:00 2001 From: BJRambo Date: Tue, 1 Mar 2016 12:21:25 +0900 Subject: [PATCH 69/86] update template permissions --- modules/board/board.view.php | 2 ++ modules/board/skins/xedition/_read.html | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/modules/board/board.view.php b/modules/board/board.view.php index 22740fa6d..6aa308221 100644 --- a/modules/board/board.view.php +++ b/modules/board/board.view.php @@ -333,6 +333,8 @@ class boardView extends board } } + Context::set('update_view', $this->grant->update_view); + // setup the document oject on context $oDocument->add('module_srl', $this->module_srl); Context::set('oDocument', $oDocument); diff --git a/modules/board/skins/xedition/_read.html b/modules/board/skins/xedition/_read.html index 4a8cfa54e..f0102cb25 100644 --- a/modules/board/skins/xedition/_read.html +++ b/modules/board/skins/xedition/_read.html @@ -115,7 +115,7 @@
    {$oDocument->getSignature()}
    - {$lang->update_log} + {$lang->update_log} {$lang->cmd_modify} {$lang->cmd_delete} From d25432a2c68b03345d5ff63d22830d18d9ddf22c Mon Sep 17 00:00:00 2001 From: BJRambo Date: Tue, 1 Mar 2016 12:29:11 +0900 Subject: [PATCH 70/86] add warning message --- modules/board/lang/ko.php | 1 + modules/board/tpl/board_insert.html | 1 + 2 files changed, 2 insertions(+) diff --git a/modules/board/lang/ko.php b/modules/board/lang/ko.php index d29eec6be..e4be63ea5 100644 --- a/modules/board/lang/ko.php +++ b/modules/board/lang/ko.php @@ -58,3 +58,4 @@ $lang->msg_protect_regdate_document = '%s일 이전의 게시글은 수정 또 $lang->msg_protect_regdate_comment = '%s일 이전의 댓글은 수정 또는 삭제 할 수 없습니다.'; $lang->msg_dont_have_update_log = '업데이트 로그가 기록되어 있지 않은 게시글입니다.'; $lang->original_letter = '원본글'; +$lang->msg_warning_update_log = '주의! 사용시 디비가 많이 늘어날 수 있습니다.'; \ No newline at end of file diff --git a/modules/board/tpl/board_insert.html b/modules/board/tpl/board_insert.html index 03e2d7762..457b8a550 100644 --- a/modules/board/tpl/board_insert.html +++ b/modules/board/tpl/board_insert.html @@ -203,6 +203,7 @@
    +

    {$lang->msg_warning_update_log}

    From acb48cb1d26bad547b3be23cee925aa585646518 Mon Sep 17 00:00:00 2001 From: BJRambo Date: Tue, 1 Mar 2016 12:34:42 +0900 Subject: [PATCH 71/86] enter next line --- modules/board/lang/ko.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/board/lang/ko.php b/modules/board/lang/ko.php index e4be63ea5..289851a1b 100644 --- a/modules/board/lang/ko.php +++ b/modules/board/lang/ko.php @@ -58,4 +58,4 @@ $lang->msg_protect_regdate_document = '%s일 이전의 게시글은 수정 또 $lang->msg_protect_regdate_comment = '%s일 이전의 댓글은 수정 또는 삭제 할 수 없습니다.'; $lang->msg_dont_have_update_log = '업데이트 로그가 기록되어 있지 않은 게시글입니다.'; $lang->original_letter = '원본글'; -$lang->msg_warning_update_log = '주의! 사용시 디비가 많이 늘어날 수 있습니다.'; \ No newline at end of file +$lang->msg_warning_update_log = '주의! 사용시 디비가 많이 늘어날 수 있습니다.'; From 2a824e150c25d7b6828448c97ecaa74e72dd87ca Mon Sep 17 00:00:00 2001 From: BJRambo Date: Tue, 1 Mar 2016 16:32:54 +0900 Subject: [PATCH 72/86] add reason_update DB column. --- modules/board/board.controller.php | 6 ++++-- modules/board/skins/xedition/write_form.html | 7 ++++++- modules/document/document.controller.php | 1 + modules/document/queries/insertDocumentUpdateLog.xml | 1 + modules/document/schemas/document_update_log.xml | 1 + 5 files changed, 13 insertions(+), 3 deletions(-) diff --git a/modules/board/board.controller.php b/modules/board/board.controller.php index f84555fbd..b70f9ee7c 100644 --- a/modules/board/board.controller.php +++ b/modules/board/board.controller.php @@ -151,12 +151,14 @@ class boardController extends board $obj->last_update = $obj->regdate = date('YmdHis'); $obj->update_order = $obj->list_order = (getNextSequence() * -1); } - + $obj->reason_update = escape($obj->reason_update); $output = $oDocumentController->updateDocument($oDocument, $obj); $msg_code = 'success_updated'; // insert a new document otherwise - } else { + } + else + { $output = $oDocumentController->insertDocument($obj, $bAnonymous); $msg_code = 'success_registed'; $obj->document_srl = $output->get('document_srl'); diff --git a/modules/board/skins/xedition/write_form.html b/modules/board/skins/xedition/write_form.html index e9a197a07..edbec4d8b 100644 --- a/modules/board/skins/xedition/write_form.html +++ b/modules/board/skins/xedition/write_form.html @@ -43,6 +43,7 @@ + get('status') == $key || ($key == 'PUBLIC' && !$document_srl))-->checked="checked" /> @@ -66,7 +67,11 @@ - + + + + +
    diff --git a/modules/document/document.controller.php b/modules/document/document.controller.php index b137e8c37..fd4eb9f1d 100644 --- a/modules/document/document.controller.php +++ b/modules/document/document.controller.php @@ -808,6 +808,7 @@ class documentController extends document $update_args->update_nick_name = $logged_info->nick_name; $update_args->tags = $obj->tags; $update_args->extra_vars = $obj->extra_vars; + $update_args->reason_update = $obj->reason_update; $update_output = executeQuery('document.insertDocumentUpdateLog', $update_args); return $update_output; diff --git a/modules/document/queries/insertDocumentUpdateLog.xml b/modules/document/queries/insertDocumentUpdateLog.xml index 087c9150c..921dd1b51 100644 --- a/modules/document/queries/insertDocumentUpdateLog.xml +++ b/modules/document/queries/insertDocumentUpdateLog.xml @@ -16,6 +16,7 @@ + diff --git a/modules/document/schemas/document_update_log.xml b/modules/document/schemas/document_update_log.xml index aeb89bafe..64104396b 100644 --- a/modules/document/schemas/document_update_log.xml +++ b/modules/document/schemas/document_update_log.xml @@ -14,4 +14,5 @@ +
    From d38a4fd987c65e79211bc246c9b8c2e752012a19 Mon Sep 17 00:00:00 2001 From: BJRambo Date: Tue, 1 Mar 2016 17:19:23 +0900 Subject: [PATCH 73/86] Enhanced to create a modified reason. --- modules/board/board.view.php | 15 +++++++++++ modules/board/conf/module.xml | 1 + modules/board/lang/ko.php | 1 + modules/board/skins/xedition/update_list.html | 2 +- modules/board/skins/xedition/update_view.html | 27 +++++++++++++++++++ modules/document/document.model.php | 10 +++++++ modules/document/queries/getUpdateLog.xml | 11 ++++++++ 7 files changed, 66 insertions(+), 1 deletion(-) create mode 100644 modules/board/skins/xedition/update_view.html create mode 100644 modules/document/queries/getUpdateLog.xml diff --git a/modules/board/board.view.php b/modules/board/board.view.php index 6aa308221..54e634521 100644 --- a/modules/board/board.view.php +++ b/modules/board/board.view.php @@ -1162,6 +1162,21 @@ class boardView extends board $this->setTemplateFile('update_list'); } + function dispBoardUpdateLogView() + { + $oDocumentModel = getModel('document'); + $update_id = Context::get('update_id'); + + if($this->grant->update_view !== true) + { + return new Object(-1, 'msg_not_permitted'); + } + $update_log = $oDocumentModel->getUpdateLog($update_id); + Context::set('update_log', $update_log); + + $this->setTemplateFile('update_view'); + } + /** * @brief the method for displaying the warning messages * display an error message if it has not a special design diff --git a/modules/board/conf/module.xml b/modules/board/conf/module.xml index 2069ad1e8..9643ceff0 100644 --- a/modules/board/conf/module.xml +++ b/modules/board/conf/module.xml @@ -77,6 +77,7 @@ + diff --git a/modules/board/lang/ko.php b/modules/board/lang/ko.php index 289851a1b..9f8334b92 100644 --- a/modules/board/lang/ko.php +++ b/modules/board/lang/ko.php @@ -59,3 +59,4 @@ $lang->msg_protect_regdate_comment = '%s일 이전의 댓글은 수정 또는 $lang->msg_dont_have_update_log = '업데이트 로그가 기록되어 있지 않은 게시글입니다.'; $lang->original_letter = '원본글'; $lang->msg_warning_update_log = '주의! 사용시 디비가 많이 늘어날 수 있습니다.'; +$lang->reason_update = '수정한 이유'; diff --git a/modules/board/skins/xedition/update_list.html b/modules/board/skins/xedition/update_list.html index b629c6bcb..09d962bbc 100644 --- a/modules/board/skins/xedition/update_list.html +++ b/modules/board/skins/xedition/update_list.html @@ -12,7 +12,7 @@ - {$val->title} + {$val->title} {$val->update_nick_name} diff --git a/modules/board/skins/xedition/update_view.html b/modules/board/skins/xedition/update_view.html new file mode 100644 index 000000000..7a546b8e3 --- /dev/null +++ b/modules/board/skins/xedition/update_view.html @@ -0,0 +1,27 @@ + +
    +
    + +
    +

    + {$category_list[$update_log->category_srl]->title} + {$update_log->title} +

    +

    + + {zdate($update_log->regdate,'Y.m.d H:i:s')} + +

    +
    + + +
    + {$update_log->content} +
    +
    + {$lang->reason_update} : + {$update_log->reason_update} +
    + +
    +
    diff --git a/modules/document/document.model.php b/modules/document/document.model.php index 8c7668804..673d4f416 100644 --- a/modules/document/document.model.php +++ b/modules/document/document.model.php @@ -1557,6 +1557,16 @@ class documentModel extends document return $output; } + + function getUpdateLog($update_id) + { + $args = new stdClass(); + $args->update_id = $update_id; + $output = exeCuteQuery('document.getUpdateLog', $args); + $updage_log = $output->data; + + return $updage_log; + } } /* End of file document.model.php */ /* Location: ./modules/document/document.model.php */ diff --git a/modules/document/queries/getUpdateLog.xml b/modules/document/queries/getUpdateLog.xml new file mode 100644 index 000000000..daae71601 --- /dev/null +++ b/modules/document/queries/getUpdateLog.xml @@ -0,0 +1,11 @@ + + + + + + + + + + + From 23de45ebefdcce61fdfac28de629e0658319828e Mon Sep 17 00:00:00 2001 From: BJRambo Date: Tue, 1 Mar 2016 17:39:34 +0900 Subject: [PATCH 74/86] tab to space --- modules/document/schemas/document_update_log.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/document/schemas/document_update_log.xml b/modules/document/schemas/document_update_log.xml index 64104396b..85a99283a 100644 --- a/modules/document/schemas/document_update_log.xml +++ b/modules/document/schemas/document_update_log.xml @@ -14,5 +14,5 @@ - +
    From 216da1ed2b6be45319960706ef792c73f9b3226b Mon Sep 17 00:00:00 2001 From: bjrambo Date: Tue, 1 Mar 2016 23:42:41 +0900 Subject: [PATCH 75/86] Don't expose to modify anonymous nickname. --- modules/document/document.controller.php | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/modules/document/document.controller.php b/modules/document/document.controller.php index 9b4146aa8..00f407a18 100644 --- a/modules/document/document.controller.php +++ b/modules/document/document.controller.php @@ -517,6 +517,16 @@ class documentController extends document $oModuleModel = getModel('module'); if(!$obj->module_srl) $obj->module_srl = $source_obj->get('module_srl'); $module_srl = $obj->module_srl; + $module_info = $oModuleModel->getModuleInfoByModuleSrl($module_srl); + if($module_info->use_anonymous == 'Y') + { + $obj->notify_message = 'N'; + $obj->member_srl = -1*$logged_info->member_srl; + $obj->email_address = $obj->homepage = $obj->user_id = ''; + $obj->user_name = $obj->nick_name = 'anonymous'; + debugPrint($obj); + } + $document_config = $oModuleModel->getModulePartConfig('document', $module_srl); if(!$document_config) { @@ -588,7 +598,7 @@ class documentController extends document $obj->password = getModel('member')->hashPassword($obj->password); } // If an author is identical to the modifier or history is used, use the logged-in user's information. - if(Context::get('is_logged')) + if(Context::get('is_logged') && $module_info->use_anonymous != 'Y') { $logged_info = Context::get('logged_info'); if($source_obj->get('member_srl')==$logged_info->member_srl) From 1e14d7219d0a4848d892984223dc8f7a8d2ac803 Mon Sep 17 00:00:00 2001 From: bjrambo Date: Tue, 1 Mar 2016 23:51:48 +0900 Subject: [PATCH 76/86] delete debug code --- modules/document/document.controller.php | 1 - 1 file changed, 1 deletion(-) diff --git a/modules/document/document.controller.php b/modules/document/document.controller.php index 00f407a18..baaceb576 100644 --- a/modules/document/document.controller.php +++ b/modules/document/document.controller.php @@ -524,7 +524,6 @@ class documentController extends document $obj->member_srl = -1*$logged_info->member_srl; $obj->email_address = $obj->homepage = $obj->user_id = ''; $obj->user_name = $obj->nick_name = 'anonymous'; - debugPrint($obj); } $document_config = $oModuleModel->getModulePartConfig('document', $module_srl); From 7a71ac93031a034d7db436a8bbff723c57d11df4 Mon Sep 17 00:00:00 2001 From: bjrambo Date: Wed, 2 Mar 2016 01:04:01 +0900 Subject: [PATCH 77/86] delete unneeded cide. --- modules/document/document.controller.php | 7 ------- 1 file changed, 7 deletions(-) diff --git a/modules/document/document.controller.php b/modules/document/document.controller.php index baaceb576..086b35028 100644 --- a/modules/document/document.controller.php +++ b/modules/document/document.controller.php @@ -518,13 +518,6 @@ class documentController extends document if(!$obj->module_srl) $obj->module_srl = $source_obj->get('module_srl'); $module_srl = $obj->module_srl; $module_info = $oModuleModel->getModuleInfoByModuleSrl($module_srl); - if($module_info->use_anonymous == 'Y') - { - $obj->notify_message = 'N'; - $obj->member_srl = -1*$logged_info->member_srl; - $obj->email_address = $obj->homepage = $obj->user_id = ''; - $obj->user_name = $obj->nick_name = 'anonymous'; - } $document_config = $oModuleModel->getModulePartConfig('document', $module_srl); if(!$document_config) From 34a86defb6161aa5b476f55a83704795b79d6587 Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Wed, 2 Mar 2016 09:40:14 +0900 Subject: [PATCH 78/86] Fix #321 incorrect display of objects in debugPrint() --- common/framework/debug.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/framework/debug.php b/common/framework/debug.php index 0ed9bfb59..ea1dec766 100644 --- a/common/framework/debug.php +++ b/common/framework/debug.php @@ -137,7 +137,7 @@ class Debug $entry = (object)array( 'type' => 'Debug', 'time' => microtime(true), - 'message' => $message, + 'message' => unserialize(serialize($message)), 'file' => isset($backtrace[0]['file']) ? $backtrace[0]['file'] : null, 'line' => isset($backtrace[0]['line']) ? $backtrace[0]['line'] : 0, 'backtrace' => $backtrace, From 39a4c14e7831cd3457c71d8ca70c4ce5aeb39a7e Mon Sep 17 00:00:00 2001 From: BJRambo Date: Thu, 3 Mar 2016 13:56:36 +0900 Subject: [PATCH 79/86] delete member_srl code --- modules/document/document.controller.php | 2 -- 1 file changed, 2 deletions(-) diff --git a/modules/document/document.controller.php b/modules/document/document.controller.php index fd4eb9f1d..ce434b29d 100644 --- a/modules/document/document.controller.php +++ b/modules/document/document.controller.php @@ -780,7 +780,6 @@ class documentController extends document if($source_obj === null) { $update_args->category_srl = $obj->category_srl; - $update_args->member_srl = $logged_info->member_srl; $update_args->module_srl = $obj->module_srl; $update_args->nick_name = $obj->nick_name; } @@ -794,7 +793,6 @@ class documentController extends document { $update_args->category_srl = $source_obj->get('category_srl'); } - $update_args->member_srl = $source_obj->get('member_srl'); $update_args->module_srl = $source_obj->get('module_srl'); $update_args->nick_name = $source_obj->get('nick_name'); } From f847db6ff40cbc9966469ff84ad591208fda475b Mon Sep 17 00:00:00 2001 From: BJRambo Date: Thu, 3 Mar 2016 14:13:48 +0900 Subject: [PATCH 80/86] History logs that adminstrator moves the documents. --- modules/document/document.admin.controller.php | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/modules/document/document.admin.controller.php b/modules/document/document.admin.controller.php index 8e6de0410..f1f77d00b 100644 --- a/modules/document/document.admin.controller.php +++ b/modules/document/document.admin.controller.php @@ -145,11 +145,20 @@ class documentAdminController extends document $obj->module_srl = $module_srl; $obj->category_srl = $category_srl; $output = executeQuery('document.updateDocumentModule', $obj); - if(!$output->toBool()) { + if(!$output->toBool()) + { $oDB->rollback(); return $output; } - + else + { + $update_output = $oDocumentController->insertDocumentUpdateLog($obj); + if(!$update_output->toBool()) + { + $oDB->rollback(); + return $update_output; + } + } //Move a module of the extra vars $output = executeQuery('document.moveDocumentExtraVars', $obj); if(!$output->toBool()) { From 9358b8543994065aadb76e53d17534d897765266 Mon Sep 17 00:00:00 2001 From: BJRambo Date: Fri, 4 Mar 2016 10:40:32 +0900 Subject: [PATCH 81/86] insert extra_vars data --- modules/document/document.controller.php | 61 +++++++++++++----------- 1 file changed, 33 insertions(+), 28 deletions(-) diff --git a/modules/document/document.controller.php b/modules/document/document.controller.php index ce434b29d..08179cda0 100644 --- a/modules/document/document.controller.php +++ b/modules/document/document.controller.php @@ -438,20 +438,8 @@ class documentController extends document $oDB->rollback(); return $output; } - // update Document Log - else - { - if($obj->update_log_setting === 'Y') - { - $update_output = $this->insertDocumentUpdateLog($obj); - if(!$update_output->toBool()) - { - $oDB->rollback(); - return $update_output; - } - } - } // Insert extra variables if the document successfully inserted. + $extra_vars = array(); $extra_keys = $oDocumentModel->getExtraKeys($obj->module_srl); if(count($extra_keys)) { @@ -462,13 +450,20 @@ class documentController extends document { $tmp = $obj->{'extra_vars'.$idx}; if(is_array($tmp)) + { $value = implode('|@|', $tmp); + } else + { $value = trim($tmp); + } + } + else if(isset($obj->{$extra_item->name})) + { + $value = trim($obj->{$extra_item->name}); } - else if(isset($obj->{$extra_item->name})) $value = trim($obj->{$extra_item->name}); if($value == NULL) continue; - + $extra_vars[$extra_item->name] = $value; $this->insertDocumentExtraVar($obj->module_srl, $obj->document_srl, $idx, $value, $extra_item->eid); } } @@ -477,6 +472,16 @@ class documentController extends document // Call a trigger (after) if($output->toBool()) { + if($obj->update_log_setting === 'Y') + { + $obj->extra_vars = serialize($extra_vars); + $update_output = $this->insertDocumentUpdateLog($obj); + if(!$update_output->toBool()) + { + $oDB->rollback(); + return $update_output; + } + } $trigger_output = ModuleHandler::triggerCall('document.insertDocument', 'after', $obj); if(!$trigger_output->toBool()) { @@ -697,20 +702,9 @@ class documentController extends document $oDB->rollback(); return $output; } - // update Document Log - else - { - if($obj->update_log_setting === 'Y') - { - $update_output = $this->insertDocumentUpdateLog($obj, $source_obj); - if(!$update_output->toBool()) - { - $oDB->rollback(); - return $update_output; - } - } - } + // Remove all extra variables + $extra_vars = array(); if(Context::get('act')!='procFileDelete') { $this->deleteDocumentExtraVars($source_obj->get('module_srl'), $obj->document_srl, null, Context::getLangType()); @@ -731,6 +725,7 @@ class documentController extends document } else if(isset($obj->{$extra_item->name})) $value = trim($obj->{$extra_item->name}); if($value == NULL) continue; + $extra_vars[$extra_item->name] = $value; $this->insertDocumentExtraVar($obj->module_srl, $obj->document_srl, $idx, $value, $extra_item->eid); } } @@ -747,6 +742,16 @@ class documentController extends document // Call a trigger (after) if($output->toBool()) { + if($obj->update_log_setting === 'Y') + { + $obj->extra_vars = serialize($extra_vars); + $update_output = $this->insertDocumentUpdateLog($obj, $source_obj); + if(!$update_output->toBool()) + { + $oDB->rollback(); + return $update_output; + } + } $trigger_output = ModuleHandler::triggerCall('document.updateDocument', 'after', $obj); if(!$trigger_output->toBool()) { From 816cc9f8417d0501ae239b06437c50aa2edf8bf7 Mon Sep 17 00:00:00 2001 From: BJRambo Date: Fri, 4 Mar 2016 10:42:35 +0900 Subject: [PATCH 82/86] language setting --- modules/board/skins/xedition/write_form.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/board/skins/xedition/write_form.html b/modules/board/skins/xedition/write_form.html index edbec4d8b..d4dedf200 100644 --- a/modules/board/skins/xedition/write_form.html +++ b/modules/board/skins/xedition/write_form.html @@ -69,7 +69,7 @@ - +
    From 847ed92e1baed9f19ea4ceffce72fa1ef52f0dbf Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Fri, 4 Mar 2016 15:57:21 +0900 Subject: [PATCH 83/86] Fix double escape of document title --- modules/board/skins/default/write_form.html | 2 +- modules/board/skins/xedition/write_form.html | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/board/skins/default/write_form.html b/modules/board/skins/default/write_form.html index f3e13930e..62301dd1a 100644 --- a/modules/board/skins/default/write_form.html +++ b/modules/board/skins/default/write_form.html @@ -10,7 +10,7 @@ {str_repeat("  ",$val->depth)} {$val->title} ({$val->document_count}) - + diff --git a/modules/board/skins/xedition/write_form.html b/modules/board/skins/xedition/write_form.html index e9a197a07..c0ced47e9 100644 --- a/modules/board/skins/xedition/write_form.html +++ b/modules/board/skins/xedition/write_form.html @@ -10,7 +10,7 @@ {str_repeat("  ",$val->depth)} {$val->title} ({$val->document_count}) - + From 4c4df273d1dbd8ae703128b0de5534f0f4fcd25a Mon Sep 17 00:00:00 2001 From: BJRambo Date: Fri, 4 Mar 2016 16:53:13 +0900 Subject: [PATCH 84/86] extra_vars viewer --- modules/board/board.view.php | 3 +++ modules/board/skins/xedition/update_view.html | 8 +++++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/modules/board/board.view.php b/modules/board/board.view.php index 54e634521..1e45f6978 100644 --- a/modules/board/board.view.php +++ b/modules/board/board.view.php @@ -1172,6 +1172,9 @@ class boardView extends board return new Object(-1, 'msg_not_permitted'); } $update_log = $oDocumentModel->getUpdateLog($update_id); + $extra_vars = unserialize($update_log->extra_vars); + + Context::set('extra_vars', $extra_vars); Context::set('update_log', $update_log); $this->setTemplateFile('update_view'); diff --git a/modules/board/skins/xedition/update_view.html b/modules/board/skins/xedition/update_view.html index 7a546b8e3..390c051a2 100644 --- a/modules/board/skins/xedition/update_view.html +++ b/modules/board/skins/xedition/update_view.html @@ -13,15 +13,17 @@

    -
    {$update_log->content}
    -
    +

    + {$key} : {$val} +

    +

    {$lang->reason_update} : {$update_log->reason_update} -

    +

    From f878b012f73270f7a0bc7112e5f45fa6ea9ac500 Mon Sep 17 00:00:00 2001 From: BJRambo Date: Fri, 4 Mar 2016 16:53:52 +0900 Subject: [PATCH 85/86] status update_log settings --- modules/board/skins/xedition/write_form.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/board/skins/xedition/write_form.html b/modules/board/skins/xedition/write_form.html index d4dedf200..9d9cf21ba 100644 --- a/modules/board/skins/xedition/write_form.html +++ b/modules/board/skins/xedition/write_form.html @@ -68,7 +68,7 @@ - + From de98f804a328d77fb0b76f8a78365b30304bc5b7 Mon Sep 17 00:00:00 2001 From: bjrambo Date: Fri, 4 Mar 2016 17:04:34 +0900 Subject: [PATCH 86/86] ignore error_log files by cpanel. --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index 1ab6c7b20..f6d44c481 100644 --- a/.gitignore +++ b/.gitignore @@ -22,4 +22,5 @@ composer.phar *.sublime-workspace *.sublime-project .codeintel +error_log