Beispiel #1
0
def index():
    branch = None
    commit = None
    try:
        branch, commit = util.getGitInfo()
    except:
        pass

    global debug

    return render_template(
        "index.jinja2",
        ajaxBaseUrl=BASEURL,
        webcamStream=settings().get(["webcam", "stream"]),
        enableTimelapse=(settings().get(["webcam", "snapshot"]) is not None
                         and settings().get(["webcam", "ffmpeg"]) is not None),
        enableGCodeVisualizer=settings().get(["feature", "gCodeVisualizer"]),
        enableTemperatureGraph=settings().get(["feature", "temperatureGraph"]),
        enableSystemMenu=settings().get(["system"]) is not None
        and settings().get(["system", "actions"]) is not None
        and len(settings().get(["system", "actions"])) > 0,
        enableAccessControl=userManager is not None,
        enableSdSupport=settings().get(["feature", "sdSupport"]),
        firstRun=settings().getBoolean(["server", "firstRun"])
        and (userManager is None or not userManager.hasBeenCustomized()),
        debug=debug,
        gitBranch=branch,
        gitCommit=commit)
Beispiel #2
0
def index():
    branch = None
    commit = None
    try:
        branch, commit = util.getGitInfo()
    except:
        pass

    return render_template(
        "index.jinja2",
        webcamStream=settings.get("webcam", "stream"),
        enableTimelapse=(settings.get("webcam", "snapshot") is not None and settings.get(
            "webcam", "ffmpeg") is not None),
        enableGCodeVisualizer=settings.get("features", "gcode_visualizer"),
        enableTemperatureGraph=settings.get("features", "temperature_graph"),
        #enableSystemMenu=settings.get(["system"]) is not None and settings.get(
            #["system", "actions"]) is not None and len(settings.get(["system", "actions"])) > 0,
        #XXX: restore this
        enableSystemMenu = False,
        enableAccessControl=userManager is not None,
        enableSdSupport=settings.get("features", "sd_support"),
        firstRun=settings.get("server", "first_run") and (
            userManager is None or not userManager.hasBeenCustomized()),
        debug=debug,
        gitBranch=branch,
        gitCommit=commit
    )
Beispiel #3
0
def index():
	branch = None
	commit = None
	try:
		branch, commit = util.getGitInfo()
	except:
		pass

	global debug

	return render_template(
		"index.jinja2",
		ajaxBaseUrl=BASEURL,
		webcamStream=settings().get(["webcam", "stream"]),
		enableTimelapse=(settings().get(["webcam", "snapshot"]) is not None and settings().get(["webcam", "ffmpeg"]) is not None),
		enableGCodeVisualizer=settings().get(["feature", "gCodeVisualizer"]),
		enableTemperatureGraph=settings().get(["feature", "temperatureGraph"]),
		enableSystemMenu=settings().get(["system"]) is not None and settings().get(["system", "actions"]) is not None and len(settings().get(["system", "actions"])) > 0,
		enableAccessControl=userManager is not None,
		enableSdSupport=settings().get(["feature", "sdSupport"]),
		firstRun=settings().getBoolean(["server", "firstRun"]) and (userManager is None or not userManager.hasBeenCustomized()),
		debug=debug,
		gitBranch=branch,
		gitCommit=commit
	)
Beispiel #4
0
def index():
	branch = None
	commit = None
	try:
		branch, commit = util.getGitInfo()
	except:
		pass

	return render_template(
		"index.jinja2",
		ajaxBaseUrl=BASEURL,
		webcamStream=settings().get(["webcam", "stream"]),
		enableTimelapse=(settings().get(["webcam", "snapshot"]) is not None and settings().get(["webcam", "ffmpeg"]) is not None),
		enableGCodeVisualizer=settings().get(["feature", "gCodeVisualizer"]),
		enableSystemMenu=settings().get(["system"]) is not None and settings().get(["system", "actions"]) is not None and len(settings().get(["system", "actions"])) > 0,
		enableAccessControl=userManager is not None,
		enableSdSupport=settings().get(["feature", "sdSupport"]),
		gitBranch=branch,
		gitCommit=commit
	)
Beispiel #5
0
def index():
    branch = None
    commit = None
    try:
        branch, commit = util.getGitInfo()
    except:
        pass

    return render_template(
        "index.jinja2",
        ajaxBaseUrl=BASEURL,
        webcamStream=settings().get(["webcam", "stream"]),
        enableTimelapse=(settings().get(["webcam", "snapshot"]) is not None
                         and settings().get(["webcam", "ffmpeg"]) is not None),
        enableGCodeVisualizer=settings().get(["feature", "gCodeVisualizer"]),
        enableSystemMenu=settings().get(["system"]) is not None
        and settings().get(["system", "actions"]) is not None
        and len(settings().get(["system", "actions"])) > 0,
        enableAccessControl=userManager is not None,
        enableSdSupport=settings().get(["feature", "sdSupport"]),
        gitBranch=branch,
        gitCommit=commit)