-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c1c179f
commit cdda464
Showing
16 changed files
with
641 additions
and
159 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
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,24 @@ | ||
from .backend.property_manager import * | ||
#from .. import BaseHandler | ||
|
||
|
||
def get_plugin_handlers(): | ||
plugin_name = get_plugin_info()["name"] | ||
|
||
return [ | ||
(r'/{}'.format(plugin_name), HomeHandler), | ||
(r'/{}/'.format(plugin_name), HomeHandler), | ||
] | ||
|
||
|
||
def get_plugin_info(): | ||
return { | ||
"name": "property_manager", | ||
"entrypoints": [ | ||
{ | ||
"title": "Property manager", | ||
"url": "/property_manager", | ||
"icon": "bi-pc-display", | ||
} | ||
] | ||
} |
Empty file.
40 changes: 40 additions & 0 deletions
40
src/OpenIntranet/plugins/property_manager/backend/property_manager.py
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,40 @@ | ||
#!/usr/bin/python3 | ||
# -*- coding: utf-8 -*- | ||
import json | ||
from datetime import datetime, timedelta | ||
|
||
import bson.json_util | ||
import tornado | ||
import tornado.options | ||
from bson import ObjectId | ||
from dateutil.relativedelta import relativedelta | ||
from tornado.web import HTTPError | ||
|
||
from plugins import BaseHandler, password_hash | ||
from plugins import BaseHandlerOwnCloud | ||
from plugins.helpers import database_user as udb | ||
from plugins.helpers import str_ops | ||
from plugins.helpers.contract_generation import generate_contract | ||
from plugins.helpers.doc_keys import CONTRACT_DOC_KEYS | ||
from plugins.helpers.emails import generate_validation_token, generate_validation_message, send_email | ||
from plugins.helpers.exceptions import BadInputHTTPError, MissingInfoHTTPError, ForbiddenHTTPError | ||
from plugins.helpers.mdoc_ops import find_type_in_addresses, update_workspans_contract_id | ||
from plugins.helpers.owncloud_utils import get_file_url, generate_contracts_directory_path, \ | ||
generate_documents_directory_path | ||
from plugins.users.backend.helpers.api import ApiJSONEncoder | ||
|
||
|
||
|
||
""" | ||
Role: | ||
základní uživatel nemá speciální roli jelikož všichni jsou základními uživateli | ||
users-proprety_manager - spravce majetku | ||
users-sudo - Admin | ||
""" | ||
|
||
ROLE_SUDO = "users-sudo" | ||
|
||
class HomeHandler(BaseHandler): | ||
def get(self): | ||
|
||
self.render("../plugins/property_manager/frontend/property_manager.overview.hbs") |
68 changes: 68 additions & 0 deletions
68
src/OpenIntranet/plugins/property_manager/frontend/property_manager.overview.hbs
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,68 @@ | ||
{% extends "base.hbs" %} | ||
{% block title %} | Produkce, uvod{% end %} | ||
{% block body %} | ||
|
||
{% import datetime %} | ||
|
||
<nav style="margin: 0.5rem;" style="--bs-breadcrumb-divider: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' widtd='8' height='8'%3E%3Cpatd d='M2.5 0L1 1.5 3.5 4 1 6.5 2.5 8l4-4-4-4z' fill='currentColor'/%3E%3C/svg%3E");" aria-label="breadcrumb"> | ||
<ol class="breadcrumb"> | ||
<li class="breadcrumb-item"><a href="./../">Home</a></li> | ||
<li class="breadcrumb-item"><a href="#">Property manager</a></li> | ||
</ol> | ||
</nav> | ||
|
||
<div class="container-fluid row"> | ||
<div class="col-md-4 col-sm-12 col-12 bg-faded sidebar"> | ||
|
||
|
||
<div class="card"> | ||
<div class="card-body"> | ||
|
||
<div class="card-title"> | ||
<h5>Kategorie</h5> | ||
<div class="form-check form-switch"> | ||
<input class="form-check-input" type="checkbox" id="search_by_category"> | ||
<label class="form-check-label" for="search_by_category">Vyhledávat dle kategorií</label> | ||
</div> | ||
<a href="#" class="badge bg-primary" onclick="$('#category-tree').jstree('open_all')">Rozbalit vše</a> | ||
<a href="#" class="badge bg-primary" onclick="$('#category-tree').jstree('close_all')">Sbalit vše</a> | ||
<a href="#" class="badge bg-primary" onclick="$('#category-tree').jstree('select_all')">Vybrat vše</a> | ||
<a href="#" class="badge bg-primary" onclick="$('#category-tree').jstree('deselect_all')">Odznačit vše</a> | ||
</div> | ||
|
||
<div id="category-tree"> | ||
|
||
</div> | ||
|
||
</div> | ||
|
||
</div> | ||
|
||
</div> | ||
<div class="col-md-8 col-sm-12"> | ||
|
||
|
||
|
||
<div class="card"> | ||
<div class="card-body"> | ||
|
||
<div class="card-title"> | ||
<h5>Seznam majetku</h5> | ||
|
||
</div> | ||
|
||
<div id="category-tree"> | ||
|
||
</div> | ||
|
||
</div> | ||
|
||
</div> | ||
|
||
|
||
</div> | ||
</div> | ||
|
||
</script> | ||
|
||
{% end %} |
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
Oops, something went wrong.