#190 장바구니 mb_id 필드 추가

This commit is contained in:
chicpro
2013-05-30 18:23:47 +09:00
parent 5fb54c91eb
commit 6d25ac9fd4
10 changed files with 38 additions and 11 deletions

View File

@ -21,12 +21,11 @@ include_once(G4_ADMIN_PATH.'/admin.head.php');
//------------------------------------------------------------------------------
// 설정 시간이 지난 주문서 없는 장바구니 자료 삭제
//------------------------------------------------------------------------------
if (!isset($cart_not_delete)) {
if (!$hours) $hours = 6;
$beforehours = date("Y-m-d H:i:s", ( G4_SERVER_TIME - (60 * 60 * $hours) ) );
$sql = " delete from {$g4['shop_cart_table']} where ct_status = '$cart_title1' and ct_time <= '$beforehours' ";
sql_query($sql);
}
$keep_term = $default['de_cart_keep_term'];
if (!$keep_term) $keep_term = 15; // 기본값 15일
$beforetime = date('Y-m-d H:i:s', ( G4_SERVER_TIME - (86400 * $keep_term) ) );
$sql = " delete from {$g4['shop_cart_table']} where ct_status = '$cart_title1' and ct_time <= '$beforetime' ";
sql_query($sql);
//------------------------------------------------------------------------------