모듈 목록이 나타나는 선택된 게시글 관리 팝업/ 위젯 코드 생성/ 통합검색 관리페이지에서 모듈을 모듈 카테고리로 나눠서 보다 보기 좋게 출력되도록 변경

git-svn-id: http://xe-core.googlecode.com/svn/sandbox@3804 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
zero 2008-02-25 22:11:15 +00:00
parent 2b84ce71fc
commit 657ae432bc
13 changed files with 118 additions and 31 deletions

View file

@ -958,11 +958,14 @@ if(xIE4Up) {
if(!disabled_exists) continue;
sels[i].oldonchange = sels[i].onchange;
sels[i].onchange = function() {
if(this.options[this.selectedIndex].disabled) {
if(this.options.length<=1) this.selectedIndex = -1;
else if(this.selectedIndex < this.options.length - 1) this.selectedIndex++;
else this.selectedIndex--;
} else {
this.oldonchange();
}
}

View file

@ -67,7 +67,7 @@ h3 .gray { color:#9d9d9d;}
.adminTable td textarea { width:98%; height:120px; }
.adminTable td a { color:#555555; text-decoration:none; }
.adminTable td a:hover { text-decoration:underline; }
.adminTable td p, .adminTable td label { color:#AAAAAA; font-size:.9em; margin-top:5px; }
.adminTable td p, .adminTable td label { margin:0; padding:0;color:#AAAAAA; font-size:.9em; margin-top:5px; }
.adminTable td p a, .adminTable td label a { text-decoration:underline; color:#999999; }
.adminTable.counter th { font-size:.9em; text-align:center; padding:0;}

View file

@ -110,9 +110,13 @@
Context::set('document_list', $document_list);
}
// 모듈의 목록을 가져옴
$oModuleModel = &getModel('module');
$module_list = ($oModuleModel->getMidList());
// 모듈 카테고리 목록을 구함
$module_categories = $oModuleModel->getModuleCategories();
// 모듈의 목록을 가져옴
$module_list = $oModuleModel->getMidList();
// 최고 관리자가 아닌 경우 자신의 관리 대상 모듈만 구해옴
$logged_info = Context::get('logged_info');
@ -140,7 +144,19 @@
}
}
}
Context::set('module_list', $module_list);
// module_category와 module의 조합
if($module_categories) {
foreach($module_list as $module_srl => $module) {
$module_categories[$module->module_category_srl]->list[$module_srl] = $module;
}
} else {
$module_categories[0]->list = $module_list;
}
// 모듈 카테고리 목록과 모듈 목록의 조합
Context::set('module_list', $module_categories);
// 팝업 레이아웃 선택
$this->setLayoutPath('./common/tpl');

View file

@ -33,8 +33,15 @@
<th scope="row">{$lang->move_target_module}</th>
<td>
<select id="target_module" name="target_module" class="w300" onchange="doGetCategoryFromModule(this); return false;">
<!--@foreach($module_list as $key => $val)-->
<option value="{$val->module_srl}">{$val->browser_title} ({$val->mid})</option>
<!--@foreach($module_list as $module_category_srl => $modules )-->
<!--@if($modules->title)-->
<option disabled="disabled">{$modules->title}</option>
<!--@else-->
<option disabled="disabled">&nbsp;</option>
<!--@end-->
<!--@foreach($modules->list as $key => $val)-->
<option value="{$val->module_srl}">&nbsp; {$val->browser_title} ({$val->mid})</option>
<!--@end-->
<!--@end-->
</select>
</td>

View file

@ -1,5 +1,5 @@
ul.document_list_box { margin:0; padding:0; list-style:none; }
.document_list_box { height:300px; overflow-y:scroll; overflow-x:hidden;}
.document_list_box { height:230px; overflow-y:scroll; overflow-x:hidden;}
.document_list { margin-top:.5em; overflow:hidden; white-space:nowrap; clear:both;}
.document_list input { float:left; margin-right:10px; }
.document_list address { float:left; width:100px; margin-right:10px; overflow:hidden; white-space:nowrap;}

View file

@ -34,9 +34,22 @@
$skin_list = $oModuleModel->getSkins($this->module_path);
Context::set('skin_list',$skin_list);
// 모듈 카테고리 목록을 구함
$module_categories = $oModuleModel->getModuleCategories();
// 생성된 mid목록을 구함
$mid_list = $oModuleModel->getMidList();
Context::set('mid_list',$mid_list);
// module_category와 module의 조합
if($module_categories) {
foreach($mid_list as $module_srl => $module) {
$module_categories[$module->module_category_srl]->list[$module_srl] = $module;
}
} else {
$module_categories[0]->list = $mid_list;
}
Context::set('mid_list',$module_categories);
// 샘플코드
Context::set('sample_code', htmlspecialchars('<form action="{getUrl()}" method="get"><input type="hidden" name="mid" value="{$mid}" /><input type="hidden" name="act" value="IS" /><input type="text" name="is_keyword" class="inputTypeText" value="{$is_keyword}" /><span class="button"><input type="submit" value="{$lang->cmd_search}" /></span></form>') );

View file

@ -4,17 +4,18 @@
<form action="./" method="get" onsubmit="return procFilter(this, insert_config)">
<table cellspacing="0" class="adminTable">
<col width="150" />
<col width="150" />
<col />
<tr>
<th scope="row">{$lang->sample_code}</th>
<td>
<td colspan="2">
<textarea class="inputTypeTextArea w400" readonly="readonly">{$sample_code}</textarea>
<p>{$lang->about_sample_code}</p>
</td>
</tr>
<tr>
<th scope="row">{$lang->skin}</th>
<td>
<td colspan="2">
<select name="skin">
<!--@foreach($skin_list as $key=>$val)-->
<option value="{$key}" <!--@if($config->skin==$key)-->selected="selected"<!--@end-->>{$val->title}</option>
@ -24,16 +25,30 @@
</td>
</tr>
<tr>
<th scope="row">{$lang->module}</th>
<th colspan="3"><input type="checkbox" onclick="checkboxSelectAll(this.form,'target_mid'); return false;" /> {$lang->about_target_module}</th>
</tr>
<!--@foreach($mid_list as $module_category_srl => $modules)-->
<!--@if($modules->title)-->
<tr>
<th rowspan="{count($modules->list)+1}">{$modules->title}</th>
</tr>
<!--@else-->
<tr>
<th rowspan="{count($modules->list)+1}">&nbsp;</th>
</tr>
<!--@end-->
<!--@foreach($modules->list as $key => $val)-->
<tr>
<td>{$val->module}</td>
<td>
<p><input type="checkbox" onclick="checkboxSelectAll(this.form,'target_mid'); return false;" /> {$lang->about_target_module}</p>
<!--@foreach($mid_list as $key => $val)-->
<p><input type="checkbox" name="target_mid" value="{$key}" id="target_mid_{$key}" <!--@if(in_array($key,$config->target_mid))-->checked="checked"<!--@end--> /> <label for="target_mid_{$key}">{$val->browser_title} ({$val->mid})</label></p>
<!--@end-->
<input type="checkbox" name="target_mid" value="{$key}" id="target_mid_{$key}" <!--@if(in_array($key,$config->target_mid))-->checked="checked"<!--@end--> />
<label for="target_mid_{$key}">{$val->browser_title} ({$val->mid})</label>
</td>
</tr>
<!--@end-->
<!--@end-->
<tr>
<th scope="row" class="button" colspan="2">
<th scope="row" class="button" colspan="3">
<span class="button"><input type="submit" value="{$lang->cmd_registration}" accesskey="s" /></span>
</th>
</tr>

View file

@ -11,6 +11,6 @@
<condition operation="in" column="module_srl" var="module_srls" pipe="and" />
</conditions>
<navigation>
<index var="sort_index" default="mid" order="asc" />
<index var="sort_index" default="browser_title" order="asc" />
</navigation>
</query>

View file

@ -2,5 +2,7 @@
<tables>
<table name="module_categories" />
</tables>
<columns />
<navigation>
<index var="sort_index" default="title" order="asc" />
</navigation>
</query>

View file

@ -1,6 +1,7 @@
@charset "utf-8";
.widget_mid_list { margin-bottom:.3em; }
.widget_title { border:1px solid #DDDDDD; margin:10px 5px 5px 0; padding:3px; }
.widget_mid_list { margin:0 0 5px 10px; }
#colorset_area { margin-top:.5em; }

View file

@ -72,11 +72,18 @@
</select>
<!--@elseif($var->type == "mid_list")-->
<!--@foreach($mid_list as $key => $val)-->
<div class="widget_mid_list">
<input type="checkbox" value="{$key}" name="{$id}" id="chk_mid_list_{$key}" />
<label for="chk_mid_list_{$key}">{$key} ({$val->browser_title})</label>
</div>
<!--@foreach($mid_list as $module_category_srl => $modules)-->
<!--@if($modules->title)-->
<div class="widget_title">{$modules->title}</div>
<!--@end-->
<!--@foreach($modules->list as $key => $val)-->
<div class="widget_mid_list">
<input type="checkbox" value="{$key}" name="{$id}" id="chk_mid_list_{$key}" />
<label for="chk_mid_list_{$key}">{$key} ({$val->browser_title})</label>
</div>
<!--@end-->
<!--@end-->
<!--@end-->
<p class="clear">{nl2br($var->description)}</p>

View file

@ -78,12 +78,21 @@
</select>
<!--@elseif($var->type == "mid_list")-->
<!--@foreach($mid_list as $key => $val)-->
<div class="widget_mid_list">
<input type="checkbox" value="{$key}" name="{$id}" id="chk_mid_list_{$key}" />
<label for="chk_mid_list_{$key}">{$key} ({$val->browser_title})</label>
</div>
<!--@foreach($mid_list as $module_category_srl => $modules)-->
<!--@if($modules->title)-->
<div class="widget_title">{$modules->title}</div>
<!--@end-->
<!--@foreach($modules->list as $key => $val)-->
<div class="widget_mid_list">
<input type="checkbox" value="{$key}" name="{$id}" id="chk_mid_list_{$key}" />
<label for="chk_mid_list_{$key}">{$key} ({$val->browser_title})</label>
</div>
<!--@end-->
<!--@end-->
<!--@end-->
<p class="clear">{nl2br($var->description)}</p>
</td>

View file

@ -39,10 +39,24 @@
$widget_info = $oWidgetModel->getWidgetInfo(Context::get('selected_widget'));
Context::set('widget_info', $widget_info);
// mid 목록을 가져옴
$oModuleModel = &getModel('module');
// 모듈 카테고리 목록을 구함
$module_categories = $oModuleModel->getModuleCategories();
// mid 목록을 가져옴
$mid_list = $oModuleModel->getMidList();
Context::set('mid_list', $mid_list);
// module_category와 module의 조합
if($module_categories) {
foreach($mid_list as $module_srl => $module) {
$module_categories[$module->module_category_srl]->list[$module_srl] = $module;
}
} else {
$module_categories[0]->list = $mid_list;
}
Context::set('mid_list',$module_categories);
// 스킨의 정보를 구함
$skin_list = $oModuleModel->getSkins($widget_info->path);