From 2f93e272054ed126be63db31d33e90f51f09d30e Mon Sep 17 00:00:00 2001 From: M.Gergo Date: Tue, 24 Mar 2020 18:56:00 +0100 Subject: Rev: 4633 --- .../classic/module-naplo/css/haladasi/hazifeladat.css | 8 +++++++- .../classic/module-naplo/html/haladasi/hazifeladat.phtml | 15 ++++++++++++--- .../javascript/haladasi/hazifeladat.jquery.min.js | 12 ++++++++++++ 3 files changed, 31 insertions(+), 4 deletions(-) create mode 100644 mayor-orig/mayor-naplo/www/skin/classic/module-naplo/javascript/haladasi/hazifeladat.jquery.min.js (limited to 'mayor-orig/mayor-naplo/www/skin/classic') diff --git a/mayor-orig/mayor-naplo/www/skin/classic/module-naplo/css/haladasi/hazifeladat.css b/mayor-orig/mayor-naplo/www/skin/classic/module-naplo/css/haladasi/hazifeladat.css index 1169d008..127dfa75 100644 --- a/mayor-orig/mayor-naplo/www/skin/classic/module-naplo/css/haladasi/hazifeladat.css +++ b/mayor-orig/mayor-naplo/www/skin/classic/module-naplo/css/haladasi/hazifeladat.css @@ -24,8 +24,14 @@ form button.btnHfStatusz:hover span { color: white; } form button.btnHfStatusz.kesz:hover span { color: orange } + #hazifeladatFeltoltesEngedely { + padding:15px 0px 15px 0px; margin:5px 0px; text-align:center; border-radius:2px; background-color:#eee + } + #hazifeladatFeltoltesEngedely.engedelyezve { background-color: #c8e6c9; } - + input.btnSubmit { + margin: 5px auto 5px auto; + } /*---*/ form button.btnLattamStatusz { diff --git a/mayor-orig/mayor-naplo/www/skin/classic/module-naplo/html/haladasi/hazifeladat.phtml b/mayor-orig/mayor-naplo/www/skin/classic/module-naplo/html/haladasi/hazifeladat.phtml index a8540faa..cddfd0e8 100644 --- a/mayor-orig/mayor-naplo/www/skin/classic/module-naplo/html/haladasi/hazifeladat.phtml +++ b/mayor-orig/mayor-naplo/www/skin/classic/module-naplo/html/haladasi/hazifeladat.phtml @@ -36,8 +36,9 @@ echo '
'._HAZIFELTOLTES.''."\n"; echo formBegin(array('enctype'=>'multipart/form-data')); - if (FILE_UPLOAD_ENABLED===false || $ADAT['hazifeladatDiak']['tanarLattamDt']!='' || $ADAT['hazifeladatDiak']['hazifeladatDiakStatus']=='kész') { + if (FILE_UPLOAD_ENABLED===false || $ADAT['hazifeladatAdat']['hazifeladatFeltoltesEngedely'] == 0 || $ADAT['hazifeladatDiak']['tanarLattamDt']!='' || $ADAT['hazifeladatDiak']['hazifeladatDiakStatus']=='kész') { if (FILE_UPLOAD_ENABLED===false) $mert = ', mert a feltöltés le van tiltva'; + elseif ($ADAT['hazifeladatAdat']['hazifeladatFeltoltesEngedely']==0) $mert = ', mert a tanár nem kért ide csatolt házi feladatot'; elseif ($ADAT['hazifeladatDiak']['tanarLattamDt']!='') $mert = ', mert már láttamozta a tanár'; elseif ($ADAT['hazifeladatDiak']['hazifeladatDiakStatus']=='kész') $mert = ', mert már késznek jelölted a feladatot'; echo '

nem tudsz új filet feltölteni'.$mert.'

'; @@ -131,11 +132,19 @@ removeButtons: 'Cut,Copy,Paste,PasteText,PasteFromWord,Anchor,Underline,Strike,SpecialChar,HorizontalRule' }); "; - echo ''; + + $_CHK = ($ADAT['hazifeladatAdat']['hazifeladatFeltoltesEngedely']==1) ? 'checked="checked"':''; + $_cls = ($ADAT['hazifeladatAdat']['hazifeladatFeltoltesEngedely']==1) ? 'class="engedelyezve"':''; + echo '
'; + echo ''; + echo ''; + echo '
'; + echo '
'; + echo ''; + echo '
'; echo '
'."\n"; if ($skin != 'ajax') formEnd(); - if (count($ADAT['hazifeladatDiak'])>0) { echo '
'; echo 'Visszajelzések'; diff --git a/mayor-orig/mayor-naplo/www/skin/classic/module-naplo/javascript/haladasi/hazifeladat.jquery.min.js b/mayor-orig/mayor-naplo/www/skin/classic/module-naplo/javascript/haladasi/hazifeladat.jquery.min.js new file mode 100644 index 00000000..4d225a86 --- /dev/null +++ b/mayor-orig/mayor-naplo/www/skin/classic/module-naplo/javascript/haladasi/hazifeladat.jquery.min.js @@ -0,0 +1,12 @@ +$(function() { + + $('input[type="checkbox"]').click(function(){ + if($(this).is(":checked")){ + $('#hazifeladatFeltoltesEngedely').addClass('engedelyezve'); + } + else if($(this).is(":not(:checked)")){ + $('#hazifeladatFeltoltesEngedely').removeClass('engedelyezve'); + } + }); + +}); \ No newline at end of file -- cgit v1.2.3