-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
REST API provider to grab about information fontman/fontman-desktop#32
- Loading branch information
1 parent
bd5c90a
commit a3625aa
Showing
4 changed files
with
33 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
""" Settings controller | ||
Provides settings REST API for Fontman client GUI | ||
Created by Lahiru Pathirage @ Mooniak <[email protected]> on 5/2/2017 | ||
""" | ||
|
||
from datetime import date | ||
from flask import Blueprint, jsonify, request | ||
|
||
from service import SystemService | ||
|
||
settings_blueprint = Blueprint("settings_blueprint", __name__) | ||
|
||
|
||
@settings_blueprint.route("/settings/about") | ||
def find_app_info(): | ||
system = SystemService().find_system_info() | ||
return jsonify( | ||
{ | ||
"platform": system.platform, | ||
"version": system.version, | ||
"year": date.today().year | ||
} | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters