forked from bofh/fetsite
Compare commits
130 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
5f5fed7881 | ||
|
|
638795b8d3 | ||
|
|
1b3e5694c9 | ||
|
|
d7ff42dc18 | ||
|
|
37956e673d | ||
|
|
2f43d5966f | ||
|
|
df3b771048 | ||
|
|
c7267f9299 | ||
|
|
2afbd0fa45 | ||
|
|
165268d695 | ||
|
|
ad36b8dfc7 | ||
|
|
cc3eccd43d | ||
| 502aae5c27 | |||
| c2ebdcbefc | |||
| 734a137563 | |||
| 9f1de3d9d0 | |||
|
|
0f683ac974 | ||
|
|
5ffecf7087 | ||
|
|
965db4dec0 | ||
|
|
6aecb4b4a8 | ||
|
|
b1616a6d6d | ||
|
|
122bf6c6d4 | ||
|
|
829bdb97be | ||
|
|
6c91513ff8 | ||
|
|
d1a496a017 | ||
|
|
eb95f7a5e4 | ||
|
|
de225627b1 | ||
|
|
08aa459f57 | ||
|
|
2b6890a6e6 | ||
|
|
04ce26754a | ||
|
|
163e1adfc2 | ||
|
|
e5a5ec85ef | ||
|
|
256d9f09fb | ||
|
|
e3c6721811 | ||
|
|
e5f0d75b79 | ||
|
|
07bb853501 | ||
|
|
af5b081a3b | ||
|
|
24f3e90235 | ||
|
|
ef1135962e | ||
|
|
22cf26f76c | ||
|
|
0c7614b41d | ||
|
|
0fedeb2bde | ||
|
|
146885abae | ||
|
|
c38139d6f1 | ||
|
|
8cb6ec785c | ||
|
|
b8903c6d9a | ||
|
|
242d05f4fa | ||
|
|
070e0dfedb | ||
|
|
610e6ae3dd | ||
|
|
6c4873d869 | ||
|
|
09d5e7b880 | ||
|
|
6b37d44c9a | ||
|
|
20088b868f | ||
|
|
f1fbd3bef3 | ||
|
|
17a43097e7 | ||
|
|
3498535d8c | ||
|
|
d313e712f1 | ||
|
|
bb4adf2eb7 | ||
|
|
09532fc74c | ||
|
|
29d5c8dac7 | ||
|
|
926431c0a2 | ||
|
|
d95e1a3399 | ||
|
|
d6fa4e1dc7 | ||
|
|
6528e8a320 | ||
|
|
18beead785 | ||
|
|
3baf44c057 | ||
|
|
9ec7a76d4a | ||
|
|
3b6590f369 | ||
|
|
708911ba4e | ||
|
|
797d2a1d31 | ||
|
|
7ad484cdd7 | ||
|
|
aca92e1107 | ||
|
|
f13fbafaae | ||
|
|
f6738a5226 | ||
|
|
2f4a9e4f10 | ||
|
|
dff490163e | ||
|
|
20a7091800 | ||
|
|
ff49499204 | ||
|
|
8b3e1ee225 | ||
|
|
dc4f161ce4 | ||
|
|
5c5236062b | ||
|
|
43af1114e8 | ||
|
|
0772d51c71 | ||
|
|
f2293513c1 | ||
|
|
87cad802d7 | ||
|
|
2e4a0680df | ||
|
|
4ca664a091 | ||
|
|
02c766f428 | ||
|
|
75e5b8e267 | ||
|
|
7d008cb599 | ||
|
|
b1fc24af80 | ||
|
|
7477b028c5 | ||
|
|
fddaa0dcb6 | ||
|
|
4ed7e92385 | ||
|
|
82876f34a8 | ||
|
|
3d97153fa5 | ||
|
|
6e10830b83 | ||
|
|
8ad15aafd2 | ||
|
|
d4948fff5e | ||
|
|
8ea2109b27 | ||
|
|
f72466f1cd | ||
|
|
cba94e926c | ||
|
|
f522a83813 | ||
|
|
94d67463a9 | ||
|
|
38656a1e75 | ||
|
|
503b9eb732 | ||
|
|
ffee3b8dfb | ||
|
|
978f617131 | ||
|
|
cf2a8adf49 | ||
|
|
14e563ef95 | ||
|
|
5660cd7748 | ||
|
|
af5d055014 | ||
|
|
453dd7867d | ||
|
|
bbfb5e6a1d | ||
|
|
4ed35f184c | ||
|
|
37aab0ef59 | ||
|
|
c53d34191a | ||
|
|
61c5624b16 | ||
|
|
a1ef7028fd | ||
|
|
b5f1ae9e69 | ||
|
|
6a9fe8243b | ||
|
|
1f581ab819 | ||
|
|
e73315bd41 | ||
|
|
491e360141 | ||
|
|
28226df76c | ||
|
|
14598fbbd9 | ||
|
|
ffaa57c914 | ||
|
|
cd439ecf02 | ||
|
|
328adfe3a5 | ||
|
|
e0312386e7 |
3
.gitignore
vendored
3
.gitignore
vendored
@@ -51,4 +51,5 @@ Gemfile.lock
|
|||||||
/config/contact_topic.yml
|
/config/contact_topic.yml
|
||||||
.#*
|
.#*
|
||||||
.*
|
.*
|
||||||
!/.gitignore
|
!/.gitignore
|
||||||
|
*.pid
|
||||||
6
Gemfile
6
Gemfile
@@ -1,11 +1,11 @@
|
|||||||
source 'https://rubygems.org'
|
source 'https://rubygems.org'
|
||||||
|
gem 'rake', '~>11.0'
|
||||||
gem 'rails', '3.2.13'
|
gem 'rails', '3.2.13'
|
||||||
gem 'sprockets', '2.2.2'
|
gem 'sprockets', '2.2.2'
|
||||||
gem 'webrick', '1.3.1'
|
gem 'webrick', '1.3.1'
|
||||||
# Bundle edge Rails instead:
|
# Bundle edge Rails instead:
|
||||||
# gem 'rails', :git => 'git://github.com/rails/rails.git'
|
# gem 'rails', :git => 'git://github.com/rails/rails.git'
|
||||||
gem 'mysql2'
|
gem 'mysql2', '~>0.3.10'
|
||||||
gem 'sqlite3'
|
gem 'sqlite3'
|
||||||
gem 'execjs', '~>1.4.0'
|
gem 'execjs', '~>1.4.0'
|
||||||
|
|
||||||
@@ -136,4 +136,4 @@ gem 'blueimp-gallery-rails'
|
|||||||
|
|
||||||
gem 'shareable'
|
gem 'shareable'
|
||||||
|
|
||||||
gem 'sunspot_test'
|
gem 'sunspot_test'
|
||||||
|
|||||||
25
README
Normal file
25
README
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
SETUP:
|
||||||
|
|
||||||
|
install ruby 2.1.10
|
||||||
|
|
||||||
|
install requirements
|
||||||
|
apt-get ...
|
||||||
|
|
||||||
|
|
||||||
|
mkdir /srv/fetsite
|
||||||
|
cd /srv/fetsite
|
||||||
|
|
||||||
|
copy / fetch Gemfile
|
||||||
|
|
||||||
|
make User fetsite
|
||||||
|
|
||||||
|
|
||||||
|
bundle install
|
||||||
|
|
||||||
|
# Config Files kopieren:
|
||||||
|
cp /srv/fetsite/config/omniout_secrets.yml.example /srv/fetsite/config/omniout_secrets.yml
|
||||||
|
cp /srv/fetsite/config/omniout_secrets.yml.example /srv/fetsite/config/omniout_secrets.yml
|
||||||
|
touch crawler_config.yml
|
||||||
|
|
||||||
|
# Datenbank erstellen
|
||||||
|
rake db:migrate
|
||||||
BIN
app/assets/images/infoscreen_header_provisorisch.png
Normal file
BIN
app/assets/images/infoscreen_header_provisorisch.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 42 KiB |
134
app/assets/stylesheets/infoscreenframe.css
Normal file
134
app/assets/stylesheets/infoscreenframe.css
Normal file
@@ -0,0 +1,134 @@
|
|||||||
|
html {
|
||||||
|
background-color: #fff;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
|
body {
|
||||||
|
display: flex;
|
||||||
|
flex-flow: wrap;
|
||||||
|
height: 100vh;
|
||||||
|
justify-content: space-between;
|
||||||
|
flex-direction: column;
|
||||||
|
}
|
||||||
|
|
||||||
|
.header {
|
||||||
|
height: 200px;
|
||||||
|
width: 100%
|
||||||
|
}
|
||||||
|
|
||||||
|
svg {
|
||||||
|
padding-top: 2em;
|
||||||
|
}
|
||||||
|
|
||||||
|
.impulsPath {
|
||||||
|
fill: none;
|
||||||
|
stroke: #04669c;
|
||||||
|
stroke-miterlimit: 1;
|
||||||
|
stroke-width: 6px;
|
||||||
|
stroke-dasharray: 1946.243;
|
||||||
|
stroke-dashoffset: 0;
|
||||||
|
stroke-linejoin: round;
|
||||||
|
stroke-linecap: round;
|
||||||
|
animation: dash 10s ease-out infinite;
|
||||||
|
animation-direction: normal;
|
||||||
|
}
|
||||||
|
|
||||||
|
.FET-logotext-stroke {
|
||||||
|
fill: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
#FET-logotext {
|
||||||
|
opacity: 0;
|
||||||
|
animation: logotext 10s ease-in infinite;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
.content-area {
|
||||||
|
|
||||||
|
height: auto;
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer {
|
||||||
|
width: 100%;
|
||||||
|
height: 150px;
|
||||||
|
background-color: #04669c;
|
||||||
|
padding-bottom: 10px;
|
||||||
|
display: flex;
|
||||||
|
flex-wrap: nowrap;
|
||||||
|
justify-content: space-between;
|
||||||
|
color: #fff;
|
||||||
|
flex-basis: bottom;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer h3,
|
||||||
|
p {
|
||||||
|
margin: 0;
|
||||||
|
padding: 0 20px;
|
||||||
|
font-family: Helvetica, Arial;
|
||||||
|
letter-spacing: 0.1em;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer h3 {
|
||||||
|
padding-top: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer .adress {
|
||||||
|
margin: auto;
|
||||||
|
text-align: left;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer .contact {
|
||||||
|
margin: auto;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer .servicecontainer{
|
||||||
|
display: inline-flex;
|
||||||
|
margin: auto;
|
||||||
|
|
||||||
|
}
|
||||||
|
.footer .servicecontainer .servicetime {
|
||||||
|
margin: auto;
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer .servicecontainer .servicetime #time {
|
||||||
|
font-size: 0.7em
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer .servicecontainer .servicestatus{
|
||||||
|
margin: auto;
|
||||||
|
width:20px;
|
||||||
|
height: 100%
|
||||||
|
padding-right: 30px;
|
||||||
|
background-color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*K E Y F R A M E S*/
|
||||||
|
|
||||||
|
@keyframes dash {
|
||||||
|
from {
|
||||||
|
stroke-dashoffset: 1946.243;
|
||||||
|
opacity: 0;
|
||||||
|
stroke-width: 0.5;
|
||||||
|
}
|
||||||
|
to {
|
||||||
|
opacity: 1;
|
||||||
|
stroke-dashoffset: 0;
|
||||||
|
stroke-width: 5px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes logotext {
|
||||||
|
from {
|
||||||
|
opacity: 0;
|
||||||
|
}
|
||||||
|
to {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -62,7 +62,7 @@ u=current_user
|
|||||||
if ! u.try(:preferredtheme).nil? and ThemesForRails.available_theme_names.include?(u.preferredtheme)
|
if ! u.try(:preferredtheme).nil? and ThemesForRails.available_theme_names.include?(u.preferredtheme)
|
||||||
u.preferredtheme
|
u.preferredtheme
|
||||||
else
|
else
|
||||||
"blue1"
|
"blue2"
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ class HomeController < ApplicationController
|
|||||||
|
|
||||||
params[:month]= Date.today.month if params[:month].nil?
|
params[:month]= Date.today.month if params[:month].nil?
|
||||||
params[:year]= Date.today.year if params[:year].nil?
|
params[:year]= Date.today.year if params[:year].nil?
|
||||||
|
|
||||||
@calentries= (@rubriken.map {|r| r.calendar}).collect(&:calentries).flatten.select {|c| c.object !=nil}
|
@calentries= (@rubriken.map {|r| r.calendar}).collect(&:calentries).flatten.select {|c| c.object !=nil}
|
||||||
|
|
||||||
@starttopic= @themen = Thema.where(:id=>t).first
|
@starttopic= @themen = Thema.where(:id=>t).first
|
||||||
@@ -25,11 +25,16 @@ class HomeController < ApplicationController
|
|||||||
@neuigkeiten = Neuigkeit.accessible_by(current_ability, :show).where(flag_infoscreen: true)
|
@neuigkeiten = Neuigkeit.accessible_by(current_ability, :show).where(flag_infoscreen: true)
|
||||||
render layout: false
|
render layout: false
|
||||||
end
|
end
|
||||||
|
def verleihkalender
|
||||||
|
authorize! :verleihkalender, User
|
||||||
|
#@neuigkeiten = Neuigkeit.accessible_by(current_ability, :show).where(flag_infoscreen: true)
|
||||||
|
render layout: false
|
||||||
|
end
|
||||||
def kontakt
|
def kontakt
|
||||||
t=YAML.load_file("#{::Rails.root.to_s}/config/contact_topic.yml")
|
t=YAML.load_file("#{::Rails.root.to_s}/config/contact_topic.yml")
|
||||||
@themen = Thema.where(:id=>t)
|
@themen = Thema.where(:id=>t)
|
||||||
end
|
end
|
||||||
def treeview
|
def treeview
|
||||||
authorize! :doadmin, User
|
authorize! :doadmin, User
|
||||||
@themengruppen = Themengruppe.order(:priority).reverse
|
@themengruppen = Themengruppe.order(:priority).reverse
|
||||||
@themengruppen += Themengruppe.intern.order(:priority).reverse
|
@themengruppen += Themengruppe.intern.order(:priority).reverse
|
||||||
@@ -54,7 +59,7 @@ class HomeController < ApplicationController
|
|||||||
else
|
else
|
||||||
@logs = `tail -n #{lines} log/development.log | grep -v 'actionpack\\|railties\\|activesupport\\|::Translation'`
|
@logs = `tail -n #{lines} log/development.log | grep -v 'actionpack\\|railties\\|activesupport\\|::Translation'`
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
def startdev
|
def startdev
|
||||||
render 'setup_fetsite_dev'
|
render 'setup_fetsite_dev'
|
||||||
@@ -64,7 +69,7 @@ class HomeController < ApplicationController
|
|||||||
end
|
end
|
||||||
|
|
||||||
def search
|
def search
|
||||||
|
|
||||||
unless params['query'].nil? || params['query'].empty?
|
unless params['query'].nil? || params['query'].empty?
|
||||||
@results = Sunspot.search Neuigkeit,Rubrik, Fetprofile, Thema, Themengruppe, Lva, Studium, Modul, Modulgruppe, Gremium, Document do
|
@results = Sunspot.search Neuigkeit,Rubrik, Fetprofile, Thema, Themengruppe, Lva, Studium, Modul, Modulgruppe, Gremium, Document do
|
||||||
fulltext params['query']
|
fulltext params['query']
|
||||||
@@ -88,7 +93,7 @@ class HomeController < ApplicationController
|
|||||||
# @themen=Thema.search(params['query']).public
|
# @themen=Thema.search(params['query']).public
|
||||||
# end
|
# end
|
||||||
@themen=[]
|
@themen=[]
|
||||||
|
|
||||||
else
|
else
|
||||||
@neuigkeiten=[]
|
@neuigkeiten=[]
|
||||||
@fetprofiles=[]
|
@fetprofiles=[]
|
||||||
@@ -110,11 +115,10 @@ class HomeController < ApplicationController
|
|||||||
unless params[:themen].nil?
|
unless params[:themen].nil?
|
||||||
t=([t].flatten+params[:themen]).uniq
|
t=([t].flatten+params[:themen]).uniq
|
||||||
end
|
end
|
||||||
unless params[:rmthema].nil?
|
unless params[:rmthema].nil?
|
||||||
t=t-[params[:rmthema]]
|
t=t-[params[:rmthema]]
|
||||||
end
|
end
|
||||||
File.open("config/contact_topic.yml",'w'){|f| f.write(t.to_yaml)}
|
File.open("config/contact_topic.yml",'w'){|f| f.write(t.to_yaml)}
|
||||||
redirect_to admin_home_index_path
|
redirect_to admin_home_index_path
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ class RubrikenController < ApplicationController
|
|||||||
@rubriken= Rubrik.accessible_by(current_ability, :show)
|
@rubriken= Rubrik.accessible_by(current_ability, :show)
|
||||||
@neuigkeiten = Neuigkeit.accessible_by(current_ability, :list).page(params[:page]).per(3)
|
@neuigkeiten = Neuigkeit.accessible_by(current_ability, :list).page(params[:page]).per(3)
|
||||||
|
|
||||||
@calentries= (@rubriken.map {|r| r.calendar.calentries.of_month(Date.new(params[:year],params[:month],1))}).flatten.select {|c| c.object !=nil}
|
@calentries= (@rubriken.map {|r| r.calendar.calentries.of_month(Date.new(params[:year].to_i,params[:month].to_i,1))}).flatten.select {|c| c.object !=nil}
|
||||||
respond_to do |format|
|
respond_to do |format|
|
||||||
format.html
|
format.html
|
||||||
format.js {render action: :show}
|
format.js {render action: :show}
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ class Ability
|
|||||||
include CanCan::Ability
|
include CanCan::Ability
|
||||||
def initialize(user,request=nil,key=nil)
|
def initialize(user,request=nil,key=nil)
|
||||||
tunet=IPAddr.new("128.131.95.0/24")
|
tunet=IPAddr.new("128.131.95.0/24")
|
||||||
local=IPAddr.new("127.0.0.1")
|
local=IPAddr.new("127.0.0.1")
|
||||||
loggedin=!(user.nil?)
|
loggedin=!(user.nil?)
|
||||||
unless key.nil?
|
unless key.nil?
|
||||||
k=Key.find_by_uuid(key)
|
k=Key.find_by_uuid(key)
|
||||||
@@ -16,6 +16,9 @@ local=IPAddr.new("127.0.0.1")
|
|||||||
if (user.has_role?("fetuser") || user.has_role?("fetadmin") || tunet.include?(IPAddr.new(request.remote_ip)) || local.include?(IPAddr.new(request.remote_ip)))
|
if (user.has_role?("fetuser") || user.has_role?("fetadmin") || tunet.include?(IPAddr.new(request.remote_ip)) || local.include?(IPAddr.new(request.remote_ip)))
|
||||||
can :infoscreen, User
|
can :infoscreen, User
|
||||||
end
|
end
|
||||||
|
if (user.has_role?("fetuser") || user.has_role?("fetadmin") || tunet.include?(IPAddr.new(request.remote_ip)) || local.include?(IPAddr.new(request.remote_ip)))
|
||||||
|
can :verleihkalender, User
|
||||||
|
end
|
||||||
|
|
||||||
if( user.has_role?("fetuser") || user.has_role?("fetadmin"))
|
if( user.has_role?("fetuser") || user.has_role?("fetadmin"))
|
||||||
can [:show,:answer, :create,:new, :create_from_template, :flag], Survey::Question
|
can [:show,:answer, :create,:new, :create_from_template, :flag], Survey::Question
|
||||||
@@ -29,10 +32,10 @@ local=IPAddr.new("127.0.0.1")
|
|||||||
can [:delete,:flag_template], Survey::Question
|
can [:delete,:flag_template], Survey::Question
|
||||||
end
|
end
|
||||||
#---------------------------------------------------
|
#---------------------------------------------------
|
||||||
|
|
||||||
can [:index,:hide], Comment
|
can [:index,:hide], Comment
|
||||||
can :show, Comment
|
can :show, Comment
|
||||||
|
|
||||||
if loggedin
|
if loggedin
|
||||||
can [:create,:new], Comment
|
can [:create,:new], Comment
|
||||||
can [:comment], Comment
|
can [:comment], Comment
|
||||||
@@ -52,7 +55,7 @@ cannot :destroy, Comment
|
|||||||
can [:create, :show], Beispiel, flag_delete: false
|
can [:create, :show], Beispiel, flag_delete: false
|
||||||
if loggedin
|
if loggedin
|
||||||
can :like, Beispiel
|
can :like, Beispiel
|
||||||
can :dislike, Beispiel
|
can :dislike, Beispiel
|
||||||
end
|
end
|
||||||
if ((user.has_role?("moderator",Beispiel)) || user.has_role?("fetuser") || user.has_role?("fetadmin"))
|
if ((user.has_role?("moderator",Beispiel)) || user.has_role?("fetuser") || user.has_role?("fetadmin"))
|
||||||
can :flag, Beispiel
|
can :flag, Beispiel
|
||||||
@@ -76,22 +79,22 @@ cannot :destroy, Comment
|
|||||||
can :manage, Studium
|
can :manage, Studium
|
||||||
#can :manage, Beispiel
|
#can :manage, Beispiel
|
||||||
can :comment, Beispiel
|
can :comment, Beispiel
|
||||||
|
|
||||||
can :manage, Lecturer
|
can :manage, Lecturer
|
||||||
|
|
||||||
end
|
end
|
||||||
unless user.has_role?("fetadmin")
|
unless user.has_role?("fetadmin")
|
||||||
cannot :delete, Studium
|
cannot :delete, Studium
|
||||||
cannot :delete, Modulgruppe
|
cannot :delete, Modulgruppe
|
||||||
cannot :delete, Modul
|
cannot :delete, Modul
|
||||||
|
|
||||||
end
|
end
|
||||||
if user.has_role?("fetadmin")
|
if user.has_role?("fetadmin")
|
||||||
can [:index, :parse, :show], Crawlobject
|
can [:index, :parse, :show], Crawlobject
|
||||||
end
|
end
|
||||||
#-----------------------------------------------------
|
#-----------------------------------------------------
|
||||||
# Rechteverwaltung fuer Informationen
|
# Rechteverwaltung fuer Informationen
|
||||||
can [:show, :index,:faqs], Themengruppe, :public=>true
|
can [:show, :index,:faqs], Themengruppe, :public=>true
|
||||||
can [:show], Thema, :isdraft=>false, :themengruppe=>{:public=>true}
|
can [:show], Thema, :isdraft=>false, :themengruppe=>{:public=>true}
|
||||||
can :show, Frage
|
can :show, Frage
|
||||||
if loggedin
|
if loggedin
|
||||||
@@ -133,7 +136,7 @@ end
|
|||||||
unless user.has_role?("fetadmin")
|
unless user.has_role?("fetadmin")
|
||||||
cannot :delete, Gallery
|
cannot :delete, Gallery
|
||||||
end
|
end
|
||||||
|
|
||||||
#-----------------------------------------------------
|
#-----------------------------------------------------
|
||||||
# Rechteverwaltung fuer Mitarbeiter
|
# Rechteverwaltung fuer Mitarbeiter
|
||||||
can [:show, :index], Fetprofile
|
can [:show, :index], Fetprofile
|
||||||
@@ -149,7 +152,7 @@ end
|
|||||||
cannot :delete, Fetprofile
|
cannot :delete, Fetprofile
|
||||||
cannot :delete ,Gremium
|
cannot :delete ,Gremium
|
||||||
end
|
end
|
||||||
|
|
||||||
#-----------------------------------------------------
|
#-----------------------------------------------------
|
||||||
# Rechteverwaltung fuer Neuigkeiten
|
# Rechteverwaltung fuer Neuigkeiten
|
||||||
can :index, Rubrik
|
can :index, Rubrik
|
||||||
@@ -171,9 +174,9 @@ end
|
|||||||
can :shownonpublic, Rubrik
|
can :shownonpublic, Rubrik
|
||||||
can :manage, Nlink
|
can :manage, Nlink
|
||||||
end
|
end
|
||||||
if user.has_role?("newsadmin") || user.has_role?("fetadmin")
|
if user.has_role?("newsadmin") || user.has_role?("fetadmin")
|
||||||
can :addmoderator, Rubrik
|
can :addmoderator, Rubrik
|
||||||
end
|
end
|
||||||
if user.has_role?("fetadmin")
|
if user.has_role?("fetadmin")
|
||||||
can :addfetuser, User
|
can :addfetuser, User
|
||||||
can :addfetadmin, User
|
can :addfetadmin, User
|
||||||
@@ -184,8 +187,8 @@ end
|
|||||||
can :manage, User
|
can :manage, User
|
||||||
can :set_preferred_theme, User
|
can :set_preferred_theme, User
|
||||||
end
|
end
|
||||||
|
|
||||||
if user.has_role?("newsadmin") || user.has_role?( "fetadmin") || user.has_role?( "fetuser")
|
if user.has_role?("newsadmin") || user.has_role?( "fetadmin") || user.has_role?( "fetuser")
|
||||||
can :manage, Rubrik
|
can :manage, Rubrik
|
||||||
can :manage, Neuigkeit
|
can :manage, Neuigkeit
|
||||||
can :showunpublished, Neuigkeit
|
can :showunpublished, Neuigkeit
|
||||||
@@ -200,7 +203,7 @@ end
|
|||||||
can [:show, :edit, :update,:new,:create,:write, :write_etherpad, :read_from_etherpad, :dump_to_etherpad, :search], Document
|
can [:show, :edit, :update,:new,:create,:write, :write_etherpad, :read_from_etherpad, :dump_to_etherpad, :search], Document
|
||||||
can :manage, Meeting
|
can :manage, Meeting
|
||||||
can :manage, Meetingtyp
|
can :manage, Meetingtyp
|
||||||
end
|
end
|
||||||
if user.has_role?("fetadmin")
|
if user.has_role?("fetadmin")
|
||||||
can :manage, Document
|
can :manage, Document
|
||||||
end
|
end
|
||||||
@@ -213,19 +216,19 @@ end
|
|||||||
end
|
end
|
||||||
if user.has_role?( "fetadmin")
|
if user.has_role?( "fetadmin")
|
||||||
can :manage, Meetingtyp
|
can :manage, Meetingtyp
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
# Rechteverwaltung Kalender
|
# Rechteverwaltung Kalender
|
||||||
can [:show, :index], Calendar, :public => true
|
can [:show, :index], Calendar, :public => true
|
||||||
can [:showics], Calendar
|
can [:showics], Calendar
|
||||||
# can [:show], Calentry
|
# can [:show], Calentry
|
||||||
if (!k.nil? && k.typ==1 && (k.user.has_role?("fetuser")||k.user.has_role?("fetadmin")))
|
if (!k.nil? && k.typ==1 && (k.user.has_role?("fetuser")||k.user.has_role?("fetadmin")))
|
||||||
if k.parent.nil?
|
if k.parent.nil?
|
||||||
can [:show,:index], Calendar
|
can [:show,:index], Calendar
|
||||||
else
|
else
|
||||||
can [:show], Calendar, id: k.parent_id
|
can [:show], Calendar, id: k.parent_id
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
if( user.has_role?("fetuser") || user.has_role?("fetadmin"))
|
if( user.has_role?("fetuser") || user.has_role?("fetadmin"))
|
||||||
@@ -242,6 +245,6 @@ end
|
|||||||
if user.has_role?("fetadmin")
|
if user.has_role?("fetadmin")
|
||||||
can :emails,User
|
can :emails,User
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ class Document < ActiveRecord::Base
|
|||||||
has_paper_trail
|
has_paper_trail
|
||||||
TYPS = { 1=>"fet_docs", 10=>"protocol", 11=> "agenda"}
|
TYPS = { 1=>"fet_docs", 10=>"protocol", 11=> "agenda"}
|
||||||
has_many :attachments, :as=>:parent
|
has_many :attachments, :as=>:parent
|
||||||
def long_name
|
def long_name
|
||||||
if self.parent.class=="Meeting"
|
if self.parent.class=="Meeting"
|
||||||
"<b>"+self.parent.text+ "</b>"+ self.name
|
"<b>"+self.parent.text+ "</b>"+ self.name
|
||||||
else
|
else
|
||||||
@@ -18,20 +18,20 @@ class Document < ActiveRecord::Base
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
def self.new_divid_for(parent)
|
def self.new_divid_for(parent)
|
||||||
"document_new_parent_" + parent.class.to_s + "_" + parent.id.to_s
|
"document_new_parent_" + parent.class.to_s + "_" + parent.id.to_s
|
||||||
end
|
end
|
||||||
def divid
|
def divid
|
||||||
"document_"+self.id.to_s
|
"document_"+self.id.to_s
|
||||||
end
|
end
|
||||||
def self.ether
|
def self.ether
|
||||||
EtherpadLite.connect('http://www.fet.at/etherpad', File.new('/srv/etherpad/etherpad-lite/APIKEY.txt'))
|
EtherpadLite.connect('https://www.fet.at/etherpad', File.new('config/etherpad/APIKEY.txt'))#https://www.etherpad.fet.at
|
||||||
end
|
end
|
||||||
def create_pdf
|
def create_pdf
|
||||||
require "open3"
|
require "open3"
|
||||||
|
|
||||||
#url=blank_document_url({id: self.id, host: host, port: port})
|
#url=blank_document_url({id: self.id, host: host, port: port})
|
||||||
# url=Rails.application.routes.url_helpers.blank_document_url({id: self.id, host: host, port: port})
|
# url=Rails.application.routes.url_helpers.blank_document_url({id: self.id, host: host, port: port})
|
||||||
|
|
||||||
file = Tempfile.new(['document', '.pdf'])
|
file = Tempfile.new(['document', '.pdf'])
|
||||||
bin=Rails.application.config.pdf_bin
|
bin=Rails.application.config.pdf_bin
|
||||||
sin,sout,serr=Open3.popen3("#{bin} --header-html \"file://#{Rails.root}/app/views/documents/header.html\" --footer-html \"file://#{Rails.root}/app/views/documents/footer.html\" --replace title1 \"#{self.name}\" - #{file.path}")
|
sin,sout,serr=Open3.popen3("#{bin} --header-html \"file://#{Rails.root}/app/views/documents/header.html\" --footer-html \"file://#{Rails.root}/app/views/documents/footer.html\" --replace title1 \"#{self.name}\" - #{file.path}")
|
||||||
@@ -70,20 +70,29 @@ class Document < ActiveRecord::Base
|
|||||||
end
|
end
|
||||||
def move_to_etherpad
|
def move_to_etherpad
|
||||||
unless self.is_etherpad? || self.id.nil?
|
unless self.is_etherpad? || self.id.nil?
|
||||||
self.etherpadkey="document_"+ self.id.to_s
|
self.etherpadkey="document_"+ self.id.to_s
|
||||||
self.ep_pad.html = '<div>'+self.text+'</div>'
|
|
||||||
end
|
if self.text.nil?
|
||||||
|
self.ep_pad.html = '<div>'+"text"+'</div>'
|
||||||
|
else
|
||||||
|
self.ep_pad.html = '<div>'+self.text+'</div>'
|
||||||
|
end
|
||||||
|
end
|
||||||
end
|
end
|
||||||
def dump_to_etherpad
|
def dump_to_etherpad
|
||||||
if self.is_etherpad?
|
if self.is_etherpad?
|
||||||
self.ep_pad.html = '<div>'+self.text+'</div>'
|
if self.text.nil?
|
||||||
|
self.ep_pad.html = '<div>'+"text"+'</div>'
|
||||||
|
else
|
||||||
|
self.ep_pad.html = '<div>'+self.text+'</div>'
|
||||||
|
end
|
||||||
else
|
else
|
||||||
self.move_to_etherpad
|
self.move_to_etherpad
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
def read_from_etherpad
|
def read_from_etherpad
|
||||||
self.text=ApplicationController.helpers.strip_control_chars( self.ep_pad.html)
|
self.text=ApplicationController.helpers.strip_control_chars( self.ep_pad.html)
|
||||||
|
|
||||||
end
|
end
|
||||||
def ep_pad
|
def ep_pad
|
||||||
self.ep_group.pad(self.etherpadkey)
|
self.ep_group.pad(self.etherpadkey)
|
||||||
@@ -93,16 +102,16 @@ class Document < ActiveRecord::Base
|
|||||||
Document.ether.group(Document::TYPS[t])
|
Document.ether.group(Document::TYPS[t])
|
||||||
end
|
end
|
||||||
def text_stripped
|
def text_stripped
|
||||||
ApplicationController.helpers.strip_control_chars(ApplicationController.helpers.strip_tags(text.to_s.gsub("<"," <").gsub(">","> ").to_s))
|
ApplicationController.helpers.strip_control_chars(ApplicationController.helpers.strip_tags(text.to_s.gsub("<"," <").gsub(">","> ").to_s))
|
||||||
|
|
||||||
end
|
end
|
||||||
searchable do
|
searchable do
|
||||||
text :text, stored: true do |d|
|
text :text, stored: true do |d|
|
||||||
d.text_stripped
|
d.text_stripped
|
||||||
end
|
end
|
||||||
text :name, :boost=>4.0, :stored=> true
|
text :name, :boost=>4.0, :stored=> true
|
||||||
text :meeting, stored: true do |d|
|
text :meeting, stored: true do |d|
|
||||||
(d.parent.is_a?(Meeting))? d.try(:parent).try(:text).to_s : ""
|
(d.parent.is_a?(Meeting))? d.try(:parent).try(:text).to_s : ""
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
def maketoc
|
def maketoc
|
||||||
@@ -116,20 +125,20 @@ class Document < ActiveRecord::Base
|
|||||||
l=2
|
l=2
|
||||||
f=true;
|
f=true;
|
||||||
s="<ul>"
|
s="<ul>"
|
||||||
c.each do |h|
|
c.each do |h|
|
||||||
s=s+ "</li></ul></li>"*(l-h["level"]) if (h["level"]<l) and !f
|
s=s+ "</li></ul></li>"*(l-h["level"]) if (h["level"]<l) and !f
|
||||||
s=s+" </li>" if (h["level"]==l) and !f
|
s=s+" </li>" if (h["level"]==l) and !f
|
||||||
if (h["level"]>l)
|
if (h["level"]>l)
|
||||||
s=s + "<ul><li>" * (h["level"]-l)
|
s=s + "<ul><li>" * (h["level"]-l)
|
||||||
else
|
else
|
||||||
s=s+"<li>"
|
s=s+"<li>"
|
||||||
end
|
end
|
||||||
s=s+h["text"]
|
s=s+h["text"]
|
||||||
|
|
||||||
l = h["level"]
|
l = h["level"]
|
||||||
f=false
|
f=false
|
||||||
end
|
end
|
||||||
s=s+"</ul>"*(l-2) if (l>2)
|
s=s+"</ul>"*(l-2) if (l>2)
|
||||||
s=s+"</ul>"
|
s=s+"</ul>"
|
||||||
self.toc=s
|
self.toc=s
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -26,7 +26,7 @@ class Gremium < ActiveRecord::Base
|
|||||||
# has_many :members, through: :memberships
|
# has_many :members, through: :memberships
|
||||||
searchable do
|
searchable do
|
||||||
text :desc
|
text :desc
|
||||||
text :name, :boost=>4.0
|
text :name
|
||||||
end
|
end
|
||||||
|
|
||||||
belongs_to :thema # Gehört zu einem Thema
|
belongs_to :thema # Gehört zu einem Thema
|
||||||
|
|||||||
@@ -16,9 +16,9 @@ class Neuigkeit < ActiveRecord::Base
|
|||||||
attr_accessible :datum, :text, :title, :rubrik_id, :author_id,:picture,:picture_cache, :calentries_attributes, :flag_important
|
attr_accessible :datum, :text, :title, :rubrik_id, :author_id,:picture,:picture_cache, :calentries_attributes, :flag_important
|
||||||
belongs_to :author, :class_name =>'User'
|
belongs_to :author, :class_name =>'User'
|
||||||
belongs_to :rubrik, :class_name =>'Rubrik', :foreign_key => "rubrik_id"
|
belongs_to :rubrik, :class_name =>'Rubrik', :foreign_key => "rubrik_id"
|
||||||
has_one :calendar, through: :rubrik
|
has_one :calendar, through: :rubrik
|
||||||
has_many :calentries, as: :object, :dependent=> :destroy
|
has_many :calentries, as: :object, :dependent=> :destroy
|
||||||
has_many :nlinks, :dependent=> :destroy
|
has_many :nlinks, :dependent=> :destroy
|
||||||
has_one :meeting
|
has_one :meeting
|
||||||
has_many :attachments, :as=>:parent
|
has_many :attachments, :as=>:parent
|
||||||
has_one :title_pic, :class_name=>"Attachment", :as=>:parent, :conditions=>["attachments.flag_titlepic =?", true]
|
has_one :title_pic, :class_name=>"Attachment", :as=>:parent, :conditions=>["attachments.flag_titlepic =?", true]
|
||||||
@@ -60,11 +60,11 @@ class Neuigkeit < ActiveRecord::Base
|
|||||||
end
|
end
|
||||||
def read_attribute(name,options={})
|
def read_attribute(name,options={})
|
||||||
if translated?(name)
|
if translated?(name)
|
||||||
a=super(name,options)
|
a=super(name,options)
|
||||||
a=self.translation_for(options[:locale] || I18n.locale).read_attribute(name) if self.no_fallbacks
|
a=self.translation_for(options[:locale] || I18n.locale).read_attribute(name) if self.no_fallbacks
|
||||||
|
|
||||||
a
|
a
|
||||||
else
|
else
|
||||||
super(name)
|
super(name)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@@ -91,7 +91,7 @@ class Neuigkeit < ActiveRecord::Base
|
|||||||
!self.meeting.nil?
|
!self.meeting.nil?
|
||||||
end
|
end
|
||||||
def self.published
|
def self.published
|
||||||
where("datum <= ? AND datum IS NOT NULL", Time.now.to_date)
|
where("datum <= ? AND datum IS NOT NULL", Time.now.to_date)
|
||||||
end
|
end
|
||||||
|
|
||||||
def datum_nilsave
|
def datum_nilsave
|
||||||
@@ -132,7 +132,17 @@ class Neuigkeit < ActiveRecord::Base
|
|||||||
"...."
|
"...."
|
||||||
else
|
else
|
||||||
words[0..100].join(" ")+ " ..." unless words.nil?
|
words[0..100].join(" ")+ " ..." unless words.nil?
|
||||||
|
|
||||||
|
end
|
||||||
|
end
|
||||||
|
def text_infoscreen_words
|
||||||
|
md = /<p>(?<text>[^\<\>]*)/.match Sanitize.clean(self.text,:elements=>['p'])
|
||||||
|
words=md[:text].split(" ") unless md.nil?
|
||||||
|
if words.nil? || words.empty?
|
||||||
|
"...."
|
||||||
|
else
|
||||||
|
words[0..1000].join(" ")+ " ..." unless words.nil?
|
||||||
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
def has_calentries?
|
def has_calentries?
|
||||||
@@ -143,7 +153,7 @@ class Neuigkeit < ActiveRecord::Base
|
|||||||
end
|
end
|
||||||
def relevant_calentry
|
def relevant_calentry
|
||||||
ce = self.calentries.min_by{|c| c.days_to_today * 1.3 * ((c.is_past?)? 2:1)} if self.is_event?
|
ce = self.calentries.min_by{|c| c.days_to_today * 1.3 * ((c.is_past?)? 2:1)} if self.is_event?
|
||||||
ce= self.meeting.calentry if self.has_meeting?
|
ce= self.meeting.calentry if self.has_meeting?
|
||||||
ce
|
ce
|
||||||
end
|
end
|
||||||
def update_cache
|
def update_cache
|
||||||
@@ -151,8 +161,8 @@ class Neuigkeit < ActiveRecord::Base
|
|||||||
self.update_column(:cache_order, (self.meeting.calentry.start.to_date - Date.today).to_i.abs * 1.3)
|
self.update_column(:cache_order, (self.meeting.calentry.start.to_date - Date.today).to_i.abs * 1.3)
|
||||||
self.update_column(:cache_relevant_date, self.meeting.calentry.start.to_date)
|
self.update_column(:cache_relevant_date, self.meeting.calentry.start.to_date)
|
||||||
self.touch
|
self.touch
|
||||||
else
|
else
|
||||||
if self.is_event?
|
if self.is_event?
|
||||||
c = self.calentries.min_by{|c| c.days_to_today * 1.3 * ((c.is_past?)? 2:1)}
|
c = self.calentries.min_by{|c| c.days_to_today * 1.3 * ((c.is_past?)? 2:1)}
|
||||||
self.update_column(:cache_order, c.days_to_today * 1.3 * ((c.is_past?)? 2:1))
|
self.update_column(:cache_order, c.days_to_today * 1.3 * ((c.is_past?)? 2:1))
|
||||||
self.update_column(:cache_relevant_date, (c.is_past?) ? c.ende.to_date : c.start.to_date)
|
self.update_column(:cache_relevant_date, (c.is_past?) ? c.ende.to_date : c.start.to_date)
|
||||||
@@ -184,8 +194,8 @@ class Neuigkeit < ActiveRecord::Base
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
searchable do
|
searchable do
|
||||||
text :text
|
text :text
|
||||||
text :datum
|
text :datum
|
||||||
text :title, :boost=>3.0
|
text :title
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -42,7 +42,7 @@ end
|
|||||||
|
|
||||||
searchable do
|
searchable do
|
||||||
text :desc
|
text :desc
|
||||||
text :name, :boost=>4.0
|
text :name
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -89,7 +89,7 @@ class Studium < ActiveRecord::Base
|
|||||||
text :zahl
|
text :zahl
|
||||||
text :typ
|
text :typ
|
||||||
text :abkuerzung
|
text :abkuerzung
|
||||||
text :name, :boost=>3.0
|
text :name
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -47,7 +47,7 @@ class Thema < ActiveRecord::Base
|
|||||||
# make topic searchable
|
# make topic searchable
|
||||||
searchable do
|
searchable do
|
||||||
text :text
|
text :text
|
||||||
text :title, :boost=>4.0
|
text :title
|
||||||
end
|
end
|
||||||
|
|
||||||
resourcify
|
resourcify
|
||||||
|
|||||||
@@ -40,7 +40,7 @@ end
|
|||||||
|
|
||||||
searchable do
|
searchable do
|
||||||
text :text
|
text :text
|
||||||
text :title, :boost=>4.0
|
text :title
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -9,7 +9,7 @@
|
|||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</p>
|
</p>
|
||||||
<%= form_for(resource, :as => resource_name, :url => session_path(resource_name)) do |f| %>
|
<!--<%= form_for(resource, :as => resource_name, :url => session_path(resource_name)) do |f| %>
|
||||||
<div><%= f.label :email %><br />
|
<div><%= f.label :email %><br />
|
||||||
<%= f.email_field :email, :autofocus => true %></div>
|
<%= f.email_field :email, :autofocus => true %></div>
|
||||||
|
|
||||||
@@ -23,4 +23,6 @@
|
|||||||
<div><%= f.submit "Sign in" %></div>
|
<div><%= f.submit "Sign in" %></div>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
|
-->
|
||||||
|
|
||||||
<%= render "devise/shared/links" %>
|
<%= render "devise/shared/links" %>
|
||||||
|
|||||||
@@ -22,7 +22,9 @@
|
|||||||
<ul class='breadcrumb hidden-print'>
|
<ul class='breadcrumb hidden-print'>
|
||||||
<% @document.versions.each do |v| %>
|
<% @document.versions.each do |v| %>
|
||||||
<li>
|
<li>
|
||||||
<%= link_to User.find(v.whodunnit).name+": "+ v.event + " (" + I18n.l(v.created_at)+ ") ", write_document_path(@document,:versionid=>v.id) unless v.whodunnit.nil? %>
|
|
||||||
|
<%= link_to User.find(v.whodunnit).try(:name)+": "+ v.event + " (" + I18n.l(v.created_at)+ ") ", write_document_path(@document,:versionid=>v.id) if User.exists?(v.whodunnit) unless v.whodunnit.nil? %>
|
||||||
|
|
||||||
<% end %> <span class="divider">/</span></li>
|
<% end %> <span class="divider">/</span></li>
|
||||||
</ul>
|
</ul>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|||||||
@@ -1 +1 @@
|
|||||||
<%= link_to "weiter" , "http://www.fet.at/etherpad/p/"+@document.ep_pad.id , target: :blank %>
|
<%= link_to "weiter" , "https://www.fet.at/etherpad/p/"+@document.ep_pad.id , target: :blank %>
|
||||||
|
|||||||
@@ -8,10 +8,9 @@ top: 0" %>
|
|||||||
<% #, gallery_foto_path(@foto.gallery, ((@foto.gallery.fotos[@foto.gallery.fotos.index(@foto)+1].nil?) ? (@foto.gallery.fotos[0].try(:id).to_i) : @foto.gallery.fotos[@foto.gallery.fotos.index(@foto)+1].try(:id).to_i) ) %>
|
<% #, gallery_foto_path(@foto.gallery, ((@foto.gallery.fotos[@foto.gallery.fotos.index(@foto)+1].nil?) ? (@foto.gallery.fotos[0].try(:id).to_i) : @foto.gallery.fotos[@foto.gallery.fotos.index(@foto)+1].try(:id).to_i) ) %>
|
||||||
<div style="position:absolute; bottom:0; ">
|
<div style="position:absolute; bottom:0; ">
|
||||||
<%= link_to ff_icon('icon-circle-arrow-down').html_safe, @foto.datei.url,
|
<%= link_to ff_icon('icon-circle-arrow-down').html_safe, @foto.datei.url,
|
||||||
:class=>"btn",title: I18n.t('fotos.download')+': '+@foto.title,:target=>:blank, :style=>"" %>
|
:class=>"btn",title: I18n.t('fotos.download')+': '+@foto.title.to_s,:target=>:blank, :style=>"" %>
|
||||||
<!-- <div class="fb-like" data-href"<%= gallery_foto_path(@foto.gallery,@foto, {fotoid:@foto.id,theme: nil, locale: nil})%>" data-layout="standard" data-action="like" data-show-faces="true" data-share="true"></div>-->
|
<!-- <div class="fb-like" data-href"<%= gallery_foto_path(@foto.gallery,@foto, {fotoid:@foto.id,theme: nil, locale: nil})%>" data-layout="standard" data-action="like" data-show-faces="true" data-share="true"></div>-->
|
||||||
<%= render_shareable :url=>gallery_foto_url(@foto.gallery,@foto, {theme: nil, locale: nil}),:static_link=>true, :buttons=>[:facebook, :twitter, :google_plus] %>
|
<%= render_shareable :url=>gallery_foto_url(@foto.gallery,@foto, {theme: nil, locale: nil}),:static_link=>true, :buttons=>[:facebook, :twitter, :google_plus] %>
|
||||||
<p id="notice"><%= notice %></p>
|
<p id="notice"><%= notice %></p>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
<%= content_for :header do %>
|
<%= content_for :header do %>
|
||||||
<title>Fet - Fotos: <%= @gallery.name %></title>
|
<title>Fet - Fotos: <%= @gallery.name %></title>
|
||||||
|
|
||||||
<%
|
<%
|
||||||
if @openfotoid.nil? || @openfotoid==0
|
if @openfotoid.nil? || @openfotoid==0
|
||||||
@firstfoto= @fotos_p.first
|
@firstfoto= @fotos_p.first
|
||||||
unless @firstfoto.nil?
|
unless @firstfoto.nil?
|
||||||
@@ -70,7 +70,7 @@ end
|
|||||||
<!-- <div class="pagination pull_left" style="margin:0px 0px 0px 0px">
|
<!-- <div class="pagination pull_left" style="margin:0px 0px 0px 0px">
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="<%= gallery_path @gallery, {:pppage => @pppage, :page => (@page==1 ? @page : @page-1)} %>"><%=I18n.t('fotos.prev')%></a></li>
|
<li><a href="<%= gallery_path @gallery, {:pppage => @pppage, :page => (@page==1 ? @page : @page-1)} %>"><%=I18n.t('fotos.prev')%></a></li>
|
||||||
<% # for i in 1..@pages do
|
<% # for i in 1..@pages do
|
||||||
i=1 %>
|
i=1 %>
|
||||||
<li><a href="<%= gallery_path @gallery, {:pppage => @pppage, :page => i} %>"><%=i%></a></li>
|
<li><a href="<%= gallery_path @gallery, {:pppage => @pppage, :page => i} %>"><%=i%></a></li>
|
||||||
<% # end %>
|
<% # end %>
|
||||||
@@ -131,7 +131,7 @@ end
|
|||||||
<% @fotos_p.each do |f| %>
|
<% @fotos_p.each do |f| %>
|
||||||
<div class="left">
|
<div class="left">
|
||||||
<div id="links">
|
<div id="links">
|
||||||
<% if (@openfotoid.to_i==f.id) %>
|
<% if (@openfotoid.to_i==f.id) %>
|
||||||
<meta itemprop="image" content="<%= f.datei.resized.url %>"/>
|
<meta itemprop="image" content="<%= f.datei.resized.url %>"/>
|
||||||
<% end %>
|
<% end %>
|
||||||
<div <% if (@openfotoid.to_i==f.id) %> itemprop="primaryImageOfPage"<% else %> itemprop="hasPart" <% end %> itemscope itemtype="http://schema.org/ImageObject">
|
<div <% if (@openfotoid.to_i==f.id) %> itemprop="primaryImageOfPage"<% else %> itemprop="hasPart" <% end %> itemscope itemtype="http://schema.org/ImageObject">
|
||||||
@@ -145,9 +145,12 @@ end
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<%= link_to ff_icon('icon-circle-arrow-down').html_safe, f.datei.url,
|
<%= link_to ff_icon('icon-circle-arrow-down').html_safe, f.datei.url,
|
||||||
:class=>"btn-small",title: I18n.t('fotos.download')+': '+f.title, rel: 'tooltip' %>
|
:class=>"btn-small",title: I18n.t('fotos.download').to_s+': '+f.title.to_s, rel: 'tooltip' %>
|
||||||
<%= link_to ff_icon('icon-remove-circle').html_safe, gallery_foto_path(@gallery, f),
|
<%= link_to ff_icon('icon-remove-circle').html_safe, gallery_foto_path(@gallery, f),
|
||||||
:method => :delete, :class=>"btn-small btn-danger",title: I18n.t('fotos.delete')+': '+f.title, rel: 'tooltip', confirm: I18n.t('fotos.delete')+': '+f.title+', Sicher?' if can?(:delete,f) %>
|
:method => :delete, :class=>"btn-small btn-danger",
|
||||||
|
title: I18n.t('fotos.delete').to_s+': '+f.title.to_s, rel: 'tooltip',
|
||||||
|
confirm: I18n.t('fotos.delete').to_s+': '+f.title.to_s+',
|
||||||
|
Sicher?' if can?(:delete,f) %>
|
||||||
<p></p>
|
<p></p>
|
||||||
</div>
|
</div>
|
||||||
<% end %>
|
<% end %>
|
||||||
@@ -169,21 +172,21 @@ end
|
|||||||
<%= link_to ff_icon('icon-remove-circle').html_safe, '',
|
<%= link_to ff_icon('icon-remove-circle').html_safe, '',
|
||||||
:class=>"btn-small btn-danger"%>: <%= I18n.t('fotos.delete')%>
|
:class=>"btn-small btn-danger"%>: <%= I18n.t('fotos.delete')%>
|
||||||
<p></p>
|
<p></p>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<% end %>
|
<% end %>
|
||||||
<%= render 'layouts/pretty_toolbar' %>
|
<%= render 'layouts/pretty_toolbar' %>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<%= javascript_include_tag "blueimp-gallery-all" %>
|
<%= javascript_include_tag "blueimp-gallery-all" %>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
blueimp.Gallery.prototype.textFactory = function (obj, callback) {
|
blueimp.Gallery.prototype.textFactory = function (obj, callback) {
|
||||||
var $element = $('<div>')
|
var $element = $('<div>')
|
||||||
.addClass('slide-content')
|
.addClass('slide-content')
|
||||||
.attr('title', obj.title)
|
.attr('title', obj.title)
|
||||||
.attr('histItem',obj.getAttribute('histitem'));
|
.attr('histItem',obj.getAttribute('histitem'));
|
||||||
|
|
||||||
$.get(obj.href)
|
$.get(obj.href)
|
||||||
.done(function (result) {
|
.done(function (result) {
|
||||||
$element.html(result);
|
$element.html(result);
|
||||||
@@ -201,13 +204,13 @@ end
|
|||||||
return $element[0];
|
return $element[0];
|
||||||
};
|
};
|
||||||
$('#openpic').click()
|
$('#openpic').click()
|
||||||
|
|
||||||
|
|
||||||
blueimp.Gallery.prototype.onslide = (function(_super) {
|
blueimp.Gallery.prototype.onslide = (function(_super) {
|
||||||
return function(index) {
|
return function(index) {
|
||||||
history.pushState({},"Foto",String(this.list[index].getAttribute('histitem')));
|
history.pushState({},"Foto",String(this.list[index].getAttribute('histitem')));
|
||||||
return _super.apply(this, arguments);
|
return _super.apply(this, arguments);
|
||||||
};
|
};
|
||||||
})(blueimp.Gallery.prototype.onslide);
|
})(blueimp.Gallery.prototype.onslide);
|
||||||
</script>
|
</script>
|
||||||
<style>
|
<style>
|
||||||
@@ -221,5 +224,3 @@ end
|
|||||||
* html .fb-like{display:inline}/* ie6 inline block fix*/
|
* html .fb-like{display:inline}/* ie6 inline block fix*/
|
||||||
*+html .fb-like{display:inline}/* ie7 inline block fix*/
|
*+html .fb-like{display:inline}/* ie7 inline block fix*/
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -13,19 +13,16 @@
|
|||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<div class="row-fluid">
|
<div class="row-fluid">
|
||||||
<div class="span5">
|
<div class="span5">
|
||||||
|
|
||||||
<ul class="linklist">
|
<ul class="linklist">
|
||||||
<li>
|
|
||||||
<%= link_to ffi1_icon("facebook1") + I18n.t('home.fblogin'), user_omniauth_authorize_path(:facebook) ,class: :linkbox %>
|
|
||||||
</li>
|
|
||||||
<li>
|
<li>
|
||||||
<%= link_to ffi1_icon("academic") + I18n.t('home.login'), user_omniauth_authorize_path(:ldap) ,class: :linkbox %>
|
<%= link_to ffi1_icon("academic") + I18n.t('home.login'), user_omniauth_authorize_path(:ldap) ,class: :linkbox %>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
<li>
|
<li>
|
||||||
<%= link_to ffi1_icon("quiz")+ I18n.t("themengruppe.faqs"), faqs_themengruppen_path,class: :linkbox %>
|
<%= link_to ffi1_icon("quiz")+ I18n.t("themengruppe.faqs"), faqs_themengruppen_path,class: :linkbox %>
|
||||||
</li>
|
</li>
|
||||||
<li><%= link_to ffi1_icon("books19")+"Beispielsammlung", studium_path(Studium.first, {:ansicht=>'semesteransicht'}) ,class: :btn ,class: :linkbox %></li>
|
<li><%= link_to ffi1_icon("books19")+"Beispielsammlung", studium_path(Studium.first, {:ansicht=>'semesteransicht'}) ,class: :btn ,class: :linkbox unless Studium.first.nil? %></li>
|
||||||
<li><%= link_to "Alte Beispielsammlung", "http://www.fet.at/alt/bin/view/Beispielsammlung/WebHome" ,class: :btn ,class: :linkbox %></li>
|
<li><%= link_to "Alte Beispielsammlung", "http://www.fet.at/alt/bin/view/Beispielsammlung/WebHome" ,class: :btn ,class: :linkbox %></li>
|
||||||
</ul>
|
</ul>
|
||||||
<ul>
|
<ul>
|
||||||
@@ -33,7 +30,7 @@
|
|||||||
<li>
|
<li>
|
||||||
<%= link_to t1 do %>
|
<%= link_to t1 do %>
|
||||||
<%= render partial: "themen/nlink", object: t %>
|
<%= render partial: "themen/nlink", object: t %>
|
||||||
<%= end %>
|
<%= end %>
|
||||||
</li>
|
</li>
|
||||||
<% end %>
|
<% end %>
|
||||||
</ul>
|
</ul>
|
||||||
@@ -60,4 +57,3 @@ Verschiedene Styles
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|||||||
@@ -3,84 +3,101 @@
|
|||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<%= stylesheet_link_tag "themes/"+theme_name+"/application", :media => "all" unless theme_name.empty? %>
|
<%= stylesheet_link_tag "themes/"+theme_name+"/application", :media => "all" unless theme_name.empty? %>
|
||||||
<%= stylesheet_link_tag "application", :media=>"all" if theme_name.empty? %>
|
<%= stylesheet_link_tag "application", :media=>"all" if theme_name.empty? %>
|
||||||
|
<%= stylesheet_link_tag "/iframe/infoscreenframe.css" %>
|
||||||
|
|
||||||
<%= javascript_include_tag "application" %>
|
<%= javascript_include_tag "application" %>
|
||||||
<%= javascript_include_tag "jmpress" %>
|
<%= javascript_include_tag "jmpress" %>
|
||||||
|
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<div id ="jmpress">
|
|
||||||
<% i=1 %>
|
|
||||||
<% @neuigkeiten.each do |n| %>
|
|
||||||
|
|
||||||
<div class="step contentbox" id="step-<%=i%>" data-x="<%= i *2000 %>" data-y="<%= Random.rand(0..5)*200 %>" data-rotate="<%= Random.rand(0..18)*10 %>" style="width:1000px; height:500px; padding: 50px; display:block" data-duration="10000"><% @toolbar_elements=[];@questions=[] %>
|
<%= content_tag(:iframe,'', width: "100%", height: "100%", name: "targetframe", allowTransparency:"true", scrolling:"no", frameborder:"0", src: "/iframe/infoscreenframe.html") %> <%#header picture/animation %>
|
||||||
<div class="media" style="width: 660px; height:340px; transform: scale(1.5) translate(120px,50px)" >
|
<div id ="jmpress">
|
||||||
|
<% i=1 %>
|
||||||
<div class="pull-left" href="#" style="max-width:200px;">
|
<% @neuigkeiten.each do |n| %>
|
||||||
<% unless n.picture_robust.big_thumb.to_s.empty? %>
|
|
||||||
<p>
|
|
||||||
<br><%= link_to image_tag(n.picture_robust.big_thumb),n.picture_robust.try(:url) %>
|
|
||||||
</p>
|
|
||||||
<% end %>
|
|
||||||
<h3>
|
|
||||||
<% if n.has_calentries? %>
|
|
||||||
<div href="#">
|
|
||||||
<%= fa_icon("calendar 2x") %>
|
|
||||||
<%= n.relevant_calentry.text %>
|
|
||||||
</div>
|
|
||||||
<% elsif n.has_meeting? %>
|
|
||||||
<div href="#">
|
|
||||||
<%= fa_icon("calendar 2x") %>
|
|
||||||
<%= n.meeting.calentry.text unless n.meeting.calentry.nil? %>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<% end %>
|
|
||||||
</h3>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="media-body">
|
|
||||||
<h1 itemprop="name">
|
|
||||||
<%= raw(n.title) %> <%#= link_to fa_icon("edit"), edit_rubrik_neuigkeit_path(n.rubrik, n), remote: true if can? :edit, n %>
|
|
||||||
</h1>
|
|
||||||
<div itemprop="articleBody" style="font-size:large">
|
|
||||||
<%= raw(n.text_first_words) %>
|
|
||||||
|
|
||||||
|
<div class="step" id="step-<%=i%>" data-x="<%= i *2000 %>" data-y="<%= Random.rand(0..5)*200 %>" style="position:absolute; height:540px; width:1230px; display: block;" data-duration="10000">
|
||||||
|
<div class="media" style="width:'95%'; height:480px;" >
|
||||||
|
<div class="pull-left" href="#" style="max-width:250px;">
|
||||||
|
<% unless n.picture_robust.big_thumb.to_s.empty? %>
|
||||||
|
<p>
|
||||||
|
<br><%= link_to image_tag(n.picture_robust.big_thumb),n.picture_robust.try(:url) %></p>
|
||||||
|
<% end %>
|
||||||
|
<h3>
|
||||||
|
<% if n.has_calentries? %>
|
||||||
|
<div href="#">
|
||||||
|
<%= fa_icon("calendar 2x") %>
|
||||||
|
<%= n.relevant_calentry.text %>
|
||||||
|
</div>
|
||||||
|
<% elsif n.has_meeting? %>
|
||||||
|
<div href="#">
|
||||||
|
<%= fa_icon("calendar 2x") %>
|
||||||
|
<%= n.meeting.calentry.text unless n.meeting.calentry.nil? %>
|
||||||
|
</div>
|
||||||
|
|
||||||
</div>
|
<% end %>
|
||||||
|
</h3>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="media-body">
|
||||||
|
<h1 itemprop="name">
|
||||||
|
<%= raw(n.title) %> <%#= link_to fa_icon("edit"), edit_rubrik_neuigkeit_path(n.rubrik, n), remote: true if can? :edit, n %>
|
||||||
|
</h1>
|
||||||
|
<div itemprop="articleBody" style="font-size:large">
|
||||||
|
<%= raw(n.text_infoscreen_words) %>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<% i = i+1 %>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<script>
|
||||||
</div>
|
var d = new Date();
|
||||||
<% i = i+1 %>
|
var n = d.getDay();
|
||||||
<% end %>
|
var now = d.getHours() + "." + d.getMinutes();
|
||||||
|
var weekdays = [
|
||||||
|
["Sunday"],
|
||||||
|
["Monday", 9.00, 14.00],
|
||||||
|
["Tuesday", 9.00, 14.00],
|
||||||
|
["Wednesday", 9.00, 14.00],
|
||||||
|
["Thursday", 9.00, 14.00],
|
||||||
|
["Friday", 9.00, 12.00],
|
||||||
|
["Saturday"] // we are closed, sorry!
|
||||||
|
];
|
||||||
|
var day = weekdays[n];
|
||||||
|
if (now > day[1] && now < day[2]) {
|
||||||
|
document.write("<div id='footer' style='background: green; height:25px; width:50px; margin:10px; position:absolute'>");
|
||||||
|
document.write("OPEN");
|
||||||
|
document.write("</div>");
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
document.write("<div id='footer' style='background: red; height:25px; width:60px; margin:10px; position:absolute'>");
|
||||||
|
document.write("CLOSED");
|
||||||
|
document.write("</div>");
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="ui-progressbar ui-widget ui-widget-content ui-corner-all" style="height:10px; z-index: 2000; left: 5px; right: 5px; bottom: 5px; height: 10px; position:absolute">
|
|
||||||
<div id="" class="ui-progressbar-value ui-widget-header ui-corner-left" style=""></div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
$(function () {
|
<script>
|
||||||
$('#jmpress').jmpress({
|
$(function () {
|
||||||
duration: {
|
$('#jmpress').jmpress({
|
||||||
barPropertyStart: '0',
|
initStep: function(element, eventData) {
|
||||||
barSelector: '.ui-progressbar-value'
|
console.log('We\'re changing to step: #' + $(element).attr('id') + '!');
|
||||||
},
|
}
|
||||||
initStep: function(element, eventData) {
|
|
||||||
console.log('We\'re changing to step: #' + $(element).attr('id') + '!');
|
});
|
||||||
}
|
setTimeout(function(){
|
||||||
|
|
||||||
|
window.location.reload();
|
||||||
|
/* or window.location = window.location.href; */
|
||||||
|
|
||||||
|
}, 100000);
|
||||||
|
|
||||||
});
|
});
|
||||||
setTimeout(function(){
|
</script>
|
||||||
|
|
||||||
window.location.reload();
|
|
||||||
/* or window.location = window.location.href; */
|
|
||||||
|
|
||||||
}, 100000);
|
|
||||||
|
|
||||||
});
|
|
||||||
</script>
|
|
||||||
</body>
|
</body>
|
||||||
|
|||||||
18
app/views/home/verleihkalender.html.erb
Normal file
18
app/views/home/verleihkalender.html.erb
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
|
||||||
|
<head>
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<%= stylesheet_link_tag "themes/"+theme_name+"/application", :media => "all" unless theme_name.empty? %>
|
||||||
|
<%= stylesheet_link_tag "application", :media=>"all" if theme_name.empty? %>
|
||||||
|
<%= stylesheet_link_tag "infoscreenframe.css" %>
|
||||||
|
|
||||||
|
<%= javascript_include_tag "application" %>
|
||||||
|
<%= javascript_include_tag "jmpress" %>
|
||||||
|
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<iframe style="border-width: 0;"
|
||||||
|
src="https://calendar.google.com/calendar/embed?src=f7i0qj89nelp59lq8panbqr2ek%40group.calendar.google.com&src=8gec92r2kpn59jqm4gclg06nrg%40group.calendar.google.com&color=%23853104" width="100%" height="100%" frameborder="0" scrolling="no">
|
||||||
|
</iframe>
|
||||||
|
<script language="javascript" type="text/javascript">setTimeout("location.reload();",60000);</script>
|
||||||
|
<!-- reloads automatically once every 60sec = 1min -->
|
||||||
|
</body>
|
||||||
@@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
<head>
|
<head>
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<link rel="shortcut icon" href="<%= absurl("/logo2014_64.png")%>">
|
<link rel="shortcut icon" href="https://www.fet.at/logo2014_64.png">
|
||||||
|
|
||||||
<link rel="alternate" hreflang="de" href="<%= url_for(params.merge(:locale=>:de))%>" />
|
<link rel="alternate" hreflang="de" href="<%= url_for(params.merge(:locale=>:de))%>" />
|
||||||
|
|
||||||
|
|||||||
@@ -33,16 +33,17 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
<% unless @calentries.nil? or @calentries.empty? or True%>
|
||||||
<div class="span3">
|
<div class="span3">
|
||||||
|
<% unless @calentries.nil? or @calentries.empty? %>
|
||||||
<% cache("calendar_" + @calentries.map{|c| c.id}.join('') + @calentries.max{|c|c.updated_at.to_i}.updated_at.to_i.to_s+"_"+I18n.locale.to_s+params[:month].to_s+params[:year].to_s) do %>
|
<% cache("calendar_" + @calentries.map{|c| c.id}.join('') + @calentries.max{|c|c.updated_at.to_i}.updated_at.to_i.to_s+"_"+I18n.locale.to_s+params[:month].to_s+params[:year].to_s) do %>
|
||||||
<%= render 'calendars/calentries', :object=>@calentries %>
|
<%= render 'calendars/calentries', :object=>@calentries %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
<% end %>
|
||||||
<% if !current_user.nil? and current_user.has_role?(:fetuser) %>
|
<% if !current_user.nil? and current_user.has_role?(:fetuser) %>
|
||||||
<%= link_to calendars_url(:format=>:ics, :key=>Key.find_or_create(current_user,1).uuid) , calendars_path(:format=>:ics, :key=>Key.find_or_create(current_user,1).uuid)%>
|
<%= link_to calendars_url(:format=>:ics, :key=>Key.find_or_create(current_user,1).uuid) , calendars_path(:format=>:ics, :key=>Key.find_or_create(current_user,1).uuid)%>
|
||||||
<% end %>
|
<% end %>
|
||||||
</div>
|
</div><% end %>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -9,7 +9,7 @@
|
|||||||
|
|
||||||
<div class="content-wrap content-column" style="max-width:90em;">
|
<div class="content-wrap content-column" style="max-width:90em;">
|
||||||
<h1><%= I18n.t('home.willkommen') %></h1>
|
<h1><%= I18n.t('home.willkommen') %></h1>
|
||||||
<%= raw(@starttopic.text) %>
|
<%= raw(@starttopic.text) unless @starttopic.nil? %>
|
||||||
|
|
||||||
|
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
@@ -26,7 +26,7 @@
|
|||||||
<li>
|
<li>
|
||||||
<%= link_to ffi1_icon("quiz")+ I18n.t("themengruppe.faqs"), faqs_themengruppen_path,class: :linkbox %>
|
<%= link_to ffi1_icon("quiz")+ I18n.t("themengruppe.faqs"), faqs_themengruppen_path,class: :linkbox %>
|
||||||
</li>
|
</li>
|
||||||
<li><%= link_to ffi1_icon("books19")+"Beispielsammlung", studium_path(Studium.first, {:ansicht=>'semesteransicht'}) ,class: :btn ,class: :linkbox %></li>
|
<li><%= link_to ffi1_icon("books19")+"Beispielsammlung", studium_path(Studium.first, {:ansicht=>'semesteransicht'}) ,class: :btn ,class: :linkbox if Studium.count >0 %></li>
|
||||||
<li><%= link_to "Alte Beispielsammlung", "http://www.fet.at/alt/bin/view/Beispielsammlung/WebHome" ,class: :btn ,class: :linkbox %></li>
|
<li><%= link_to "Alte Beispielsammlung", "http://www.fet.at/alt/bin/view/Beispielsammlung/WebHome" ,class: :btn ,class: :linkbox %></li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
|
|||||||
@@ -9,7 +9,7 @@
|
|||||||
|
|
||||||
<div class="content-wrap content-column" style="max-width:90em;">
|
<div class="content-wrap content-column" style="max-width:90em;">
|
||||||
<h1><%= I18n.t('home.willkommen') %></h1>
|
<h1><%= I18n.t('home.willkommen') %></h1>
|
||||||
<%= raw(@starttopic.text) %>
|
<%= raw(@starttopic.text) unless @starttopic.nil? %>
|
||||||
|
|
||||||
|
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
@@ -26,7 +26,7 @@
|
|||||||
<li>
|
<li>
|
||||||
<%= link_to ffi1_icon("quiz")+ I18n.t("themengruppe.faqs"), faqs_themengruppen_path,class: :linkbox %>
|
<%= link_to ffi1_icon("quiz")+ I18n.t("themengruppe.faqs"), faqs_themengruppen_path,class: :linkbox %>
|
||||||
</li>
|
</li>
|
||||||
<li><%= link_to ffi1_icon("books19")+"Beispielsammlung", studium_path(Studium.first, {:ansicht=>'semesteransicht'}) ,class: :btn ,class: :linkbox %></li>
|
<li><%= link_to ffi1_icon("books19")+"Beispielsammlung", studium_path(Studium.first, {:ansicht=>'semesteransicht'}) ,class: :btn ,class: :linkbox if Studium.count > 0 %></li>
|
||||||
<li><%= link_to "Alte Beispielsammlung", "http://www.fet.at/alt/bin/view/Beispielsammlung/WebHome" ,class: :btn ,class: :linkbox %></li>
|
<li><%= link_to "Alte Beispielsammlung", "http://www.fet.at/alt/bin/view/Beispielsammlung/WebHome" ,class: :btn ,class: :linkbox %></li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
|
|||||||
@@ -1,65 +1,66 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html>
|
<html>
|
||||||
<head>
|
<head>
|
||||||
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<link rel="shortcut icon" href="<%= absurl("/logo2014_64.png")%>">
|
<link rel="shortcut icon" href="https://www.fet.at/logo2014_64.png">
|
||||||
|
|
||||||
<link rel="alternate" hreflang="de" href="<%= url_for(params.merge(:locale=>:de))%>" />
|
<link rel="alternate" hreflang="de" href="<%= url_for(params.merge(:locale=>:de))%>" />
|
||||||
<link rel="alternate" hreflang="en" href="<%= url_for(params.merge(:locale=>:en))%>" />
|
<link rel="alternate" hreflang="en" href="<%= url_for(params.merge(:locale=>:en))%>" />
|
||||||
|
|
||||||
<%= stylesheet_link_tag "themes/"+theme_name+"/application", :media => "all" unless theme_name.empty? %>
|
<%= stylesheet_link_tag "themes/"+theme_name+"/application", :media => "all" unless theme_name.empty? %>
|
||||||
<%= stylesheet_link_tag "application", :media=>"all" if theme_name.empty? %>
|
<%= stylesheet_link_tag "application", :media=>"all" if theme_name.empty? %>
|
||||||
<%= javascript_include_tag "application" %>
|
<%= javascript_include_tag "application" %>
|
||||||
<%= csrf_meta_tags %>
|
<%= csrf_meta_tags %>
|
||||||
<% if content_for?(:header) %>
|
<% if content_for?(:header) %>
|
||||||
<%= yield :header %>
|
<%= yield :header %>
|
||||||
<% else %>
|
<% else %>
|
||||||
<title>Fetsite</title>
|
<title>Fetsite</title>
|
||||||
<% end %>
|
<% end %>
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
<div id="maincontainer" class="container-fluid">
|
<div id="maincontainer" class="container-fluid">
|
||||||
<div class="row-fluid">
|
<div class="row-fluid">
|
||||||
<div class="span10 offset1 header_span">
|
<div class="span10 offset1 header_span">
|
||||||
<% cache("menu_u"+user_signed_in?.to_s+current_user.try(:id).to_s+"l"+I18n.locale.to_s+ can?(:seeintern, User).to_s+ can?(:index,Gallery).to_s+params[:theme].to_s, expires_in: 24.hours) do %>
|
<% cache("menu_u"+user_signed_in?.to_s+current_user.try(:id).to_s+"l"+I18n.locale.to_s+ can?(:seeintern, User).to_s+ can?(:index,Gallery).to_s+params[:theme].to_s, expires_in: 24.hours) do %>
|
||||||
<div class="header_wrap">
|
<div class="header_wrap">
|
||||||
<div class="header hidden-print">
|
<div class="header hidden-print">
|
||||||
<%= link_to home_index_path do %>
|
<%= link_to home_index_path do %>
|
||||||
<!-- <span class="feticon-fet_logo fa-4x color-1"> </span>-->
|
<!-- <span class="feticon-fet_logo fa-4x color-1"> </span>-->
|
||||||
<%= image_tag('/logo2014_64.png',{:style=>"float:left;height:50px",:height=>"50"}) %>
|
<%= image_tag('/logo2014_64.png',{:style=>"float:left;height:50px",:height=>"50"}) %>
|
||||||
<% end %>
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
<div class="header visible-print">
|
<div class="header visible-print">
|
||||||
<%= image_tag('/logo2014_64.png',{:style=>"float:left;height:50px",:height=>"50"}) %>
|
<%= image_tag('/logo2014_64.png',{:style=>"float:left;height:50px",:height=>"50"}) %>
|
||||||
</div>
|
</div>
|
||||||
<div class="visible-print">
|
<div class="visible-print">
|
||||||
Fachschaft Elektrotechnik
|
Fachschaft Elektrotechnik
|
||||||
<hr/>
|
<hr/>
|
||||||
</div>
|
</div>
|
||||||
<div id="menudiv" style="margin-top:12px" class="hidden-print">
|
<div id="menudiv" style="margin-top:12px" class="hidden-print">
|
||||||
<%= render :template => 'layouts/menu' %>
|
<%= render :template => 'layouts/menu' %>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<% end %>
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="row-fluid">
|
||||||
|
<div class="span10 offset1" id="contentdiv">
|
||||||
|
<%= yield %>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="row-fluid">
|
<script>
|
||||||
<div class="span10 offset1" id="contentdiv">
|
$('.dropdown-toggle').click(function(e) {
|
||||||
<%= yield %>
|
e.preventDefault();
|
||||||
</div>
|
setTimeout($.proxy(function() {
|
||||||
</div>
|
if ('ontouchstart' in document.documentElement) {
|
||||||
</div>
|
$(this).siblings('.dropdown-backdrop').off().remove();
|
||||||
<script>
|
}
|
||||||
$('.dropdown-toggle').click(function(e) {
|
}, this), 0);
|
||||||
e.preventDefault();
|
});
|
||||||
setTimeout($.proxy(function() {
|
</script>
|
||||||
if ('ontouchstart' in document.documentElement) {
|
|
||||||
$(this).siblings('.dropdown-backdrop').off().remove();
|
|
||||||
}
|
|
||||||
}, this), 0);
|
|
||||||
});
|
|
||||||
</script>
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
@@ -82,9 +82,12 @@
|
|||||||
<div class="row-fluid">
|
<div class="row-fluid">
|
||||||
<div class="span12">
|
<div class="span12">
|
||||||
<%= new_question_for(@lva) %>
|
<%= new_question_for(@lva) %>
|
||||||
|
<% unless @questions.nil? %>
|
||||||
<% @questions.each do |q| %>
|
<% @questions.each do |q| %>
|
||||||
<%= render q if can? :show, q %>
|
<%= render q if can? :show, q %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
|
||||||
<h2><%= I18n.t("lva.bspe") %></h2>
|
<h2><%= I18n.t("lva.bspe") %></h2>
|
||||||
<p>
|
<p>
|
||||||
|
|||||||
@@ -16,6 +16,7 @@ de:
|
|||||||
savecont: "Zwischenspeichern"
|
savecont: "Zwischenspeichern"
|
||||||
intern: "Intern"
|
intern: "Intern"
|
||||||
manage: "Verwalten"
|
manage: "Verwalten"
|
||||||
|
new: "Neu"
|
||||||
home:
|
home:
|
||||||
sprache: "Deutsch"
|
sprache: "Deutsch"
|
||||||
kontakt: "Kontakt"
|
kontakt: "Kontakt"
|
||||||
|
|||||||
@@ -6,6 +6,7 @@ de:
|
|||||||
active_members: "Aktive Mitglieder"
|
active_members: "Aktive Mitglieder"
|
||||||
notactive_members: "Pension"
|
notactive_members: "Pension"
|
||||||
new_profile: "Neues Profil anlegen"
|
new_profile: "Neues Profil anlegen"
|
||||||
|
new: "Neues Profil anlegen"
|
||||||
gremium:
|
gremium:
|
||||||
new: "Neues Gremium"
|
new: "Neues Gremium"
|
||||||
seit: "seit"
|
seit: "seit"
|
||||||
|
|||||||
@@ -15,8 +15,8 @@
|
|||||||
get 'internlist'
|
get 'internlist'
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
resources :gremien do
|
resources :gremien do
|
||||||
collection do
|
collection do
|
||||||
get 'verwalten'
|
get 'verwalten'
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@@ -35,7 +35,7 @@
|
|||||||
resources :choices
|
resources :choices
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
themes_for_rails
|
themes_for_rails
|
||||||
devise_for :users, :controllers => { :omniauth_callbacks => "users/omniauth_callbacks" }
|
devise_for :users, :controllers => { :omniauth_callbacks => "users/omniauth_callbacks" }
|
||||||
resources :home, :only=>[:index] do
|
resources :home, :only=>[:index] do
|
||||||
@@ -47,7 +47,7 @@ resources :emails, :only=>[:index] do
|
|||||||
end
|
end
|
||||||
get ':locale', constraints: {locale: /en|de/}, action: :language,controller: :home, as: "language"
|
get ':locale', constraints: {locale: /en|de/}, action: :language,controller: :home, as: "language"
|
||||||
scope '(:locale)/admin' do
|
scope '(:locale)/admin' do
|
||||||
resources :users, :only=>[] do
|
resources :users, :only=>[] do
|
||||||
collection do
|
collection do
|
||||||
get :index
|
get :index
|
||||||
post :all_update
|
post :all_update
|
||||||
@@ -73,13 +73,14 @@ end
|
|||||||
end
|
end
|
||||||
devise_for :users , :controllers=>{:omniauth_callbacks=> "users/omniauth_callbacks"}
|
devise_for :users , :controllers=>{:omniauth_callbacks=> "users/omniauth_callbacks"}
|
||||||
|
|
||||||
|
|
||||||
scope '(:locale)', constraints: {:locale=>/en|de/i} do
|
scope '(:locale)', constraints: {:locale=>/en|de/i} do
|
||||||
get 't/:theme/:url', to: redirect('/%{url}')
|
get 't/:theme/:url', to: redirect('/%{url}')
|
||||||
scope '(t/:theme)' do
|
scope '(t/:theme)' do
|
||||||
get "" , controller: :home, action: :index
|
get "" , controller: :home, action: :index
|
||||||
get "intern" , controller: :home, action: :intern
|
get "intern" , controller: :home, action: :intern
|
||||||
get "infoscreen" , controller: :home, action: :infoscreen
|
get "infoscreen" , controller: :home, action: :infoscreen
|
||||||
|
get "verleihkalender" , controller: :home, action: :verleihkalender
|
||||||
get "beispielsammlung", to: redirect('/studien')
|
get "beispielsammlung", to: redirect('/studien')
|
||||||
scope '(:ansicht)' do
|
scope '(:ansicht)' do
|
||||||
resources :studien, :only=>[:new,:edit,:update,:destroy,:show] do
|
resources :studien, :only=>[:new,:edit,:update,:destroy,:show] do
|
||||||
@@ -88,11 +89,11 @@ end
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
resources :modulgruppen,:only =>[:create,:index] do
|
resources :modulgruppen,:only =>[:create,:index] do
|
||||||
end
|
end
|
||||||
|
|
||||||
resources :studien,:except=>[:show,:new,:edit,:update,:destroy], :shallow=>true do
|
resources :studien,:except=>[:show,:new,:edit,:update,:destroy], :shallow=>true do
|
||||||
resources :modulgruppen, :path => "(:locale)/modulgruppen"
|
resources :modulgruppen, :path => "(:locale)/modulgruppen"
|
||||||
end
|
end
|
||||||
get 'verwalten/studien', :controller=>:studien, :action=>:verwalten, :as=>'studien_verwalten'
|
get 'verwalten/studien', :controller=>:studien, :action=>:verwalten, :as=>'studien_verwalten'
|
||||||
@@ -102,7 +103,7 @@ end
|
|||||||
resources :moduls do
|
resources :moduls do
|
||||||
member do
|
member do
|
||||||
get 'edit_lvas'
|
get 'edit_lvas'
|
||||||
post 'update_lvas'
|
post 'update_lvas'
|
||||||
get 'load_tiss'
|
get 'load_tiss'
|
||||||
post 'show_tiss'
|
post 'show_tiss'
|
||||||
end
|
end
|
||||||
@@ -111,7 +112,7 @@ end
|
|||||||
get 'new_bulk'
|
get 'new_bulk'
|
||||||
post 'update_bulk'
|
post 'update_bulk'
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
resources :beispiele do #, :only=>[:show,:index,:create]
|
resources :beispiele do #, :only=>[:show,:index,:create]
|
||||||
member do
|
member do
|
||||||
@@ -121,7 +122,7 @@ end
|
|||||||
get 'set_lecturer'
|
get 'set_lecturer'
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
resources :lvas do
|
resources :lvas do
|
||||||
member do
|
member do
|
||||||
get 'beispiel_sammlung'
|
get 'beispiel_sammlung'
|
||||||
get 'compare_tiss'
|
get 'compare_tiss'
|
||||||
@@ -130,8 +131,8 @@ end
|
|||||||
end
|
end
|
||||||
resources :beispiele#, :only=>[:show,:index,:create]
|
resources :beispiele#, :only=>[:show,:index,:create]
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
resources :fetzneditions
|
resources :fetzneditions
|
||||||
resources :galleries do
|
resources :galleries do
|
||||||
collection do
|
collection do
|
||||||
@@ -139,14 +140,14 @@ end
|
|||||||
end
|
end
|
||||||
resources :fotos
|
resources :fotos
|
||||||
end
|
end
|
||||||
|
|
||||||
resources :gremien do
|
resources :gremien do
|
||||||
collection do
|
collection do
|
||||||
get 'verwalten'
|
get 'verwalten'
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
# resources :fetprofiles, as: :fetprofiles_bak do
|
# resources :fetprofiles, as: :fetprofiles_bak do
|
||||||
# collection do
|
# collection do
|
||||||
# get 'verwalten'
|
# get 'verwalten'
|
||||||
# get 'internlist'
|
# get 'internlist'
|
||||||
# end
|
# end
|
||||||
@@ -158,12 +159,12 @@ end
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
resources :fragen, :only =>[:new, :edit, :update, :destroy, :create]
|
resources :fragen, :only =>[:new, :edit, :update, :destroy, :create]
|
||||||
|
|
||||||
|
|
||||||
resources :neuigkeiten, :only => [:show] , constraints: {id: /\d+/i}
|
|
||||||
|
resources :neuigkeiten, :only => [:show] , constraints: {id: /\d+/i}
|
||||||
get "neuigkeiten", controller: :rubriken, action: :index, as: "neuigkeiten"
|
get "neuigkeiten", controller: :rubriken, action: :index, as: "neuigkeiten"
|
||||||
resources :rubriken do
|
resources :rubriken do
|
||||||
collection do
|
collection do
|
||||||
get 'verwalten' , :action => :alle_verwalten
|
get 'verwalten' , :action => :alle_verwalten
|
||||||
get 'intern'
|
get 'intern'
|
||||||
end
|
end
|
||||||
@@ -173,7 +174,7 @@ end
|
|||||||
get 'removemoderator'
|
get 'removemoderator'
|
||||||
end
|
end
|
||||||
|
|
||||||
resources :neuigkeiten, :except => [:index] do
|
resources :neuigkeiten, :except => [:index] do
|
||||||
member do
|
member do
|
||||||
get 'publish'
|
get 'publish'
|
||||||
get 'unpublish'
|
get 'unpublish'
|
||||||
@@ -197,7 +198,7 @@ end
|
|||||||
collection do
|
collection do
|
||||||
get 'intern'
|
get 'intern'
|
||||||
get 'treeview'
|
get 'treeview'
|
||||||
get 'admin'
|
get 'admin'
|
||||||
get 'dev'
|
get 'dev'
|
||||||
get 'startdev'
|
get 'startdev'
|
||||||
get 'linksnotimplemented'
|
get 'linksnotimplemented'
|
||||||
@@ -208,14 +209,14 @@ end
|
|||||||
end
|
end
|
||||||
|
|
||||||
resources :themengruppen do
|
resources :themengruppen do
|
||||||
get :verwalten
|
get :verwalten
|
||||||
get :verwalten_all,:on=>:collection
|
get :verwalten_all,:on=>:collection
|
||||||
get :faqs, :on=>:collection
|
get :faqs, :on=>:collection
|
||||||
post :sort_themen
|
post :sort_themen
|
||||||
post :sort_themengruppen, :on=>:collection
|
post :sort_themengruppen, :on=>:collection
|
||||||
resources :themen, :only=>[:new, :show]
|
resources :themen, :only=>[:new, :show]
|
||||||
end
|
end
|
||||||
|
|
||||||
resources :themen do
|
resources :themen do
|
||||||
member do
|
member do
|
||||||
get :attachments
|
get :attachments
|
||||||
@@ -227,14 +228,14 @@ end
|
|||||||
get :meetings
|
get :meetings
|
||||||
end
|
end
|
||||||
resources :attachments do
|
resources :attachments do
|
||||||
member do
|
member do
|
||||||
get :set_titlepic
|
get :set_titlepic
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
resources :attachments do
|
resources :attachments do
|
||||||
member do
|
member do
|
||||||
get :set_titlepic
|
get :set_titlepic
|
||||||
end
|
end
|
||||||
collection do
|
collection do
|
||||||
@@ -260,12 +261,12 @@ end
|
|||||||
member do
|
member do
|
||||||
get :announce
|
get :announce
|
||||||
get :create_protocol
|
get :create_protocol
|
||||||
get :create_agenda
|
get :create_agenda
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
resources :meetingtyps do
|
resources :meetingtyps do
|
||||||
member do
|
member do
|
||||||
get :create_protocol_and_agenda
|
get :create_protocol_and_agenda
|
||||||
@@ -275,5 +276,3 @@ end
|
|||||||
end
|
end
|
||||||
root :to => 'home#index'
|
root :to => 'home#index'
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -3,18 +3,23 @@ production:
|
|||||||
hostname: localhost
|
hostname: localhost
|
||||||
port: 8080
|
port: 8080
|
||||||
log_level: WARNING
|
log_level: WARNING
|
||||||
path: /solr-4.10.2/default #production #ollection1 #production
|
path: /solr/#/default #production #ollection1 #production
|
||||||
# solr_home: solr
|
# solr_home: solr
|
||||||
# read_timeout: 2
|
# read_timeout: 2
|
||||||
# open_timeout: 0.5
|
# open_timeout: 0.5
|
||||||
|
|
||||||
development:
|
development:
|
||||||
solr:
|
solr:
|
||||||
hostname: localhost
|
hostname: triton-amp.local
|
||||||
port: 8982
|
port: 8080
|
||||||
log_level: INFO
|
log_level: INFO
|
||||||
path: /solr/development
|
path: /solr/mycore
|
||||||
|
# solr:
|
||||||
|
# hostname: localhost
|
||||||
|
# port: 8983
|
||||||
|
# log_level: INFO
|
||||||
|
# path: /solr/mycore
|
||||||
|
|
||||||
test:
|
test:
|
||||||
solr:
|
solr:
|
||||||
hostname: localhost
|
hostname: localhost
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
#! /bin/bash
|
#! /bin/bash
|
||||||
ruby_command="ruby"
|
ruby_command="ruby"
|
||||||
rake_command="rake"
|
rake_command="rake"
|
||||||
bundler_command="bundler"
|
bundler_command="bundle"
|
||||||
|
|
||||||
# Are the necessary programs installed?
|
# Are the necessary programs installed?
|
||||||
command -v $ruby_command >/dev/null 2>&1 || { echo >&2 "The given ruby command does not exist. Please change the command or install ruby"; exit 1; }
|
command -v $ruby_command >/dev/null 2>&1 || { echo >&2 "The given ruby command does not exist. Please change the command or install ruby"; exit 1; }
|
||||||
@@ -14,19 +14,21 @@ echo "Generating base configs..."
|
|||||||
# Generate clean config files if they don't exist
|
# Generate clean config files if they don't exist
|
||||||
cp -u config/database.yml.example config/database.yml
|
cp -u config/database.yml.example config/database.yml
|
||||||
cp -u config/omniauth_secrets.yml.example config/omniauth_secrets.yml
|
cp -u config/omniauth_secrets.yml.example config/omniauth_secrets.yml
|
||||||
|
touch config/crawl_config.yml
|
||||||
echo "Bundle install..."
|
echo "Bundle install..."
|
||||||
# Run Bundler
|
# Run Bundler
|
||||||
$bundler_command install || {echo "Bundler failed. Please run \"$bundle\_command install\" seperately and debug the errors, before running this script again";exit 1;}
|
$bundler_command install || { echo "Bundler failed. Please run \"$bundle\_command install\" seperately and debug the errors, before running this script again";exit 1; }
|
||||||
|
|
||||||
echo "Migrate the database..."
|
echo "Migrate the database..."
|
||||||
# Run the migration
|
# Run the migration
|
||||||
$rake_command db:migrate ||{echo "Migration failed. Please run \"$rake\_command db:migrate\" seperately and debug the errors, before running this script again"; exit 1;}
|
$rake_command db:migrate || { echo "Migration failed. Please run \"$rake\_command db:migrate\" seperately and debug the errors, before running this script again"; exit 1; }
|
||||||
|
|
||||||
|
|
||||||
echo "Start the sunspot server"
|
echo "Start the sunspot server"
|
||||||
# Run Sunspot
|
# Run Sunspot
|
||||||
$rake_command sunspot:solr:stop &> /dev/null
|
$rake_command sunspot:solr:stop &> /dev/null
|
||||||
$rake_command sunspot:solr:start || exit 1
|
$rake_command sunspot:solr:start || exit 1
|
||||||
|
bundle exec sunspot-solr start -p 8982
|
||||||
|
|
||||||
# Topic 1 is supposed to be the startpage topic
|
# Topic 1 is supposed to be the startpage topic
|
||||||
if [ ! -f config/start_topic.yml ]; then
|
if [ ! -f config/start_topic.yml ]; then
|
||||||
@@ -34,7 +36,7 @@ if [ ! -f config/start_topic.yml ]; then
|
|||||||
echo "1" > config/start_topic.yml
|
echo "1" > config/start_topic.yml
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Generate fetadmin user "admin@fet.at", password: 12345678
|
touch config/crawl_config.yml
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
BIN
public/assets/infoscreen_header_provisorisch.png
Normal file
BIN
public/assets/infoscreen_header_provisorisch.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 42 KiB |
134
public/assets/infoscreenframe.css
Normal file
134
public/assets/infoscreenframe.css
Normal file
@@ -0,0 +1,134 @@
|
|||||||
|
html {
|
||||||
|
background-color: #fff;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
|
body {
|
||||||
|
display: flex;
|
||||||
|
flex-flow: wrap;
|
||||||
|
height: 100vh;
|
||||||
|
justify-content: space-between;
|
||||||
|
flex-direction: column;
|
||||||
|
}
|
||||||
|
|
||||||
|
.header {
|
||||||
|
height: 200px;
|
||||||
|
width: 100%
|
||||||
|
}
|
||||||
|
|
||||||
|
svg {
|
||||||
|
padding-top: 2em;
|
||||||
|
}
|
||||||
|
|
||||||
|
.impulsPath {
|
||||||
|
fill: none;
|
||||||
|
stroke: #04669c;
|
||||||
|
stroke-miterlimit: 1;
|
||||||
|
stroke-width: 6px;
|
||||||
|
stroke-dasharray: 1946.243;
|
||||||
|
stroke-dashoffset: 0;
|
||||||
|
stroke-linejoin: round;
|
||||||
|
stroke-linecap: round;
|
||||||
|
animation: dash 10s ease-out infinite;
|
||||||
|
animation-direction: normal;
|
||||||
|
}
|
||||||
|
|
||||||
|
.FET-logotext-stroke {
|
||||||
|
fill: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
#FET-logotext {
|
||||||
|
opacity: 0;
|
||||||
|
animation: logotext 10s ease-in infinite;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
.content-area {
|
||||||
|
|
||||||
|
height: auto;
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer {
|
||||||
|
width: 100%;
|
||||||
|
height: 150px;
|
||||||
|
background-color: #04669c;
|
||||||
|
padding-bottom: 10px;
|
||||||
|
display: flex;
|
||||||
|
flex-wrap: nowrap;
|
||||||
|
justify-content: space-between;
|
||||||
|
color: #fff;
|
||||||
|
flex-basis: bottom;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer h3,
|
||||||
|
p {
|
||||||
|
margin: 0;
|
||||||
|
padding: 0 20px;
|
||||||
|
font-family: Helvetica, Arial;
|
||||||
|
letter-spacing: 0.1em;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer h3 {
|
||||||
|
padding-top: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer .adress {
|
||||||
|
margin: auto;
|
||||||
|
text-align: left;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer .contact {
|
||||||
|
margin: auto;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer .servicecontainer{
|
||||||
|
display: inline-flex;
|
||||||
|
margin: auto;
|
||||||
|
|
||||||
|
}
|
||||||
|
.footer .servicecontainer .servicetime {
|
||||||
|
margin: auto;
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer .servicecontainer .servicetime #time {
|
||||||
|
font-size: 0.7em
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer .servicecontainer .servicestatus{
|
||||||
|
margin: auto;
|
||||||
|
width:20px;
|
||||||
|
height: 100%
|
||||||
|
padding-right: 30px;
|
||||||
|
background-color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*K E Y F R A M E S*/
|
||||||
|
|
||||||
|
@keyframes dash {
|
||||||
|
from {
|
||||||
|
stroke-dashoffset: 1946.243;
|
||||||
|
opacity: 0;
|
||||||
|
stroke-width: 0.5;
|
||||||
|
}
|
||||||
|
to {
|
||||||
|
opacity: 1;
|
||||||
|
stroke-dashoffset: 0;
|
||||||
|
stroke-width: 5px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes logotext {
|
||||||
|
from {
|
||||||
|
opacity: 0;
|
||||||
|
}
|
||||||
|
to {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
134
public/iframe/infoscreenframe.css
Normal file
134
public/iframe/infoscreenframe.css
Normal file
@@ -0,0 +1,134 @@
|
|||||||
|
html {
|
||||||
|
background-color: #fff;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
|
body {
|
||||||
|
display: flex;
|
||||||
|
flex-flow: wrap;
|
||||||
|
height: 100vh;
|
||||||
|
justify-content: space-between;
|
||||||
|
flex-direction: column;
|
||||||
|
}
|
||||||
|
|
||||||
|
.header {
|
||||||
|
height: 200px;
|
||||||
|
width: 100%
|
||||||
|
}
|
||||||
|
|
||||||
|
svg {
|
||||||
|
padding-top: 2em;
|
||||||
|
}
|
||||||
|
|
||||||
|
.impulsPath {
|
||||||
|
fill: none;
|
||||||
|
stroke: #04669c;
|
||||||
|
stroke-miterlimit: 1;
|
||||||
|
stroke-width: 6px;
|
||||||
|
stroke-dasharray: 1946.243;
|
||||||
|
stroke-dashoffset: 0;
|
||||||
|
stroke-linejoin: round;
|
||||||
|
stroke-linecap: round;
|
||||||
|
animation: dash 10s ease-out infinite;
|
||||||
|
animation-direction: normal;
|
||||||
|
}
|
||||||
|
|
||||||
|
.FET-logotext-stroke {
|
||||||
|
fill: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
#FET-logotext {
|
||||||
|
opacity: 0;
|
||||||
|
animation: logotext 10s ease-in infinite;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
.content-area {
|
||||||
|
|
||||||
|
height: auto;
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer {
|
||||||
|
width: 100%;
|
||||||
|
height: 150px;
|
||||||
|
background-color: #04669c;
|
||||||
|
padding-bottom: 10px;
|
||||||
|
display: flex;
|
||||||
|
flex-wrap: nowrap;
|
||||||
|
justify-content: space-between;
|
||||||
|
color: #fff;
|
||||||
|
flex-basis: bottom;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer h3,
|
||||||
|
p {
|
||||||
|
margin: 0;
|
||||||
|
padding: 0 20px;
|
||||||
|
font-family: Helvetica, Arial;
|
||||||
|
letter-spacing: 0.1em;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer h3 {
|
||||||
|
padding-top: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer .adress {
|
||||||
|
margin: auto;
|
||||||
|
text-align: left;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer .contact {
|
||||||
|
margin: auto;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer .servicecontainer{
|
||||||
|
display: inline-flex;
|
||||||
|
margin: auto;
|
||||||
|
|
||||||
|
}
|
||||||
|
.footer .servicecontainer .servicetime {
|
||||||
|
margin: auto;
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer .servicecontainer .servicetime #time {
|
||||||
|
font-size: 0.7em
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer .servicecontainer .servicestatus{
|
||||||
|
margin: auto;
|
||||||
|
width:20px;
|
||||||
|
height: 100%
|
||||||
|
padding-right: 30px;
|
||||||
|
background-color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*K E Y F R A M E S*/
|
||||||
|
|
||||||
|
@keyframes dash {
|
||||||
|
from {
|
||||||
|
stroke-dashoffset: 1946.243;
|
||||||
|
opacity: 0;
|
||||||
|
stroke-width: 0.5;
|
||||||
|
}
|
||||||
|
to {
|
||||||
|
opacity: 1;
|
||||||
|
stroke-dashoffset: 0;
|
||||||
|
stroke-width: 5px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes logotext {
|
||||||
|
from {
|
||||||
|
opacity: 0;
|
||||||
|
}
|
||||||
|
to {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
104
public/iframe/infoscreenframe.html
Normal file
104
public/iframe/infoscreenframe.html
Normal file
@@ -0,0 +1,104 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="de">
|
||||||
|
|
||||||
|
<head>
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<title>Infoscreen</title>
|
||||||
|
<style media="screen">
|
||||||
|
pre.code {
|
||||||
|
-moz-border-radius: 10px;
|
||||||
|
-webkit-border-radius: 10px;
|
||||||
|
border-radius: 10px;
|
||||||
|
padding: 10px;
|
||||||
|
height: 280px;
|
||||||
|
overflow: auto;
|
||||||
|
background: #181818;
|
||||||
|
border: solid 2px #181818;
|
||||||
|
}
|
||||||
|
|
||||||
|
#codelines {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
#svg {
|
||||||
|
-moz-border-radius: 10px;
|
||||||
|
-webkit-border-radius: 10px;
|
||||||
|
border-radius: 10px;
|
||||||
|
border: solid 2px #ccc;
|
||||||
|
width: 300px;
|
||||||
|
height: 300px;
|
||||||
|
float: left;
|
||||||
|
margin-right: 10px;
|
||||||
|
font: 1em source-sans-pro, Source Sans Pro, Helvetica, sans-serif;
|
||||||
|
}
|
||||||
|
|
||||||
|
</style>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<link rel="stylesheet" href="./infoscreenframe.css">
|
||||||
|
|
||||||
|
|
||||||
|
</head>
|
||||||
|
|
||||||
|
<body>
|
||||||
|
<div class="header">
|
||||||
|
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1280 200">
|
||||||
|
<path id="impulsPath" class="impulsPath" d="M0,61.43H1018c2.41,0,6.77-2.28,9.12-2.28,2.66,0,8.3,6.58,11.65,6.58,3.16,0,7.47-15.07,10-15.07,4.3,0,10.38,29.62,14.18,29.62s11.89-55.47,13.67-55.47c5.32,0,10.63,86.34,14.18,86.34,4.3,0,10.63-111.15,13.42-111.15,3.54,0,8.86,123.56,13.17,123.56,3.8,0,8.36-116.85,13.55-116.85,3.42,0,8.74,100,13.67,100,3.67,0,9.24-71.15,12.91-71.15,3.42,0,10.51,41.78,12.91,41.78,3.42,0,8.48-24.56,12.41-24.56,4.43,0,7.93,12.91,12.41,12.91,5.7,0,8.3-6.58,11.65-6.58s6.77,2.28,9.12,2.28h64"/>
|
||||||
|
<g id="FET-logotext"><g id="F"><path d="M1042,82.71l12.7-35.9v-.1c.2-.3,3.8-8.5,13.1-9.6h37.9l-4,11.6h-25.8a7.19,7.19,0,0,0-4.8,3.7l-.6,1.6h14.1l-4.1,11.7h-14l-6.1,17Z"/><path class="FET-logotext-stroke" d="M1102.9,39l-2.6,7.6h-24.6a9.18,9.18,0,0,0-6.4,5l-1.6,4.4h14.1l-2.7,7.7h-14l-6.1,17h-14.2l11.7-33.2s3.3-7.5,11.5-8.5h34.9m5.7-4h-40.9c-10.4,1.3-14.5,10.4-14.7,10.8l-.1.1V46L1041,79.31l-1.9,5.3h22.7l.9-2.7,5.1-14.4H1082l.9-2.7,2.7-7.7,1.9-5.3h-13.7a5.48,5.48,0,0,1,2.3-1.4h27.1l.9-2.7,2.6-7.6,1.9-5.1Z"/></g><g id="E"><path d="M1101.3,82.71h-.2a8.59,8.59,0,0,1-6.2-3.8,9.86,9.86,0,0,1-.7-7.9l8.8-24.9.1-.1c.2-.3,4.3-8.1,13.3-9H1154l-4,11.7-26-.1a7.1,7.1,0,0,0-4.6,3.7l-.6,1.7h14.1l-4.1,11.7h-14.2l-1.1,3.1a2.37,2.37,0,0,0,.2,1.6,2.23,2.23,0,0,0,1.2.7h27l-4,11.7h-36.6Z"/><path class="FET-logotext-stroke" d="M1151.2,39l-2.6,7.7-24.8-.1a9.21,9.21,0,0,0-6.2,5l-1.7,4.4H1130l-2.7,7.7h-14.1l-1.6,4.5s-1.1,4.1,3,4.9H1139l-2.6,7.7h-35c-7.8-1.3-5.3-9.1-5.3-9.1l8.7-24.6s3.7-7.1,11.7-7.9l34.7-.2m5.6-4h-40.6c-10.1,1-14.7,9.7-14.9,10l-.1.3-.1.3-8.7,24.6v.2c-.2.5-1.6,5.4.9,9.6a10.41,10.41,0,0,0,7.5,4.7l.3.1h38.2l.9-2.7,2.6-7.7,1.8-5.3h-29l.5-1.4h14.1l.9-2.7,2.7-7.7,1.9-5.3H1122a6.42,6.42,0,0,1,2.2-1.4l24.3.1h2.9l.9-2.7,2.6-7.7,1.9-5.3Z"/></g><g id="T"><path d="M1154.3,82.71l12-34-15.1-.1.9-2.6a14.39,14.39,0,0,1,11.5-9H1204l-4.1,11.7h-15l-12.1,34.1h-18.5Z"/><path class="FET-logotext-stroke" d="M1201.2,38.91l-2.7,7.7h-15l-12.1,34.1h-14.3l12-34-15.1-.1a12.54,12.54,0,0,1,9.9-7.7h37.3m5.7-4h-43.6a16.53,16.53,0,0,0-13.1,10.3l-1.8,5.3h5.6l9.5.1-10.1,28.7-1.9,5.3h22.7l.9-2.7,11.1-31.4h15l.9-2.7,2.7-7.7,2.1-5.2Z"/></g></g>
|
||||||
|
</svg>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div class="content-area">
|
||||||
|
<!-- Inhaltsbereich -->
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<div class="footer">
|
||||||
|
<div class="adress">
|
||||||
|
<h3>Fachschaft Elektrotechnik</h3><br>
|
||||||
|
<p>Gußhausstraße 25-27<br>Room CD 01 09 (1st floor)<br>1040 Vienna</p>
|
||||||
|
</div>
|
||||||
|
<div class="contact">
|
||||||
|
<h3>Contact</h3><br>
|
||||||
|
<p>E-Mail: service@fet.at<br>Phone: +43-1-58801 49553<br></p>
|
||||||
|
</div>
|
||||||
|
<div class="servicecontainer">
|
||||||
|
<div class="servicetime">
|
||||||
|
<h3>Service times</h3><br>
|
||||||
|
<p style="text-align: right">Mon to Thur: 9am to 02pm<br>Fri: 9am to 12am<br>
|
||||||
|
<span id="time"></span>
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="servicestatus">
|
||||||
|
<!-- <svg class="servicestatusled">
|
||||||
|
<circle id="servicestatusled" cx="10" cy="15" r="10" style="fill: red" />
|
||||||
|
</svg> -->
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<script>
|
||||||
|
var today = new Date();
|
||||||
|
today = today;
|
||||||
|
document.getElementById('time').innerHTML = today;
|
||||||
|
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
|
|
||||||
|
</html>
|
||||||
Reference in New Issue
Block a user