Var refuseurl='{PHP echo wmurl (" group/members ", array (" submit "=& gt;" Yes ", "status"=& gt; 2, "gid"=& gt; The $group (" id ")))} & amp; Uid='+ uid;
Var btnArray=[' cancel ', 'sure'];
Mui. Prompt (" please enter descr ', 'such as the reason of delete', '{$_W (" account ")/" name "}', btnArray, function (e) {
If (e.i ndex==1) {
If (e.v alue!=' ') {
Refuseurl +='& amp; Remark='+ e.v alue.//remark to descr field
Var Callback=function (obj) {
If (obj type=='success') {
$(' groupmemberitem '+ uid), remove ();//remove to delete
}
}
AjaxView (refuseurl, Callback);
} else {
Util. Toast (' please enter descr ', ' 'and' error ');
return false;
}
}
})
}
HTML code:
A great god, and this is a use delete data operation,
And I want to achieve is a modified data operation,
I now have a "yuangong" field of the default value is 0,
I want to use such a js to amend the "yuangong" the value of the field to 1
Because don't know how to write the operation to modify the data, since the consult becoming
Thank god!
CodePudding user response:
Wasn't a great god to help ah, maybe you will feel js modify data is not achieve them, but the js member can delete data, that attracts me now this js function to modify the data effectThe function RefusedApply (uid) {
Var refuseurl='{PHP echo wmurl (" group/members ", array (" submit "=& gt;" Yes ", "status"=& gt; 2, "gid"=& gt; The $group (" id ")))} & amp; Uid='+ uid;
Var btnArray=[' cancel ', 'sure'];
Mui. Prompt (" please enter descr ', 'such as the reason of delete', '{$_W (" account ")/" name "}', btnArray, function (e) {
If (e.i ndex==1) {
If (e.v alue!=' ') {
Refuseurl +='& amp; Remark='+ e.v alue.//remark to descr field
Var Callback=function (obj) {
If (obj type=='success') {
$(' groupmemberitem '+ uid), remove ();//remove to delete
}
}
AjaxView (refuseurl, Callback);
} else {
Util. Toast (' please enter descr ', ' 'and' error ');
return false;
}
}
})
}
HTML code:
This code is deleted members don't have any problems
What a great god, and to help change, make the js can modify the data,
Thank you for the great god
CodePudding user response:
No problem you can't directly use theChange interface to edit, click the edit button request API mandatory change yuangong field to 1 and then to obtain the list data
CodePudding user response:
A great god, and I don't know should how to delete the interface for editing interfaceStill hope the great god help some directions, how should the interface for editing
Thanks for a great god
CodePudding user response:
All say so clearly on the ground floor, add a judgment, change submitted address not to go, I don't know what you are entangled with theCodePudding user response:
This address how to write ah, I don't know, since I don't know what ask you these great godCodePudding user response: