Add Pump Sources (only Dana currently has an Entry, but required I think for pump history uploaded in AAPS, or Prime/Fill/ReservoirChange from pump)

This commit is contained in:
Philoul 2021-04-03 18:51:36 +02:00
parent 41ffa873f1
commit be35597da4
11 changed files with 70 additions and 1 deletions

View file

@ -207,6 +207,49 @@ class Translator @Inject internal constructor(
Sources.ConfigBuilder -> TODO() Sources.ConfigBuilder -> TODO()
Sources.Overview -> TODO() Sources.Overview -> TODO()
Sources.Stats -> TODO() Sources.Stats -> TODO()
Sources.TreatmentDialog -> TODO()
Sources.InsulinDialog -> TODO()
Sources.CarbDialog -> TODO()
Sources.WizardDialog -> TODO()
Sources.QuickWizard -> TODO()
Sources.ExtendedBolusDialog -> TODO()
Sources.TTDialog -> TODO()
Sources.ProfileSwitchDialog -> TODO()
Sources.LoopDialog -> TODO()
Sources.TempBasalDialog -> TODO()
Sources.CalibrationDialog -> TODO()
Sources.FillDialog -> TODO()
Sources.BgCheck -> TODO()
Sources.SensorInsert -> TODO()
Sources.BatteryChange -> TODO()
Sources.Note -> TODO()
Sources.Exercise -> TODO()
Sources.Question -> TODO()
Sources.Announcement -> TODO()
Sources.Actions -> TODO()
Sources.BG -> TODO()
Sources.LocalProfile -> TODO()
Sources.Maintenance -> TODO()
Sources.NSProfile -> TODO()
Sources.Objectives -> TODO()
Sources.Dana -> TODO()
Sources.DanaR -> TODO()
Sources.DanaRC -> TODO()
Sources.DanaRv2 -> TODO()
Sources.DanaRS -> TODO()
Sources.Insight -> TODO()
Sources.Combo -> TODO()
Sources.Medtronic -> TODO()
Sources.Omnipod -> TODO()
Sources.OmnipodEros -> TODO()
Sources.OmnipodDash -> TODO()
Sources.MDI -> TODO()
Sources.VirtualPump -> TODO()
Sources.Treatments -> TODO()
Sources.Food -> TODO()
Sources.ConfigBuilder -> TODO()
Sources.Overview -> TODO()
Sources.Stats -> TODO()
*/ */
Sources.Automation -> resourceHelper.gs(R.string.automation) Sources.Automation -> resourceHelper.gs(R.string.automation)
Sources.Loop -> resourceHelper.gs(R.string.loop) Sources.Loop -> resourceHelper.gs(R.string.loop)

View file

@ -64,6 +64,19 @@ class UserEntryPresentationHelper @Inject constructor(
Sources.NSProfile -> R.drawable.ic_nightscout_profile Sources.NSProfile -> R.drawable.ic_nightscout_profile
Sources.Objectives -> R.drawable.ic_graduation Sources.Objectives -> R.drawable.ic_graduation
Sources.Pump -> R.drawable.ic_generic_icon Sources.Pump -> R.drawable.ic_generic_icon
Sources.Dana -> R.drawable.ic_danars_128
Sources.DanaR -> R.drawable.ic_danars_128
Sources.DanaRC -> R.drawable.ic_danars_128
Sources.DanaRv2 -> R.drawable.ic_danars_128
Sources.DanaRS -> R.drawable.ic_danars_128
Sources.Insight -> R.drawable.ic_insight_128
Sources.Combo -> R.drawable.ic_combo_128
Sources.Medtronic -> R.drawable.ic_veo_128
Sources.Omnipod -> R.drawable.ic_pod_128
Sources.OmnipodEros -> R.drawable.ic_pod_128
Sources.OmnipodDash -> R.drawable.ic_pod_128
Sources.MDI -> R.drawable.ic_ict
Sources.VirtualPump -> R.drawable.ic_virtual_pump
Sources.SMS -> R.drawable.ic_sms Sources.SMS -> R.drawable.ic_sms
Sources.Treatments -> R.drawable.ic_treatments Sources.Treatments -> R.drawable.ic_treatments
Sources.Wear -> R.drawable.ic_watch Sources.Wear -> R.drawable.ic_watch

View file

@ -110,7 +110,7 @@ class DanaFragment : DaggerFragment() {
binding.btconnection.setOnLongClickListener { binding.btconnection.setOnLongClickListener {
activity?.let { activity?.let {
OKDialog.showConfirmation(it, resourceHelper.gs(R.string.resetpairing)) { OKDialog.showConfirmation(it, resourceHelper.gs(R.string.resetpairing)) {
uel.log(Action.CLEAR_PAIRING_KEYS, Sources.Pump) uel.log(Action.CLEAR_PAIRING_KEYS, Sources.Dana)
(activePlugin.activePump as DanaPumpInterface).clearPairing() (activePlugin.activePump as DanaPumpInterface).clearPairing()
} }
} }

View file

@ -127,6 +127,19 @@ data class UserEntry(
NSProfile, //From NSProfile plugin NSProfile, //From NSProfile plugin
Objectives, //From Objectives plugin Objectives, //From Objectives plugin
Pump, //To update with one Source per pump Pump, //To update with one Source per pump
Dana, //Only one UserEntry in Common module Dana
DanaR, //No entry currently
DanaRC, //No entry currently
DanaRv2, //No entry currently
DanaRS, //No entry currently
Insight, //No entry currently
Combo, //No entry currently
Medtronic, //No entry currently
Omnipod, //No entry currently
OmnipodEros, //No entry currently
OmnipodDash, //No entry currently
MDI, //No entry currently
VirtualPump, //No entry currently
SMS, //From SMS plugin SMS, //From SMS plugin
Treatments, //From Treatments plugin Treatments, //From Treatments plugin
Wear, //From Wear plugin Wear, //From Wear plugin