在visualforce页面加载时隐藏的pageblocksection项目

时间:2015-03-29 01:41:33

标签: visualforce

我的要求是,当页面最初加载时,默认情况下应隐藏以下两个pageblocksectionitems,并且在后端,它们将FEE字段值(不显示在页面上)翻转到5.99然后应该有条件地显示这两个pageblocksectionitems(我已经处理了。)

我在visualforce页面中添加了2个pageblocksectionitems。但我想根据字段值显示那些。我怎么能做到这一点?

代码段 -

<apex:pageBlockSectionItem id="emvQn">
                    <apex:outputPanel id="emvQSpan">
                        <apex:outputLabel style="color:red">*</apex:outputLabel>
                        <apex:outputLabel value="If you have a non-EMV"/><br/> 
                        <apex:outputLabel value="compliant card reader, would" /><br/>
                         <apex:outputLabel value="you like to purchase an"/><br/>
                         <apex:outputLabel value="EMV-compliant card reader:" />
                    </apex:outputPanel>
                    <apex:outputPanel id="emvQOSpan">
                        <apex:selectList Value="{!ReaderOption}" id="ReaderOptionsId" onchange="Readerdef('select');" size="1" style="width:250px" onkeypress="handleKeyPressSearch(event);">
                            <apex:selectOption itemValue="None" itemLabel="--None--" />
                            <apex:selectOption itemValue="Yes" itemLabel="Yes"/>                            
                            <apex:selectOption itemValue="No" itemLabel="No" />
                        </apex:selectList>                        
                    </apex:outputPanel>
                </apex:pageBlockSectionItem>

               <apex:pageBlockSectionItem id="emvOpn">                
                    <apex:outputPanel id="emvOpnSpan">
                      <apex:outputLabel style="color:red">*</apex:outputLabel>                        
                      <apex:outputLabel value="Reader Type:"/>
                    </apex:outputPanel>
                    <apex:outputPanel id="emvReadSpan">
                      <apex:selectList Value="{!NewSRSMPODLead.Reader_Type__c}" id="ReaderTypeId" size="1" style="width:250px" onkeypress="handleKeyPressSearch(event);">
                            <apex:selectOption itemValue="None" itemLabel="--None--" />
                            <apex:selectOption itemValue="EMV Card Reader" itemLabel="EMV"/>
                            <apex:selectOption itemValue="MSR Card Reader" itemLabel="MSR"/>                            
                 `enter code here`           <apex:selectOption itemValue="Not Applicable" itemLabel="No thanks"/>
                      </apex:selectList>                                                
                   </apex:outputPanel>
                </apex:pageBlockSectionItem>

0 个答案:

没有答案