initial task is not executed
See original GitHub issueI may be missing something here, but the initial task is completely skipped…
public class MHCTaskProvider extends TaskProvider {
private HashMap<String, Task> map = new HashMap<>();
public MHCTaskProvider(Context context){
put(TASK_ID_INITIAL, createInitialTask(context));
put(TASK_ID_CONSENT, ConsentTask.create(context, TASK_ID_CONSENT));
put(TASK_ID_SIGN_IN, new SignInTask(context));
put(TASK_ID_SIGN_UP, new SignUpTask(context));
}
@Override
public Task get(String taskId) {
return map.get(taskId);
}
@Override
public void put(String id, Task task) {
map.put(id, task);
}
private Task createInitialTask(Context context){
List<Step> steps = new ArrayList<>();
FormStep additionalInfoForm = new FormStep("MedicalInfo", "", "");
additionalInfoForm.setStepTitle(R.string.task_inital_toolbar_title);
//Height
DecimalAnswerFormat heightFormat = new DecimalAnswerFormat(0, 210);
QuestionStep heightStep = new QuestionStep("height", "Height", heightFormat);
heightStep.setOptional(false);
//Weight
DecimalAnswerFormat weightFormat = new DecimalAnswerFormat(0, 150);
QuestionStep weightStep = new QuestionStep("weight", "Weight", weightFormat);
heightStep.setOptional(false);
//What time do you generally wake up?
DateAnswerFormat timeFormat = new DateAnswerFormat(AnswerFormat.DateAnswerStyle.Time);
QuestionStep wakeupStep = new QuestionStep("wakeuptime", "What time do you generally wake up?", timeFormat);
wakeupStep.setOptional(false);
//What time do you generally go to sleep?
QuestionStep sleepStep = new QuestionStep("sleeptime", "What time do you generally go to sleep?", timeFormat);
sleepStep.setOptional(false);
additionalInfoForm.setOptional(false);
//additionalInfoForm.setFormSteps(heightStep, weightStep, wakeupStep, sleepStep);
additionalInfoForm.setFormSteps(heightStep, weightStep);
steps.add(additionalInfoForm);
return new OrderedTask(TASK_ID_INITIAL, steps);
}
}
Issue Analytics
- State:
- Created 7 years ago
- Comments:10 (2 by maintainers)
Top Results From Across the Web
Task not executed ?! - FreeRTOS
Hello everybody ! I'm new in the world of FreeRTOS and I tried it on an Freescale HC12 card with the Help of...
Read more >Task Scheduler not running, triggering or starting programs
In this article, we are covering some basic and useful steps to fix the Task Scheduler not running issue in Windows 11/10.
Read more >Gradle task not executed if added as a dependency
1 Answer 1 ... I suppose the reason is within the phase when tasks are executed. tarTask is configured at the configuration phase...
Read more >doFirst() does not execute first, but only after task execution
I am in the process of converting a plugin from Groovy to Java. I have a Groovy task: task dofirsttest(type: Exec) { doLast{...
Read more >Task Scheduler not running or starting programs in Windows 10
While using Windows 10 on a regular basis, one can easily understand that the OS is a mixture of various background tasks and...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
all right, fixed! it was my “dummy” Data Provider messing with it. Thanks!
Thanks, that worked.