use the custom assigned-to value if the editor is showing

pull/14/head
Tim Su 14 years ago
parent 73f9efaced
commit 5b18b5cc0a

@ -337,11 +337,10 @@ public class EditPeopleActivity extends Activity {
Flags.set(Flags.REFRESH); Flags.set(Flags.REFRESH);
try { try {
JSONObject userJson; JSONObject userJson;
AssignedToUser assignedTo = (AssignedToUser) assignedSpinner.getSelectedItem(); if(assignedCustom.getVisibility() == View.VISIBLE)
if(assignedTo == null)
userJson = PeopleContainer.createUserJson(assignedCustom); userJson = PeopleContainer.createUserJson(assignedCustom);
else else
userJson = assignedTo.user; userJson = ((AssignedToUser) assignedSpinner.getSelectedItem()).user;
if(userJson == null || userJson.optLong("id", -1) == 0) { if(userJson == null || userJson.optLong("id", -1) == 0) {
task.setValue(Task.USER_ID, 0L); task.setValue(Task.USER_ID, 0L);
task.setValue(Task.USER, "{}"); task.setValue(Task.USER, "{}");

Loading…
Cancel
Save