Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Comparing changes

Choose two branches to see what's changed or to start a new pull request. If you need to, you can also compare across forks.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also compare across forks.
base fork: ci-bonfire/Bonfire
...
head fork: ci-bonfire/Bonfire
  • 5 commits
  • 8 files changed
  • 0 commit comments
  • 1 contributor
Commits on Mar 19, 2013
@sourcejedi sourcejedi activities_js: remove dead code (out-of-date prototype)
This dead code tripped my grep for 'admin'.  I don't try to update it,
I just remove it so it doesn't turn up in grep.

As well as hardcoding  'admin' (should be SITE_AREA),
this wouldn't work without adding ci_csrf_token
(see Bonfire 0.6 changelog).
8b6353c
@sourcejedi sourcejedi Fix remaining hard-coded /admin links (affects database module)
Replace hard-coded 'admin' with SITE_AREA.

These links also omitted to use site_url (for sub-directory installs).
Using site_url directly would leave them a bit messy, so I used anchor()
instead.
4b23012
@sourcejedi sourcejedi database module: fix a couple of broken links
Links were missing the context segment (developer).
b2a9636
Commits on Mar 21, 2013
@sourcejedi sourcejedi AUTO_INCREMENT portability fix (#750)
AUTO_INCREMENT isn't portable SQL.  dbforge converts it to different types
in different databases, and they don't all work the same.

Inserting 0 or NULL into an AUTO_INCREMENT column is MySQL-specific.
It doesn't work in PostgreSQL.  Use the obvious portable approach of not
assigning a value to the AUTO_INCREMENT column.

It seems this approach obvious to most other people as well :).
This only affected one migration mentioned in issue #750,
and the creation of new roles.

There was similar-looking code in users and builder which shouldn't affect
anything, but I've tidied it away so we can be sure.
70306fe
@sourcejedi sourcejedi Merge branch 'develop' of github.com:ci-bonfire/Bonfire into develop a7be4a4
View
13 bonfire/migrations/003_Permission_system_upgrade.php
@@ -76,12 +76,17 @@ public function up()
{
if($field != 'role_id' && $field != 'permission_id')
{
- $this->db->query("INSERT INTO {$prefix}permissions VALUES (0,'{$field}','','active');");
+ $this->db->insert('permissions', array('name' => $field));
}
}
- $this->db->query("INSERT INTO {$prefix}permissions VALUES (0,'Permissions.Settings.View','Allow access to view the Permissions menu unders Settings Context','active');");
- $this->db->query("INSERT INTO {$prefix}permissions VALUES (0,'Permissions.Settings.Manage','Allow access to manage the Permissions in the system','active');");
-
+ $this->db->insert('permissions', array(
+ 'name' => 'Permissions.Settings.View',
+ 'description' => 'Allow access to view the Permissions menu unders Settings Context'
+ ));
+ $this->db->insert('permissions', array(
+ 'name' => 'Permissions.Settings.Manage',
+ 'description' => 'Allow access to manage the Permissions in the system',
+ ));
// create the new bf_role_permissions table
$this->dbforge->add_field("role_id int(11) NOT NULL");
View
16 bonfire/modules/activities/views/reports/activities_js.php
@@ -41,22 +41,6 @@ function submit_delete(event) {
"bLengthChange": false,
"aaSorting": [[3,'desc']],
"bAutoWidth": false,
-<?php
-/* This is for server side processing
- "bServerSide": true,
- 'sAjaxSource' : '<?php echo base_url(); ?>admin/reports/activities/ajax_activity',
- 'fnServerData' : function(sSource, aoData, fnCallback)
- {
- $.ajax({
- 'dataType': 'json',
- 'type' : 'POST',
- 'url' : sSource,
- 'data' : aoData,
- 'success' : fnCallback
- });
- },
-*/
-?>
"aoColumns": [
{ "sWidth": "10%" },
null,
View
4 bonfire/modules/builder/views/files/controller.php
@@ -277,10 +277,6 @@ public function edit()
*/
private function save_{$module_name_lower}(\$type='insert', \$id=0)
{
- if (\$type == 'update') {
- \$_POST['{$primary_key_field}'] = \$id;
- }
-
{validation_rules}
if (\$this->form_validation->run() === FALSE)
View
2  bonfire/modules/database/views/developer/backup.php
@@ -71,7 +71,7 @@
<div class="form-actions">
<button type="submit" name="backup" class="btn btn-primary" ><?php echo lang('db_backup'); ?></button> <?php echo lang('bf_or'); ?>
- <a href="/admin/developer/database"><?php echo lang('bf_action_cancel'); ?></a>
+ <?php echo anchor(SITE_AREA .'/developer/database', lang('bf_action_cancel')); ?>
</div>
<?php echo form_close(); ?>
View
2  bonfire/modules/database/views/developer/drop.php
@@ -22,7 +22,7 @@
<div class="actions">
<button type="submit" name="drop" class="btn btn-danger"><?php echo lang('bf_action_delete'); ?> <?php echo lang('db_tables'); ?></button> <?php echo lang('bf_or'); ?>
- <a href="/admin/database"><?php echo lang('bf_action_cancel'); ?></a>
+ <?php echo anchor(SITE_AREA .'/developer/database', lang('bf_action_cancel')); ?>
</div>
<?php endif; ?>
View
6 bonfire/modules/database/views/developer/restore.php
@@ -4,7 +4,7 @@
<h3><?php echo lang('db_restore_results'); ?>:</h3>
<div style="text-align: right; margin-bottom: 10px;">
- <a href="/admin/database/backups"><?php echo lang('db_back_to_tools'); ?></a>
+ <?php echo anchor(SITE_AREA .'/developer/database/backups', lang('db_back_to_tools')); ?>
</div>
<div class="content-box" style="padding: 15px">
@@ -12,7 +12,7 @@
</div>
<div class="text-right">
- <a href="/admin/database/backups"><?php echo lang('db_back_to_tools'); ?></a>
+ <?php echo anchor(SITE_AREA .'/developer/database/backups', lang('db_back_to_tools')); ?>
</div>
<?php else : ?>
@@ -31,7 +31,7 @@
<div class="form-actions">
<input type="submit" name="restore" class="btn btn-primary" value="<?php echo lang('db_restore'); ?>" /> <?php echo lang('bf_or'); ?>
- <a href="<?php echo site_url(SITE_AREA .'/developer/database/backups') ?>"><?php echo lang('bf_action_cancel'); ?></a>
+ <?php echo anchor(SITE_AREA .'/developer/database/backups', lang('bf_action_cancel')); ?>
</div>
<?php echo form_close(); ?>
View
2  bonfire/modules/roles/controllers/settings.php
@@ -297,8 +297,6 @@ private function save_role($type='insert', $id=0)
$this->form_validation->set_rules('default', 'lang:role_default_role', 'trim|is_numeric|max_length[1]');
$this->form_validation->set_rules('can_delete', 'lang:role_can_delete_role', 'trim|is_numeric|max_length[1]');
- $_POST['role_id'] = $id;
-
if ($this->form_validation->run() === FALSE)
{
return FALSE;
View
1  bonfire/modules/users/controllers/settings.php
@@ -497,7 +497,6 @@ private function save_user($type='insert', $id=0, $meta_fields=array(), $cur_rol
}
else
{
- $_POST['id'] = $id;
$this->form_validation->set_rules('email', lang('bf_email'), 'required|trim|unique[users.email,users.id]|valid_email|max_length[120]');
$this->form_validation->set_rules('password', lang('bf_password'), 'min_length[8]|max_length[120]|valid_password|matches[pass_confirm]');
$this->form_validation->set_rules('pass_confirm', lang('bf_password_confirm'), '');

No commit comments for this range

Something went wrong with that request. Please try again.