Sample dialog containing a Custom MBO

This topic contains a complete example of custom dialog XML containing tabular data. This sample can be used as a reference to create a new table data object. It uses as an example, a Building Access offering that allows a user to create as many rows as needed to specify building access information.

<dialog beanclass="com.ibm.ism.pmsc.webclient.beans.shoppingcr.PmScInputSpecBean" 
headercss="pmscoffcat_dialog_header" id="WPBuildingAccess" label="Building Access" 
labelcss="pmscoffcat_dialog_header" relationship="PMSCCRSPEC" width="800">
<section id="PmBuildingAccess_dial_sec1" textcss="pmscoffcat_text_node">
   <sectionrow id="PmBuildingAccess_first_secrow">
      <datasrc id="PmBuildingAccess_offering_info" relationship="PMSCOFFERING"/>
	   <sectioncol id="PmBuildingAccess_details_col1">
	      <section id="PmBuildingAccess_main_grid2">
		   <sectionrow id="PmBuildingAccess_main_grid1_row11">
		      <sectioncol id="PmBuildingAccess_main_seccol1">
		         <section id="PmBuildingAccess_main_new_section22">
			    <recordimage datasrc="PmBuildingAccess_offering_info" 
                             id="PmBuildingAccess_image" thumbnail="true"/>
			 </section>
		      </sectioncol>
		      <sectioncol id="PmBuildingAccess_main_sc112">
			  <section id="PmBuildingAccess_main_newsec1121">
			     <multiparttextbox dataattribute="itemnum"  
                               datasrc="PmBuildingAccess_offering_info" 
                               descdataattribute="description" descinputmode="readonly" 
                               desctextcss="pmscoffcat_text_node"  
                               id="PmBuildingAccess_main_grid1_11" inputmode="READONLY"   
                               label="Offering" longdesc="false"/>
		            <multilinetextbox columns="60" 
                               dataattribute="PMSCOFFERING.DESCRIPTION_LONGDESCRIPTION" 
                               datasrc="PmBuildingAccess_offering_info" 
                               id="PmBuildingAccess_offering_long_desc"                
                               inputmode="READONLY" label="Description" rows="6"     
                               textcss="pmscoffcat_textarea_node"/>
		         </section>
		      </sectioncol>
		   </sectionrow>
		</section>
	   </sectioncol>
	</sectionrow>
	<sectionrow id="pmbldaccess_omCR_sec_secrow">
	<sectioncol id="pmbldaccess_omCR_sr2_details_col1">
	   <section id="pmbldaccess_omCR_sr2_sec1">
	      <datasrc id="pmbldaccess_omCR_sr2_datasrc" relationship="SR"/>
	         <sectionrow id="pmbldaccess_omCR_sr2_grid1_srow1">			    
                   <sectioncol datasrc="pmbldaccess_omCR_sr2_datasrc" 
                      id="pmbldaccess_omCR_sr2_grid1_row1_col0">
		       <textbox align="LEFT" dataattribute="pmscaffectedperson" 
                         id="pmbldaccess_omCR_sr2_affectedpers_text"  
                         inputmode="required" label="Requested For" lookup="personname" 
                         width="125"/>
		       <textbox align="LEFT" dataattribute="pmscquantity" 
                         id="pmbldaccess_omCR_sr2_reqeddate_text" inputmode="required" 
                         label="Quantity" sigoption="HIDEQUANTITY"/>
		    </sectioncol>
		    <sectioncol id="pmbldaccess_omCR_sr2_grid1_row1_col2">
	               <section datasrc="pmbldaccess_omCR_sr2_datasrc" 
                          id="pmbldaccess_omCR_attach_sec2">
			   <attachments event="drviewattachments" 
                             id="pmbldaccess_omCR_sr2_attach" label="Attachments" 
                             menutype="drattachments"/>
			</section>
		    </sectioncol>
		</sectionrow>
	    </section>
	</sectioncol>
     </sectionrow>
   </section>
   <section id="PmBuildingAccess__tab1topsection" labelcss="pmscoffcat_tablabel" 
      textcss="pmscoffcat_text_node">
      <section cssclass="pmscoffcat_border pmscoffcat_section_color" 
         headercss="pmrdp_section_header_text" id="PmBuildingAccess_step2_DateSec1">
         <sectionrow id="PmBuildingAccess_step2_DateSecRow2">
	    <sectioncol id="PmBuildingAccess_step2_DateSecCol1">
		<section id="PmBuildingAccess_step2_DateSecCol1a">
		   <sctextbox dataattribute="alnvalue1" id="PmBuildingAccess_aln1" 
                     input="true" inputmode="required" label="Employee Name" 
                     labelcss="pmrdp_text_node" usereditable="true"/>
	    	   <sctextbox dataattribute="alnvalue2" id="PmBuildingAccess_alndom1" 
                     label="Employee Serial Number"/>
		</section>
	    </sectioncol>
	    <sectioncol id="PmBuildingAccess_step2_DateSecCol2">
		<section id="PmBuildingAccess_step2_DateSecCol2a">
		   <sctextbox dataattribute="alnvalue3" id="PmBuildingAccess_enddate" 
                     inputmode="required" label="Start Date" lookup="datelookup" 
                     width="100"/>
	           <sctextbox dataattribute="alnvalue4" 
                     id="PmBuildingAccess_step2_startddate" inputmode="required" 
                     label="End Date" lookup="datelookup" width="100"/>
		</section>
	   </sectioncol>
	</sectionrow>
	<sectionrow id="PmBuildingAccess_row_blankline2">
	   <blankline id="PmBuildingAccess_blankspace2"/>
	</sectionrow>
    </section>
	   <blankline id="PmBuildingAccess_grid1_3"/>
	   <section border="true" id="PmBuildingAccess_attrs_step2_table2" label="Add  
              Buildings" textcss="pmscoffcat_text_node">
	      <table
                beanclass="com.ibm.ism.pmsc.webclient.beans.shoppingcr.PmScComplexIt
                emBean" id="PmBuildingAccess__virtserv_table2" 
                ondatachange="refreshtable" parentdatasrc="pmbldaccess_omCR_sr2_datasrc" 
                relationship="PMSCEXBLDACCESS">
		<tablebody displayrowsperpage="5" filterable="true" 
                  id="PmBuildingAccess__table2_tablebody">
		   <tablecol filterable="true" 
                     id="PmBuildingAccess_PmscCatalogTable_tablebody_0"      
                     mxevent="toggledetailstate" mxevent_desc="Show Detail" 
                     sortable="false" type="event"/>
		   <tablecol dataattribute="BUILDINGNUM" 
                     id="PmBuildingAccess__table_tablebody_2_b" label="Building 
                     Number"/>
		   <tablecol dataattribute="DESCRIPTION"  
                     id="PmBuildingAccess__table_tablebody_2_c" label="Description"/>
		   <tablecol dataattribute="ACCESSTYPE" 
                     id="PmBuildingAccess__table_tablebody_2_d" label="Access Type"/>
		   <tablecol filterable="false" hidden="false" 
                     id="PmBuildingAccess__table_tablebody_2_h" 
                     mxevent="toggledeleterow" mxevent_desc="Mark Row for Delete" 
                     mxevent_icon="btn_garbage.gif" sortable="false" type="event"/>
		</tablebody>
		   <tabledetails id="PmBuildingAccess_tabledetails">
		      <section id="PmBuildingAccess_tabledetails_sec1" label="Details">
		         <sectionrow id="PmBuildingAccess_tabledetails_sec1_row1">
			    <sectioncol id="PmBuildingAccess_tabledetails_sec1_row1_col1">
				<combobox dataattribute="BUILDINGNUM" 
                                 id="PmBuildingAccess_aln5aa" label="Building Number" 
                                 labelcss="pmrdp_text_node"/>
				<textbox dataattribute="DESCRIPTION" 
                                 id="PmBuildingAccess_aln5" label="Description" 
                                 labelcss="pmrdp_text_node"/>
			    </sectioncol>
			    <sectioncol 
                              id="PmBuildingAccess_tabledetails_sec1_row1_column1">
			       	<textbox dataattribute="ACCESSTYPE" 
                                 id="PmBuildingAccess_aln5a" label="Access Type" 
                                 labelcss="pmrdp_text_node" lookup="valuelist"/>
				<textbox dataattribute="ADDRESS" 
                                 id="PmBuildingAccess_aln5c" inputmode="readonly" 
                                 label="Address" labelcss="pmrdp_text_node"/>
			    </sectioncol>
			</sectionrow>
		   </section>
		</tabledetails>
		<buttongroup id="PmBuildingAccess_results_showlist_details_3">
		   <pushbutton id="PmBuildingAccess_results_showlist_details_3_1" 
                      label="New Row" mxevent="addrow"/>
		</buttongroup>
	   </table>
	</section>
    </section>
    <buttongroup id="PmBuildingAccess_vOrderBNSMCR" textcss="pmscoffcat_text_node"> 
       <srmpushbutton id="PmBuildingAccess_vgetcnpdataCR_12" label="Add to Favorites" 
          mxevent="addtofav" sigoption="HIDEFAVORITE"/>
       	<srmpushbutton id="PmBuildingAccess_vgetcnpdataCR_122" label="Delete from 
          Favorites" mxevent="deletefav" sigoption="HIDEDELETEFAV" type="event"/>
	<srmpushbutton default="true" id="PmBuildingAccess_vgetcnpdataCR_11" label="Add 
          To Cart" mxevent="dialogok" sigoption="ADDTOCART" type="event" 
          value="opencrdr"/>
	<srmpushbutton id="PmBuildingAccess_vgetcnpdataCR_14" label="Order Now!" 
          mxevent="shippingInfo" sigoption="HIDEORDERNOW" type="event"/>
	<srmpushbutton id="PmBuildingAccess_vgetcnpdataCR_OK" label="OK" 
          mxevent="dialogok" sigoption="OKBUTTON" type="event" value="okClicked"/>
	<srmpushbutton id="PmBuildingAccess_vgetcnpdataCR_13" label="Cancel" 
          mxevent="dialogok" type="event" value="cancelClicked"/>
   </buttongroup>
</dialog>


Feedback