mobile skin 적용중
This commit is contained in:
@ -5,10 +5,6 @@ include_once('./_common.php');
|
||||
|
||||
auth_check($auth[$sub_menu], 'w');
|
||||
|
||||
function b_draw($pos, $color='red') {
|
||||
return "border-{$pos}-width:1px; border-{$pos}-color:{$color}; border-{$pos}-style:solid; ";
|
||||
}
|
||||
|
||||
$sql = " select count(*) as cnt from {$g4['group_table']} ";
|
||||
$row = sql_fetch($sql);
|
||||
if (!$row['cnt'])
|
||||
@ -113,6 +109,22 @@ include_once ('./admin.head.php');
|
||||
<input type="text" id="bo_subject" name="bo_subject" maxlength="120" class="required" value="<?=get_text($board['bo_subject'])?>" size="80" required="required">
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row"><label for="bo_use">사용여부</label></th>
|
||||
<td>
|
||||
<?=help("게시판그룹의 사용여부 설정이 게시판의 사용여부 설정보다 우선합니다.")?>
|
||||
<select id="bo_use_" name="bo_use">
|
||||
<option value="both" <?=get_selected($board['bo_use'], 'both', true);?>>PC와 모바일에서 모두 사용</option>
|
||||
<option value="pc" <?=get_selected($board['bo_use'], 'pc');?>>PC 전용</option>
|
||||
<option value="mobile" <?=get_selected($board['bo_use'], 'mobile');?>>모바일 전용</option>
|
||||
<option value="none" <?=get_selected($board['bo_use'], 'none');?>>사용하지 않음</option>
|
||||
</select>
|
||||
</td>
|
||||
<td class="group_setting">
|
||||
<input type="checkbox" id="chk_use" name="chk_use" value="1">
|
||||
<label for="chk_use">동일그룹 모두 적용</label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row"><label for="bo_category_list">분류</label></th>
|
||||
<td>
|
||||
|
||||
@ -53,6 +53,7 @@ $bo_category_list = str_replace($src_char, $dst_char, $bo_category_list);
|
||||
|
||||
$sql_common = " gr_id = '{$_POST['gr_id']}',
|
||||
bo_subject = '{$_POST['bo_subject']}',
|
||||
bo_use = '{$_POST['bo_use']}',
|
||||
bo_admin = '{$_POST['bo_admin']}',
|
||||
bo_list_level = '{$_POST['bo_list_level']}',
|
||||
bo_read_level = '{$_POST['bo_read_level']}',
|
||||
@ -210,6 +211,7 @@ if ($w == '') {
|
||||
|
||||
// 같은 그룹내 게시판 동일 옵션 적용
|
||||
$fields = "";
|
||||
if (is_checked('chk_use')) $fields .= " , bo_use = '{$bo_use}' ";
|
||||
if (is_checked('chk_admin')) $fields .= " , bo_admin = '{$bo_admin}' ";
|
||||
if (is_checked('chk_list_level')) $fields .= " , bo_list_level = '{$bo_list_level}' ";
|
||||
if (is_checked('chk_read_level')) $fields .= " , bo_read_level = '{$bo_read_level}' ";
|
||||
@ -274,10 +276,7 @@ for ($i=1; $i<=10; $i++) {
|
||||
}
|
||||
|
||||
if ($fields) {
|
||||
$sql = " update {$g4['board_table']}
|
||||
set bo_table = bo_table
|
||||
{$fields}
|
||||
where gr_id = '$gr_id' ";
|
||||
$sql = " update {$g4['board_table']} set bo_table = bo_table {$fields} where gr_id = '$gr_id' ";
|
||||
sql_query($sql);
|
||||
}
|
||||
|
||||
|
||||
@ -4,6 +4,15 @@ include_once('./_common.php');
|
||||
|
||||
auth_check($auth[$sub_menu], 'r');
|
||||
|
||||
if (!isset($board['bo_use'])) {
|
||||
// 게시판 사용 필드 추가
|
||||
// both : pc, mobile 둘다 사용
|
||||
// pc : pc 전용 사용
|
||||
// mobile : mobile 전용 사용
|
||||
// none : 사용 안함
|
||||
sql_query(" ALTER TABLE `{$g4['board_table']}` ADD `bo_use` ENUM( 'both', 'pc', 'mobile', 'none' ) NOT NULL DEFAULT 'both' AFTER `bo_subject` ", false);
|
||||
}
|
||||
|
||||
$sql_common = " from {$g4['board_table']} a ";
|
||||
$sql_search = " where (1) ";
|
||||
|
||||
@ -108,6 +117,7 @@ var list_delete_php = 'board_list_delete.php';
|
||||
<th scope="col"><?=subject_sort_link('bo_subject')?>제목</a></th>
|
||||
<th scope="col">포인트</th>
|
||||
<th scope="col">검색</th>
|
||||
<th scope="col"><?=subject_sort_link('bo_use')?>사용여부</a></th>
|
||||
<th scope="col">관리</th>
|
||||
</tr>
|
||||
</thead>
|
||||
@ -136,7 +146,7 @@ for ($i=0; $row=sql_fetch_array($result); $i++) {
|
||||
<td>
|
||||
<?=get_skin_select("board", "bo_skin_$i", "bo_skin[$i]", $row['bo_skin']);?>
|
||||
</td>
|
||||
<td><input type="text" id="bo_subject[<?=$i?>]" name="bo_subject[<?=$i?>]" class="required" value="<?=get_text($row['bo_subject'])?>" title="게시판제목" size="20" required="required"></td>
|
||||
<td><input type="text" id="bo_subject_<?=$i?>" name="bo_subject[<?=$i?>]" class="required" value="<?=get_text($row['bo_subject'])?>" title="게시판제목" size="20" required="required"></td>
|
||||
<td>
|
||||
<label for="bo_read_point_<?=$i?>">읽기</label>
|
||||
<input type="text" id="bo_read_point_<?=$i?>" name="bo_read_point[<?=$i?>]" value="<?=$row['bo_read_point']?>" size="2">
|
||||
@ -153,6 +163,14 @@ for ($i=0; $row=sql_fetch_array($result); $i++) {
|
||||
<label for="bo_order_search_<?=$i?>">순서</label>
|
||||
<input type="text" id="bo_order_search_<?=$i?>" name="bo_order_search[<?=$i?>]" value="<?=$row['bo_order_search']?>" size="1">
|
||||
</td>
|
||||
<td>
|
||||
<select id="bo_use_<?=$i?>" name="bo_use[<?=$i?>]">
|
||||
<option value="both" <?=get_selected($row['bo_use'], 'both', true);?>>양쪽</option>
|
||||
<option value="pc" <?=get_selected($row['bo_use'], 'pc');?>>PC</option>
|
||||
<option value="mobile" <?=get_selected($row['bo_use'], 'mobile');?>>모바일</option>
|
||||
<option value="none" <?=get_selected($row['bo_use'], 'none');?>>미사용</option>
|
||||
</select>
|
||||
</td>
|
||||
<td><?=$one_update?> <?=$one_copy?></td>
|
||||
</tr>
|
||||
<?
|
||||
|
||||
@ -30,6 +30,7 @@ if ($_POST['btn_submit'] == "선택수정") {
|
||||
$sql = " update {$g4['board_table']}
|
||||
set gr_id = '{$_POST['gr_id'][$k]}',
|
||||
bo_subject = '{$_POST['bo_subject'][$k]}',
|
||||
bo_use = '{$_POST['bo_use'][$k]}',
|
||||
bo_skin = '{$_POST['bo_skin'][$k]}',
|
||||
bo_read_point = '{$_POST['bo_read_point'][$k]}',
|
||||
bo_write_point = '{$_POST['bo_write_point'][$k]}',
|
||||
|
||||
@ -7,14 +7,11 @@ auth_check($auth[$sub_menu], 'w');
|
||||
if ($is_admin != 'super' && $w == '') alert('최고관리자만 접근 가능합니다.');
|
||||
|
||||
$html_title = '게시판그룹';
|
||||
if ($w == '')
|
||||
{
|
||||
if ($w == '') {
|
||||
$gr_id_attr = 'required';
|
||||
$gr['gr_use_access'] = 0;
|
||||
$html_title .= ' 생성';
|
||||
}
|
||||
else if ($w == 'u')
|
||||
{
|
||||
} else if ($w == 'u') {
|
||||
$gr_id_attr = 'readonly style="background-color:#dddddd"';
|
||||
$gr = sql_fetch(" select * from {$g4['group_table']} where gr_id = '$gr_id' ");
|
||||
$html_title .= ' 수정';
|
||||
@ -50,6 +47,18 @@ include_once('./admin.head.php');
|
||||
?>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row"><label for="gr_use">사용여부</label></th>
|
||||
<td>
|
||||
<?=help("게시판그룹의 사용여부 설정이 게시판의 사용여부 설정보다 우선합니다.")?>
|
||||
<select id="gr_use_" name="gr_use">
|
||||
<option value="both" <?=get_selected($group['gr_use'], 'both', true);?>>PC와 모바일에서 모두 사용</option>
|
||||
<option value="pc" <?=get_selected($group['gr_use'], 'pc');?>>PC 전용</option>
|
||||
<option value="mobile" <?=get_selected($group['gr_use'], 'mobile');?>>모바일 전용</option>
|
||||
<option value="none" <?=get_selected($group['gr_use'], 'none');?>>사용하지 않음</option>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row"><label for="gr_admin">그룹 관리자</label></th>
|
||||
<td>
|
||||
|
||||
@ -4,6 +4,15 @@ include_once('./_common.php');
|
||||
|
||||
auth_check($auth[$sub_menu], 'r');
|
||||
|
||||
if (!isset($group['gr_use'])) {
|
||||
// 게시판 그룹 사용 필드 추가
|
||||
// both : pc, mobile 둘다 사용
|
||||
// pc : pc 전용 사용
|
||||
// mobile : mobile 전용 사용
|
||||
// none : 사용 안함
|
||||
sql_query(" ALTER TABLE `{$g4['board_group_table']}` ADD `gr_use` ENUM( 'both', 'pc', 'mobile', 'none' ) NOT NULL DEFAULT 'both' AFTER `gr_subject` ", false);
|
||||
}
|
||||
|
||||
$sql_common = " from {$g4['group_table']} ";
|
||||
|
||||
$sql_search = " where (1) ";
|
||||
@ -29,10 +38,7 @@ if ($sst)
|
||||
else
|
||||
$sql_order = " order by gr_id asc ";
|
||||
|
||||
$sql = " select count(*) as cnt
|
||||
{$sql_common}
|
||||
{$sql_search}
|
||||
{$sql_order} ";
|
||||
$sql = " select count(*) as cnt {$sql_common} {$sql_search} {$sql_order} ";
|
||||
$row = sql_fetch($sql);
|
||||
$total_count = $row['cnt'];
|
||||
|
||||
@ -41,11 +47,7 @@ $total_page = ceil($total_count / $rows); // 전체 페이지 계산
|
||||
if (!$page) $page = 1; // 페이지가 없으면 첫 페이지 (1 페이지)
|
||||
$from_record = ($page - 1) * $rows; // 시작 열을 구함
|
||||
|
||||
$sql = " select *
|
||||
{$sql_common}
|
||||
{$sql_search}
|
||||
{$sql_order}
|
||||
limit {$from_record}, {$rows} ";
|
||||
$sql = " select * {$sql_common} {$sql_search} {$sql_order} limit {$from_record}, {$rows} ";
|
||||
$result = sql_query($sql);
|
||||
|
||||
$listall = '';
|
||||
@ -110,6 +112,7 @@ var list_update_php = "./boardgroup_list_update.php";
|
||||
<th scope="col">게시판</th>
|
||||
<th scope="col">접근사용</th>
|
||||
<th scope="col">접근회원수</th>
|
||||
<th scope="col"><?=subject_sort_link('gr_use')?>사용여부</a></th>
|
||||
<th scope="col">관리</th>
|
||||
</tr>
|
||||
</thead>
|
||||
@ -151,6 +154,14 @@ for ($i=0; $row=sql_fetch_array($result); $i++)
|
||||
<td><a href="./board_list.php?sfl=a.gr_id&stx=<?=$row['gr_id']?>"><?=$row2['cnt']?></a></td>
|
||||
<td><input type="checkbox" id="gr_use_access" name="gr_use_access[<?=$i?>]" <?=$row['gr_use_access']?'checked':''?> value="1" title="선택 시 접근회원 사용"></td>
|
||||
<td><a href="./boardgroupmember_list.php?gr_id=<?=$row['gr_id']?>"><?=$row1['cnt']?></a></td>
|
||||
<td>
|
||||
<select id="gr_use_<?=$i?>" name="gr_use[<?=$i?>]">
|
||||
<option value="both" <?=get_selected($row['gr_use'], 'both', true);?>>양쪽</option>
|
||||
<option value="pc" <?=get_selected($row['gr_use'], 'pc');?>>PC</option>
|
||||
<option value="mobile" <?=get_selected($row['gr_use'], 'mobile');?>>모바일</option>
|
||||
<option value="none" <?=get_selected($row['gr_use'], 'none');?>>미사용</option>
|
||||
</select>
|
||||
</td>
|
||||
<td class="td_mng"><?=$s_upd?> <?=$s_del?></td>
|
||||
</tr>
|
||||
|
||||
|
||||
@ -13,6 +13,7 @@ for ($i=0; $i<count($_POST['chk']); $i++)
|
||||
|
||||
$sql = " update {$g4['group_table']}
|
||||
set gr_subject = '{$_POST['gr_subject'][$k]}',
|
||||
gr_use = '{$_POST['gr_use'][$k]}',
|
||||
gr_admin = '{$_POST['gr_admin'][$k]}',
|
||||
gr_use_access = '{$_POST['gr_use_access'][$k]}'
|
||||
where gr_id = '{$_POST['gr_id'][$k]}' ";
|
||||
|
||||
Reference in New Issue
Block a user