-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathseller_penjualan.php
107 lines (95 loc) · 2.42 KB
/
seller_penjualan.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
<?php
include 'connect.php';
if (!isset($_SESSION['email'])) {
header('location: login.php');
}
else if ($_SESSION['email'] != "[email protected]") {
header('location: home.php');
}
?>
<!doctype html>
<html lang="en">
<head>
<title>Proyek Tekweb</title>
<?php include('assets/header.php'); ?>
<script src="js/home_func.js"></script>
<link rel="stylesheet" type="text/css" href="assets/sidebar_seller.css">
<link rel="stylesheet" type="text/css" href="css/seller_penjualan_style.css">
<meta name="viewport" content="width=device-width, initial-scale=1">
<script>
$(function() {
$.ajax ({
url:'seller_penjualan_ajax.php',
method:'POST',
data: {
id_status : '1',
type : 'ready',
id_trf : 0
},
success:function(data) {
$('#wrapper-item').html(data.output);
},
error:function(data) {
}
});
$(".bt").click(function() {
$(".bt").removeClass("btn-active text-success");
$(this).addClass("btn-active text-success");
var id_status = $(this).data('id');
$.ajax ({
url:'seller_penjualan_ajax.php',
method:'POST',
data: {
id_status : id_status,
type : 'page',
id_trf : 0
},
success:function(data) {
$('#wrapper-item').html(data.output);
},
error:function(data) {
}
});
});
$('body').on('click', '.terima-pesanan', function(){
var id_trf = $(this).data('idtrf');
$.ajax ({
url:'seller_penjualan_ajax.php',
method:'POST',
data: {
id_status : '1',
type : 'update',
id_trf : id_trf
},
success:function(data) {
alert("Pesanan diterima!");
$('#wrapper-item').html(data.output);
},
error:function(data) {
}
});
});
});
</script>
</head>
<body>
<?php include('assets/navbar_seller.php'); ?>
<div class="fluid-container" style="overflow-x: hidden;">
<div class="row no-gutters">
<?php include('assets/sidebar_seller.php'); ?>
<div class="col-10 mt-4 ml-3">
<h4>Daftar Pesanan</h4>
<div class="card border-dark my-3">
<div class="card-header header-btn f-12">
<a href="#" class="bt btn-active text-success" data-id="1">Menunggu Konfirmasi</a>
<a href="#" class="bt" data-id="3">Sedang Dikirim</a>
<a href="#" class="bt" data-id="4">Sampai Tujuan</a>
</div>
</div>
<div class="row no-gutters" id="wrapper-item">
</div>
</div>
</div>
</div>
</body>
</html>