251 Commits

Author SHA1 Message Date
f52ec0411d gremium und studien factory und specs 2019-01-13 15:13:31 +01:00
92d63b71ed neuigkeit factory small fix 2019-01-13 13:35:06 +01:00
30cbe8923f neuigkeit controller spec 2019-01-13 13:24:00 +01:00
1b15fdf385 very small fix for neuigkeit controller 2019-01-13 10:12:01 +01:00
d7c8342817 additional neuigkeit test 2019-01-13 10:11:25 +01:00
71d14c83ae rewriting some factories 2019-01-13 10:01:22 +01:00
fea219ba92 forst neuigkeit controller spec 2019-01-07 23:32:23 +01:00
1b065cd3f0 nes neuigkeiten model specs 2019-01-07 23:31:55 +01:00
67bfa0f699 Merge branch 'master' into prep_upgrade 2019-01-05 16:20:37 +01:00
ff20774889 improve tests for lva 2019-01-05 16:18:30 +01:00
f7f8937197 started increasing test coverage for lva 2019-01-05 02:56:47 +01:00
c713fdd0d0 ignore coverage folder 2019-01-05 02:56:08 +01:00
bc8f4cfce3 small fixes for neuigkeit spec 2019-01-05 02:55:35 +01:00
5759ba79e0 increase test coverage for meetings 2019-01-05 02:54:50 +01:00
70e415446a simplecov added to determine test coverage 2019-01-05 02:53:04 +01:00
82cd127370 Remove generated documentation from version control 2019-01-02 18:52:35 +01:00
72e18f9e29 generated documentation 2019-01-01 19:04:08 +01:00
e873916095 no longer ignore Gemfile.lock and adding Gemfile.lock 2018-12-30 09:33:19 +01:00
6ebb36d840 no longer ignore Gemfile.lock 2018-12-30 09:32:28 +01:00
f6c3cda045 fixes in fotogallery 2018-12-29 01:04:16 +01:00
a20c6fa673 Corrected solr config + minor bugfixes 2018-09-17 12:05:47 +02:00
Andreas Stephanides
52ffe0c701 added developer login strategy for testing 2018-06-02 12:01:18 +02:00
Andreas Stephanides
52fcabf2dc fix login menu 2018-05-26 08:52:26 +02:00
Andreas Stephanides
c03a60c236 developer login added 2018-05-26 08:50:54 +02:00
1cf84c90ae test 2018-05-20 23:35:38 +02:00
2e732561e8 infoscreenframe 2018-05-20 23:29:34 +02:00
a8f353f213 fixes for production Gemfile 2018-05-20 22:21:34 +02:00
6ba20206ab Merge remote-tracking branch 'origin/stable-production' into stable-production 2018-05-20 21:31:56 +02:00
Andreas Stephanides
2ae99b4b9e remove http header language detection 2018-05-20 21:20:43 +02:00
Andreas Stephanides
f61681c5d0 moved views from theme blue2 to default removed override by theme 2018-05-20 21:18:37 +02:00
1b91d99b24 Merge remote-tracking branch 'origin/master' into stable-production 2018-05-14 21:14:40 +02:00
28906eb5fb write True small 2018-05-14 21:13:42 +02:00
745c4413f4 fix the solr path for production 2018-05-14 21:00:17 +02:00
ac7e7f3462 Merge remote-tracking branch 'origin/master' into stable-production 2018-05-14 20:26:09 +02:00
e55a71e77d rake version set to 10 2018-05-14 20:26:04 +02:00
502aae5c27 merge latest 2018-05-14 20:17:30 +02:00
c2ebdcbefc merge master and stable 2018-05-14 19:58:17 +02:00
734a137563 testtmp 2018-05-14 18:55:37 +02:00
9f1de3d9d0 diverse hot fixes von der productive Version auf fetruby 2018-05-14 17:56:17 +02:00
Pet
0f683ac974 Found out the testrby is on Mogok ;) 2018-04-12 23:25:25 +02:00
Pet
5ffecf7087 Updated Lackis infoscreen layout 2018-04-12 22:48:20 +02:00
Pet
965db4dec0 Updated Lackis infoscreen layout 2018-04-12 22:45:00 +02:00
Pet
6aecb4b4a8 Updated Lackis infoscreen layout 2018-04-12 22:43:10 +02:00
Pet
b1616a6d6d Updated Lackis infoscreen layout 2018-04-12 22:39:48 +02:00
Pet
122bf6c6d4 Updated Lackis infoscreen layout 2018-04-12 22:37:00 +02:00
Pet
829bdb97be Updated Lackis infoscreen layout 2018-04-12 22:35:10 +02:00
Pet
6c91513ff8 Updated Lackis infoscreen layout 2018-04-12 22:33:00 +02:00
Pet
d1a496a017 Updated Lackis infoscreen layout 2018-04-12 22:29:34 +02:00
Pet
eb95f7a5e4 Updated Lackis infoscreen layout 2018-04-12 22:26:46 +02:00
Pet
de225627b1 Updated Lackis infoscreen layout 2018-04-12 22:20:44 +02:00
Pet
08aa459f57 Updated Lackis infoscreen layout 2018-04-12 22:16:06 +02:00
Pet
2b6890a6e6 Updated Lackis infoscreen layout 2018-04-12 22:14:55 +02:00
Pet
04ce26754a Updated Lackis infoscreen layout 2018-04-12 22:10:14 +02:00
Pet
163e1adfc2 Updated Lackis infoscreen layout 2018-04-12 22:04:47 +02:00
Pet
e5a5ec85ef Updated Lackis infoscreen layout 2018-04-12 22:02:50 +02:00
Pet
256d9f09fb Updated Lackis infoscreen layout 2018-04-12 21:58:19 +02:00
Pet
e3c6721811 Updated Lackis infoscreen layout 2018-04-12 21:55:05 +02:00
Pet
e5f0d75b79 Updated Lackis infoscreen layout 2018-04-12 21:47:07 +02:00
Pet
07bb853501 Updated Lackis infoscreen layout 2018-04-12 21:42:03 +02:00
Pet
af5b081a3b Updated Lackis infoscreen layout 2018-04-12 20:54:08 +02:00
Pet
24f3e90235 Updated Lackis infoscreen layout 2018-04-12 20:51:16 +02:00
Pet
ef1135962e Implemented Lackis infoscreen layout 2018-04-12 20:33:09 +02:00
Pet
22cf26f76c changed infoscreen layout 2018-03-28 16:06:52 +02:00
Pet
0c7614b41d removed the wrong login window 2018-03-27 23:09:18 +02:00
Pet
0fedeb2bde changed etherpad link 2018-03-27 22:03:17 +02:00
Pet
146885abae changed etherpad link 2018-03-27 22:01:20 +02:00
Pet
c38139d6f1 changed the etherpad url 2018-03-26 22:18:50 +02:00
ruby fuer rvm
8cb6ec785c no sunspot pid file 2018-03-10 07:10:03 +00:00
root
b8903c6d9a ignore pid files 2018-03-10 06:59:53 +00:00
Andreas Stephanides
242d05f4fa AutoCommit Mit Aug 23 10:03:01 CEST 2017 2017-08-23 10:03:01 +02:00
Andreas Stephanides
070e0dfedb fixing blue2 index 2017-07-27 09:23:02 +02:00
ruby
610e6ae3dd new design 2017-07-25 17:11:51 +02:00
Andreas Stephanides
6c4873d869 AutoCommit Die Jul 25 11:03:01 CEST 2017 2017-07-25 11:03:01 +02:00
Andreas Stephanides
09d5e7b880 Merge branch 'master' of https://git.triton.fet.at/git/fetsite 2017-07-25 10:21:50 +02:00
Andreas Stephanides
6b37d44c9a AutoCommit Die Jul 25 10:03:02 CEST 2017 2017-07-25 10:03:02 +02:00
peter
20088b868f added header image to infoscreen 2017-06-01 00:06:20 +02:00
peter
f1fbd3bef3 added header image to infoscreen 2017-05-31 23:58:38 +02:00
peter
17a43097e7 added header image to infoscreen 2017-05-31 23:55:56 +02:00
peter
3498535d8c added header image to infoscreen 2017-05-31 23:54:11 +02:00
peter
d313e712f1 added header image to infoscreen 2017-05-31 23:52:47 +02:00
peter
bb4adf2eb7 added header image to infoscreen 2017-05-31 23:47:38 +02:00
peter
09532fc74c added header image to infoscreen 2017-05-31 23:41:51 +02:00
peter
29d5c8dac7 added header image to infoscreen 2017-05-31 23:39:50 +02:00
peter
926431c0a2 added header image to infoscreen 2017-05-31 23:38:02 +02:00
peter
d95e1a3399 added header image to infoscreen 2017-05-31 23:35:58 +02:00
peter
d6fa4e1dc7 added header image to infoscreen 2017-05-31 23:27:07 +02:00
peter
6528e8a320 added header image to infoscreen 2017-05-31 23:24:35 +02:00
peter
18beead785 added header image to infoscreen 2017-05-31 23:16:34 +02:00
peter
3baf44c057 added header image to infoscreen 2017-05-31 23:08:43 +02:00
peter
9ec7a76d4a added header image to infoscreen 2017-05-31 23:03:13 +02:00
peter
3b6590f369 added header image to infoscreen 2017-05-31 23:01:07 +02:00
peter
708911ba4e added header image to infoscreen 2017-05-31 22:55:09 +02:00
peter
797d2a1d31 added header image to infoscreen 2017-05-31 22:54:01 +02:00
peter
7ad484cdd7 added header image to infoscreen 2017-05-31 22:52:06 +02:00
peter
aca92e1107 added header image to infoscreen 2017-05-31 22:46:11 +02:00
peter
f13fbafaae added header image to infoscreen 2017-05-31 22:45:42 +02:00
peter
f6738a5226 added header image to infoscreen 2017-05-31 22:42:31 +02:00
peter
2f4a9e4f10 added header image to infoscreen 2017-05-31 22:40:19 +02:00
peter
dff490163e added header image to infoscreen 2017-05-31 22:39:03 +02:00
peter
20a7091800 added header image to infoscreen 2017-05-31 22:38:10 +02:00
peter
ff49499204 added header image to infoscreen 2017-05-31 22:36:18 +02:00
peter
8b3e1ee225 added header image to infoscreen 2017-05-31 22:32:14 +02:00
peter
dc4f161ce4 added header image to infoscreen 2017-05-31 22:29:42 +02:00
peter
5c5236062b added header image to infoscreen 2017-05-31 22:20:53 +02:00
peter
43af1114e8 added header image to infoscreen 2017-05-31 22:16:54 +02:00
peter
0772d51c71 added header image to infoscreen 2017-05-31 22:15:34 +02:00
peter
f2293513c1 added header image to infoscreen 2017-05-31 22:14:12 +02:00
peter
87cad802d7 added header image to infoscreen 2017-05-31 22:12:39 +02:00
peter
2e4a0680df added header image to infoscreen 2017-05-31 22:07:11 +02:00
peter
4ca664a091 added header image to infoscreen 2017-05-31 22:04:03 +02:00
peter
02c766f428 added header image to infoscreen 2017-05-31 22:03:05 +02:00
peter
75e5b8e267 added header image to infoscreen 2017-05-31 21:59:47 +02:00
peter
7d008cb599 added header image to infoscreen 2017-05-31 21:51:41 +02:00
peter
b1fc24af80 set config.serve_static_assets = false 2017-05-31 21:49:21 +02:00
peter
7477b028c5 set config.serve_static_assets = false 2017-05-31 21:44:51 +02:00
peter
fddaa0dcb6 set config.serve_static_assets = false 2017-05-31 21:40:47 +02:00
peter
4ed7e92385 set config.serve_static_assets = true 2017-05-31 21:35:24 +02:00
peter
82876f34a8 changed infoscreen layout 2017-05-31 21:29:54 +02:00
peter
3d97153fa5 changed infoscreen layout 2017-05-31 21:28:09 +02:00
peter
6e10830b83 changed infoscreen layout 2017-05-31 21:05:06 +02:00
peter
8ad15aafd2 changed infoscreen layout 2017-05-31 21:03:43 +02:00
peter
d4948fff5e changed infoscreen layout 2017-05-31 15:11:59 +02:00
peter
8ea2109b27 changed infoscreen layout 2017-05-31 15:10:40 +02:00
peter
f72466f1cd changed infoscreen layout 2017-05-31 15:09:05 +02:00
peter
cba94e926c changed infoscreen layout 2017-05-31 15:07:47 +02:00
peter
f522a83813 changed infoscreen layout 2017-05-31 15:05:53 +02:00
peter
94d67463a9 changed infoscreen layout 2017-05-31 15:03:08 +02:00
peter
38656a1e75 changed infoscreen layout 2017-05-31 15:01:35 +02:00
peter
503b9eb732 changed infoscreen layout 2017-05-31 14:59:25 +02:00
peter
ffee3b8dfb changed infoscreen layout 2017-05-31 14:57:01 +02:00
peter
978f617131 changed infoscreen layout 2017-05-31 14:54:07 +02:00
peter
cf2a8adf49 changed infoscreen layout 2017-05-31 14:49:35 +02:00
peter
14e563ef95 changed infoscreen layout 2017-05-31 12:35:30 +02:00
Pet
5660cd7748 added testtext 2017-05-31 12:14:00 +02:00
Andreas Stephanides
af5d055014 change timeout for inforscreen 2017-05-29 09:56:46 +02:00
Andreas Stephanides
453dd7867d change timeout for inforscreen 2017-05-29 09:44:09 +02:00
root
bbfb5e6a1d Merge branch 'latest' of https://git.triton.fet.at/git/fetsite into latest 2017-05-13 23:04:50 +02:00
Andreas Stephanides
4ed35f184c https-etherpad 2017-05-12 07:18:19 +02:00
ruby
37aab0ef59 Merge branch 'latest' of https://git.triton.fet.at/git/fetsite into latest 2017-05-09 15:13:08 +02:00
ruby
c53d34191a fixes to init script 2017-05-09 15:11:28 +02:00
ruby
61c5624b16 blue2 default2 2017-05-09 15:11:00 +02:00
ruby
a1ef7028fd local solr sunspot 2017-05-09 15:10:40 +02:00
Andreas Stephanides
b5f1ae9e69 APIKEY 2017-05-09 13:39:52 +02:00
Andreas Stephanides
6a9fe8243b fix apth for ETHERPAD Key 2017-05-09 13:38:32 +02:00
Andreas Stephanides
1f581ab819 delete empty files 2017-05-09 13:31:45 +02:00
root
e73315bd41 fix neuigkeiten 2017-05-04 17:56:47 +02:00
Andreas Stephanides
491e360141 small fixes incl. solr 2017-04-18 19:03:09 +02:00
Andreas Stephanides
28226df76c Merge remote-tracking branch 'fetmaster/master' 2017-04-17 13:20:01 +02:00
root
dfef3721dc test1 2017-04-15 15:32:26 +02:00
Andreas Stephanides
14598fbbd9 add a README 2017-04-03 15:26:29 +02:00
Andreas Stephanides
ffaa57c914 starttopic nil 2017-04-03 15:26:19 +02:00
Andreas Stephanides
cd439ecf02 solr config update 2017-04-03 15:26:01 +02:00
Andreas Stephanides
328adfe3a5 calentries view fixed 2017-04-03 15:25:40 +02:00
Andreas Stephanides
e0312386e7 no boost for studium 2017-04-03 15:25:22 +02:00
ee451cdd9b some changes 2017-03-30 23:11:57 +02:00
cfdbeeaf46 Merge /home/andis/fetsite 2015-09-14 16:01:15 +02:00
Andreas Stephanides
5542777216 AutoCommit Mon Sep 14 16:00:56 CEST 2015 2015-09-14 16:00:56 +02:00
e341384493 Merge /home/andis/fetsite 2015-09-14 15:56:10 +02:00
Andreas Stephanides
0337131472 AutoCommit Mon Sep 14 15:54:50 CEST 2015 2015-09-14 15:54:50 +02:00
e4a100823f Merge /home/andis/fetsite 2015-09-14 13:50:46 +02:00
Andreas Stephanides
e15526865d AutoCommit Mon Sep 14 13:50:05 CEST 2015 2015-09-14 13:50:05 +02:00
f052940d6c Merge /home/andis/fetsite 2015-09-14 12:06:15 +02:00
7c6e04ca2e inactive facebook config 2015-09-14 12:05:55 +02:00
Andreas Stephanides
1d8bae3aee AutoCommit Mon Sep 14 12:03:04 CEST 2015 2015-09-14 12:03:04 +02:00
Andreas Stephanides
168b4d9e4c AutoCommit Mon Sep 14 01:03:01 CEST 2015 2015-09-14 01:03:01 +02:00
Andreas Stephanides
a47c6fea7a AutoCommit Mon Sep 14 00:03:01 CEST 2015 2015-09-14 00:03:01 +02:00
Andreas Stephanides
10949e9708 AutoCommit Son Sep 13 14:03:06 CEST 2015 2015-09-13 14:03:06 +02:00
Andreas Stephanides
a9c9b22a94 AutoCommit Son Sep 13 13:03:44 CEST 2015 2015-09-13 13:03:44 +02:00
Andreas Stephanides
b073a1a098 AutoCommit Son Sep 13 12:03:20 CEST 2015 2015-09-13 12:03:21 +02:00
Andreas Stephanides
d85a01c810 AutoCommit Son Sep 13 11:03:05 CEST 2015 2015-09-13 11:03:05 +02:00
Andreas Stephanides
4a8e5d393e AutoCommit Son Sep 13 10:03:11 CEST 2015 2015-09-13 10:03:11 +02:00
Andreas Stephanides
97d5427f6d AutoCommit Son Sep 13 00:03:01 CEST 2015 2015-09-13 00:03:01 +02:00
Andreas Stephanides
92667b92e9 AutoCommit Sam Sep 12 22:03:04 CEST 2015 2015-09-12 22:03:04 +02:00
Andreas Stephanides
ff70c31c40 AutoCommit Sam Sep 12 13:03:02 CEST 2015 2015-09-12 13:03:02 +02:00
Andreas Stephanides
3d87ce6fd2 AutoCommit Sam Sep 12 12:03:06 CEST 2015 2015-09-12 12:03:06 +02:00
Andreas Stephanides
cfb42584e1 AutoCommit Sam Sep 12 11:03:02 CEST 2015 2015-09-12 11:03:02 +02:00
Andreas Stephanides
52dac513f7 AutoCommit Sam Sep 12 10:03:56 CEST 2015 2015-09-12 10:03:56 +02:00
Andreas Stephanides
514bdc1ef0 AutoCommit Fre Sep 11 21:03:01 CEST 2015 2015-09-11 21:03:01 +02:00
Andreas Stephanides
e486ab02fd AutoCommit Fre Sep 11 19:03:01 CEST 2015 2015-09-11 19:03:01 +02:00
Andreas Stephanides
0dc83df98c AutoCommit Fre Sep 11 15:03:05 CEST 2015 2015-09-11 15:03:05 +02:00
Andreas Stephanides
9a9c7f74f9 AutoCommit Fre Sep 11 13:03:02 CEST 2015 2015-09-11 13:03:02 +02:00
Andreas Stephanides
68e2d4a5a7 AutoCommit Don Sep 10 22:03:01 CEST 2015 2015-09-10 22:03:01 +02:00
Andreas Stephanides
edaf154549 AutoCommit Don Sep 10 21:03:02 CEST 2015 2015-09-10 21:03:02 +02:00
Andreas Stephanides
f59f0cb05a AutoCommit Don Sep 10 20:03:01 CEST 2015 2015-09-10 20:03:01 +02:00
Andreas Stephanides
b7abbb8a77 AutoCommit Don Sep 10 09:03:01 CEST 2015 2015-09-10 09:03:01 +02:00
Andreas Stephanides
9521f04c72 AutoCommit Don Sep 10 00:03:03 CEST 2015 2015-09-10 00:03:03 +02:00
Andreas Stephanides
01c6fedaee AutoCommit Mit Sep 9 23:03:01 CEST 2015 2015-09-09 23:03:01 +02:00
Andreas Stephanides
1e48881830 AutoCommit Mit Sep 9 22:03:05 CEST 2015 2015-09-09 22:03:05 +02:00
Andreas Stephanides
0da3ee8ed9 AutoCommit Mit Sep 9 11:03:36 CEST 2015 2015-09-09 11:03:37 +02:00
Andreas Stephanides
5531eb089e AutoCommit Die Sep 8 14:03:06 CEST 2015 2015-09-08 14:03:06 +02:00
Andreas Stephanides
8fa549ae23 AutoCommit Mon Sep 7 00:03:01 CEST 2015 2015-09-07 00:03:01 +02:00
Andreas Stephanides
8c2efffff4 AutoCommit Son Sep 6 23:03:05 CEST 2015 2015-09-06 23:03:05 +02:00
Andreas Stephanides
b9079c0525 AutoCommit Son Sep 6 21:03:06 CEST 2015 2015-09-06 21:03:06 +02:00
Andreas Stephanides
d509884aa1 AutoCommit Sam Sep 5 21:03:02 CEST 2015 2015-09-05 21:03:02 +02:00
Andreas Stephanides
13f852cf48 AutoCommit Sam Sep 5 19:03:01 CEST 2015 2015-09-05 19:03:01 +02:00
Andreas Stephanides
a96e48fa36 AutoCommit Sam Sep 5 18:03:02 CEST 2015 2015-09-05 18:03:02 +02:00
Andreas Stephanides
a84332d09f AutoCommit Sam Sep 5 17:03:04 CEST 2015 2015-09-05 17:03:04 +02:00
Andreas Stephanides
4b1d11751d AutoCommit Sam Sep 5 16:03:02 CEST 2015 2015-09-05 16:03:02 +02:00
Andreas Stephanides
eccb090d5c AutoCommit Sam Sep 5 15:03:11 CEST 2015 2015-09-05 15:03:11 +02:00
Andreas Stephanides
c7d12e9a42 AutoCommit Fre Sep 4 14:03:04 CEST 2015 2015-09-04 14:03:04 +02:00
Andreas Stephanides
f7ad93c398 AutoCommit Don Sep 3 16:03:01 CEST 2015 2015-09-03 16:03:01 +02:00
Andreas Stephanides
984e5f4b56 AutoCommit Don Sep 3 12:03:05 CEST 2015 2015-09-03 12:03:05 +02:00
Andreas Stephanides
4835155d06 AutoCommit Don Sep 3 11:03:01 CEST 2015 2015-09-03 11:03:01 +02:00
Andreas Stephanides
e7c21ad95b AutoCommit Don Sep 3 10:03:06 CEST 2015 2015-09-03 10:03:06 +02:00
Andreas Stephanides
889d7ac3d0 AutoCommit Mit Sep 2 23:03:01 CEST 2015 2015-09-02 23:03:01 +02:00
Andreas Stephanides
194a8375dd AutoCommit Mit Sep 2 22:03:01 CEST 2015 2015-09-02 22:03:01 +02:00
Andreas Stephanides
7b9b226e59 AutoCommit Mit Sep 2 21:03:01 CEST 2015 2015-09-02 21:03:01 +02:00
Andreas Stephanides
d4964f40fb AutoCommit Die Sep 1 14:03:03 CEST 2015 2015-09-01 14:03:03 +02:00
Andreas Stephanides
5134dc2e5f AutoCommit Die Sep 1 13:03:03 CEST 2015 2015-09-01 13:03:03 +02:00
Andreas Stephanides
c37040a74b AutoCommit Die Sep 1 12:03:25 CEST 2015 2015-09-01 12:03:25 +02:00
Andreas Stephanides
c1a7d9b7c2 AutoCommit Die Sep 1 10:03:01 CEST 2015 2015-09-01 10:03:01 +02:00
Andreas Stephanides
576b763d82 AutoCommit Die Sep 1 09:03:01 CEST 2015 2015-09-01 09:03:01 +02:00
Andreas Stephanides
c02ee30013 AutoCommit Die Sep 1 01:03:02 CEST 2015 2015-09-01 01:03:02 +02:00
Andreas Stephanides
1cea790324 AutoCommit Die Sep 1 00:03:02 CEST 2015 2015-09-01 00:03:02 +02:00
Andreas Stephanides
3bcd8389d4 AutoCommit Mon Aug 31 23:03:01 CEST 2015 2015-08-31 23:03:01 +02:00
Andreas Stephanides
221bd95cbf AutoCommit Mon Aug 31 22:03:01 CEST 2015 2015-08-31 22:03:01 +02:00
Andreas Stephanides
8c1e430bb2 AutoCommit Mon Aug 31 18:03:21 CEST 2015 2015-08-31 18:03:21 +02:00
Andreas Stephanides
589597509a AutoCommit Mon Aug 31 17:03:03 CEST 2015 2015-08-31 17:03:03 +02:00
Andreas Stephanides
93dbdedf53 AutoCommit Mon Aug 31 16:03:01 CEST 2015 2015-08-31 16:03:01 +02:00
Andreas Stephanides
1bc9d65a44 AutoCommit Mon Aug 31 15:03:01 CEST 2015 2015-08-31 15:03:01 +02:00
Andreas Stephanides
f61231accc AutoCommit Mon Aug 31 14:03:19 CEST 2015 2015-08-31 14:03:19 +02:00
Andreas Stephanides
cec9939144 AutoCommit Mon Aug 31 13:03:02 CEST 2015 2015-08-31 13:03:02 +02:00
Andreas Stephanides
6b324ded44 AutoCommit Son Aug 30 20:03:01 CEST 2015 2015-08-30 20:03:01 +02:00
Andreas Stephanides
18a6821029 AutoCommit Son Aug 30 19:03:01 CEST 2015 2015-08-30 19:03:01 +02:00
Andreas Stephanides
2d9944dfc3 AutoCommit Son Aug 30 18:03:01 CEST 2015 2015-08-30 18:03:01 +02:00
Andreas Stephanides
9dd9c3cc48 AutoCommit Son Aug 30 17:03:01 CEST 2015 2015-08-30 17:03:01 +02:00
Andreas Stephanides
8bfd96d0af AutoCommit Son Aug 30 16:03:01 CEST 2015 2015-08-30 16:03:01 +02:00
Andreas Stephanides
4a671f5cff AutoCommit Son Aug 30 15:03:01 CEST 2015 2015-08-30 15:03:01 +02:00
Andreas Stephanides
5bf63421a6 AutoCommit Son Aug 30 14:03:01 CEST 2015 2015-08-30 14:03:01 +02:00
Andreas Stephanides
723d7be980 Merge branch 'master' of https://github.com/fetsite/fetsite into tests 2015-08-30 13:04:23 +02:00
Andreas Stephanides
e098c0cd36 AutoCommit Son Aug 30 10:03:05 CEST 2015 2015-08-30 10:03:05 +02:00
Andreas Stephanides
bffb978fc7 AutoCommit Don Aug 27 17:03:04 CEST 2015 2015-08-27 17:03:04 +02:00
Andreas Stephanides
8e1e19d3ab AutoCommit Don Aug 27 16:03:04 CEST 2015 2015-08-27 16:03:04 +02:00
Andreas Stephanides
7c2f1f9753 AutoCommit Don Aug 27 15:03:02 CEST 2015 2015-08-27 15:03:02 +02:00
Andreas Stephanides
370c439c29 AutoCommit Don Aug 27 14:03:04 CEST 2015 2015-08-27 14:03:04 +02:00
Andreas Stephanides
1047851b47 AutoCommit Mit Aug 26 12:03:05 CEST 2015 2015-08-26 12:03:05 +02:00
Andreas Stephanides
94cad06e31 AutoCommit Mit Aug 26 11:03:04 CEST 2015 2015-08-26 11:03:04 +02:00
8ed5b7287e small fixes 2015-08-26 09:40:53 +02:00
Andreas Stephanides
934e004416 AutoCommit Sam Aug 22 18:17:03 CEST 2015 2015-08-22 18:17:03 +02:00
Andreas Stephanides
af39f21595 AutoCommit Sam Aug 22 18:03:02 CEST 2015 2015-08-22 18:03:02 +02:00
Andreas Stephanides
82b71f045f Merge branch 'survey' 2015-08-22 17:55:32 +02:00
Andreas Stephanides
37c2d893b6 AutoCommit Sam Aug 22 00:03:01 CEST 2015 2015-08-22 00:03:01 +02:00
Andreas Stephanides
58fd356f00 Merge branch 'master' of fet.at:~/fetsite 2015-08-07 17:23:16 +02:00
909cefb85b Merge branch 'master' of https://github.com/fetsite/fetsite 2015-07-14 14:38:36 +02:00
07549c6f0e Merge branch 'master' of https://github.com/fetsite/fetsite 2015-07-13 11:52:23 +02:00
c356c3c128 Merge branch 'master' of https://github.com/fetsite/fetsite 2015-07-12 09:44:32 +02:00
c7902423b5 Merge branch 'master' of https://github.com/fetsite/fetsite 2015-07-12 07:15:57 +02:00
dd94a1b47b Merge branch 'master' of https://github.com/fetsite/fetsite 2015-07-11 20:07:28 +02:00
48f8c975cd Merge branch 'master' of https://github.com/fetsite/fetsite 2015-06-26 16:21:38 +02:00
6b0314af7a merge cachebsp 2015-06-26 11:08:44 +02:00
f718567722 fix cachebsp 2015-06-26 11:07:08 +02:00
167 changed files with 6910 additions and 1730 deletions

12
.gitignore vendored
View File

@@ -28,7 +28,7 @@
/db/schema.rb /db/schema.rb
/db/structure.sql /db/structure.sql
/config/initializers/devise.rb /config/initializers/devise.rb
Gemfile.lock
# Ignore all logfiles and tempfiles. # Ignore all logfiles and tempfiles.
/log/*.log /log/*.log
/tmp /tmp
@@ -40,15 +40,23 @@ console
/server /server
/public/uploads/ /public/uploads/
/public/sitemap* /public/sitemap*
/public/assets/
/vendor/* /vendor/*
/bak/* /bak/*
/solr/* /solr/*
/log/* /log/*
*# *#
Gemfile.lock
/config/database.yml /config/database.yml
/config/start_topic.yml /config/start_topic.yml
/config/contact_topic.yml /config/contact_topic.yml
/config/etherpad/APIKEY.*
/config/page.yml
.#* .#*
.* .*
!/.gitignore !/.gitignore
*.pid
/doc/app
coverage/*

43
Gemfile
View File

@@ -1,11 +1,11 @@
source 'https://rubygems.org' source 'https://rubygems.org'
gem 'rake', '~>10.0'
gem 'rails', '3.2.13' gem 'rails', '3.2.13'
gem 'sprockets', '2.2.2' gem 'sprockets', '2.2.2'
gem 'webrick', '1.3.1' gem 'webrick', '1.3.1'
# Bundle edge Rails instead: # Bundle edge Rails instead:
# gem 'rails', :git => 'git://github.com/rails/rails.git' # gem 'rails', :git => 'git://github.com/rails/rails.git'
gem 'mysql2' gem 'mysql2', '~>0.3.10'
gem 'sqlite3' gem 'sqlite3'
gem 'execjs', '~>1.4.0' gem 'execjs', '~>1.4.0'
@@ -13,8 +13,8 @@ gem 'webrick', '1.3.1'
# Gems used only for assets and not required # Gems used only for assets and not required
# in production environments by default. # in production environments by default.
gem 'sass-rails', '~> 3.2' gem 'sass-rails', '~> 3.0'
gem 'coffee-rails', '~> 3.2.1' gem 'coffee-rails', '~> 3.0'
gem 'bootstrap-sass','~> 2.3.2.1' gem 'bootstrap-sass','~> 2.3.2.1'
group :assets do group :assets do
@@ -33,7 +33,7 @@ gem 'jquery-rails'
# gem 'jbuilder' # gem 'jbuilder'
# Use unicorn as the app server # Use unicorn as the app server
gem 'unicorn' gem 'unicorn', '~>4.8.0'
# Deploy with Capistran # Deploy with Capistran
# gem 'capistrano' # gem 'capistrano'
@@ -60,16 +60,17 @@ gem "paper_trail" , '~>3.0.5'#, :git=>'git://github.com/airblade/paper_trail.git
# User management # User management
gem "devise" ,'~>2.2.3' gem "devise" ,'~>2.2.3'
gem "omniauth" gem "omniauth", '~>1.2.2'
gem "omniauth-facebook" gem "omniauth-facebook", '~>2.0.0'
gem "omniauth-ldap" gem "omniauth-ldap", '~>1.0.4'
gem "fb_graph" gem "fb_graph",'~>2.7.17'
gem "meta-tags" gem "meta-tags"
# Roles for users # Roles for users
gem "rolify" gem "rolify", '~>4.0.0'
# Abilities # Abilities
gem "cancan" gem "cancan", '~>1.6.0'
# Fileupload # Fileupload
@@ -81,11 +82,21 @@ gem 'haml'
#gem 'wikicloth' #gem 'wikicloth'
#gem 'gollum-lib' #gem 'gollum-lib'
gem 'awesome_nested_set' gem 'awesome_nested_set'
gem 'annotate', ">=2.5.0" gem 'annotate', "~>2.6.0"
gem 'carrierwave', "~>0.9.0" gem 'carrierwave', "~>0.9.0"
group :development, :test do group :development, :test do
gem 'factory_girl_rails' gem 'factory_girl_rails',"~>4.5.0"
gem 'rspec-rails' gem 'minitest', "~>4.7.5"
gem 'progress_bar'
gem 'rspec-core', '~>3.3.0'
gem 'rspec-support', '~>3.3.0'
gem 'rspec-rails', '~>3.3.0'
gem 'rspec-collection_matchers', '~>1.1.2'
gem 'rspec-activemodel-mocks', '~>1.0.1'
gem 'rspec-html-matchers', '~>0.7.0'
gem 'rspec-expectations', '~>3.3.1'
gem 'capybara', '~>2.5.0'
gem 'simplecov'
end end
gem "simple_calendar", "~> 0.1.9" gem "simple_calendar", "~> 0.1.9"
@@ -93,7 +104,7 @@ gem 'rmagick'
gem 'bootstrap-addons-rails' gem 'bootstrap-addons-rails'
gem "jquery-fileupload-rails", "0.4.1" gem "jquery-fileupload-rails", "0.4.1"
gem "jquery-ui-rails","~> 4.1.1" gem "jquery-ui-rails","~> 4.1.0"
gem "font-awesome-rails" gem "font-awesome-rails"
gem "jquery-datetimepicker-rails" gem "jquery-datetimepicker-rails"
# gem "jquery-sortable-rails" # gem "jquery-sortable-rails"
@@ -125,3 +136,5 @@ gem 'blueimp-gallery'
gem 'blueimp-gallery-rails' gem 'blueimp-gallery-rails'
gem 'shareable' gem 'shareable'
gem 'sunspot_test'

456
Gemfile.lock Normal file
View File

@@ -0,0 +1,456 @@
GIT
remote: git://github.com/matenia/bootstrap-kaminari-views.git
revision: 9df61d400fc144c3f33d65f3f97e4867b8e68273
specs:
bootstrap-kaminari-views (0.0.5)
kaminari (>= 0.13)
rails (>= 3.1)
GIT
remote: git://github.com/rgrove/sanitize
revision: acc7e6440139379a0c6b4b76b662ed90acd4b923
specs:
sanitize (4.6.4)
crass (~> 1.0.2)
nokogiri (>= 1.4.4)
nokogumbo (~> 1.4)
GEM
remote: https://rubygems.org/
specs:
actionmailer (3.2.13)
actionpack (= 3.2.13)
mail (~> 2.5.3)
actionpack (3.2.13)
activemodel (= 3.2.13)
activesupport (= 3.2.13)
builder (~> 3.0.0)
erubis (~> 2.7.0)
journey (~> 1.0.4)
rack (~> 1.4.5)
rack-cache (~> 1.2)
rack-test (~> 0.6.1)
sprockets (~> 2.2.1)
active_record_query_trace (1.5.4)
activemodel (3.2.13)
activesupport (= 3.2.13)
builder (~> 3.0.0)
activerecord (3.2.13)
activemodel (= 3.2.13)
activesupport (= 3.2.13)
arel (~> 3.0.2)
tzinfo (~> 0.3.29)
activeresource (3.2.13)
activemodel (= 3.2.13)
activesupport (= 3.2.13)
activesupport (3.2.13)
i18n (= 0.6.1)
multi_json (~> 1.0)
acts_as_votable (0.11.1)
addressable (2.5.2)
public_suffix (>= 2.0.2, < 4.0)
aes_key_wrap (1.0.1)
annotate (2.6.10)
activerecord (>= 3.2, <= 4.3)
rake (~> 10.4)
arel (3.0.3)
attr_required (1.0.1)
awesome_nested_set (2.1.6)
activerecord (>= 3.0.0)
bcrypt (3.1.11)
bcrypt-ruby (3.1.5)
bcrypt (>= 3.1.3)
bindata (2.4.3)
blueimp-gallery (2.11.0.1)
railties (>= 3.1.0)
blueimp-gallery-rails (2.7.0)
railties (>= 3.0, < 5.0)
bootstrap-addons-rails (0.1.2)
rails
bootstrap-sass (2.3.2.2)
sass (~> 3.2)
builder (3.0.4)
cancan (1.6.10)
capybara (2.5.0)
mime-types (>= 1.16)
nokogiri (>= 1.3.3)
rack (>= 1.0.0)
rack-test (>= 0.5.4)
xpath (~> 2.0)
carrierwave (0.9.0)
activemodel (>= 3.2.0)
activesupport (>= 3.2.0)
json (>= 1.7)
chronic (0.10.2)
climate_control (0.2.0)
cocaine (0.5.8)
climate_control (>= 0.0.3, < 1.0)
coffee-rails (3.2.2)
coffee-script (>= 2.2.0)
railties (~> 3.2.0)
coffee-script (2.4.1)
coffee-script-source
execjs
coffee-script-source (1.12.2)
crass (1.0.4)
devise (2.2.8)
bcrypt-ruby (~> 3.0)
orm_adapter (~> 0.1)
railties (~> 3.1)
warden (~> 1.2.1)
diff-lcs (1.3)
docile (1.3.1)
domain_name (0.5.20180417)
unf (>= 0.0.5, < 1.0.0)
erubis (2.7.0)
etherpad-lite (0.3.0)
rest-client (>= 1.6)
execjs (1.4.1)
multi_json (~> 1.0)
factory_girl (4.5.0)
activesupport (>= 3.0.0)
factory_girl_rails (4.5.0)
factory_girl (~> 4.5.0)
railties (>= 3.0.0)
faraday (0.12.2)
multipart-post (>= 1.2, < 3)
fb_graph (2.7.17)
httpclient (>= 2.4)
multi_json (>= 1.3)
rack-oauth2 (>= 0.14.4)
tzinfo
ffi (1.9.23)
font-awesome-rails (4.7.0.4)
railties (>= 3.2, < 6.0)
formtastic (2.2.1)
actionpack (>= 3.0)
formtastic-bootstrap (3.0.0)
formtastic (>= 2.2)
git (1.3.0)
globalize (3.0.5)
activemodel (>= 3.0.0, < 4.0.0)
activerecord (>= 3.0.0, < 4.0.0)
globalize-accessors (0.1.5)
globalize (>= 3)
globalize-versioning (0.2.0)
activemodel (>= 3.2.0, < 5)
activerecord (>= 3.2.0, < 5)
globalize (>= 3.0.4, < 6)
paper_trail (>= 3.0.0, < 5)
haml (5.0.4)
temple (>= 0.8.0)
tilt
hashie (3.5.7)
highline (1.7.10)
hike (1.2.3)
http-cookie (1.0.3)
domain_name (~> 0.5)
httpclient (2.8.3)
i18n (0.6.1)
journey (1.0.4)
jquery-datetimepicker-rails (2.4.1.0)
jquery-fileupload-rails (0.4.1)
actionpack (>= 3.1)
railties (>= 3.1)
jquery-rails (3.1.5)
railties (>= 3.0, < 5.0)
thor (>= 0.14, < 2.0)
jquery-ui-rails (4.1.2)
railties (>= 3.1.0)
json (2.1.0)
json-jwt (1.9.4)
activesupport
aes_key_wrap
bindata
jwt (1.5.6)
kaminari (0.17.0)
actionpack (>= 3.0.0)
activesupport (>= 3.0.0)
kgio (2.11.2)
libv8 (3.16.14.19)
mail (2.5.5)
mime-types (~> 1.16)
treetop (~> 1.4.8)
meta-tags (2.9.0)
actionpack (>= 3.2.0, < 5.3)
mime-types (1.25.1)
mini_portile2 (2.3.0)
minitest (4.7.5)
multi_json (1.13.1)
multi_xml (0.6.0)
multipart-post (2.0.0)
mysql2 (0.3.21)
net-ldap (0.16.1)
netrc (0.11.0)
nokogiri (1.8.2)
mini_portile2 (~> 2.3.0)
nokogumbo (1.5.0)
nokogiri
oauth2 (1.4.0)
faraday (>= 0.8, < 0.13)
jwt (~> 1.0)
multi_json (~> 1.3)
multi_xml (~> 0.5)
rack (>= 1.2, < 3)
omniauth (1.2.2)
hashie (>= 1.2, < 4)
rack (~> 1.0)
omniauth-facebook (2.0.1)
omniauth-oauth2 (~> 1.2)
omniauth-ldap (1.0.5)
net-ldap (~> 0.12)
omniauth (~> 1.0)
pyu-ruby-sasl (~> 0.0.3.2)
rubyntlm (~> 0.3.4)
omniauth-oauth2 (1.5.0)
oauth2 (~> 1.1)
omniauth (~> 1.2)
opengraph_parser (0.2.3)
addressable
nokogiri
options (2.3.2)
orm_adapter (0.5.0)
paper_trail (3.0.9)
activerecord (>= 3.0, < 5.0)
activesupport (>= 3.0, < 5.0)
paperclip (3.4.2)
activemodel (>= 3.0.0)
activerecord (>= 3.0.0)
activesupport (>= 3.0.0)
cocaine (~> 0.5.0)
mime-types
polyglot (0.3.5)
pr_geohash (1.0.0)
progress_bar (1.2.0)
highline (~> 1.6)
options (~> 2.3.0)
public_suffix (3.0.2)
pyu-ruby-sasl (0.0.3.3)
rack (1.4.7)
rack-cache (1.7.2)
rack (>= 0.4)
rack-oauth2 (1.9.2)
activesupport
attr_required
httpclient
json-jwt (>= 1.9.0)
rack
rack-ssl (1.3.4)
rack
rack-test (0.6.3)
rack (>= 1.0)
rails (3.2.13)
actionmailer (= 3.2.13)
actionpack (= 3.2.13)
activerecord (= 3.2.13)
activeresource (= 3.2.13)
activesupport (= 3.2.13)
bundler (~> 1.0)
railties (= 3.2.13)
railties (3.2.13)
actionpack (= 3.2.13)
activesupport (= 3.2.13)
rack-ssl (~> 1.3.2)
rake (>= 0.8.7)
rdoc (~> 3.4)
thor (>= 0.14.6, < 2.0)
raindrops (0.19.0)
rake (10.5.0)
rb-fsevent (0.10.3)
rb-inotify (0.9.10)
ffi (>= 0.5.0, < 2)
rdoc (3.9.5)
ref (2.0.0)
rest-client (2.0.2)
http-cookie (>= 1.0.2, < 2.0)
mime-types (>= 1.16, < 4.0)
netrc (~> 0.8)
rmagick (2.16.0)
rolify (4.0.0)
rsolr (2.2.1)
builder (>= 2.1.2)
faraday (>= 0.9.0)
rspec (3.3.0)
rspec-core (~> 3.3.0)
rspec-expectations (~> 3.3.0)
rspec-mocks (~> 3.3.0)
rspec-activemodel-mocks (1.0.3)
activemodel (>= 3.0)
activesupport (>= 3.0)
rspec-mocks (>= 2.99, < 4.0)
rspec-collection_matchers (1.1.3)
rspec-expectations (>= 2.99.0.beta1)
rspec-core (3.3.2)
rspec-support (~> 3.3.0)
rspec-expectations (3.3.1)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.3.0)
rspec-html-matchers (0.7.3)
nokogiri (~> 1)
rspec (>= 3.0.0.a, < 4)
rspec-mocks (3.3.2)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.3.0)
rspec-rails (3.3.3)
actionpack (>= 3.0, < 4.3)
activesupport (>= 3.0, < 4.3)
railties (>= 3.0, < 4.3)
rspec-core (~> 3.3.0)
rspec-expectations (~> 3.3.0)
rspec-mocks (~> 3.3.0)
rspec-support (~> 3.3.0)
rspec-support (3.3.0)
rubyntlm (0.3.4)
rubyzip (1.2.1)
sass (3.5.6)
sass-listen (~> 4.0.0)
sass-listen (4.0.0)
rb-fsevent (~> 0.9, >= 0.9.4)
rb-inotify (~> 0.9, >= 0.9.7)
sass-rails (3.2.6)
railties (~> 3.2.0)
sass (>= 3.1.10)
tilt (~> 1.3)
seed_dump (0.5.3)
shareable (1.1.4)
actionpack (>= 3.0.0)
activesupport (>= 3.0.0)
simple_calendar (0.1.11)
rails (>= 3.0)
simplecov (0.16.1)
docile (~> 1.1)
json (>= 1.8, < 3)
simplecov-html (~> 0.10.0)
simplecov-html (0.10.2)
sitemap_generator (6.0.1)
builder (~> 3.0)
sprockets (2.2.2)
hike (~> 1.2)
multi_json (~> 1.0)
rack (~> 1.0)
tilt (~> 1.1, != 1.3.0)
sqlite3 (1.3.13)
sunspot (2.3.0)
pr_geohash (~> 1.0)
rsolr (>= 1.1.1, < 3)
sunspot_rails (2.3.0)
rails (>= 3)
sunspot (= 2.3.0)
sunspot_solr (2.3.0)
sunspot_test (0.4.1)
sunspot_rails (>= 2.1.1)
sunspot_solr
temple (0.8.0)
themes_for_rails (0.5.1)
rails (>= 3.0.0)
therubyracer (0.12.3)
libv8 (~> 3.16.14.15)
ref
thor (0.20.0)
tilt (1.4.1)
tinymce-rails (4.1.10)
railties (>= 3.1.1)
treetop (1.4.15)
polyglot
polyglot (>= 0.3.1)
tzinfo (0.3.54)
uglifier (4.1.10)
execjs (>= 0.3.0, < 3)
unf (0.1.4)
unf_ext
unf_ext (0.0.7.5)
unicorn (4.8.3)
kgio (~> 2.6)
rack
raindrops (~> 0.7)
warden (1.2.7)
rack (>= 1.0)
webrick (1.3.1)
whenever (0.10.0)
chronic (>= 0.6.3)
xpath (2.1.0)
nokogiri (~> 1.3)
yaml_db (0.6.0)
rails (>= 3.0, < 5.2)
rake (>= 0.8.7)
PLATFORMS
ruby
DEPENDENCIES
active_record_query_trace
acts_as_votable
annotate (~> 2.6.0)
awesome_nested_set
blueimp-gallery
blueimp-gallery-rails
bootstrap-addons-rails
bootstrap-kaminari-views!
bootstrap-sass (~> 2.3.2.1)
cancan (~> 1.6.0)
capybara (~> 2.5.0)
carrierwave (~> 0.9.0)
coffee-rails (~> 3.0)
devise (~> 2.2.3)
etherpad-lite
execjs (~> 1.4.0)
factory_girl_rails (~> 4.5.0)
fb_graph (~> 2.7.17)
font-awesome-rails
formtastic (~> 2.2.1)
formtastic-bootstrap (~> 3.0.0)
git
globalize (~> 3.0.4)
globalize-accessors
globalize-versioning
haml
jquery-datetimepicker-rails
jquery-fileupload-rails (= 0.4.1)
jquery-rails
jquery-ui-rails (~> 4.1.0)
kaminari
meta-tags
minitest (~> 4.7.5)
mysql2 (~> 0.3.10)
omniauth (~> 1.2.2)
omniauth-facebook (~> 2.0.0)
omniauth-ldap (~> 1.0.4)
opengraph_parser
paper_trail (~> 3.0.5)
paperclip (~> 3.4.0)
progress_bar
rails (= 3.2.13)
rake (~> 10.0)
rmagick
rolify (~> 4.0.0)
rspec-activemodel-mocks (~> 1.0.1)
rspec-collection_matchers (~> 1.1.2)
rspec-core (~> 3.3.0)
rspec-expectations (~> 3.3.1)
rspec-html-matchers (~> 0.7.0)
rspec-rails (~> 3.3.0)
rspec-support (~> 3.3.0)
rubyzip
sanitize!
sass-rails (~> 3.0)
seed_dump (~> 0.5.3)
shareable
simple_calendar (~> 0.1.9)
simplecov
sitemap_generator
sprockets (= 2.2.2)
sqlite3
sunspot_rails
sunspot_solr
sunspot_test
themes_for_rails
therubyracer
tinymce-rails (~> 4.1.0)
uglifier (>= 1.0.3)
unicorn (~> 4.8.0)
webrick (= 1.3.1)
whenever
yaml_db
BUNDLED WITH
1.16.6

25
README Normal file
View File

@@ -0,0 +1,25 @@
SETUP:
install ruby 2.1.10
install requirements
apt-get ...
mkdir /srv/fetsite
cd /srv/fetsite
copy / fetch Gemfile
make User fetsite
bundle install
# Config Files kopieren:
cp /srv/fetsite/config/omniout_secrets.yml.example /srv/fetsite/config/omniout_secrets.yml
cp /srv/fetsite/config/omniout_secrets.yml.example /srv/fetsite/config/omniout_secrets.yml
touch crawler_config.yml
# Datenbank erstellen
rake db:migrate

11
README_productive.md Normal file
View File

@@ -0,0 +1,11 @@
install ruby/fetsite requirements
do all the rvm stuff
apt-get install git
chown fetsite /srv
su fetsite
cd /srv

File diff suppressed because it is too large Load Diff

View File

@@ -1,149 +1,123 @@
/* /*
* This is a manifest file that'll be compiled into application.css, which will include all the files * This is a manifest file that'll be compiled into application.css, which will include all the files
* listed below. * listed below.
* *
* Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets, * Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets,
* or vendor/assets/stylesheets of plugins, if any, can be referenced here using a relative path. * or vendor/assets/stylesheets of plugins, if any, can be referenced here using a relative path.
* *
* You're free to add application-wide styles to this file and they'll appear at the top of the * You're free to add application-wide styles to this file and they'll appear at the top of the
* compiled file, but it's generally better to create a new file per style scope. * compiled file, but it's generally better to create a new file per style scope.
*= require_self *
* require_tree . *= require_self
*= require 'calendars' * require_tree .
*= require jquery.fileupload-ui *= require blueimp-gallery-all
* require 'bootstrap' *= require jquery.fileupload-ui
*= require 'tinymce' *= require jquery.datetimepicker
*= require jquery.ui.dialog
*= require jquery.ui.autocomplete
*= require jquery.ui.progressbar
*= require jquery.ui.tabs
* require 'bootstrap'
* require 'neuigkeiten'
*/
*/ $color_schema_1: #006599;
// Colorshema #0A64A4 $color_schema_2: #630CE8;
$color_prim: #0A64A4; $color_schema_3: #FF0021;
$color_prim_light: #0B65A5; $color_schema_4: #E8820C;
$color_prim_vlight: #2B85C5; $color_schema_5: #FFF30D;
$color_cont: FFDB73;
$color_cont_light:FFDB73; $color_schema_1_dark: darken($color_schema_1, 10%);
$linkColor: #03006E; $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: $color_schema_3;
$color_cont_light:lighten($color_cont ,10%);
$linkColor: $color_prim;
$linkColorHover: $color_schema_1;
$white: #FFFFFF; $white: #FFFFFF;
$bodyBackground: $white; $bodyBackground: #EEE;
$navbarBackground: $color_cont;
$navbarBackground: #FFFFFF;
$navbarBackgroundHighlight:lighten($navbarBackground,30%);
$navbarBackground: #EEE;//$color_prim;
$navbarText: $color_prim;
$navbarLinkColor: $color_prim;
$navbarLinkColorHover: $color_schema_1;
$dropdownLinkColor: black;
$navbar-default-brand-color: black;
$navbarBrandColor:black;
$navbarBackgroundHighlight: #EEE;
//$navbarBackgroundHighlight:#FFFFFF; //$navbarBackgroundHighlight:#FFFFFF;
$navbarLinkBackgroundHover:#FFBE00;
$navbarLinkBackgroundHover: lighten(#cccccc,10%); $navbarLinkBackgroundHover: darken($navbarBackground,10%);
$infoBackground:#65A5D1; $infoBackground:#65A5D1;
$infoText:#03406A; $infoText:#03406A;
$sansFontFamily: Helvetica, Arial; $sansFontFamily: Helvetica, Arial;
@import 'bootstrap'; @import 'bootstrap';
@import 'bootstrap-responsive'; @import 'bootstrap-responsive';
@import 'bootstrap/image-gallery'; @import 'bootstrap/image-gallery';
@import 'font-awesome'; @import 'font-awesome';
@import 'neuigkeiten';
h1 { @import 'themengruppen';
font-size: 23px
}
h2 {
font-size: 19px
}
body,html {
padding:0;
margin:0;
}
a:hover {
text-decoration:none;
}
div.header { div.header {
display: block; display: block;
// background: url('/header1.png') no-repeat; // background: url('../../../../header1.png') no-repeat;
background-color: #FFF; // background-color:white;// $color_prim;
background-position: right; // background-position: right;
border-bottom:1px solid black; vertical-align:middle;
height:41px; float:left;
color:#000; color:#000;
padding-left:87px; padding-top:0px;
padding-top:0px; overflow:visible;
overflow:hidden; height:45px;
margin-bottom: 20px margin-bottom: 0 px
} }
div.header h1 { div.header h1 {
padding:0; padding:0;
margin:4px; margin:4px;
font-size:20px; font-size:20px;
line-height:32px; line-height:32px;
} }
#menudiv { div.header img {
width:100%; //top:2px;
//position:relative;
}
div.navbar {
border-bottom: $color_prim solid 3px;
}
div.headerrow {
} }
$contentdiv-background:none;
.navbar .nav li { $navbar-li-minwidth: 0;
min-width:100%;
}
.navbar .nav .divider {
border-style: solid;
border-width: 1px 0px 0px 0px;
border-color: grey;
min-width: 100%;
}
.navbar .navbar-inner
{
border:none;
box-shadow:none;
}
#contentdiv
{
background: #FFFFFF
}
#contentdiv .container-fluid
{
padding:0;
}
a.linkbox, div.contentbox
{
display:block;
padding:5px;
border-radius: 10px;
border: lightgray solid 1px;
}
a.linkbox:hover
{
box-shadow: 1px 1px 2px 2px lightgray;
}
a.linkbox li
{
}
ul.linkbox-list li
{
margin-bottom:10px;
}
ul.linkbox-list
{
max-width:70em;
}
div.contentbox
{
margin: 5px;
}
.navbar .nav li {
min-width:100%;
background:44F;
}
@import 'galleries'; $box-border: #ccc solid 1px;
@import 'tinymce'; $box-border-radius:0px;
$box-background: white;
@import 'layout';
@import 'linkboxes';
@import 'calendars';
@import 'formtastic-bootstrap'

View File

@@ -0,0 +1,134 @@
html {
background-color: #fff;
overflow: hidden;
}
body {
display: flex;
flex-flow: wrap;
height: 100vh;
justify-content: space-between;
flex-direction: column;
}
.header {
height: 200px;
width: 100%
}
svg {
padding-top: 2em;
}
.impulsPath {
fill: none;
stroke: #04669c;
stroke-miterlimit: 1;
stroke-width: 6px;
stroke-dasharray: 1946.243;
stroke-dashoffset: 0;
stroke-linejoin: round;
stroke-linecap: round;
animation: dash 10s ease-out infinite;
animation-direction: normal;
}
.FET-logotext-stroke {
fill: #fff;
}
#FET-logotext {
opacity: 0;
animation: logotext 10s ease-in infinite;
}
.content-area {
height: auto;
width: 100%;
}
.footer {
width: 100%;
height: 150px;
background-color: #04669c;
padding-bottom: 10px;
display: flex;
flex-wrap: nowrap;
justify-content: space-between;
color: #fff;
flex-basis: bottom;
}
.footer h3,
p {
margin: 0;
padding: 0 20px;
font-family: Helvetica, Arial;
letter-spacing: 0.1em;
}
.footer h3 {
padding-top: 20px;
}
.footer .adress {
margin: auto;
text-align: left;
}
.footer .contact {
margin: auto;
text-align: center;
}
.footer .servicecontainer{
display: inline-flex;
margin: auto;
}
.footer .servicecontainer .servicetime {
margin: auto;
text-align: right;
}
.footer .servicecontainer .servicetime #time {
font-size: 0.7em
}
.footer .servicecontainer .servicestatus{
margin: auto;
width:20px;
height: 100vh; /* height: 100%;*/
padding-right: 30px;
background-color: #fff;
}
/*K E Y F R A M E S*/
@keyframes dash {
from {
stroke-dashoffset: 1946.243;
opacity: 0;
stroke-width: 0.5;
}
to {
opacity: 1;
stroke-dashoffset: 0;
stroke-width: 5px;
}
}
@keyframes logotext {
from {
opacity: 0;
}
to {
opacity: 1;
}
}

View File

@@ -44,98 +44,6 @@ a:hover {
ul.linkbox-list
{
max-width:70em;
margin-left:auto;
margin-right:auto;
}
a.linkbox, div.contentbox
{
display:block;
padding:5px;
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
{
}
ul.linkbox-list li
{
margin-bottom:10px;
}
div.contentbox div.contentbox
{ {
margin: 5px; margin: 5px;
@@ -175,28 +83,6 @@ div.smallspan {
min-height:0; min-height:0;
} }
ul.linklist
{max-width:100%;
padding:0;
margin:5px;
}
ul.linklist li{
list-style:none;
margin-bottom:2px;
}
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;
}
form.inline div { form.inline div {
float:left;} float:left;}

View File

@@ -0,0 +1,61 @@
ul.linkbox-list
{
max-width:70em;
margin-left:auto;
margin-right:auto;
}
a.linkbox, div.contentbox
{
display:block;
padding:5px;
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 { }
ul.linkbox-list li {
margin-bottom:10px;
}
ul.linklist {
max-width:100%;
padding:0;
margin:5px;
}
ul.linklist li {
list-style:none;
margin-bottom:2px;
}
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;
}

View File

@@ -16,6 +16,7 @@
*= require jquery.datetimepicker *= require jquery.datetimepicker
*= require jquery.ui.dialog *= require jquery.ui.dialog
*= require jquery.ui.autocomplete *= require jquery.ui.autocomplete
*= require jquery.ui.progressbar
*= require jquery.ui.tabs *= require jquery.ui.tabs
* require 'bootstrap' * require 'bootstrap'
* require 'neuigkeiten' * require 'neuigkeiten'
@@ -117,5 +118,6 @@ $box-border-radius:0px;
$box-background: white; $box-background: white;
@import 'layout'; @import 'layout';
@import 'linkboxes';
@import 'calendars'; @import 'calendars';
@import 'formtastic-bootstrap' @import 'formtastic-bootstrap'

View File

@@ -0,0 +1,61 @@
ul.linkbox-list
{
max-width:70em;
margin-left:auto;
margin-right:auto;
}
a.linkbox, div.contentbox
{
display:block;
padding:5px;
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 { }
ul.linkbox-list li {
margin-bottom:10px;
}
ul.linklist {
max-width:100%;
padding:0;
margin:5px;
}
ul.linklist li {
list-style:none;
margin-bottom:2px;
}
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;
}

View File

@@ -1,4 +1,6 @@
/* This is the main file for theme "blue2"
*/
/* /*
* This is a manifest file that'll be compiled into application.css, which will include all the files * This is a manifest file that'll be compiled into application.css, which will include all the files
* listed below. * listed below.
@@ -15,6 +17,8 @@
*= require jquery.datetimepicker *= require jquery.datetimepicker
*= require jquery.ui.dialog *= require jquery.ui.dialog
*= require jquery.ui.tabs *= require jquery.ui.tabs
*= require jquery.ui.progressbar
* require 'bootstrap' * require 'bootstrap'
* require 'neuigkeiten' * require 'neuigkeiten'
@@ -89,9 +93,11 @@ div.header {
height:45px; height:45px;
margin-bottom: 0 px margin-bottom: 0 px
} }
div.header_span { div.header_span {
background:white background:white
} }
div.header h1 { div.header h1 {
padding:0; padding:0;
margin:4px; margin:4px;
@@ -117,16 +123,16 @@ $navbar-li-minwidth: 0;
$box-border: lightgray solid 1px; $box-border: lightgray solid 1px;
$box-border-radius:4px; $box-border-radius:6px;
$box-background: white; $box-background: white;
@import 'layout'; @import 'layout';
@import 'calendars'; @import 'calendars';
@import 'formtastic-bootstrap'; @import 'formtastic-bootstrap';
@import 'linkboxes';
@import 'extra'; @import 'extra';
body { body {
background: #FFF; //#EFEFEF; background: #FCFCFC; //#EFEFEF;
background-size:100%; background-size:100%;
} }

View File

@@ -0,0 +1,142 @@
ul.linkbox-list
{
max-width:70em;
margin-left:auto;
margin-right:auto;
}
ul.linkbox-list > li {
margin-bottom:0px;
}
ul.linkbox-list > li:first-child a.linkbox {
border-top-left-radius:$box-border-radius;
border-top-right-radius:$box-border-radius;
border: $box-border;
}
ul.linkbox-list > li:last-child a.linkbox {
border-bottom-left-radius:$box-border-radius;
border-bottom-right-radius:$box-border-radius;
}
ul.linkbox-list > li a.linkbox {
border-radius: 0;
border-top: none;
}
ul.linkbox-list > li a.linkbox:hover {
z-index:2000
}
a.linkbox, div.contentbox
{
display:block;
padding:5px;
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 { }
ul.linklist {
max-width:100%;
padding:0;
margin:5px;
}
ul.linklist li {
list-style:none;
}
ul.linklist li a i{
vertical-align:middle;
margin-right:6px;
font-size:2em;}
ul.linklist > li a.linkbox {
border-radius: 0;
border: $box-border;
/* border-color:white;*/
padding-top: 7px;
margin-bottom:0px;
margin-top:0px;
/* border-bottom: $box-border;
border-top: $box-border;
*/
border-color:white;
/* border-bottom-color:white; */
}
ul.linklist > li a.linkbox:hover {
border: $box-border;
border-top: $box-border;
box-shadow: none;
border-color: black;
background: #FCFCFC;
/* margin: 0;
margin-bottom:0px;*/
}
ul.linklist > li:first-child a.linkbox {}
ul.linklist > li:last-child a.linkbox {
}
ul.linklist > li:first-child a.linkbox {
border-top-left-radius:$box-border-radius;
border-top-right-radius:$box-border-radius;
/* border-top:$box-border; */
margin-top:0px;
}
ul.linklist > li:last-child a.linkbox {
border-bottom-left-radius:$box-border-radius;
border-bottom-right-radius:$box-border-radius;
/* border-bottom:$box-border;*/
margin-bottom:0px;
}
ul.linklist {
border-radius: $box-border-radius;
border: $box-border;
/* box-shadow: 0px 0px 1px 1px lightgray;*/
}
span.linklist li a {
padding:5px;
border: $box-border;
background: $box-background;
display:block;
float:left;
}

View File

@@ -9,15 +9,19 @@
if params[:locale] if params[:locale]
if I18n.available_locales.include?(params[:locale].to_sym) if I18n.available_locales.include?(params[:locale].to_sym)
session[:locale] = params[:locale] session[:locale] = params[:locale]
else else
flash.now[:notice]= "#{params[:locale]} translation not available" flash.now[:notice]= "#{params[:locale]} translation not available"
logger.error flash.now[:notice] logger.error flash.now[:notice]
end end
end end
I18n.locale = session[:locale] || request.env['HTTP_ACCEPT_LANGUAGE'].scan(/^de|en/).first || I18n.default_locale http_header=request.env['HTTP_ACCEPT_LANGUAGE']
unless http_header.nil?
ht= http_header.scan(/^de|en/).first
else
ht=nil
end
I18n.locale = session[:locale] || I18n.default_locale
# removed ht from selection add || ht to check http header
session[:locale] = I18n.locale session[:locale] = I18n.locale
end end
@@ -46,7 +50,8 @@
else else
flash[:error] = "You must first login to view this page" flash[:error] = "You must first login to view this page"
session[:user_return_to] = request.url session[:user_return_to] = request.url
redirect_to "/users/sign_in" return redirect_to "/users/sign_in"
end end
end end
@@ -55,7 +60,7 @@ u=current_user
if ! u.try(:preferredtheme).nil? and ThemesForRails.available_theme_names.include?(u.preferredtheme) if ! u.try(:preferredtheme).nil? and ThemesForRails.available_theme_names.include?(u.preferredtheme)
u.preferredtheme u.preferredtheme
else else
"blue1" "blue2"
end end
end end

View File

@@ -32,6 +32,7 @@ class BeispieleController < ApplicationController
def new def new
@beispiel = Beispiel.new @beispiel = Beispiel.new
@beispiel.lva = Lva.find_by_id(params[:lva_id]) @beispiel.lva = Lva.find_by_id(params[:lva_id])
@beispiel.flag_delete=false
@backlink = @beispiel.lva.nil? ? root_url : lva_path(@beispiel.lva) @backlink = @beispiel.lva.nil? ? root_url : lva_path(@beispiel.lva)
respond_to do |format| respond_to do |format|
format.html # new.html.erb format.html # new.html.erb
@@ -43,6 +44,7 @@ class BeispieleController < ApplicationController
@beispiel = Beispiel.find(params[:id]) @beispiel = Beispiel.find(params[:id])
@beispiel.lecturer = Lecturer.find(params[:beispiel][:lecturer_id]) @beispiel.lecturer = Lecturer.find(params[:beispiel][:lecturer_id])
@beispiel.save @beispiel.save
if @beispiel.save if @beispiel.save
format.html { redirect_to @backlink, notice: 'Beispiel was successfully updated.' } format.html { redirect_to @backlink, notice: 'Beispiel was successfully updated.' }
format.js {render text: "alert(\"updated\");"} format.js {render text: "alert(\"updated\");"}
@@ -66,8 +68,9 @@ class BeispieleController < ApplicationController
logger.info "Creating Beispiel..." logger.info "Creating Beispiel..."
@lva = Lva.find_by_id(params[:lva_id]) @lva = Lva.find_by_id(params[:lva_id])
params.delete(:lva_id) params.delete(:lva_id)
params[:beispiel][:flag_delete]=false
@beispiel = Beispiel.new(params[:beispiel]) @beispiel = Beispiel.new(params[:beispiel])
@beispiel.flag_delete=false
logger.info "New Beispiel: #{params.inspect}" logger.info "New Beispiel: #{params.inspect}"
@beispiel.name=@beispiel.beispieldatei.filename @beispiel.name=@beispiel.beispieldatei.filename

View File

@@ -157,7 +157,7 @@ class DocumentsController < ApplicationController
@results = Document.search do @results = Document.search do
fulltext params['query'] do fulltext params['query'] do
fields :name, :text, :meeting fields :name, :text, :meeting
highlight :text highlight :text,:name,:meeting
end end
end end
@res=[] @res=[]

View File

@@ -0,0 +1,22 @@
class EmailsController < ApplicationController
before_filter :authorize
def index
end
def daily_reminder
ActionMailer::Base.default_url_options[:host] = request.host_with_port
@mail =NewsMailer.daily_reminder(current_user.id)
if params[:send]
usr=User.where(:flag_getemails => true)
usr.each do |u|
NewsMailer.daily_reminder(current_user.id).deliver
end
end
render layout: false
end
protected
def authorize
authorize! :emails, User
end
end

View File

@@ -9,18 +9,17 @@ class FetprofilesController < ApplicationController
@fetprofiles = Fetprofile.order(:vorname,:nachname) if params[:filter]== "all" @fetprofiles = Fetprofile.order(:vorname,:nachname) if params[:filter]== "all"
@fetprofiles = Fetprofile.where(:active=>false).order(:nachname,:vorname) if params[:filter]== "notactive" @fetprofiles = Fetprofile.where(:active=>false).order(:nachname,:vorname) if params[:filter]== "notactive"
@gremientabs = Gremium.tabs @gremientabs = Gremium.tabs
@toolbar_elements << {:hicon=>'icon-plus', :text=> I18n.t('profile.new_profile'),:path => new_fetprofile_path(@fetprofile) } if can? :new, @fetprofile @toolbar_elements << {:hicon=>'icon-plus', :text=> I18n.t('profile.new_profile'),:path => new_fetprofile_path(@fetprofile) } if can? :new, @fetprofile
respond_to do |format| respond_to do |format|
format.html # index.html.erb format.html # index.html.erb
end end
end end
def internlist def internlist
@fetprofiles = Fetprofile.order(:vorname,:nachname) @fetprofiles = Fetprofile.order(:vorname,:nachname)
end end
# GET /fetprofiles/1 # GET /fetprofiles/1
# GET /fetprofiles/1.json # GET /fetprofiles/1.json

View File

@@ -19,6 +19,11 @@ class HomeController < ApplicationController
end end
def dev def dev
end
def infoscreen
authorize! :infoscreen, User
@neuigkeiten = Neuigkeit.accessible_by(current_ability, :show).where(flag_infoscreen: true)
render layout: false
end end
def kontakt def kontakt
t=YAML.load_file("#{::Rails.root.to_s}/config/contact_topic.yml") t=YAML.load_file("#{::Rails.root.to_s}/config/contact_topic.yml")

View File

@@ -3,6 +3,7 @@ class NeuigkeitenController < ApplicationController
before_filter :load_toolbar_elements, :only=>[:show,:find_link] before_filter :load_toolbar_elements, :only=>[:show,:find_link]
before_filter :load_toolbar_elements_edit, :only=>[:edit] before_filter :load_toolbar_elements_edit, :only=>[:edit]
acts_as_flagable
@@ -49,7 +50,7 @@ class NeuigkeitenController < ApplicationController
end end
@calentry=ce @calentry=ce
ce.object=@neuigkeit ce.object=@neuigkeit
@neuigkeit.calentry=ce @neuigkeit.calentries<<ce
@neuigkeit.save @neuigkeit.save
render 'edit' render 'edit'
@@ -119,12 +120,15 @@ end
end end
end end
def mail_preview def mail_preview
ActionMailer::Base.default_url_options[:host] = request.host_with_port
@neuigkeit = Neuigkeit.find(params[:id]) @neuigkeit = Neuigkeit.find(params[:id])
@user=current_user @user=current_user
@ability=Ability.new(@user) @ability=Ability.new(@user)
@mail = NewsMailer.neuigkeit_mail("all@fet.at", params[:id])
authorize! :publish, @neuigkeit authorize! :publish, @neuigkeit
render template: "news_mailer/neuigkeit_mail", layout: false render layout: false
end end
def newsletter_preview def newsletter_preview
authorize! :publish, Neuigkeit authorize! :publish, Neuigkeit
@@ -141,9 +145,10 @@ end
@calentries<< Calentry.new @calentries<< Calentry.new
end end
def find_link def find_link
@rubrik=@neuigkeit.rubrik @rubrik=@neuigkeit.rubrik
if can?(:shownonpublic, Rubrik) if can?(:shownonpublic, Rubrik)
@rubriken = Rubrik.all @rubriken = Rubrik.all
else else
@rubriken = Rubrik.where(:public=>true) @rubriken = Rubrik.where(:public=>true)
@@ -152,7 +157,8 @@ end
@calentries1=@neuigkeit.calentries @calentries1=@neuigkeit.calentries
nlink_search = Neuigkeit::LINKTYPES.clone nlink_search = Neuigkeit::LINKTYPES.clone
nlink_search.collect!{|t| t.constantize} nlink_search.collect!{|t| t.constantize}
# @nlink_search.collect!{|t| t.search(params[:query]).limit(2)}
# @nlink_search.collect!{|t| t.search(params[:query]).limit(2)}
@results= Sunspot.search nlink_search do @results= Sunspot.search nlink_search do
fulltext params[:query] fulltext params[:query]
end end
@@ -164,6 +170,7 @@ end
end end
def create_link def create_link
@neuigkeit = Neuigkeit.find(params[:id]) @neuigkeit = Neuigkeit.find(params[:id])
@@ -174,6 +181,7 @@ end
format.js format.js
end end
end end
def delete_link def delete_link
@neuigkeit = Neuigkeit.find(params[:id]) @neuigkeit = Neuigkeit.find(params[:id])
@nlink = @neuigkeit.nlinks.find(params[:nlink_id]) @nlink = @neuigkeit.nlinks.find(params[:nlink_id])
@@ -183,6 +191,7 @@ end
format.js format.js
end end
end end
def create def create
@neuigkeit = Neuigkeit.new(params[:neuigkeit]) @neuigkeit = Neuigkeit.new(params[:neuigkeit])
@neuigkeit.author=current_user @neuigkeit.author=current_user

View File

@@ -16,7 +16,7 @@ class RubrikenController < ApplicationController
@rubriken= Rubrik.accessible_by(current_ability, :show) @rubriken= Rubrik.accessible_by(current_ability, :show)
@neuigkeiten = Neuigkeit.accessible_by(current_ability, :list).page(params[:page]).per(3) @neuigkeiten = Neuigkeit.accessible_by(current_ability, :list).page(params[:page]).per(3)
@calentries= (@rubriken.map {|r| r.calendar}).collect(&:calentries).flatten.select {|c| c.object !=nil} @calentries= (@rubriken.map {|r| r.calendar.calentries.of_month(Date.new(params[:year].to_i,params[:month].to_i,1))}).flatten.select {|c| c.object !=nil}
respond_to do |format| respond_to do |format|
format.html format.html
format.js {render action: :show} format.js {render action: :show}

View File

@@ -2,11 +2,23 @@
class Users::OmniauthCallbacksController < Devise::OmniauthCallbacksController class Users::OmniauthCallbacksController < Devise::OmniauthCallbacksController
skip_before_filter :verify_authenticity_token skip_before_filter :verify_authenticity_token
def failure def failure
# flash[:notice] = "Failure #{Hash.new(request.env)} #{Hash.new(params)}" # flash[:notice] = "Failure #{Hash.new(request.env)} #{Hash.new(params)}"
#redirect_to new_user_registration_url , :notice=>"Omniauth Login failed" #redirect_to new_user_registration_url , :notice=>"Omniauth Login failed"
super super
end end
def developer
if Rails.env.development?
@user= User.find_for_developer_oauth(request.env["omniauth.auth"],current_user)
if @user
sign_in_and_redirect @user, event: :authentication
else
redirect_to new_user_registration_url
end
else
flash[:notice]=flash[:notice] + "Still not logged in "
redirect_to new_user_registration_url
end
end
def facebook def facebook
# You need to implement the method below in your model (e.g. app/models/user.rb) # 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) @user = User.find_for_facebook_oauth(request.env["omniauth.auth"], current_user)
@@ -23,7 +35,7 @@ class Users::OmniauthCallbacksController < Devise::OmniauthCallbacksController
end end
def ldap def ldap
logger.debug current_user.to_s logger.debug current_user.to_s
@user=User.find_for_ldap_oauth(request.env["omniauth.auth"],current_user) @user=User.find_for_ldap_oauth(request.env["omniauth.auth"],current_user)
# @user=User.find_for_ldap_oauth(session["devise.ldap_data"],current_user) # @user=User.find_for_ldap_oauth(session["devise.ldap_data"],current_user)
# @user=User.first # @user=User.first

View File

@@ -1,8 +1,22 @@
class UsersController < ApplicationController class UsersController < ApplicationController
def index def index
authorize!(:index,User)
@users = User.all @users = User.all
end end
def show
@user=User.find(params[:id])
authorize!(:show, @user)
end
def set_preferred_theme
@user=User.find(params[:id])
authorize!(:set_preferred_theme, @user)
@user.preferredtheme=params[:theme]
@user.save
redirect_to root_url
end
def add_role def add_role
authorize!(:add_role, User)
@user= User.find(params[:id]) @user= User.find(params[:id])
if (params[:role]=="fetuser" && can?(:addfetuser,User)) if (params[:role]=="fetuser" && can?(:addfetuser,User))
@user.add_role(params[:role]) @user.add_role(params[:role])
@@ -13,6 +27,8 @@ class UsersController < ApplicationController
redirect_to users_url redirect_to users_url
end end
def fb_set_default_publish_page def fb_set_default_publish_page
authorize!(:doadmin, User)
if Fetsite::Application.config.facebookconfig_enabled if Fetsite::Application.config.facebookconfig_enabled
if params["page"].nil? || !(current_user.provider=="facebook") if params["page"].nil? || !(current_user.provider=="facebook")
redirect_to intern_home_index_path redirect_to intern_home_index_path
@@ -27,6 +43,7 @@ class UsersController < ApplicationController
end end
def all_update def all_update
authorize! :doadmin,User
params[:users].each do |id,u| params[:users].each do |id,u|
user=User.find(id) user=User.find(id)
user.fetprofile = Fetprofile.find(u[:fetprofile_id].to_i) if u[:fetprofile_id].to_i>0 user.fetprofile = Fetprofile.find(u[:fetprofile_id].to_i) if u[:fetprofile_id].to_i>0

View File

@@ -42,8 +42,9 @@ m.save
# current_url1({:locale=>target_locale}) .sub "/"+I18n.locale.to_s+"/", "/"+target_locale.to_s+"/" # current_url1({:locale=>target_locale}) .sub "/"+I18n.locale.to_s+"/", "/"+target_locale.to_s+"/"
language_path(locale: target_locale) language_path(locale: target_locale)
end end
def ffi1_icon (name) def ffi1_icon (name)
content_tag("i","", class: "ficon ffi1-"+name ) content_tag("i", "", class: "ficon ffi1-" + name )
end end
def ffi2_icon (name) def ffi2_icon (name)
@@ -54,8 +55,11 @@ m.save
end end
def fa_stack(icon1, icon2) def fa_stack(icon1, icon2)
content_tag("span", content_tag("span", content_tag("i","", class: "ficon "+" fa-"+icon1+" fa fa-stack-1x" ) + content_tag("i","", class: "ficon "+" fa-"+icon2+" fa fa-stack-2x" ),class: "fa-stack "),class:"fa-stack-sm") h_1 = content_tag("span", content_tag("i","", class: "ficon "+" fa-"+icon1+" fa fa-stack-1x" ) + content_tag("i","", class: "ficon "+" fa-"+icon2+" fa fa-stack-2x" ),class: "fa-stack ")
h_2 = content_tag("span", h_1 ,class: "fa-stack-sm")
h_2
end end
def ffi1_list def ffi1_list
y=YAML.load_file("#{::Rails.root.to_s}/config/flatfeticon1.yml") y=YAML.load_file("#{::Rails.root.to_s}/config/flatfeticon1.yml")

View File

@@ -1,4 +1,4 @@
class CheckboxAutocompleteInput < FormtasticBootstrap::Inputs::CheckboxInput class CheckboxAutocompleteInput < FormtasticBootstrap::Inputs::CheckBoxesInput
def input_html_options def input_html_options
super super
#super.merge(:class => "input-append date") #super.merge(:class => "input-append date")

View File

@@ -1,23 +1,44 @@
# -*- coding: utf-8 -*-
class NewsMailer < ActionMailer::Base class NewsMailer < ActionMailer::Base
default from: "salzamt@fet.at" default from: "salzamt@fet.at"
helper :plugins helper :plugins
def current_user
@user
end
def neuigkeit_mail(email, neuigkeit_id) def neuigkeit_mail(email, neuigkeit_id)
@neuigkeit= Neuigkeit.find(neuigkeit_id) @neuigkeit= Neuigkeit.find(neuigkeit_id)
@user=User.first @user=User.first
@ability=Ability.new(@user) @ability=Ability.new(@user)
subject = @neuigkeit.title subject = @neuigkeit.title
subject = subject + " email: " + email if Rails.env=="development" subject = subject.to_s + " email: " + email.to_s if Rails.env=="development"
email = "andis@fet.at" if Rails.env=="development" email = "andis@fet.at" if Rails.env=="development"
email="andis@fet.at" email="andis@fet.at"
mail(to: email, subject: subject) mail(to: email, subject: subject)
render locals: {current_user: User.first} render locals: {current_user: User.first}
end end
def daily_newsletter(user_id) def daily_newsletter(user_id)
user=User.find(user_id) user=User.find(user_id)
self.message.perform_deliveries = false unless user.flag_getemails
ability= Ability.new(user) ability= Ability.new(user)
@neuigkeiten=Neuigkeit.accessible_by(ability).published_scope.where("cache_order<2") @neuigkeiten=Neuigkeit.accessible_by(ability).published_scope.where("cache_order<2")
end end
def daily_reminder(user_id)
user=User.find(user_id)
@user=user
self.message.perform_deliveries = false unless user.flag_getemails
@ability = Ability.new(user)
@calentries = Calentry.of_month(Date.today).limit(100)
# @neuigkeiten=Neuigkeit.accessiblße_by(ability).published_scope.where("cache_order<2")
mail(to: user.email, content_type: "text/html", subject: "sdf")
render locals: {c_user: user}
end
private
include CanCan::ControllerAdditions
def current_user
@user
end
def current_ability
@ability
end
end end

View File

@@ -1,7 +1,10 @@
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
require 'ipaddr'
class Ability class Ability
include CanCan::Ability include CanCan::Ability
def initialize(user,request=nil,key=nil) def initialize(user,request=nil,key=nil)
tunet=IPAddr.new("128.131.95.0/24")
local=IPAddr.new("127.0.0.1")
loggedin=!(user.nil?) loggedin=!(user.nil?)
unless key.nil? unless key.nil?
k=Key.find_by_uuid(key) k=Key.find_by_uuid(key)
@@ -10,6 +13,9 @@ class Ability
end end
end end
user ||= User.new # guest user (not logged in) user ||= User.new # guest user (not logged in)
if (user.has_role?("fetuser") || user.has_role?("fetadmin") || tunet.include?(IPAddr.new(request.remote_ip)) || local.include?(IPAddr.new(request.remote_ip)))
can :infoscreen, User
end
if( user.has_role?("fetuser") || user.has_role?("fetadmin")) if( user.has_role?("fetuser") || user.has_role?("fetadmin"))
can [:show,:answer, :create,:new, :create_from_template, :flag], Survey::Question can [:show,:answer, :create,:new, :create_from_template, :flag], Survey::Question
@@ -152,6 +158,7 @@ end
can :show, Neuigkeit, :cache_is_published=>true, :rubrik=>{:public=>true} can :show, Neuigkeit, :cache_is_published=>true, :rubrik=>{:public=>true}
if loggedin if loggedin
can :show, :id => user.id
end end
if( user.has_role?("fetuser") || user.has_role?("fetadmin")) if( user.has_role?("fetuser") || user.has_role?("fetadmin"))
@@ -159,6 +166,7 @@ end
can :showintern, Neuigkeit can :showintern, Neuigkeit
can :showintern, Rubrik can :showintern, Rubrik
can :seeintern, User can :seeintern, User
can :set_preferred_theme, user
can :list, Neuigkeit can :list, Neuigkeit
can :shownonpublic, Rubrik can :shownonpublic, Rubrik
can :manage, Nlink can :manage, Nlink
@@ -169,8 +177,12 @@ end
if user.has_role?("fetadmin") if user.has_role?("fetadmin")
can :addfetuser, User can :addfetuser, User
can :addfetadmin, User can :addfetadmin, User
can :add_role, User
can :show, User
can :index, User
can :edit, User can :edit, User
can :manage, User can :manage, User
can :set_preferred_theme, User
end end
if user.has_role?("newsadmin") || user.has_role?( "fetadmin") || user.has_role?( "fetuser") if user.has_role?("newsadmin") || user.has_role?( "fetadmin") || user.has_role?( "fetuser")
@@ -227,7 +239,8 @@ end
can :doadmin, User can :doadmin, User
end end
unless user.has_role?("fetadmin") if user.has_role?("fetadmin")
can :emails,User
end end
end end

View File

@@ -14,14 +14,14 @@
class Calentry < ActiveRecord::Base class Calentry < ActiveRecord::Base
attr_accessible :ende, :start, :summary, :typ,:calendar_ids, :calendar, :dauer, :object_id, :object_type attr_accessible :ende, :start, :summary, :typ,:calendar_ids, :calendar, :dauer, :object_id, :object_type
belongs_to :calendar belongs_to :calendar, touch: true
#belongs_to :neuigkeit #belongs_to :neuigkeit
validates :start, :presence => true validates :start, :presence => true
validates :object, :presence => true validates :object, :presence => true
validates :typ, :presence => true validates :typ, :presence => true
before_save :get_public before_save :get_public
belongs_to :object, polymorphic: true, touch: true # Objekt zu dem der Calentry gehört (derzeit ein Newsartikel) belongs_to :object, polymorphic: true, touch: true # Objekt zu dem der Calentry gehört (derzeit ein Newsartikel)
scope :of_month, ->(d) {where("start >= ? AND start <= ?", d.beginning_of_month, d.end_of_month)}
scope :upcoming, ->{ where("start >= ?", Time.now).order(:start)} scope :upcoming, ->{ where("start >= ?", Time.now).order(:start)}
scope :recent,-> { where("start <= ?", Time.now).order(:start).reverse_order} scope :recent,-> { where("start <= ?", Time.now).order(:start).reverse_order}
validate do |entry| validate do |entry|
@@ -31,7 +31,10 @@ class Calentry < ActiveRecord::Base
end end
resourcify resourcify
def self.updated_at
#Calentry.select("MAX(updated_at) as m_updated_at").first.m_updated_at
Calentry.all.max_by(&:updated_at).updated_at
end
def is_upcomming? def is_upcomming?
self.start > Time.now self.start > Time.now
end end

View File

@@ -24,7 +24,7 @@ class Document < ActiveRecord::Base
"document_"+self.id.to_s "document_"+self.id.to_s
end end
def self.ether def self.ether
EtherpadLite.connect('http://www.fet.at/etherpad', File.new('/srv/etherpad/etherpad-lite/APIKEY.txt')) EtherpadLite.connect('https://www.fet.at/etherpad', File.new('config/etherpad/APIKEY.txt'))#https://www.etherpad.fet.at
end end
def create_pdf def create_pdf
require "open3" require "open3"
@@ -71,12 +71,21 @@ class Document < ActiveRecord::Base
def move_to_etherpad def move_to_etherpad
unless self.is_etherpad? || self.id.nil? unless self.is_etherpad? || self.id.nil?
self.etherpadkey="document_"+ self.id.to_s self.etherpadkey="document_"+ self.id.to_s
self.ep_pad.html = '<div>'+self.text+'</div>'
if self.text.nil?
self.ep_pad.html = '<div>'+"text"+'</div>'
else
self.ep_pad.html = '<div>'+self.text+'</div>'
end
end end
end end
def dump_to_etherpad def dump_to_etherpad
if self.is_etherpad? if self.is_etherpad?
self.ep_pad.html = '<div>'+self.text+'</div>' if self.text.nil?
self.ep_pad.html = '<div>'+"text"+'</div>'
else
self.ep_pad.html = '<div>'+self.text+'</div>'
end
else else
self.move_to_etherpad self.move_to_etherpad
end end
@@ -102,7 +111,7 @@ class Document < ActiveRecord::Base
end end
text :name, :boost=>4.0, :stored=> true text :name, :boost=>4.0, :stored=> true
text :meeting, stored: true do |d| text :meeting, stored: true do |d|
(d.parent_type == "Meeting")? d.try(:parent).try(:text).to_s : "" (d.parent.is_a?(Meeting))? d.try(:parent).try(:text).to_s : ""
end end
end end
def maketoc def maketoc

View File

@@ -32,13 +32,13 @@ class Fetprofile < ActiveRecord::Base
has_many :nlinks, as: :link has_many :nlinks, as: :link
def validate_birthday def validate_birthday
unless birth_month.nil? || birth_day.nil? unless birth_month.nil? || birth_day.nil?
unless Date.valid_date?((birth_year.nil?) ? Date.today.year : birth_year, birth_month, birth_day) 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_month, "Invalides Datum")
errors.add(:birth_day, "Invalides Datum") errors.add(:birth_day, "Invalides Datum")
v= false v= false
else else
v= true v= true
end end
else else
v= false v= false
end end
@@ -78,3 +78,5 @@ class Fetprofile < ActiveRecord::Base
end end
end end

View File

@@ -23,12 +23,16 @@ class Gremium < ActiveRecord::Base
has_many :memberships, dependent: :destroy # Mitgliedschaften bei dem Gremium has_many :memberships, dependent: :destroy # Mitgliedschaften bei dem Gremium
has_many :nlinks, as: :link, dependent: :destroy has_many :nlinks, as: :link, dependent: :destroy
# scope :search, ->(query) {where("gremien.name like ? or gremien.desc like ?", "%#{query}%", "%#{query}%")} # scope :search, ->(query) {where("gremien.name like ? or gremien.desc like ?", "%#{query}%", "%#{query}%")}
# has_many :members, through: :memberships
searchable do searchable do
text :desc text :desc
text :name, :boost=>4.0 text :name
end end
belongs_to :thema # Gehört zu einem Thema belongs_to :thema # Gehört zu einem Thema
validates :name, :presence=>true
validates :typ, :presence=>true
validates :typ, :inclusion =>{ in: Gremium::TYPEN.keys()}
scope :tabs, -> { where(:typ => [1,3]).order(:typ).order(:name) } # Gremien die in Tabs angezeigt werden (Alle Anderen nur in der Liste scope :tabs, -> { where(:typ => [1,3]).order(:typ).order(:name) } # Gremien die in Tabs angezeigt werden (Alle Anderen nur in der Liste

View File

@@ -18,21 +18,6 @@
# typ :string(255) # typ :string(255)
# #
# == Schema Information
#
# Table name: lvas
#
# id :integer not null, primary key
# name :string(255)
# desc :text
# ects :decimal
# lvanr :string(255)
# stunden :decimal
# created_at :datetime not null
# updated_at :datetime not null
# modul_id :integer
# semester_id :integer
class Lva < ActiveRecord::Base class Lva < ActiveRecord::Base
ERLAUBTE_TYPEN = ['VO', 'UE', 'VU', 'LU', 'SE', 'PR', 'andere']; ERLAUBTE_TYPEN = ['VO', 'UE', 'VU', 'LU', 'SE', 'PR', 'andere'];
translates :desc,:pruefungsinformation, :fallbacks_for_empty_translations => true, :versioning=> :paper_trail #true #{:gem=>:paper_trail} translates :desc,:pruefungsinformation, :fallbacks_for_empty_translations => true, :versioning=> :paper_trail #true #{:gem=>:paper_trail}
@@ -113,7 +98,7 @@ class Lva < ActiveRecord::Base
url url
end end
# this should be more DRY
def load_tissdata def load_tissdata
urlp="https://tiss.tuwien.ac.at/api/course/"+ lvanr.to_s.gsub(".","")+"-" urlp="https://tiss.tuwien.ac.at/api/course/"+ lvanr.to_s.gsub(".","")+"-"
begin begin
@@ -202,7 +187,8 @@ class Lva < ActiveRecord::Base
end end
end end
# Why is this an instance method??
# How is it used?
def update_multiple(hash) def update_multiple(hash)
newlvas=[] newlvas=[]
params["lvas"].each do |i,l| params["lvas"].each do |i,l|
@@ -237,7 +223,7 @@ class Lva < ActiveRecord::Base
lecturers.map { |l| l.name } lecturers.map { |l| l.name }
end end
end end
# is this used? in which context?
def self.update_multiple_with_modul(hash,modul) def self.update_multiple_with_modul(hash,modul)
newlvas=[] newlvas=[]
hash.each do |i,l| hash.each do |i,l|
@@ -263,7 +249,7 @@ class Lva < ActiveRecord::Base
end end
# is this used? in which context?
def read_et_forum def read_et_forum
lva=self lva=self
url=lva.forumlink url=lva.forumlink

View File

@@ -1,40 +1,58 @@
# coding: utf-8
# This class represents a single meeting of a group or the whole Fachschaft.
#
class Meeting < ActiveRecord::Base class Meeting < ActiveRecord::Base
belongs_to :parent, :polymorphic=>true, touch: true
belongs_to :meetingtyp
attr_accessible :desc, :intern, :name, :parent_id, :parent_type, :calentry,:calentry_attributes, :meetingtyp_id attr_accessible :desc, :intern, :name, :parent_id, :parent_type, :calentry,:calentry_attributes, :meetingtyp_id
# Meeting can belong to different kind of parents e.g. topics
belongs_to :parent, :polymorphic=>true, touch: true
# Each meeting should have a type, for more information see MeetingTyp
belongs_to :meetingtyp
# Belongs to a news article, that is usually the Announcement of that meeting
belongs_to :neuigkeit, touch: true belongs_to :neuigkeit, touch: true
# has one protocol of type Document, which is of typ=10=protocol
has_one :protocol, :class_name=>'Document', :conditions=>{:typ=>10}, :as=>:parent has_one :protocol, :class_name=>'Document', :conditions=>{:typ=>10}, :as=>:parent
# has one agenda of type Document
has_one :agenda , :as=>:parent,:conditions=>{:typ=>11}, :class_name=>'Document' has_one :agenda , :as=>:parent,:conditions=>{:typ=>11}, :class_name=>'Document'
# has one calentry which contains the date and time of this meeting
has_one :calentry, as: :object, :dependent=> :destroy has_one :calentry, as: :object, :dependent=> :destroy
# has one calendar through the meetingtyp, thus each meeting is put into a calendar
has_one :calendar, :through=>:meetingtyp has_one :calendar, :through=>:meetingtyp
# has one rubrik, thus it is associated to a rubrik
has_one :rubrik, :through=>:meetingtyp has_one :rubrik, :through=>:meetingtyp
# scope upcomming only contains meetings in the future and 1 hour into the past
scope :upcomming, includes(:calentry).where("calentries.start>?",1.hour.ago) scope :upcomming, includes(:calentry).where("calentries.start>?",1.hour.ago)
default_scope includes(:calentry).order("calentries.start").reverse_order default_scope includes(:calentry).order("calentries.start").reverse_order
accepts_nested_attributes_for :calentry accepts_nested_attributes_for :calentry
# validate :agenda, :presence=>true
# validate :protocol, :presence=>true # Each meeting is required to have a parent otherwise it will not be shown anywhere on the website
validate :parent, :presence=>true validate :parent, :presence=>true
# Each meeting needs a calendar entry
validate :calentry, :presence=>true validate :calentry, :presence=>true
# before each validation fix the calendar entry such that it is always
before_validation :fix_calentry before_validation :fix_calentry
# title is an alias for text
def title def title
self.text self.text
end end
# Text is a text representation of the meeting
def text def text
unless self.meetingtyp.try(:name).to_s.empty? t = self.meetingtyp.try(:name) || self.parent.try(:title) || ""
t = self.meetingtyp.name.to_s+", " t = t + ", " unless t.empty?
else
t=""
t = parent.title.to_s + ", " if self.name.empty?
end
t= t+ self.name.to_s t= t+ self.name.to_s
# t = t + " " + I18n.l(self.calentry.start) unless self.calentry.nil?
t = t +" "+ I18n.t("date.am")+" "+ self.calentry.text unless self.calentry.nil? t = t +" "+ I18n.t("date.am")+" "+ self.calentry.text unless self.calentry.nil?
t t
end end
# Creante an anouncement with an author
# @param user is the author
def create_announcement(user) def create_announcement(user)
if self.neuigkeit.nil? if self.neuigkeit.nil?
n = Neuigkeit.new n = Neuigkeit.new
@@ -48,32 +66,40 @@ class Meeting < ActiveRecord::Base
self.neuigkeit= n self.neuigkeit= n
end end
end end
# Update the title of the announcement to the text of this meeting
# @returns [true] if save was successful
def update_announcement def update_announcement
n=self.neuigkeit n=self.neuigkeit
n.title=self.text n.title=self.text
n.save n.save
end end
# fixing the calendar entry and the calendar
# most importantly the calendar of the calentry
def fix_calentry def fix_calentry
self.calentry.object=self unless self.calentry.nil? self.calentry.object=self unless self.calentry.nil?
self.calentry.calendar = self.meetingtyp.rubrik.calendar self.calentry.calendar = self.meetingtyp.rubrik.calendar
end end
def public? def public?
! (self.intern) ! (self.intern)
end end
# Create a Document that is a protocol for the meeting
def create_protocol def create_protocol
if self.protocol.nil? if self.protocol.nil? # if no protocol exists
d=Document.new d=Document.new
d.typ=10 d.typ=10
d.name="Protokoll" d.name="Protokoll"
unless self.meetingtyp.protocol.nil?
d.text=self.meetingtyp.protocol.text
end
d.save d.save
self.protocol=d self.protocol=d
end end
# what happens if a protocol already exists?
end end
# Create a calender entry for this meeting
def create_calentry def create_calentry
if self.calentry.nil? if self.calentry.nil?
ce =Calentry.new ce =Calentry.new
@@ -86,9 +112,6 @@ class Meeting < ActiveRecord::Base
d=Document.new d=Document.new
d.typ=11 d.typ=11
d.name="Agenda" d.name="Agenda"
unless self.meetingtyp.agenda.nil?
d.text=self.meetingtyp.agenda.text
end
d.save d.save
self.agenda=d self.agenda=d
end end
@@ -112,27 +135,17 @@ class Meeting < ActiveRecord::Base
def update_time_from_protocol def update_time_from_protocol
st= /Beginn[\s:]*([^<>]*)/.match(self.protocol.text)[1].to_s st= /Beginn[\s:]*([^<>]*)/.match(self.protocol.text)[1].to_s
st= /Anfang[\s:]*([^<>]*)/.match(self.protocol.text)[1].to_s if st.empty? st= /Anfang[\s:]*([^<>]*)/.match(self.protocol.text)[1].to_s if st.nil? || st.empty?
self.calentry.start=(self.calentry.start.to_date.to_s + " " +st).to_datetime unless st.empty? self.calentry.start=(self.calentry.start.to_date.to_s + " " +st).to_datetime unless st.nil? || st.empty?
st= /Ende[\s:]*([^<>]*)/.match(self.protocol.text)[1].to_s st= /Ende[\s:]*([^<>]*)/.match(self.protocol.text).try(:second).try(:to_s )
self.calentry.ende=(self.calentry.ende.to_date.to_s + " " +st).to_datetime unless st.empty? self.calentry.ende=(self.calentry.ende.to_date.to_s + " " +st).to_datetime unless st.nil? || st.empty?
end end
def agenda_text def agenda_text
unless self.agenda.nil? return self.agenda.try(:text) || ""
t= self.agenda.text
else
t= ""
end
t
end end
def protocol_text def protocol_text
unless self.protocol.nil? return self.protocol.try(:text) || ""
t= self.protocol.text end
else
t= ""
end
t
end
searchable do searchable do
text :text text :text

View File

@@ -1,7 +1,8 @@
class Meetingtyp < ActiveRecord::Base class Meetingtyp < ActiveRecord::Base
attr_accessible :agendaintern, :desc, :name, :protocolintern, :rubrik_id, :picture attr_accessible :agendaintern, :desc, :name, :protocolintern, :rubrik_id, :picture
belongs_to :rubrik belongs_to :rubrik
validate :rubrik, :presence=>true validates :rubrik, :presence=>true
validates :name, :presence=>true
has_many :meetings has_many :meetings
has_one :calendar, through: :rubrik has_one :calendar, through: :rubrik
has_one :protocol, :class_name=>'Document', :conditions=>{:typ=>10}, :as=>:parent has_one :protocol, :class_name=>'Document', :conditions=>{:typ=>10}, :as=>:parent

View File

@@ -13,7 +13,7 @@
# #
class Neuigkeit < ActiveRecord::Base class Neuigkeit < ActiveRecord::Base
attr_accessible :datum, :text, :title, :rubrik_id, :author_id,:picture, :calentries_attributes, :flag_important attr_accessible :datum, :text, :title, :rubrik_id, :author_id,:picture,:picture_cache, :calentries_attributes, :flag_important
belongs_to :author, :class_name =>'User' belongs_to :author, :class_name =>'User'
belongs_to :rubrik, :class_name =>'Rubrik', :foreign_key => "rubrik_id" belongs_to :rubrik, :class_name =>'Rubrik', :foreign_key => "rubrik_id"
has_one :calendar, through: :rubrik has_one :calendar, through: :rubrik
@@ -30,6 +30,7 @@ class Neuigkeit < ActiveRecord::Base
translates :title,:text, :versioning=>{:gem=>:paper_trail, :options=>{:fallbacks_for_empty_translations => true}} translates :title,:text, :versioning=>{:gem=>:paper_trail, :options=>{:fallbacks_for_empty_translations => true}}
globalize_accessors :locales => [:de, :en], :attributes =>[:text,:title] globalize_accessors :locales => [:de, :en], :attributes =>[:text,:title]
mount_uploader :picture, PictureUploader mount_uploader :picture, PictureUploader
include IsCommentable
default_scope order(:cache_order).includes(:calentries).includes(:title_pic) default_scope order(:cache_order).includes(:calentries).includes(:title_pic)
scope :recent, -> { published.limit(10)} scope :recent, -> { published.limit(10)}
@@ -44,6 +45,12 @@ class Neuigkeit < ActiveRecord::Base
before_validation :sanitize before_validation :sanitize
after_save :update_cache after_save :update_cache
attr_accessor :no_fallbacks attr_accessor :no_fallbacks
acts_as_flagable
FLAG_ICONS={"infoscreen" => "fa fa-desktop", "important"=>"fa fa-exclamation"}
FLAG_CONFIRM={"infoscreen" => "Neuigkeit am Infoscreen anzeigen"}
def globalize_fallbacks(locale) def globalize_fallbacks(locale)
if self.no_fallbacks if self.no_fallbacks
[locale] [locale]
@@ -128,6 +135,16 @@ class Neuigkeit < ActiveRecord::Base
end end
end end
def text_infoscreen_words
md = /<p>(?<text>[^\<\>]*)/.match Sanitize.clean(self.text,:elements=>['p'])
words=md[:text].split(" ") unless md.nil?
if words.nil? || words.empty?
"...."
else
words[0..1000].join(" ")+ " ..." unless words.nil?
end
end
def has_calentries? def has_calentries?
!self.calentries.nil? && !self.calentries.empty? !self.calentries.nil? && !self.calentries.empty?
end end
@@ -179,6 +196,6 @@ class Neuigkeit < ActiveRecord::Base
searchable do searchable do
text :text text :text
text :datum text :datum
text :title, :boost=>3.0 text :title
end end
end end

View File

@@ -42,7 +42,7 @@ end
searchable do searchable do
text :desc text :desc
text :name, :boost=>4.0 text :name
end end
end end

View File

@@ -34,7 +34,7 @@ class Studium < ActiveRecord::Base
has_many :lvas, :through=>:moduls has_many :lvas, :through=>:moduls
has_many :semester, :dependent => :destroy has_many :semester, :dependent => :destroy
has_many :attachments, :as=>:parent has_many :attachments, :as=>:parent
validates :abkuerzung, :length=>{:maximum=>5}, :format=>{:with=>/^[a-zA-z]{0,5}$/} validates :abkuerzung, :length=>{:maximum=>5}, :format=>{:with=>/^[a-zA-z]{0,5}$/}
validates :typ, :inclusion => {:in => ["Bachelor","Master"] } validates :typ, :inclusion => {:in => ["Bachelor","Master"] }
validates :name, :uniqueness => true, :presence=>true validates :name, :uniqueness => true, :presence=>true
validates :zahl, :presence=>true, :format=>{:with=>/^[0-9A-Z]{4,10}$/}, :uniqueness => true validates :zahl, :presence=>true, :format=>{:with=>/^[0-9A-Z]{4,10}$/}, :uniqueness => true
@@ -89,7 +89,7 @@ validates :abkuerzung, :length=>{:maximum=>5}, :format=>{:with=>/^[a-zA-z]{0,5}$
text :zahl text :zahl
text :typ text :typ
text :abkuerzung text :abkuerzung
text :name, :boost=>3.0 text :name
end end
end end

View File

@@ -1,5 +1,5 @@
class Survey::Answer < ActiveRecord::Base class Survey::Answer < ActiveRecord::Base
belongs_to :choice, class_name: 'Survey::Choice' belongs_to :choice, class_name: 'Survey::Choice', touch: true
belongs_to :user belongs_to :user
# attr_accessible :title, :body # attr_accessible :title, :body
end end

View File

@@ -1,5 +1,5 @@
class Survey::Choice < ActiveRecord::Base class Survey::Choice < ActiveRecord::Base
belongs_to :question, class_name: 'Survey::Question' belongs_to :question, class_name: 'Survey::Question', touch: true
attr_accessible :picture, :sort, :text, :icon, :picture_cache, :remove_picture, :question_id attr_accessible :picture, :sort, :text, :icon, :picture_cache, :remove_picture, :question_id
has_many :answers, class_name: 'Survey::Answer', dependent: :destroy has_many :answers, class_name: 'Survey::Answer', dependent: :destroy
include ActionView::Helpers::TagHelper include ActionView::Helpers::TagHelper

View File

@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
class Survey::Question < ActiveRecord::Base class Survey::Question < ActiveRecord::Base
attr_accessible :text, :title, :typ, :choice_ids, :parent_type, :parent_id attr_accessible :text, :title, :typ, :choice_ids, :parent_type, :parent_id
belongs_to :parent, polymorphic: true belongs_to :parent, polymorphic: true, touch: true
has_many :choices, dependent: :destroy, class_name: "Survey::Choice" has_many :choices, dependent: :destroy, class_name: "Survey::Choice"
has_many :answers, through: :choices has_many :answers, through: :choices
include IsCommentable include IsCommentable

View File

@@ -47,7 +47,7 @@ class Thema < ActiveRecord::Base
# make topic searchable # make topic searchable
searchable do searchable do
text :text text :text
text :title, :boost=>4.0 text :title
end end
resourcify resourcify

View File

@@ -40,7 +40,7 @@ end
searchable do searchable do
text :text text :text
text :title, :boost=>4.0 text :title
end end
end end

View File

@@ -29,13 +29,34 @@ class User < ActiveRecord::Base
# Include default devise modules. Others available are: # Include default devise modules. Others available are:
# :token_authenticatable, :confirmable, # :token_authenticatable, :confirmable,
# :lockable, :timeoutable and :omniauthable # :lockable, :timeoutable and :omniauthable
devise :database_authenticatable, :recoverable, :rememberable, :trackable, :validatable,:omniauthable, :omniauth_providers => [:facebook,:ldap] devise :database_authenticatable, :recoverable, :rememberable, :trackable, :validatable,:omniauthable, :omniauth_providers => [:facebook,:ldap,:developer]
acts_as_voter acts_as_voter
# Setup accessible (or protected) attributes for your model # Setup accessible (or protected) attributes for your model
attr_accessible :email, :password, :password_confirmation, :remember_me, :provider, :uid, :name attr_accessible :email, :password, :password_confirmation, :remember_me, :provider, :uid, :name
belongs_to :fetprofile belongs_to :fetprofile
# attr_accessible :title, :body # attr_accessible :title, :body
def self.find_for_facebook_oauth(auth, signed_in_resource=nil)
def self.find_for_developer_oauth(auth, signed_in_resource=nil)
# logger.debug("Developer Login started")
# logger.debug(auth.info.to_s)
# logger.debug(auth.extra.raw_info.to_s)
email = auth.info.email.to_s
logger.debug("Login E-Mail:"+"'"+ email+"'")
user= User.where(:provider=>auth.provider,:uid=>email).first
unless user
user= User.create(name: email,
provider: auth.provider,
uid: email,
email: email,
password:Devise.friendly_token[0,20])
user.add_role("fetuser")
end
user
end
def self.find_for_facebook_oauth(auth, signed_in_resource=nil)
logger.debug auth.to_s logger.debug auth.to_s
logger.debug "DDD Username= #{auth.username}" 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

View File

@@ -1,33 +1,22 @@
<div id="<%= beispiel.divid %>" class="contentbox"> <div id="<%= beispiel.divid %>" class="contentbox">
<div class="row-fluid"> <div class="row-fluid">
<div class="span6" > <div class="span5" >
<b><%=link_to ffi1_icon("note20")+" " + beispiel.name + " " + I18n.l(beispiel.datum), beispiel.beispieldatei.url, title: beispiel.desc %></b> <b><%=link_to ffi1_icon("note20")+" " + beispiel.name + " " + I18n.l(beispiel.datum), beispiel.beispieldatei.url, title: beispiel.desc %></b>
</div> </div>
<div class="span1" > <div class="span1" >
<%= (beispiel.beispieldatei.size/1024.0).round(2).to_s %>KiB <%= (beispiel.beispieldatei.size/1024.0).round(2).to_s %>KiB
</div> </div>
<div class="span5"> <div class="span2" >
<%= beispiel.lecturer.try(:name).to_s %>
<%= </div>
if can?(:like, beispiel) <div class="span4">
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), remote: true <%= flag_link(beispiel, "goodquality")%>
else <%= flag_link(beispiel, "badquality")%>
"liked by " + beispiel.get_likes.size.to_s <%= flag_link(beispiel, "delete")%>
end <%= like_dislike_for(beispiel) %>
%> <%= link_to ff_icon("icon-pencil")+"edit", edit_beispiel_path(beispiel), remote: true if can? :edit, beispiel %>
<%= link_to fa_icon("trash")+"delete", beispiel_path(beispiel), :method=>:delete, :data=>{:confirm=>I18n.t('beispiel.sure')} if can? :delete, beispiel %>
<%= <% link_to "Refresh", beispiel_path(beispiel,show_comments: true), remote: true %></br>
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) , remote: true
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 fa_icon("trash")+"delete", beispiel_path(beispiel), :method=>:delete, :data=>{:confirm=>I18n.t('beispiel.sure')} if can? :delete, beispiel %>
<% link_to "Refresh", beispiel_path(beispiel,show_comments: true), remote: true %></br>
</div> </div>
</div> </div>
<% unless beispiel.desc.nil? || beispiel.desc.empty? %> <% unless beispiel.desc.nil? || beispiel.desc.empty? %>
@@ -39,4 +28,5 @@
</div> </div>
<% end %> <% end %>
<%= render_comments_for(beispiel) %>
</div> </div>

View File

@@ -12,7 +12,7 @@
<% end %> <% end %>
</div> </div>
<div class="span6"> <div class="span6">
<% f.file_field :beispieldatei, :label => "Neue Datei hochladen:"%> <%= f.file_field :beispieldatei, :label => "Neue Datei hochladen:" if @beispiel.beispieldatei.nil? || @beispiel.beispieldatei.blank? %>
</div> </div>
<%=f.input :datum , :as => :datetimepicker %> <%=f.input :datum , :as => :datetimepicker %>
@@ -20,11 +20,11 @@
<div class="row-fluid"> <div class="row-fluid">
<%= f.input :name %> <%= f.input :name %>
<%= f.input :lva if @beispiel.lva.nil?%>
<%= f.input :desc %> <%= f.input :desc %>
</div> </div>
<div class="span4"> <div class="span4">
<%= f.input :lecturer, :as=>:select, :collection => @beispiel.lva.lecturers %> <%= f.input :lecturer, :as=>:select, :collection => ((@beispiel.lva.nil?|| @beispiel.lva.lecturers.empty?)? Lecturer.all : @beispiel.lva.lecturers) %>
</div> </div>
<%= f.hidden_field :beispieldatei_cache %> <%= f.hidden_field :beispieldatei_cache %>
<%= f.actions do %> <%= f.actions do %>

View File

@@ -0,0 +1 @@
<%= mail.icon_text %>

View File

@@ -9,6 +9,7 @@
</li> </li>
</ul> </ul>
</p> </p>
<%= form_for(resource, :as => resource_name, :url => session_path(resource_name)) do |f| %> <%= form_for(resource, :as => resource_name, :url => session_path(resource_name)) do |f| %>
<div><%= f.label :email %><br /> <div><%= f.label :email %><br />
<%= f.email_field :email, :autofocus => true %></div> <%= f.email_field :email, :autofocus => true %></div>

View File

@@ -1,17 +1,19 @@
<% unless search_results.nil? %> <% unless search_results.nil? %>
<%= search_results %> <%#= search_results %>
<ul> <ul>
<% search_results.each_hit_with_result do |hit,result| %> <% search_results.each_hit_with_result do |hit,result| %>
<li> <%= link_to result.parent.title+": " + result.name, document_path(result) %> <li> <%= link_to result.parent.title+": " + result.name, document_path(result) %>
<% hit.highlights(:name).each do |hlgt| %> <% hit.highlights(:name).each do |hlgt| %>
<%= raw(hlgt.format{|word|"<b>#{word}</b>" } ) %> <%= (hlgt.format{|word|"<b>#{word}</b>" } ).html_safe%>
<% end %> <% end %>
<% %> <% %>
<% hit.highlights(:text).each do |hlgt| %> <% hit.highlights(:text).each do |hlgt| %>
<%= "text:" + raw(hlgt.format {|word| raw("<b>#{word}</b>") })%> <%= ("<br>text: " + hlgt.format {|word| "<b>#{word}</b>" }).html_safe%>
<% end %> <% end %>
<% hit.highlights(:meeting).each do |hlgt| %> <% hit.highlights(:meeting).each do |hlgt| %>
<%= "text:" + raw(hlgt.format {|word| "*#{word}*" })%> <%= "text:" + (hlgt.format {|word| "*#{word}*" }).html_safe%>
<% end %> <% end %>
</li> </li>

View File

@@ -22,7 +22,9 @@
<ul class='breadcrumb hidden-print'> <ul class='breadcrumb hidden-print'>
<% @document.versions.each do |v| %> <% @document.versions.each do |v| %>
<li> <li>
<%= link_to User.find(v.whodunnit).name+": "+ v.event + " (" + I18n.l(v.created_at)+ ") ", write_document_path(@document,:versionid=>v.id) unless v.whodunnit.nil? %>
<%= link_to User.find(v.whodunnit).try(:name)+": "+ v.event + " (" + I18n.l(v.created_at)+ ") ", write_document_path(@document,:versionid=>v.id) if User.exists?(v.whodunnit) unless v.whodunnit.nil? %>
<% end %> <span class="divider">/</span></li> <% end %> <span class="divider">/</span></li>
</ul> </ul>
<% end %> <% end %>

View File

@@ -1 +1 @@
<%= link_to "weiter" , "http://www.fet.at/etherpad/p/"+@document.ep_pad.id , target: :blank %> <%= link_to "weiter" , "https://www.fet.at/etherpad/p/"+@document.ep_pad.id , target: :blank %>

View File

@@ -0,0 +1,3 @@
<%=link_to "reminder", daily_reminder_emails_path(params: {send: true}) %>
<hr>Subject: <b><%= @mail.subject %></b><br>
<%= raw(@mail.body) %>

View File

@@ -0,0 +1 @@
<%=link_to "reminder", daily_reminder_emails_path() %>

View File

@@ -2,3 +2,4 @@
<%= link_to fetprofile, {class: :linkbox} do %> <%= link_to fetprofile, {class: :linkbox} do %>
<%= render :partial=>"fetprofiles/compact", :locals=>{:fetprofile=>fetprofile} %> <%= render :partial=>"fetprofiles/compact", :locals=>{:fetprofile=>fetprofile} %>
<% end %> <% end %>
<%= root_path() %>

View File

@@ -51,10 +51,11 @@ end
<%= @fetprofile.desc %> <%= @fetprofile.desc %>
</p> </p>
<%= render partial: "interninfo", object: @fetprofile if can?(:seeintern, @fetprofile) %> <%= render partial: "interninfo", object: @fetprofile if can?(:seeintern, @fetprofile) %>
<ul> <ul>
<% @memberships.each do |m| %> <% @memberships.each do |m| %>
<li> <li>
<%= link_to m.gremium do %> <%= render m %><% end %> <%= link_to gremium_path(m.gremium) do %> <%= render m %><% end %>
<%= link_to I18n.t('common.edit'), edit_fetprofile_membership_path(@fetprofile,m) if params["verwalten"] && can?(:edit, m)%> <%= link_to I18n.t('common.edit'), edit_fetprofile_membership_path(@fetprofile,m) if params["verwalten"] && can?(:edit, m)%>
<%= link_to I18n.t('common.delete'), [@fetprofile, m], method: :delete, data: {confirm: I18n.t('common.sure_del')} if params["verwalten"] && can?(:delete, m ) %> <%= link_to I18n.t('common.delete'), [@fetprofile, m], method: :delete, data: {confirm: I18n.t('common.sure_del')} if params["verwalten"] && can?(:delete, m ) %>
</li> </li>
@@ -64,5 +65,13 @@ end
</div> </div>
</div> </div>
</div> </div>
<%= render 'layouts/pretty_toolbar' %> <% if can?(:edit, @fetprofile) %>
<div>
<span>
<%= link_to ff_icon("icon-pencil")+I18n.t('common.edit'), edit_fetprofile_path(@fetprofile) if can?(:edit, @fetprofile) %>
<%= link_to fa_icon("trash")+I18n.t('common.delete'), fetprofile_path(@fetprofile),method: :delete, data: { confirm: "Are you sure?" } if can?(:delete, @fetprofile) %>
</span>
</div>
<% end %>
<%#= render 'layouts/pretty_toolbar' %>
</div> </div>

View File

@@ -8,10 +8,9 @@ top: 0" %>
<% #, gallery_foto_path(@foto.gallery, ((@foto.gallery.fotos[@foto.gallery.fotos.index(@foto)+1].nil?) ? (@foto.gallery.fotos[0].try(:id).to_i) : @foto.gallery.fotos[@foto.gallery.fotos.index(@foto)+1].try(:id).to_i) ) %> <% #, gallery_foto_path(@foto.gallery, ((@foto.gallery.fotos[@foto.gallery.fotos.index(@foto)+1].nil?) ? (@foto.gallery.fotos[0].try(:id).to_i) : @foto.gallery.fotos[@foto.gallery.fotos.index(@foto)+1].try(:id).to_i) ) %>
<div style="position:absolute; bottom:0; "> <div style="position:absolute; bottom:0; ">
<%= link_to ff_icon('icon-circle-arrow-down').html_safe, @foto.datei.url, <%= link_to ff_icon('icon-circle-arrow-down').html_safe, @foto.datei.url,
:class=>"btn",title: I18n.t('fotos.download')+': '+@foto.title,:target=>:blank, :style=>"" %> :class=>"btn",title: I18n.t('fotos.download')+': '+@foto.title.to_s,:target=>:blank, :style=>"" %>
<!-- <div class="fb-like" data-href"<%= gallery_foto_path(@foto.gallery,@foto, {fotoid:@foto.id,theme: nil, locale: nil})%>" data-layout="standard" data-action="like" data-show-faces="true" data-share="true"></div>--> <!-- <div class="fb-like" data-href"<%= gallery_foto_path(@foto.gallery,@foto, {fotoid:@foto.id,theme: nil, locale: nil})%>" data-layout="standard" data-action="like" data-show-faces="true" data-share="true"></div>-->
<%= render_shareable :url=>gallery_foto_url(@foto.gallery,@foto, {theme: nil, locale: nil}),:static_link=>true, :buttons=>[:facebook, :twitter, :google_plus] %> <%= render_shareable :url=>gallery_foto_url(@foto.gallery,@foto, {theme: nil, locale: nil}),:static_link=>true, :buttons=>[:facebook, :twitter, :google_plus] %>
<p id="notice"><%= notice %></p> <p id="notice"><%= notice %></p>
</div> </div>

View File

@@ -145,9 +145,12 @@ end
</div> </div>
</div> </div>
<%= link_to ff_icon('icon-circle-arrow-down').html_safe, f.datei.url, <%= link_to ff_icon('icon-circle-arrow-down').html_safe, f.datei.url,
:class=>"btn-small",title: I18n.t('fotos.download')+': '+f.title, rel: 'tooltip' %> :class=>"btn-small",title: I18n.t('fotos.download').to_s+': '+f.title.to_s, rel: 'tooltip' %>
<%= link_to ff_icon('icon-remove-circle').html_safe, gallery_foto_path(@gallery, f), <%= link_to ff_icon('icon-remove-circle').html_safe, gallery_foto_path(@gallery, f),
:method => :delete, :class=>"btn-small btn-danger",title: I18n.t('fotos.delete')+': '+f.title, rel: 'tooltip', confirm: I18n.t('fotos.delete')+': '+f.title+', Sicher?' if can?(:delete,f) %> :method => :delete, :class=>"btn-small btn-danger",
title: I18n.t('fotos.delete').to_s+': '+f.title.to_s, rel: 'tooltip',
confirm: I18n.t('fotos.delete').to_s+': '+f.title.to_s+',
Sicher?' if can?(:delete,f) %>
<p></p> <p></p>
</div> </div>
<% end %> <% end %>
@@ -221,5 +224,3 @@ end
* html .fb-like{display:inline}/* ie6 inline block fix*/ * html .fb-like{display:inline}/* ie6 inline block fix*/
*+html .fb-like{display:inline}/* ie7 inline block fix*/ *+html .fb-like{display:inline}/* ie7 inline block fix*/
</style> </style>

View File

@@ -2,6 +2,8 @@
<p> <p>
<%= link_to "user", users_path %> <%= link_to "user", users_path %>
</p> </p>
<p><%= link_to "emails", emails_path %></p>
<% if Fetsite::Application.config.facebookconfig_enabled %> <% if Fetsite::Application.config.facebookconfig_enabled %>
<h2>Facebook Konfiguration</h2> <h2>Facebook Konfiguration</h2>
<p><%= link_to "Grant extra FB privileges", user_omniauth_authorize_path(:facebook,:params=>{scope:"manage_pages,publish_actions,email"}), :confirm=>"Wirklich?" %> <p><%= link_to "Grant extra FB privileges", user_omniauth_authorize_path(:facebook,:params=>{scope:"manage_pages,publish_actions,email"}), :confirm=>"Wirklich?" %>

View File

@@ -7,12 +7,14 @@
fjs.parentNode.insertBefore(js, fjs); fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));</script> }(document, 'script', 'facebook-jssdk'));</script>
<div class="content-wrap content-column" style="max-width:100em;"> <div class="content-wrap content-column" style="max-width:90em;">
<h1><%= I18n.t('home.willkommen') %></h1> <h1><%= I18n.t('home.willkommen') %></h1>
<%= render partial: "themen/small", object: @starttopic %> <%= raw(@starttopic.text) unless @starttopic.nil? %>
<div class="container-fluid"> <div class="container-fluid">
<div class="row-fluid"> <div class="row-fluid">
<div class="span5"> <div class="span4">
<ul class="linklist"> <ul class="linklist">
<li> <li>
@@ -21,41 +23,43 @@
<li> <li>
<%= link_to ffi1_icon("academic") + I18n.t('home.login'), user_omniauth_authorize_path(:ldap) ,class: :linkbox %> <%= link_to ffi1_icon("academic") + I18n.t('home.login'), user_omniauth_authorize_path(:ldap) ,class: :linkbox %>
</li> </li>
<li> <li>
<%= link_to ffi1_icon("quiz")+ I18n.t("themengruppe.faqs"), faqs_themengruppen_path,class: :linkbox %> <%= link_to ffi1_icon("quiz")+ I18n.t("themengruppe.faqs"), faqs_themengruppen_path,class: :linkbox %>
</li> </li>
<li><%= link_to ffi1_icon("books19")+"Beispielsammlung", studium_path(Studium.first, {:ansicht=>'semesteransicht'}) ,class: :btn ,class: :linkbox %></li> <li><%= link_to ffi1_icon("books19")+"Beispielsammlung", studium_path(Studium.first, {:ansicht=>'semesteransicht'}) ,class: :btn ,class: :linkbox if Studium.count > 0 %></li>
<li><%= link_to "Alte Beispielsammlung", "http://www.fet.at/alt/bin/view/Beispielsammlung/WebHome" ,class: :btn ,class: :linkbox %></li> <li><%= link_to "Alte Beispielsammlung", "http://www.fet.at/alt/bin/view/Beispielsammlung/WebHome" ,class: :btn ,class: :linkbox %></li>
</ul> </ul>
<ul>
<% cache("stickytopics_startpage_"+cache_array_key(@stickythemen)) do %>
<ul class="linklist">
<% @stickythemen.each do |t1| %> <% @stickythemen.each do |t1| %>
<li> <li>
<%= link_to t1 do %> <%= link_to t1,:class=>:linkbox do %>
<%= render partial: "themen/nlink", object: t %> <%= render partial: "themen/nlink", object: t1 %>
<%= end %> <% end %>
</li> </li>
<% end %> <% end %>
</ul> </ul>
<% end %>
<%= render 'beispiele' %>
<%= render 'beispiele' %>
<div class="fb-like-box" data-href="https://www.facebook.com/FachschaftET" data-colorscheme="light" data-show-faces="true" data-header="true" data-stream="false" data-show-border="true"></div>
</div> </div>
<div class="span7">
<ul class="unstyled linkbox-list" style="margin:5px;"> <div class="span5">
<ul class="unstyled linkbox-list">
<% @neuigkeiten.each do |n| %> <% @neuigkeiten.each do |n| %>
<li><%= render n if can?(:show, n) %> </li> <li><%= render n if can?(:show, n) %> </li>
<% end %> <% end %>
</ul> </ul>
Verschiedene Styles </div>
<ul>
<li> <%= link_to "Darkblue", home_index_path({:theme=>"darkblue"}) %></li>
<li> <%= link_to "Blue1", home_index_path({:theme=>"blue1"}) %></li>
<li> <%= link_to "2003", home_index_path({:theme=>"2003"}) %></li> <div class="span3">
<li> <%= link_to "white_1", home_index_path({:theme=>"white_1"}) %></li> <% cache("calendar_" + cache_array_key(@calentries)+params[:month].to_s+params[:year].to_s) do %>
</ul> <%= render 'calendars/calentries', :object=>@calentries %>
<% end %>
<div class="fb-like-box" data-href="https://www.facebook.com/FachschaftET" data-colorscheme="light" data-show-faces="true" data-header="true" data-stream="false" data-show-border="true"></div>
</div> </div>
</div> </div>
</div> </div>

View File

@@ -0,0 +1,103 @@
<head>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<%= stylesheet_link_tag "themes/"+theme_name+"/application", :media => "all" unless theme_name.empty? %>
<%= stylesheet_link_tag "application", :media=>"all" if theme_name.empty? %>
<%= stylesheet_link_tag "/iframe/infoscreenframe.css" %>
<%= javascript_include_tag "application" %>
<%= javascript_include_tag "jmpress" %>
</head>
<body>
<%= content_tag(:iframe,'', width: "100%", height: "100%", name: "targetframe", allowTransparency:"true", scrolling:"no", frameborder:"0", src: "/iframe/infoscreenframe.html") %> <%#header picture/animation %>
<div id ="jmpress">
<% i=1 %>
<% @neuigkeiten.each do |n| %>
<div class="step" id="step-<%=i%>" data-x="<%= i *2000 %>" data-y="<%= Random.rand(0..5)*200 %>" style="position:absolute; height:540px; width:1230px; display: block;" data-duration="10000">
<div class="media" style="width:'95%'; height:480px;" >
<div class="pull-left" href="#" style="max-width:250px;">
<% unless n.picture_robust.big_thumb.to_s.empty? %>
<p>
<br><%= link_to image_tag(n.picture_robust.big_thumb),n.picture_robust.try(:url) %></p>
<% end %>
<h3>
<% if n.has_calentries? %>
<div href="#">
<%= fa_icon("calendar 2x") %>
<%= n.relevant_calentry.text %>
</div>
<% elsif n.has_meeting? %>
<div href="#">
<%= fa_icon("calendar 2x") %>
<%= n.meeting.calentry.text unless n.meeting.calentry.nil? %>
</div>
<% end %>
</h3>
</div>
<div class="media-body">
<h1 itemprop="name">
<%= raw(n.title) %> <%#= link_to fa_icon("edit"), edit_rubrik_neuigkeit_path(n.rubrik, n), remote: true if can? :edit, n %>
</h1>
<div itemprop="articleBody" style="font-size:large">
<%= raw(n.text_infoscreen_words) %>
</div>
</div>
</div>
</div>
<% i = i+1 %>
<% end %>
</div>
<script>
var d = new Date();
var n = d.getDay();
var now = d.getHours() + "." + d.getMinutes();
var weekdays = [
["Sunday"],
["Monday", 9.00, 14.00],
["Tuesday", 9.00, 14.00],
["Wednesday", 9.00, 14.00],
["Thursday", 9.00, 14.00],
["Friday", 9.00, 12.00],
["Saturday"] // we are closed, sorry!
];
var day = weekdays[n];
if (now > day[1] && now < day[2]) {
document.write("<div id='footer' style='background: green; height:25px; width:50px; margin:10px; position:absolute'>");
document.write("OPEN");
document.write("</div>");
}
else {
document.write("<div id='footer' style='background: red; height:25px; width:60px; margin:10px; position:absolute'>");
document.write("CLOSED");
document.write("</div>");
}
</script>
<script>
$(function () {
$('#jmpress').jmpress({
initStep: function(element, eventData) {
console.log('We\'re changing to step: #' + $(element).attr('id') + '!');
}
});
setTimeout(function(){
window.location.reload();
/* or window.location = window.location.href; */
}, 100000);
});
</script>
</body>

View File

@@ -1,21 +1,49 @@
<h1> FET Intern NEU </h1> <h1> FET Intern NEU blue2</h1>
<div class="container-fluid"> <div class="container-fluid">
<div class="row-fluid"> <div class="row-fluid">
<div class="span6"> <div class="span6">
<ul class="linklist"> <div>
<ul class="linklist">
<li>
<%= link_to fa_icon("list")+"Adressliste", internlist_fetprofiles_path ,class: :linkbox %>
</li>
<li>
<%= link_to ff_icon("ffi1-setting")+"Admin" , admin_home_index_path, class: :linkbox if current_user.has_role?(:fetadmin) %>
</li>
<li>
<%= link_to ff_icon("fa fa-folder")+"Treeview" , treeview_home_index_path, class: :linkbox if current_user.has_role?(:fetadmin) %>
</li>
<li>
<%= link_to ff_icon("ffi1-newspaper9")+"Crawler" , crawler_index_path, class: :linkbox if current_user.has_role?(:fetadmin) %>
</li>
<li> <li>
<%= link_to "Adressliste", internlist_fetprofiles_path ,class: :linkbox %></li> <%= link_to ff_icon("ffi1-setting")+"Meetings" , meetingtyps_path, class: :linkbox if current_user.has_role?(:fetadmin) %>
<li> <%= link_to "Admin" , admin_home_index_path, class: :linkbox if current_user.has_role?(:fetadmin) %> </li>
</li> <li>
</ul> <%= link_to ff_icon("ffi1-setting")+"Alte Oberfläche" , set_preferred_theme_user_path(current_user, params: {theme: "blue1"}), class: :linkbox if can? :set_preferred_theme, current_user %>
</li>
</ul><br>
</div>
<div>Suche nach Protokollen
<%= semantic_form_for :search,:remote=>true, :url=>search_documents_path, :html=>{:id=>"search_form",:class=>"", :method=>'get'} do |f| %>
<%= f.input :query, :input_html => { :name => 'query' } , :label=>false, :class=>"search-query" %>
<% f.actions do %>
<% f.action :submit, :as => :input %>
<% end %>
<% end %>
<div id="searchresults">
<%= render :partial=>"documents/search_results", :object=>@results %>
</div>
</div>
<ul class="unstyled linkbox-list"> <ul class="unstyled linkbox-list">
<li> <li>
<% @themengruppen.each do |themengruppe| %> <% @themengruppen.each do |themengruppe| %>
<div class="container-fluid"> <div class="container-fluid">
<%= render themengruppe if can?(:show,themengruppe)%> <%= render themengruppe if can?(:show,themengruppe)%>
</div> </div>
<% end %> <% end %>
</li> </li>
</ul> </ul>
<%= link_to "Users", users_path %> <%= link_to "Users", users_path %>
@@ -23,9 +51,9 @@
<div class="span6"> <div class="span6">
<h2>Neuigkeiten</h2> <h2>Neuigkeiten</h2>
<ul class="unstyled linkbox-list"> <ul class="unstyled linkbox-list">
<% @neuigkeiten.each do |n| %> <% @neuigkeiten.each do |n| %>
<li><%= render n if can?(:show, n) %></li> <li><%= render n if can?(:show, n) %></li>
<% end %> <% end %>
</ul> </ul>
</div> </div>
</div> </div>

View File

@@ -7,11 +7,11 @@
<%= current_user.email %> is logged in. <%= current_user.email %> is logged in.
</li> </li>
<li><%= link_to('Logout', destroy_user_session_path, :method => :delete) %> </li> <li><%= link_to('Logout', destroy_user_session_path, :method => :delete,:id => "login_link") %> </li>
</ul> </ul>
</li> </li>
<% else %> <% else %>
<li> <li>
<%= link_to('Login', new_user_session_path) %> <%= link_to('Login', new_user_session_path, id:"login_link") %>
</li> </li>
<% end %> <% end %>

View File

@@ -1,71 +1,66 @@
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
<head> <head>
<meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="shortcut icon" href="<%= absurl("/logo2014_64.png")%>"> <link rel="shortcut icon" href="https://www.fet.at/logo2014_64.png">
<link rel="alternate" hreflang="de" href="<%= url_for(params.merge(:locale=>:de))%>" /> <link rel="alternate" hreflang="de" href="<%= url_for(params.merge(:locale=>:de))%>" />
<link rel="alternate" hreflang="en" href="<%= url_for(params.merge(:locale=>:en))%>" /> <link rel="alternate" hreflang="en" href="<%= url_for(params.merge(:locale=>:en))%>" />
<!--<link rel="shortcut icon" href="http://www.fet.at/favicon.ico">-->
<!---->
<%= stylesheet_link_tag "themes/"+theme_name+"/application", :media => "all" unless theme_name.empty? %> <%= stylesheet_link_tag "themes/"+theme_name+"/application", :media => "all" unless theme_name.empty? %>
<%= stylesheet_link_tag "application", :media=>"all" if theme_name.empty? %> <%= stylesheet_link_tag "application", :media=>"all" if theme_name.empty? %>
<% theme_stylesheet_link_tag "test", :media => "all" %> <%= javascript_include_tag "application" %>
<% theme_stylesheet_link_tag "mod", :media=>"all" %> <%= csrf_meta_tags %>
<%= javascript_include_tag "application" %> <% if content_for?(:header) %>
<%= csrf_meta_tags %> <%= yield :header %>
<% if content_for?(:header) %> <% else %>
<%= yield :header %> <title>Fetsite</title>
<% else %> <% end %>
<title>Fetsite</title>
<% end %>
</head> </head>
<body> <body>
<div id="maincontainer" class="container-fluid"> <div id="maincontainer" class="container-fluid">
<div class="row-fluid"> <div class="row-fluid">
<div class="span10 offset1 header_span"> <div class="span10 offset1 header_span">
<% cache("menu_u"+user_signed_in?.to_s+current_user.try(:id).to_s+"l"+I18n.locale.to_s+ can?(:seeintern, User).to_s+ can?(:index,Gallery).to_s+params[:theme].to_s, expires_in: 24.hours) do %> <% cache("menu_u"+user_signed_in?.to_s+current_user.try(:id).to_s+"l"+I18n.locale.to_s+ can?(:seeintern, User).to_s+ can?(:index,Gallery).to_s+params[:theme].to_s, expires_in: 24.hours) do %>
<div class="header_wrap"> <div class="header_wrap">
<div class="header hidden-print"> <div class="header hidden-print">
<%= link_to home_index_path do %> <%= link_to home_index_path do %>
<!-- <span class="feticon-fet_logo fa-4x color-1"> </span>--> <!-- <span class="feticon-fet_logo fa-4x color-1"> </span>-->
<%= image_tag('/logo2014_64.png',{:style=>"float:left;height:50px",:height=>"50"}) %> <%= image_tag('/logo2014_64.png',{:style=>"float:left;height:50px",:height=>"50"}) %>
<% end %> <% end %>
</div> </div>
<div class="header visible-print"> <div class="header visible-print">
<%= image_tag('/logo2014_64.png',{:style=>"float:left;height:50px",:height=>"50"}) %> <%= image_tag('/logo2014_64.png',{:style=>"float:left;height:50px",:height=>"50"}) %>
</div> </div>
<div class="visible-print"> <div class="visible-print">
Fachschaft Elektrotechnik Fachschaft Elektrotechnik
<hr/> <hr/>
</div> </div>
<div id="menudiv" style="margin-top:12px" class="hidden-print"> <div id="menudiv" style="margin-top:12px" class="hidden-print">
<%= render :template => 'layouts/menu' %> <%= render :template => 'layouts/menu' %>
</div> </div>
</div>
<% end %>
</div>
</div>
<div class="row-fluid">
<div class="span10 offset1" id="contentdiv">
<%= yield %>
</div>
</div> </div>
<% end %>
</div>
</div> </div>
<div class="row-fluid"> <script>
<div class="span10 offset1" id="contentdiv"> $('.dropdown-toggle').click(function(e) {
<%= yield %> e.preventDefault();
</div> setTimeout($.proxy(function() {
</div> if ('ontouchstart' in document.documentElement) {
</div> $(this).siblings('.dropdown-backdrop').off().remove();
<script> }
$('.dropdown-toggle').click(function(e) { }, this), 0);
e.preventDefault(); });
setTimeout($.proxy(function() { </script>
if ('ontouchstart' in document.documentElement) {
$(this).siblings('.dropdown-backdrop').off().remove();
}
}, this), 0);
});
</script>
</body> </body>
</html> </html>

View File

@@ -44,8 +44,20 @@
</ul></div> </ul></div>
</li> </li>
<%= render 'layouts/login' %> <li>
</ul> <% if not user_signed_in? %>
<% if Rails.env.development? %>
<%# link_to I18n.t('home.login'), user_omniauth_authorize_path(:developer) %>
<%= render 'layouts/login' %>
<% else %>
<%= link_to ffi1_icon("academic") + I18n.t('home.login'), user_omniauth_authorize_path(:ldap) %>
<% end %>
<% else %>
<%= render 'layouts/login' %>
<% end %>
</li></ul>
<!--<span class="pull-right"><%if I18n.locale == :en %> <!--<span class="pull-right"><%if I18n.locale == :en %>
<%= link_to image_tag("/flaggen/png/at.png") + " Deutsch" ,switch_locale_url(:de)%> <%= link_to image_tag("/flaggen/png/at.png") + " Deutsch" ,switch_locale_url(:de)%>

View File

@@ -1,12 +1,10 @@
<%= content_for :header do %> <%= content_for :header do %>
<title>Fetsite - <%= @lva.full_name %></title> <title>Fetsite - <%= @lva.full_name %></title>
<% set_meta_tags :og => { <% set_meta_tags :og => {
:url=>lva_path(:theme=>nil) :url=>lva_path(:theme=>nil) }
} %>
%> <%= display_meta_tags %>
<%= display_meta_tags %>
<% end %> <% end %>
<div itemscope itemtype="schema.org/Article" > <div itemscope itemtype="schema.org/Article" >
<div class="container-fluid"> <div class="container-fluid">
<%= render 'studien/tabs'%> <%= render 'studien/tabs'%>
@@ -14,106 +12,145 @@
<div class="row-fluid"> <div class="row-fluid">
<div class="span12"> <div class="span12">
<%= render 'layouts/pretty_toolbar' %> <%= render 'layouts/pretty_toolbar' %>
</div> </div>
</div> </div>
<div class="row-fluid"> <div class="row-fluid">
<div class="span8"> <div class="span8">
<h1 itemprop="name"><%= @lva.full_name %></h1> <h1 itemprop="name"><%= @lva.full_name %></h1>
<meta itemprop="url" content="<%= lva_path(@lva) %>" /> <meta itemprop="url" content="<%= lva_path(@lva) %>" />
<ul class="linklist"> <ul class="linklist">
<li> <li>
<%= link_to ffi1_icon("live2")+"ET-Forum", @lva.forumlink, class: :linkbox, itemprop: "discussionUrl" unless @lva.forumlink.nil? or @lva.forumlink.empty?%> <%= link_to ffi1_icon("live2")+"ET-Forum", @lva.forumlink, class: :linkbox, itemprop: "discussionUrl" unless @lva.forumlink.nil? or @lva.forumlink.empty?%>
</li> </li>
<li> <li>
<%= link_to "TISS", @lva.tisslink, class: :linkbox %> <%= link_to "TISS", @lva.tisslink, class: :linkbox %>
</li> </li>
</ul> </ul>
<div itemprop="articleBody"> <div itemprop="articleBody">
<h2><%= I18n.t('lva.pruefungsinfo')%></h2> <h2><%= I18n.t('lva.pruefungsinfo')%></h2>
<div class=""> <div class="">
<%= @lva.pruefungsinformation.to_s.html_safe %> <%= @lva.pruefungsinformation.to_s.html_safe %>
</div> </div>
<h2><%= I18n.t('lva.lernaufwand')%></h2> <h2><%= I18n.t('lva.lernaufwand')%></h2>
<div class=""> <div class="">
<%= @lva.lernaufwand %> <%= @lva.lernaufwand %>
</div> </div>
<h2><%= I18n.t('lva.desc')%></h2>
<div class="">
<%= @lva.desc.to_s.html_safe %>
</div>
</div>
<h2><%= I18n.t('lva.desc')%></h2>
<div class="">
<%= @lva.desc.to_s.html_safe %>
</div>
</div>
</div> </div>
<div class="span4"> <div class="span4">
<div class="contentbox"> <div class="contentbox">
<ul> <ul>
<li><b><%= I18n.t('lva.lvanr')%>:</b> <%=@lva.lvanr %></li> <li><b><%= I18n.t('lva.lvanr')%>:</b> <%=@lva.lvanr %></li>
<li><b>ECTS:</b> <%=@lva.ects %></li> <li><b>ECTS:</b> <%=@lva.ects %></li>
<li><b><%= I18n.t('lva.stunden')%>:</b> <%=@lva.stunden %></li> <li><b><%= I18n.t('lva.stunden')%>:</b> <%=@lva.stunden %></li>
</ul> </ul>
<h2><%= I18n.t('lva.module')%></h2> <h2><%= I18n.t('lva.module')%></h2>
<ul> <ul>
<% @lva.modul.each do |modul| %> <% @lva.modul.each do |modul| %>
<li><b><%= link_to modul.name , modul_path(modul)%></b> <li><b><%= link_to modul.name , modul_path(modul)%></b>
<ul> <ul>
<% modul.modulgruppen.each do |g| %> <% modul.modulgruppen.each do |g| %>
<li><%= link_to g.studium.title_context , studium_path(g.studium)%> (<%=link_to g.name, modulgruppe_path(g)%>)</li>
<% end %> <li><%= link_to g.studium.title_context , studium_path(g.studium)%> (<%=link_to g.name, modulgruppe_path(g)%>)</li>
</ul> <% end %>
</li> </ul>
<% end %> </li>
</ul>
</div> <% end %>
<div class="contentbox"> </ul>
<h2> <%= I18n.t "lecturers.lecturers" %> </h2> </div>
<% @lva.lecturers.each do |lec| %> <div class="contentbox">
<%= render :partial=>'lecturers/lec_lva', :object=>lec %> <h2> <%= I18n.t "lecturers.lecturers" %> </h2>
<% end %> <% @lva.lecturers.each do |lec| %>
</div> <%= render :partial=>'lecturers/lec_lva', :object=>lec %>
<% end %>
</div>
</div> </div>
</div> </div>
<div class="row-fluid">
<div class="row-fluid">
<div class="span12"> <div class="span12">
<%= new_question_for(@lva) %>
<% unless @questions.nil? %>
<% @questions.each do |q| %>
<%= render q if can? :show, q %>
<% end %>
<% end %>
<h2><%= I18n.t("lva.bspe") %></h2> <h2><%= I18n.t("lva.bspe") %></h2>
<p><%= I18n.t("lva.ratebsp")%> <%= link_to ffi1_icon("facebook1") + I18n.t('home.fblogin'), user_omniauth_authorize_path(:facebook) ,class: :linkbox %> <p>
<%= I18n.t("lva.ratebsp")%>
<%= link_to ffi1_icon("facebook1") + I18n.t('home.fblogin'), user_omniauth_authorize_path(:facebook) ,class: :linkbox %>
</p> </p>
<%= link_to t("beispiel.zip") , beispiel_sammlung_lva_path(@lva), class: :linkbox %> <%= link_to t("beispiel.zip") , beispiel_sammlung_lva_path(@lva), class: :linkbox %>
<% @beispiele_all.each do |b| %> <% @beispiele.each do |b| %>
<% cache("beispiel_" +I18n.locale.to_s+b.id.to_s+can?(:delete,b).to_s+"_"+can?(:edit,b).to_s + "_" + can?(:flag, b).to_s+ can?(:comment, b).to_s + "_" + can?(:like, b).to_s + "_" + b.updated_at.try(:utc).try(:to_s) + get_theme_help(current_user).to_s) do %> <% cache("beispiel_" +I18n.locale.to_s+b.id.to_s+can?(:delete,b).to_s+"_"+can?(:edit,b).to_s + "_" + can?(:flag, b).to_s + "_" + can?(:like, b).to_s + "_" + b.updated_at.try(:utc).try(:to_s) + get_theme_help(current_user).to_s) do %>
<%= render b%> <%= render b%>
<% end %> <% end %>
<% end %> <% end %>
<% if @beispiele_badQ.count > 0 %>
<h3> Bad Quality or Outdated</h3>
<% @beispiele_badQ.each do |b| %>
<% cache("beispiel_" +I18n.locale.to_s+b.id.to_s+can?(:delete,b).to_s+"_"+can?(:edit,b).to_s + "_" + can?(:flag, b).to_s + "_" + can?(:like, b).to_s + "_" + b.updated_at.try(:utc).try(:to_s) + get_theme_help(current_user).to_s) do %>
<%= render b%>
<% end %>
<% end %>
<% end %>
<% if @beispiele_deleted.count > 0 %>
<h3> Trash</h3>
<% @beispiele_deleted.each do |b| %>
<% cache("beispiel_" +I18n.locale.to_s+b.id.to_s+can?(:delete,b).to_s+"_"+can?(:edit,b).to_s + "_" + can?(:flag, b).to_s + "_" + can?(:like, b).to_s + "_" + b.updated_at.try(:utc).try(:to_s) + get_theme_help(current_user).to_s) do %>
<%= render b%>
<% end %>
<% end %>
<% end %>
</div> </div>
</div> </div>
<div class="row-fluid"> <div class="span12"> <div class="row-fluid">
<% unless @lva.nlinks.empty? %> <div class="span12">
<h2><%= I18n.t("rubrik.title") %></h2>
<% @lva.nlinks.each do |l| %> <% unless @lva.nlinks.empty? %>
<%= render l.neuigkeit %> <h2><%= I18n.t("rubrik.title") %></h2>
<% end %> <% @lva.nlinks.each do |l| %>
<% end %> <%= render l.neuigkeit %>
</div></div> <% end %>
<% end %>
</div>
</div>
<% cache("lva_beispiel_form_bulk_"+@lva.id.to_s+I18n.locale.to_s+@lva.updated_at.to_i.to_s) do %> <% cache("lva_beispiel_form_bulk_"+@lva.id.to_s+I18n.locale.to_s+@lva.updated_at.to_i.to_s) do %>
<div class="row-fluid"> <div class="row-fluid">
<div class="span12"> <div class="span12">
<%= render 'beispiele/form_bulk' %> <%= render 'beispiele/form_bulk' %>
</div> </div>
</div> </div>
<% end %> <% end %>
<% unless @crawlobjects.nil? %> <% unless @crawlobjects.nil? %>
<div class="row-fluid"> <div class="row-fluid">
<div class="span12"> <div class="span12">
<% @crawlobjects.each do |co| %> <% @crawlobjects.each do |co| %>
<%= render co %> <%= render co %>
<% end %> <% end %>
</div> </div>
</div> </div>
<% end %> <% end %>
</div> </div>

View File

@@ -0,0 +1,10 @@
<h1>
<%= mail.title%>
</h1>
<%= content_tag(:img,"",src: "http://" + ActionMailer::Base.default_url_options[:host].to_s + mail.picture.big_thumb.url.to_s) %>
<%=url_for controller: "neuigkeiten",action: :show, :id=>mail.id, only_path: false %>
<%= raw(mail.text) %>
<% mail.questions.each do |q| %>
<%= render partial:"survey/questions/mail", object: q %>
<% end %>
<%= link_to "Auf Fet.at weiterlesen", rubrik_neuigkeit_url(mail.rubrik, mail,:locale=>:de, :theme=>nil) %>

View File

@@ -0,0 +1,60 @@
<div class="toolbar-inline">
<%= link_to(fa_icon("edit"), edit_rubrik_neuigkeit_path( menu.rubrik, menu), remote: true , class: "btn", title: "Edit") if can? :edit, menu
%>
<span class="btn-group">
<%= link_to(fa_icon("paperclip"), "#", class: "btn", id: "attachments-form-open", title: "Attachments") if can? :edit, menu
%>
<%= link_to(fa_icon("calendar-o"), new_calentry_path(:object_id=>menu.id, :object_type=>"Neuigkeit"), :remote=>true, class: :btn) if can? :edit, menu
%>
<%= link_to(fa_icon("link") , "#", id: "findlink-open",title: "Neue Verknüpfung" , class: "btn") if can? :find_link, menu
%>
</span>
<%= new_question_for(menu, fa_icon("question")) if can? :new, Survey::Question %>
<span class=" pull-right">
<%= flag_link(menu, "important")%>
<%= flag_link(menu, "infoscreen")%>
<%= link_to(fa_icon("globe"), publish_rubrik_neuigkeit_path(menu.rubrik,menu), title: I18n.t('neuigkeit.publish'), class: "btn") if can?(:publish, menu) && !menu.published?
%>
<%= link_to(fa_stack("globe","ban"), unpublish_rubrik_neuigkeit_path(menu.rubrik,menu), :remote=>true, class: "btn stacked") if can?(:unpublish, menu) && menu.published?
%>
<% if menu.published? %>
<div class="dropdown" style=" display:inline"">
<a class="dropdown-toggle btn" data-toggle="dropdown" title="publish" href="#">
<%= fa_icon("mail-forward")%><span class="caret"></span>
</a>
<ul class="dropdown-menu">
<%= li_tag(link_to(fa_icon("facebook-square") + " post on facebook", publish_to_facebook_rubrik_neuigkeit_path(menu.rubrik,menu))) if can?(:publish, menu) && menu.published?
%>
<%= li_tag(link_to(fa_icon("envelope-o") + " send mail", mail_preview_rubrik_neuigkeit_path(menu.rubrik,menu))) if can?(:publish, menu) && menu.published?
%>
</ul>
</div>
<% end %>
</span>
<div class="ui-dialog" id="attachments-form">
<%= render_new_attachments_for(menu, fa_icon("plus"), {class: "btn"}) %>
</div>
</div>
<script>
$(function(){
dialogatt = $( "#attachments-form" ).dialog({
autoOpen: false,
width: "90%",
modal: true,
title: "Neue Attachments",
buttons: {
"Fertig": function() {
dialogatt.dialog( "close" );
}
}
});
$("#attachments-form-open").on("click",function(){dialogatt.dialog("open")})
});
</script>

View File

@@ -29,13 +29,18 @@
</div> </div>
<% end %> <% end %>
<div class="media"> <div class="media">
<% unless @neuigkeit.picture_robust.big_thumb.to_s.empty? %>
<div class="pull-left" href="#"> <div class="pull-left" href="#" style="width:200px">
<p><br><%= link_to image_tag(@neuigkeit.picture_robust.big_thumb.url),@neuigkeit.picture_robust.try(:url) %> <p><br>
<% unless @neuigkeit.picture_robust.big_thumb.to_s.empty? %><%= link_to image_tag(@neuigkeit.picture_robust.big_thumb.url),@neuigkeit.picture_robust.try(:url) %>
<% end %>
<%= f.input :picture, as: :uploader %>
<%= f.hidden_field :picture_cache %>
</p> </p>
</div> </div>
<% end %>
<div class="media-body"> <div class="media-body" style="border: dashed black thin">
<h1 itemprop="name" class="editable_simple" data-target="#neuigkeit_title"> <h1 itemprop="name" class="editable_simple" data-target="#neuigkeit_title">
<%= raw(@neuigkeit.title) %> <%= raw(@neuigkeit.title) %>
</h1> </h1>

View File

@@ -1,9 +1,22 @@
<div id="neuigkeit_<%= neuigkeit_view.id %>" class="contentbox" itemscope itemtype="http://schema.org/Article"> <% if neuigkeit_view.nil?
<meta itemprop="about" content="<%= neuigkeit_view.text_first_words %>"/> neuigkeit_view=@neuigkeit
<meta itemprop="sameAs" content="<%= neuigkeit_url(neuigkeit_view,:theme=>nil)%>"/> end
<meta itemprop="url" content="<%= neuigkeit_url(neuigkeit_view,:theme=>nil)%>"/> %>
<div id="neuigkeit_<%= neuigkeit_view.id %>" class="contentbox" itemscope itemtype="http://schema.org/Article">
<%= meta_itemprop("about", neuigkeit_view.text_first_words) %>
<%= meta_itemprop("sameAs", neuigkeit_url(neuigkeit_view,:theme=>nil)) %>
<%= meta_itemprop("url", neuigkeit_url(neuigkeit_view,:theme=>nil)) %>
<div class="media"> <div>
<% cache("menu_neuigkeit"+ neuigkeit_view.id.to_s + can?(:edit,neuigkeit_view).to_s + can?(:find_link, neuigkeit_view).to_s + can?(:new, Survey::Question).to_s + can?(:publish, neuigkeit_view).to_s + can?(:unpublish, neuigkeit_view).to_s + neuigkeit_view.published?.to_s + neuigkeit_view.flag_important.to_s + neuigkeit_view.flag_infoscreen.to_s) do %>
<%= render partial: "menu" , object: neuigkeit_view%>
<% end %>
</div>
<div>
<%#= render 'layouts/pretty_toolbar', :object=> @toolbar_elements %>
</div>
<div class="media">
<span itemprop="articleSection"> <span itemprop="articleSection">
<%= ff_icon(neuigkeit_view.rubrik.icon) unless neuigkeit_view.rubrik.icon.nil? or neuigkeit_view.rubrik.icon.empty? %>&nbsp;<%= neuigkeit_view.rubrik.name %> <%= ff_icon(neuigkeit_view.rubrik.icon) unless neuigkeit_view.rubrik.icon.nil? or neuigkeit_view.rubrik.icon.empty? %>&nbsp;<%= neuigkeit_view.rubrik.name %>
</span> </span>
@@ -15,8 +28,9 @@
</span> </span>
<% end %> <% end %>
</div> </div>
<% unless neuigkeit_view.published? %> <% unless neuigkeit_view.published? %>
<div class="sticker sticker-red"> Not Published <%= link_to "Publish", publish_rubrik_neuigkeit_path(@neuigkeit.rubrik,@neuigkeit),remote:true, class: :btn if can? :publish, neuigkeit_view %></div> <div class="sticker sticker-red"> Not Published <%= link_to "Publish", publish_rubrik_neuigkeit_path(neuigkeit_view.rubrik,neuigkeit_view),remote:true, class: :btn if can? :publish, neuigkeit_view %></div>
<% end %> <% end %>
<% unless neuigkeit_view.origurl.nil? || neuigkeit_view.origurl.empty? %> <% unless neuigkeit_view.origurl.nil? || neuigkeit_view.origurl.empty? %>
<div class="alert"><%= link_to "Zitiert von "+ neuigkeit_view.origurl, neuigkeit_view.origurl %> <div class="alert"><%= link_to "Zitiert von "+ neuigkeit_view.origurl, neuigkeit_view.origurl %>
@@ -31,7 +45,7 @@
<% end %> <% end %>
<div class="media-body"> <div class="media-body">
<h1 itemprop="name"> <h1 itemprop="name">
<%= raw(neuigkeit_view.title) %> <%= link_to fa_icon("edit"), edit_rubrik_neuigkeit_path(neuigkeit_view.rubrik, neuigkeit_view), remote: true if can? :edit, neuigkeit_view %> <%= raw(neuigkeit_view.title) %> <%#= link_to fa_icon("edit"), edit_rubrik_neuigkeit_path(neuigkeit_view.rubrik, neuigkeit_view), remote: true if can? :edit, neuigkeit_view %>
</h1> </h1>
<div itemprop="articleBody"> <div itemprop="articleBody">
<%= raw(neuigkeit_view.text) %> <%= raw(neuigkeit_view.text) %>
@@ -40,14 +54,19 @@
</div> </div>
<%= render_calentries_for(neuigkeit_view)%> <%= render_calentries_for(neuigkeit_view)%>
<%= new_calentry_div(neuigkeit_view) %>
<% unless neuigkeit_view.meeting.nil? %> <% unless neuigkeit_view.meeting.nil? %>
<%= render neuigkeit_view.meeting %> <%= render neuigkeit_view.meeting %>
<% end%> <% end%>
<%= render_attachments_for(neuigkeit_view) %> <%= render_attachments_list_for(neuigkeit_view) %>
<%= render 'layouts/pretty_toolbar', :object=> @toolbar_elements %> </div>
</div>
<% @questions.each do |q| %>
<%= render q if can? :show, q %>
<% end %>

View File

@@ -0,0 +1,5 @@
<%= link_to "send", mail_preview_rubrik_neuigkeit_path(@neuigkeit) %>
<%= raw(@mail.subject) %>
<hr />
<%= raw(@mail.body) %>

View File

@@ -38,19 +38,15 @@
</p> </p>
<%= render partial: "neuigkeit_view", object: @neuigkeit %> <%= render partial: "neuigkeit_view", object: @neuigkeit %>
<%= new_question_for(@neuigkeit) if can? :new, Survey::Question %>
<% @questions.each do |q| %>
<%= render q if can? :show, q %>
<% end %>
</div> </div>
<div class="fb-like" data-href"<%= rubrik_neuigkeit_url(@rubrik,@neuigkeit,{themes: nil, locale: nil})%>" data-layout="standard" data-action="like" data-show-faces="true" data-share="true"></div> <div class="fb-like" data-href"<%= rubrik_neuigkeit_url(@rubrik,@neuigkeit,{themes: nil, locale: nil})%>" data-layout="standard" data-action="like" data-show-faces="true" data-share="true"></div>
<%= render_comments_for(@neuigkeit) %>
<%# link_to fa_icon("link") + "Neue Verknüpfung" , "#", id: "findlink-open" if can? :find_link, @neuigkeit %>
<%= link_to fa_icon("link") + "Neue Verknüpfung" , "#", id: "findlink-open" if can? :find_link, @neuigkeit %>
<% cache(cache_array_key(@neuigkeit.nlinks, "NLinks")) do %> <% cache(cache_array_key(@neuigkeit.nlinks, "NLinks")) do %>
<%= render partial: 'neuigkeiten/nlink_list_whole', :object=>@neuigkeit.nlinks %> <%= render partial: 'neuigkeiten/nlink_list_whole', :object=>@neuigkeit.nlinks %>
<% end %> <% end %>
<div id="findlink-body" class="ui-dialog" style=""> <div id="findlink-body" class="ui-dialog" style="">
@@ -62,6 +58,7 @@
<%= render partial: 'nlink_list_search_whole', object: @nlink_search %> <%= render partial: 'nlink_list_search_whole', object: @nlink_search %>
<% end %> <% end %>
</div> </div>
<script> <script>
$(function(){ $(function(){
dialog = $( "#findlink-body" ).dialog({ dialog = $( "#findlink-body" ).dialog({

View File

@@ -0,0 +1,13 @@
<%= stylesheet_link_tag "http://"+ActionMailer::Base.default_url_options[:host].to_s + "/assets/themes/blue2/application.css", :media=>"all" %>
<% @calentries.each do |ce| %>
<% if can?(:show , ce.object) %>
<hr/>
<h1> <%= render partial: "calentries/mail", object: ce %>
</h1>
<%= render partial: "neuigkeiten/mail", object: ce.object if ce.object.kind_of?(Neuigkeit)%>
<% end %>
<% end %>
<hr/>

View File

@@ -4,7 +4,7 @@
<h1> <h1>
<%= @neuigkeit.title%> <%= @neuigkeit.title%>
</h1> </h1>
<%= content_tag(:img,"",src: "http://"+ActionMailer::Base.default_url_options[:host].to_s+@neuigkeit.picture.big_thumb.url) %> <%= content_tag(:img,"",src: "http://"+ActionMailer::Base.default_url_options[:host].to_s+@neuigkeit.picture.big_thumb.url.to_s) %>
<%=url_for controller: "neuigkeiten",action: :show, :id=>@neuigkeit.id, only_path: false %> <%=url_for controller: "neuigkeiten",action: :show, :id=>@neuigkeit.id, only_path: false %>
<%= raw(@neuigkeit.text) %> <%= raw(@neuigkeit.text) %>
<% @neuigkeit.questions.each do |q| %> <% @neuigkeit.questions.each do |q| %>

View File

@@ -33,16 +33,17 @@
</div> </div>
</div> </div>
<% unless @calentries.nil? or @calentries.empty? or true%>
<div class="span3"> <div class="span3">
<% unless @calentries.nil? or @calentries.empty? %>
<% cache("calendar_" + @calentries.map{|c| c.id}.join('') + @calentries.max{|c|c.updated_at.to_i}.updated_at.to_i.to_s+"_"+I18n.locale.to_s+params[:month].to_s+params[:year].to_s) do %> <% cache("calendar_" + @calentries.map{|c| c.id}.join('') + @calentries.max{|c|c.updated_at.to_i}.updated_at.to_i.to_s+"_"+I18n.locale.to_s+params[:month].to_s+params[:year].to_s) do %>
<%= render 'calendars/calentries', :object=>@calentries %> <%= render 'calendars/calentries', :object=>@calentries %>
<% end %> <% end %>
<% end %>
<% if !current_user.nil? and current_user.has_role?(:fetuser) %> <% if !current_user.nil? and current_user.has_role?(:fetuser) %>
<%= link_to calendars_url(:format=>:ics, :key=>Key.find_or_create(current_user,1).uuid) , calendars_path(:format=>:ics, :key=>Key.find_or_create(current_user,1).uuid)%> <%= link_to calendars_url(:format=>:ics, :key=>Key.find_or_create(current_user,1).uuid) , calendars_path(:format=>:ics, :key=>Key.find_or_create(current_user,1).uuid)%>
<% end %> <% end %>
</div> </div><% end %>
</div> </div>
</div> </div>
</div> </div>

View File

@@ -9,7 +9,7 @@
<div class="content-wrap content-column" style="max-width:90em;"> <div class="content-wrap content-column" style="max-width:90em;">
<h1><%= I18n.t('home.willkommen') %></h1> <h1><%= I18n.t('home.willkommen') %></h1>
<%= raw(@starttopic.text) %> <%= raw(@starttopic.text) unless @starttopic.nil? %>
<div class="container-fluid"> <div class="container-fluid">
@@ -26,7 +26,7 @@
<li> <li>
<%= link_to ffi1_icon("quiz")+ I18n.t("themengruppe.faqs"), faqs_themengruppen_path,class: :linkbox %> <%= link_to ffi1_icon("quiz")+ I18n.t("themengruppe.faqs"), faqs_themengruppen_path,class: :linkbox %>
</li> </li>
<li><%= link_to ffi1_icon("books19")+"Beispielsammlung", studium_path(Studium.first, {:ansicht=>'semesteransicht'}) ,class: :btn ,class: :linkbox %></li> <li><%= link_to ffi1_icon("books19")+"Beispielsammlung", studium_path(Studium.first, {:ansicht=>'semesteransicht'}) ,class: :btn ,class: :linkbox if Studium.count >0 %></li>
<li><%= link_to "Alte Beispielsammlung", "http://www.fet.at/alt/bin/view/Beispielsammlung/WebHome" ,class: :btn ,class: :linkbox %></li> <li><%= link_to "Alte Beispielsammlung", "http://www.fet.at/alt/bin/view/Beispielsammlung/WebHome" ,class: :btn ,class: :linkbox %></li>
</ul> </ul>

View File

@@ -1,32 +0,0 @@
<div id="<%= beispiel.divid %>" class="contentbox">
<div class="row-fluid">
<div class="span5" >
<b><%=link_to ffi1_icon("note20")+" " + beispiel.name + " " + I18n.l(beispiel.datum), beispiel.beispieldatei.url, title: beispiel.desc %></b>
</div>
<div class="span1" >
<%= (beispiel.beispieldatei.size/1024.0).round(2).to_s %>KiB
</div>
<div class="span2" >
<%= beispiel.lecturer.try(:name).to_s %>
</div>
<div class="span4">
<%= flag_link(beispiel, "goodquality")%>
<%= flag_link(beispiel, "badquality")%>
<%= flag_link(beispiel, "delete")%>
<%= like_dislike_for(beispiel) %>
<%= link_to ff_icon("icon-pencil")+"edit", edit_beispiel_path(beispiel), remote: true if can? :edit, beispiel %>
<%= link_to fa_icon("trash")+"delete", beispiel_path(beispiel), :method=>:delete, :data=>{:confirm=>I18n.t('beispiel.sure')} if can? :delete, beispiel %>
<% link_to "Refresh", beispiel_path(beispiel,show_comments: true), remote: true %></br>
</div>
</div>
<% unless beispiel.desc.nil? || beispiel.desc.empty? %>
<div class="row-fluid">
<div class="span12">
<%= beispiel.desc %>
</div>
</div>
<% end %>
<%= render_comments_for(beispiel) %>
</div>

View File

@@ -1,67 +0,0 @@
<div id="fb-root"></div>
<script>(function(d, s, id) {
var js, fjs = d.getElementsByTagName(s)[0];
if (d.getElementById(id)) return;
js = d.createElement(s); js.id = id;
js.src = "//connect.facebook.net/de_DE/sdk.js#xfbml=1&appId=120379864660921&version=v2.0";
fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));</script>
<div class="content-wrap content-column" style="max-width:90em;">
<h1><%= I18n.t('home.willkommen') %></h1>
<%= raw(@starttopic.text) %>
<div class="container-fluid">
<div class="row-fluid">
<div class="span4">
<ul class="linklist">
<li>
<%= link_to ffi1_icon("facebook1") + I18n.t('home.fblogin'), user_omniauth_authorize_path(:facebook) ,class: :linkbox %>
</li>
<li>
<%= link_to ffi1_icon("academic") + I18n.t('home.login'), user_omniauth_authorize_path(:ldap) ,class: :linkbox %>
</li>
<li>
<%= link_to ffi1_icon("quiz")+ I18n.t("themengruppe.faqs"), faqs_themengruppen_path,class: :linkbox %>
</li>
<li><%= link_to ffi1_icon("books19")+"Beispielsammlung", studium_path(Studium.first, {:ansicht=>'semesteransicht'}) ,class: :btn ,class: :linkbox %></li>
<li><%= link_to "Alte Beispielsammlung", "http://www.fet.at/alt/bin/view/Beispielsammlung/WebHome" ,class: :btn ,class: :linkbox %></li>
</ul>
<% cache("stickytopics_startpage_"+cache_array_key(@stickythemen)) do %>
<ul class="linklist">
<% @stickythemen.each do |t1| %>
<li>
<%= link_to t1,:class=>:linkbox do %>
<%= render partial: "themen/nlink", object: t1 %>
<% end %>
</li>
<% end %>
</ul>
<% end %>
<%= render 'beispiele' %>
</div>
<div class="span5">
<ul class="unstyled linklist">
<% @neuigkeiten.each do |n| %>
<li><%= render n if can?(:show, n) %> </li>
<% end %>
</ul>
</div>
<div class="span3">
<% cache("calendar_" + cache_array_key(@calentries)+params[:month].to_s+params[:year].to_s) do %>
<%= render 'calendars/calentries', :object=>@calentries %>
<% end %>
<div class="fb-like-box" data-href="https://www.facebook.com/FachschaftET" data-colorscheme="light" data-show-faces="true" data-header="true" data-stream="false" data-show-border="true"></div>
</div>
</div>
</div>
</div>

View File

@@ -1,58 +0,0 @@
<h1> FET Intern NEU blue2</h1>
<div class="container-fluid">
<div class="row-fluid">
<div class="span6">
<div>
<ul class="linklist_block">
<li>
<%= link_to fa_icon("list")+"Adressliste", internlist_fetprofiles_path ,class: :linkbox %>
</li>
<li>
<%= link_to ff_icon("ffi1-setting")+"Admin" , admin_home_index_path, class: :linkbox if current_user.has_role?(:fetadmin) %>
</li>
<li>
<%= link_to ff_icon("fa fa-folder")+"Treeview" , treeview_home_index_path, class: :linkbox if current_user.has_role?(:fetadmin) %>
</li>
<li>
<%= link_to ff_icon("ffi1-newspaper9")+"Crawler" , crawler_index_path, class: :linkbox if current_user.has_role?(:fetadmin) %>
</li>
<li>
<%= link_to ff_icon("ffi1-setting")+"Meetings" , meetingtyps_path, class: :linkbox if current_user.has_role?(:fetadmin) %>
</li>
</ul><br>
</div>
<div>Suche nach Protokollen
<%= semantic_form_for :search,:remote=>true, :url=>search_documents_path, :html=>{:id=>"search_form",:class=>"", :method=>'get'} do |f| %>
<%= f.input :query, :input_html => { :name => 'query' } , :label=>false, :class=>"search-query" %>
<% f.actions do %>
<% f.action :submit, :as => :input %>
<% end %>
<% end %>
<div id="searchresults">
<%= render :partial=>"documents/search_results", :object=>@results %>
</div>
</div>
<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>

View File

@@ -1,65 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="shortcut icon" href="<%= absurl("/logo2014_64.png")%>">
<link rel="alternate" hreflang="de" href="<%= url_for(params.merge(:locale=>:de))%>" />
<link rel="alternate" hreflang="en" href="<%= url_for(params.merge(:locale=>:en))%>" />
<%= stylesheet_link_tag "themes/"+theme_name+"/application", :media => "all" unless theme_name.empty? %>
<%= stylesheet_link_tag "application", :media=>"all" if theme_name.empty? %>
<%= javascript_include_tag "application" %>
<%= csrf_meta_tags %>
<% if content_for?(:header) %>
<%= yield :header %>
<% else %>
<title>Fetsite</title>
<% end %>
</head>
<body>
<div id="maincontainer" class="container-fluid">
<div class="row-fluid">
<div class="span10 offset1 header_span">
<% cache("menu_u"+user_signed_in?.to_s+current_user.try(:id).to_s+"l"+I18n.locale.to_s+ can?(:seeintern, User).to_s+ can?(:index,Gallery).to_s+params[:theme].to_s, expires_in: 24.hours) do %>
<div class="header_wrap">
<div class="header hidden-print">
<%= link_to home_index_path do %>
<!-- <span class="feticon-fet_logo fa-4x color-1"> </span>-->
<%= image_tag('/logo2014_64.png',{:style=>"float:left;height:50px",:height=>"50"}) %>
<% end %>
</div>
<div class="header visible-print">
<%= image_tag('/logo2014_64.png',{:style=>"float:left;height:50px",:height=>"50"}) %>
</div>
<div class="visible-print">
Fachschaft Elektrotechnik
<hr/>
</div>
<div id="menudiv" style="margin-top:12px" class="hidden-print">
<%= render :template => 'layouts/menu' %>
</div>
</div>
<% end %>
</div>
</div>
<div class="row-fluid">
<div class="span10 offset1" id="contentdiv">
<%= yield %>
</div>
</div>
</div>
<script>
$('.dropdown-toggle').click(function(e) {
e.preventDefault();
setTimeout($.proxy(function() {
if ('ontouchstart' in document.documentElement) {
$(this).siblings('.dropdown-backdrop').off().remove();
}
}, this), 0);
});
</script>
</body>
</html>

View File

@@ -1,62 +0,0 @@
<div class="navbar">
<div class="navbar-inner">
<div class="container">
<!-- <a class="brand" href="#"><% t 'home.mtitle'%></a>-->
<a class ="btn btn-navbar" data-toggle="collapse" data-parent="#menudiv" data-target=".nav-collapse">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</a>
<div class="nav-collapse collapse">
<ul class="nav nav-pills nav-stacked">
<li><%= link_to I18n.t(:home,:scope=>'home' ), home_index_path %>
</li>
<li><%= link_to I18n.t(:news,:scope=>'home' ),rubriken_path %></li>
<li><%= link_to I18n.t(:info,:scope=>'home' ),themengruppen_path %></li>
<li><%= link_to I18n.t('mitarbeiter',:scope=>'home' ),fetprofiles_path %></li>
<% if can? :index, Gallery %>
<li><%= link_to I18n.t('fotos',:scope=>'home' ),galleries_path %></li>
<% end %>
<li><%= link_to I18n.t(:studien,:scope=>'home' ), studien_path %></li>
<li> <%= link_to I18n.t("home.search"), search_home_index_path %></li>
<li> <%= link_to I18n.t("home.kontakt"), kontakt_home_index_path %></li>
<% if can?(:seeintern, User) %>
<li>
<%= link_to 'Intern' , intern_home_index_path %>
</li><% end %>
</ul>
<ul class="nav nav-pills nav-stacked pull-right">
<li>
<!--<a href="#" class="dropdown-toggle" data-toggle="dropdown" data-hover="dropdown" > <%= image_tag("/flaggen/png/"+I18n.locale.to_s+".png") + " " +I18n.t('sprache',:scope=>'home')%><b class="caret"></b></a>-->
<!-- Split button -->
<div class="btn-group navbar-btn">
<button type="button" class="btn btn-link dropdown-toggle" data-hover="dropdown" aria-expanded="false">
<%= image_tag("/flaggen/png/"+I18n.locale.to_s+".png") + " " +I18n.t('sprache',:scope=>'home')%>
</button>
<button type="button" class="btn btn-link dropdown-toggle" data-hover="dropdown" data-toggle="dropdown" >
<span class="caret"></span>
</button>
<ul class="dropdown-menu" role="menu">
<li><%= link_to image_tag("/flaggen/png/at.png") + " Deutsch" ,switch_locale_url(:de)%> </li>
<li><%= link_to image_tag("/flaggen/png/gb.png") + " English" ,switch_locale_url(:en)%> </li>
</ul></div>
</li>
<%= render 'layouts/login' %>
</ul>
<!--<span class="pull-right"><%if I18n.locale == :en %>
<%= link_to image_tag("/flaggen/png/at.png") + " Deutsch" ,switch_locale_url(:de)%>
<% elsif I18n.locale == :de %>
<%= link_to image_tag("/flaggen/png/gb.png") + " English" ,switch_locale_url(:en)%>
<%end %>
</span>-->
</div>
</div>
</div>
</div>

View File

@@ -1,154 +0,0 @@
<%= content_for :header do %>
<title>Fetsite - <%= @lva.full_name %></title>
<% set_meta_tags :og => {
:url=>lva_path(:theme=>nil) }
%>
<%= display_meta_tags %>
<% end %>
<div itemscope itemtype="schema.org/Article" >
<div class="container-fluid">
<%= render 'studien/tabs'%>
<p id="notice"><%= notice %></p>
<div class="row-fluid">
<div class="span12">
<%= render 'layouts/pretty_toolbar' %>
</div>
</div>
<div class="row-fluid">
<div class="span8">
<h1 itemprop="name"><%= @lva.full_name %></h1>
<meta itemprop="url" content="<%= lva_path(@lva) %>" />
<ul class="linklist">
<li>
<%= link_to ffi1_icon("live2")+"ET-Forum", @lva.forumlink, class: :linkbox, itemprop: "discussionUrl" unless @lva.forumlink.nil? or @lva.forumlink.empty?%>
</li>
<li>
<%= link_to "TISS", @lva.tisslink, class: :linkbox %>
</li>
</ul>
<div itemprop="articleBody">
<h2><%= I18n.t('lva.pruefungsinfo')%></h2>
<div class="">
<%= @lva.pruefungsinformation.to_s.html_safe %>
</div>
<h2><%= I18n.t('lva.lernaufwand')%></h2>
<div class="">
<%= @lva.lernaufwand %>
</div>
<h2><%= I18n.t('lva.desc')%></h2>
<div class="">
<%= @lva.desc.to_s.html_safe %>
</div>
</div>
</div>
<div class="span4">
<div class="contentbox">
<ul>
<li><b><%= I18n.t('lva.lvanr')%>:</b> <%=@lva.lvanr %></li>
<li><b>ECTS:</b> <%=@lva.ects %></li>
<li><b><%= I18n.t('lva.stunden')%>:</b> <%=@lva.stunden %></li>
</ul>
<h2><%= I18n.t('lva.module')%></h2>
<ul>
<% @lva.modul.each do |modul| %>
<li><b><%= link_to modul.name , modul_path(modul)%></b>
<ul>
<% modul.modulgruppen.each do |g| %>
<li><%= link_to g.studium.title_context , studium_path(g.studium)%> (<%=link_to g.name, modulgruppe_path(g)%>)</li>
<% end %>
</ul>
</li>
<% end %>
</ul>
</div>
<div class="contentbox">
<h2> <%= I18n.t "lecturers.lecturers" %> </h2>
<% @lva.lecturers.each do |lec| %>
<%= render :partial=>'lecturers/lec_lva', :object=>lec %>
<% end %>
</div>
</div>
</div>
<div class="row-fluid">
<div class="span12">
<%= new_question_for(@lva) %>
<% @questions.each do |q| %>
<%= render q if can? :show, q %>
<% end %>
<h2><%= I18n.t("lva.bspe") %></h2>
<p>
<%= I18n.t("lva.ratebsp")%>
<%= link_to ffi1_icon("facebook1") + I18n.t('home.fblogin'), user_omniauth_authorize_path(:facebook) ,class: :linkbox %>
</p>
<%= link_to t("beispiel.zip") , beispiel_sammlung_lva_path(@lva), class: :linkbox %>
<% @beispiele.each do |b| %>
<% cache("beispiel_" +I18n.locale.to_s+b.id.to_s+can?(:delete,b).to_s+"_"+can?(:edit,b).to_s + "_" + can?(:flag, b).to_s + "_" + can?(:like, b).to_s + "_" + b.updated_at.try(:utc).try(:to_s) + get_theme_help(current_user).to_s) do %>
<%= render b%>
<% end %>
<% end %>
<% if @beispiele_badQ.count > 0 %>
<h3> Bad Quality or Outdated</h3>
<% @beispiele_badQ.each do |b| %>
<% cache("beispiel_" +I18n.locale.to_s+b.id.to_s+can?(:delete,b).to_s+"_"+can?(:edit,b).to_s + "_" + can?(:flag, b).to_s + "_" + can?(:like, b).to_s + "_" + b.updated_at.try(:utc).try(:to_s) + get_theme_help(current_user).to_s) do %>
<%= render b%>
<% end %>
<% end %>
<% end %>
<% if @beispiele_deleted.count > 0 %>
<h3> Trash</h3>
<% @beispiele_deleted.each do |b| %>
<% cache("beispiel_" +I18n.locale.to_s+b.id.to_s+can?(:delete,b).to_s+"_"+can?(:edit,b).to_s + "_" + can?(:flag, b).to_s + "_" + can?(:like, b).to_s + "_" + b.updated_at.try(:utc).try(:to_s) + get_theme_help(current_user).to_s) do %>
<%= render b%>
<% end %>
<% end %>
<% end %>
</div>
</div>
<div class="row-fluid">
<div class="span12">
<% unless @lva.nlinks.empty? %>
<h2><%= I18n.t("rubrik.title") %></h2>
<% @lva.nlinks.each do |l| %>
<%= render l.neuigkeit %>
<% end %>
<% end %>
</div>
</div>
<% cache("lva_beispiel_form_bulk_"+@lva.id.to_s+I18n.locale.to_s+@lva.updated_at.to_i.to_s) do %>
<div class="row-fluid">
<div class="span12">
<%= render 'beispiele/form_bulk' %>
</div>
</div>
<% end %>
<% unless @crawlobjects.nil? %>
<div class="row-fluid">
<div class="span12">
<% @crawlobjects.each do |co| %>
<%= render co %>
<% end %>
</div>
</div>
<% end %>
</div>
</div>

View File

@@ -1,74 +0,0 @@
<div class="toolbar-inline">
<%= link_to(fa_icon("edit"), edit_rubrik_neuigkeit_path( @neuigkeit.rubrik, @neuigkeit), remote: true , class: "btn", title: "Edit") if can? :edit, @neuigkeit
%>
<span class="btn-group">
<%= link_to(fa_icon("paperclip"), "#", \
class: "btn", id: "attachments-form-open", title: "Attachments") \
if can? :edit, @neuigkeit
%>
<%= link_to(fa_icon("calendar-o"), \
new_calentry_path(:object_id=>@neuigkeit.id, :object_type=>"Neuigkeit"), \
:remote=>true, class: :btn) \
if can? :edit, @neuigkeit
%>
<%= link_to(fa_icon("link") , "#", \
id: "findlink-open",title: "Neue Verknüpfung" , class: "btn") \
if can? :find_link, @neuigkeit
%>
</span>
<%= new_question_for(@neuigkeit, fa_icon("question")) if can? :new, Survey::Question %>
<span class=" pull-right">
<%= link_to(fa_icon("globe"), \
publish_rubrik_neuigkeit_path(@neuigkeit.rubrik,@neuigkeit), \
title: I18n.t('neuigkeit.publish'), class: "btn") \
if can?(:publish, @neuigkeit) && !@neuigkeit.published?
%>
<%= link_to (fa_stack("globe","ban"), \
unpublish_rubrik_neuigkeit_path(@neuigkeit.rubrik,@neuigkeit), \
:remote=>true, class: "btn stacked") \
if can?(:unpublish, @neuigkeit) && @neuigkeit.published?
%>
<% if @neuigkeit.published? %>
<div class="dropdown" style=" display:inline"">
<a class="dropdown-toggle btn" data-toggle="dropdown" title="publish" href="#">
<%= fa_icon("mail-forward")%><span class="caret"></span>
</a>
<ul class="dropdown-menu">
<%= li_tag(link_to(fa_icon("facebook-square") + " post on facebook", \
publish_to_facebook_rubrik_neuigkeit_path(@neuigkeit.rubrik,@neuigkeit))) \
if can?(:publish, @neuigkeit) && @neuigkeit.published?
%>
<%= li_tag(link_to(fa_icon("envelope-o") + " send mail", \
mail_to_fet_rubrik_neuigkeit_path(@neuigkeit.rubrik,@neuigkeit))) \
if can?(:publish, @neuigkeit) && @neuigkeit.published?
%>
</ul>
</div>
<% end %>
</span>
<div class="ui-dialog" id="attachments-form">
<%= render_new_attachments_for(@neuigkeit, fa_icon("plus"), {class: "btn"}) %>
</div>
</div>
<script>
$(function(){
dialogatt = $( "#attachments-form" ).dialog({
autoOpen: false,
width: "90%",
modal: true,
title: "Neue Attachments",
buttons: {
"Fertig": function() {
dialogatt.dialog( "close" );
}
}
});
$("#attachments-form-open").on("click",function(){dialogatt.dialog("open")})
});
</script>

View File

@@ -1,68 +0,0 @@
<div id="neuigkeit_<%= neuigkeit_view.id %>" class="contentbox" itemscope itemtype="http://schema.org/Article">
<%= meta_itemprop("about", neuigkeit_view.text_first_words) %>
<%= meta_itemprop("sameAs", neuigkeit_url(neuigkeit_view,:theme=>nil)) %>
<%= meta_itemprop("url", neuigkeit_url(neuigkeit_view,:theme=>nil)) %>
<div>
<% cache() do %>
<%= render partial: "menu" %>
<% end %>
</div>
<div>
<%#= render 'layouts/pretty_toolbar', :object=> @toolbar_elements %>
</div>
<div class="media">
<span itemprop="articleSection">
<%= ff_icon(neuigkeit_view.rubrik.icon) unless neuigkeit_view.rubrik.icon.nil? or neuigkeit_view.rubrik.icon.empty? %>&nbsp;<%= neuigkeit_view.rubrik.name %>
</span>
<span class="pull-right">
<span itemprop="author"><%= neuigkeit_view.author.email.to_s unless neuigkeit_view.try(:author).try(:email).to_s %>
<%= neuigkeit_view.author.text %></span>
<% unless neuigkeit_view.try(:datum).try(:to_date).nil? %>
<%= " "+ I18n.t("neuigkeit.am")+" " %><span itemprop="datePublished"><%= I18n.l(neuigkeit_view.try(:datum).try(:to_date)) %>
</span>
<% end %>
</div>
<% unless neuigkeit_view.published? %>
<div class="sticker sticker-red"> Not Published <%= link_to "Publish", publish_rubrik_neuigkeit_path(@neuigkeit.rubrik,@neuigkeit),remote:true, class: :btn if can? :publish, neuigkeit_view %></div>
<% end %>
<% unless neuigkeit_view.origurl.nil? || neuigkeit_view.origurl.empty? %>
<div class="alert"><%= link_to "Zitiert von "+ neuigkeit_view.origurl, neuigkeit_view.origurl %>
</div>
<% end %>
<div class="media">
<% unless neuigkeit_view.picture_robust.big_thumb.to_s.empty? %>
<div class="pull-left" href="#">
<p><br><%= link_to image_tag(neuigkeit_view.picture_robust.big_thumb),neuigkeit_view.picture_robust.try(:url) %>
</p>
</div>
<% end %>
<div class="media-body">
<h1 itemprop="name">
<%= raw(neuigkeit_view.title) %> <%#= link_to fa_icon("edit"), edit_rubrik_neuigkeit_path(neuigkeit_view.rubrik, neuigkeit_view), remote: true if can? :edit, neuigkeit_view %>
</h1>
<div itemprop="articleBody">
<%= raw(neuigkeit_view.text) %>
</div>
</div>
</div>
<%= render_calentries_for(neuigkeit_view)%>
<%= new_calentry_div(neuigkeit_view) %>
<% unless neuigkeit_view.meeting.nil? %>
<%= render neuigkeit_view.meeting %>
<% end%>
<%= render_attachments_list_for(neuigkeit_view) %>
</div>
<% @questions.each do |q| %>
<%= render q if can? :show, q %>
<% end %>

View File

@@ -1,76 +0,0 @@
<%= content_for :header do %>
<title>Fetsite - <%= @neuigkeit.title %> (<%= @neuigkeit.rubrik.name %>)</title>
<% set_meta_tags :author => fetprofile_path(@neuigkeit.author.fetprofile) unless @neuigkeit.author.fetprofile.nil? %>
<% unless @neuigkeit.picture_robust.url.nil? %>
<%
picture_url=URI(root_url)
picture_url.path=@neuigkeit.picture_robust.url(:locale=>nil, :theme=>nil)
%>
<% end %>
<% set_meta_tags :og =>
{
:image => picture_url.to_s,
:title => @neuigkeit.title.to_s + " (" + @neuigkeit.rubrik.name.to_s + ")",
:type => "article",
:description =>@neuigkeit.text_first_words,
:url=>neuigkeit_url(:theme=>nil)
}
%>
<%= display_meta_tags %>
<% end %>
<%= render 'rubriken/tabs' %>
<div id="fb-root"></div>
<script>(function(d, s, id) {
var js, fjs = d.getElementsByTagName(s)[0];
if (d.getElementById(id)) return;
js = d.createElement(s); js.id = id;
js.src = "//connect.facebook.net/de_DE/sdk.js#xfbml=1&appId=120379864660921&version=v2.0";
fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));</script>
<div class="content-column content-wrap">
<%= link_to "Refresh", neuigkeit_path(@neuigkeit), remote: true %>
<p id="notice">
<%= notice %>
</p>
<%= render partial: "neuigkeit_view", object: @neuigkeit %>
</div>
<div class="fb-like" data-href"<%= rubrik_neuigkeit_url(@rubrik,@neuigkeit,{themes: nil, locale: nil})%>" data-layout="standard" data-action="like" data-show-faces="true" data-share="true"></div>
<%= link_to fa_icon("link") + "Neue Verknüpfung" , "#", id: "findlink-open" if can? :find_link, @neuigkeit %>
<% cache(cache_array_key(@neuigkeit.nlinks, "NLinks")) do %>
<%= render partial: 'neuigkeiten/nlink_list_whole', :object=>@neuigkeit.nlinks %>
<% end %>
<div id="findlink-body" class="ui-dialog" style="">
<% if can? :find_link, @neuigkeit %>
Nach Element suchen:
<%= semantic_form_for :find_link, :url=>find_link_rubrik_neuigkeit_path(@rubrik,@neuigkeit), :html=>{:id=>"search_form", :method=>'get'} , :remote=> true do |f| %>
<%= f.input :query, :input_html => { :name => 'query' },:label=>false %>
<% end %>
<%= render partial: 'nlink_list_search_whole', object: @nlink_search %>
<% end %>
</div>
<script>
$(function(){
dialog = $( "#findlink-body" ).dialog({
autoOpen: false,
width: 350,
modal: true,
title: "Neue Verknüpfung hinzufügen",
buttons: {
"Fertig": function() {
dialog.dialog( "close" );
}
}
});
$("#findlink-open").on("click",function(){dialog.dialog("open")})
});
</script>

View File

@@ -33,7 +33,7 @@
</td> </td>
<td> <td>
<%= semantic_fields_for "users[#{user.id}]", user do |f|%> <%= semantic_fields_for "users[#{user.id}]", user do |f|%>
<%= f.input :fetprofile ,:label=>false , :as=>:select , :collection=>Fetprofile.all %> <%= f.input :fetprofile ,:label=>false , :as=>:select , :collection=>Fetprofile.order(:vorname,:nachname) %>
<% end %> <% end %>
</td> </td>

View File

@@ -16,7 +16,7 @@ Fetsite::Application.configure do
# Don't care if the mailer can't send # Don't care if the mailer can't send
config.action_mailer.raise_delivery_errors = true config.action_mailer.raise_delivery_errors = true
config.action_mailer.delivery_method =:sendmail config.action_mailer.delivery_method =:sendmail
config.action_mailer.default_url_options = {}#{:host=> "localhost", :port=>3000} # :host => 'glonass.htu.tuwien.ac.at' } config.action_mailer.default_url_options = {:host=> "localhost", :port=>3000} # :host => 'glonass.htu.tuwien.ac.at' }
# Print deprecation notices to the Rails logger # Print deprecation notices to the Rails logger
config.active_support.deprecation = :log config.active_support.deprecation = :log

View File

@@ -31,7 +31,7 @@ Fetsite::Application.configure do
# config.force_ssl = true # config.force_ssl = true
# See everything in the log (default is :info) # See everything in the log (default is :info)
config.log_level = :debug config.log_level = :info
# Prepend all log lines with the following tags # Prepend all log lines with the following tags
config.log_tags = [ :remote_ip , :uuid ] config.log_tags = [ :remote_ip , :uuid ]
@@ -66,6 +66,6 @@ Fetsite::Application.configure do
# with SQLite, MySQL, and PostgreSQL) # with SQLite, MySQL, and PostgreSQL)
# config.active_record.auto_explain_threshold_in_seconds = 0.5 # config.active_record.auto_explain_threshold_in_seconds = 0.5
config.facebookconfig_enabled=true config.facebookconfig_enabled=false
end end

View File

View File

@@ -1 +1 @@
Rails.application.config.assets.precompile += ['blueimp-gallery-all.js'] Rails.application.config.assets.precompile += ['blueimp-gallery-all.js', 'jmpress.js']

View File

@@ -225,6 +225,7 @@ Devise.setup do |config|
# up on your models and hooks. # up on your models and hooks.
#config.omniauth :facebook, 'appid', 'secret' #config.omniauth :facebook, 'appid', 'secret'
secrets = YAML.load_file("#{::Rails.root.to_s}/config/omniauth_secrets.yml") secrets = YAML.load_file("#{::Rails.root.to_s}/config/omniauth_secrets.yml")
config.omniauth :developer,:title => "Developer" unless Rails.env.production?
config.omniauth :facebook, secrets["facebook"]["appid"], secrets["facebook"]["secret"] config.omniauth :facebook, secrets["facebook"]["appid"], secrets["facebook"]["secret"]
config.omniauth :ldap, :title => "My LDAP", config.omniauth :ldap, :title => "My LDAP",
:host => secrets["ldap"]["host"], :host => secrets["ldap"]["host"],
@@ -236,6 +237,8 @@ Devise.setup do |config|
:bind_dn =>secrets["ldap"]['bind'], :bind_dn =>secrets["ldap"]['bind'],
:password => secrets["ldap"]['password'] :password => secrets["ldap"]['password']
# ==> Warden configuration<< # ==> Warden configuration<<
# If you want to use other strategies, that are not supported by Devise, or # If you want to use other strategies, that are not supported by Devise, or
# change the failure app, you can configure them inside the config.warden block. # change the failure app, you can configure them inside the config.warden block.

View File

@@ -0,0 +1,74 @@
# config/initializers/sunspot.rb
module Sunspot
#
# DataExtractors present an internal API for the indexer to use to extract
# field values from models for indexing. They must implement the #value_for
# method, which takes an object and returns the value extracted from it.
#
module DataExtractor #:nodoc: all
#
# AttributeExtractors extract data by simply calling a method on the block.
#
class AttributeExtractor
def initialize(attribute_name)
@attribute_name = attribute_name
end
def value_for(object)
Filter.new( object.send(@attribute_name) ).value
end
end
#
# BlockExtractors extract data by evaluating a block in the context of the
# object instance, or if the block takes an argument, by passing the object
# as the argument to the block. Either way, the return value of the block is
# the value returned by the extractor.
#
class BlockExtractor
def initialize(&block)
@block = block
end
def value_for(object)
Filter.new( Util.instance_eval_or_call(object, &@block) ).value
end
end
#
# Constant data extractors simply return the same value for every object.
#
class Constant
def initialize(value)
@value = value
end
def value_for(object)
Filter.new(@value).value
end
end
#
# A Filter to allow easy value cleaning
#
class Filter
def initialize(value)
@value = value
end
def value
strip_control_characters @value
end
def strip_control_characters(value)
return value unless value.is_a? String
value.chars.inject("") do |str, char|
unless char.ascii_only? and (char.ord < 32 or char.ord == 127)
str << char
end
str
end
end
end
end
end

View File

@@ -16,6 +16,7 @@ de:
savecont: "Zwischenspeichern" savecont: "Zwischenspeichern"
intern: "Intern" intern: "Intern"
manage: "Verwalten" manage: "Verwalten"
new: "Neu"
home: home:
sprache: "Deutsch" sprache: "Deutsch"
kontakt: "Kontakt" kontakt: "Kontakt"

View File

@@ -6,6 +6,7 @@ de:
active_members: "Aktive Mitglieder" active_members: "Aktive Mitglieder"
notactive_members: "Pension" notactive_members: "Pension"
new_profile: "Neues Profil anlegen" new_profile: "Neues Profil anlegen"
new: "Neues Profil anlegen"
gremium: gremium:
new: "Neues Gremium" new: "Neues Gremium"
seit: "seit" seit: "seit"

View File

@@ -8,7 +8,20 @@
resources :comments, contstraints: {id: /[0-9]+/}, only: :show resources :comments, contstraints: {id: /[0-9]+/}, only: :show
## Inserted for testing tests
resources :members , controller: :fetprofiles , as: :fetprofiles do
collection do
get 'verwalten'
get 'internlist'
end
end
resources :gremien do
collection do
get 'verwalten'
end
end
#
# #-------------------------
namespace :survey do namespace :survey do
resources :questions do resources :questions do
@@ -26,7 +39,12 @@
themes_for_rails themes_for_rails
devise_for :users, :controllers => { :omniauth_callbacks => "users/omniauth_callbacks" } devise_for :users, :controllers => { :omniauth_callbacks => "users/omniauth_callbacks" }
resources :home, :only=>[:index] do resources :home, :only=>[:index] do
end end
resources :emails, :only=>[:index] do
collection do
get :daily_reminder
end
end
get ':locale', constraints: {locale: /en|de/}, action: :language,controller: :home, as: "language" get ':locale', constraints: {locale: /en|de/}, action: :language,controller: :home, as: "language"
scope '(:locale)/admin' do scope '(:locale)/admin' do
resources :users, :only=>[] do resources :users, :only=>[] do
@@ -35,6 +53,7 @@
post :all_update post :all_update
end end
member do member do
get :set_preferred_theme
get :fb_set_default_publish_page get :fb_set_default_publish_page
end end
end end
@@ -53,6 +72,7 @@
end end
end end
devise_for :users , :controllers=>{:omniauth_callbacks=> "users/omniauth_callbacks"} devise_for :users , :controllers=>{:omniauth_callbacks=> "users/omniauth_callbacks"}
#match '/auth/:provider/callback', to: "session#new", via: [:get, :post]
scope '(:locale)', constraints: {:locale=>/en|de/i} do scope '(:locale)', constraints: {:locale=>/en|de/i} do
@@ -60,6 +80,7 @@
scope '(t/:theme)' do scope '(t/:theme)' do
get "" , controller: :home, action: :index get "" , controller: :home, action: :index
get "intern" , controller: :home, action: :intern get "intern" , controller: :home, action: :intern
get "infoscreen" , controller: :home, action: :infoscreen
get "beispielsammlung", to: redirect('/studien') get "beispielsammlung", to: redirect('/studien')
scope '(:ansicht)' do scope '(:ansicht)' do
resources :studien, :only=>[:new,:edit,:update,:destroy,:show] do resources :studien, :only=>[:new,:edit,:update,:destroy,:show] do
@@ -125,12 +146,12 @@
get 'verwalten' get 'verwalten'
end end
end end
resources :fetprofiles, as: :fetprofiles_bak do # resources :fetprofiles, as: :fetprofiles_bak do
collection do # collection do
get 'verwalten' # get 'verwalten'
get 'internlist' # get 'internlist'
end # end
end # end
resources :members , controller: :fetprofiles , as: :fetprofiles do resources :members , controller: :fetprofiles , as: :fetprofiles do
collection do collection do
get 'verwalten' get 'verwalten'
@@ -140,8 +161,26 @@
resources :fragen, :only =>[:new, :edit, :update, :destroy, :create] resources :fragen, :only =>[:new, :edit, :update, :destroy, :create]
resources :neuigkeiten, :only => [:show] , constraints: {id: /\d+/i} resources :neuigkeiten, :only => [:show] , constraints: {id: /\d+/i} do
member do
get 'publish'
get 'unpublish'
get 'add_calentry'
get 'rm_calentry'
get 'create_link'
get 'delete_link'
get 'find_link'
get 'publish_to_facebook'
get 'mail_to_fet'
get 'mail_preview'
get 'flag'
end
collection do
get 'newsletter_preview'
end
end
get "neuigkeiten", controller: :rubriken, action: :index, as: "neuigkeiten" get "neuigkeiten", controller: :rubriken, action: :index, as: "neuigkeiten"
resources :rubriken do resources :rubriken do
collection do collection do
get 'verwalten' , :action => :alle_verwalten get 'verwalten' , :action => :alle_verwalten
@@ -165,7 +204,7 @@
get 'publish_to_facebook' get 'publish_to_facebook'
get 'mail_to_fet' get 'mail_to_fet'
get 'mail_preview' get 'mail_preview'
get 'flag'
end end
collection do collection do
get 'newsletter_preview' get 'newsletter_preview'

View File

@@ -2,8 +2,10 @@ production:
solr: solr:
hostname: localhost hostname: localhost
port: 8080 port: 8080
log_level: WARNING # log_level: WARNING
path: /solr-4.10.2/default #production #ollection1 #production # min_memory: 32M
# max_memory: 1G
# path: /solr-4.10.2/default #production #ollection1 #production
# solr_home: solr # solr_home: solr
# read_timeout: 2 # read_timeout: 2
# open_timeout: 0.5 # open_timeout: 0.5
@@ -11,9 +13,16 @@ production:
development: development:
solr: solr:
hostname: localhost hostname: localhost
port: 8982 port: 8983
log_level: INFO log_level: INFO
path: /solr/development path: /solr/fetsite_test
# min_memory: 32M
# max_memory: 1G
# solr:
# hostname: localhost
# port: 8983
# log_level: INFO
# path: /solr/mycore
test: test:
solr: solr:

45
config/unicorn.rb Normal file
View File

@@ -0,0 +1,45 @@
# config/unicorn.rb
worker_processes Integer(ENV["WEB_CONCURRENCY"] || 5)
timeout 60
preload_app true
listen "/var/run/fetsite.sock"
stderr_path "/var/log/unicorn.log"
stdout_path "/var/log/unicorn.log"
before_fork do |server, worker|
Signal.trap 'TERM' do
puts 'Unicorn master intercepting TERM and sending myself QUIT instead'
Process.kill 'QUIT', Process.pid
end
defined?(ActiveRecord::Base) and
ActiveRecord::Base.connection.disconnect!
end
after_fork do |server, worker|
Signal.trap 'TERM' do
puts 'Unicorn worker intercepting TERM and doing nothing. Wait for master to send QUIT'
end
defined?(ActiveRecord::Base) and
ActiveRecord::Base.establish_connection
begin
uid, gid = Process.euid, Process.egid
user, group = 'fetsite', 'nogroup'
target_uid = Etc.getpwnam(user).uid
target_gid = Etc.getgrnam(group).gid
worker.tmp.chown(target_uid, target_gid)
if uid != target_uid || gid != target_gid
Process.initgroups(user, target_gid)
Process::GID.change_privilege(target_gid)
Process::UID.change_privilege(target_uid)
end
rescue => e
if RAILS_ENV == 'development'
STDERR.puts "couldn't change user, oh well"
else
raise e
end
end
end

View File

@@ -0,0 +1,7 @@
class AddInfoscreenToNeuigkeit < ActiveRecord::Migration
def change
add_column :neuigkeiten, :flag_infoscreen, :boolean, default: false
add_column :themen, :flag_infoscreen, :boolean, default: false
end
end

0
false Normal file
View File

Some files were not shown because too many files have changed in this diff Show More