diff --git a/css/history.css b/css/history.css index 62d0ac3baefc07ec0cb431950db38ff8f673f80d..dd3da3a4a4d0a78a73d2ae396e0a16831bafa735 100755 --- a/css/history.css +++ b/css/history.css @@ -1,7 +1,6 @@ .history_container { margin-top: 10%; height: 79%; - border: 1px solid red; /*OJO LALI HAPUS IKI*/ } .history_container .subheader { @@ -31,7 +30,6 @@ font-family: calibri; position: relative;; - border: 0.5px solid black; display: block; text-decoration: none; @@ -48,9 +46,7 @@ table.history_table { margin-top: 5px; - border: 1px solid blue; /*OJO LALI HAPUS IKI*/ width: 100%; - border: 1px solid purple; padding: 0; border-collapse: collapse; } @@ -89,7 +85,6 @@ p.history_comment { } table.history_table th, td { - border: 1px solid purple; padding: 5px; border-collapse: collapse; } @@ -105,4 +100,11 @@ img.history_pict { display: inline; margin: 0; +} + +.hide_hist_button { + margin: 0; + color: white; + background-color: red; + font-size: 9px; } \ No newline at end of file diff --git a/history/driver_history.html b/history/driver_history.html deleted file mode 100755 index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000 diff --git a/history/driver_history.php b/history/driver_history.php index d1e4a056aa85944398e99ddf15f82175ed8a7471..3b724f75b57bedabd2c7b007d66d2013040a33bb 100644 --- a/history/driver_history.php +++ b/history/driver_history.php @@ -64,14 +64,15 @@ echo "<tr> <td> - <img class='history_pict' src='../profile/getProfilePict.php?id=".$row['cust_id']."' + <img class='history_pict' src='../profile/getProfilePict.php?id=".$row['cust_id']."'> + <button class='hide_hist_button' type='button' value='hide' onclick='hide_row(this)'>Hide</button> </td> <td> <p class='history_date'>".$row['date']."</p> <p class='history_username'>".$driver_name."</p> <p class='history_loc'>".$row['pick_city']." - ".$row['dest_city']."</p> - <p class='history_rating'>rating ".$row['score']."</p> - <p class='history_comment'>You commented:</p> + <p class='history_rating'>gave ".$row['score']." stars for this order</p> + <p class='history_comment'>and left comment:</p> <p class='history_comment' style='margin-left: 30px;'>".$row['comment']."</p> </td> </tr>"; @@ -85,4 +86,6 @@ </div> </div> </body> -</html> \ No newline at end of file +</html> + +<script type="text/javascript" src="hide_history.js"></script> \ No newline at end of file diff --git a/history/hide_history.js b/history/hide_history.js new file mode 100644 index 0000000000000000000000000000000000000000..13ad2f0eab422aaaff00c740cd8b4fa8a30e3d29 --- /dev/null +++ b/history/hide_history.js @@ -0,0 +1,4 @@ +function hide_row(o) { + var p = o.parentNode.parentNode; + p.parentNode.removeChild(p); +} \ No newline at end of file diff --git a/history/history.html b/history/history.html deleted file mode 100755 index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000 diff --git a/history/order_history.html b/history/order_history.html deleted file mode 100755 index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000 diff --git a/history/transaction_history.php b/history/transaction_history.php index 9be4a6d8871de85b61c668da0461ce722d77ee81..17e99d6b3055c4fc8d43886de91b19229af7f1ef 100644 --- a/history/transaction_history.php +++ b/history/transaction_history.php @@ -5,6 +5,9 @@ <link rel="stylesheet" type="text/css" href="../css/default_style.css"> <link rel="stylesheet" type="text/css" href="../css/history.css"> <link rel="stylesheet" type="text/css" href="../css/header.css"> + <script type="text/javascript" src="hide_history.js"> + </script> +} </head> <body> <div class="frame"> @@ -63,7 +66,8 @@ echo "<tr> <td> - <img class='history_pict' src='../profile/getProfilePict.php?id=".$row['driver_id']."' + <img class='history_pict' src='../profile/getProfilePict.php?id=".$row['driver_id']."'> + <button class='hide_hist_button' type='button' value='hide' onclick='hide_row(this)'>Hide</button> </td> <td> <p class='history_date'>".$row['date']."</p> @@ -85,3 +89,5 @@ </div> </body> </html> + +<script type="text/javascript" src="hide_history.js"></script> \ No newline at end of file