mirror of
https://github.com/DarkflameUniverse/NexusDashboard.git
synced 2024-11-25 06:57:19 +00:00
apparently some skills have no icon
add jinja debug helper restrict char_xml to gm 9 strip quoted from local desc
This commit is contained in:
parent
c6d624e154
commit
cf359e2c6b
@ -57,6 +57,10 @@ def create_app():
|
|||||||
if cdclient is not None:
|
if cdclient is not None:
|
||||||
cdclient.close()
|
cdclient.close()
|
||||||
|
|
||||||
|
@app.template_filter('debug')
|
||||||
|
def debug(text):
|
||||||
|
print(text)
|
||||||
|
|
||||||
# add the commands to flask cli
|
# add the commands to flask cli
|
||||||
app.cli.add_command(init_db)
|
app.cli.add_command(init_db)
|
||||||
app.cli.add_command(init_accounts)
|
app.cli.add_command(init_accounts)
|
||||||
|
@ -89,6 +89,7 @@ def view(id):
|
|||||||
|
|
||||||
@character_blueprint.route('/view_xml/<id>', methods=['GET'])
|
@character_blueprint.route('/view_xml/<id>', methods=['GET'])
|
||||||
@login_required
|
@login_required
|
||||||
|
@gm_level(9)
|
||||||
def view_xml(id):
|
def view_xml(id):
|
||||||
|
|
||||||
character_data = CharacterInfo.query.filter(CharacterInfo.id == id).first()
|
character_data = CharacterInfo.query.filter(CharacterInfo.id == id).first()
|
||||||
@ -107,6 +108,7 @@ def view_xml(id):
|
|||||||
|
|
||||||
@character_blueprint.route('/get_xml/<id>', methods=['GET'])
|
@character_blueprint.route('/get_xml/<id>', methods=['GET'])
|
||||||
@login_required
|
@login_required
|
||||||
|
@gm_level(9)
|
||||||
def get_xml(id):
|
def get_xml(id):
|
||||||
|
|
||||||
character_data = CharacterInfo.query.filter(CharacterInfo.id == id).first()
|
character_data = CharacterInfo.query.filter(CharacterInfo.id == id).first()
|
||||||
|
@ -271,6 +271,8 @@ def register_luclient_jinja_helpers(app):
|
|||||||
)[0]
|
)[0]
|
||||||
if desc in ("", None):
|
if desc in ("", None):
|
||||||
desc = None
|
desc = None
|
||||||
|
if desc:
|
||||||
|
desc = desc.strip('"')
|
||||||
return desc
|
return desc
|
||||||
|
|
||||||
@app.template_filter('get_item_set')
|
@app.template_filter('get_item_set')
|
||||||
|
@ -27,10 +27,12 @@
|
|||||||
{% set skill_desc = skill[0]|get_skill_desc %}
|
{% set skill_desc = skill[0]|get_skill_desc %}
|
||||||
{% if "IP" not in skill_desc and "AP" not in skill_desc and "LP" not in skill_desc and skill[0]|string not in skill_desc %}
|
{% if "IP" not in skill_desc and "AP" not in skill_desc and "LP" not in skill_desc and skill[0]|string not in skill_desc %}
|
||||||
<br/>
|
<br/>
|
||||||
<img src='{{ url_for('luclient.get_icon_iconid', id=skill[1]) }}'
|
{% if skill[1]%}
|
||||||
alt='Skill: '
|
<img src='{{ url_for('luclient.get_icon_iconid', id=skill[1]) }}'
|
||||||
width='32'
|
alt='Skill: '
|
||||||
height='32'>
|
width='32'
|
||||||
|
height='32'>
|
||||||
|
{% endif %}
|
||||||
{{ skill[0]|get_skill_desc }}
|
{{ skill[0]|get_skill_desc }}
|
||||||
<br/>
|
<br/>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
Loading…
Reference in New Issue
Block a user