if ($input = $data->edit_rayon($_POST['id'], $_POST['rayon'], $_POST['id_area'])) {
                    $arr['status'] = TRUE;
                    $arr['msg'] = "Data tersimpan..";
                } else {
                    $arr['status'] = FALSE;
                    $arr['msg'] = "Gagal menyimpan..";
                }
            } else {
                $arr['status'] = FALSE;
                $arr['msg'] = "Lengkapi terlebih dahulu..";
            }
            echo json_encode($arr);
            break;
        case 'hapus-rayon':
            $arr = array();
            if (isset($_POST['id']) && $_POST['id'] != "") {
                if ($input = $data->hapus_rayon($_POST['id'])) {
                    $arr['status'] = TRUE;
                    $arr['msg'] = "Berhasil dihapus..";
                } else {
                    $arr['status'] = FALSE;
                    $arr['msg'] = "Gagal menghapus..";
                }
            } else {
                $arr['status'] = FALSE;
                $arr['msg'] = "Insufficient data stored..";
            }
            echo json_encode($arr);
            break;
    }
}