change user api

This commit is contained in:
ibuler
2016-11-09 19:29:15 +08:00
parent ea3f8af161
commit 8d7759d22f
15 changed files with 266 additions and 254 deletions

View File

@@ -189,9 +189,9 @@ function activeNav() {
function APIUpdateAttr(props) {
// props = {url: .., body: , success: , error: , method: ,}
props = props || {};
success_message = props.success_message || 'Update Successfully!';
fail_message = props.fail_message || 'Error occurred while updating.';
var success_message = props.success_message || 'Update Successfully!';
var fail_message = props.fail_message || 'Error occurred while updating.';
console.log(props.body);
$.ajax({
url: props.url,
type: props.method || "PATCH",