diff --git a/setup.py b/setup.py index c56e2cc..4dce4e3 100644 --- a/setup.py +++ b/setup.py @@ -2,12 +2,12 @@ from setuptools import setup, find_packages -version = "1.0.1" +version = "2.0.1" setup( name="bika.ui", version=version, - description="Custom user interface for SENAITE LIMS", + description="Custom user interface for SENAITE LIMS 2", long_description='', classifiers=[ "Framework :: Plone", @@ -29,6 +29,8 @@ install_requires=[ "setuptools", "senaite.lims", + "collective.localstyles", + "z3c.jbot" ], extras_require={ "test": [ diff --git a/src/bika.ui.egg-info/PKG-INFO b/src/bika.ui.egg-info/PKG-INFO index 1553fac..68d1988 100644 --- a/src/bika.ui.egg-info/PKG-INFO +++ b/src/bika.ui.egg-info/PKG-INFO @@ -1,7 +1,7 @@ -Metadata-Version: 1.1 +Metadata-Version: 2.1 Name: bika.ui -Version: 1.0.1 -Summary: Custom user interface for SENAITE LIMS +Version: 2.0.1 +Summary: Custom user interface for SENAITE LIMS 2 Home-page: https://github.com/bika/bika.ui Author: BikaLabs Author-email: info@bikalabs.com @@ -13,3 +13,4 @@ Classifier: Framework :: Zope2 Classifier: Programming Language :: Python Classifier: Development Status :: 5 - Production/Stable Classifier: License :: OSI Approved :: GNU General Public License v2 (GPLv2) +Provides-Extra: test diff --git a/src/bika.ui.egg-info/SOURCES.txt b/src/bika.ui.egg-info/SOURCES.txt index 55a859e..6e0ddf8 100644 --- a/src/bika.ui.egg-info/SOURCES.txt +++ b/src/bika.ui.egg-info/SOURCES.txt @@ -1,3 +1,4 @@ +README.md setup.cfg setup.py src/bika/__init__.py @@ -11,5 +12,6 @@ src/bika.ui.egg-info/requires.txt src/bika.ui.egg-info/top_level.txt src/bika/ui/__init__.py src/bika/ui/interfaces.py +src/bika/ui/setuphandlers.py src/bika/ui/browser/__init__.py src/bika/ui/browser/view.py \ No newline at end of file diff --git a/src/bika.ui.egg-info/requires.txt b/src/bika.ui.egg-info/requires.txt index 89961c5..0963105 100644 --- a/src/bika.ui.egg-info/requires.txt +++ b/src/bika.ui.egg-info/requires.txt @@ -1,5 +1,7 @@ setuptools senaite.lims +collective.localstyles +z3c.jbot [test] Products.PloneTestCase diff --git a/src/bika/ui/configure.zcml b/src/bika/ui/configure.zcml index 296e0bd..5d78789 100644 --- a/src/bika/ui/configure.zcml +++ b/src/bika/ui/configure.zcml @@ -36,4 +36,9 @@ provides="Products.GenericSetup.interfaces.EXTENSION" /> + + + diff --git a/src/bika/ui/overrides/senaite.core.browser.viewlets.templates.colophon.pt b/src/bika/ui/overrides/senaite.core.browser.viewlets.templates.colophon.pt new file mode 100644 index 0000000..8d67cbc --- /dev/null +++ b/src/bika/ui/overrides/senaite.core.browser.viewlets.templates.colophon.pt @@ -0,0 +1,39 @@ +
+ +
+
+
+ +
+ +
+ +
+
+
+
diff --git a/src/bika/ui/overrides/senaite.core.browser.viewlets.templates.footer.pt b/src/bika/ui/overrides/senaite.core.browser.viewlets.templates.footer.pt new file mode 100644 index 0000000..9e9c373 --- /dev/null +++ b/src/bika/ui/overrides/senaite.core.browser.viewlets.templates.footer.pt @@ -0,0 +1,19 @@ + diff --git a/src/bika/ui/profiles/default/metadata.xml b/src/bika/ui/profiles/default/metadata.xml index dbf8d35..a9049fa 100644 --- a/src/bika/ui/profiles/default/metadata.xml +++ b/src/bika/ui/profiles/default/metadata.xml @@ -1,4 +1,7 @@ 1.0.1 + + profile-collective.localstyles:default + diff --git a/src/bika/ui/profiles/default/registry.xml b/src/bika/ui/profiles/default/registry.xml new file mode 100644 index 0000000..77d9510 --- /dev/null +++ b/src/bika/ui/profiles/default/registry.xml @@ -0,0 +1,38 @@ + + + + + + + SENAITE LIMS + This shows up in the title bar of browsers and in syndication feeds. + Site title + + Bika LIMS + + + + + + /++resource++bika.lims.images/bikalimslogo.png + This must be a URL relative to the site root. + False + Relative URL for the SENAITE toolbar logo + + /++resource++bika.lims.images/bikalimslogo.png + + + + + + Toolbar CSS + CSS styles for the toolbar logo + + + + + 50px + + + + diff --git a/src/bika/ui/profiles/default/structure/.objects b/src/bika/ui/profiles/default/structure/.objects new file mode 100644 index 0000000..1396ae9 --- /dev/null +++ b/src/bika/ui/profiles/default/structure/.objects @@ -0,0 +1 @@ +localstyles.css,File diff --git a/src/bika/ui/profiles/default/structure/localstyles.css/.data b/src/bika/ui/profiles/default/structure/localstyles.css/.data new file mode 100644 index 0000000..00cc7e7 --- /dev/null +++ b/src/bika/ui/profiles/default/structure/localstyles.css/.data @@ -0,0 +1,22 @@ +title: localstyles.css +description: +subjects: +language: en +effective: +expires: +creators: admin +contributors: +rights: +allow_discussion: +id: localstyles.css +exclude_from_nav: False +relatedItems: +MIME-Version: 1.0 +Content-Type: text/css +Content-Transfer-Encoding: base64 +Content-Disposition: attachment; filename*="utf-8''localstyles.css" +Portal-Type: File + +I3NlbmFpdGUtdG9vbGJhciB7CiAgICBiYWNrZ3JvdW5kLWNvbG9yOiB3aGl0ZTsKfQojc2VuYWl0 +ZS10b29sYmFyIGEgewogICAgY29sb3I6ICMyOTMzMzM7Cn0KI3NlbmFpdGUtdG9vbGJhciBhOmhv +dmVyIHsKICAgIGNvbG9yOiBkYXJrZ3JleTsKfQo= diff --git a/src/bika/ui/profiles/default/structure/localstyles.css/.objects b/src/bika/ui/profiles/default/structure/localstyles.css/.objects new file mode 100644 index 0000000..e69de29 diff --git a/src/bika/ui/setuphandlers.py b/src/bika/ui/setuphandlers.py new file mode 100644 index 0000000..0c479b3 --- /dev/null +++ b/src/bika/ui/setuphandlers.py @@ -0,0 +1,15 @@ +from bika.ui import logger +from bika.ui import PRODUCT_NAME +from bika.ui import PROFILE_ID + + +def post_install(portal_setup): + """Runs after the last import step of the *default* profile + This handler is registered as a *post_handler* in the generic setup profile + :param portal_setup: SetupTool + """ + logger.info("{} post-install handler [BEGIN]".format(PRODUCT_NAME.upper())) + context = portal_setup._getImportContext(PROFILE_ID) + portal = context.getSite() # noqa + + logger.info("{} post-install handler [DONE]".format(PRODUCT_NAME.upper())) diff --git a/src/bika/ui/static/lims/images/bikalimslogo.png b/src/bika/ui/static/lims/images/bikalimslogo.png new file mode 100644 index 0000000..e5fc57a Binary files /dev/null and b/src/bika/ui/static/lims/images/bikalimslogo.png differ diff --git a/src/bika/ui/static/lims/styles/localstyles.css b/src/bika/ui/static/lims/styles/localstyles.css new file mode 100644 index 0000000..780ff73 --- /dev/null +++ b/src/bika/ui/static/lims/styles/localstyles.css @@ -0,0 +1,9 @@ +#senaite-toolbar { + background-color: white; +} +#senaite-toolbar a { + color: #293333; +} +#senaite-toolbar a:hover { + color: darkgrey; +}