Index: trunk/grails-app/views/taskDetailed/createUnscheduled.gsp
===================================================================
--- trunk/grails-app/views/taskDetailed/createUnscheduled.gsp	(revision 433)
+++ trunk/grails-app/views/taskDetailed/createUnscheduled.gsp	(revision 487)
@@ -71,5 +71,9 @@
                                 </td>
                                 <td valign="top" class="value ${hasErrors(bean:taskInstance,field:'leadPerson','errors')}">
-                                    <g:select optionKey="id" from="${Person.list()}" name="leadPerson.id" value="${taskInstance?.leadPerson?.id}" ></g:select>
+                                    <g:select optionKey="id"
+                                                        from="${Person.findAllByIsActive(true).sort { p1, p2 -> p1.firstName.compareToIgnoreCase(p2.firstName) }}"
+                                                        name="leadPerson.id"
+                                                        value="${taskInstance?.leadPerson?.id}" >
+                                    </g:select>
                                     <g:helpBalloon code="task.leadPerson" />
                                 </td>
@@ -81,21 +85,12 @@
                                 </td>
                                 <td valign="top" class="value ${hasErrors(bean:taskInstance,field:'primaryAsset','errors')}">
-                                    <g:select optionKey="id" from="${Asset.list()}" name="primaryAsset.id" value="${taskInstance?.primaryAsset?.id}" noSelection="['null':'--None--']"></g:select>
+                                    <g:select optionKey="id"
+                                                        from="${Asset.findAllByIsActive(true).sort { p1, p2 -> p1.name.compareToIgnoreCase(p2.name) }}"
+                                                        name="primaryAsset.id"
+                                                        value="${taskInstance?.primaryAsset?.id}"
+                                                        noSelection="['null':'--None--']"></g:select>
                                     <g:helpBalloon code="task.primaryAsset" />
                                 </td>
                             </tr>
-
-<!--                            <tr class="prop">
-                                <td valign="top" class="name">
-                                    <label for="associatedAssets">Associated Assets:</label>
-                                </td>
-                                <td valign="top" class="value ${hasErrors(bean:taskInstance,field:'associatedAssets','errors')}">
-                                    <g:select id="associatedAssets" name="associatedAssets"
-                                                    from="${Asset.list()}"
-                                                    size="5" multiple="yes" optionKey="id"
-                                                    value="${taskInstance?.associatedAssets?.id}"  noSelection="['':'--None--']"/>
-                                    <g:helpBalloon code="task.associatedAssets" />
-                                </td>
-                            </tr>-->
                         
                             <tr class="prop">
@@ -104,25 +99,11 @@
                                 </td>
                                 <td valign="top" class="value ${hasErrors(bean:taskInstance,field:'taskPriority','errors')}">
-                                    <g:select optionKey="id" from="${unscheduledTaskPriorities}" name="taskPriority.id" value="${taskInstance?.taskPriority?.id}" ></g:select>
+                                    <g:select optionKey="id"
+                                                        from="${unscheduledTaskPriorities}"
+                                                        name="taskPriority.id"
+                                                        value="${taskInstance?.taskPriority?.id}" >
+                                    </g:select>
                                 </td>
                             </tr>
-                        
-<!--                            <tr class="prop">
-                                <td valign="top" class="name">
-                                    <label for="scheduled">Scheduled:</label>
-                                </td>
-                                <td valign="top" class="value ${hasErrors(bean:taskInstance,field:'scheduled','errors')}">
-                                    <g:checkBox name="scheduled" value="${taskInstance?.scheduled}" ></g:checkBox>
-                                </td>
-                            </tr>-->
-
-<!--                            <tr class="prop">
-                                <td valign="top" class="name">
-                                    <label for="parentTask">Parent Task:</label>
-                                </td>
-                                <td valign="top" class="value ${hasErrors(bean:taskInstance,field:'parentTask','errors')}">
-                                    <g:select optionKey="id" from="${Task.findAllByTrash(false)}" name="parentTask.id" value="${taskInstance?.parentTask?.id}" noSelection="['null':'--None--']"></g:select>
-                                </td>
-                            </tr> -->
                         
                             <tr class="prop">
@@ -131,5 +112,9 @@
                                 </td>
                                 <td valign="top" class="value ${hasErrors(bean:taskInstance,field:'taskGroup','errors')}">
-                                    <g:select optionKey="id" from="${TaskGroup.list()}" name="taskGroup.id" value="${taskInstance?.taskGroup?.id}" ></g:select>
+                                    <g:select optionKey="id"
+                                                        from="${TaskGroup.findAllByIsActive(true).sort { p1, p2 -> p1.name.compareToIgnoreCase(p2.name) }}"
+                                                        name="taskGroup.id"
+                                                        value="${taskInstance?.taskGroup?.id}" >
+                                    </g:select>
                                 </td>
                             </tr> 
