--- /dev/null
+CREATE TABLE members (
+ id INTEGER UNSIGNED NOT NULL AUTO_INCREMENT,
+ username VARCHAR(40) NOT NULL default '',
+ password VARCHAR(40) NOT NULL default '',
+ uid VARCHAR(40) NOT NULL,
+ created_at DATETIME NOT NULL DEFAULT '0000-00-00 00:00:00',
+ PRIMARY KEY(id),
+ INDEX members_login(username, password),
+ UNIQUE INDEX members_uid(uid),
+ UNIQUE INDEX members_username(username)
+);
+
--- /dev/null
+CREATE TABLE notes (
+ id INTEGER UNSIGNED NOT NULL AUTO_INCREMENT,
+ member_id INTEGER UNSIGNED NOT NULL,
+ lat FLOAT NOT NULL,
+ lon FLOAT NOT NULL,
+ title TEXT NOT NULL,
+ body TEXT NOT NULL,
+ public_flag VARCHAR(32) NOT NULL DEFAULT 'private',
+ created DATETIME NOT NULL,
+ modified DATETIME NOT NULL,
+ PRIMARY KEY(id),
+ INDEX note_member_id(member_id),
+ INDEX note_pulic_flag(public_flag, member_id, modified),
+ INDEX note_modified(modified, member_id)
+)
+TYPE=InnoDB;
--- /dev/null
+<?php
+class MembersController extends AppController {
+
+ var $name = 'Members';
+ var $helpers = array('Html', 'Form');
+
+ function index() {
+ $this->Member->recursive = 0;
+ $this->set('members', $this->paginate());
+ }
+
+ function view($id = null) {
+ if (!$id) {
+ $this->Session->setFlash(__('Invalid Member.', true));
+ $this->redirect(array('action'=>'index'));
+ }
+ $this->set('member', $this->Member->read(null, $id));
+ }
+
+ function add() {
+ if (!empty($this->data)) {
+ $this->Member->create();
+ if ($this->Member->save($this->data)) {
+ $this->Session->setFlash(__('The Member has been saved', true));
+ $this->redirect(array('action'=>'index'));
+ } else {
+ $this->Session->setFlash(__('The Member could not be saved. Please, try again.', true));
+ }
+ }
+ }
+
+ function edit($id = null) {
+ if (!$id && empty($this->data)) {
+ $this->Session->setFlash(__('Invalid Member', true));
+ $this->redirect(array('action'=>'index'));
+ }
+ if (!empty($this->data)) {
+ if ($this->Member->save($this->data)) {
+ $this->Session->setFlash(__('The Member has been saved', true));
+ $this->redirect(array('action'=>'index'));
+ } else {
+ $this->Session->setFlash(__('The Member could not be saved. Please, try again.', true));
+ }
+ }
+ if (empty($this->data)) {
+ $this->data = $this->Member->read(null, $id);
+ }
+ }
+
+ function delete($id = null) {
+ if (!$id) {
+ $this->Session->setFlash(__('Invalid id for Member', true));
+ $this->redirect(array('action'=>'index'));
+ }
+ if ($this->Member->del($id)) {
+ $this->Session->setFlash(__('Member deleted', true));
+ $this->redirect(array('action'=>'index'));
+ }
+ }
+
+
+ function admin_index() {
+ $this->Member->recursive = 0;
+ $this->set('members', $this->paginate());
+ }
+
+ function admin_view($id = null) {
+ if (!$id) {
+ $this->Session->setFlash(__('Invalid Member.', true));
+ $this->redirect(array('action'=>'index'));
+ }
+ $this->set('member', $this->Member->read(null, $id));
+ }
+
+ function admin_add() {
+ if (!empty($this->data)) {
+ $this->Member->create();
+ if ($this->Member->save($this->data)) {
+ $this->Session->setFlash(__('The Member has been saved', true));
+ $this->redirect(array('action'=>'index'));
+ } else {
+ $this->Session->setFlash(__('The Member could not be saved. Please, try again.', true));
+ }
+ }
+ }
+
+ function admin_edit($id = null) {
+ if (!$id && empty($this->data)) {
+ $this->Session->setFlash(__('Invalid Member', true));
+ $this->redirect(array('action'=>'index'));
+ }
+ if (!empty($this->data)) {
+ if ($this->Member->save($this->data)) {
+ $this->Session->setFlash(__('The Member has been saved', true));
+ $this->redirect(array('action'=>'index'));
+ } else {
+ $this->Session->setFlash(__('The Member could not be saved. Please, try again.', true));
+ }
+ }
+ if (empty($this->data)) {
+ $this->data = $this->Member->read(null, $id);
+ }
+ }
+
+ function admin_delete($id = null) {
+ if (!$id) {
+ $this->Session->setFlash(__('Invalid id for Member', true));
+ $this->redirect(array('action'=>'index'));
+ }
+ if ($this->Member->del($id)) {
+ $this->Session->setFlash(__('Member deleted', true));
+ $this->redirect(array('action'=>'index'));
+ }
+ }
+
+}
+?>
\ No newline at end of file
--- /dev/null
+<?php
+class NotesController extends AppController {
+
+ var $name = 'Notes';
+ var $helpers = array('Html', 'Form');
+
+ function index() {
+ $this->Note->recursive = 0;
+ $this->set('notes', $this->paginate());
+ }
+
+ function view($id = null) {
+ if (!$id) {
+ $this->Session->setFlash(__('Invalid Note.', true));
+ $this->redirect(array('action'=>'index'));
+ }
+ $this->set('note', $this->Note->read(null, $id));
+ }
+
+ function add() {
+ if (!empty($this->data)) {
+ $this->Note->create();
+ if ($this->Note->save($this->data)) {
+ $this->Session->setFlash(__('The Note has been saved', true));
+ $this->redirect(array('action'=>'index'));
+ } else {
+ $this->Session->setFlash(__('The Note could not be saved. Please, try again.', true));
+ }
+ }
+ $members = $this->Note->Member->find('list');
+ $this->set(compact('members'));
+ }
+
+ function edit($id = null) {
+ if (!$id && empty($this->data)) {
+ $this->Session->setFlash(__('Invalid Note', true));
+ $this->redirect(array('action'=>'index'));
+ }
+ if (!empty($this->data)) {
+ if ($this->Note->save($this->data)) {
+ $this->Session->setFlash(__('The Note has been saved', true));
+ $this->redirect(array('action'=>'index'));
+ } else {
+ $this->Session->setFlash(__('The Note could not be saved. Please, try again.', true));
+ }
+ }
+ if (empty($this->data)) {
+ $this->data = $this->Note->read(null, $id);
+ }
+ $members = $this->Note->Member->find('list');
+ $this->set(compact('members'));
+ }
+
+ function delete($id = null) {
+ if (!$id) {
+ $this->Session->setFlash(__('Invalid id for Note', true));
+ $this->redirect(array('action'=>'index'));
+ }
+ if ($this->Note->del($id)) {
+ $this->Session->setFlash(__('Note deleted', true));
+ $this->redirect(array('action'=>'index'));
+ }
+ }
+
+
+ function admin_index() {
+ $this->Note->recursive = 0;
+ $this->set('notes', $this->paginate());
+ }
+
+ function admin_view($id = null) {
+ if (!$id) {
+ $this->Session->setFlash(__('Invalid Note.', true));
+ $this->redirect(array('action'=>'index'));
+ }
+ $this->set('note', $this->Note->read(null, $id));
+ }
+
+ function admin_add() {
+ if (!empty($this->data)) {
+ $this->Note->create();
+ if ($this->Note->save($this->data)) {
+ $this->Session->setFlash(__('The Note has been saved', true));
+ $this->redirect(array('action'=>'index'));
+ } else {
+ $this->Session->setFlash(__('The Note could not be saved. Please, try again.', true));
+ }
+ }
+ $members = $this->Note->Member->find('list');
+ $this->set(compact('members'));
+ }
+
+ function admin_edit($id = null) {
+ if (!$id && empty($this->data)) {
+ $this->Session->setFlash(__('Invalid Note', true));
+ $this->redirect(array('action'=>'index'));
+ }
+ if (!empty($this->data)) {
+ if ($this->Note->save($this->data)) {
+ $this->Session->setFlash(__('The Note has been saved', true));
+ $this->redirect(array('action'=>'index'));
+ } else {
+ $this->Session->setFlash(__('The Note could not be saved. Please, try again.', true));
+ }
+ }
+ if (empty($this->data)) {
+ $this->data = $this->Note->read(null, $id);
+ }
+ $members = $this->Note->Member->find('list');
+ $this->set(compact('members'));
+ }
+
+ function admin_delete($id = null) {
+ if (!$id) {
+ $this->Session->setFlash(__('Invalid id for Note', true));
+ $this->redirect(array('action'=>'index'));
+ }
+ if ($this->Note->del($id)) {
+ $this->Session->setFlash(__('Note deleted', true));
+ $this->redirect(array('action'=>'index'));
+ }
+ }
+
+}
+?>
\ No newline at end of file
--- /dev/null
+<?php
+class Member extends AppModel {
+
+ var $name = 'Member';
+ var $validate = array(
+ );
+
+}
+?>
--- /dev/null
+<?php
+class Note extends AppModel {
+
+ var $name = 'Note';
+
+ //The Associations below have been created with all possible keys, those that are not needed can be removed
+ var $belongsTo = array(
+ 'Member' => array(
+ 'className' => 'Member',
+ 'foreignKey' => 'member_id',
+ 'conditions' => '',
+ 'fields' => '',
+ 'order' => ''
+ )
+ );
+
+}
+?>
\ No newline at end of file
--- /dev/null
+<div class="members form">
+<?php echo $form->create('Member');?>
+ <fieldset>
+ <legend><?php __('Add Member');?></legend>
+ <?php
+ echo $form->input('username');
+ echo $form->input('password');
+ echo $form->input('uid');
+ echo $form->input('created_at');
+ ?>
+ </fieldset>
+<?php echo $form->end('Submit');?>
+</div>
+<div class="actions">
+ <ul>
+ <li><?php echo $html->link(__('List Members', true), array('action' => 'index'));?></li>
+ </ul>
+</div>
--- /dev/null
+<div class="members form">
+<?php echo $form->create('Member');?>
+ <fieldset>
+ <legend><?php __('Add Member');?></legend>
+ <?php
+ echo $form->input('username');
+ echo $form->input('password');
+ echo $form->input('uid');
+ echo $form->input('created_at');
+ ?>
+ </fieldset>
+<?php echo $form->end('Submit');?>
+</div>
+<div class="actions">
+ <ul>
+ <li><?php echo $html->link(__('List Members', true), array('action' => 'index'));?></li>
+ </ul>
+</div>
--- /dev/null
+<div class="members form">
+<?php echo $form->create('Member');?>
+ <fieldset>
+ <legend><?php __('Edit Member');?></legend>
+ <?php
+ echo $form->input('id');
+ echo $form->input('username');
+ echo $form->input('password');
+ echo $form->input('uid');
+ echo $form->input('created_at');
+ ?>
+ </fieldset>
+<?php echo $form->end('Submit');?>
+</div>
+<div class="actions">
+ <ul>
+ <li><?php echo $html->link(__('Delete', true), array('action' => 'delete', $form->value('Member.id')), null, sprintf(__('Are you sure you want to delete # %s?', true), $form->value('Member.id'))); ?></li>
+ <li><?php echo $html->link(__('List Members', true), array('action' => 'index'));?></li>
+ </ul>
+</div>
--- /dev/null
+<div class="members index">
+<h2><?php __('Members');?></h2>
+<p>
+<?php
+echo $paginator->counter(array(
+'format' => __('Page %page% of %pages%, showing %current% records out of %count% total, starting on record %start%, ending on %end%', true)
+));
+?></p>
+<table cellpadding="0" cellspacing="0">
+<tr>
+ <th><?php echo $paginator->sort('id');?></th>
+ <th><?php echo $paginator->sort('username');?></th>
+ <th><?php echo $paginator->sort('password');?></th>
+ <th><?php echo $paginator->sort('uid');?></th>
+ <th><?php echo $paginator->sort('created_at');?></th>
+ <th class="actions"><?php __('Actions');?></th>
+</tr>
+<?php
+$i = 0;
+foreach ($members as $member):
+ $class = null;
+ if ($i++ % 2 == 0) {
+ $class = ' class="altrow"';
+ }
+?>
+ <tr<?php echo $class;?>>
+ <td>
+ <?php echo $member['Member']['id']; ?>
+ </td>
+ <td>
+ <?php echo $member['Member']['username']; ?>
+ </td>
+ <td>
+ <?php echo $member['Member']['password']; ?>
+ </td>
+ <td>
+ <?php echo $member['Member']['uid']; ?>
+ </td>
+ <td>
+ <?php echo $member['Member']['created_at']; ?>
+ </td>
+ <td class="actions">
+ <?php echo $html->link(__('View', true), array('action' => 'view', $member['Member']['id'])); ?>
+ <?php echo $html->link(__('Edit', true), array('action' => 'edit', $member['Member']['id'])); ?>
+ <?php echo $html->link(__('Delete', true), array('action' => 'delete', $member['Member']['id']), null, sprintf(__('Are you sure you want to delete # %s?', true), $member['Member']['id'])); ?>
+ </td>
+ </tr>
+<?php endforeach; ?>
+</table>
+</div>
+<div class="paging">
+ <?php echo $paginator->prev('<< '.__('previous', true), array(), null, array('class'=>'disabled'));?>
+ | <?php echo $paginator->numbers();?>
+ <?php echo $paginator->next(__('next', true).' >>', array(), null, array('class' => 'disabled'));?>
+</div>
+<div class="actions">
+ <ul>
+ <li><?php echo $html->link(__('New Member', true), array('action' => 'add')); ?></li>
+ </ul>
+</div>
--- /dev/null
+<div class="members view">
+<h2><?php __('Member');?></h2>
+ <dl><?php $i = 0; $class = ' class="altrow"';?>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Id'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $member['Member']['id']; ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Username'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $member['Member']['username']; ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Password'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $member['Member']['password']; ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Uid'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $member['Member']['uid']; ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Created At'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $member['Member']['created_at']; ?>
+
+ </dd>
+ </dl>
+</div>
+<div class="actions">
+ <ul>
+ <li><?php echo $html->link(__('Edit Member', true), array('action' => 'edit', $member['Member']['id'])); ?> </li>
+ <li><?php echo $html->link(__('Delete Member', true), array('action' => 'delete', $member['Member']['id']), null, sprintf(__('Are you sure you want to delete # %s?', true), $member['Member']['id'])); ?> </li>
+ <li><?php echo $html->link(__('List Members', true), array('action' => 'index')); ?> </li>
+ <li><?php echo $html->link(__('New Member', true), array('action' => 'add')); ?> </li>
+ </ul>
+</div>
--- /dev/null
+<div class="members form">
+<?php echo $form->create('Member');?>
+ <fieldset>
+ <legend><?php __('Edit Member');?></legend>
+ <?php
+ echo $form->input('id');
+ echo $form->input('username');
+ echo $form->input('password');
+ echo $form->input('uid');
+ echo $form->input('created_at');
+ ?>
+ </fieldset>
+<?php echo $form->end('Submit');?>
+</div>
+<div class="actions">
+ <ul>
+ <li><?php echo $html->link(__('Delete', true), array('action' => 'delete', $form->value('Member.id')), null, sprintf(__('Are you sure you want to delete # %s?', true), $form->value('Member.id'))); ?></li>
+ <li><?php echo $html->link(__('List Members', true), array('action' => 'index'));?></li>
+ </ul>
+</div>
--- /dev/null
+<div class="members index">
+<h2><?php __('Members');?></h2>
+<p>
+<?php
+echo $paginator->counter(array(
+'format' => __('Page %page% of %pages%, showing %current% records out of %count% total, starting on record %start%, ending on %end%', true)
+));
+?></p>
+<table cellpadding="0" cellspacing="0">
+<tr>
+ <th><?php echo $paginator->sort('id');?></th>
+ <th><?php echo $paginator->sort('username');?></th>
+ <th><?php echo $paginator->sort('password');?></th>
+ <th><?php echo $paginator->sort('uid');?></th>
+ <th><?php echo $paginator->sort('created_at');?></th>
+ <th class="actions"><?php __('Actions');?></th>
+</tr>
+<?php
+$i = 0;
+foreach ($members as $member):
+ $class = null;
+ if ($i++ % 2 == 0) {
+ $class = ' class="altrow"';
+ }
+?>
+ <tr<?php echo $class;?>>
+ <td>
+ <?php echo $member['Member']['id']; ?>
+ </td>
+ <td>
+ <?php echo $member['Member']['username']; ?>
+ </td>
+ <td>
+ <?php echo $member['Member']['password']; ?>
+ </td>
+ <td>
+ <?php echo $member['Member']['uid']; ?>
+ </td>
+ <td>
+ <?php echo $member['Member']['created_at']; ?>
+ </td>
+ <td class="actions">
+ <?php echo $html->link(__('View', true), array('action' => 'view', $member['Member']['id'])); ?>
+ <?php echo $html->link(__('Edit', true), array('action' => 'edit', $member['Member']['id'])); ?>
+ <?php echo $html->link(__('Delete', true), array('action' => 'delete', $member['Member']['id']), null, sprintf(__('Are you sure you want to delete # %s?', true), $member['Member']['id'])); ?>
+ </td>
+ </tr>
+<?php endforeach; ?>
+</table>
+</div>
+<div class="paging">
+ <?php echo $paginator->prev('<< '.__('previous', true), array(), null, array('class'=>'disabled'));?>
+ | <?php echo $paginator->numbers();?>
+ <?php echo $paginator->next(__('next', true).' >>', array(), null, array('class' => 'disabled'));?>
+</div>
+<div class="actions">
+ <ul>
+ <li><?php echo $html->link(__('New Member', true), array('action' => 'add')); ?></li>
+ </ul>
+</div>
--- /dev/null
+<div class="members view">
+<h2><?php __('Member');?></h2>
+ <dl><?php $i = 0; $class = ' class="altrow"';?>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Id'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $member['Member']['id']; ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Username'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $member['Member']['username']; ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Password'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $member['Member']['password']; ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Uid'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $member['Member']['uid']; ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Created At'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $member['Member']['created_at']; ?>
+
+ </dd>
+ </dl>
+</div>
+<div class="actions">
+ <ul>
+ <li><?php echo $html->link(__('Edit Member', true), array('action' => 'edit', $member['Member']['id'])); ?> </li>
+ <li><?php echo $html->link(__('Delete Member', true), array('action' => 'delete', $member['Member']['id']), null, sprintf(__('Are you sure you want to delete # %s?', true), $member['Member']['id'])); ?> </li>
+ <li><?php echo $html->link(__('List Members', true), array('action' => 'index')); ?> </li>
+ <li><?php echo $html->link(__('New Member', true), array('action' => 'add')); ?> </li>
+ </ul>
+</div>
--- /dev/null
+<div class="notes form">
+<?php echo $form->create('Note');?>
+ <fieldset>
+ <legend><?php __('Add Note');?></legend>
+ <?php
+ echo $form->input('member_id');
+ echo $form->input('lat');
+ echo $form->input('lon');
+ echo $form->input('title');
+ echo $form->input('body');
+ echo $form->input('public_flag');
+ ?>
+ </fieldset>
+<?php echo $form->end('Submit');?>
+</div>
+<div class="actions">
+ <ul>
+ <li><?php echo $html->link(__('List Notes', true), array('action' => 'index'));?></li>
+ <li><?php echo $html->link(__('List Members', true), array('controller' => 'members', 'action' => 'index')); ?> </li>
+ <li><?php echo $html->link(__('New Member', true), array('controller' => 'members', 'action' => 'add')); ?> </li>
+ </ul>
+</div>
--- /dev/null
+<div class="notes form">
+<?php echo $form->create('Note');?>
+ <fieldset>
+ <legend><?php __('Add Note');?></legend>
+ <?php
+ echo $form->input('member_id');
+ echo $form->input('lat');
+ echo $form->input('lon');
+ echo $form->input('title');
+ echo $form->input('body');
+ echo $form->input('public_flag');
+ ?>
+ </fieldset>
+<?php echo $form->end('Submit');?>
+</div>
+<div class="actions">
+ <ul>
+ <li><?php echo $html->link(__('List Notes', true), array('action' => 'index'));?></li>
+ <li><?php echo $html->link(__('List Members', true), array('controller' => 'members', 'action' => 'index')); ?> </li>
+ <li><?php echo $html->link(__('New Member', true), array('controller' => 'members', 'action' => 'add')); ?> </li>
+ </ul>
+</div>
--- /dev/null
+<div class="notes form">
+<?php echo $form->create('Note');?>
+ <fieldset>
+ <legend><?php __('Edit Note');?></legend>
+ <?php
+ echo $form->input('id');
+ echo $form->input('member_id');
+ echo $form->input('lat');
+ echo $form->input('lon');
+ echo $form->input('title');
+ echo $form->input('body');
+ echo $form->input('public_flag');
+ ?>
+ </fieldset>
+<?php echo $form->end('Submit');?>
+</div>
+<div class="actions">
+ <ul>
+ <li><?php echo $html->link(__('Delete', true), array('action' => 'delete', $form->value('Note.id')), null, sprintf(__('Are you sure you want to delete # %s?', true), $form->value('Note.id'))); ?></li>
+ <li><?php echo $html->link(__('List Notes', true), array('action' => 'index'));?></li>
+ <li><?php echo $html->link(__('List Members', true), array('controller' => 'members', 'action' => 'index')); ?> </li>
+ <li><?php echo $html->link(__('New Member', true), array('controller' => 'members', 'action' => 'add')); ?> </li>
+ </ul>
+</div>
--- /dev/null
+<div class="notes index">
+<h2><?php __('Notes');?></h2>
+<p>
+<?php
+echo $paginator->counter(array(
+'format' => __('Page %page% of %pages%, showing %current% records out of %count% total, starting on record %start%, ending on %end%', true)
+));
+?></p>
+<table cellpadding="0" cellspacing="0">
+<tr>
+ <th><?php echo $paginator->sort('id');?></th>
+ <th><?php echo $paginator->sort('member_id');?></th>
+ <th><?php echo $paginator->sort('lat');?></th>
+ <th><?php echo $paginator->sort('lon');?></th>
+ <th><?php echo $paginator->sort('title');?></th>
+ <th><?php echo $paginator->sort('body');?></th>
+ <th><?php echo $paginator->sort('public_flag');?></th>
+ <th><?php echo $paginator->sort('created');?></th>
+ <th><?php echo $paginator->sort('modified');?></th>
+ <th class="actions"><?php __('Actions');?></th>
+</tr>
+<?php
+$i = 0;
+foreach ($notes as $note):
+ $class = null;
+ if ($i++ % 2 == 0) {
+ $class = ' class="altrow"';
+ }
+?>
+ <tr<?php echo $class;?>>
+ <td>
+ <?php echo $note['Note']['id']; ?>
+ </td>
+ <td>
+ <?php echo $html->link($note['Member']['id'], array('controller' => 'members', 'action' => 'view', $note['Member']['id'])); ?>
+ </td>
+ <td>
+ <?php echo $note['Note']['lat']; ?>
+ </td>
+ <td>
+ <?php echo $note['Note']['lon']; ?>
+ </td>
+ <td>
+ <?php echo $note['Note']['title']; ?>
+ </td>
+ <td>
+ <?php echo $note['Note']['body']; ?>
+ </td>
+ <td>
+ <?php echo $note['Note']['public_flag']; ?>
+ </td>
+ <td>
+ <?php echo $note['Note']['created']; ?>
+ </td>
+ <td>
+ <?php echo $note['Note']['modified']; ?>
+ </td>
+ <td class="actions">
+ <?php echo $html->link(__('View', true), array('action' => 'view', $note['Note']['id'])); ?>
+ <?php echo $html->link(__('Edit', true), array('action' => 'edit', $note['Note']['id'])); ?>
+ <?php echo $html->link(__('Delete', true), array('action' => 'delete', $note['Note']['id']), null, sprintf(__('Are you sure you want to delete # %s?', true), $note['Note']['id'])); ?>
+ </td>
+ </tr>
+<?php endforeach; ?>
+</table>
+</div>
+<div class="paging">
+ <?php echo $paginator->prev('<< '.__('previous', true), array(), null, array('class'=>'disabled'));?>
+ | <?php echo $paginator->numbers();?>
+ <?php echo $paginator->next(__('next', true).' >>', array(), null, array('class' => 'disabled'));?>
+</div>
+<div class="actions">
+ <ul>
+ <li><?php echo $html->link(__('New Note', true), array('action' => 'add')); ?></li>
+ <li><?php echo $html->link(__('List Members', true), array('controller' => 'members', 'action' => 'index')); ?> </li>
+ <li><?php echo $html->link(__('New Member', true), array('controller' => 'members', 'action' => 'add')); ?> </li>
+ </ul>
+</div>
--- /dev/null
+<div class="notes view">
+<h2><?php __('Note');?></h2>
+ <dl><?php $i = 0; $class = ' class="altrow"';?>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Id'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $note['Note']['id']; ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Member'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $html->link($note['Member']['id'], array('controller' => 'members', 'action' => 'view', $note['Member']['id'])); ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Lat'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $note['Note']['lat']; ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Lon'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $note['Note']['lon']; ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Title'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $note['Note']['title']; ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Body'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $note['Note']['body']; ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Public Flag'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $note['Note']['public_flag']; ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Created'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $note['Note']['created']; ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Modified'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $note['Note']['modified']; ?>
+
+ </dd>
+ </dl>
+</div>
+<div class="actions">
+ <ul>
+ <li><?php echo $html->link(__('Edit Note', true), array('action' => 'edit', $note['Note']['id'])); ?> </li>
+ <li><?php echo $html->link(__('Delete Note', true), array('action' => 'delete', $note['Note']['id']), null, sprintf(__('Are you sure you want to delete # %s?', true), $note['Note']['id'])); ?> </li>
+ <li><?php echo $html->link(__('List Notes', true), array('action' => 'index')); ?> </li>
+ <li><?php echo $html->link(__('New Note', true), array('action' => 'add')); ?> </li>
+ <li><?php echo $html->link(__('List Members', true), array('controller' => 'members', 'action' => 'index')); ?> </li>
+ <li><?php echo $html->link(__('New Member', true), array('controller' => 'members', 'action' => 'add')); ?> </li>
+ </ul>
+</div>
--- /dev/null
+<div class="notes form">
+<?php echo $form->create('Note');?>
+ <fieldset>
+ <legend><?php __('Edit Note');?></legend>
+ <?php
+ echo $form->input('id');
+ echo $form->input('member_id');
+ echo $form->input('lat');
+ echo $form->input('lon');
+ echo $form->input('title');
+ echo $form->input('body');
+ echo $form->input('public_flag');
+ ?>
+ </fieldset>
+<?php echo $form->end('Submit');?>
+</div>
+<div class="actions">
+ <ul>
+ <li><?php echo $html->link(__('Delete', true), array('action' => 'delete', $form->value('Note.id')), null, sprintf(__('Are you sure you want to delete # %s?', true), $form->value('Note.id'))); ?></li>
+ <li><?php echo $html->link(__('List Notes', true), array('action' => 'index'));?></li>
+ <li><?php echo $html->link(__('List Members', true), array('controller' => 'members', 'action' => 'index')); ?> </li>
+ <li><?php echo $html->link(__('New Member', true), array('controller' => 'members', 'action' => 'add')); ?> </li>
+ </ul>
+</div>
--- /dev/null
+<div class="notes index">
+<h2><?php __('Notes');?></h2>
+<p>
+<?php
+echo $paginator->counter(array(
+'format' => __('Page %page% of %pages%, showing %current% records out of %count% total, starting on record %start%, ending on %end%', true)
+));
+?></p>
+<table cellpadding="0" cellspacing="0">
+<tr>
+ <th><?php echo $paginator->sort('id');?></th>
+ <th><?php echo $paginator->sort('member_id');?></th>
+ <th><?php echo $paginator->sort('lat');?></th>
+ <th><?php echo $paginator->sort('lon');?></th>
+ <th><?php echo $paginator->sort('title');?></th>
+ <th><?php echo $paginator->sort('body');?></th>
+ <th><?php echo $paginator->sort('public_flag');?></th>
+ <th><?php echo $paginator->sort('created');?></th>
+ <th><?php echo $paginator->sort('modified');?></th>
+ <th class="actions"><?php __('Actions');?></th>
+</tr>
+<?php
+$i = 0;
+foreach ($notes as $note):
+ $class = null;
+ if ($i++ % 2 == 0) {
+ $class = ' class="altrow"';
+ }
+?>
+ <tr<?php echo $class;?>>
+ <td>
+ <?php echo $note['Note']['id']; ?>
+ </td>
+ <td>
+ <?php echo $html->link($note['Member']['id'], array('controller' => 'members', 'action' => 'view', $note['Member']['id'])); ?>
+ </td>
+ <td>
+ <?php echo $note['Note']['lat']; ?>
+ </td>
+ <td>
+ <?php echo $note['Note']['lon']; ?>
+ </td>
+ <td>
+ <?php echo $note['Note']['title']; ?>
+ </td>
+ <td>
+ <?php echo $note['Note']['body']; ?>
+ </td>
+ <td>
+ <?php echo $note['Note']['public_flag']; ?>
+ </td>
+ <td>
+ <?php echo $note['Note']['created']; ?>
+ </td>
+ <td>
+ <?php echo $note['Note']['modified']; ?>
+ </td>
+ <td class="actions">
+ <?php echo $html->link(__('View', true), array('action' => 'view', $note['Note']['id'])); ?>
+ <?php echo $html->link(__('Edit', true), array('action' => 'edit', $note['Note']['id'])); ?>
+ <?php echo $html->link(__('Delete', true), array('action' => 'delete', $note['Note']['id']), null, sprintf(__('Are you sure you want to delete # %s?', true), $note['Note']['id'])); ?>
+ </td>
+ </tr>
+<?php endforeach; ?>
+</table>
+</div>
+<div class="paging">
+ <?php echo $paginator->prev('<< '.__('previous', true), array(), null, array('class'=>'disabled'));?>
+ | <?php echo $paginator->numbers();?>
+ <?php echo $paginator->next(__('next', true).' >>', array(), null, array('class' => 'disabled'));?>
+</div>
+<div class="actions">
+ <ul>
+ <li><?php echo $html->link(__('New Note', true), array('action' => 'add')); ?></li>
+ <li><?php echo $html->link(__('List Members', true), array('controller' => 'members', 'action' => 'index')); ?> </li>
+ <li><?php echo $html->link(__('New Member', true), array('controller' => 'members', 'action' => 'add')); ?> </li>
+ </ul>
+</div>
--- /dev/null
+<div class="notes view">
+<h2><?php __('Note');?></h2>
+ <dl><?php $i = 0; $class = ' class="altrow"';?>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Id'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $note['Note']['id']; ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Member'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $html->link($note['Member']['id'], array('controller' => 'members', 'action' => 'view', $note['Member']['id'])); ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Lat'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $note['Note']['lat']; ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Lon'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $note['Note']['lon']; ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Title'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $note['Note']['title']; ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Body'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $note['Note']['body']; ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Public Flag'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $note['Note']['public_flag']; ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Created'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $note['Note']['created']; ?>
+
+ </dd>
+ <dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Modified'); ?></dt>
+ <dd<?php if ($i++ % 2 == 0) echo $class;?>>
+ <?php echo $note['Note']['modified']; ?>
+
+ </dd>
+ </dl>
+</div>
+<div class="actions">
+ <ul>
+ <li><?php echo $html->link(__('Edit Note', true), array('action' => 'edit', $note['Note']['id'])); ?> </li>
+ <li><?php echo $html->link(__('Delete Note', true), array('action' => 'delete', $note['Note']['id']), null, sprintf(__('Are you sure you want to delete # %s?', true), $note['Note']['id'])); ?> </li>
+ <li><?php echo $html->link(__('List Notes', true), array('action' => 'index')); ?> </li>
+ <li><?php echo $html->link(__('New Note', true), array('action' => 'add')); ?> </li>
+ <li><?php echo $html->link(__('List Members', true), array('controller' => 'members', 'action' => 'index')); ?> </li>
+ <li><?php echo $html->link(__('New Member', true), array('controller' => 'members', 'action' => 'add')); ?> </li>
+ </ul>
+</div>