• R/O
  • HTTP
  • SSH
  • HTTPS

magic3: Commit

Cloud computing platform


Commit MetaInfo

Révisionb699cb9fe57a2e4f9b46af11c97aaf4e03e08961 (tree)
l'heure2014-04-23 16:20:10
Auteurnaoki hirata <naoki@magi...>
Commiternaoki hirata

Message de Log

コアファイル管理画面追加。

Change Summary

Modification

--- /dev/null
+++ b/widgets/admin_main/include/container/admin_mainCorefileWidgetContainer.php
@@ -0,0 +1,59 @@
1+<?php
2+/**
3+ * コンテナクラス
4+ *
5+ * PHP versions 5
6+ *
7+ * LICENSE: This source file is licensed under the terms of the GNU General Public License.
8+ *
9+ * @package Magic3 Framework
10+ * @author 平田直毅(Naoki Hirata) <naoki@aplo.co.jp>
11+ * @copyright Copyright 2006-2014 Magic3 Project.
12+ * @license http://www.gnu.org/copyleft/gpl.html GPL License
13+ * @version SVN: $Id$
14+ * @link http://www.magic3.org
15+ */
16+require_once($gEnvManager->getCurrentWidgetContainerPath() . '/admin_mainBaseWidgetContainer.php');
17+
18+class admin_mainCorefileWidgetContainer extends admin_mainBaseWidgetContainer
19+{
20+ private $useBootstrap;
21+
22+ /**
23+ * コンストラクタ
24+ */
25+ function __construct()
26+ {
27+ // 親クラスを呼び出す
28+ parent::__construct();
29+ }
30+ /**
31+ * テンプレートファイルを設定
32+ *
33+ * _assign()でデータを埋め込むテンプレートファイルのファイル名を返す。
34+ * 読み込むディレクトリは、「自ウィジェットディレクトリ/include/template」に固定。
35+ *
36+ * @param RequestManager $request HTTPリクエスト処理クラス
37+ * @param object $param 任意使用パラメータ。そのまま_assign()に渡る
38+ * @return string テンプレートファイル名。テンプレートライブラリを使用しない場合は空文字列「''」を返す。
39+ */
40+ function _setTemplate($request, &$param)
41+ {
42+ return 'corefile.tmpl.html';
43+ }
44+ /**
45+ * テンプレートにデータ埋め込む
46+ *
47+ * _setTemplate()で指定したテンプレートファイルにデータを埋め込む。
48+ *
49+ * @param RequestManager $request HTTPリクエスト処理クラス
50+ * @param object $param 任意使用パラメータ。_setTemplate()と共有。
51+ * @param なし
52+ */
53+ function _assign($request, &$param)
54+ {
55+ // 管理用URL設定
56+ $this->tmpl->addVar("_widget", "admin_url", $this->gEnv->getDefaultAdminUrl());
57+ }
58+}
59+?>
--- /dev/null
+++ b/widgets/admin_main/include/container/admin_mainMenucoreWidgetContainer.php
@@ -0,0 +1,61 @@
1+<?php
2+/**
3+ * コンテナクラス
4+ *
5+ * PHP versions 5
6+ *
7+ * LICENSE: This source file is licensed under the terms of the GNU General Public License.
8+ *
9+ * @package Magic3 Framework
10+ * @author 平田直毅(Naoki Hirata) <naoki@aplo.co.jp>
11+ * @copyright Copyright 2006-2014 Magic3 Project.
12+ * @license http://www.gnu.org/copyleft/gpl.html GPL License
13+ * @version SVN: $Id$
14+ * @link http://www.magic3.org
15+ */
16+require_once($gEnvManager->getCurrentWidgetContainerPath() . '/admin_mainBaseWidgetContainer.php');
17+
18+class admin_mainMenucoreWidgetContainer extends admin_mainBaseWidgetContainer
19+{
20+ private $useBootstrap;
21+
22+ /**
23+ * コンストラクタ
24+ */
25+ function __construct()
26+ {
27+ // 親クラスを呼び出す
28+ parent::__construct();
29+
30+ $this->useBootstrap = $this->gPage->getUseBootstrap();
31+ }
32+ /**
33+ * テンプレートファイルを設定
34+ *
35+ * _assign()でデータを埋め込むテンプレートファイルのファイル名を返す。
36+ * 読み込むディレクトリは、「自ウィジェットディレクトリ/include/template」に固定。
37+ *
38+ * @param RequestManager $request HTTPリクエスト処理クラス
39+ * @param object $param 任意使用パラメータ。そのまま_assign()に渡る
40+ * @return string テンプレートファイル名。テンプレートライブラリを使用しない場合は空文字列「''」を返す。
41+ */
42+ function _setTemplate($request, &$param)
43+ {
44+ return 'menucore.tmpl.html';
45+ }
46+ /**
47+ * テンプレートにデータ埋め込む
48+ *
49+ * _setTemplate()で指定したテンプレートファイルにデータを埋め込む。
50+ *
51+ * @param RequestManager $request HTTPリクエスト処理クラス
52+ * @param object $param 任意使用パラメータ。_setTemplate()と共有。
53+ * @param なし
54+ */
55+ function _assign($request, &$param)
56+ {
57+ // 管理用URL設定
58+ $this->tmpl->addVar("_widget", "admin_url", $this->gEnv->getDefaultAdminUrl());
59+ }
60+}
61+?>
--- a/widgets/admin_main/include/container/admin_mainWidgetContainer.php
+++ b/widgets/admin_main/include/container/admin_mainWidgetContainer.php
@@ -234,8 +234,6 @@ class admin_mainWidgetContainer extends admin_mainBaseWidgetContainer
234234 }
235235 // コンテナを起動
236236 switch ($task){
237- case 'menu': //
238- case 'test': // テスト用画面
239237 case 'top': // トップ画面
240238 case 'userlist': // ユーザリスト
241239 case 'usergroup': // ユーザグループ
@@ -253,7 +251,6 @@ class admin_mainWidgetContainer extends admin_mainBaseWidgetContainer
253251 case 'usercustom': // ユーザ定義値管理
254252 case 'createtable': // テーブル作成
255253 case 'edittable': // テーブル編集
256- case 'editmenu': // メニュー編集
257254 case 'pageinfo': // ページ情報
258255 case 'pageid': // ページID
259256 case 'menuid': // メニューID
@@ -273,6 +270,13 @@ class admin_mainWidgetContainer extends admin_mainBaseWidgetContainer
273270 case 'tenantserver': // テナントサーバ管理
274271 case 'analyzecalc': // アクセス解析集計
275272 case 'analyzegraph': // アクセス解析グラフ表示
273+
274+ // 管理画面の設定用
275+ case 'menu': // 管理画面設定メニュー
276+ case 'menucore': // 管理画面コア設定メニュー
277+ case 'editmenu': // メニュー編集
278+ case 'corefile': // コアファイル編集
279+ case 'test': // テスト用画面
276280 $this->gLaunch->goSubWidget($task);
277281 return false;
278282 case 'logout': // ログアウト処理
--- /dev/null
+++ b/widgets/admin_main/include/template/corefile.tmpl.html
@@ -0,0 +1,22 @@
1+/**
2+ * 表示データ作成用テンプレート(patTemplate)
3+ *
4+ * LICENSE: This source file is licensed under the terms of the GNU General Public License.
5+ *
6+ * @package Magic3 Framework
7+ * @author 平田直毅(Naoki Hirata) <naoki@aplo.co.jp>
8+ * @copyright Copyright 2006-2014 Magic3 Project.
9+ * @license http://www.gnu.org/copyleft/gpl.html GPL License
10+ * @version SVN: $Id$
11+ * @link http://www.magic3.org
12+ */
13+<patTemplate:tmpl name="_widget">
14+<script type="text/javascript">
15+//<![CDATA[
16+$(function(){
17+});
18+//]]>
19+</script>
20+<!-- m3:ErrorMessage -->
21+<h2>コアファイル管理</h2>
22+</patTemplate:tmpl>
\ No newline at end of file
--- /dev/null
+++ b/widgets/admin_main/include/template/menucore.tmpl.html
@@ -0,0 +1,29 @@
1+/**
2+ * 表示データ作成用テンプレート(patTemplate)
3+ *
4+ * LICENSE: This source file is licensed under the terms of the GNU General Public License.
5+ *
6+ * @package Magic3 Framework
7+ * @author 平田直毅(Naoki Hirata) <naoki@aplo.co.jp>
8+ * @copyright Copyright 2006-2014 Magic3 Project.
9+ * @license http://www.gnu.org/copyleft/gpl.html GPL License
10+ * @version SVN: $Id$
11+ * @link http://www.magic3.org
12+ */
13+<patTemplate:tmpl name="_widget">
14+<script type="text/javascript">
15+//<![CDATA[
16+$(function(){
17+ $(document).keyup(function(e){
18+ if (e.which == 27) location.href = '{ADMIN_URL}'; // ESCキー
19+ });
20+});
21+//]]>
22+</script>
23+<div class="panel panel-info" style="width:300px;margin:0 auto;" >
24+ <div class="panel-heading"><span >システムコア制御</span></div>
25+ <ul class="list-group">
26+ <li class="list-group-item"><a href="?task=corefile" ><span >コアファイル管理</span></a></li>
27+ </ul>
28+</div>
29+</patTemplate:tmpl>
--- a/widgets/admin_main/include/template/top.tmpl.html
+++ b/widgets/admin_main/include/template/top.tmpl.html
@@ -24,8 +24,7 @@ function editMenu(){
2424 window.location.href = '{ADMIN_URL}?task=menu';
2525 }
2626 function goCoreMenu(){
27- alert("core");
28- //window.location.href = '{ADMIN_URL}?task=menucore';
27+ window.location.href = '{ADMIN_URL}?task=menucore';
2928 }
3029 $(function(){
3130 // メニュー編集機能キー登録
Afficher sur ancien navigateur de dépôt.