Ignore:
Timestamp:
Nov 10, 2009, 1:26:53 PM (14 years ago)
Author:
gav
Message:

Add support for inventory item Pictures and Images.
Add new PersonService, refactor CreateDataService and TaskService to suite.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/grails-app/views/inventoryItemDetailed/show.gsp

    r175 r182  
    77        <title>Show InventoryItem</title>
    88        <nav:resources override="true"/>
     9        <g:render template="/shared/pictureHead" />
    910    </head>
    1011    <body>
     
    1920                <table>
    2021                    <tbody>
    21 
     22                   
     23                        <tr class="prop">
     24                            <td valign="top" class="name">Picture:</td>
     25                            <td valign="top" class="value">
     26                                <g:if test="${inventoryItemInstance.picture}" >
     27                                    <span class='gallery'><wa:pictureLightboxAnchor picture="${inventoryItemInstance.picture}" size="${Image.Medium}" lightboxSize="${Image.Large}" target="_blank" title="Show Original" /></span>
     28                                </g:if>
     29                                <g:else>
     30                                    <g:link controller="pictureDetailed"
     31                                                    params="['inventoryItem.id':inventoryItemInstance?.id]"
     32                                                    action="create">
     33                                        Add Picture
     34                                    </g:link>
     35                                </g:else>
     36                            </td>
     37                        </tr>
    2238                   
    2339                        <tr class="prop">
     
    4359                       
    4460                        <tr class="prop">
    45                             <td valign="top" class="name">Units In Stock:</td>
    46                            
    47                             <td valign="top" class="value">${fieldValue(bean:inventoryItemInstance, field:'unitsInStock')}</td>
    48                            
    49                         </tr>
    50                    
    51                         <tr class="prop">
    52                             <td valign="top" class="name">Unit Of Measure:</td>
    53                            
    54                             <td valign="top" class="value">${inventoryItemInstance?.unitOfMeasure?.encodeAsHTML()}</td>
    55                            
    56                         </tr>
    57 
     61                            <td valign="top" class="name">Location:</td>
     62                           
     63                            <td valign="top" class="value">
     64                                <g:link controller="inventoryLocationDetailed" action="show" id="${inventoryItemInstance?.inventoryLocation?.id}">
     65                                    ${inventoryItemInstance?.inventoryLocation?.encodeAsHTML()}
     66                                </g:link>
     67                                    in ${inventoryItemInstance?.inventoryLocation?.inventoryStore.encodeAsHTML()}
     68                            </td>
     69                           
     70                        </tr>
     71                       
     72                        <tr class="prop">
     73                            <td valign="top" class="name">In Stock:</td>
     74                           
     75                            <td valign="top" class="value">
     76                                ${fieldValue(bean:inventoryItemInstance, field:'unitsInStock')} ${inventoryItemInstance?.unitOfMeasure?.encodeAsHTML()}
     77                            </td>
     78                           
     79                        </tr>
    5880                   
    5981                        <tr class="prop">
     
    184206                                </ul>
    185207                            </td>
    186                            
    187                         </tr>
    188                        
    189                         <tr class="prop">
    190                             <td valign="top" class="name">Inventory Location:</td>
    191                            
    192                             <td valign="top" class="value"><g:link controller="inventoryLocationDetailed" action="show" id="${inventoryItemInstance?.inventoryLocation?.id}">${inventoryItemInstance?.inventoryLocation?.encodeAsHTML()}</g:link></td>
    193208                           
    194209                        </tr>
Note: See TracChangeset for help on using the changeset viewer.