#328 상품문의에 비밀글 추가

This commit is contained in:
chicpro
2013-11-21 15:07:14 +09:00
parent 2a6ceabe9e
commit 9f9f581f11
11 changed files with 172 additions and 69 deletions

View File

@ -16,6 +16,8 @@ $w = escape_trim($_REQUEST['w']);
$it_id = escape_trim($_REQUEST['it_id']);
$iq_id = escape_trim($_REQUEST['iq_id']);
$chk_secret = '';
if ($w == "u")
{
$qa = sql_fetch(" select * from {$g5['g5_shop_item_qa_table']} where iq_id = '$iq_id' ");
@ -28,6 +30,9 @@ if ($w == "u")
if (!$iq_admin && $qa['mb_id'] != $member['mb_id']) {
alert_close("자신의 상품문의만 수정이 가능합니다.");
}
if($qa['iq_secret'])
$chk_secret = 'checked="checked"';
}
include_once(G5_PATH.'/head.sub.php');

View File

@ -26,6 +26,7 @@ if ($w == "")
$sql = "insert {$g5['g5_shop_item_qa_table']}
set it_id = '$it_id',
mb_id = '{$member['mb_id']}',
iq_secret = '$iq_secret',
iq_name = '$iq_name',
iq_password = '$iq_password',
iq_subject = '$iq_subject',
@ -47,7 +48,8 @@ else if ($w == "u")
}
$sql = " update {$g5['g5_shop_item_qa_table']}
set iq_subject = '$iq_subject',
set iq_secret = '$iq_secret',
iq_subject = '$iq_subject',
iq_question = '$iq_question'
where iq_id = '$iq_id' ";
sql_query($sql);