- Timestamp:
- Jan 15, 2010, 6:43:40 AM (15 years ago)
- Location:
- trunk/grails-app
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/grails-app/controllers/MaintenanceActionDetailedController.groovy
r178 r269 27 27 if(maintenanceActionInstance) { 28 28 try { 29 maintenanceActionInstance.delete( )29 maintenanceActionInstance.delete(flush:true) 30 30 flash.message = "MaintenanceAction ${params.id} deleted" 31 31 redirect(action:list) … … 77 77 else { 78 78 flash.message = "MaintenanceAction not found with id ${params.id}" 79 redirect(action: edit,id:params.id)79 redirect(action:list) 80 80 } 81 81 } -
trunk/grails-app/services/CreateBulkDataService.groovy
r261 r269 65 65 // createBulkTestTaskProcedure() 66 66 // createBulkTestMaintenanceActions() 67 // createBulkTestSystemSections() 68 // createBulkTestAssetTypes() 69 // createBulkTestAssemblies() 70 // createBulkTestSubAssemblies() 71 // createBulkTestComponentItems() 67 // createBulkTestSections() 72 68 // createBulkTestAssets() 73 69 // createBulkTestAssetExtenedAttributes() 70 // createBulkTestAssetSubItems() 71 // createBulkTestAssetSubItemExtenedAttributes() 74 72 75 73 log.info "Creating BULK data...complete." -
trunk/grails-app/views/maintenanceActionDetailed/create.gsp
r178 r269 5 5 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> 6 6 <meta name="layout" content="main" /> 7 <title>Create MaintenanceAction</title> 7 <title>Create MaintenanceAction</title> 8 8 </head> 9 9 <body> … … 28 28 <tr class="prop"> 29 29 <td valign="top" class="name"> 30 <label for=" maintenancePolicy">Maintenance Policy:</label>30 <label for="section">Section:</label> 31 31 </td> 32 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:'maintenancePolicy','errors')}"> 33 <g:select optionKey="id" from="${MaintenancePolicy.list()}" name="maintenancePolicy.id" value="${maintenanceActionInstance?.maintenancePolicy?.id}" noSelection="['null':'']"></g:select> 34 </td> 35 </tr> 36 37 <tr class="prop"> 38 <td valign="top" class="name"> 39 <label for="systemSection">System Section:</label> 40 </td> 41 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:'systemSection','errors')}"> 42 <g:select optionKey="id" from="${SystemSection.list()}" name="systemSection.id" value="${maintenanceActionInstance?.systemSection?.id}" noSelection="['null':'']"></g:select> 32 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:'section','errors')}"> 33 <g:select optionKey="id" from="${Section.list()}" name="section.id" value="${maintenanceActionInstance?.section?.id}" noSelection="['null':'']"></g:select> 43 34 </td> 44 35 </tr> … … 55 46 <tr class="prop"> 56 47 <td valign="top" class="name"> 57 <label for="asset Type">Asset Type:</label>48 <label for="assetSubItem">Asset Sub Item:</label> 58 49 </td> 59 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:'asset Type','errors')}">60 <g:select optionKey="id" from="${Asset Type.list()}" name="assetType.id" value="${maintenanceActionInstance?.assetType?.id}" noSelection="['null':'']"></g:select>50 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:'assetSubItem','errors')}"> 51 <g:select optionKey="id" from="${AssetSubItem.list()}" name="assetSubItem.id" value="${maintenanceActionInstance?.assetSubItem?.id}" noSelection="['null':'']"></g:select> 61 52 </td> 62 53 </tr> … … 64 55 <tr class="prop"> 65 56 <td valign="top" class="name"> 66 <label for=" assembly">Assembly:</label>57 <label for="maintenancePolicy">Maintenance Policy:</label> 67 58 </td> 68 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:'assembly','errors')}"> 69 <g:select optionKey="id" from="${Assembly.list()}" name="assembly.id" value="${maintenanceActionInstance?.assembly?.id}" noSelection="['null':'']"></g:select> 70 </td> 71 </tr> 72 73 <tr class="prop"> 74 <td valign="top" class="name"> 75 <label for="subAssembly">Sub Assembly:</label> 76 </td> 77 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:'subAssembly','errors')}"> 78 <g:select optionKey="id" from="${SubAssembly.list()}" name="subAssembly.id" value="${maintenanceActionInstance?.subAssembly?.id}" noSelection="['null':'']"></g:select> 79 </td> 80 </tr> 81 82 <tr class="prop"> 83 <td valign="top" class="name"> 84 <label for="componentItem">Component Item:</label> 85 </td> 86 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:'componentItem','errors')}"> 87 <g:select optionKey="id" from="${ComponentItem.list()}" name="componentItem.id" value="${maintenanceActionInstance?.componentItem?.id}" noSelection="['null':'']"></g:select> 59 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:'maintenancePolicy','errors')}"> 60 <g:select optionKey="id" from="${MaintenancePolicy.list()}" name="maintenancePolicy.id" value="${maintenanceActionInstance?.maintenancePolicy?.id}" noSelection="['null':'']"></g:select> 88 61 </td> 89 62 </tr> … … 109 82 <tr class="prop"> 110 83 <td valign="top" class="name"> 111 <label for=" isActive">Is Active:</label>84 <label for="reasoning">Reasoning:</label> 112 85 </td> 113 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:' isActive','errors')}">114 < g:checkBox name="isActive" value="${maintenanceActionInstance?.isActive}" ></g:checkBox>86 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:'reasoning','errors')}"> 87 <input type="text" id="reasoning" name="reasoning" value="${fieldValue(bean:maintenanceActionInstance,field:'reasoning')}"/> 115 88 </td> 116 89 </tr> … … 118 91 <tr class="prop"> 119 92 <td valign="top" class="name"> 120 <label for=" reasoning">Reasoning:</label>93 <label for="isActive">Is Active:</label> 121 94 </td> 122 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:' reasoning','errors')}">123 < input type="text" id="reasoning" name="reasoning" value="${fieldValue(bean:maintenanceActionInstance,field:'reasoning')}"/>95 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:'isActive','errors')}"> 96 <g:checkBox name="isActive" value="${maintenanceActionInstance?.isActive}" ></g:checkBox> 124 97 </td> 125 98 </tr> -
trunk/grails-app/views/maintenanceActionDetailed/edit.gsp
r178 r269 31 31 <tr class="prop"> 32 32 <td valign="top" class="name"> 33 <label for=" maintenancePolicy">Maintenance Policy:</label>33 <label for="section">Section:</label> 34 34 </td> 35 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:'maintenancePolicy','errors')}"> 36 <g:select optionKey="id" from="${MaintenancePolicy.list()}" name="maintenancePolicy.id" value="${maintenanceActionInstance?.maintenancePolicy?.id}" noSelection="['null':'']"></g:select> 37 </td> 38 </tr> 39 40 <tr class="prop"> 41 <td valign="top" class="name"> 42 <label for="systemSection">System Section:</label> 43 </td> 44 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:'systemSection','errors')}"> 45 <g:select optionKey="id" from="${SystemSection.list()}" name="systemSection.id" value="${maintenanceActionInstance?.systemSection?.id}" noSelection="['null':'']"></g:select> 35 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:'section','errors')}"> 36 <g:select optionKey="id" from="${Section.list()}" name="section.id" value="${maintenanceActionInstance?.section?.id}" noSelection="['null':'']"></g:select> 46 37 </td> 47 38 </tr> … … 58 49 <tr class="prop"> 59 50 <td valign="top" class="name"> 60 <label for="asset Type">Asset Type:</label>51 <label for="assetSubItem">Asset Sub Item:</label> 61 52 </td> 62 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:'asset Type','errors')}">63 <g:select optionKey="id" from="${Asset Type.list()}" name="assetType.id" value="${maintenanceActionInstance?.assetType?.id}" noSelection="['null':'']"></g:select>53 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:'assetSubItem','errors')}"> 54 <g:select optionKey="id" from="${AssetSubItem.list()}" name="assetSubItem.id" value="${maintenanceActionInstance?.assetSubItem?.id}" noSelection="['null':'']"></g:select> 64 55 </td> 65 56 </tr> … … 67 58 <tr class="prop"> 68 59 <td valign="top" class="name"> 69 <label for=" assembly">Assembly:</label>60 <label for="maintenancePolicy">Maintenance Policy:</label> 70 61 </td> 71 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:'assembly','errors')}"> 72 <g:select optionKey="id" from="${Assembly.list()}" name="assembly.id" value="${maintenanceActionInstance?.assembly?.id}" noSelection="['null':'']"></g:select> 73 </td> 74 </tr> 75 76 <tr class="prop"> 77 <td valign="top" class="name"> 78 <label for="subAssembly">Sub Assembly:</label> 79 </td> 80 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:'subAssembly','errors')}"> 81 <g:select optionKey="id" from="${SubAssembly.list()}" name="subAssembly.id" value="${maintenanceActionInstance?.subAssembly?.id}" noSelection="['null':'']"></g:select> 82 </td> 83 </tr> 84 85 <tr class="prop"> 86 <td valign="top" class="name"> 87 <label for="componentItem">Component Item:</label> 88 </td> 89 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:'componentItem','errors')}"> 90 <g:select optionKey="id" from="${ComponentItem.list()}" name="componentItem.id" value="${maintenanceActionInstance?.componentItem?.id}" noSelection="['null':'']"></g:select> 62 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:'maintenancePolicy','errors')}"> 63 <g:select optionKey="id" from="${MaintenancePolicy.list()}" name="maintenancePolicy.id" value="${maintenanceActionInstance?.maintenancePolicy?.id}" noSelection="['null':'']"></g:select> 91 64 </td> 92 65 </tr> … … 112 85 <tr class="prop"> 113 86 <td valign="top" class="name"> 114 <label for=" isActive">Is Active:</label>87 <label for="reasoning">Reasoning:</label> 115 88 </td> 116 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:' isActive','errors')}">117 < g:checkBox name="isActive" value="${maintenanceActionInstance?.isActive}" ></g:checkBox>89 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:'reasoning','errors')}"> 90 <input type="text" id="reasoning" name="reasoning" value="${fieldValue(bean:maintenanceActionInstance,field:'reasoning')}"/> 118 91 </td> 119 92 </tr> … … 121 94 <tr class="prop"> 122 95 <td valign="top" class="name"> 123 <label for=" reasoning">Reasoning:</label>96 <label for="isActive">Is Active:</label> 124 97 </td> 125 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:' reasoning','errors')}">126 < input type="text" id="reasoning" name="reasoning" value="${fieldValue(bean:maintenanceActionInstance,field:'reasoning')}"/>98 <td valign="top" class="value ${hasErrors(bean:maintenanceActionInstance,field:'isActive','errors')}"> 99 <g:checkBox name="isActive" value="${maintenanceActionInstance?.isActive}" ></g:checkBox> 127 100 </td> 128 101 </tr> -
trunk/grails-app/views/maintenanceActionDetailed/list.gsp
r178 r269 23 23 <g:sortableColumn property="id" title="Id" /> 24 24 25 <th>Maintenance Policy</th> 26 27 <th>System Section</th> 25 <th>Section</th> 28 26 29 27 <th>Asset</th> 30 28 31 <th>Asset Type</th>29 <th>Asset Sub Item</th> 32 30 33 <th> Assembly</th>31 <th>Maintenance Policy</th> 34 32 33 <g:sortableColumn property="procedureStepNumber" title="Procedure Step Number" /> 34 35 35 </tr> 36 36 </thead> … … 41 41 <td><g:link action="show" id="${maintenanceActionInstance.id}">${fieldValue(bean:maintenanceActionInstance, field:'id')}</g:link></td> 42 42 43 <td>${fieldValue(bean:maintenanceActionInstance, field:'maintenancePolicy')}</td> 44 45 <td>${fieldValue(bean:maintenanceActionInstance, field:'systemSection')}</td> 43 <td>${fieldValue(bean:maintenanceActionInstance, field:'section')}</td> 46 44 47 45 <td>${fieldValue(bean:maintenanceActionInstance, field:'asset')}</td> 48 46 49 <td>${fieldValue(bean:maintenanceActionInstance, field:'asset Type')}</td>47 <td>${fieldValue(bean:maintenanceActionInstance, field:'assetSubItem')}</td> 50 48 51 <td>${fieldValue(bean:maintenanceActionInstance, field:'assembly')}</td> 49 <td>${fieldValue(bean:maintenanceActionInstance, field:'maintenancePolicy')}</td> 50 51 <td>${fieldValue(bean:maintenanceActionInstance, field:'procedureStepNumber')}</td> 52 52 53 53 </tr> -
trunk/grails-app/views/maintenanceActionDetailed/show.gsp
r178 r269 30 30 31 31 <tr class="prop"> 32 <td valign="top" class="name"> Maintenance Policy:</td>32 <td valign="top" class="name">Section:</td> 33 33 34 <td valign="top" class="value"><g:link controller="maintenancePolicyDetailed" action="show" id="${maintenanceActionInstance?.maintenancePolicy?.id}">${maintenanceActionInstance?.maintenancePolicy?.encodeAsHTML()}</g:link></td> 35 36 </tr> 37 38 <tr class="prop"> 39 <td valign="top" class="name">System Section:</td> 40 41 <td valign="top" class="value"><g:link controller="systemSectionDetailed" action="show" id="${maintenanceActionInstance?.systemSection?.id}">${maintenanceActionInstance?.systemSection?.encodeAsHTML()}</g:link></td> 34 <td valign="top" class="value"><g:link controller="section" action="show" id="${maintenanceActionInstance?.section?.id}">${maintenanceActionInstance?.section?.encodeAsHTML()}</g:link></td> 42 35 43 36 </tr> … … 46 39 <td valign="top" class="name">Asset:</td> 47 40 48 <td valign="top" class="value"><g:link controller="asset Detailed" action="show" id="${maintenanceActionInstance?.asset?.id}">${maintenanceActionInstance?.asset?.encodeAsHTML()}</g:link></td>41 <td valign="top" class="value"><g:link controller="asset" action="show" id="${maintenanceActionInstance?.asset?.id}">${maintenanceActionInstance?.asset?.encodeAsHTML()}</g:link></td> 49 42 50 43 </tr> 51 44 52 45 <tr class="prop"> 53 <td valign="top" class="name">Asset Type:</td>46 <td valign="top" class="name">Asset Sub Item:</td> 54 47 55 <td valign="top" class="value"><g:link controller="asset TypeDetailed" action="show" id="${maintenanceActionInstance?.assetType?.id}">${maintenanceActionInstance?.assetType?.encodeAsHTML()}</g:link></td>48 <td valign="top" class="value"><g:link controller="assetSubItem" action="show" id="${maintenanceActionInstance?.assetSubItem?.id}">${maintenanceActionInstance?.assetSubItem?.encodeAsHTML()}</g:link></td> 56 49 57 50 </tr> 58 51 59 52 <tr class="prop"> 60 <td valign="top" class="name"> Assembly:</td>53 <td valign="top" class="name">Maintenance Policy:</td> 61 54 62 <td valign="top" class="value"><g:link controller="assemblyDetailed" action="show" id="${maintenanceActionInstance?.assembly?.id}">${maintenanceActionInstance?.assembly?.encodeAsHTML()}</g:link></td> 63 64 </tr> 65 66 <tr class="prop"> 67 <td valign="top" class="name">Sub Assembly:</td> 68 69 <td valign="top" class="value"><g:link controller="subAssemblyDetailed" action="show" id="${maintenanceActionInstance?.subAssembly?.id}">${maintenanceActionInstance?.subAssembly?.encodeAsHTML()}</g:link></td> 70 71 </tr> 72 73 <tr class="prop"> 74 <td valign="top" class="name">Component Item:</td> 75 76 <td valign="top" class="value"><g:link controller="componentItemDetailed" action="show" id="${maintenanceActionInstance?.componentItem?.id}">${maintenanceActionInstance?.componentItem?.encodeAsHTML()}</g:link></td> 55 <td valign="top" class="value"><g:link controller="maintenancePolicy" action="show" id="${maintenanceActionInstance?.maintenancePolicy?.id}">${maintenanceActionInstance?.maintenancePolicy?.encodeAsHTML()}</g:link></td> 77 56 78 57 </tr> … … 93 72 94 73 <tr class="prop"> 74 <td valign="top" class="name">Reasoning:</td> 75 76 <td valign="top" class="value">${fieldValue(bean:maintenanceActionInstance, field:'reasoning')}</td> 77 78 </tr> 79 80 <tr class="prop"> 95 81 <td valign="top" class="name">Is Active:</td> 96 82 … … 100 86 101 87 <tr class="prop"> 102 <td valign="top" class="name">Reasoning:</td>103 104 <td valign="top" class="value">${fieldValue(bean:maintenanceActionInstance, field:'reasoning')}</td>105 106 </tr>107 108 <tr class="prop">109 88 <td valign="top" class="name">Task Procedure:</td> 110 89 111 <td valign="top" class="value"><g:link controller="taskProcedure Detailed" action="show" id="${maintenanceActionInstance?.taskProcedure?.id}">${maintenanceActionInstance?.taskProcedure?.encodeAsHTML()}</g:link></td>90 <td valign="top" class="value"><g:link controller="taskProcedure" action="show" id="${maintenanceActionInstance?.taskProcedure?.id}">${maintenanceActionInstance?.taskProcedure?.encodeAsHTML()}</g:link></td> 112 91 113 92 </tr>
Note: See TracChangeset
for help on using the changeset viewer.