|
|
|
|
@ -53,15 +53,15 @@ if __name__ == '__main__':
|
|
|
|
|
],
|
|
|
|
|
title="Setting the API",
|
|
|
|
|
form_height=5)
|
|
|
|
|
if choice0 == "cancel":
|
|
|
|
|
break
|
|
|
|
|
if choice0 == d.CANCEL:
|
|
|
|
|
exit(2)
|
|
|
|
|
(choice1, routine_mode) = d.menu("Choose the routine mode listed below.",
|
|
|
|
|
width=54,
|
|
|
|
|
choices=[("Fixed", "Fixed interval between each routine."),
|
|
|
|
|
("Ranged", "Randomly picks an interval in a range.")],
|
|
|
|
|
title="Routine Mode")
|
|
|
|
|
if choice1 == "cancel":
|
|
|
|
|
break
|
|
|
|
|
if choice1 == d.CANCEL:
|
|
|
|
|
exit(2)
|
|
|
|
|
else:
|
|
|
|
|
if routine_mode == "Fixed":
|
|
|
|
|
(choice2, interval) = d.inputbox("Enter the interval during each routine, in seconds",
|
|
|
|
|
@ -88,7 +88,7 @@ if __name__ == '__main__':
|
|
|
|
|
for item in interval:
|
|
|
|
|
item = int(item)
|
|
|
|
|
if choice2 == "cancel":
|
|
|
|
|
break
|
|
|
|
|
exit(2)
|
|
|
|
|
business_hour = True if d.yesno("Do you wanna enable business hours mode?\n"
|
|
|
|
|
"If you enabled this, the API will be only called from 9 to 5, "
|
|
|
|
|
"from Monday to Friday.",
|
|
|
|
|
@ -99,7 +99,7 @@ if __name__ == '__main__':
|
|
|
|
|
else parsed_arguments.temp_file_threshold),
|
|
|
|
|
title="Temporary file threshold")
|
|
|
|
|
if choice4 == "Cancel":
|
|
|
|
|
break
|
|
|
|
|
exit(2)
|
|
|
|
|
# Conclusion
|
|
|
|
|
if d.yesno("You've selected:\n"
|
|
|
|
|
"Client ID: {0}\n"
|
|
|
|
|
|