Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion crud_ci/application/models/products_model.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,11 @@ function getAllProducts()
function getProduct($id)
{
//select produk berdasarkan id yang dimiliki
$this->db->select("*");
$this->db->from("msProduct");
$this->db->where("id", $id);

return $this->db->get();
}

function addProduct($data)
Expand All @@ -38,4 +43,4 @@ function deleteProduct($id)
{
//delete produk berdasarkan id
}
}
}