Ignore:
Timestamp:
2011/02/19 20:54:52 (12 years ago)
Author:
kishida
Message:

#1016 コンテンツ管理リファクタリング

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/version-2_5-dev/data/Smarty/templates/admin/contents/file_manager.tpl

    r20116 r20208  
    3131<form name="form1" method="post" action="?"  enctype="multipart/form-data"> 
    3232<input type="hidden" name="mode" value="" /> 
    33 <input type="hidden" name="now_file" value="<!--{$tpl_now_dir}-->" /> 
     33<input type="hidden" name="now_file" value="<!--{$tpl_now_dir|h}-->" /> 
     34<input type="hidden" name="now_dir" value="<!--{$tpl_now_file|h}-->" /> 
    3435<input type="hidden" name="tree_select_file" value="" /> 
    3536<input type="hidden" name="tree_status" value="" /> 
    3637<input type="hidden" name="select_file" value="" /> 
    3738<div id="admin-contents" class="contents-main"> 
    38 <div id="contents-filemanager-tree"> 
    39   <div id="tree"></div> 
     39    <div id="contents-filemanager-tree"> 
     40      <div id="tree"></div> 
     41    </div> 
     42    <div id="contents-filemanager-right"> 
     43        <table class="now_dir"> 
     44            <tr> 
     45                <th>ファイルのアップロード</th> 
     46                <td> 
     47                    <!--{if $arrErr.upload_file}--><span class="attention"><!--{$arrErr.upload_file}--></span><!--{/if}--> 
     48                    <input type="file" name="upload_file" size="40" <!--{if $arrErr.upload_file}-->style="background-color:<!--{$smarty.const.ERR_COLOR|h}-->"<!--{/if}-->><a class="btn-normal" href="javascript:;" onclick="setTreeStatus('tree_status');fnModeSubmit('upload','',''); return false;">アップロード</a> 
     49                </td> 
     50            </tr> 
     51            <tr> 
     52                <th>フォルダ作成</th> 
     53                <td> 
     54                    <!--{if $arrErr.create_file}--><span class="attention"><!--{$arrErr.create_file}--></span><!--{/if}--> 
     55                    <input type="text" name="create_file" value="" style="width:336px;<!--{if $arrErr.create_file}--> background-color:<!--{$smarty.const.ERR_COLOR|h}--><!--{/if}-->"><a class="btn-normal" href="javascript:;" onclick="setTreeStatus('tree_status');fnModeSubmit('create','',''); return false;">作成</a> 
     56                </td> 
     57            </tr> 
     58        </table> 
     59        <h2><!--{$tpl_now_dir|h}--></h2> 
     60        <table class="list"> 
     61            <tr> 
     62                <th>ファイル名</th> 
     63                <th>サイズ</th> 
     64                <th>更新日付</th> 
     65                <th class="edit">表示</th> 
     66                <th>ダウンロード</th> 
     67                <th class="delete">削除</th> 
     68            </tr> 
     69            <!--{if !$tpl_is_top_dir}--> 
     70                <tr id="parent_dir" onclick="fnSetFormVal('form1', 'select_file', '<!--{$tpl_parent_dir|h}-->');fnSelectFile('parent_dir', '#808080');" onDblClick="setTreeStatus('tree_status');fnDbClick(arrTree, '<!--{$tpl_parent_dir|h}-->', true, '<!--{$tpl_now_dir|h}-->', true)" style=""> 
     71                    <td> 
     72                        <img src="<!--{$TPL_URLPATH}-->img/contents/folder_parent.gif" alt="フォルダ">&nbsp;.. 
     73                    </td> 
     74                    <td>&nbsp;</td> 
     75                    <td>&nbsp;</td> 
     76                    <td>&nbsp;</td> 
     77                    <td>&nbsp;</td> 
     78                    <td>&nbsp;</td> 
     79                </tr> 
     80            <!--{/if}--> 
     81            <!--{section name=cnt loop=$arrFileList}--> 
     82                <!--{assign var="id" value="select_file`$smarty.section.cnt.index`"}--> 
     83                <tr id="<!--{$id}-->" style=""> 
     84                    <td class="file-name" onDblClick="setTreeStatus('tree_status');fnDbClick(arrTree, '<!--{$arrFileList[cnt].file_path|h}-->', <!--{if $arrFileList[cnt].is_dir|h}-->true<!--{else}-->false<!--{/if}-->, '<!--{$tpl_now_dir|h}-->', false)"> 
     85                        <!--{if $arrFileList[cnt].is_dir}--> 
     86                            <img src="<!--{$TPL_URLPATH}-->img/contents/folder_close.gif" alt="フォルダ"> 
     87                        <!--{else}--> 
     88                            <img src="<!--{$TPL_URLPATH}-->img/contents/file.gif"> 
     89                        <!--{/if}--> 
     90                        <!--{$arrFileList[cnt].file_name|h}--> 
     91                    </td> 
     92                    <td class="right"> 
     93                        <!--{$arrFileList[cnt].file_size|number_format}--> 
     94                    </td> 
     95                    <td class="center"> 
     96                        <!--{$arrFileList[cnt].file_time|h}--> 
     97                    </td> 
     98                    <!--{if $arrFileList[cnt].is_dir}--> 
     99                        <td class="center"> 
     100                            <a href="javascript:;" onclick="fnSetFormVal('form1', 'tree_select_file', '<!--{$arrFileList[cnt].file_path}-->');fnSelectFile('<!--{$id}-->', '#808080');fnModeSubmit('move','',''); return false;">表示</a> 
     101                        </td> 
     102                    <!--{else}--> 
     103                        <td class="center"> 
     104                            <a href="javascript:;" onclick="fnSetFormVal('form1', 'select_file', '<!--{$arrFileList[cnt].file_path|h}-->');fnSelectFile('<!--{$id}-->', '#808080');fnModeSubmit('view','',''); return false;">表示</a> 
     105                        </td> 
     106                    <!--{/if}--> 
     107                    <!--{if $arrFileList[cnt].is_dir}--> 
     108                        <!--{* ディレクトリはダウンロード不可 *}--> 
     109                        <td class="center">-</td> 
     110                    <!--{else}--> 
     111                        <td class="center"> 
     112                            <a href="javascript:;" onclick="fnSetFormVal('form1', 'select_file', '<!--{$arrFileList[cnt].file_path|h}-->');fnSelectFile('<!--{$id}-->', '#808080');setTreeStatus('tree_status');fnModeSubmit('download','',''); return false;">ダウンロード</a> 
     113                        </td> 
     114                    <!--{/if}--> 
     115                    <td class="center"> 
     116                        <a href="javascript:;" onclick="fnSetFormVal('form1', 'select_file', '<!--{$arrFileList[cnt].file_path|h}-->');fnSelectFile('<!--{$id}-->', '#808080');setTreeStatus('tree_status');fnModeSubmit('delete','',''); return false;">削除</a> 
     117                    </td> 
     118                </tr> 
     119            <!--{/section}--> 
     120        </table> 
     121    </div> 
    40122</div> 
    41  
    42 <div id="contents-filemanager-right"> 
    43   <table class="now_dir"> 
    44     <tr> 
    45       <th>ファイルのアップロード</th> 
    46       <td> 
    47         <!--{if $arrErr.upload_file}--><span class="attention"><!--{$arrErr.upload_file}--></span><!--{/if}--> 
    48         <input type="file" name="upload_file" size="40" <!--{if $arrErr.upload_file}-->style="background-color:<!--{$smarty.const.ERR_COLOR|h}-->"<!--{/if}-->><a class="btn-normal" href="javascript:;" onclick="setTreeStatus('tree_status');fnModeSubmit('upload','',''); return false;">アップロード</a> 
    49       </td> 
    50     </tr> 
    51     <tr> 
    52       <th>フォルダ作成</th> 
    53       <td> 
    54         <!--{if $arrErr.create_file}--><span class="attention"><!--{$arrErr.create_file}--></span><!--{/if}--> 
    55         <input type="text" name="create_file" value="" style="width:336px;<!--{if $arrErr.create_file}--> background-color:<!--{$smarty.const.ERR_COLOR|h}--><!--{/if}-->"><a class="btn-normal" href="javascript:;" onclick="setTreeStatus('tree_status');fnModeSubmit('create','',''); return false;">作成</a> 
    56       </td> 
    57     </tr> 
    58   </table> 
    59  
    60   <h2><!--{$tpl_now_dir|h}--></h2> 
    61  
    62     <table class="list"> 
    63       <tr> 
    64         <th>ファイル名</th> 
    65         <th>サイズ</th> 
    66         <th>更新日付</th> 
    67         <th class="edit">表示</th> 
    68         <th>ダウンロード</th> 
    69         <th class="delete">削除</th> 
    70       </tr> 
    71       <!--{if !$tpl_is_top_dir}--> 
    72       <tr id="parent_dir" onclick="fnSetFormVal('form1', 'select_file', '<!--{$tpl_parent_dir|h}-->');fnSelectFile('parent_dir', '#808080');" onDblClick="setTreeStatus('tree_status');fnDbClick(arrTree, '<!--{$tpl_parent_dir|h}-->', true, '<!--{$tpl_now_dir|h}-->', true)" style=""> 
    73         <td> 
    74           <img src="<!--{$TPL_URLPATH}-->img/contents/folder_parent.gif" alt="フォルダ">&nbsp;.. 
    75         </td> 
    76         <td>&nbsp;</td> 
    77         <td>&nbsp;</td> 
    78         <td>&nbsp;</td> 
    79         <td>&nbsp;</td> 
    80         <td>&nbsp;</td> 
    81       </tr> 
    82       <!--{/if}--> 
    83       <!--{section name=cnt loop=$arrFileList}--> 
    84       <!--{assign var="id" value="select_file`$smarty.section.cnt.index`"}--> 
    85       <tr id="<!--{$id}-->" style=""> 
    86         <td class="file-name" onDblClick="setTreeStatus('tree_status');fnDbClick(arrTree, '<!--{$arrFileList[cnt].file_path|h}-->', <!--{if $arrFileList[cnt].is_dir|h}-->true<!--{else}-->false<!--{/if}-->, '<!--{$tpl_now_dir|h}-->', false)"> 
    87           <!--{if $arrFileList[cnt].is_dir}--> 
    88           <img src="<!--{$TPL_URLPATH}-->img/contents/folder_close.gif" alt="フォルダ"> 
    89           <!--{else}--> 
    90           <img src="<!--{$TPL_URLPATH}-->img/contents/file.gif"> 
    91           <!--{/if}--> 
    92           <!--{$arrFileList[cnt].file_name|h}--> 
    93         </td> 
    94         <td class="right"><!--{$arrFileList[cnt].file_size|number_format}--></td> 
    95         <td class="center"><!--{$arrFileList[cnt].file_time|h}--></td> 
    96         <td class="center"><a href="javascript:;" onclick="fnSetFormVal('form1', 'select_file', '<!--{$arrFileList[cnt].file_path|h}-->');fnSelectFile('<!--{$id}-->', '#808080');fnModeSubmit('view','',''); return false;">表示</a></td> 
    97         <td class="center"><a href="javascript:;" onclick="fnSetFormVal('form1', 'select_file', '<!--{$arrFileList[cnt].file_path|h}-->');fnSelectFile('<!--{$id}-->', '#808080');setTreeStatus('tree_status');fnModeSubmit('download','',''); return false;">ダウンロード</a></td> 
    98         <td class="center"><a href="javascript:;" onclick="fnSetFormVal('form1', 'select_file', '<!--{$arrFileList[cnt].file_path|h}-->');fnSelectFile('<!--{$id}-->', '#808080');setTreeStatus('tree_status');fnModeSubmit('delete','',''); return false;">削除</a></td> 
    99       </tr> 
    100       <!--{/section}--> 
    101     </table> 
    102   </div> 
    103 </div> 
    104  
    105123</form> 
Note: See TracChangeset for help on using the changeset viewer.