Skip to content

Commit b95ce42

Browse files
committed
manage to fix submenus display errors
1 parent b449429 commit b95ce42

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

application/controllers/Menu.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@ public function save()
160160
if (!empty($data['title'])) {
161161
$data['id'] = $this->input->post('menu_id');
162162
$data['url'] = $this->input->post('url');
163-
$data['class'] = $this->input->post('class');
163+
// $data['class'] = $this->input->post('class');
164164

165165
$item_moved = false;
166166
$group_id = $this->input->post('group_id');
@@ -189,7 +189,7 @@ public function save()
189189
$response['status'] = 1;
190190
$d['title'] = $data['title'];
191191
$d['url'] = $data['url'];
192-
$d['klass'] = $data['class']; //klass instead of class because of an error in js
192+
// $d['klass'] = $data['class']; //klass instead of class because of an error in js
193193
$response['menu'] = $d;
194194
}
195195
} else {

assets/js/menu.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ jQuery(function ($) {
136136
$('body').on('click', '.edit-menu', function () {
137137
var menu_id = $(this).next().next().val();
138138
var menu_div = $(this).parent().parent();
139-
139+
console.log(_BASE_URL + 'menu/edit/' + menu_id);
140140
var li = $(this).closest('li');
141141
gbox.show({
142142
type: 'ajax',
@@ -148,12 +148,12 @@ jQuery(function ($) {
148148
url: $('#gbox form').attr('action'),
149149
data: $('#gbox form').serialize(),
150150
success: function (data) {
151+
151152
switch (data.status) {
152153
case 1:
153154
gbox.hide();
154155
menu_div.find('.ns-title').html(data.menu.title);
155156
menu_div.find('.ns-url').html(data.menu.url);
156-
// menu_div.find('.ns-class').html(data.menu.klass);
157157
break;
158158
case 2:
159159
gbox.hide();

0 commit comments

Comments
 (0)