forked from bofh/fetsite
Merge remote-tracking branch 'origin'
This commit is contained in:
2
.gitignore
vendored
2
.gitignore
vendored
@@ -5,6 +5,7 @@
|
||||
/config/omniauth_secrets.yml
|
||||
/config/database.yml
|
||||
/config/initializers/omniauth_secrets.rb
|
||||
/config/databas*
|
||||
# See http://help.github.com/ignore-files/ for more about ignoring files.
|
||||
#
|
||||
# If you find yourself ignoring temporary files generated by your text editor
|
||||
@@ -33,3 +34,4 @@ console
|
||||
/bak/*
|
||||
*#
|
||||
Gemfile.lock
|
||||
/config/database.yml
|
||||
|
||||
14
Gemfile
14
Gemfile
@@ -45,7 +45,7 @@ gem 'jquery-rails'
|
||||
gem 'formtastic', '~>2.2.1'
|
||||
gem 'formtastic-bootstrap', '~>2.1.3' #, :git => "git://github.com/mjbellantoni/formtastic-bootstrap.git"
|
||||
# TinyMCE
|
||||
gem "tinymce-rails" , '~>3.5.8'
|
||||
gem "tinymce-rails" , '~>4.1.0'
|
||||
|
||||
# Internationalisierung
|
||||
#gem "globalize3" ,'~>3.0.4'
|
||||
@@ -60,9 +60,10 @@ gem "omniauth"
|
||||
gem "omniauth-facebook"
|
||||
gem "omniauth-ldap"
|
||||
|
||||
gem "fb_graph"
|
||||
|
||||
# Roles for users
|
||||
gem "rolify"
|
||||
|
||||
# Abilities
|
||||
gem "cancan"
|
||||
|
||||
@@ -72,8 +73,9 @@ gem 'paperclip' ,'~>3.4.0'
|
||||
|
||||
gem 'git'
|
||||
gem 'haml'
|
||||
#gem 'RedCloth'
|
||||
#gem 'gollum'
|
||||
gem 'RedCloth'
|
||||
gem 'wikicloth'
|
||||
gem 'gollum-lib'
|
||||
gem 'awesome_nested_set'
|
||||
gem 'annotate', ">=2.5.0"
|
||||
gem 'carrierwave', "~>0.9.0"
|
||||
@@ -89,9 +91,13 @@ gem 'bootstrap-addons-rails'
|
||||
gem "jquery-fileupload-rails"
|
||||
gem "jquery-ui-rails","~> 4.1.1"
|
||||
gem "font-awesome-rails"
|
||||
gem "jquery-datetimepicker-rails"
|
||||
# gem "jquery-sortable-rails"
|
||||
gem "seed_dump", "~> 0.5.3"
|
||||
#gem "themes_for_rails" ,:git =>'git://github.com/tkriplean/themes_for_rails.git'
|
||||
#gem "themes_for_rails", :git=> 'git://github.com/lucasefe/themes_for_rails.git'
|
||||
gem 'themes_for_rails'
|
||||
|
||||
gem 'rubyzip'
|
||||
|
||||
gem 'acts_as_votable'
|
||||
49
Gemfile.lock
49
Gemfile.lock
@@ -9,6 +9,7 @@ GIT
|
||||
GEM
|
||||
remote: https://rubygems.org/
|
||||
specs:
|
||||
RedCloth (4.2.9)
|
||||
actionmailer (3.2.13)
|
||||
actionpack (= 3.2.13)
|
||||
mail (~> 2.5.3)
|
||||
@@ -40,6 +41,7 @@ GEM
|
||||
activerecord (>= 2.3.0)
|
||||
rake (>= 0.8.7)
|
||||
arel (3.0.3)
|
||||
attr_required (1.0.0)
|
||||
awesome_nested_set (2.1.6)
|
||||
activerecord (>= 3.0.0)
|
||||
bcrypt-ruby (3.1.2)
|
||||
@@ -53,6 +55,7 @@ GEM
|
||||
activemodel (>= 3.2.0)
|
||||
activesupport (>= 3.2.0)
|
||||
json (>= 1.7)
|
||||
charlock_holmes (0.6.9.4)
|
||||
climate_control (0.0.3)
|
||||
activesupport (>= 3.0)
|
||||
cocaine (0.5.3)
|
||||
@@ -73,6 +76,7 @@ GEM
|
||||
erubis (2.7.0)
|
||||
execjs (1.4.0)
|
||||
multi_json (~> 1.0)
|
||||
expression_parser (0.9.0)
|
||||
factory_girl (4.3.0)
|
||||
activesupport (>= 3.0.0)
|
||||
factory_girl_rails (4.3.0)
|
||||
@@ -80,6 +84,11 @@ GEM
|
||||
railties (>= 3.0.0)
|
||||
faraday (0.8.8)
|
||||
multipart-post (~> 1.2.0)
|
||||
fb_graph (2.7.15)
|
||||
httpclient (>= 2.2.0.2)
|
||||
multi_json (>= 1.3)
|
||||
rack-oauth2 (>= 0.14.4)
|
||||
tzinfo
|
||||
font-awesome-rails (4.0.3.1)
|
||||
railties (>= 3.2, < 5.0)
|
||||
formtastic (2.2.1)
|
||||
@@ -87,19 +96,34 @@ GEM
|
||||
formtastic-bootstrap (2.1.3)
|
||||
formtastic (~> 2.2)
|
||||
git (1.2.6)
|
||||
github-markup (0.7.5)
|
||||
gitlab-grit (2.6.0)
|
||||
charlock_holmes (~> 0.6.9)
|
||||
diff-lcs (~> 1.1)
|
||||
mime-types (~> 1.15)
|
||||
posix-spawn (~> 0.3.6)
|
||||
globalize (3.0.4)
|
||||
activemodel (>= 3.0.0, < 4.0.0)
|
||||
activerecord (>= 3.0.0, < 4.0.0)
|
||||
globalize-versioning (0.1.0.alpha.1)
|
||||
globalize (>= 3, < 5)
|
||||
paper_trail (~> 3.0.0)
|
||||
gollum-lib (2.0.0)
|
||||
github-markup (>= 0.7.5, < 1.0.0)
|
||||
gitlab-grit (= 2.6.0)
|
||||
nokogiri (~> 1.6.0)
|
||||
rouge (~> 1.3.1)
|
||||
sanitize (~> 2.0.6)
|
||||
stringex (~> 2.1.0)
|
||||
haml (4.0.5)
|
||||
tilt
|
||||
hashie (2.0.5)
|
||||
hike (1.2.3)
|
||||
httpauth (0.2.0)
|
||||
httpclient (2.4.0)
|
||||
i18n (0.6.1)
|
||||
journey (1.0.4)
|
||||
jquery-datetimepicker-rails (2.2.5.0)
|
||||
jquery-fileupload-rails (0.4.1)
|
||||
actionpack (>= 3.1)
|
||||
railties (>= 3.1)
|
||||
@@ -150,10 +174,17 @@ GEM
|
||||
cocaine (~> 0.5.0)
|
||||
mime-types
|
||||
polyglot (0.3.3)
|
||||
posix-spawn (0.3.8)
|
||||
pyu-ruby-sasl (0.0.3.3)
|
||||
rack (1.4.5)
|
||||
rack-cache (1.2)
|
||||
rack (>= 0.4)
|
||||
rack-oauth2 (1.0.8)
|
||||
activesupport (>= 2.3)
|
||||
attr_required (>= 0.0.5)
|
||||
httpclient (>= 2.2.0.2)
|
||||
multi_json (>= 1.3.6)
|
||||
rack (>= 1.1)
|
||||
rack-ssl (1.3.3)
|
||||
rack
|
||||
rack-test (0.6.2)
|
||||
@@ -177,8 +208,10 @@ GEM
|
||||
rdoc (3.12.2)
|
||||
json (~> 1.4)
|
||||
ref (1.0.5)
|
||||
rinku (1.7.3)
|
||||
rmagick (2.13.2)
|
||||
rolify (3.2.0)
|
||||
rouge (1.3.4)
|
||||
rspec-core (2.14.7)
|
||||
rspec-expectations (2.14.4)
|
||||
diff-lcs (>= 1.1.3, < 2.0)
|
||||
@@ -208,6 +241,7 @@ GEM
|
||||
rack (~> 1.0)
|
||||
tilt (~> 1.1, != 1.3.0)
|
||||
sqlite3 (1.3.8)
|
||||
stringex (2.1.2)
|
||||
themes_for_rails (0.5.1)
|
||||
rails (>= 3.0.0)
|
||||
therubyracer (0.12.0)
|
||||
@@ -215,7 +249,7 @@ GEM
|
||||
ref
|
||||
thor (0.18.1)
|
||||
tilt (1.4.1)
|
||||
tinymce-rails (3.5.8)
|
||||
tinymce-rails (4.1.0)
|
||||
railties (>= 3.1.1)
|
||||
treetop (1.4.15)
|
||||
polyglot
|
||||
@@ -226,11 +260,17 @@ GEM
|
||||
json (>= 1.8.0)
|
||||
warden (1.2.3)
|
||||
rack (>= 1.0)
|
||||
webrick (1.3.1)
|
||||
wikicloth (0.8.1)
|
||||
builder
|
||||
expression_parser
|
||||
rinku
|
||||
|
||||
PLATFORMS
|
||||
ruby
|
||||
|
||||
DEPENDENCIES
|
||||
RedCloth
|
||||
annotate (>= 2.5.0)
|
||||
awesome_nested_set
|
||||
bootstrap-addons-rails
|
||||
@@ -241,13 +281,16 @@ DEPENDENCIES
|
||||
devise (~> 2.2.3)
|
||||
execjs (~> 1.4.0)
|
||||
factory_girl_rails
|
||||
fb_graph
|
||||
font-awesome-rails
|
||||
formtastic (~> 2.2.1)
|
||||
formtastic-bootstrap (~> 2.1.3)
|
||||
git
|
||||
globalize (~> 3.0.4)
|
||||
globalize-versioning
|
||||
gollum-lib
|
||||
haml
|
||||
jquery-datetimepicker-rails
|
||||
jquery-fileupload-rails
|
||||
jquery-rails
|
||||
jquery-ui-rails (~> 4.1.1)
|
||||
@@ -269,5 +312,7 @@ DEPENDENCIES
|
||||
sqlite3
|
||||
themes_for_rails
|
||||
therubyracer
|
||||
tinymce-rails (~> 3.5.8)
|
||||
tinymce-rails (~> 4.1.0)
|
||||
uglifier (>= 1.0.3)
|
||||
webrick (= 1.3.1)
|
||||
wikicloth
|
||||
|
||||
BIN
app/assets/fonts/flatfeticon.eot
Normal file
BIN
app/assets/fonts/flatfeticon.eot
Normal file
Binary file not shown.
3
app/assets/fonts/flatfeticon.svg
Normal file
3
app/assets/fonts/flatfeticon.svg
Normal file
File diff suppressed because one or more lines are too long
|
After Width: | Height: | Size: 1.1 MiB |
BIN
app/assets/fonts/flatfeticon.ttf
Normal file
BIN
app/assets/fonts/flatfeticon.ttf
Normal file
Binary file not shown.
BIN
app/assets/fonts/flatfeticon.woff
Normal file
BIN
app/assets/fonts/flatfeticon.woff
Normal file
Binary file not shown.
@@ -26,24 +26,18 @@
|
||||
//= require bootstrap/image-gallery.min
|
||||
//= require jquery-fileupload
|
||||
// require jquery.remotipart
|
||||
//= require jquery.datetimepicker
|
||||
|
||||
function insertAttachment(url,name) {
|
||||
var ext = url.split('.').pop().toLowerCase();
|
||||
var img_ext = [ "jpg", "png", "bmp" , "jpeg" ];
|
||||
|
||||
// if ( img_ext.indexOf(ext) > -1) {
|
||||
// tinymce.activeEditor.setContent(tinymce.activeEditor.getContent({format : 'raw'}) + "<img src=\"" + url + "\" title=\"" + name + "\">");
|
||||
// }
|
||||
// else {
|
||||
// tinymce.activeEditor.setContent(tinymce.activeEditor.getContent({format : 'raw'}) + "<a href=\"" + url + "\">" + name +"</a>");
|
||||
// }
|
||||
|
||||
|
||||
if ( img_ext.indexOf(ext) > -1) {
|
||||
tinymce.activeEditor.execCommand('mceInsertContent', false, "<img src=\"" + url + "\" title=\"" + name + "\">");
|
||||
}
|
||||
else {
|
||||
tinymce.activeEditor.execCommand('mceInsertContent', false, "<a href=\"" + url + "\">" + name +"</a>");
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
function insertIcon_ffi1(name) {
|
||||
tinymce.activeEditor.execCommand('mceInsertContent',false,'<span class="'+name+'"> </span> ')
|
||||
}
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
*= require 'calendars'
|
||||
*= require jquery.fileupload-ui
|
||||
* require 'bootstrap'
|
||||
|
||||
*= require 'tinymce'
|
||||
|
||||
*/
|
||||
// Colorshema #0A64A4
|
||||
|
||||
786
app/assets/stylesheets/flatfeticon1.css.scss
Normal file
786
app/assets/stylesheets/flatfeticon1.css.scss
Normal file
@@ -0,0 +1,786 @@
|
||||
@font-face {
|
||||
font-family: "ffi1";
|
||||
src: url("/assets/flatfeticon.eot");
|
||||
src: url("/assets/flatfeticon.eot#iefix") format("embedded-opentype"),
|
||||
url("/assets/flatfeticon.woff") format("woff"),
|
||||
url("/assets/flatfeticon.ttf") format("truetype"),
|
||||
url("/assets/flatfeticon.svg") format("svg");
|
||||
font-weight: normal;
|
||||
font-style: normal;
|
||||
}
|
||||
[class^="ffi1-"]:before, [class*=" ffi1-"]:before,
|
||||
[class^="ffi1-"]:after, [class*=" ffi1-"]:after {
|
||||
font-family: ffi1;
|
||||
font-style: normal;
|
||||
margin-left: 4px;
|
||||
font-weight:normal;
|
||||
}
|
||||
|
||||
.ffi1-academic:before {
|
||||
content: "\e000";
|
||||
}
|
||||
.ffi1-apple:before {
|
||||
content: "\e001";
|
||||
}
|
||||
.ffi1-auricular6:before {
|
||||
content: "\e002";
|
||||
}
|
||||
.ffi1-bag2:before {
|
||||
content: "\e003";
|
||||
}
|
||||
.ffi1-bald34:before {
|
||||
content: "\e004";
|
||||
}
|
||||
.ffi1-balloons2:before {
|
||||
content: "\e005";
|
||||
}
|
||||
.ffi1-banes:before {
|
||||
content: "\e006";
|
||||
}
|
||||
.ffi1-bar1:before {
|
||||
content: "\e007";
|
||||
}
|
||||
.ffi1-black268:before {
|
||||
content: "\e008";
|
||||
}
|
||||
.ffi1-book119:before {
|
||||
content: "\e009";
|
||||
}
|
||||
.ffi1-book135:before {
|
||||
content: "\e00a";
|
||||
}
|
||||
.ffi1-book137:before {
|
||||
content: "\e00b";
|
||||
}
|
||||
.ffi1-book139:before {
|
||||
content: "\e00c";
|
||||
}
|
||||
.ffi1-books17:before {
|
||||
content: "\e00d";
|
||||
}
|
||||
.ffi1-books19:before {
|
||||
content: "\e00e";
|
||||
}
|
||||
.ffi1-books20:before {
|
||||
content: "\e00f";
|
||||
}
|
||||
.ffi1-books30:before {
|
||||
content: "\e010";
|
||||
}
|
||||
.ffi1-books8:before {
|
||||
content: "\e011";
|
||||
}
|
||||
.ffi1-boy21:before {
|
||||
content: "\e012";
|
||||
}
|
||||
.ffi1-bricks2:before {
|
||||
content: "\e013";
|
||||
}
|
||||
.ffi1-briefcase32:before {
|
||||
content: "\e014";
|
||||
}
|
||||
.ffi1-businessman216:before {
|
||||
content: "\e015";
|
||||
}
|
||||
.ffi1-businessman217:before {
|
||||
content: "\e016";
|
||||
}
|
||||
.ffi1-businessman56:before {
|
||||
content: "\e017";
|
||||
}
|
||||
.ffi1-businessman65:before {
|
||||
content: "\e018";
|
||||
}
|
||||
.ffi1-businessmen32:before {
|
||||
content: "\e019";
|
||||
}
|
||||
.ffi1-calculator40:before {
|
||||
content: "\e01a";
|
||||
}
|
||||
.ffi1-calendar130:before {
|
||||
content: "\e01b";
|
||||
}
|
||||
.ffi1-call36:before {
|
||||
content: "\e01c";
|
||||
}
|
||||
.ffi1-call7:before {
|
||||
content: "\e01d";
|
||||
}
|
||||
.ffi1-candy1:before {
|
||||
content: "\e01e";
|
||||
}
|
||||
.ffi1-candy10:before {
|
||||
content: "\e01f";
|
||||
}
|
||||
.ffi1-career:before {
|
||||
content: "\e020";
|
||||
}
|
||||
.ffi1-certificate2:before {
|
||||
content: "\e021";
|
||||
}
|
||||
.ffi1-checkboxmark:before {
|
||||
content: "\e022";
|
||||
}
|
||||
.ffi1-chemistry:before {
|
||||
content: "\e023";
|
||||
}
|
||||
.ffi1-chemistry1:before {
|
||||
content: "\e024";
|
||||
}
|
||||
.ffi1-circular114:before {
|
||||
content: "\e025";
|
||||
}
|
||||
.ffi1-circular116:before {
|
||||
content: "\e026";
|
||||
}
|
||||
.ffi1-class6:before {
|
||||
content: "\e027";
|
||||
}
|
||||
.ffi1-classroom:before {
|
||||
content: "\e028";
|
||||
}
|
||||
.ffi1-cleaning1:before {
|
||||
content: "\e029";
|
||||
}
|
||||
.ffi1-clipboard44:before {
|
||||
content: "\e02a";
|
||||
}
|
||||
.ffi1-close13:before {
|
||||
content: "\e02b";
|
||||
}
|
||||
.ffi1-cocktail15:before {
|
||||
content: "\e02c";
|
||||
}
|
||||
.ffi1-cocktail7:before {
|
||||
content: "\e02d";
|
||||
}
|
||||
.ffi1-coffee20:before {
|
||||
content: "\e02e";
|
||||
}
|
||||
.ffi1-coins24:before {
|
||||
content: "\e02f";
|
||||
}
|
||||
.ffi1-colors3:before {
|
||||
content: "\e030";
|
||||
}
|
||||
.ffi1-comfortable:before {
|
||||
content: "\e031";
|
||||
}
|
||||
.ffi1-comments16:before {
|
||||
content: "\e032";
|
||||
}
|
||||
.ffi1-compass58:before {
|
||||
content: "\e033";
|
||||
}
|
||||
.ffi1-computer135:before {
|
||||
content: "\e034";
|
||||
}
|
||||
.ffi1-computer136:before {
|
||||
content: "\e035";
|
||||
}
|
||||
.ffi1-computers:before {
|
||||
content: "\e036";
|
||||
}
|
||||
.ffi1-connected20:before {
|
||||
content: "\e037";
|
||||
}
|
||||
.ffi1-contacts1:before {
|
||||
content: "\e038";
|
||||
}
|
||||
.ffi1-copy12:before {
|
||||
content: "\e039";
|
||||
}
|
||||
.ffi1-croissant1:before {
|
||||
content: "\e03a";
|
||||
}
|
||||
.ffi1-data39:before {
|
||||
content: "\e03b";
|
||||
}
|
||||
.ffi1-data45:before {
|
||||
content: "\e03c";
|
||||
}
|
||||
.ffi1-delivered:before {
|
||||
content: "\e03d";
|
||||
}
|
||||
.ffi1-delivery35:before {
|
||||
content: "\e03e";
|
||||
}
|
||||
.ffi1-descendant1:before {
|
||||
content: "\e03f";
|
||||
}
|
||||
.ffi1-diploma:before {
|
||||
content: "\e040";
|
||||
}
|
||||
.ffi1-dislike:before {
|
||||
content: "\e041";
|
||||
}
|
||||
.ffi1-dna9:before {
|
||||
content: "\e042";
|
||||
}
|
||||
.ffi1-domain1:before {
|
||||
content: "\e043";
|
||||
}
|
||||
.ffi1-drink24:before {
|
||||
content: "\e044";
|
||||
}
|
||||
.ffi1-dwelling1:before {
|
||||
content: "\e045";
|
||||
}
|
||||
.ffi1-earth23:before {
|
||||
content: "\e046";
|
||||
}
|
||||
.ffi1-ecological2:before {
|
||||
content: "\e047";
|
||||
}
|
||||
.ffi1-edit12:before {
|
||||
content: "\e048";
|
||||
}
|
||||
.ffi1-education14:before {
|
||||
content: "\e049";
|
||||
}
|
||||
.ffi1-education17:before {
|
||||
content: "\e04a";
|
||||
}
|
||||
.ffi1-education20:before {
|
||||
content: "\e04b";
|
||||
}
|
||||
.ffi1-educational8:before {
|
||||
content: "\e04c";
|
||||
}
|
||||
.ffi1-educative1:before {
|
||||
content: "\e04d";
|
||||
}
|
||||
.ffi1-electric6:before {
|
||||
content: "\e04e";
|
||||
}
|
||||
.ffi1-electrical7:before {
|
||||
content: "\e04f";
|
||||
}
|
||||
.ffi1-electronic32:before {
|
||||
content: "\e050";
|
||||
}
|
||||
.ffi1-electronic51:before {
|
||||
content: "\e051";
|
||||
}
|
||||
.ffi1-elegant8:before {
|
||||
content: "\e052";
|
||||
}
|
||||
.ffi1-email20:before {
|
||||
content: "\e053";
|
||||
}
|
||||
.ffi1-facebook1:before {
|
||||
content: "\e054";
|
||||
}
|
||||
.ffi1-facebook30:before {
|
||||
content: "\e055";
|
||||
}
|
||||
.ffi1-female188:before {
|
||||
content: "\e056";
|
||||
}
|
||||
.ffi1-female189:before {
|
||||
content: "\e057";
|
||||
}
|
||||
.ffi1-female218:before {
|
||||
content: "\e058";
|
||||
}
|
||||
.ffi1-food23:before {
|
||||
content: "\e059";
|
||||
}
|
||||
.ffi1-fork27:before {
|
||||
content: "\e05a";
|
||||
}
|
||||
.ffi1-gears3:before {
|
||||
content: "\e05b";
|
||||
}
|
||||
.ffi1-gingerbread:before {
|
||||
content: "\e05c";
|
||||
}
|
||||
.ffi1-girl16:before {
|
||||
content: "\e05d";
|
||||
}
|
||||
.ffi1-glass15:before {
|
||||
content: "\e05e";
|
||||
}
|
||||
.ffi1-good2:before {
|
||||
content: "\e05f";
|
||||
}
|
||||
.ffi1-graduate11:before {
|
||||
content: "\e060";
|
||||
}
|
||||
.ffi1-graduate8:before {
|
||||
content: "\e061";
|
||||
}
|
||||
.ffi1-graduate9:before {
|
||||
content: "\e062";
|
||||
}
|
||||
.ffi1-graduates2:before {
|
||||
content: "\e063";
|
||||
}
|
||||
.ffi1-graduation20:before {
|
||||
content: "\e064";
|
||||
}
|
||||
.ffi1-graduation25:before {
|
||||
content: "\e065";
|
||||
}
|
||||
.ffi1-grocery10:before {
|
||||
content: "\e066";
|
||||
}
|
||||
.ffi1-halloween10:before {
|
||||
content: "\e067";
|
||||
}
|
||||
.ffi1-hammer7:before {
|
||||
content: "\e068";
|
||||
}
|
||||
.ffi1-hand132:before {
|
||||
content: "\e069";
|
||||
}
|
||||
.ffi1-handbag6:before {
|
||||
content: "\e06a";
|
||||
}
|
||||
.ffi1-hands-shake:before {
|
||||
content: "\e06b";
|
||||
}
|
||||
.ffi1-handshake1:before {
|
||||
content: "\e06c";
|
||||
}
|
||||
.ffi1-hardbound:before {
|
||||
content: "\e06d";
|
||||
}
|
||||
.ffi1-head21:before {
|
||||
content: "\e06e";
|
||||
}
|
||||
.ffi1-hierarchical:before {
|
||||
content: "\e06f";
|
||||
}
|
||||
.ffi1-homework:before {
|
||||
content: "\e070";
|
||||
}
|
||||
.ffi1-hot31:before {
|
||||
content: "\e071";
|
||||
}
|
||||
.ffi1-hot50:before {
|
||||
content: "\e072";
|
||||
}
|
||||
.ffi1-house25:before {
|
||||
content: "\e073";
|
||||
}
|
||||
.ffi1-important:before {
|
||||
content: "\e074";
|
||||
}
|
||||
.ffi1-index3:before {
|
||||
content: "\e075";
|
||||
}
|
||||
.ffi1-instructor:before {
|
||||
content: "\e076";
|
||||
}
|
||||
.ffi1-italian1:before {
|
||||
content: "\e077";
|
||||
}
|
||||
.ffi1-job:before {
|
||||
content: "\e078";
|
||||
}
|
||||
.ffi1-judge:before {
|
||||
content: "\e079";
|
||||
}
|
||||
.ffi1-keys:before {
|
||||
content: "\e07a";
|
||||
}
|
||||
.ffi1-kids1:before {
|
||||
content: "\e07b";
|
||||
}
|
||||
.ffi1-kindergarden:before {
|
||||
content: "\e07c";
|
||||
}
|
||||
.ffi1-laptop88:before {
|
||||
content: "\e07d";
|
||||
}
|
||||
.ffi1-lecture1:before {
|
||||
content: "\e07e";
|
||||
}
|
||||
.ffi1-lecture2:before {
|
||||
content: "\e07f";
|
||||
}
|
||||
.ffi1-like3:before {
|
||||
content: "\e080";
|
||||
}
|
||||
.ffi1-live2:before {
|
||||
content: "\e081";
|
||||
}
|
||||
.ffi1-magnifier12:before {
|
||||
content: "\e082";
|
||||
}
|
||||
.ffi1-magnifier13:before {
|
||||
content: "\e083";
|
||||
}
|
||||
.ffi1-male103:before {
|
||||
content: "\e084";
|
||||
}
|
||||
.ffi1-man183:before {
|
||||
content: "\e085";
|
||||
}
|
||||
.ffi1-man204:before {
|
||||
content: "\e086";
|
||||
}
|
||||
.ffi1-man315:before {
|
||||
content: "\e087";
|
||||
}
|
||||
.ffi1-man388:before {
|
||||
content: "\e088";
|
||||
}
|
||||
.ffi1-man397:before {
|
||||
content: "\e089";
|
||||
}
|
||||
.ffi1-man82:before {
|
||||
content: "\e08a";
|
||||
}
|
||||
.ffi1-men9:before {
|
||||
content: "\e08b";
|
||||
}
|
||||
.ffi1-milk8:before {
|
||||
content: "\e08c";
|
||||
}
|
||||
.ffi1-mirrors:before {
|
||||
content: "\e08d";
|
||||
}
|
||||
.ffi1-money13:before {
|
||||
content: "\e08e";
|
||||
}
|
||||
.ffi1-mop1:before {
|
||||
content: "\e08f";
|
||||
}
|
||||
.ffi1-mop2:before {
|
||||
content: "\e090";
|
||||
}
|
||||
.ffi1-movie19:before {
|
||||
content: "\e091";
|
||||
}
|
||||
.ffi1-multiple25:before {
|
||||
content: "\e092";
|
||||
}
|
||||
.ffi1-news:before {
|
||||
content: "\e093";
|
||||
}
|
||||
.ffi1-newspaper9:before {
|
||||
content: "\e094";
|
||||
}
|
||||
.ffi1-note20:before {
|
||||
content: "\e095";
|
||||
}
|
||||
.ffi1-open127:before {
|
||||
content: "\e096";
|
||||
}
|
||||
.ffi1-open135:before {
|
||||
content: "\e097";
|
||||
}
|
||||
.ffi1-open160:before {
|
||||
content: "\e098";
|
||||
}
|
||||
.ffi1-open161:before {
|
||||
content: "\e099";
|
||||
}
|
||||
.ffi1-owl10:before {
|
||||
content: "\e09a";
|
||||
}
|
||||
.ffi1-package8:before {
|
||||
content: "\e09b";
|
||||
}
|
||||
.ffi1-paperclip14:before {
|
||||
content: "\e09c";
|
||||
}
|
||||
.ffi1-party:before {
|
||||
content: "\e09d";
|
||||
}
|
||||
.ffi1-party1:before {
|
||||
content: "\e09e";
|
||||
}
|
||||
.ffi1-pen38:before {
|
||||
content: "\e09f";
|
||||
}
|
||||
.ffi1-pen39:before {
|
||||
content: "\e0a0";
|
||||
}
|
||||
.ffi1-pen43:before {
|
||||
content: "\e0a1";
|
||||
}
|
||||
.ffi1-pencil54:before {
|
||||
content: "\e0a2";
|
||||
}
|
||||
.ffi1-pencil66:before {
|
||||
content: "\e0a3";
|
||||
}
|
||||
.ffi1-pens:before {
|
||||
content: "\e0a4";
|
||||
}
|
||||
.ffi1-people30:before {
|
||||
content: "\e0a5";
|
||||
}
|
||||
.ffi1-personal5:before {
|
||||
content: "\e0a6";
|
||||
}
|
||||
.ffi1-persong:before {
|
||||
content: "\e0a7";
|
||||
}
|
||||
.ffi1-persons8:before {
|
||||
content: "\e0a8";
|
||||
}
|
||||
.ffi1-phone25:before {
|
||||
content: "\e0a9";
|
||||
}
|
||||
.ffi1-pie46:before {
|
||||
content: "\e0aa";
|
||||
}
|
||||
.ffi1-plate7:before {
|
||||
content: "\e0ab";
|
||||
}
|
||||
.ffi1-plug12:before {
|
||||
content: "\e0ac";
|
||||
}
|
||||
.ffi1-plugin:before {
|
||||
content: "\e0ad";
|
||||
}
|
||||
.ffi1-power20:before {
|
||||
content: "\e0ae";
|
||||
}
|
||||
.ffi1-power48:before {
|
||||
content: "\e0af";
|
||||
}
|
||||
.ffi1-printer11:before {
|
||||
content: "\e0b0";
|
||||
}
|
||||
.ffi1-printer70:before {
|
||||
content: "\e0b1";
|
||||
}
|
||||
.ffi1-professor17:before {
|
||||
content: "\e0b2";
|
||||
}
|
||||
.ffi1-professor4:before {
|
||||
content: "\e0b3";
|
||||
}
|
||||
.ffi1-professor5:before {
|
||||
content: "\e0b4";
|
||||
}
|
||||
.ffi1-professor7:before {
|
||||
content: "\e0b5";
|
||||
}
|
||||
.ffi1-pumpkin2:before {
|
||||
content: "\e0b6";
|
||||
}
|
||||
.ffi1-puzzle25:before {
|
||||
content: "\e0b7";
|
||||
}
|
||||
.ffi1-question41:before {
|
||||
content: "\e0b8";
|
||||
}
|
||||
.ffi1-question42:before {
|
||||
content: "\e0b9";
|
||||
}
|
||||
.ffi1-quiz:before {
|
||||
content: "\e0ba";
|
||||
}
|
||||
.ffi1-regular2:before {
|
||||
content: "\e0bb";
|
||||
}
|
||||
.ffi1-remove9:before {
|
||||
content: "\e0bc";
|
||||
}
|
||||
.ffi1-resistor1:before {
|
||||
content: "\e0bd";
|
||||
}
|
||||
.ffi1-ruler14:before {
|
||||
content: "\e0be";
|
||||
}
|
||||
.ffi1-running5:before {
|
||||
content: "\e0bf";
|
||||
}
|
||||
.ffi1-sandwich:before {
|
||||
content: "\e0c0";
|
||||
}
|
||||
.ffi1-scales2:before {
|
||||
content: "\e0c1";
|
||||
}
|
||||
.ffi1-school31:before {
|
||||
content: "\e0c2";
|
||||
}
|
||||
.ffi1-school35:before {
|
||||
content: "\e0c3";
|
||||
}
|
||||
.ffi1-school6:before {
|
||||
content: "\e0c4";
|
||||
}
|
||||
.ffi1-science2:before {
|
||||
content: "\e0c5";
|
||||
}
|
||||
.ffi1-scissors3:before {
|
||||
content: "\e0c6";
|
||||
}
|
||||
.ffi1-search4:before {
|
||||
content: "\e0c7";
|
||||
}
|
||||
.ffi1-search54:before {
|
||||
content: "\e0c8";
|
||||
}
|
||||
.ffi1-services:before {
|
||||
content: "\e0c9";
|
||||
}
|
||||
.ffi1-serving1:before {
|
||||
content: "\e0ca";
|
||||
}
|
||||
.ffi1-setting:before {
|
||||
content: "\e0cb";
|
||||
}
|
||||
.ffi1-sheep1:before {
|
||||
content: "\e0cc";
|
||||
}
|
||||
.ffi1-shop3:before {
|
||||
content: "\e0cd";
|
||||
}
|
||||
.ffi1-shopping66:before {
|
||||
content: "\e0ce";
|
||||
}
|
||||
.ffi1-shopping8:before {
|
||||
content: "\e0cf";
|
||||
}
|
||||
.ffi1-soccer32:before {
|
||||
content: "\e0d0";
|
||||
}
|
||||
.ffi1-social19:before {
|
||||
content: "\e0d1";
|
||||
}
|
||||
.ffi1-speech84:before {
|
||||
content: "\e0d2";
|
||||
}
|
||||
.ffi1-square74:before {
|
||||
content: "\e0d3";
|
||||
}
|
||||
.ffi1-stack21:before {
|
||||
content: "\e0d4";
|
||||
}
|
||||
.ffi1-stopwatch6:before {
|
||||
content: "\e0d5";
|
||||
}
|
||||
.ffi1-store:before {
|
||||
content: "\e0d6";
|
||||
}
|
||||
.ffi1-student13:before {
|
||||
content: "\e0d7";
|
||||
}
|
||||
.ffi1-student15:before {
|
||||
content: "\e0d8";
|
||||
}
|
||||
.ffi1-student40:before {
|
||||
content: "\e0d9";
|
||||
}
|
||||
.ffi1-students3:before {
|
||||
content: "\e0da";
|
||||
}
|
||||
.ffi1-students5:before {
|
||||
content: "\e0db";
|
||||
}
|
||||
.ffi1-students6:before {
|
||||
content: "\e0dc";
|
||||
}
|
||||
.ffi1-students7:before {
|
||||
content: "\e0dd";
|
||||
}
|
||||
.ffi1-sweet8:before {
|
||||
content: "\e0de";
|
||||
}
|
||||
.ffi1-tags2:before {
|
||||
content: "\e0df";
|
||||
}
|
||||
.ffi1-tags3:before {
|
||||
content: "\e0e0";
|
||||
}
|
||||
.ffi1-talking2:before {
|
||||
content: "\e0e1";
|
||||
}
|
||||
.ffi1-teacher12:before {
|
||||
content: "\e0e2";
|
||||
}
|
||||
.ffi1-teacher13:before {
|
||||
content: "\e0e3";
|
||||
}
|
||||
.ffi1-teacher4:before {
|
||||
content: "\e0e4";
|
||||
}
|
||||
.ffi1-teacher8:before {
|
||||
content: "\e0e5";
|
||||
}
|
||||
.ffi1-teacher9:before {
|
||||
content: "\e0e6";
|
||||
}
|
||||
.ffi1-test17:before {
|
||||
content: "\e0e7";
|
||||
}
|
||||
.ffi1-text87:before {
|
||||
content: "\e0e8";
|
||||
}
|
||||
.ffi1-textile:before {
|
||||
content: "\e0e9";
|
||||
}
|
||||
.ffi1-three115:before {
|
||||
content: "\e0ea";
|
||||
}
|
||||
.ffi1-thumb31:before {
|
||||
content: "\e0eb";
|
||||
}
|
||||
.ffi1-toilet1:before {
|
||||
content: "\e0ec";
|
||||
}
|
||||
.ffi1-tools:before {
|
||||
content: "\e0ed";
|
||||
}
|
||||
.ffi1-two174:before {
|
||||
content: "\e0ee";
|
||||
}
|
||||
.ffi1-two185:before {
|
||||
content: "\e0ef";
|
||||
}
|
||||
.ffi1-two28:before {
|
||||
content: "\e0f0";
|
||||
}
|
||||
.ffi1-users1:before {
|
||||
content: "\e0f1";
|
||||
}
|
||||
.ffi1-users2:before {
|
||||
content: "\e0f2";
|
||||
}
|
||||
.ffi1-users5:before {
|
||||
content: "\e0f3";
|
||||
}
|
||||
.ffi1-users6:before {
|
||||
content: "\e0f4";
|
||||
}
|
||||
.ffi1-verified9:before {
|
||||
content: "\e0f5";
|
||||
}
|
||||
.ffi1-view2:before {
|
||||
content: "\e0f6";
|
||||
}
|
||||
.ffi1-wifi10:before {
|
||||
content: "\e0f7";
|
||||
}
|
||||
.ffi1-wind15:before {
|
||||
content: "\e0f8";
|
||||
}
|
||||
.ffi1-winners2:before {
|
||||
content: "\e0f9";
|
||||
}
|
||||
.ffi1-woman83:before {
|
||||
content: "\e0fa";
|
||||
}
|
||||
.ffi1-worker12:before {
|
||||
content: "\e0fb";
|
||||
}
|
||||
.ffi1-worker2:before {
|
||||
content: "\e0fc";
|
||||
}
|
||||
.ffi1-worker4:before {
|
||||
content: "\e0fd";
|
||||
}
|
||||
.ffi1-workers:before {
|
||||
content: "\e0fe";
|
||||
}
|
||||
.ffi1-writing17:before {
|
||||
content: "\e0ff";
|
||||
}
|
||||
@@ -15,11 +15,9 @@ a:hover {
|
||||
text-decoration:none;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@import 'tinymce';
|
||||
@import 'fetlogo';
|
||||
@import 'flatfeticon1';
|
||||
|
||||
|
||||
|
||||
@@ -35,14 +33,77 @@ a.linkbox, div.contentbox
|
||||
border-radius:$box-border-radius;
|
||||
border: $box-border;
|
||||
background: $box-background;
|
||||
|
||||
}
|
||||
|
||||
|
||||
a.linkbox:hover
|
||||
{
|
||||
box-shadow: 1px 1px 2px 2px lightgray;
|
||||
}
|
||||
|
||||
a.linkbox.color-1
|
||||
{
|
||||
color:$color_schema_1;
|
||||
}
|
||||
a.linkbox.color-2
|
||||
{
|
||||
color:$color_schema_2;
|
||||
}
|
||||
a.linkbox.color-3
|
||||
{
|
||||
color:$color_schema_3;
|
||||
}
|
||||
a.linkbox.color-4
|
||||
{
|
||||
color:$color_schema_4;
|
||||
}
|
||||
a.linkbox.color-5
|
||||
{
|
||||
color:$color_schema_5;
|
||||
}
|
||||
|
||||
a.color-1-dark
|
||||
{
|
||||
color:$color_schema_1_dark;
|
||||
}
|
||||
a.color-2-dark
|
||||
{
|
||||
color:$color_schema_2_dark;
|
||||
}
|
||||
a.color-3-dark
|
||||
{
|
||||
color:$color_schema_3_dark;
|
||||
}
|
||||
a.color-4-dark
|
||||
{
|
||||
color:$color_schema_4_dark;
|
||||
}
|
||||
a.color-5-dark
|
||||
{
|
||||
color:$color_schema_5_dark;
|
||||
}
|
||||
a.color-1-dark:hover
|
||||
{
|
||||
color:$color_schema_1;
|
||||
}
|
||||
a.color-2-dark:hover
|
||||
{
|
||||
color:$color_schema_2;
|
||||
}
|
||||
a.color-3-dark:hover
|
||||
{
|
||||
color:$color_schema_3;
|
||||
}
|
||||
a.color-4-dark:hover
|
||||
{
|
||||
color:$color_schema_4;
|
||||
}
|
||||
a.color-5-dark:hover
|
||||
{
|
||||
color:$color_schema_5;
|
||||
}
|
||||
|
||||
|
||||
a.linkbox li
|
||||
{
|
||||
}
|
||||
@@ -90,4 +151,25 @@ div.smallspan {
|
||||
min-height:0;
|
||||
}
|
||||
|
||||
ul.linklist
|
||||
{max-width:25em;
|
||||
padding:0;
|
||||
margin:0;
|
||||
}
|
||||
ul.linklist li{
|
||||
list-style:none;
|
||||
maring-bottom:5px;
|
||||
}
|
||||
ul.linklist li a i{
|
||||
vertical-align:middle;
|
||||
margin-right:6px;
|
||||
font-size:2em;}
|
||||
span.linklist a {
|
||||
padding:5px;
|
||||
border-radius:$box-border-radius;
|
||||
border: $box-border;
|
||||
background: $box-background;
|
||||
display:block;
|
||||
float:left;
|
||||
|
||||
}
|
||||
@@ -1,22 +1,17 @@
|
||||
// Place all the styles related to the themengruppen controller here.
|
||||
// They will automatically be included in application.css.
|
||||
// You can use Sass (SCSS) here: http://sass-lang.com/
|
||||
div.themengruppe
|
||||
{padding:10px;
|
||||
margin:2px;
|
||||
border-radius: 10px;
|
||||
min-width:13em;
|
||||
border: #91B4FF solid 0px;
|
||||
height: 90%
|
||||
}
|
||||
|
||||
a.themengruppe:hover
|
||||
{
|
||||
box-shadow: 1px 1px 2px 2px lightgray;
|
||||
}
|
||||
|
||||
a.themengruppe
|
||||
div.sticker
|
||||
{
|
||||
padding: 5px;
|
||||
display:block;
|
||||
width: 90%;
|
||||
text-align: center;
|
||||
padding: 5px
|
||||
}
|
||||
div.sticker-red
|
||||
{ background: red;
|
||||
}
|
||||
div.sticker-yellow
|
||||
{ background: yellow;
|
||||
}
|
||||
@@ -17,6 +17,19 @@
|
||||
* require 'neuigkeiten'
|
||||
*/
|
||||
// Colorshema #0A64A4
|
||||
$color_schema_1: #006599;
|
||||
$color_schema_2: #630CE8;
|
||||
$color_schema_3: #FF0021;
|
||||
$color_schema_4: #E8820C;
|
||||
$color_schema_5: #FFF30D;
|
||||
|
||||
$color_schema_1_dark: darken($color_schema_1, 10%);
|
||||
$color_schema_2_dark: darken($color_schema_2, 10%);
|
||||
$color_schema_3_dark: darken($color_schema_3, 10%);
|
||||
$color_schema_4_dark: darken($color_schema_4, 10%);
|
||||
$color_schema_5_dark: darken($color_schema_5, 10%);
|
||||
|
||||
|
||||
$color_prim: #7070a0;
|
||||
$color_prim_light: lighten($color_prim ,10%);
|
||||
$color_prim_vlight: lighten($color_prim ,30%);
|
||||
|
||||
@@ -12,20 +12,35 @@
|
||||
*= require_self
|
||||
* require_tree .
|
||||
*= require jquery.fileupload-ui
|
||||
*= require jquery.datetimepicker
|
||||
* require 'bootstrap'
|
||||
|
||||
* require 'neuigkeiten'
|
||||
*/
|
||||
// Colorshema #0A64A4
|
||||
$color_prim: #071672;
|
||||
|
||||
$color_schema_1: #006599;
|
||||
$color_schema_2: #630CE8;
|
||||
$color_schema_3: #FF0021;
|
||||
$color_schema_4: #E8820C;
|
||||
$color_schema_5: #FFF30D;
|
||||
|
||||
$color_schema_1_dark: darken($color_schema_1, 10%);
|
||||
$color_schema_2_dark: darken($color_schema_2, 10%);
|
||||
$color_schema_3_dark: darken($color_schema_3, 10%);
|
||||
$color_schema_4_dark: darken($color_schema_4, 10%);
|
||||
$color_schema_5_dark: darken($color_schema_5, 10%);
|
||||
|
||||
$color_prim: $color_schema_1_dark; // #006599; //071672;
|
||||
|
||||
$color_prim_light: lighten($color_prim ,10%);
|
||||
$color_prim_vlight: lighten($color_prim ,30%);
|
||||
$color_prim_dark: darken($color_prim ,10%);
|
||||
$color_prim_vdark: darken($color_prim ,30%);
|
||||
|
||||
$color_cont: FFDB73;
|
||||
$color_cont_light:FFDB73;
|
||||
$color_cont: $color_schema_3;
|
||||
$color_cont_light:lighten($color_cont ,10%);
|
||||
$linkColor: $color_prim;
|
||||
$linkColorHover: $color_schema_1;
|
||||
$white: #FFFFFF;
|
||||
|
||||
$bodyBackground: #EEE;
|
||||
@@ -36,7 +51,7 @@ $bodyBackground: #EEE;
|
||||
$navbarBackground: #EEE;//$color_prim;
|
||||
$navbarText: $color_prim;
|
||||
$navbarLinkColor: $color_prim;
|
||||
$navbarLinkColorHover: $color_prim_dark;
|
||||
$navbarLinkColorHover: $color_schema_1;
|
||||
$dropdownLinkColor: black;
|
||||
$navbar-default-brand-color: black;
|
||||
$navbarBrandColor:black;
|
||||
@@ -45,7 +60,7 @@ $navbarBrandColor:black;
|
||||
$navbarBackgroundHighlight: #EEE;
|
||||
//$navbarBackgroundHighlight:#FFFFFF;
|
||||
|
||||
$navbarLinkBackgroundHover:#FFBE00;
|
||||
|
||||
$navbarLinkBackgroundHover: darken($navbarBackground,10%);
|
||||
|
||||
|
||||
@@ -58,28 +73,26 @@ $sansFontFamily: Helvetica, Arial;
|
||||
@import 'bootstrap/image-gallery';
|
||||
@import 'font-awesome';
|
||||
@import 'neuigkeiten';
|
||||
|
||||
@import 'themengruppen';
|
||||
|
||||
div.header {
|
||||
display: block;
|
||||
// background: url('../../../../header1.png') no-repeat;
|
||||
// background-color:white;// $color_prim;
|
||||
// background-position: right;
|
||||
|
||||
vertical-align:middle;
|
||||
float:left;
|
||||
color:#000;
|
||||
padding-left:87px;
|
||||
padding-top:0px;
|
||||
|
||||
overflow:visible;
|
||||
height:45px;
|
||||
height:45px;
|
||||
margin-bottom: 0 px
|
||||
}
|
||||
div.header h1 {
|
||||
padding:0;
|
||||
margin:4px;
|
||||
font-size:20px;
|
||||
line-height:32px;
|
||||
margin:4px;
|
||||
font-size:20px;
|
||||
line-height:32px;
|
||||
}
|
||||
div.header img {
|
||||
//top:2px;
|
||||
@@ -90,7 +103,8 @@ border-bottom: $color_prim solid 3px;
|
||||
}
|
||||
div.headerrow {
|
||||
}
|
||||
$contentdiv-background:none;
|
||||
|
||||
$contentdiv-background:none;
|
||||
$navbar-li-minwidth: 0;
|
||||
|
||||
|
||||
@@ -98,5 +112,6 @@ $navbar-li-minwidth: 0;
|
||||
$box-border: lightgray solid 1px;
|
||||
$box-border-radius:0px;
|
||||
$box-background: white;
|
||||
|
||||
@import 'layout';
|
||||
@import 'calendars';
|
||||
@@ -16,6 +16,18 @@
|
||||
|
||||
* require 'neuigkeiten'
|
||||
*/
|
||||
$color_schema_1: #006599;
|
||||
$color_schema_2: #630CE8;
|
||||
$color_schema_3: #FF0021;
|
||||
$color_schema_4: #E8820C;
|
||||
$color_schema_5: #FFF30D;
|
||||
|
||||
$color_schema_1_dark: darken($color_schema_1, 10%);
|
||||
$color_schema_2_dark: darken($color_schema_2, 10%);
|
||||
$color_schema_3_dark: darken($color_schema_3, 10%);
|
||||
$color_schema_4_dark: darken($color_schema_4, 10%);
|
||||
$color_schema_5_dark: darken($color_schema_5, 10%);
|
||||
|
||||
// Colorshema #0A64A4
|
||||
$color_prim: #071672;
|
||||
$color_prim_light: lighten($color_prim ,10%);
|
||||
@@ -77,7 +89,7 @@ $sansFontFamily: cmunrm, Helvetica, Arial;
|
||||
@import 'neuigkeiten';
|
||||
@import 'fetlogo';
|
||||
#menudiv {
|
||||
font-family: ayuma2yk;
|
||||
|
||||
}
|
||||
|
||||
div.header {
|
||||
|
||||
@@ -17,6 +17,20 @@
|
||||
* require 'neuigkeiten'
|
||||
*/
|
||||
|
||||
|
||||
$color_schema_1: #006599;
|
||||
$color_schema_2: #630CE8;
|
||||
$color_schema_3: #FF0021;
|
||||
$color_schema_4: #E8820C;
|
||||
$color_schema_5: #FFF30D;
|
||||
|
||||
$color_schema_1_dark: darken($color_schema_1, 30%);
|
||||
$color_schema_2_dark: darken($color_schema_2, 30%);
|
||||
$color_schema_3_dark: darken($color_schema_3, 30%);
|
||||
$color_schema_4_dark: darken($color_schema_4, 30%);
|
||||
$color_schema_5_dark: darken($color_schema_5, 30%);
|
||||
|
||||
|
||||
$color_prim: #0A64A4;
|
||||
$color_prim_light: #0B65A5;
|
||||
$color_prim_vlight: #2B85C5;
|
||||
@@ -74,3 +88,4 @@ $box-border-radius:8px;
|
||||
$box-background: white;
|
||||
@import 'layout';
|
||||
@import 'calendars';
|
||||
@import 'tinymce';
|
||||
19
app/assets/stylesheets/tinymce.css.scss
Normal file
19
app/assets/stylesheets/tinymce.css.scss
Normal file
@@ -0,0 +1,19 @@
|
||||
i.mce-i-fa {
|
||||
font: 400 17px/1 FontAwesome;
|
||||
padding: 0;
|
||||
vertical-align: middle;
|
||||
speak: none;
|
||||
-webkit-font-smoothing: antialiased;
|
||||
-moz-osx-font-smoothing: grayscale;
|
||||
margin-left: -2px;
|
||||
padding-right: 2px
|
||||
}
|
||||
i.fa-red { color:red; }
|
||||
|
||||
.mc-important {
|
||||
color: red;
|
||||
font-weight:bold;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
@import 'flatfeticon1'
|
||||
@@ -18,7 +18,7 @@ def get_theme
|
||||
params[:theme]
|
||||
|
||||
else
|
||||
"2003"
|
||||
"blue1"
|
||||
end
|
||||
end
|
||||
def default_url_options
|
||||
|
||||
@@ -46,19 +46,29 @@ class AttachmentsController < ApplicationController
|
||||
# POST /attachments.json
|
||||
def create
|
||||
@attachment = Attachment.new(params[:attachment])
|
||||
@thema = Thema.find(params[:thema_id])
|
||||
@attachment.thema_id = @thema.id
|
||||
@thema = Thema.find_by_id(params[:thema_id])
|
||||
# logger.info "gg"
|
||||
@attachment.thema = @thema
|
||||
@attachment.name=@attachment.datei.filename
|
||||
@action="create"
|
||||
logger.info "#{@attachment.inspect}"
|
||||
|
||||
|
||||
# logger.info "sdf"
|
||||
respond_to do |format|
|
||||
if @attachment.save
|
||||
format.html { redirect_to @thema, notice: 'Attachment was successfully created.' }
|
||||
format.json { render json: @thema, status: :created, location: @thema }
|
||||
format.js { }
|
||||
format.html {
|
||||
render :json => [@attachment.to_jq_upload].to_json,
|
||||
:content_type => 'text/html',
|
||||
:layout => false
|
||||
}
|
||||
|
||||
# format.html { redirect_to @thema, notice: 'Attachment was successfully created.' }
|
||||
format.json { render json: {files: [@attachment.to_jq_upload]}, status: :created, location: [@thema, @attachment]}
|
||||
|
||||
else
|
||||
format.html { render action: "new" }
|
||||
format.json { render json: @attachment.errors, status: :unprocessable_entity }
|
||||
format.js { render action: "new.js.erb"}
|
||||
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
class BeispieleController < ApplicationController
|
||||
# GET /beispiele
|
||||
# GET /beispiele.json
|
||||
|
||||
load_and_authorize_resource
|
||||
include LikeVoteable
|
||||
def index
|
||||
@beispiele = Beispiel.all
|
||||
|
||||
@@ -99,4 +100,4 @@ class BeispieleController < ApplicationController
|
||||
format.json { head :no_content }
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
@@ -7,14 +7,19 @@ class FetprofilesController < ApplicationController
|
||||
|
||||
@fetprofiles = Fetprofile.active.order(:vorname,:nachname)
|
||||
@fetprofiles = Fetprofile.order(:vorname,:nachname) if params[:filter]== "all"
|
||||
@fetprofiles = Fetprofile.where(:active=>false).order(:vorname,:nachname) if params[:filter]== "notactive"
|
||||
@fetprofiles = Fetprofile.where(:active=>false).order(:nachname,:vorname) if params[:filter]== "notactive"
|
||||
|
||||
@gremientabs = Gremium.tabs
|
||||
@toolbar_elements << {:hicon=>'icon-plus', :text=> I18n.t('profile.new_profile'),:path => new_fetprofile_path(@fetprofile) } if can? :new, @fetprofile
|
||||
|
||||
respond_to do |format|
|
||||
format.html # index.html.erb
|
||||
format.json { render json: @fetprofiles }
|
||||
end
|
||||
end
|
||||
def internlist
|
||||
@fetprofiles = Fetprofile.order(:vorname,:nachname)
|
||||
end
|
||||
|
||||
|
||||
# GET /fetprofiles/1
|
||||
# GET /fetprofiles/1.json
|
||||
@@ -84,7 +89,18 @@ class FetprofilesController < ApplicationController
|
||||
|
||||
respond_to do |format|
|
||||
if @fetprofile.update_attributes(params[:fetprofile])
|
||||
format.html { redirect_to @fetprofile, notice: 'Fetprofile was successfully updated.' }
|
||||
format.html {
|
||||
unless params[:button]=="continue" || params[:commit]=="continue"
|
||||
|
||||
redirect_to @fetprofile, notice: 'profile was successfully updated.'
|
||||
else
|
||||
@memberships=@fetprofile.memberships.order(:typ)
|
||||
@memberships<< Membership.new
|
||||
@memberships<< Membership.new
|
||||
@memberships<< Membership.new
|
||||
render action: "edit", notice: 'profile was successfully updated.'
|
||||
end
|
||||
}
|
||||
format.json { head :no_content }
|
||||
else
|
||||
@memberships=@fetprofile.memberships.order(:typ)
|
||||
|
||||
@@ -6,7 +6,7 @@ class GalleriesController < ApplicationController
|
||||
# GET /galleries.json
|
||||
def index
|
||||
@galleries = Gallery.all
|
||||
@toolbar_elements << {:hicon => 'icon-plus', :text => I18n.t('fotos.new-gallery'), :path => new_gallery_path }
|
||||
@toolbar_elements << {:hicon => 'icon-plus', :text => I18n.t('fotos.new-gallery'), :path => new_gallery_path } if can? :new, Gallery
|
||||
|
||||
respond_to do |format|
|
||||
format.html # index.html.erb
|
||||
|
||||
@@ -7,6 +7,8 @@ class GremienController < ApplicationController
|
||||
@gremien = Gremium.all
|
||||
@gremientabs=Gremium.tabs
|
||||
@toolbar_elements << {:text=>I18n.t('gremium.new'),:path=>new_gremium_path() ,:icon=>:plus} if can? :new, Gremium
|
||||
@toolbar_elements << {:text=>I18n.t('profile.new'),:path=>new_fetprofile_path() ,:icon=>:plus} if can? :new, Fetprofile
|
||||
|
||||
respond_to do |format|
|
||||
format.html # index.html.erb
|
||||
format.json { render json: @gremien }
|
||||
@@ -83,7 +85,17 @@ class GremienController < ApplicationController
|
||||
|
||||
respond_to do |format|
|
||||
if @gremium.update_attributes(params[:gremium])
|
||||
format.html { redirect_to @gremium, notice: 'Gremium was successfully updated.' }
|
||||
format.html {
|
||||
unless params[:button]=="continue" || params[:commit]=="continue"
|
||||
redirect_to @gremium, notice: 'Gremium was successfully updated.'
|
||||
else
|
||||
@memberships=@gremium.memberships.order(:typ)
|
||||
@memberships<< Membership.new
|
||||
@memberships<< Membership.new
|
||||
@memberships<< Membership.new
|
||||
render action: "edit", notice: 'gremium was successfully updated.'
|
||||
end
|
||||
}
|
||||
format.json { head :no_content }
|
||||
else
|
||||
format.html { render action: "edit" }
|
||||
@@ -93,7 +105,8 @@ class GremienController < ApplicationController
|
||||
end
|
||||
|
||||
# DELETE /gremien/1
|
||||
# DELETE /gremien/1.json
|
||||
#
|
||||
#
|
||||
def destroy
|
||||
@gremium = Gremium.find(params[:id])
|
||||
@gremium.destroy
|
||||
|
||||
@@ -12,7 +12,14 @@ class HomeController < ApplicationController
|
||||
def intern
|
||||
authorize! :seeintern, User
|
||||
@neuigkeiten = Neuigkeit.intern.recent
|
||||
@themengruppen=Themengruppe.intern.order(:priority).reverse
|
||||
end
|
||||
def admin
|
||||
authorize! :doadmin, User
|
||||
|
||||
|
||||
end
|
||||
|
||||
def startdev
|
||||
render 'setup_fetsite_dev'
|
||||
end
|
||||
@@ -20,10 +27,20 @@ class HomeController < ApplicationController
|
||||
render 'links_notimplemented'
|
||||
end
|
||||
def search
|
||||
|
||||
unless params['query'].nil? || params['query'].empty?
|
||||
if can?(:showintern, Neuigkeit)
|
||||
@neuigkeiten=Neuigkeit.search(params['query'])
|
||||
else
|
||||
@neuigkeiten =Neuigkeit.search(params['query']).public
|
||||
end
|
||||
@fetprofiles = Fetprofile.search(params['query'])
|
||||
if can?(:showintern, Neuigkeit)
|
||||
@themen=Thema.search(params['query'])
|
||||
else
|
||||
@themen=Thema.search(params['query']).public
|
||||
end
|
||||
|
||||
else
|
||||
@neuigkeiten=[]
|
||||
@fetprofiles=[]
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
class LvasController < ApplicationController
|
||||
# GET /lvas
|
||||
require 'zip'
|
||||
before_filter :load_toolbar, :only => [:show]
|
||||
load_and_authorize_resource
|
||||
def index
|
||||
@@ -9,7 +10,34 @@ class LvasController < ApplicationController
|
||||
{:hicon=>'icon-list', :text=>I18n.t("modul.list"),:path=>moduls_path},
|
||||
{:hicon=>'icon-list', :text=>I18n.t("lva.list"),:path=>lvas_path}]
|
||||
end
|
||||
def beispiel_sammlung
|
||||
@lva = Lva.find_by_id(params[:id])
|
||||
#Attachment name
|
||||
filename = 'beispiel_sammlung_' + @lva.lvanr.to_s + '_' + l(Date.today).to_s + '.zip'
|
||||
temp_file = Tempfile.new(filename)
|
||||
begin
|
||||
#This is the tricky part
|
||||
#Initialize the temp file as a zip file
|
||||
Zip::OutputStream.open(temp_file) { |zos| }
|
||||
#Add files to the zip file as usual
|
||||
Zip::File.open(temp_file.path, Zip::File::CREATE) do |zip|
|
||||
#Put files in here
|
||||
i=1
|
||||
@lva.beispiele.each do |bsp|
|
||||
zip.add(i.to_s + '_' + File.basename(bsp.beispieldatei.current_path), bsp.beispieldatei.current_path)
|
||||
i = i + 1
|
||||
end
|
||||
|
||||
end
|
||||
#Read the binary data from the file
|
||||
zip_data = File.read(temp_file.path)
|
||||
send_data(zip_data, :type => 'application/zip', :filename => filename)
|
||||
ensure
|
||||
#Close and delete the temp file
|
||||
temp_file.close
|
||||
temp_file.unlink
|
||||
end
|
||||
end
|
||||
# GET /lvas/1
|
||||
|
||||
def show
|
||||
@@ -89,7 +117,7 @@ private
|
||||
@toolbar_elements =[]
|
||||
@toolbar_elements<<{:hicon=>'icon-pencil', :icon=>:pencil,:text =>I18n.t('common.edit'),:path => edit_lva_path(@lva)} if can? :edit, @lva
|
||||
@toolbar_elements << {:hicon=>'icon-remove-circle', :text=>"Tissvergleichladen", :path=> compare_tiss_lva_path(@lva)} if can? :compare_tiss, @lva
|
||||
@toolbar_elements << {:hicon=>'icon-remove-circle', :text=>I18n.t('common.delete'), :path=> lva_path(@lva), :method=>:delete, :confirm=>'Sure?' } if can? :delete, @lva
|
||||
@toolbar_elements << {:hicon=>'icon-remove-circle', :text=>I18n.t('lva.delete'), :path=> lva_path(@lva), :method=>:delete, :confirm=>t('lva.deletesure') } if can? :delete, @lva
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
class NeuigkeitenController < ApplicationController
|
||||
before_filter :load_toolbar_elements, :only=>[:show,:find_link]
|
||||
before_filter :load_toolbar_elements_edit, :only=>[:edit]
|
||||
@@ -35,7 +36,7 @@ class NeuigkeitenController < ApplicationController
|
||||
if params[:calentry_id].nil?
|
||||
ce = Calentry.new(:start=>Time.now, :ende=>1.hour.from_now, :typ=>1, :calendar=>@neuigkeit.rubrik.calendar)
|
||||
else
|
||||
ce=Calentry.find(params[:calentry_id])
|
||||
ce = Calentry.find(params[:calentry_id])
|
||||
end
|
||||
@calentry=ce
|
||||
ce.object=@neuigkeit
|
||||
@@ -63,7 +64,28 @@ class NeuigkeitenController < ApplicationController
|
||||
end
|
||||
redirect_to rubrik_neuigkeit_path(@neuigkeit.rubrik,@neuigkeit)
|
||||
end
|
||||
def publish_to_facebook
|
||||
@neuigkeit = Neuigkeit.find(params[:id])
|
||||
unless @neuigkeit.published?
|
||||
redirect_to [@neuigkeit.rubrik,@neuigkeit], notice: 'Neuigkeit muss veröffentlicht sein um sie auf Facebook zu posten.'
|
||||
else
|
||||
page=YAML.load_file("#{::Rails.root.to_s}/tmp/page.yml")
|
||||
page.feed!(:access_token=>page.access_token, :message=>@neuigkeit.text_first_words, :name=>@neuigkeit.title, :link=>rubrik_neuigkeit_url(@neuigkeit.rubrik, @neuigkeit)+".html", :picture=>@neuigkeit.picture.url)
|
||||
|
||||
redirect_to [@neuigkeit.rubrik,@neuigkeit], notice: 'Neuigkeit auf Facebook gepostet'
|
||||
end
|
||||
end
|
||||
def mail_to_fet
|
||||
@neuigkeit = Neuigkeit.find(params[:id])
|
||||
authorize! :publish, @neuigkeit
|
||||
unless @neuigkeit.published?
|
||||
redirect_to [@neuigkeit.rubrik,@neuigkeit], notice: 'Neuigkeit muss veröffentlicht sein um sie als Mail zu versenden.'
|
||||
else
|
||||
NewsMailer.neuigkeit_mail(current_user.email, params[:id]).deliver
|
||||
redirect_to [@neuigkeit.rubrik,@neuigkeit], notice: 'Neuigkeit versendet'
|
||||
|
||||
end
|
||||
end
|
||||
def edit
|
||||
@neuigkeit = Neuigkeit.find(params[:id])
|
||||
|
||||
@@ -137,8 +159,14 @@ private
|
||||
def load_toolbar_elements
|
||||
@neuigkeit=Neuigkeit.find(params[:id])
|
||||
@toolbar_elements=[]
|
||||
@toolbar_elements << {:hicon=>'icon-plus', :text=> I18n.t('neuigkeit.publish'),:path => publish_rubrik_neuigkeit_path(@neuigkeit.rubrik,@neuigkeit),:confirm=>'Sure?' } if can?(:publish, @neuigkeit) && @neuigkeit.published?
|
||||
@toolbar_elements << {:hicon=>'icon-minus', :text=> I18n.t('neuigkeit.unpublish'),:path => unpublish_rubrik_neuigkeit_path(@neuigkeit.rubrik,@neuigkeit),:confirm=>'Sure?' } if can?(:unpublish, @neuigkeit) && !@neuigkeit.published?
|
||||
@toolbar_elements << {:hicon=>'icon-plus', :text=> I18n.t('neuigkeit.publish'),:path => publish_rubrik_neuigkeit_path(@neuigkeit.rubrik,@neuigkeit),:confirm=> I18n.t('neuigkeit.publish_sure') } if can?(:publish, @neuigkeit) && !@neuigkeit.published?
|
||||
@toolbar_elements << {:hicon=>'icon-facebook', :text=> I18n.t('neuigkeit.publishfb'),:path => publish_to_facebook_rubrik_neuigkeit_path(@neuigkeit.rubrik,@neuigkeit),:confirm=>I18n.t('neuigkeit.publishfb_sure') } if can?(:publish, @neuigkeit) && @neuigkeit.published?
|
||||
|
||||
@toolbar_elements << {:hicon=>'icon-facebook', :text=> I18n.t('neuigkeit.publishfetmail'),:path => mail_to_fet_rubrik_neuigkeit_path(@neuigkeit.rubrik,@neuigkeit),:confirm=>I18n.t('neuigkeit.publishfetmail_sure') } if can?(:publish, @neuigkeit) && @neuigkeit.published?
|
||||
|
||||
@toolbar_elements << {:hicon=>'icon-minus', :text=> I18n.t('neuigkeit.unpublish'),:path => unpublish_rubrik_neuigkeit_path(@neuigkeit.rubrik,@neuigkeit),:confirm=> I18n.t('neuigkeit.unpublish_sure') } if can?(:unpublish, @neuigkeit) && @neuigkeit.published?
|
||||
|
||||
|
||||
@toolbar_elements << {:text=>I18n.t('common.edit'),:path=>edit_rubrik_neuigkeit_path(@neuigkeit.rubrik,@neuigkeit),:icon=>:pencil} if can? :edit, @neuigkeit.rubrik
|
||||
@versions= @neuigkeit.translation.versions.select([:created_at]).reverse
|
||||
|
||||
|
||||
@@ -2,13 +2,15 @@ class RubrikenController < ApplicationController
|
||||
before_filter {@toolbar_elements=[]}
|
||||
load_and_authorize_resource
|
||||
def index
|
||||
if can?(:shownonpublic, Rubrik)
|
||||
if can?(:showintern, Rubrik)
|
||||
@rubriken = Rubrik.all
|
||||
@neuigkeiten = Neuigkeit.recent
|
||||
else
|
||||
@rubriken = Rubrik.where(:public=>true)
|
||||
@neuigkeiten = Neuigkeit.public.recent
|
||||
end
|
||||
@neuigkeiten = @rubriken.collect(&:neuigkeiten).map(&:recent).flatten
|
||||
@calentries= @rubriken.collect(&:calendar).collect(&:calentries).flatten
|
||||
|
||||
@calentries= @rubriken.collect(&:calentries).flatten
|
||||
end
|
||||
def intern
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@ class StudienController < ApplicationController
|
||||
@topbar_elements=[{:hicon=>'icon-list', :text=>I18n.t("studien.allestudien"),:path=>studien_path}]
|
||||
@topbar_elements<<{:hicon=>'icon-list', :text=>I18n.t("modul.list"),:path=>moduls_path}
|
||||
@topbar_elements<<{:hicon=>'icon-list', :text=>I18n.t("lva.list"),:path=>lvas_path}
|
||||
@toolbar_elements<<{:icon =>:plus, :hicon=>'icon-plus-sign', :text=> I18n.t('studien.new') ,:path=>new_studium_path }
|
||||
@toolbar_elements<<{:icon =>:plus, :hicon=>'icon-plus-sign', :text=> I18n.t('studien.new') ,:path=>new_studium_path } if can? :new, Studium
|
||||
# @toolbar_elements<<{:text=> I18n.t('modulgruppe.show.link') ,:path=>modulgruppen_path }
|
||||
end
|
||||
|
||||
@@ -31,14 +31,14 @@ class StudienController < ApplicationController
|
||||
end
|
||||
@studienphasen << {:modulgruppen=>modulgruppen, :phase => ph}.merge(opts)
|
||||
end
|
||||
|
||||
@toolbar_elements=[{:icon=>:plus, :hicon =>'icon-plus-sign' ,:text=> I18n.t('studien.new') , :path => new_studium_path(@studium) },
|
||||
{:icon=>:pencil, :hicon=>'icon-pencil',:text =>I18n.t('common.edit'),:path => edit_studium_path(@studium)},
|
||||
{:icon=>:pencil, :hicon=>'icon-pencil',:text =>I18n.t('common.edit'),:path => edit_lvas_studium_path(@studium)},
|
||||
{:hicon=>'icon-remove-circle', :text=> I18n.t('common.delete'),:path => studium_path(@studium), :method=> :delete,:confirm=>'Sure?' }]
|
||||
|
||||
@toolbar_modulgruppen =[ {:hicon=>'icon-plus-sign', :text=> I18n.t('modulgruppe.new'), :path=>new_studium_modulgruppe_path(@studium)},
|
||||
{:hicon=>'icon-list', :text => I18n.t('modulgruppe.list'), :path=>modulgruppen_path}]
|
||||
@toolbar_elements=[]
|
||||
@toolbar_elements<<{:icon=>:plus, :hicon =>'icon-plus-sign' ,:text=> I18n.t('studien.new') , :path => new_studium_path(@studium) } if can? :new, Studium
|
||||
@toolbar_elements<<{:icon=>:pencil, :hicon=>'icon-pencil',:text =>I18n.t('common.edit'),:path => edit_studium_path(@studium)} if can? :edit, Studium
|
||||
@toolbar_elements<<{:icon=>:pencil, :hicon=>'icon-pencil',:text =>I18n.t('lva.editlvas'),:path => edit_lvas_studium_path(@studium)} if can? :edit_lvas, Studium
|
||||
@toolbar_elements<<{:hicon=>'icon-remove-circle', :text=> I18n.t('common.delete'),:path => studium_path(@studium), :method=> :delete,:confirm=>'Sure?' } if can? :delete, Studium
|
||||
@toolbar_modulgruppen =[]
|
||||
@toolbar_modulgruppen << {:hicon=>'icon-plus-sign', :text=> I18n.t('modulgruppe.new'), :path=>new_studium_modulgruppe_path(@studium)} if can? :new, Modulgruppe
|
||||
@toolbar_modulgruppen << {:hicon=>'icon-list', :text => I18n.t('modulgruppe.list'), :path=>modulgruppen_path} if can? :index, Modulgruppe
|
||||
case params[:ansicht]
|
||||
when 'semesteransicht'
|
||||
when 'infoansicht'
|
||||
@@ -60,7 +60,7 @@ class StudienController < ApplicationController
|
||||
|
||||
def edit_lvas
|
||||
@studium = Studium.find(params[:id])
|
||||
@lvas=@studium.lvas
|
||||
@lvas=@studium.lvas.uniq
|
||||
@semester=@studium.semester
|
||||
@toolbar_elements=[{:text => I18n.t('studien.anzeigen') , :path => url_for(@studium) }]
|
||||
@toolbar_elements<<{:text =>I18n.t('studien.allestudien'),:path=>studien_path(@studium)}
|
||||
|
||||
@@ -3,24 +3,12 @@ class ThemenController < ApplicationController
|
||||
# GET /themen.json
|
||||
load_and_authorize_resource
|
||||
|
||||
def index
|
||||
@themen = Thema.all
|
||||
|
||||
respond_to do |format|
|
||||
format.html # index.html.erb
|
||||
format.json { render json: @themen }
|
||||
end
|
||||
end
|
||||
|
||||
# GET /themen/1
|
||||
# GET /themen/1.json
|
||||
def show
|
||||
@thema = Thema.find(params[:id])
|
||||
|
||||
@fragen=@thema.fragen
|
||||
@toolbar_elements = [{:icon=>:pencil, :hicon=>'icon-pencil', :text=>"Verwalten", :path=>verwalten_thema_path(@thema)}]
|
||||
|
||||
@toolbar_elements = [{:icon=>:pencil, :hicon=>'icon-pencil', :text=>I18n.t('thema.edit'), :path=>edit_thema_path(@thema)}]
|
||||
@toolbar_elements = [{:icon=>:pencil, :hicon=>'icon-pencil', :text=>I18n.t("thema.manage"), :path=>verwalten_thema_path(@thema)}]
|
||||
@toolbar_elements << [{:icon=>:pencil, :hicon=>'icon-pencil', :text=>I18n.t('thema.edit'), :path=>edit_thema_path(@thema)}]
|
||||
@toolbar_elements << {:hicon=>'icon-remove-circle', :text=>I18n.t('thema.remove'), :path=>thema_path(@thema), :method=>:delete, :confirm=>I18n.t('thema.sure')}
|
||||
|
||||
respond_to do |format|
|
||||
@@ -32,8 +20,8 @@ class ThemenController < ApplicationController
|
||||
end
|
||||
def verwalten
|
||||
@thema = Thema.find(params[:id])
|
||||
@attachment=Attachment.new
|
||||
@fragen=@thema.fragen
|
||||
@toolbar_elements = [{:icon=>:pencil, :hicon=>'icon-pencil', :text=>"Verwalten", :path=>verwalten_thema_path(@thema)}]
|
||||
|
||||
@toolbar_elements = [{:icon=>:pencil, :hicon=>'icon-pencil', :text=>I18n.t('thema.edit'), :path=>edit_thema_path(@thema)}]
|
||||
@toolbar_elements << {:hicon=>'icon-remove-circle', :text=>I18n.t('thema.remove'), :path=>thema_path(@thema), :method=>:delete, :confirm=>I18n.t('thema.sure')}
|
||||
@@ -54,9 +42,14 @@ class ThemenController < ApplicationController
|
||||
# GET /themen/1/edit
|
||||
def edit
|
||||
@thema = Thema.find(params[:id])
|
||||
|
||||
if @thema.is_wiki?
|
||||
redirect_to edit_wiki_path(Wiki.find(@thema.id))
|
||||
return
|
||||
end
|
||||
respond_to do |format|
|
||||
format.html
|
||||
format.js
|
||||
format.js { @themen= @thema.themengruppe.themen }
|
||||
end
|
||||
end
|
||||
|
||||
@@ -64,14 +57,16 @@ class ThemenController < ApplicationController
|
||||
# POST /themen.json
|
||||
def create
|
||||
@thema = Thema.new(params[:thema])
|
||||
|
||||
@themen = @thema.themengruppe.themen.order(:priority).reverse
|
||||
|
||||
respond_to do |format|
|
||||
if @thema.save
|
||||
format.html { redirect_to @thema, notice: 'Thema was successfully created.' }
|
||||
@themen = @thema.themengruppe.themen.order(:priority).reverse
|
||||
format.html { redirect_to @thema, notice: I18n.t("thema.created") }
|
||||
format.json { render json: @thema, status: :created, location: @thema }
|
||||
format.js {render action: "update"}
|
||||
else
|
||||
@themen = @thema.themengruppe.themen.order(:priority).reverse
|
||||
format.html { render action: "new" }
|
||||
format.json { render json: @thema.errors, status: :unprocessable_entity }
|
||||
format.js { render action: "edit" }
|
||||
@@ -88,6 +83,7 @@ class ThemenController < ApplicationController
|
||||
def attachments
|
||||
@thema = Thema.find(params[:id])
|
||||
@attachments=@thema.attachments
|
||||
@attachment=Attachment.new
|
||||
respond_to do |format|
|
||||
format.js
|
||||
end
|
||||
@@ -97,9 +93,18 @@ class ThemenController < ApplicationController
|
||||
def update
|
||||
@thema = Thema.find(params[:id])
|
||||
@themen = @thema.themengruppe.themen.order(:priority).reverse
|
||||
@thema.assign_attributes(params[:thema])
|
||||
@thema.fix_links(request.host_with_port)
|
||||
|
||||
respond_to do |format|
|
||||
if @thema.update_attributes(params[:thema])
|
||||
format.html { redirect_to @thema, notice: 'Thema was successfully updated.' }
|
||||
if @thema.save
|
||||
format.html {
|
||||
if params["button"]=="continue"
|
||||
render action: "edit", notice: I18n.t("thema.updated")
|
||||
else
|
||||
redirect_to @thema, notice: I18n.t("thema.updated")
|
||||
end
|
||||
}
|
||||
format.json { head :no_content }
|
||||
format.js
|
||||
else
|
||||
@@ -115,7 +120,7 @@ class ThemenController < ApplicationController
|
||||
def destroy
|
||||
@thema = Thema.find(params[:id])
|
||||
@thema.destroy
|
||||
|
||||
@themen = @thema.themengruppe.themen.order(:priority).reverse
|
||||
respond_to do |format|
|
||||
format.html { redirect_to themengruppe_path(@thema.themengruppe) }
|
||||
format.json { head :no_content }
|
||||
|
||||
@@ -3,9 +3,10 @@ class ThemengruppenController < ApplicationController
|
||||
# GET /themengruppen.json
|
||||
load_and_authorize_resource
|
||||
def index
|
||||
@themengruppen = Themengruppe.order(:priority).reverse
|
||||
@toolbar_elements = [{:icon=>:plus, :hicon=>'icon-plus-sign', :text=>I18n.t('themengruppe.new'), :path=>new_themengruppe_path()}]
|
||||
@toolbar_elements = [{:icon=>:plus, :hicon=>'icon-plus-sign', :text=>I18n.t('common.verwalten'), :path=>verwalten_all_themengruppen_path()}]
|
||||
@themengruppen = Themengruppe.where(:public=>true).order(:priority).reverse
|
||||
@toolbar_elements = []
|
||||
@toolbar_elements << {:icon=>:plus, :hicon=>'icon-plus-sign', :text=>I18n.t('themengruppe.new'), :path=>new_themengruppe_path()} if can? :new, Themengruppe
|
||||
@toolbar_elements << {:icon=>:plus, :hicon=>'icon-plus-sign', :text=>I18n.t('themengruppe.manage_all'), :path=>verwalten_all_themengruppen_path()} if can? :verwalten_all, Themengruppe
|
||||
|
||||
respond_to do |format|
|
||||
format.html # index.html.erb
|
||||
@@ -21,13 +22,13 @@ class ThemengruppenController < ApplicationController
|
||||
# GET /themengruppen/1.json
|
||||
def show
|
||||
@themengruppe = Themengruppe.find(params[:id])
|
||||
if can? :showdraft , Thema
|
||||
@themen = @themengruppe.themen.order(:priority).reverse
|
||||
|
||||
else
|
||||
@themen = @themengruppe.themen.where(:isdraft=>false).order(:priority).reverse
|
||||
end
|
||||
@toolbar_elements = []
|
||||
@toolbar_elements << {:icon=>:plus, :hicon=>'icon-plus-sign', :text=>I18n.t('thema.add'), :path=>new_themengruppe_thema_path(@themengruppe)} if can? :new, Themengruppe
|
||||
@toolbar_elements << {:icon=>:pencil, :hicon=>'icon-pencil', :text=>I18n.t('themengruppe.edit'), :path=>edit_themengruppe_path(@themengruppe)} if can? :edit, @themengruppe
|
||||
@toolbar_elements << {:icon=>:pencil, :hicon=>'icon-pencil', :text=>I18n.t("themengruppe.manage"), :path=>themengruppe_verwalten_path(@themengruppe)} if can? :edit, @themengruppe
|
||||
@toolbar_elements << {:hicon=>'icon-remove-circle',:text=>I18n.t('themengruppe.remove'), :path=>themengruppe_path(@themengruppe), :method=>:delete,:confirm=>I18n.t('themengruppe.sure')} if can? :delete, @themengruppe
|
||||
|
||||
respond_to do |format|
|
||||
format.html # show.html.erb
|
||||
@@ -51,11 +52,20 @@ class ThemengruppenController < ApplicationController
|
||||
@themengruppe = Themengruppe.find(params[:id])
|
||||
end
|
||||
def verwalten_all
|
||||
@themengruppen =Themengruppe.order(:priority).reverse
|
||||
@themengruppen =Themengruppe.public.order(:priority).reverse
|
||||
@themengruppen_intern =Themengruppe.intern.order(:priority).reverse
|
||||
@toolbar_elements = [{:icon=>:plus, :hicon=>'icon-plus-sign', :text=>I18n.t('themengruppe.new'), :path=>new_themengruppe_path()}]
|
||||
|
||||
end
|
||||
def verwalten
|
||||
@themengruppe = Themengruppe.find(params[:themengruppe_id])
|
||||
@themen = @themengruppe.themen.order(:priority).reverse
|
||||
|
||||
@toolbar_elements =[]
|
||||
@toolbar_elements << {:icon=>:pencil, :hicon=>'icon-pencil', :text=>I18n.t('themengruppe.edit'), :path=>edit_themengruppe_path(@themengruppe)} if can? :edit, @themengruppe
|
||||
@toolbar_elements << {:icon=>:plus, :hicon=>'icon-plus-sign', :text=>I18n.t('thema.add'), :path=>new_themengruppe_thema_path(@themengruppe)} if can? :new, Themengruppe
|
||||
@toolbar_elements << {:hicon=>'icon-remove-circle',:text=>I18n.t('themengruppe.remove'), :path=>themengruppe_path(@themengruppe), :method=>:delete,:confirm=>I18n.t('themengruppe.sure')} if can? :delete, @themengruppe
|
||||
|
||||
end
|
||||
|
||||
def sort_themengruppen
|
||||
|
||||
@@ -1,15 +1,17 @@
|
||||
|
||||
class Users::OmniauthCallbacksController < Devise::OmniauthCallbacksController
|
||||
skip_before_filter :verify_authenticity_token
|
||||
def failure
|
||||
skip_before_filter :verify_authenticity_token
|
||||
def failure
|
||||
|
||||
# flash[:notice] = "Failure #{Hash.new(request.env)} #{Hash.new(params)}"
|
||||
#redirect_to new_user_registration_url , :notice=>"Omniauth Login failed"
|
||||
super
|
||||
end
|
||||
def facebook
|
||||
#redirect_to new_user_registration_url , :notice=>"Omniauth Login failed"
|
||||
super
|
||||
end
|
||||
def facebook
|
||||
# You need to implement the method below in your model (e.g. app/models/user.rb)
|
||||
@user = User.find_for_facebook_oauth(request.env["omniauth.auth"], current_user)
|
||||
data=request.env["omniauth.auth"]
|
||||
session[:fbuser_access_token]=data.credentials.token
|
||||
|
||||
if @user
|
||||
sign_in_and_redirect @user, :event => :authentication #this will throw if @user is not activated
|
||||
|
||||
@@ -12,9 +12,19 @@ class UsersController < ApplicationController
|
||||
end
|
||||
redirect_to users_url
|
||||
end
|
||||
def fb_set_default_publish_page
|
||||
if params["page"].nil? || !(current_user.provider=="facebook")
|
||||
redirect_to intern_home_index_path
|
||||
else
|
||||
@fbu=FbGraph::User.new(current_user.uid.to_s).fetch(:access_token=>session["fbuser_access_token"])
|
||||
File.open("tmp/page.yml",'w'){|f| f.write(@fbu.accounts(:access_token=>session["fbuser_access_token"]).select { |p| p.name == params["page"] }.first.to_yaml)}
|
||||
logger.debug @fbu.to_s
|
||||
redirect_to admin_home_index_path
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
def all_update
|
||||
|
||||
params[:users].each do |id,u|
|
||||
user=User.find(id)
|
||||
user.fetprofile = Fetprofile.find(u[:fetprofile_id].to_i) if u[:fetprofile_id].to_i>0
|
||||
@@ -26,7 +36,6 @@ class UsersController < ApplicationController
|
||||
def do_confirm
|
||||
@user= User.find(params[:id])
|
||||
@user.confirm!
|
||||
|
||||
redirect_to users_url
|
||||
end
|
||||
end
|
||||
|
||||
46
app/controllers/wikis_controller.rb
Normal file
46
app/controllers/wikis_controller.rb
Normal file
@@ -0,0 +1,46 @@
|
||||
class WikisController < ApplicationController
|
||||
load_and_authorize_resource
|
||||
|
||||
def show
|
||||
@wiki = Wiki.find(params[:id])
|
||||
@fragen = @wiki.fragen
|
||||
@toolbar_elements = [{:icon=>:pencil, :hicon=>'icon-pencil', :text=>I18n.t('wiki.edit'), :path=>verwalten_thema_path(@wiki)}]
|
||||
end
|
||||
|
||||
def wiki
|
||||
@wiki = Wiki.find_or_init(params[:name])
|
||||
@fragen = @wiki.fragen
|
||||
@toolbar_elements = []
|
||||
# @toolbar_elements = [{:icon=>:pencil, :hicon=>'icon-pencil', :text=>I18n.t('wiki.edit'), :path=>verwalten_wiki_path(@wiki)}]
|
||||
|
||||
redirect_to wiki_path(@wiki)
|
||||
end
|
||||
|
||||
|
||||
def edit
|
||||
@wiki = Wiki.find(params[:id])
|
||||
respond_to do |format|
|
||||
format.html
|
||||
format.js
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
def update
|
||||
@wiki = Wiki.find(params[:id])
|
||||
@themen = @wiki.themengruppe.themen.order(:priority).reverse
|
||||
@wiki.raw_data=params[:wiki][:raw_data]
|
||||
respond_to do |format|
|
||||
if @wiki.update_attributes(params[:wiki])
|
||||
format.html { redirect_to verwalten_thema_path(@wiki), notice: 'Thema was successfully updated.' }
|
||||
format.json { head :no_content }
|
||||
format.js
|
||||
else
|
||||
format.html { render action: "edit" }
|
||||
format.json { render json: @wiki.errors, status: :unprocessable_entity }
|
||||
format.js { render action: "edit" }
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
end
|
||||
@@ -8,6 +8,26 @@ module ApplicationHelper
|
||||
current_url1({:locale=>target_locale}) .sub "/"+I18n.locale.to_s+"/", "/"+target_locale.to_s+"/"
|
||||
|
||||
end
|
||||
def ffi1_icon (name)
|
||||
content_tag("i","", class: "ffi1-"+name )
|
||||
end
|
||||
def ff_icon (name)
|
||||
content_tag("i","", class: name )
|
||||
end
|
||||
|
||||
def ffi1_list
|
||||
y=YAML.load_file("#{::Rails.root.to_s}/config/flatfeticon1.yml")
|
||||
y["ffi1"]
|
||||
end
|
||||
|
||||
def tinymce_icon_choice
|
||||
s=""
|
||||
ffi1_list.each do |i|
|
||||
s=s+'<a onclick="insertIcon_ffi1(\'ffi1-'+i+'\')">'+ffi1_icon(i)+'</a>'
|
||||
end
|
||||
raw(s)
|
||||
end
|
||||
|
||||
def toolbar_html(elemente)
|
||||
html = ""
|
||||
limiter = " | "
|
||||
|
||||
32
app/inputs/datetimepicker_input.rb
Normal file
32
app/inputs/datetimepicker_input.rb
Normal file
@@ -0,0 +1,32 @@
|
||||
class DatetimepickerInput < FormtasticBootstrap::Inputs::StringInput
|
||||
def input_html_options
|
||||
s=super
|
||||
value=builder.object.send(method)
|
||||
value=I18n.l(value) unless value.nil?
|
||||
super.merge(:class => "datetimepicker",:value=>value)
|
||||
end
|
||||
|
||||
def html_options
|
||||
super
|
||||
|
||||
end
|
||||
def wrapper_html_options
|
||||
super.merge(:class=>"")
|
||||
#super.merge(:class=>"datepicker",'date-date-format'.to_sym=>"%d.%m.%Y")
|
||||
end
|
||||
def controls_wrapper_html_options
|
||||
super.merge(:class=> " date input-append", 'data-date'.to_sym =>I18n.l(Date.today()).to_s, 'data-date-format'.to_sym=>I18n.t('date.formats.default-picker'))
|
||||
end
|
||||
def to_html
|
||||
bootstrap_wrapping do
|
||||
builder.text_field(method, input_html_options) +
|
||||
'<span class="add-on" ><i class="icon-th"></i></span>'.html_safe()
|
||||
end
|
||||
end
|
||||
def options
|
||||
super
|
||||
#d.merge(:class=>"datepicker")
|
||||
#super.merge(:append_content=>'<span class="add-on input-append"
|
||||
#super.merge(:append_content=>'<span class="add-on" ><i class="icon-th"></i></span>')
|
||||
end
|
||||
end
|
||||
7
app/mailers/news_mailer.rb
Normal file
7
app/mailers/news_mailer.rb
Normal file
@@ -0,0 +1,7 @@
|
||||
class NewsMailer < ActionMailer::Base
|
||||
default from: "salzamt@fet.at"
|
||||
def neuigkeit_mail(email, neuigkeit_id)
|
||||
@neuigkeit= Neuigkeit.find(neuigkeit_id)
|
||||
mail(to: "andis@fet.at", subject: @neuigkeit.title)
|
||||
end
|
||||
end
|
||||
@@ -2,47 +2,111 @@
|
||||
class Ability
|
||||
include CanCan::Ability
|
||||
def initialize(user)
|
||||
# Define abilities for the passed in user here. For example:
|
||||
#
|
||||
# if user.admin?
|
||||
# can :manage, :all
|
||||
# else
|
||||
# can :read, :all
|
||||
# end
|
||||
# The first argument to `can` is the action you are giving the user permission to do.
|
||||
# If you pass :manage it will apply to every action. Other common actions here are
|
||||
# :read, :create, :update and :destroy.
|
||||
#
|
||||
# The second argument is the resource the user can perform the action on. If you pass
|
||||
# :all it will apply to every resource. Otherwise pass a Ruby class of the resource.
|
||||
#
|
||||
# The third argument is an optional hash of conditions to further filter the objects.
|
||||
# For example, here the user can only update published articles.
|
||||
#
|
||||
# can :update, Article, :published => true
|
||||
#
|
||||
# See the wiki for details: https://github.com/ryanb/cancan/wiki/Defining-Abilitiescan :manage, :all
|
||||
|
||||
loggedin=!(user.nil?)
|
||||
user ||= User.new # guest user (not logged in)
|
||||
|
||||
|
||||
# For Debug allow everything
|
||||
# Remove this line in production environment and for testing user management
|
||||
# can :manage, :all
|
||||
can :addfetuser, User
|
||||
can :addfetadmin, User
|
||||
|
||||
#-----------------------------------------------------
|
||||
# Rechteverwaltung fuer Studien Modul
|
||||
can [:show, :index], Studium
|
||||
can [:show, :index], Modulgruppe
|
||||
can [:show, :index], Modul
|
||||
can [:show, :index], Lva
|
||||
can [:create, :show], Beispiel
|
||||
if loggedin
|
||||
can :like, Beispiel
|
||||
can :dislike, Beispiel
|
||||
end
|
||||
if( user.has_role?("fetuser") || user.has_role?("fetadmin"))
|
||||
can :manage, Modulgruppe
|
||||
can :manage, Modul
|
||||
can :manage, Lva
|
||||
can :manage, Studium
|
||||
end
|
||||
unless user.has_role?("fetadmin")
|
||||
cannot :delete, Studium
|
||||
cannot :delete, Modulgruppe
|
||||
cannot :delete, Modul
|
||||
end
|
||||
|
||||
#-----------------------------------------------------
|
||||
# Rechteverwaltung fuer Informationen
|
||||
can [:show, :index,:faqs], Themengruppe, :public=>true
|
||||
can [:show], Thema, :isdraft=>false
|
||||
can :show, Frage
|
||||
if loggedin
|
||||
end
|
||||
if( user.has_role?("fetuser") || user.has_role?("fetadmin"))
|
||||
can :manage, Frage
|
||||
can :showdraft , Thema
|
||||
can :showintern, Thema
|
||||
can :manage, Thema
|
||||
can :manage, Themengruppe
|
||||
end
|
||||
unless user.has_role?("fetadmin")
|
||||
cannot :delete, Themengruppe
|
||||
cannot :delete, Thema
|
||||
end
|
||||
|
||||
#-----------------------------------------------------
|
||||
# Rechteverwaltung fuer Fotos
|
||||
|
||||
can [:show,:index], Gallery
|
||||
can [:show, :index,:faqs], Themengruppe
|
||||
can [:show], Thema
|
||||
can [:create], Beispiel
|
||||
if loggedin
|
||||
end
|
||||
if( user.has_role?("fetuser") || user.has_role?("fetadmin"))
|
||||
can :manage, Gallery
|
||||
end
|
||||
unless user.has_role?("fetadmin")
|
||||
cannot :delete, Gallery
|
||||
end
|
||||
|
||||
#-----------------------------------------------------
|
||||
# Rechteverwaltung fuer Mitarbeiter
|
||||
can [:show, :index], Fetprofile
|
||||
can [:show, :index],Gremium
|
||||
# Rechteverwaltung fuer Studien Modul
|
||||
if loggedin
|
||||
end
|
||||
if( user.has_role?("fetuser") || user.has_role?("fetadmin"))
|
||||
can :manage, Fetprofile
|
||||
can :manage, Gremium
|
||||
can :manage, Membership
|
||||
end
|
||||
unless user.has_role?("fetadmin")
|
||||
cannot :delete, Fetprofile
|
||||
cannot :delete ,Gremium
|
||||
end
|
||||
|
||||
#-----------------------------------------------------
|
||||
# Rechteverwaltung fuer Neuigkeiten
|
||||
can [:show,:index], Rubrik, :public=>true
|
||||
can :show, Neuigkeit, :rubrik=>{:public=>true}
|
||||
|
||||
if loggedin
|
||||
end
|
||||
if( user.has_role?("fetuser") || user.has_role?("fetadmin"))
|
||||
can :showintern, Neuigkeit
|
||||
can :showintern, Rubrik
|
||||
can :seeintern, User
|
||||
can :shownonpublic, Rubrik
|
||||
|
||||
end
|
||||
if user.has_role?("newsadmin") || user.has_role?("fetadmin")
|
||||
can :addmoderator, Rubrik
|
||||
end
|
||||
if user.has_role?("fetadmin")
|
||||
can :addfetuser, User
|
||||
can :addfetadmin, User
|
||||
end
|
||||
|
||||
if user.has_role?("newsadmin") || user.has_role?( "fetadmin") || user.has_role?( "fetuser")
|
||||
can :manage, Rubrik
|
||||
can :manage, Neuigkeit
|
||||
can :showunpublished, Neuigkeit
|
||||
end
|
||||
unless user.has_role?("fetadmin")
|
||||
cannot :delete, Rubrik
|
||||
cannot :delete, Neuigkeit
|
||||
|
||||
end
|
||||
|
||||
|
||||
|
||||
@@ -50,9 +114,9 @@ class Ability
|
||||
can [:show, :index], Calendar, :public => true
|
||||
can [:showics], Calendar
|
||||
can [:show], Calentry
|
||||
|
||||
if( user.has_role?("fetuser") || user.has_role?("fetadmin"))
|
||||
can :manage,:all
|
||||
can :manage, Modulgruppe
|
||||
|
||||
|
||||
can [:show,:index], Calendar
|
||||
can [:edit, :update,:new,:create,:verwalten], Calendar
|
||||
@@ -61,28 +125,11 @@ class Ability
|
||||
if( user.has_role?("fetadmin"))
|
||||
can [:delete],Calendar
|
||||
can [:delete],Calentry
|
||||
can :doadmin, User
|
||||
end
|
||||
|
||||
# Rechteverwaltung fuer Neuigkeiten
|
||||
|
||||
# can :write, Neuigkeit if user.has_role?("newsmoderator", Neuigkeit.rubrik)
|
||||
|
||||
if user.has_role?("newsadmin") || user.has_role?("fetadmin")
|
||||
can :addmoderator, Rubrik
|
||||
unless user.has_role?("fetadmin")
|
||||
end
|
||||
can [:show,:index], Rubrik, :public=>true
|
||||
|
||||
can :show, Neuigkeit, :rubrik=>{:public=>true}
|
||||
|
||||
if user.has_role?("newsadmin") || user.has_role?( "fetadmin") || user.has_role?( "fetuser")
|
||||
can :manage, Rubrik
|
||||
can :manage, Neuigkeit
|
||||
can :shownonpublic, Rubrik
|
||||
can :showunpublished, Neuigkeit
|
||||
can :seeintern, User
|
||||
|
||||
end
|
||||
|
||||
|
||||
end
|
||||
end
|
||||
|
||||
@@ -12,9 +12,22 @@
|
||||
|
||||
class Attachment < ActiveRecord::Base
|
||||
has_paper_trail
|
||||
attr_accessible :name, :datei
|
||||
attr_accessible :name, :datei, :datei_cache
|
||||
belongs_to :thema
|
||||
mount_uploader :datei, AttachmentUploader
|
||||
validates :thema, :presence => true
|
||||
validates :name, :presence => true
|
||||
|
||||
def to_jq_upload
|
||||
{
|
||||
"id" => read_attribute(:id),
|
||||
"title" => read_attribute(:title),
|
||||
"description" => read_attribute(:desc),
|
||||
"name" => read_attribute(:title),
|
||||
"size" => datei.size,
|
||||
"url" => datei.url,
|
||||
"thumbnail_url" => datei.thumb.url,
|
||||
"delete_type" => "DELETE"
|
||||
}
|
||||
end
|
||||
end
|
||||
|
||||
@@ -14,7 +14,9 @@
|
||||
class Beispiel < ActiveRecord::Base
|
||||
has_paper_trail
|
||||
attr_accessible :desc, :name, :lva_id, :beispieldatei, :beispieldatei_cache, :datum
|
||||
acts_as_votable
|
||||
belongs_to :lva
|
||||
|
||||
mount_uploader :beispieldatei, AttachmentUploader
|
||||
validates :beispieldatei, :presence => true
|
||||
validates :name, :presence => true
|
||||
|
||||
@@ -32,9 +32,12 @@ class Calentry < ActiveRecord::Base
|
||||
|
||||
resourcify
|
||||
def get_public
|
||||
self.public = (self.try(:object).nil?)? (self.calendar.try(:public)) : object.try(:public)
|
||||
self.public = (self.try(:object).nil?)? (self.calendar.try(:public?)) : object.try(:public?)
|
||||
true
|
||||
end
|
||||
def s_time=(s_time)
|
||||
start
|
||||
end
|
||||
def start_time
|
||||
start
|
||||
end
|
||||
@@ -60,7 +63,7 @@ end
|
||||
end
|
||||
end
|
||||
def text
|
||||
I18n.l(self.start) +" bis "+ I18n.l(self.ende)
|
||||
I18n.l(self.start) +" "+ I18n.t("cal.bis")+" "+ I18n.l(self.ende)
|
||||
end
|
||||
scope :public, -> { where(:public => :true) }
|
||||
# scope :upcoming, -> { where("start >= ?" , Time.now).where("start <= ?", 28.days.from_now) }
|
||||
|
||||
@@ -15,19 +15,29 @@
|
||||
#
|
||||
|
||||
class Fetprofile < ActiveRecord::Base
|
||||
attr_accessible :active, :desc, :fetmailalias, :nachname, :picture, :short, :vorname, :memberships_attributes, :remove_picture, :picture_cache
|
||||
attr_accessible :active, :desc, :fetmailalias, :nachname, :picture, :short, :vorname, :memberships_attributes, :remove_picture, :picture_cache, :plz, :street, :city, :instant,:skype, :telnr, :hdynr, :birth_day, :birth_month, :birth_year,:geschlecht
|
||||
has_many :memberships, dependent: :delete_all
|
||||
has_many :gremien, :through=> :membership
|
||||
mount_uploader :picture, PictureUploader
|
||||
has_paper_trail
|
||||
validates :desc, :presence=>true
|
||||
validates :desc, :presence=>true
|
||||
validates :nachname, length:{minimum: 3},:presence=>true
|
||||
validates :vorname, length:{minimum: 3},:presence=>true
|
||||
validate :validate_birthday
|
||||
GESCHLECHT={0=>"gendered", 1=>"maennlich", 2=>"weiblich"}
|
||||
has_many :users
|
||||
scope :search, ->(query) {where("nachname like ? or vorname like ? or short like ?", "%#{query}%", "%#{query}%", "%#{query}%")}
|
||||
|
||||
accepts_nested_attributes_for :memberships, :reject_if=>lambda{|a| a[:typ].blank?|| a[:start].blank? ||a[:gremium_id].blank?}, :allow_destroy=>true
|
||||
has_many :nlinks, as: :link
|
||||
def validate_birthday
|
||||
unless birth_month.nil? || birth_day.nil?
|
||||
unless Date.valid_date?((birth_year.nil?) ? Date.today.year : birth_year, birth_month, birth_day)
|
||||
errors.add(:birth_month, "Invalides Datum")
|
||||
errors.add(:birth_day, "Invalides Datum")
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
def title
|
||||
self.name
|
||||
@@ -39,4 +49,15 @@ validates :desc, :presence=>true
|
||||
def fetmail
|
||||
(fetmailalias.nil? || fetmailalias.empty?) ? short.to_s + "@fet.at" : fetmailalias.to_s + "@fet.at"
|
||||
end
|
||||
def adress
|
||||
connector= (self.street.nil?||self.street.empty?||(self.city.empty? && self.plz.empty?)) ? '' : ', '
|
||||
self.plz.to_s + ' ' + self.city.to_s + connector.to_s + self.street.to_s
|
||||
end
|
||||
def birthday
|
||||
if self.birth_year.nil? || self.birth_year.zero?
|
||||
Date.new( Date.today.year,self.birth_month,self.birth_day)
|
||||
else
|
||||
Date.new( self.birth_year,self.birth_month,self.birth_day)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
#
|
||||
|
||||
class Gremium < ActiveRecord::Base
|
||||
TYPEN={1=>"offiziell", 2=>"offiziell-temporär", 3 => "inoffiziell",4=>"inoffiziell-tempo", 11=> "berufungskommission",12=> "habilitationskommission" } # Kategorien, im Wesentlichen wichtig für Listung oder nicht Listung
|
||||
TYPEN={1=>"offiziell", 2=>"offiziell-notab", 3 => "inoffiziell",4=>"inoffiziell-notab", 11=> "berufungskommission",12=> "habilitationskommission" } # Kategorien, im Wesentlichen wichtig für Listung oder nicht Listung
|
||||
GESCHLECHT={0=>"saechlich", 1 => "maennlich", 2 => "weiblich"} # Geschlecht des Gremiums zur richtige Deklination
|
||||
ART2FALL={0=>"des", 1=>"des",2=>"der"} # Artikel 2.Fall abhängig vom Geschlecht
|
||||
ART4FALL={0=>"das", 1=>"den",2=>"die"} # Artikel 2.Fall abhängig vom Geschlecht
|
||||
@@ -20,8 +20,8 @@ class Gremium < ActiveRecord::Base
|
||||
TEXT={11=>I18n.t("gremium.filter.berufung.text"),12=>I18n.t("gremium.filter.habil.text")}
|
||||
|
||||
attr_accessible :desc, :name, :typ, :geschlecht,:thema_id, :memberships_attributes
|
||||
has_many :memberships # Mitgliedschaften bei dem Gremium
|
||||
has_many :nlinks, as: :link
|
||||
has_many :memberships, dependent: :destroy # Mitgliedschaften bei dem Gremium
|
||||
has_many :nlinks, as: :link, dependent: :destroy
|
||||
scope :search, ->(query) {where("gremien.name like ? or gremien.desc like ?", "%#{query}%", "%#{query}%")}
|
||||
|
||||
belongs_to :thema # Gehört zu einem Thema
|
||||
|
||||
@@ -40,7 +40,7 @@ class Lva < ActiveRecord::Base
|
||||
has_paper_trail :ignore=>[:desc, :pruefungsinformation]# Versionsverfolgung
|
||||
translates :desc,:pruefungsinformation, :fallbacks_for_empty_translations => true, :versioning=>true
|
||||
|
||||
attr_accessible :desc, :ects, :lvanr, :name, :stunden, :modul_ids, :semester_ids, :pruefungsinformation, :lernaufwand, :typ, :lecturer_ids
|
||||
attr_accessible :desc, :ects, :lvanr, :name, :stunden, :modul_ids, :semester_ids, :pruefungsinformation, :lernaufwand, :typ, :lecturer_ids, :forumlink
|
||||
|
||||
has_and_belongs_to_many :modul,:uniq=>true # Gehört zu einem Modul
|
||||
has_and_belongs_to_many :semester
|
||||
@@ -58,12 +58,14 @@ class Lva < ActiveRecord::Base
|
||||
validates_presence_of :modul # Zugehöriges Modul eingetragen?
|
||||
# (zumindest eines)
|
||||
|
||||
|
||||
def typ_n
|
||||
typ=="andere" ? "" : typ
|
||||
end
|
||||
def title
|
||||
self.name
|
||||
end
|
||||
def full_name
|
||||
return self.typ + ' ' + self.name
|
||||
return self.typ_n + ' ' + self.name
|
||||
end
|
||||
def add_semesters
|
||||
# Diese Methode fügt die Instanz automatisch zu allen Studien als "Ohne Semesterempfehlung" (Semester 0) zu, bei denen die Instanz im Studium noch nicht vorkommt.
|
||||
|
||||
@@ -14,6 +14,7 @@
|
||||
|
||||
class Membership < ActiveRecord::Base
|
||||
TYPEN={-2=>"VorsitzendeR", -1=>"stv VorsitzendeR", 0=>"2. stv VorsitzendeR", 1=>"Mitglied",2=> "Ersatzmitglied",3=>"VerantwortlicheR"}
|
||||
TYPEN_g={0=>TYPEN, 1=>{ -2=>"Vorsitzender", -1=>"stv Vorsitzender", 0=>"2. stv Vorsitzender", 1=>"Mitglied",2=> "Ersatzmitglied",3=>"Verantwortlicher"},2=>{-2=>"Vorsitzende", -1=>"stv Vorsitzende", 0=>"2. stv Vorsitzende", 1=>"Mitglied",2=> "Ersatzmitglied",3=>"Verantwortliche"}}
|
||||
attr_accessible :fetprofile_id, :gremium_id, :start, :stop, :typ
|
||||
belongs_to :fetprofile
|
||||
belongs_to :gremium
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
#
|
||||
|
||||
class Modul < ActiveRecord::Base
|
||||
attr_accessible :desc,:name, :depend, :studium_id, :modulgruppen
|
||||
attr_accessible :desc,:name, :depend, :studium_id, :modulgruppen, :modulgruppe_ids
|
||||
|
||||
has_and_belongs_to_many :lvas , :uniq=>true
|
||||
has_and_belongs_to_many :modulgruppen
|
||||
|
||||
@@ -22,9 +22,11 @@ class Neuigkeit < ActiveRecord::Base
|
||||
translates :title,:text, :versioning=>{:gem=>:paper_trail, :options=>{:fallbacks_for_empty_translations => true}}
|
||||
|
||||
has_many :calentries, as: :object
|
||||
has_many :nlinks
|
||||
|
||||
mount_uploader :picture, PictureUploader
|
||||
|
||||
default_scope order(:datum).reverse_order
|
||||
#scope :published, -> {where("datum <= ? AND datum IS NOT NULL", Time.now.to_date)}
|
||||
scope :recent, -> { published.limit(10)}
|
||||
scope :unpublished, -> {where("datum >= ? OR datum IS NULL", Date.today)}
|
||||
scope :public, ->{includes(:rubrik).where("rubriken.public"=>true)}
|
||||
@@ -34,7 +36,9 @@ class Neuigkeit < ActiveRecord::Base
|
||||
LINKTYPES=["Thema", "Gallery", "Lva","Studium","Fetprofile", "Gremium"]
|
||||
accepts_nested_attributes_for :calentries, :allow_destroy=>true , :reject_if=> lambda{|a| a[:start].blank?}
|
||||
before_validation :sanitize
|
||||
has_many :nlinks
|
||||
|
||||
|
||||
|
||||
def self.published
|
||||
where("datum <= ? AND datum IS NOT NULL", Time.now.to_date)
|
||||
end
|
||||
@@ -46,7 +50,7 @@ class Neuigkeit < ActiveRecord::Base
|
||||
self.rubrik.public
|
||||
end
|
||||
def published?
|
||||
self.datum_nilsave>=Time.now.to_date
|
||||
self.datum_nilsave<Time.now.to_date
|
||||
end
|
||||
|
||||
def publish
|
||||
@@ -56,8 +60,8 @@ class Neuigkeit < ActiveRecord::Base
|
||||
self.datum = nil
|
||||
end
|
||||
def name
|
||||
self.title
|
||||
end
|
||||
self.title
|
||||
end
|
||||
def text_first_words
|
||||
md = /<p>(?<text>[^\<\>]*)/.match Sanitize.clean(self.text,:elements=>['p'])
|
||||
words=md[:text].split(" ") unless md.nil?
|
||||
@@ -68,15 +72,15 @@ end
|
||||
|
||||
end
|
||||
end
|
||||
def has_calentries?
|
||||
!self.calentries.nil? && !self.calentries.empty?
|
||||
end
|
||||
private
|
||||
def sanitize
|
||||
self.calentries.each do |calentry|
|
||||
calentry.calendar= self.rubrik.calendar
|
||||
calentry.typ=1
|
||||
calentry.object=self
|
||||
end
|
||||
end
|
||||
def has_calentries?
|
||||
!self.calentries.nil? && !self.calentries.empty?
|
||||
end
|
||||
private
|
||||
def sanitize
|
||||
self.calentries.each do |calentry|
|
||||
calentry.calendar= self.rubrik.calendar
|
||||
calentry.typ=1
|
||||
calentry.object=self
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
#
|
||||
|
||||
class Rubrik < ActiveRecord::Base
|
||||
attr_accessible :desc, :name, :prio, :calendar, :public
|
||||
attr_accessible :desc, :name, :prio, :calendar, :public, :icon, :color
|
||||
has_many :neuigkeiten, :class_name => "Neuigkeit"
|
||||
has_many :published, :class_name => "Neuigkeit", :conditions=>["Neuigkeit.published"]
|
||||
has_many :calentries, :through => :neuigkeiten, :as=>:object
|
||||
|
||||
@@ -9,9 +9,10 @@
|
||||
# updated_at :datetime not null
|
||||
# themengruppe_id :integer
|
||||
#
|
||||
|
||||
require 'uri'
|
||||
class Thema < ActiveRecord::Base
|
||||
attr_accessible :text, :title, :themengruppe_id
|
||||
include Rails.application.routes.url_helpers
|
||||
attr_accessible :text, :title, :themengruppe_id,:isdraft, :hidelink, :hideattachment
|
||||
has_many :fragen
|
||||
has_many :attachments
|
||||
belongs_to :themengruppe, :foreign_key => "themengruppe_id"
|
||||
@@ -20,9 +21,21 @@ class Thema < ActiveRecord::Base
|
||||
validates :themengruppe, :presence => true
|
||||
validates :title, :presence => true
|
||||
validates :text, :presence => true
|
||||
scope :search, ->(query) {where("text like ? or title like ?", "%#{query}%", "%#{query}%")}
|
||||
translates :title,:text, :versioning =>true, :fallbacks_for_empty_translations => true
|
||||
|
||||
scope :search, ->(query) {where("text like ? or title like ?", "%#{query}%", "%#{query}%")}
|
||||
scope :outdated, -> {includes(:translations).where("thema_translations.updated_at<?",2.month.ago).where("thema_translations.locale"=>I18n.t.locale)
|
||||
}
|
||||
translates :title,:text, :versioning =>true, :fallbacks_for_empty_translations => true
|
||||
def is_outdated?
|
||||
unless translation.try(:updated_at).nil?
|
||||
translation.updated_at < 2.month.ago
|
||||
else
|
||||
false
|
||||
end
|
||||
end
|
||||
def is_wiki?
|
||||
!(wikiname.nil? || wikiname.empty?)
|
||||
end
|
||||
def text_first_words
|
||||
md = /<p>(?<text>[^\<\>]*)/.match Sanitize.clean(self.text,:elements=>['p'])
|
||||
words=md[:text].split(" ") unless md.nil?
|
||||
@@ -34,4 +47,10 @@ class Thema < ActiveRecord::Base
|
||||
end
|
||||
end
|
||||
|
||||
def fix_links(host)
|
||||
full_url= URI.parse(root_url(:host=>host))
|
||||
self.text.gsub!(/src="[^"]*attachment\/datei\/(\d+)[^"]*"/){|s| full_url.path=Attachment.find($1.to_i).datei.url; 'src="'+full_url.to_s+'"'}
|
||||
self.text.gsub!(/href="[^"]*themen\/(\d+)[^"]*"/){|s| full_url.path=thema_path(Thema.find($1.to_i)); 'href="'+full_url.to_s+'"'}
|
||||
|
||||
end
|
||||
end
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
|
||||
class Themengruppe < ActiveRecord::Base
|
||||
WORD_COUNT = 50
|
||||
attr_accessible :text, :title, :picture, :priority
|
||||
attr_accessible :text, :title, :picture, :priority, :public, :icon
|
||||
has_many :themen, class_name: 'Thema'
|
||||
has_many :fragen, through: :themen
|
||||
|
||||
@@ -20,4 +20,20 @@ class Themengruppe < ActiveRecord::Base
|
||||
validates :text, :presence => true
|
||||
|
||||
translates :title,:text, :versioning =>true, :fallbacks_for_empty_translations => true
|
||||
|
||||
scope :intern,-> {where(:public=>false)}
|
||||
scope :public,-> {where(:public=>true)}
|
||||
|
||||
def self.find_wiki_default
|
||||
where(:wiki_default=>true).first
|
||||
end
|
||||
def intern
|
||||
! self.public
|
||||
end
|
||||
def make_wiki_default
|
||||
Themengruppe.where(:wiki_default=>:true).update_all(:wiki_default=>:false)
|
||||
self.wiki_default=true;
|
||||
self.save;
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
@@ -30,7 +30,7 @@ class User < ActiveRecord::Base
|
||||
# :token_authenticatable, :confirmable,
|
||||
# :lockable, :timeoutable and :omniauthable
|
||||
devise :database_authenticatable, :recoverable, :rememberable, :trackable, :validatable,:omniauthable, :omniauth_providers => [:facebook,:ldap]
|
||||
|
||||
acts_as_voter
|
||||
# Setup accessible (or protected) attributes for your model
|
||||
attr_accessible :email, :password, :password_confirmation, :remember_me, :provider, :uid, :name
|
||||
belongs_to :fetprofile
|
||||
@@ -38,16 +38,17 @@ belongs_to :fetprofile
|
||||
def self.find_for_facebook_oauth(auth, signed_in_resource=nil)
|
||||
logger.debug auth.to_s
|
||||
logger.debug "DDD Username= #{auth.username}"
|
||||
# user = User.where(:provider => auth.provider, :uid => auth.uid).first
|
||||
user = User.where(:provider => auth.provider, :uid => auth.uid).first
|
||||
unless user
|
||||
user = User.create(name:auth.uid,
|
||||
user = User.create(name: auth.uid,
|
||||
provider:auth.provider,
|
||||
uid:auth.uid,
|
||||
uid: auth.uid,
|
||||
email:auth.info.email,
|
||||
password:Devise.friendly_token[0,20]
|
||||
)
|
||||
end
|
||||
|
||||
|
||||
user
|
||||
end
|
||||
def self.find_for_ldap_oauth(auth,signed_in_resource=nil)
|
||||
@@ -61,15 +62,7 @@ logger.debug auth.to_s
|
||||
email:auth.extra.raw_info.mail.first.to_s,
|
||||
password:Devise.friendly_token[0,20])
|
||||
user.add_role("fetuser")
|
||||
logger.debug(auth.extra.raw_info.to_s)
|
||||
end
|
||||
unless user
|
||||
# user=User.create(name:"fail",
|
||||
# provider:"ldap",
|
||||
# uid:"sdf",
|
||||
# email:"sdf@fet.at",
|
||||
# password:Devise.friendly_token[0,20])
|
||||
|
||||
logger.debug(auth.extra.raw_info.to_s)
|
||||
end
|
||||
user
|
||||
end
|
||||
|
||||
73
app/models/wiki.rb
Normal file
73
app/models/wiki.rb
Normal file
@@ -0,0 +1,73 @@
|
||||
class Wiki < Thema
|
||||
validates :wikiname, :uniqueness=>true, :presence=>true
|
||||
after_initialize :load_wiki
|
||||
attr_accessible :wikiname, :wikiformat, :hidelink, :raw_data
|
||||
WIKIFORMATS={nil=> :textile, 0 =>:textile, 1=> :mediawiki}
|
||||
|
||||
def self.find_or_init(name)
|
||||
w = Wiki.where(:wikiname=>name).first
|
||||
page = is_file_availaible(name)
|
||||
if w.nil?
|
||||
unless page.nil?
|
||||
w=Wiki.new(:wikiname=>name, :title=>name, :wikiformat=>Wiki::WIKIFORMATS.invert[page.format], :hidelink=>true)
|
||||
else
|
||||
w=Wiki.new(:wikiname=>name, :title=>name, :wikiformat=>0, :hidelink=>true)
|
||||
wiki = Gollum::Wiki.new("../wiki.git", :base_path => "/wiki")
|
||||
page=wiki.write_page(name, :textile, "ioi", self.commit)
|
||||
w.reload_page
|
||||
end
|
||||
|
||||
w.themengruppe = Themengruppe.find_wiki_default
|
||||
w.raw_data="Neues Wiki"
|
||||
w.save
|
||||
end
|
||||
w
|
||||
end
|
||||
|
||||
def raw_data
|
||||
self.page.raw_data
|
||||
end
|
||||
|
||||
def raw_data=(data)
|
||||
self.get_page(self.wikiname)
|
||||
self.wiki.update_page(self.page, self.wikiname, Wiki::WIKIFORMATS[self.wikiformat], data, self.commit)
|
||||
self.text=self.page.formatted_data
|
||||
|
||||
end
|
||||
|
||||
def page
|
||||
self.get_page(wikiname) if @page.nil?
|
||||
@page
|
||||
end
|
||||
|
||||
def wiki
|
||||
@wiki
|
||||
end
|
||||
def reload_page
|
||||
self.get_page(self.wikiname)
|
||||
end
|
||||
protected
|
||||
|
||||
|
||||
def self.is_file_availaible(name)
|
||||
wiki = Gollum::Wiki.new("../wiki.git", :base_path => "/wiki")
|
||||
wiki.page(name)
|
||||
end
|
||||
|
||||
def load_wiki
|
||||
@wiki = Gollum::Wiki.new("../wiki.git", :base_path => "/wiki")
|
||||
end
|
||||
|
||||
def get_page(name)
|
||||
@page= @wiki.page(name)
|
||||
@page=self.wiki.write_page(self.wikiname, Wiki::WIKIFORMATS[self.wikiformat]," ",self.commit) if @page.nil?
|
||||
@page
|
||||
end
|
||||
def commit
|
||||
{message: "RailsUpdate", name:"SomeUser", email: "ttt@t"}
|
||||
end
|
||||
|
||||
def self.commit
|
||||
{message: "RailsUpdate", name:"SomeUser", email: "ttt@t"}
|
||||
end
|
||||
end
|
||||
@@ -4,8 +4,13 @@ class AttachmentUploader < CarrierWave::Uploader::Base
|
||||
|
||||
# Include RMagick or MiniMagick support:
|
||||
include CarrierWave::RMagick
|
||||
# include CarrierWave::Uploader::Processing
|
||||
|
||||
# include CarrierWave::RMagick
|
||||
# include CarrierWave::MiniMagick
|
||||
def root
|
||||
Rails.root.join 'public/'
|
||||
end
|
||||
|
||||
# Choose what kind of storage to use for this uploader:
|
||||
storage :file
|
||||
@@ -16,12 +21,44 @@ class AttachmentUploader < CarrierWave::Uploader::Base
|
||||
def store_dir
|
||||
"uploads/#{model.class.to_s.underscore}/#{mounted_as}/#{model.id}"
|
||||
end
|
||||
def cover
|
||||
manipulate! do |frame, index|
|
||||
index== 0 ? frame.convert(:jpg) : nil
|
||||
|
||||
version :thumb do
|
||||
end
|
||||
end
|
||||
version :thumb ,:if=>:image? do
|
||||
process :resize_to_fill => [64, 64]
|
||||
process :convert => :jpg
|
||||
|
||||
def full_filename(for_file)
|
||||
super.chomp(File.extname(super)) + '.jpg'
|
||||
end
|
||||
end
|
||||
|
||||
# Provide a default URL as a default if there hasn't been a file uploaded:
|
||||
version :cover , :if=>:image? do
|
||||
process :cover
|
||||
process :resize_to_fit => [64,64]
|
||||
process :convert => :jpg
|
||||
def full_filename(for_file)
|
||||
super.chomp(File.extname(super)) + '.jpg'
|
||||
end
|
||||
end
|
||||
version :thumb_small , :if=>:image? do
|
||||
process :resize_to_fill => [32, 32]
|
||||
end
|
||||
version :thumb_big , :if=>:image? do
|
||||
|
||||
process :resize_to_fill => [200, 200]
|
||||
process :convert => :jpg
|
||||
def full_filename(for_file)
|
||||
super.chomp(File.extname(super)) + '.jpg'
|
||||
end
|
||||
|
||||
end
|
||||
version :resized, :if=>:image? do
|
||||
process :resize_to_fit => [1024,1024]
|
||||
end
|
||||
# def default_url
|
||||
# # For Rails 3.1+ asset pipeline compatibility:
|
||||
# # ActionController::Base.helpers.asset_path("fallback/" + [version_name, "default.png"].compact.join('_'))
|
||||
@@ -52,5 +89,8 @@ class AttachmentUploader < CarrierWave::Uploader::Base
|
||||
# def filename
|
||||
# "something.jpg" if original_filename
|
||||
# end
|
||||
|
||||
protected
|
||||
def image?(file)
|
||||
%w(jpg png jpeg).include?(File.extname(full_filename(file)))
|
||||
end
|
||||
end
|
||||
|
||||
@@ -12,6 +12,10 @@ class BeispieldateiUploader < CarrierWave::Uploader::Base
|
||||
|
||||
# Override the directory where uploaded files will be stored.
|
||||
# This is a sensible default for uploaders that are meant to be mounted:
|
||||
def root
|
||||
Rails.root.join 'public/'
|
||||
end
|
||||
|
||||
def store_dir
|
||||
"uploads/#{model.class.to_s.underscore}/#{mounted_as}/#{model.id}"
|
||||
end
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
<% data_ext = attachment.datei.file.extension.downcase %>
|
||||
|
||||
<%= attachment.name %> </br>
|
||||
|
||||
<% if (!["jpg","png","jpeg"].find_index(data_ext).nil?) %>
|
||||
<%= image_tag attachment.datei.thumb.url %>
|
||||
<% else %>
|
||||
<%= image_tag "pdf-logo.jpg" %>
|
||||
<% end %>
|
||||
|
||||
<%= attachment.name %>
|
||||
|
||||
143
app/views/attachments/_form_bulk.html.erb
Normal file
143
app/views/attachments/_form_bulk.html.erb
Normal file
@@ -0,0 +1,143 @@
|
||||
|
||||
<div class="container-fluid">
|
||||
<%= semantic_form_for [@thema,@attachment], :remote=>true, :html => { :multipart => true, :id => "fileupload" } do |f| %>
|
||||
<!-- The fileupload-buttonbar contains buttons to add/delete files and start/cancel the upload -->
|
||||
<div class="row-fluid">
|
||||
|
||||
<div class="span7">
|
||||
<div class="fileupload-buttonbar">
|
||||
<!-- The fileinput-button span is used to style the file input field as button -->
|
||||
<span class="btn btn-success fileinput-button">
|
||||
<i class="icon-plus icon-white"></i>
|
||||
<span>Add files...</span>
|
||||
<%= f.file_field :datei, :multiple=>true %>
|
||||
<% f.input :thema %>
|
||||
</span>
|
||||
<button type="submit" class="btn btn-primary start">
|
||||
<i class="icon-upload icon-white"></i>
|
||||
<span>Start upload</span>
|
||||
</button>
|
||||
<button type="reset" class="btn btn-warning cancel">
|
||||
<i class="icon-ban-circle icon-white"></i>
|
||||
<span>Cancel upload</span>
|
||||
</button>
|
||||
<button type="button" class="btn btn-danger delete">
|
||||
<i class="icon-trash icon-white"></i>
|
||||
<span>Delete</span>
|
||||
</button>
|
||||
<input type="checkbox" class="toggle">
|
||||
</div>
|
||||
<div class="span5">
|
||||
<!-- The global progress bar -->
|
||||
<div class="progress progress-success progress-striped active fade">
|
||||
<div class="bar" style="width:100%;"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- The loading indicator is shown during image processing -->
|
||||
<div class="fileupload-loading"></div>
|
||||
<br>
|
||||
<!-- The table listing the files available for upload/download -->
|
||||
<table class="table table-striped"><tbody class="files" data-toggle="modal-lva" data-target="#modal-lva"></tbody>
|
||||
</table>
|
||||
<% end %>
|
||||
|
||||
</div>
|
||||
<script>
|
||||
var fileUploadErrors = {
|
||||
maxFileSize: 'File is too big',
|
||||
minFileSize: 'File is too small',
|
||||
acceptFileTypes: 'Filetype not allowed',
|
||||
maxNumberOfFiles: 'Max number of files exceeded',
|
||||
uploadedBytes: 'Uploaded bytes exceed file size',
|
||||
emptyResult: 'Empty file upload result'
|
||||
};
|
||||
</script>
|
||||
|
||||
<!-- The template to display files available for upload -->
|
||||
<script id="template-upload" type="text/x-tmpl">
|
||||
{% for (var i=0, file; file=o.files[i]; i++) { %}
|
||||
<tr class="template-upload fade">
|
||||
<!--<td class="preview"><span class="fade"></span></td>-->
|
||||
<td class="name"><span>{%=file.name %}</span></td>
|
||||
<td class="size"><span>{%=o.formatFileSize(file.size)%}</span></td>
|
||||
{% if (file.error) { %}
|
||||
<td class="error" colspan="2"><span class="label label-important">{%=locale.fileupload.error%}</span> {%=locale.fileupload.errors[file.error] || file.error%}</td>
|
||||
{% } else if (o.files.valid && !i) { %}
|
||||
<td>
|
||||
<div class="progress progress-success progress-striped active"><div class="bar" style="width:0%;"></div></div>
|
||||
</td>
|
||||
<td class="start">{% if (!o.options.autoUpload) { %}
|
||||
<button class="btn btn-primary">
|
||||
<i class="icon-upload icon-white"></i>
|
||||
<span>{%=locale.fileupload.start%}</span>
|
||||
</button>
|
||||
{% } %}</td>
|
||||
{% } else { %}
|
||||
<td colspan="2"></td>
|
||||
{% } %}
|
||||
<td class="cancel">{% if (!i) { %}
|
||||
<button class="btn btn-warning">
|
||||
<i class="icon-ban-circle icon-white"></i>
|
||||
<span>{%=locale.fileupload.cancel%}</span>
|
||||
</button>
|
||||
{% } %}</td>
|
||||
</tr>
|
||||
{% } %}
|
||||
</script>
|
||||
<!-- The template to display files available for download -->
|
||||
<script id="template-download" type="text/x-tmpl">
|
||||
{% for (var i=0, file; file=o.files[i]; i++) { %}
|
||||
<tr class="template-download fade">
|
||||
{% if (file.error) { %}
|
||||
<td></td>
|
||||
<td class="name"><span>{%=file.name%}</span></td>
|
||||
<td class="size"><span>{%=o.formatFileSize(file.size)%}</span></td>
|
||||
<td class="error" colspan="2"><span class="label label-important">{%=locale.fileupload.error%}</span> {%=locale.fileupload.errors[file.error] || file.error%}</td>
|
||||
{% } else { %}
|
||||
<!--<td class="preview">{% if (file.thumbnail_url) { %}
|
||||
<a href="{%=file.url%}" title="{%=file.name%}" rel="lva" download="{%=file.name%}"><img src="{%=file.thumbnail_url%}"></a>
|
||||
{% } %}</td>-->
|
||||
<td class="name">
|
||||
<a href="{%=file.url%}" title="{%=file.name%}" rel="{%=file.thumbnail_url&&'lva'%}" download="{%=file.name%}">{%=file.name%}</a>
|
||||
</td>
|
||||
<td class="size"><span>{%=o.formatFileSize(file.size)%}</span></td>
|
||||
<td colspan="2"></td>
|
||||
{% } %}
|
||||
<td class="delete">
|
||||
<button class="btn btn-danger" data-type="{%=file.delete_type%}" data-url="{%=file.delete_url%}">
|
||||
<i class="icon-trash icon-white"></i>
|
||||
<span>{%=locale.fileupload.destroy%}</span>
|
||||
</button>
|
||||
<input type="checkbox" name="delete" value="1">
|
||||
</td>
|
||||
</tr>
|
||||
{% } %}
|
||||
</script>
|
||||
|
||||
<script type="text/javascript" charset="utf-8">
|
||||
$(function () {
|
||||
// Initialize the jQuery File Upload widget:
|
||||
$('#fileupload').fileupload();
|
||||
//
|
||||
// Load existing files:
|
||||
$.getJSON($('#fileupload').prop('action'), function (files) {
|
||||
var fu = $('#fileupload').data('blueimpFileupload'),
|
||||
template;
|
||||
fu._adjustMaxNumberOfFiles(-files.length);
|
||||
console.log(files);
|
||||
// no Download on Upload form
|
||||
//template = fu._renderDownload(files)
|
||||
//.appendTo($('#fileupload .files'));
|
||||
// Force reflow:
|
||||
fu._reflow = fu._transition && template.length &&
|
||||
template[0].offsetWidth;
|
||||
template.addClass('in');
|
||||
$('#loading').remove();
|
||||
});
|
||||
$('#attachment_datei').attr('name', 'attachment[datei]');
|
||||
$('#attachment_datei').fileupload();
|
||||
|
||||
});
|
||||
</script>
|
||||
@@ -1,10 +1,32 @@
|
||||
|
||||
<div class="row-fluid contentbox">
|
||||
<div class="span5">
|
||||
<b><%=link_to beispiel.name, beispiel.beispieldatei.url%></b> <%= link_to "edit", edit_beispiel_path(beispiel)%></br>
|
||||
<%= I18n.t("file.size") + ": " + (beispiel.beispieldatei.size/1024.0).round(2).to_s %>KiB
|
||||
<div class="span8">
|
||||
|
||||
<b><%=link_to ffi1_icon("note20")+" " + beispiel.name, beispiel.beispieldatei.url, title: beispiel.desc %></b>
|
||||
|
||||
<%= I18n.t("file.size") + ": " + (beispiel.beispieldatei.size/1024.0).round(2).to_s %>KiB <br>
|
||||
<span class="linklist"><%=
|
||||
if can?(:like, beispiel)
|
||||
link_to ffi1_icon("like3")+" like" + "("+beispiel.get_likes.size.to_s+")", like_beispiel_path(beispiel),title: "liked by " + ((current_user.liked?(beispiel)) ? ("you and " + ((beispiel.get_likes.size - 1).to_s + " others")) : beispiel.get_likes.size.to_s)
|
||||
else
|
||||
"liked by " + beispiel.get_likes.size.to_s
|
||||
end
|
||||
%>
|
||||
|
||||
<%=
|
||||
if can?(:dislike, beispiel)
|
||||
link_to ffi1_icon("dislike")+" dislike" + "("+beispiel.get_dislikes.size.to_s+")", dislike_beispiel_path(beispiel),title:"disliked by " + ((current_user.disliked?(beispiel)) ? ("you and " + ((beispiel.get_dislikes.size - 1).to_s + " others")) : beispiel.get_dislikes.size.to_s)
|
||||
else
|
||||
"disliked by " + beispiel.get_dislikes.size.to_s
|
||||
end
|
||||
|
||||
%>
|
||||
|
||||
<%= link_to ff_icon("icon-pencil")+" edit", edit_beispiel_path(beispiel) if can? :edit, beispiel%>
|
||||
<%= link_to ff_icon("icon-remove")+" delete", beispiel_path(beispiel), :method=>:delete, :data=>{:confirm=>I18n.t('beispiel.sure')} if can? :delete, beispiel %></br>
|
||||
</span>
|
||||
</div>
|
||||
<div class="span7">
|
||||
<div class="span4">
|
||||
<%= beispiel.desc %>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -14,6 +14,8 @@
|
||||
</div>
|
||||
|
||||
<div class="row-fluid">
|
||||
<%= f.input :name %>
|
||||
|
||||
<%= f.input :desc %>
|
||||
</div>
|
||||
|
||||
@@ -21,7 +23,7 @@
|
||||
|
||||
</div>
|
||||
<div class="span4">
|
||||
<%= f.input :lva, :as=>:radio, :collection => Lva.all%>
|
||||
<%= f.input :lva, :as=>:radio, :collection => Lva.all %>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
|
||||
</div>
|
||||
<div class="span4">
|
||||
<%= f.input :start, :as => :datepicker %></div><div class="span4">
|
||||
<%= f.input :start, :as => :datetimepicker %></div><div class="span4">
|
||||
<%= f.input :dauer , :as => :string, :append=>"h" %></div><div class="span1">
|
||||
<% f.input :typ %></div> <div class="span1"><%= f.check_box :_destroy %> <%= I18n.t 'common.delete' %></div>
|
||||
</div>
|
||||
|
||||
@@ -11,11 +11,11 @@
|
||||
</div> </div>
|
||||
<div class="row-fluid">
|
||||
<div class="span12">
|
||||
<%= f.input :desc %>
|
||||
<%= f.input :desc , input_html: {style: "width:100%"}%>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row-fluid">
|
||||
<div class="span4"> <%= f.input :active %></div>
|
||||
<div class="span4"> <%= f.input :active %> <%= f.input :geschlecht,:as=>:select, :collection=>Fetprofile::GESCHLECHT.invert %></div>
|
||||
<div class="span4">
|
||||
<%= image_tag(@fetprofile.picture.thumb.url) unless @fetprofile.picture.nil? %>
|
||||
<%= f.file_field :picture %>
|
||||
@@ -28,28 +28,48 @@
|
||||
<div class="span4"> <%= f.input :fetmailalias %></div>
|
||||
</div>
|
||||
|
||||
<% @memberships.each do |m| %>
|
||||
<div class="row-fluid">
|
||||
<div class="span6">
|
||||
|
||||
<%= f.semantic_fields_for :memberships, m do |membership| %>
|
||||
<%= I18n.t("fetprofile.adresse") %>:
|
||||
|
||||
<div class="row-fluid">
|
||||
|
||||
|
||||
<div class="span3"><%= membership.input :start, :as=>:datepicker, :prepend=>"von",:label=>false%></div>
|
||||
<div class="span3"><%= membership.input :stop, :as=>:datepicker,:label=>false, :prepend =>"bis" %></div>
|
||||
<div class="span2"><%= membership.input :typ ,:as=>:select, :collection=>Membership::TYPEN.invert, :label=>false %></div>
|
||||
<div class="span3"><%= membership.input :gremium, :label=>false %>
|
||||
<%=f.input :street %>
|
||||
<table><tr><td>
|
||||
<%=f.input :plz, input_html: {style: "width:5em"} %></td>
|
||||
<td><%=f.input :city, input_html: {style: "width:5em"} %></td></tr></table>
|
||||
<%=f.input :telnr %>
|
||||
<%=f.input :hdynr %>
|
||||
|
||||
</div>
|
||||
<div class="span1"><%= membership.check_box :_destroy %> <%= I18n.t 'common.delete' %></div>
|
||||
<div class="span6">
|
||||
<%= I18n.t("fetprofile.geburtstag") %>:
|
||||
<table><tr>
|
||||
<td><%=f.input :birth_day, input_html: {style: "width:3em"}%></td>
|
||||
<td><%=f.input :birth_month, input_html: {style: "width:3em"} %></td>
|
||||
<td><%=f.input :birth_year, input_html: {style: "width:5em"} %></td>
|
||||
</tr></table>
|
||||
|
||||
</div>
|
||||
<% end %>
|
||||
<% end %> <% end %>
|
||||
|
||||
|
||||
<%=f.input :instant %>
|
||||
<%=f.input :skype %>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div id="memberships_form_list">
|
||||
<% @memberships.each do |m| %>
|
||||
<%= render partial:"membership_fields", object: m , locals: {:f=>f} %>
|
||||
<% end %>
|
||||
</div>
|
||||
|
||||
<% end %>
|
||||
<div class="row-fluid">
|
||||
<div class="span12">
|
||||
<%= f.actions do %>
|
||||
<%= f.action :submit, :as => :input %>
|
||||
<%= f.action :submit, :as => :button, :label=>I18n.t("common.save") %>
|
||||
<%= f.action :submit, :as => :button, :label=>I18n.t("common.savecont"), :button_html=>{value: "continue"} %>
|
||||
<%= f.action :cancel, :as=> :link , :label=>I18n.t("common.cancel") %>
|
||||
<% end %>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
16
app/views/fetprofiles/_interninfo.html.erb
Normal file
16
app/views/fetprofiles/_interninfo.html.erb
Normal file
@@ -0,0 +1,16 @@
|
||||
<p>
|
||||
<b>Geburtstag</b> <%= %>
|
||||
</p>
|
||||
<p>
|
||||
<b>Adresse:</b>
|
||||
<%= interninfo.plz %>
|
||||
<%= interninfo.city %>,
|
||||
<%= interninfo.street %>
|
||||
</p>
|
||||
<p>
|
||||
<%= raw("<b>Telefon: </b>")+ interninfo.telnr + "<br>" unless (interninfo.telnr.nil? || interninfo.telnr.empty?) %>
|
||||
<%= raw("<b>Handy: </b>") +interninfo.hdynr unless interninfo.hdynr.nil? || interninfo.hdynr.empty? %><br>
|
||||
<%= raw("<b>Skype: </b>") +interninfo.skype unless interninfo.skype.nil? || interninfo.skype.empty? %><br>
|
||||
<%= raw("<b>Instant Messaging: </b>") +interninfo.instant unless interninfo.instant.nil? || interninfo.instant.empty? %><br>
|
||||
|
||||
</p>
|
||||
12
app/views/fetprofiles/_internrow.html.erb
Normal file
12
app/views/fetprofiles/_internrow.html.erb
Normal file
@@ -0,0 +1,12 @@
|
||||
<tr>
|
||||
<td> <%= link_to internrow.name, internrow %>
|
||||
</td>
|
||||
<td> <%= internrow.adress %></td>
|
||||
<td>
|
||||
<%= raw("Telefon: ")+ internrow.telnr + "<br>" unless internrow.telnr.nil? || internrow.telnr.empty?%>
|
||||
<%= raw("Handy: ") +internrow.hdynr + raw("<br>") unless internrow.hdynr.nil? || internrow.hdynr.empty? %>
|
||||
<%= raw("Skype: ") +internrow.skype + raw("<br>") unless internrow.skype.nil? || internrow.skype.empty? %>
|
||||
<%= raw("Instant Messaging: ") +internrow.instant + raw("<br>") unless internrow.instant.nil? || internrow.instant.empty? %>
|
||||
</td>
|
||||
<td><%= internrow.fetmail %></td>
|
||||
</tr>
|
||||
13
app/views/fetprofiles/_membership_fields.html.erb
Normal file
13
app/views/fetprofiles/_membership_fields.html.erb
Normal file
@@ -0,0 +1,13 @@
|
||||
<%= f.semantic_fields_for :memberships, membership_fields do |membership| %>
|
||||
<table><tr><td>
|
||||
<%= membership.input :start, :as=>:datepicker, :prepend=>"von",:label=>false , :input_html => { :style => "width:6em"} %>
|
||||
</td><td>
|
||||
<%= membership.input :stop, :as=>:datepicker,:label=>false, :prepend =>"bis" , :input_html => { :style => "width:6em"}%></td><td>
|
||||
|
||||
<%= membership.input :typ ,:as=>:select, :collection=>Membership::TYPEN.invert, :label=>false , :input_html => { :style => "width:12em" }%></td><td>
|
||||
|
||||
<%= membership.input :gremium, :label=>false %>
|
||||
</td><td>
|
||||
<%= membership.check_box :_destroy %> <%= I18n.t 'common.delete' %></td></tr></table>
|
||||
|
||||
<% end %>
|
||||
@@ -1,6 +1,7 @@
|
||||
<h1>Editing fetprofile</h1>
|
||||
<h1><%= I18n.t("fetprofile.edit")%></h1>
|
||||
|
||||
<%= render 'form' %>
|
||||
|
||||
<%= link_to 'Show', @fetprofile %> |
|
||||
<%= link_to 'Back', fetprofiles_path %>
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -6,9 +6,15 @@
|
||||
<%= I18n.t 'profile.active_members' if params[:filter].nil? || params[:filter]== "active"
|
||||
%>
|
||||
</h1>
|
||||
<div class="row-fluid">
|
||||
<div class="span12">
|
||||
<%= render 'layouts/pretty_toolbar' %>
|
||||
|
||||
<% link_to I18n.t('profile.new_profile'), new_fetprofile_path %>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<ul class="unstyled fetprofile_list linkbox-list" style="width:100%">
|
||||
|
||||
<% @fetprofiles.each do |fetprofile| %>
|
||||
|
||||
<li>
|
||||
@@ -39,11 +45,7 @@
|
||||
|
||||
</ul>
|
||||
|
||||
<div class="row-fluid">
|
||||
<div class="span12">
|
||||
<%= link_to I18n.t('profile.new_profile'), new_fetprofile_path %>
|
||||
</div>
|
||||
</div></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
5
app/views/fetprofiles/internlist.html.erb
Normal file
5
app/views/fetprofiles/internlist.html.erb
Normal file
@@ -0,0 +1,5 @@
|
||||
<table style="width:100%" class="table table-striped">
|
||||
<% @fetprofiles.each do |item| %>
|
||||
<%= render partial: "internrow", object: item %>
|
||||
<% end %>
|
||||
</table>
|
||||
@@ -2,4 +2,4 @@
|
||||
|
||||
<%= render 'form' %>
|
||||
|
||||
<%= link_to I18n.t('common.back'), fetprofiles_path %>
|
||||
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
<p>
|
||||
<%= @fetprofile.desc %>
|
||||
</p>
|
||||
|
||||
<%= render partial: "interninfo", object: @fetprofile if can?(:seeintern, @fetprofile) %>
|
||||
<ul>
|
||||
<% @memberships.each do |m| %>
|
||||
<li>
|
||||
|
||||
@@ -10,3 +10,5 @@
|
||||
<%= f.action :submit, :as => :input %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<%= tinymce :theme => "simple", :language => "de", :plugins => ["wordcount", "paste"] %>
|
||||
<% tinymce :compact %>
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
<p>
|
||||
<b> <%= frage.title %> </b> <br/>
|
||||
<b> <%= frage.title %>? </b> <br/>
|
||||
<%= raw(frage.text) %>
|
||||
<br/>
|
||||
|
||||
<%= link_to 'Edit', edit_frage_path(frage),:remote=>true %> |
|
||||
<%= link_to 'Destroy',frage, method: :delete, :remote=> true , data: { confirm: 'Are you sure?' } %>
|
||||
<%= link_to 'Edit', edit_frage_path(frage),:remote=>true %>
|
||||
<%= link_to 'Destroy',frage, method: :delete, :remote=> true , data: { confirm: I18n.t("frage.sure") } %>
|
||||
</p>
|
||||
|
||||
@@ -10,3 +10,4 @@
|
||||
<%= f.action :submit, :as => :input %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<%= tinymce :menubar=>false %>
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
<h1><%= I18n.t('fotos.galleries')%></h1>
|
||||
<%= render :partial => 'layouts/pretty_toolbar' %>
|
||||
<% @galleries.each_slice(2) do |row| %>
|
||||
<div class="row-fluid">
|
||||
<% row.each do |gallery| %>
|
||||
@@ -37,4 +38,3 @@
|
||||
<% end %>
|
||||
|
||||
<br />
|
||||
<%= render :partial => 'layouts/pretty_toolbar' %>
|
||||
|
||||
@@ -5,41 +5,41 @@
|
||||
<%= f.input :typ, :as => :select, :collection => Gremium::TYPEN.invert %>
|
||||
<%= f.input :geschlecht, :as => :select, :collection => Gremium::GESCHLECHT.invert %>
|
||||
<%= f.input :thema, :as=> :select, :collection => Thema.all %>
|
||||
|
||||
|
||||
<% f.inputs :for => :memberships, :objects=>@memberships do |membership,i| %>
|
||||
<div class="row-fluid">
|
||||
<div class="span1"></div>
|
||||
<div class="span3"><%= membership.input :start, :as=>:datepicker, :prepend=>"von",:label=>false%></div>
|
||||
<div class="span3"><%= membership.input :stop, :as=>:datepicker,:label=>false, :prepend =>"bis" %></div>
|
||||
<div class="span2"><%= membership.input :typ ,:as=>:select, :collection=>Membership::TYPEN.invert, :label=>false %></div>
|
||||
<div class="span3"><%= membership.input :fetprofile, :as=>:select, :label=>false %></div>
|
||||
|
||||
|
||||
</div>
|
||||
<% end %>
|
||||
|
||||
|
||||
<% @memberships.each do |m| %>
|
||||
|
||||
<% @memberships.each do |m| %>
|
||||
<%= f.semantic_fields_for :memberships, m do |memberships_attributes| %>
|
||||
<div class="row-fluid">
|
||||
<div class="span1"></div>
|
||||
<div class="span3"><%= memberships_attributes.input :start, :as=>:datepicker, :prepend=>"von",:label=>false%></div>
|
||||
<div class="span3"><%= memberships_attributes.input :stop, :as=>:datepicker,:label=>false, :prepend =>"bis" %></div>
|
||||
<div class="span2"><%= memberships_attributes.input :typ ,:as=>:select, :collection=>Membership::TYPEN.invert, :label=>false %></div>
|
||||
<div class="span3"><%= memberships_attributes.input :fetprofile, :as=>:select, :label=>false %></div>
|
||||
|
||||
|
||||
<div class="span11">
|
||||
<table>
|
||||
<tr><td><%= memberships_attributes.input :start, :as=>:datepicker, :prepend=>"von",:label=>false , :input_html => { :style => "width:6em" } ,:value=>Proc.new { |c| I18n.l(c) }%>
|
||||
</td>
|
||||
<td>
|
||||
<%= memberships_attributes.input :stop, :as=>:datepicker,:label=>false, :prepend =>"bis" , :input_html => { :style => "width:6em"},:value_method=>Proc.new { |c| I18n.l(c) }%>
|
||||
</td>
|
||||
<td>
|
||||
<%= memberships_attributes.input :typ ,:as=>:select, :collection=>Membership::TYPEN.invert, :label=>false, :input_html => { :style => "width:12em" } %>
|
||||
</td>
|
||||
<td><%= memberships_attributes.input :fetprofile, :as=>:select, :label=>false %></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<% end %>
|
||||
<% end %>
|
||||
|
||||
<% end %>
|
||||
<% end %>
|
||||
|
||||
<%= f.actions do %>
|
||||
<%= f.action :submit, :as => :input %>
|
||||
<%= f.action :submit, :as => :button, :label=>I18n.t("common.savecont"), :button_html=>{value: "continue"} %>
|
||||
<%= f.action :cancel, :as=> :link , :label=>I18n.t("common.cancel") %>
|
||||
|
||||
<% end %>
|
||||
<% end %>
|
||||
<script>$('.datepicker').datepicker()</script>
|
||||
<%= tinymce %>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
<h1>Listing gremien</h1>
|
||||
<%= render 'layouts/pretty_toolbar' %>
|
||||
<div class="container-fluid">
|
||||
<% @gremien.each do |gremium| %>
|
||||
<div class="row-fluid">
|
||||
<div class="span2">
|
||||
<%= gremium.typ %>
|
||||
<%= Gremium::TYPEN[gremium.typ.to_i] %>
|
||||
</div>
|
||||
<div class="span8">
|
||||
<b><%= gremium.name %></b>
|
||||
<%= gremium.desc %>
|
||||
</div>
|
||||
<div class="span2">
|
||||
<div class="btn-group">
|
||||
@@ -17,10 +17,9 @@
|
||||
<span class="caret"></span>
|
||||
</button>
|
||||
<ul class="dropdown-menu">
|
||||
<li>
|
||||
<%= link_to 'Show', gremium %></li>
|
||||
<li> <%= link_to 'Edit', edit_gremium_path(gremium) %></li>
|
||||
<li> <%= link_to 'Destroy', gremium, method: :delete, data: { confirm: 'Are you sure?' }, class:"btn-danger" %>
|
||||
<li><%= link_to 'Show', gremium %></li>
|
||||
<li><%= link_to 'Edit', edit_gremium_path(gremium) %></li>
|
||||
<li><%= link_to 'Destroy', gremium, method: :delete, data: { confirm: 'Are you sure?' }, class:"btn-danger" %>
|
||||
</li> </ul>
|
||||
</div>
|
||||
</div>
|
||||
@@ -38,7 +37,7 @@
|
||||
</table>
|
||||
|
||||
<br />
|
||||
<%= render 'layouts/pretty_toolbar' %>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1,21 +1,16 @@
|
||||
<div class="contentbox">
|
||||
<div class="row-fluid">
|
||||
|
||||
<div class="span8">
|
||||
<h4>Neueste Beispiele in unserer Sammlung</h4>
|
||||
<h4><%= I18n.t("home.newexamples") %></h4>
|
||||
</div>
|
||||
<div class="span4">
|
||||
<%= link_to I18n.t("beispiel.add"), new_beispiel_path, :class=>"btn"%>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
<ul class="unstyled linkbox-list">
|
||||
<% @beispiele.each do |b| %>
|
||||
<li>
|
||||
<%= link_to b, {:class=> :linkbox} do %>
|
||||
<%= link_to b.lva, {:class=> :linkbox} do %>
|
||||
<div class="row-fluid">
|
||||
<div class="span8">
|
||||
<b><%=b.name%></b> (<%=b.lva.full_name%>)
|
||||
|
||||
@@ -27,12 +27,16 @@
|
||||
<h2>Themen</h2>
|
||||
<% end %>
|
||||
|
||||
<% @themen.each do |thema| %>
|
||||
<ul class="unstyled content-list" style="max-width:70em">
|
||||
|
||||
<% @themen.each do |thema| %>
|
||||
<% if can? :show, thema %>
|
||||
<li><%= link_to thema.title,thema %>
|
||||
<div class="contentbox">
|
||||
<%= render :partial=>"themen/small", :object=>thema %>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
<% end %>
|
||||
|
||||
<% end %>
|
||||
</ul>
|
||||
|
||||
12
app/views/home/admin.html.erb
Normal file
12
app/views/home/admin.html.erb
Normal file
@@ -0,0 +1,12 @@
|
||||
<p><%= link_to "Grant extra FB privileges", user_omniauth_authorize_path(:facebook,:params=>{scope:"manage_pages,publish_actions,email"}) %>
|
||||
</p>
|
||||
<p>
|
||||
<%= link_to "user", users_path %>
|
||||
</p>
|
||||
<p>
|
||||
<%= @fbu.to_yaml.to_s %>
|
||||
|
||||
<%= semantic_form_for :set_page, url: fb_set_default_publish_page_user_path(current_user), html:{method: :get} do |f| %>
|
||||
<%= f.input :page , :input_html => { :name => 'page' }%>
|
||||
<% end %>
|
||||
</p>
|
||||
@@ -1,31 +0,0 @@
|
||||
<h1>Entwicklungsprojekt</h1>
|
||||
<%= link_to "notimplemented", home_linksnotimplemented_path %>
|
||||
<h2>Feature List: 2013-07-17</h2>
|
||||
<ul>
|
||||
<li>Info zu Studien/Studienpläne</li>
|
||||
<li>Info zu LVAs</li>
|
||||
<li>Beispielsammlung</li>
|
||||
<li>Kalender</li>
|
||||
<li>Events</li>
|
||||
<li>Termine</li>
|
||||
<li>Fotos</li>
|
||||
<li>FET Mitarbeiter</li>
|
||||
<li>Personen Profile (TISS?)</li>
|
||||
<li>News</li>
|
||||
<li>Gremien - Mitgliedschaften</li>
|
||||
<li>Börse (JOBs) Sitzungsbeschluss:Derzeit Nein</li>
|
||||
<li>Lost&Found </li>
|
||||
<li>FAQ</li>
|
||||
<li>Informationen (ZB Auslandssemester, Anfänerinfo</li>
|
||||
<li>Impressum</li>
|
||||
<li>Linksammlung</li>
|
||||
<li>Fetzn</li>
|
||||
<li>FET Sitzungstops</li>
|
||||
</ul>
|
||||
<h2>Testfeatures</h2>
|
||||
<b>Neuigkeiten</b>
|
||||
<p>Wichtige Punkte die noch entwickelt werden sind: <ul><li>Verwaltung bestehender Nachrichten</li><li>Facebook Interface</li></ul></p>
|
||||
<p><%= link_to "Neuigkeiten", rubriken_path %></p>
|
||||
|
||||
<p><b>Wiki</b></p>
|
||||
<p></p>
|
||||
@@ -5,7 +5,7 @@
|
||||
<li><%= render n if can?(:show, n) %> </li>
|
||||
<% end %>
|
||||
</ul>
|
||||
<p>
|
||||
<p><i class="ffi1-bar1 ffi1"></i>
|
||||
<%= link_to I18n.t('home.login'), user_omniauth_authorize_path(:ldap) %>
|
||||
</p>
|
||||
<div class="alert">
|
||||
@@ -23,14 +23,11 @@
|
||||
<p><%= link_to "Steuerelemente und Komponenten", "http://getbootstrap.com/2.3.2/index.html" %></p>
|
||||
<p>Um bei der Entwicklung mitzuhelfen braucht nur Ruby on Rails installiert werden</p>
|
||||
<p><%= link_to "Getting Started" , startdev_home_index_path %></p>
|
||||
<p> Das Kalender Feature wird überarbeitet, in Zukunft soll folgender Link nicht mehr funktionieren <%= link_to "Kalender", calendars_path %>
|
||||
</p>
|
||||
|
||||
</div>
|
||||
<%= link_to "Entwicklungsstatus" , dev_home_index_path %>
|
||||
<%= render 'beispiele' %>
|
||||
|
||||
Verschiedene Styles
|
||||
<%= I18n.t("home.selectstyle") %>
|
||||
<ul>
|
||||
<li> <%= link_to "Darkblue", home_index_path({:theme=>"darkblue"}) %></li>
|
||||
<li> <%= link_to "Blue1", home_index_path({:theme=>"blue1"}) %></li>
|
||||
|
||||
@@ -1,10 +1,34 @@
|
||||
<h1> FET Intern NEU </h1>
|
||||
<h2>Neuigkeiten</h2>
|
||||
<ul class="unstyled linkbox-list" style="max-width:70em">
|
||||
<% @neuigkeiten.each do |n| %>
|
||||
<li><%= render n if can?(:show, n) %> </li>
|
||||
<% end %>
|
||||
<div class="container-fluid">
|
||||
<div class="row-fluid">
|
||||
<div class="span6">
|
||||
<ul class="linklist">
|
||||
<li>
|
||||
<%= link_to "Adressliste", internlist_fetprofiles_path ,class: :linkbox %></li>
|
||||
<li> <%= link_to "Admin" , admin_home_index_path, class: :linkbox if current_user.has_role?(:fetadmin) %>
|
||||
</li>
|
||||
</ul>
|
||||
<ul class="unstyled linkbox-list">
|
||||
<li>
|
||||
<% @themengruppen.each do |themengruppe| %>
|
||||
<div class="container-fluid">
|
||||
<%= render themengruppe if can?(:show,themengruppe)%>
|
||||
</div>
|
||||
<% end %>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<%= link_to "Users", users_path %>
|
||||
</div>
|
||||
<div class="span6">
|
||||
<h2>Neuigkeiten</h2>
|
||||
<ul class="unstyled linkbox-list">
|
||||
<% @neuigkeiten.each do |n| %>
|
||||
<li><%= render n if can?(:show, n) %></li>
|
||||
<% end %>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<h2></h2>
|
||||
|
||||
|
||||
@@ -1,10 +1,12 @@
|
||||
<div class="content-column content-wrap">
|
||||
<h1>Kontakt</h1>
|
||||
<h1> <%= I18n.t "kontakt.H1" %></h1>
|
||||
<p>
|
||||
<%= I18n.t "home.kontakt" %>
|
||||
<%= I18n.t "kontakt.text" %>
|
||||
</p>
|
||||
<h2>Service</h2>
|
||||
<h2><%= I18n.t "kontakt.service" %></h2>
|
||||
<%= raw(I18n.t( "kontakt.service_text")) %>
|
||||
<h2><%= I18n.t "kontakt.adresse" %></h2>
|
||||
<p><%= raw(I18n.t("kontakt.adresse_text")) %></p>
|
||||
<p><%= raw(I18n.t ("kontakt.telefon_text")) %></p>
|
||||
|
||||
<h2>Impressum</h2>
|
||||
<h2>Credits</h2>
|
||||
</div>
|
||||
|
||||
@@ -5,6 +5,7 @@ Verwendung: Aufruf mit
|
||||
|
||||
-->
|
||||
<% toolbar_elements = !pretty_toolbar.nil? ? pretty_toolbar : @toolbar_elements %>
|
||||
<% unless toolbar_elements.nil? || toolbar_elements.empty? %>
|
||||
<span class="label"><%= I18n.t("common.actions")%></span>
|
||||
<div class="btn-group">
|
||||
<% toolbar_elements.each do |t| %>
|
||||
@@ -14,10 +15,10 @@ Verwendung: Aufruf mit
|
||||
<% else %>
|
||||
<div class="btn-group">
|
||||
<a class="btn dropdown-toggle" data-toggle="dropdown" href="#">
|
||||
Versionen<span class="caret"></span>
|
||||
<%= I18n.t("common.versions") %><span class="caret"></span>
|
||||
</a>
|
||||
<ul class="dropdown-menu">
|
||||
<li> <%= link_to "active", t[:path] %>
|
||||
<li> <%= link_to I18n.t("common.activeversion"), t[:path] %>
|
||||
</li>
|
||||
<% t[:versions].each_with_index do |v,i| %>
|
||||
<li>
|
||||
@@ -37,3 +38,4 @@ Verwendung: Aufruf mit
|
||||
<% end %>
|
||||
<% end %>
|
||||
</div>
|
||||
<% end %>
|
||||
|
||||
@@ -3,25 +3,17 @@
|
||||
|
||||
<head>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<link rel="shortcut icon" href="./public/favicon.ico">
|
||||
<link rel="shortcut icon" href="http://glonass.htu.tuwien.ac.at/favicon.ico">
|
||||
<!--<link rel="shortcut icon" href="http://www.fet.at/favicon.ico">-->
|
||||
<title>Fetsite</title>
|
||||
|
||||
|
||||
<%= stylesheet_link_tag "themes/"+theme_name+"/application", :media => "all" unless theme_name.empty? %>
|
||||
<%= stylesheet_link_tag "application", :media=>"all" if theme_name.empty? %>
|
||||
<%= theme_stylesheet_link_tag "test", :media => "all" %>
|
||||
<% theme_stylesheet_link_tag "test", :media => "all" %>
|
||||
<% theme_stylesheet_link_tag "mod", :media=>"all" %>
|
||||
<!-- <link rel="stylesheet" href="css/bootstrap.css">
|
||||
<link rel="stylesheet" href="css/style.css">
|
||||
<link rel="stylesheet" href="css/bootstrap-responsive.css">
|
||||
<link rel="stylesheet" href="css/bootstrap-image-gallery.css">
|
||||
-->
|
||||
<!--[if lt IE 7]><link rel="stylesheet" href="css/bootstrap-ie6.css"><![endif]-->
|
||||
|
||||
<%= javascript_include_tag "application" %>
|
||||
<%= csrf_meta_tags %>
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
@@ -29,10 +21,13 @@
|
||||
<div class="row-fluid">
|
||||
<div class="span1 "></div>
|
||||
<div class="span10 ">
|
||||
<div class="header_wrap" style="background:7070a0">
|
||||
<div class="header_wrap">
|
||||
<div class="header">
|
||||
<%= link_to image_tag('/fetlogo90.png',{:style=>"float:left;height:50px",:height=>"50"}),home_index_path %>
|
||||
<h1 style="display:block"></h1>
|
||||
<% link_to image_tag('/fetlogo90.png',{:style=>"float:left;height:50px",:height=>"50"}),home_index_path %>
|
||||
<%= link_to home_index_path do %>
|
||||
<span class="feticon-fet_logo fa-4x color-1"> </span>
|
||||
<% end %>
|
||||
|
||||
</div>
|
||||
|
||||
<div id="menudiv" style="margin-top:12px">
|
||||
|
||||
@@ -23,8 +23,7 @@
|
||||
<li>
|
||||
<%= link_to 'Intern' , intern_home_index_path %>
|
||||
</li><% end %>
|
||||
</ul>
|
||||
<ul class="nav navbar-nav">
|
||||
|
||||
<li class="dropdown">
|
||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown"><%= image_tag("/flaggen/png/"+I18n.locale.to_s+".png") + " " +I18n.t('sprache',:scope=>'home')%><b class="caret"></b></a>
|
||||
<ul class="dropdown-menu">
|
||||
|
||||
@@ -20,6 +20,10 @@
|
||||
<%= f.input :ects, :wrapper_html=>{:class=>'span4'} %>
|
||||
<%= f.input :stunden, :wrapper_html=>{:class=>'span4'} %>
|
||||
</div>
|
||||
|
||||
<div class="row-fluid">
|
||||
<%= f.input :forumlink, :wrapper_html=>{:class=>'span12'}%>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -28,7 +32,8 @@
|
||||
<%= f.input :desc , :as=>:tinymce_text %>
|
||||
<%= f.input :pruefungsinformation %>
|
||||
<%= f.input :lernaufwand %>
|
||||
</div></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="span3">
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<p id="notice"><%= notice %></p>
|
||||
|
||||
<h1><%=lva.typ.to_s + ' ' + lva.name %></h1>
|
||||
<h1><%= lva.typ_n.to_s + ' ' + lva.name %></h1>
|
||||
<h2>Prüfungsinformation</h2>
|
||||
<div class="">
|
||||
<%= lva.pruefungsinformation.to_s.html_safe %>
|
||||
|
||||
@@ -3,11 +3,14 @@
|
||||
<p id="notice"><%= notice %></p>
|
||||
<div class="row-fluid">
|
||||
<div class="span8">
|
||||
<h1><%=@lva.typ.to_s + ' ' + @lva.name %></h1>
|
||||
<h1><%= @lva.full_name %></h1>
|
||||
<ul class="linklist">
|
||||
<li><%= link_to ffi1_icon("live2")+"ET-Forum",@lva.forumlink, class: :linkbox unless @lva.forumlink.nil? or @lva.forumlink.empty?%></li>
|
||||
</ul>
|
||||
|
||||
<h2>Prüfungsinformation</h2>
|
||||
<div class="">
|
||||
<%= @lva.pruefungsinformation.html_safe %>
|
||||
<%= @lva.pruefungsinformation.to_s.html_safe %>
|
||||
</div>
|
||||
|
||||
<h2>Lernaufwand</h2>
|
||||
@@ -19,10 +22,6 @@
|
||||
<%= @lva.desc.to_s.html_safe %>
|
||||
</div>
|
||||
|
||||
<h2>Beispiele</h2>
|
||||
<% @lva.beispiele.each do |b| %>
|
||||
<%= render b%>
|
||||
<% end %>
|
||||
|
||||
|
||||
</div>
|
||||
@@ -57,6 +56,17 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row-fluid">
|
||||
<div class="span12">
|
||||
|
||||
<h2>Beispiele</h2>
|
||||
<%= link_to t("beispiel.zip") , beispiel_sammlung_lva_path(@lva), class: :linkbox %>
|
||||
<% @lva.beispiele.each do |b| %>
|
||||
<%= render b%>
|
||||
<% end %>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row-fluid">
|
||||
<div class="span12">
|
||||
<% unless @lva.nlinks.empty? %>
|
||||
|
||||
@@ -1,12 +0,0 @@
|
||||
<%= semantic_form_for [@membership.fetprofile,@membership] do |f| %>
|
||||
<%= f.inputs do %>
|
||||
<%= f.input :gremium, :as=>:radio %>
|
||||
<%= f.input :start %>
|
||||
<%= f.input :stop %>
|
||||
<%= f.input :typ ,:as=>:radio,:collection=>Membership::TYPEN.invert %>
|
||||
<% end %>
|
||||
|
||||
<%= f.actions do %>
|
||||
<%= f.action :submit, :as => :input %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
@@ -1,6 +1,6 @@
|
||||
|
||||
<%= membership.stop.nil? ? "seit " : "von " %>
|
||||
<%= membership.stop.nil? ? I18n.t("gremium.seit")+" " : I18n.t("gremium.von")+" " %>
|
||||
<%=membership.start.to_s %>
|
||||
<%= " bis "+membership.stop.to_s unless membership.stop.nil? %>
|
||||
<%= Membership::TYPEN[membership.typ.to_i] %>
|
||||
<%= " "+I18n.t("gremium.bis")+" "+membership.stop.to_s unless membership.stop.nil? %>
|
||||
<%= Membership::TYPEN_g[membership.fetprofile.geschlecht.to_i][membership.typ.to_i] %>
|
||||
<%= membership.gremium.fall2 %>
|
||||
|
||||
@@ -1,6 +0,0 @@
|
||||
<h1>Editing membership</h1>
|
||||
|
||||
<%= render 'form' %>
|
||||
|
||||
<%= link_to 'Show', @membership %> |
|
||||
<%= link_to 'Back', memberships_path %>
|
||||
@@ -1,31 +0,0 @@
|
||||
<h1>Listing memberships</h1>
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<th>Fetprofile</th>
|
||||
<th>Gremium</th>
|
||||
<th>Start</th>
|
||||
<th>Stop</th>
|
||||
<th>Typ</th>
|
||||
<th></th>
|
||||
<th></th>
|
||||
<th></th>
|
||||
</tr>
|
||||
|
||||
<% @memberships.each do |membership| %>
|
||||
<tr>
|
||||
<td><%= membership.fetprofile_id %></td>
|
||||
<td><%= membership.gremium_id %></td>
|
||||
<td><%= membership.start %></td>
|
||||
<td><%= membership.stop %></td>
|
||||
<td><%= membership.typ %></td>
|
||||
<td><%= link_to 'Show', membership %></td>
|
||||
<td><%= link_to 'Edit', edit_membership_path(membership) %></td>
|
||||
<td><%= link_to 'Destroy', membership, method: :delete, data: { confirm: 'Are you sure?' } %></td>
|
||||
</tr>
|
||||
<% end %>
|
||||
</table>
|
||||
|
||||
<br />
|
||||
|
||||
<%= link_to 'New Membership', new_membership_path %>
|
||||
@@ -1,5 +0,0 @@
|
||||
<h1>New membership</h1>
|
||||
|
||||
<%= render 'form' %>
|
||||
|
||||
<%= link_to 'Back', @membership.fetprofile %>
|
||||
@@ -1,30 +0,0 @@
|
||||
<p id="notice"><%= notice %></p>
|
||||
|
||||
<p>
|
||||
<b>Fetprofile:</b>
|
||||
<%= @membership.fetprofile_id %>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
<b>Gremium:</b>
|
||||
<%= @membership.gremium_id %>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
<b>Start:</b>
|
||||
<%= @membership.start %>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
<b>Stop:</b>
|
||||
<%= @membership.stop %>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
<b>Typ:</b>
|
||||
<%= @membership.typ %>
|
||||
</p>
|
||||
|
||||
|
||||
<%= link_to 'Edit', edit_membership_path(@membership) %> |
|
||||
<%= link_to 'Back', memberships_path %>
|
||||
@@ -1,10 +1,8 @@
|
||||
<h1><%= I18n.t("modulgruppe.show.title")%></h1>
|
||||
|
||||
|
||||
<% @modulgruppen.sort_by{|n| n[:name]}.each do |modulgruppe| %>
|
||||
<%= render modulgruppe%>
|
||||
<% end %>
|
||||
<br>
|
||||
<% if !@studium.nil? %>
|
||||
<%= link_to 'New Modulgruppe', new_studium_modulgruppe_path(@studium) %>
|
||||
<%= link_to I18n.t("modulgruppe.new"), new_studium_modulgruppe_path(@studium) if can? :new, Modulgruppe %>
|
||||
<% end%>
|
||||
|
||||
@@ -6,8 +6,8 @@
|
||||
</div>
|
||||
<div class="media-body">
|
||||
<div>
|
||||
<small><%= neuigkeit.rubrik.name %></small>
|
||||
<small class="pull-right"> <%= "am "+ I18n.l(neuigkeit.try(:datum).try(:to_date)) unless neuigkeit.try(:datum).try(:to_date).nil? %></small>
|
||||
<small><%= ff_icon(neuigkeit.rubrik.icon) unless neuigkeit.rubrik.icon.nil? or neuigkeit.rubrik.icon.empty? %> <%= neuigkeit.rubrik.name %></small>
|
||||
<small class="pull-right"> <%= I18n.t("neuigkeit.am")+" "+ I18n.l(neuigkeit.try(:datum).try(:to_date)) unless neuigkeit.try(:datum).try(:to_date).nil? %></small>
|
||||
</div>
|
||||
<h1>
|
||||
<%= neuigkeit.title%>
|
||||
|
||||
@@ -1,14 +1,14 @@
|
||||
<%= tinymce_assets %>
|
||||
<div class="container-fluid">
|
||||
<%= semantic_form_for [@neuigkeit.rubrik,@neuigkeit] do |f| %>
|
||||
<%= semantic_form_for [@neuigkeit.rubrik,@neuigkeit] do |f| %>
|
||||
<%= f.inputs do %>
|
||||
<div class="row-fluid">
|
||||
<div class="span12">
|
||||
<div class="row-fluid">
|
||||
<div class="span12">
|
||||
<%= f.input :title, :placeholder=> "Titel" %>
|
||||
<%= f.input :text, :as=> :tinymce_text %>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row-fluid">
|
||||
</div>
|
||||
</div>
|
||||
<div class="row-fluid">
|
||||
<div class="span6">
|
||||
<% f.input :datum, :as=> :datepicker %>
|
||||
<%= f.input :rubrik, :as=> :radio, :collection=>Rubrik.all %>
|
||||
@@ -16,22 +16,25 @@
|
||||
<div class="span6">
|
||||
<%= f.input :author, :as=> :select %>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row-fluid">
|
||||
</div>
|
||||
<div class="row-fluid">
|
||||
<div class="span12">
|
||||
<%= f.input :picture, :as=> :file %>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<%= f.semantic_fields_for :calentries , @calentries do |calentry| %>
|
||||
<%= render 'calentries/nested_fields', :f => calentry %>
|
||||
<%= f.semantic_fields_for :calentries , @calentries do |calentry| %>
|
||||
<%= render 'calentries/nested_fields', :f => calentry %>
|
||||
<% end %>
|
||||
|
||||
<% end %>
|
||||
<%= f.actions do %>
|
||||
<%= f.action :submit, :as => :input %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
</div>
|
||||
<script>$('.datepicker').datepicker()</script>
|
||||
<script>
|
||||
$(document).ready(function(){
|
||||
$('.datetimepicker').map($(this).datetimepicker({format: 'd.m.Y H:i', startDate: (!($(this).attr("value")==undefined))? $(this).attr("value"): ""}))
|
||||
})</script>
|
||||
<%= tinymce %>
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
|
||||
<%= link_to [neuigkeit.rubrik,neuigkeit], {class: :linkbox} do %>
|
||||
<% c =[:linkbox] %>
|
||||
<% c << "color-"+neuigkeit.rubrik.color.to_s+"-dark" unless neuigkeit.rubrik.color.nil? %>
|
||||
<%= link_to [neuigkeit.rubrik,neuigkeit], {class: c} do %>
|
||||
<%= render :partial=>"neuigkeiten/compact",:locals=> {:neuigkeit=> neuigkeit} %>
|
||||
<% end %>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<li>
|
||||
<li>
|
||||
<%= link_to nlink_list.link do %>
|
||||
<div class="contentbox" >
|
||||
<% p = nlink_list.link_type.downcase.pluralize+"/nlink" %>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
|
||||
<li>
|
||||
<%= link_to nlink_list_search.title, nlink_list_search %>
|
||||
<%= link_to "add:"+nlink_list_search.title, create_link_rubrik_neuigkeit_path(@neuigkeit.rubrik,@neuigkeit, :link_id=>nlink_list_search.id, :link_type=>nlink_list_search.class.to_s) %>
|
||||
<%= link_to "add:"+nlink_list_search.title, create_link_rubrik_neuigkeit_path(@neuigkeit.rubrik,@neuigkeit, :link_id=>nlink_list_search.id, :link_type=>nlink_list_search.class.to_s) %>
|
||||
<div class="contentbox" >
|
||||
<% p = nlink_list_search.class.to_s.downcase.pluralize+"/nlink" %>
|
||||
<%= render :partial=>p, :object=>nlink_list_search %>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<h1>Editing neuigkeit</h1>
|
||||
<h1><%= I18n.t("neuigkeit.edit") %></h1>
|
||||
<%= %>
|
||||
<%= render 'form' %>
|
||||
<%= render 'layouts/pretty_toolbar' %>
|
||||
|
||||
@@ -3,11 +3,11 @@
|
||||
<p id="notice"><%= notice %></p>
|
||||
<div class="contentbox">
|
||||
<span>
|
||||
<%= @neuigkeit.rubrik.name %>
|
||||
<%= ff_icon(@neuigkeit.rubrik.icon) unless @neuigkeit.rubrik.icon.nil? or @neuigkeit.rubrik.icon.empty? %> <%= @neuigkeit.rubrik.name %>
|
||||
</span>
|
||||
<span class="pull-right">
|
||||
<%= @neuigkeit.author.email.to_s unless @neuigkeit.try(:author).try(:email).to_s %>
|
||||
<%= @neuigkeit.author.text+ " am " + I18n.l(@neuigkeit.try(:datum).try(:to_date)) unless @neuigkeit.try(:datum).try(:to_date).nil? %>
|
||||
<%= @neuigkeit.author.text+ " "+ I18n.t("neuigkeit.am")+" " + I18n.l(@neuigkeit.try(:datum).try(:to_date)) unless @neuigkeit.try(:datum).try(:to_date).nil? %>
|
||||
</span>
|
||||
<div class="media">
|
||||
<div class="pull-left" href="#">
|
||||
@@ -17,7 +17,6 @@
|
||||
<div class="media-body">
|
||||
<h1>
|
||||
<%= @neuigkeit.title%>
|
||||
|
||||
</h1>
|
||||
<%= raw(@neuigkeit.text) %>
|
||||
<p></p>
|
||||
@@ -29,7 +28,7 @@
|
||||
<%= render 'layouts/pretty_toolbar', :object=> @toolbar_elements %>
|
||||
</div>
|
||||
|
||||
Siehe auch:
|
||||
<%= I18n.t("neuigkeit.sieheauch") %>
|
||||
<ul class="unstyled">
|
||||
<div id="nlink_list">
|
||||
<%= render partial: "nlink_list", collection: @neuigkeit.nlinks %>
|
||||
@@ -38,9 +37,9 @@ Siehe auch:
|
||||
<%= render partial: "nlink_list_search", collection: @nlink_search %>
|
||||
</div>
|
||||
</ul>
|
||||
|
||||
<% if can? :find_link, @neuigkeit %>
|
||||
<%= semantic_form_for :find_link, :url=>find_link_rubrik_neuigkeit_path(@rubrik,@neuigkeit), :html=>{:id=>"search_form", :method=>'get'} do |f| %>
|
||||
<%= f.input :query, :input_html => { :name => 'query' },:label=>false %>
|
||||
<% end %>
|
||||
|
||||
<% end %>
|
||||
</div>
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user