Verified Commit fb9af1f6 authored by Jan Wennrich's avatar Jan Wennrich 🎓

feat: reworked project side-panel header (#800)

parent 311415d2
......@@ -64,4 +64,26 @@
line-height: 36px !important;
margin: 0 !important;
width: 40px !important;
}
.quiqqer-project-panel .qui-panel-icon {
display: none;
}
.quiqqer-project-panel h2.qui-panel-title {
padding-left: 10px;
}
.quiqqer-project-panel-button-home {
width: 40px;
}
.quiqqer-project-panel-button-home .image-container {
float: left;
text-align: center;
width: 100%;
}
.quiqqer-project-panel-button-home .image-container span {
float: none;
}
\ No newline at end of file
......@@ -68,7 +68,7 @@ define('controls/projects/project/Panel', [
name : 'projects-panel',
project: false,
lang : false,
icon : 'fa fa-home'
icon : false
});
this.parent(options);
......@@ -79,18 +79,18 @@ define('controls/projects/project/Panel', [
title: Locale.get('quiqqer/system', 'projects.project.panel.title')
});
this.$Map = null;
this.$Map = null;
this.$projectmaps = {};
this.$Filter = null;
this.$Button = null;
this.$Filter = null;
this.$Button = null;
this.$ProjectList = null;
this.$ProjectList = null;
this.$ProjectContainer = null;
this.$ProjectSearch = null;
this.$ProjectContent = null;
this.$ProjectSearch = null;
this.$ProjectContent = null;
this.$LanguageSelect = null;
this.$MediaButton = null;
this.$MediaButton = null;
this.$__fx_run = false;
......@@ -150,6 +150,8 @@ define('controls/projects/project/Panel', [
var self = this,
Content = this.getContent();
this.getElm().addClass('quiqqer-project-panel');
Content.set(
'html',
......@@ -163,9 +165,9 @@ define('controls/projects/project/Panel', [
Content.setStyle('opacity', 0);
this.$ProjectContainer = Content.getElement('.project-container');
this.$ProjectList = Content.getElement('.project-list');
this.$ProjectSearch = Content.getElement('.project-search');
this.$ProjectContent = Content.getElement('.project-content');
this.$ProjectList = Content.getElement('.project-list');
this.$ProjectSearch = Content.getElement('.project-search');
this.$ProjectContent = Content.getElement('.project-content');
this.$ProjectContainer.setStyles({
height: 'calc(100% - 40px)'
......@@ -305,7 +307,7 @@ define('controls/projects/project/Panel', [
// title button
this.$Button = new QUIButton({
name : 'projects',
image : 'fa fa-arrow-circle-left',
icon : 'fa fa-home',
title : Locale.get('quiqqer/system', 'projects.project.panel.projectSelect'),
events: {
onClick: function (Btn, event) {
......@@ -339,6 +341,7 @@ define('controls/projects/project/Panel', [
this.$Button.getElm().removeClass('qui-button');
this.$Button.getElm().addClass('button');
this.$Button.getElm().addClass('btn-blue');
this.$Button.getElm().addClass('quiqqer-project-panel-button-home');
},
/**
......@@ -366,24 +369,26 @@ define('controls/projects/project/Panel', [
self.openProject();
self.Loader.hide();
return;
} else if (Object.getLength(result)) {
for (key in result) {
if (!result.hasOwnProperty(key)) {
continue;
}
} else {
if (Object.getLength(result)) {
for (key in result) {
if (!result.hasOwnProperty(key)) {
continue;
}
if (result[key].standard !== "1") {
continue;
}
if (result[key].standard !== "1") {
continue;
self.setAttribute('project', key);
self.setAttribute('lang', result[key].default_lang);
break;
}
self.setAttribute('project', key);
self.setAttribute('lang', result[key].default_lang);
break;
self.openProject();
self.Loader.hide();
return;
}
self.openProject();
self.Loader.hide();
return;
}
// no projects exists
......@@ -676,7 +681,7 @@ define('controls/projects/project/Panel', [
onChildClick : this.$openSitePanel,
onChildContextMenu: function (Item, MapItem, event) {
var title = MapItem.getAttribute('text') + ' - ' +
MapItem.getAttribute('value');
MapItem.getAttribute('value');
MapItem.getContextMenu().setTitle(title).setPosition(
event.page.x,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment