Unbreak NSUpload.updateProfileSwitch methods.
This commit is contained in:
parent
a4e9cb4976
commit
5a6af7f6d5
1 changed files with 2 additions and 2 deletions
|
@ -310,7 +310,7 @@ public class NSUpload {
|
||||||
data.put("timeshift", profileSwitch.timeshift);
|
data.put("timeshift", profileSwitch.timeshift);
|
||||||
data.put("percentage", profileSwitch.percentage);
|
data.put("percentage", profileSwitch.percentage);
|
||||||
}
|
}
|
||||||
data.put("created_at", getNextAvailableSecond(profileSwitch.date));
|
data.put("created_at", DateUtil.toISOString(profileSwitch.date));
|
||||||
data.put("enteredBy", MainApp.instance().getString(R.string.app_name));
|
data.put("enteredBy", MainApp.instance().getString(R.string.app_name));
|
||||||
if (profileSwitch._id != null) {
|
if (profileSwitch._id != null) {
|
||||||
Context context = MainApp.instance().getApplicationContext();
|
Context context = MainApp.instance().getApplicationContext();
|
||||||
|
@ -337,7 +337,7 @@ public class NSUpload {
|
||||||
if (data.has("notes")) prebolus.put("notes", data.get("notes"));
|
if (data.has("notes")) prebolus.put("notes", data.get("notes"));
|
||||||
long mills = DateUtil.fromISODateString(data.getString("created_at")).getTime();
|
long mills = DateUtil.fromISODateString(data.getString("created_at")).getTime();
|
||||||
Date preBolusDate = new Date(mills + data.getInt("preBolus") * 60000L + 1000L);
|
Date preBolusDate = new Date(mills + data.getInt("preBolus") * 60000L + 1000L);
|
||||||
prebolus.put("created_at", getNextAvailableSecond(preBolusDate.getTime()));
|
prebolus.put("created_at", DateUtil.toISOString(preBolusDate.getTime()));
|
||||||
uploadCareportalEntryToNS(prebolus);
|
uploadCareportalEntryToNS(prebolus);
|
||||||
}
|
}
|
||||||
Context context = MainApp.instance().getApplicationContext();
|
Context context = MainApp.instance().getApplicationContext();
|
||||||
|
|
Loading…
Reference in a new issue