Changeset 7631

Show
Ignore:
Timestamp:
04/29/09 13:58:03 (15 months ago)
Author:
josowski
Message:

Fixes a small issue related where the competing interest statement field could be enabled when the user did not select to use it.

References #1281

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • head/ambra/webapp/src/main/webapp/javascript/init_article.js

    r7469 r7631  
    188188  _annotationForm.noteType.value = _annotationForm.cNoteType.value; 
    189189 
     190  if (_annotationForm.competingInterest[0].checked == true) { 
     191    _annotationForm.ciStatement.value = ""; 
     192  } 
     193 
    190194  dojo.xhrPost({ 
    191195     url: _namespace + "/annotation/secure/createAnnotationSubmit.action", 
     
    229233         dojo.fx.wipeIn({ node:submitMsg.id, duration: 500 }).play(); 
    230234         ambra.formUtil.enableFormFields(_annotationForm); 
     235 
     236         if (_annotationForm.competingInterest[0].checked == true) { 
     237           _annotationForm.ciStatementArea.disabled = true; 
     238         } else { 
     239           _annotationForm.ciStatementArea.disabled = false; 
     240         }          
     241 
    231242         _annotationDlg.placeModalDialog(); 
    232243       } 
     
    324335  _annotationForm.competingInterest[1].checked = false; 
    325336 
     337  _annotationForm.ciStatementArea.disabled = true; 
     338 
    326339  // create it 
    327340  ambra.annotation.createNewAnnotation();