diff --git a/css/user_info.css b/css/user_info.css index 436f22b8..92665087 100644 --- a/css/user_info.css +++ b/css/user_info.css @@ -81,168 +81,8 @@ height:20px; } -#EntranceManage_00 { - width: 500px; height: 409px; - z-index: 2; -} - -#EntranceManage_0000 { - width: 498px; height: 50px; -} - -#EntranceManage_0001 { - width: 100px; height: 30px; -} - -#EntranceManage_0002 { - width: 498px; height: 25px; -} - -#EntranceManage_0003 { - width: 98px; height: 84px; - line-height: 84px; -} - -#EntranceManage_0004 { - width: 148px; height: 84px; - line-height: 84px; -} - -#EntranceManage_0005 { - width: 98px; height: 84px; - line-height: 84px; -} - -#EntranceManage_0006 { - width: 148px; height: 84px; - text-align: left; -} - -#EntranceManage_000600 { - width: 80px; height: 17px; -} - -#EntranceManage_000601 { - width: 80px; height: 17px; -} - -#EntranceManage_000602 { - width: 80px; height: 17px; -} - -#EntranceManage_000603 { - width: 144px; height: 20px; -} - -#EntranceManage_0007 { - width: 98px; height: 64px; - line-height: 64px; -} - -#EntranceManage_0008 { - width: 148px; height: 64px; - line-height: 64px; -} - -#EntranceManage_0009 { - width: 98px; height: 64px; - line-height: 64px; -} - -#EntranceManage_0010 { - width: 148px; height: 64px; - line-height: 64px; -} - -#EntranceManage_0011 { - width: 98px; height: 20px; -} - -#EntranceManage_0012 { - width: 148px; height: 20px; -} - -#EntranceManage_0013 { - width: 248px; height: 20px; -} - -#EntranceManage_0014 { - width: 98px; height: 64px; - line-height: 64px; -} - -#EntranceManage_0015 { - width: 148px; height: 64px; -} - -#EntranceManage_001500 { - width: 64px; height: 64px; -} - -#EntranceManage_001501 { - width: 64px; height: 64px; -} - -#EntranceManage_0016 { - width: 248px; height: 64px; -} - -#EntranceManage_001600 { - width: 100px; height: 16px; - display: none; -} - -#EntranceManage_001601 { - width: 70px; height: 20px; -} - -#EntranceManage_001602 { - width: 85px; height: 20px; -} - -#EntranceManage_001603 { - width: 85px; height: 20px; -} - -#EntranceManage_0017 { - width: 98px; height: 100px; - line-height: 100px; -} - -#EntranceManage_0018 { - width: 398px; height: 100px; - text-align: left; -} - -#EntranceManage_0019 { - width: 149px; height: 20px; -} - -#EntranceManage_0020 { - width: 500px; height: 20px; - border: none; -} - -#EntranceManage_002000 { - width: 500px; -} - -#EntranceManage_00200000 { - width: 498px; height: 20px; -} - -.EntranceManage_Sequence { - width: 48px; height: 20px; -} - -.EntranceManage_Date { - width: 148px; height: 20px; -} - -.EntranceManage_Amount { - width: 148px; height: 20px; -} - -.EntranceManage_Cumul { - width: 148px; height: 20px; -} +#third_use_disallow{ + display:none; + margin-left:10px; + width:40px; +} \ No newline at end of file diff --git a/i_entrance/j_disallow_third_use.php b/i_entrance/j_disallow_third_use.php new file mode 100644 index 00000000..4d15f83b --- /dev/null +++ b/i_entrance/j_disallow_third_use.php @@ -0,0 +1,17 @@ +setReadOnly(); +$userID = Session::getUserID(); + +$db = RootDB::db(); +$db->update('member', [ + 'third_use'=>0 +], 'no=%i', $userID); + +Json::die([ + 'result'=>true, + 'reason'=>'success' +]); \ No newline at end of file diff --git a/i_entrance/j_get_user_info.php b/i_entrance/j_get_user_info.php index f42e1674..7b755ebd 100644 --- a/i_entrance/j_get_user_info.php +++ b/i_entrance/j_get_user_info.php @@ -9,7 +9,7 @@ $userID = Session::getUserID(); // 외부 파라미터 $db = RootDB::db(); -$member = $db->queryFirstRow('SELECT `id`, `name`, `grade`, `picture` FROM `member` WHERE `NO` = %i', $userID); +$member = $db->queryFirstRow('SELECT `id`, `name`, `grade`, `picture`, reg_date, third_use FROM `member` WHERE `NO` = %i', $userID); if(!$member['picture']){ $picture = ServConfig::getSharedIconPath().'/default.jpg'; @@ -49,5 +49,7 @@ Json::die([ 'name'=>$member['name'], 'grade'=>$grade, 'picture'=>$picture, - 'global_salt'=>RootDB::getGlobalSalt() + 'global_salt'=>RootDB::getGlobalSalt(), + 'join_date'=>$member['reg_date'], + 'third_use'=>($member['third_use']!=0) ]); diff --git a/i_entrance/user_info.html b/i_entrance/user_info.html index 46cd745c..9519f960 100644 --- a/i_entrance/user_info.html +++ b/i_entrance/user_info.html @@ -55,6 +55,13 @@ + + 가입일시 + + + + 개인정보 3자 제공 동의 : + 회원 탈퇴 diff --git a/js/user_info.js b/js/user_info.js index a3119784..f825f1df 100644 --- a/js/user_info.js +++ b/js/user_info.js @@ -14,6 +14,11 @@ function fillUserInfo(result){ $('#slot_grade').html(result.grade); $('#slot_icon').attr('src', result.picture); $('#global_salt').val(result.global_salt); + $('#slot_join_date').html(result.join_date); + $('#slot_third_use').html(result.third_use?'○':'×'); + if(result.third_use){ + $('#third_use_disallow').show(); + } } function changeIconPreview(){ @@ -66,6 +71,20 @@ function deleteIcon(){ }); } +function disallowThirdUse(){ + $.ajax({ + type:'post', + url:'j_disallow_third_use.php', + dataType:'json' + }).then(function(result){ + alert('철회했습니다.'); + location.reload(); + },function(){ + alert('알 수 없는 이유로 철회를 실패했습니다.'); + location.reload(); + }); +} + function changeIcon(e){ e.preventDefault(); var $icon = $('#image_upload'); @@ -219,6 +238,12 @@ $(function(){ return false; }); + $('#third_use_disallow').click(function(){ + if(confirm('개인정보 3자 제공 동의를 철회할까요?')){ + disallowThirdUse(); + } + }); + $('#change_pw_form').submit(changePassword); $('#change_icon_form').submit(changeIcon);