From 308998cde989eeb627b288ae31be382c22951b4d Mon Sep 17 00:00:00 2001 From: Manuel Cillero Date: Wed, 20 Sep 2017 00:26:05 +0200 Subject: [PATCH] Preparing SuiteDesk to display always the dashboard with a pair number of items --- modules/storm/storm.module | 17 +++++++++++++---- themes/zuitedesk/css/suitedesk.css | 3 +++ themes/zuitedesk/images/storm/search.png | Bin 0 -> 1256 bytes themes/zuitedesk/zuitedesk.info | 2 +- 4 files changed, 17 insertions(+), 5 deletions(-) create mode 100644 themes/zuitedesk/images/storm/search.png diff --git a/modules/storm/storm.module b/modules/storm/storm.module index a7af929..1a4f100 100644 --- a/modules/storm/storm.module +++ b/modules/storm/storm.module @@ -989,6 +989,10 @@ function storm_dashboard($type = 'page') { $link_blocks = storm_dashboard_get_links(TRUE, $type); if (!empty($link_blocks)) { + /* ALWAYS DISPLAY A PAIR NUMBER OF ITEMS + if (count($link_blocks) % 20) { + array_pop($link_blocks); + } */ // DIVIDE LINKS INTO TWO BLOCKS $count = ceil(count($link_blocks) / 2); $link_blocks = array_chunk($link_blocks, $count); @@ -1132,20 +1136,25 @@ function storm_storm_dashboard_links($type) { 'title' => t('Attributes'), 'icon' => 'stormattributes-item', 'path' => 'attributes', - 'params' => array(), 'access_arguments' => 'Storm: access administration pages', - 'map' => array(), 'weight' => 180, ); $links[] = array( + 'theme' => 'storm_dashboard_link', 'title' => t('Configuration'), 'icon' => 'stormconfiguration-item', 'path' => 'admin/settings/suitedesk', - 'params' => array(), 'access_arguments' => 'Storm: access administration pages', - 'map' => array(), 'weight' => 190, ); +/* $links[] = array( + 'theme' => 'storm_dashboard_link', + 'title' => t('Search in SuiteDesk'), + 'icon' => 'stormsearch-item', + 'path' => 'search', + 'access_arguments' => 'access content', + 'weight' => 200, + ); LAST ITEM TO REMOVE IF THERE IS AN ODD NUMBER OF ITEMS */ } return $links; } diff --git a/themes/zuitedesk/css/suitedesk.css b/themes/zuitedesk/css/suitedesk.css index 61464dc..ac8805a 100644 --- a/themes/zuitedesk/css/suitedesk.css +++ b/themes/zuitedesk/css/suitedesk.css @@ -472,6 +472,9 @@ dt.stormcomponent span.stormlinks-count + a > img { #stormconfiguration-item { background: transparent url(../images/storm/configuration.png) no-repeat top left; } +#stormsearch-item { + background: transparent url(../images/storm/search.png) no-repeat top left; +} /* * "SuiteDesk" list & filter. diff --git a/themes/zuitedesk/images/storm/search.png b/themes/zuitedesk/images/storm/search.png new file mode 100644 index 0000000000000000000000000000000000000000..8a1597bf9187a5181be941535112b8e0fb6a2d14 GIT binary patch literal 1256 zcmVP)boTXu_ez;8ct_k@m#%5L|fNcXNcGk)2~Fl7Ql|4 zz0Gn{0HU$lIj-k57?A@1(J+AXMC@k2-b@mad;s?XAYbQ@?KrD@J6pa90zfxZ?$YY>4d^%mTf=Y-`!RWpop1Eh-euRe?-Ip@TB(iv1lwYf6N|;#_Cpj zp1Vmz93noiNYyY|$9g)O(|_p16D6LTnI$5_MAY8j-9A_rt6ix*-5{cgh%d9n@!rms zBRK(7EUKT89vSHs(f1MYB_evFudDSR?u^D0CX*gX10W){nR#pPzLpiG^J|Jl3J0Yuoc;CbHrfdCHdZaPlH#{t0g^jpz*9ghVdJu*B+d*1qN5~z0%b+x*IOR*ws z$c90td9K%3T2+%%C`u}yj%cmBjWHnNL1NyJQ#-b8J4HkdelFCBmJdp+YMda(E8>Zn zFmg~t7ZNdS$9cJDZ}a(_+i~UMrIDeb^ieS~Q)LU&DPmgFx36{ojW#NsUy~Hkn?>Yq ze@fci-`%!$%o9;^*$WfST^QIUT9=Dx+aESg0cZzs0>Bvn1ptZ^spUq@T_PF)t^(Le z#BV!}BdI+*z8u#~IA_7q=lm937$6F}lu}!aF$n;xi1;^)xw2Xq+7xN<%W_In`etBGDc`i~~RlCW} zq}M2=U;tQ_z3os}>++jc^Z!exPn-H85$_if7?F+ndCp5^Rkg(xi|U=*0`T6JjXD$x zts=H6s-w~MR|c=X<7P5Fp6gcMmJp0eUHxk3?1h1^jFAUP5klcG4(@4Ix7-7xva_)v zW82O)i|uTy6Ab)ahjEML%y%dIADA&~7*MC!vey3a?TL$b