Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Usulan Reviewer
- public function editusulan_post()
- {
- $username = trim($this->post('username'));
- $id = $this->post('id');
- if ($username == '') {
- $response = [
- 'resp_error' => true,
- 'resp_msg' => 'Username Kosong.',
- ];
- } elseif ($id == '') {
- $response = [
- 'resp_error' => true,
- 'resp_msg' => 'ID Proposal Kosong.',
- ];
- } else {
- $detail = $this->db->get_where('lemlit_reviewer', array('propose_id' => $id, 'user_username' => $username))->row();
- if (count($detail) == 0) {
- $response = [
- 'resp_error' => false,
- 'resp_msg' => 'Data Reviewer Tidak Di Temukan',
- ];
- } else {
- $response = [
- 'resp_error' => false,
- 'id' => $detail->propose_id,
- 'user_username' => trim($detail->user_username),
- 'reviewer_id' => $detail->reviewer_id,
- 'usulan_dana' => $detail->usulan_dana,
- 'usulan_rupiah' => number_format($detail->usulan_dana, 0, '', ','),
- ];
- }
- }
- $this->response($response, 200);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement