<%--
  /**
   * Copyright (c) 2003 by Sun Microsystems, Inc. All rights reserved.
   * Use is subject to license terms.
   *
   * "@(#)sm_chgreadahead_withpools_include.jsp    1.3    03/09/03     SMI"
   * 
   */
 --%>

<%@include file="/layout/spacer.jsp"%>


  <table border="0" cellspacing="0" cellpadding="0">
    <tr>
      <td nowrap>                  
              <table class="back-table" border="0" cellspacing="0" cellpadding="1" width="100%">
                <tr>
                  <td>
                    <table class="front-table" border="0" cellspacing="0" cellpadding="0" width="100%">
                      <tr class="header-row">                        
                        <td align="left">
                          <div class="table-header-text">
                            <bean:message key="affected.pools.table.poolname"/>
                          </div>
                        </td>                                                
                        <td align="left">
                          <div class="table-header-text">
                            <bean:message key="affected.pools.table.currentprofile"/>
                          </div>
                        </td>  
                        <td align="left">
                          <div class="table-header-text">
                            <bean:message key="affected.pools.table.matchingprofiles"/>
                          </div>
                        </td>  
                        <td align="left">
                          <div class="table-header-text">
                            <bean:message key="affected.pools.table.newprofile"/>
                          </div>
                        </td>  
                      </tr>
                      <logic:notPresent name="t4Form" property="affectedPoolObjects">
                       <tr>
                        <td colspan="4" align="left" nowrap>
                          <div class="table-normal-text">
                            <bean:message key="storage.mgmt.system.expert.confirm.affectedpools.none"/>
                          </div>
                        </td> 
                       </tr>
                      </logic:notPresent>

                      <logic:present name="t4Form" property="affectedPoolObjects">
                      <!-- begin data row listing -->
                      <logic:iterate id="afPool" name="t4Form" property="affectedPoolObjects" type="AffectedPool" indexId="idx">
                           <tr>
                             <td>
                               <div class="table-normal-text">
                                   <bean:write name="afPool" property="affectedPool.name"/>
                               </div>
                             </td>
                             <td align="right">
                                <div class="table-normal-text">
                                  <bean:write name="afPool" property="affectedPool.profileName"/>
                                </div>
                             </td>
                             <td>
                                <div class="table-normal-text">
                                  <logic:present name="afPool" property="matchingProfiles">
                                    <html:select size="3" name="afPool" property="newProfile" onchange="changeInput()"> 
                                       <logic:iterate id="profile" name="afPool" property="matchingProfiles" type="StorageProfile" >
                                          <html:option value="<%=profile.getName()%>"/>
                                       </logic:iterate>
                                    </html:select>
                                  </logic:present>
                                  <logic:notPresent name="afPool" property="matchingProfiles">
                                     <bean:message key="affected.pools.table.matchingprofiles.none"/>
                                  </logic:notPresent>
                                </div>
                             </td>
                             <td>
                                <div class="table-normal-text">
                                  <logic:present name="afPool" property="newProfile">
                                    <input type="text" name="newProfileName<%=idx%>" value="<%=afPool.getNewProfile().getName()%>">
                                  </logic:present>
                                  <logic:notPresent name="afPool" property="newProfile">
                                    <input type="text" name="newProfileName<%=idx%>">
                                  </logic:notPresent>
                                </div>
                             </td>
                           </tr>
                         </logic:iterate>
                         </logic:present>
                    </table>
                  </td>
                </tr>
              </table>
            </td>
          </tr>
        </table>
      </td>
    </tr>
  </table>
