82 dataType: 'json', |
82 dataType: 'json', |
83 url: url, |
83 url: url, |
84 cache: false, |
84 cache: false, |
85 data: data, |
85 data: data, |
86 type: 'POST', |
86 type: 'POST', |
87 success: function(data, status, xhr) { |
87 success: function(data) { |
88 commit(true); |
88 if (data.error) { |
|
89 console.log('delete: ' + data.msg); |
|
90 alert('Fout: ' + data.msg); |
|
91 } else { |
|
92 console.log('delete: success'); |
|
93 } |
89 location.reload(true); |
94 location.reload(true); |
90 }, |
95 }, |
91 error: function(jqXHR, textStatus, errorThrown) { |
96 error: function(jqXHR, textStatus, errorThrown) { |
92 commit(false); |
97 commit(false); |
93 } |
98 } |
99 dataType: 'json', |
104 dataType: 'json', |
100 url: url, |
105 url: url, |
101 cache: false, |
106 cache: false, |
102 data: data, |
107 data: data, |
103 type: 'POST', |
108 type: 'POST', |
104 success: function(data, status, xhr) { |
109 success: function(data) { |
105 commit(true); |
110 if (data.error) { |
|
111 console.log('insert: ' + data.msg); |
|
112 alert('Fout: ' + data.msg); |
|
113 } else { |
|
114 console.log('insert: success'); |
|
115 } |
106 location.reload(true); |
116 location.reload(true); |
107 }, |
117 }, |
108 error: function(jqXHR, textStatus, errorThrown) { |
118 error: function(jqXHR, textStatus, errorThrown) { |
109 commit(false); |
119 commit(false); |
110 } |
120 } |
116 dataType: 'json', |
126 dataType: 'json', |
117 url: url, |
127 url: url, |
118 cache: false, |
128 cache: false, |
119 data: data, |
129 data: data, |
120 type: 'POST', |
130 type: 'POST', |
121 success: function(data, status, xhr) { |
131 success: function(data) { |
122 commit(true); |
132 if (data.error) { |
|
133 console.log('updaterow: ' + data.msg); |
|
134 alert('Fout: ' + data.msg); |
|
135 } else { |
|
136 console.log('updaterow: success'); |
|
137 } |
123 location.reload(true); |
138 location.reload(true); |
124 }, |
139 }, |
125 error: function(jqXHR, textStatus, errorThrown) { |
140 error: function(jqXHR, textStatus, errorThrown) { |
126 commit(false); |
141 commit(false); |
127 } |
142 } |