주문폼에서 쿠폰 적용 레이어에서 불필요한 태그가 남아있는 현상 수정
This commit is contained in:
@ -120,10 +120,10 @@ if($w == '') {
|
|||||||
$sql = " select * from {$g5['g5_shop_coupon_zone_table']} where cz_id = '$cz_id' ";
|
$sql = " select * from {$g5['g5_shop_coupon_zone_table']} where cz_id = '$cz_id' ";
|
||||||
$cp = sql_fetch($sql);
|
$cp = sql_fetch($sql);
|
||||||
|
|
||||||
if(!$cp['cz_id'])
|
if(! (isset($cp['cz_id']) && $cp['cz_id']))
|
||||||
alert('쿠폰정보가 존재하지 않습니다.', './couponzonelist.php');
|
alert('쿠폰정보가 존재하지 않습니다.', './couponzonelist.php');
|
||||||
|
|
||||||
if ($_POST['cp_img_del'] && $cp['cz_file']) {
|
if ((isset($_POST['cp_img_del']) && $_POST['cp_img_del']) && $cp['cz_file']) {
|
||||||
@unlink(G5_DATA_PATH."/coupon/{$cp['cz_file']}");
|
@unlink(G5_DATA_PATH."/coupon/{$cp['cz_file']}");
|
||||||
$cp['cz_file'] = '';
|
$cp['cz_file'] = '';
|
||||||
}
|
}
|
||||||
|
|||||||
@ -866,6 +866,9 @@ $(function() {
|
|||||||
});
|
});
|
||||||
|
|
||||||
$("#od_coupon_btn").click(function() {
|
$("#od_coupon_btn").click(function() {
|
||||||
|
if( $("#od_coupon_frm").parent(".od_coupon_wrap").length ){
|
||||||
|
$("#od_coupon_frm").parent(".od_coupon_wrap").remove();
|
||||||
|
}
|
||||||
$("#od_coupon_frm").remove();
|
$("#od_coupon_frm").remove();
|
||||||
var $this = $(this);
|
var $this = $(this);
|
||||||
var price = parseInt($("input[name=org_od_price]").val()) - parseInt($("input[name=item_coupon]").val());
|
var price = parseInt($("input[name=org_od_price]").val()) - parseInt($("input[name=item_coupon]").val());
|
||||||
@ -913,6 +916,9 @@ $(function() {
|
|||||||
$("#od_cp_price").text(number_format(String(price)));
|
$("#od_cp_price").text(number_format(String(price)));
|
||||||
$("#sc_cp_price").text(0);
|
$("#sc_cp_price").text(0);
|
||||||
calculate_order_price();
|
calculate_order_price();
|
||||||
|
if( $("#od_coupon_frm").parent(".od_coupon_wrap").length ){
|
||||||
|
$("#od_coupon_frm").parent(".od_coupon_wrap").remove();
|
||||||
|
}
|
||||||
$("#od_coupon_frm").remove();
|
$("#od_coupon_frm").remove();
|
||||||
$("#od_coupon_btn").text("변경").focus();
|
$("#od_coupon_btn").text("변경").focus();
|
||||||
if(!$("#od_coupon_cancel").length)
|
if(!$("#od_coupon_cancel").length)
|
||||||
@ -920,6 +926,9 @@ $(function() {
|
|||||||
});
|
});
|
||||||
|
|
||||||
$(document).on("click", "#od_coupon_close", function() {
|
$(document).on("click", "#od_coupon_close", function() {
|
||||||
|
if( $("#od_coupon_frm").parent(".od_coupon_wrap").length ){
|
||||||
|
$("#od_coupon_frm").parent(".od_coupon_wrap").remove();
|
||||||
|
}
|
||||||
$("#od_coupon_frm").remove();
|
$("#od_coupon_frm").remove();
|
||||||
$("#od_coupon_btn").focus();
|
$("#od_coupon_btn").focus();
|
||||||
});
|
});
|
||||||
@ -934,6 +943,9 @@ $(function() {
|
|||||||
$("#od_cp_price").text(0);
|
$("#od_cp_price").text(0);
|
||||||
$("#sc_cp_price").text(0);
|
$("#sc_cp_price").text(0);
|
||||||
calculate_order_price();
|
calculate_order_price();
|
||||||
|
if( $("#od_coupon_frm").parent(".od_coupon_wrap").length ){
|
||||||
|
$("#od_coupon_frm").parent(".od_coupon_wrap").remove();
|
||||||
|
}
|
||||||
$("#od_coupon_frm").remove();
|
$("#od_coupon_frm").remove();
|
||||||
$("#od_coupon_btn").text("쿠폰적용").focus();
|
$("#od_coupon_btn").text("쿠폰적용").focus();
|
||||||
$(this).remove();
|
$(this).remove();
|
||||||
|
|||||||
@ -867,6 +867,9 @@ $(function() {
|
|||||||
});
|
});
|
||||||
|
|
||||||
$("#od_coupon_btn").click(function() {
|
$("#od_coupon_btn").click(function() {
|
||||||
|
if( $("#od_coupon_frm").parent(".od_coupon_wrap").length ){
|
||||||
|
$("#od_coupon_frm").parent(".od_coupon_wrap").remove();
|
||||||
|
}
|
||||||
$("#od_coupon_frm").remove();
|
$("#od_coupon_frm").remove();
|
||||||
var $this = $(this);
|
var $this = $(this);
|
||||||
var price = parseInt($("input[name=org_od_price]").val()) - parseInt($("input[name=item_coupon]").val());
|
var price = parseInt($("input[name=org_od_price]").val()) - parseInt($("input[name=item_coupon]").val());
|
||||||
@ -914,6 +917,9 @@ $(function() {
|
|||||||
$("#od_cp_price").text(number_format(String(price)));
|
$("#od_cp_price").text(number_format(String(price)));
|
||||||
$("#sc_cp_price").text(0);
|
$("#sc_cp_price").text(0);
|
||||||
calculate_order_price();
|
calculate_order_price();
|
||||||
|
if( $("#od_coupon_frm").parent(".od_coupon_wrap").length ){
|
||||||
|
$("#od_coupon_frm").parent(".od_coupon_wrap").remove();
|
||||||
|
}
|
||||||
$("#od_coupon_frm").remove();
|
$("#od_coupon_frm").remove();
|
||||||
$("#od_coupon_btn").text("변경").focus();
|
$("#od_coupon_btn").text("변경").focus();
|
||||||
if(!$("#od_coupon_cancel").length)
|
if(!$("#od_coupon_cancel").length)
|
||||||
@ -921,6 +927,9 @@ $(function() {
|
|||||||
});
|
});
|
||||||
|
|
||||||
$(document).on("click", "#od_coupon_close", function() {
|
$(document).on("click", "#od_coupon_close", function() {
|
||||||
|
if( $("#od_coupon_frm").parent(".od_coupon_wrap").length ){
|
||||||
|
$("#od_coupon_frm").parent(".od_coupon_wrap").remove();
|
||||||
|
}
|
||||||
$("#od_coupon_frm").remove();
|
$("#od_coupon_frm").remove();
|
||||||
$("#od_coupon_btn").focus();
|
$("#od_coupon_btn").focus();
|
||||||
});
|
});
|
||||||
@ -935,6 +944,9 @@ $(function() {
|
|||||||
$("#od_cp_price").text(0);
|
$("#od_cp_price").text(0);
|
||||||
$("#sc_cp_price").text(0);
|
$("#sc_cp_price").text(0);
|
||||||
calculate_order_price();
|
calculate_order_price();
|
||||||
|
if( $("#od_coupon_frm").parent(".od_coupon_wrap").length ){
|
||||||
|
$("#od_coupon_frm").parent(".od_coupon_wrap").remove();
|
||||||
|
}
|
||||||
$("#od_coupon_frm").remove();
|
$("#od_coupon_frm").remove();
|
||||||
$("#od_coupon_btn").text("쿠폰적용").focus();
|
$("#od_coupon_btn").text("쿠폰적용").focus();
|
||||||
$(this).remove();
|
$(this).remove();
|
||||||
|
|||||||
Reference in New Issue
Block a user