Changeset 123 for trunk/grails-app


Ignore:
Timestamp:
May 4, 2009, 5:12:01 AM (15 years ago)
Author:
gav
Message:

Install Quartz plugin and make a start on TaskRecurringScheduleJob?

Location:
trunk/grails-app
Files:
2 added
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/grails-app/domain/RecurringSchedule.groovy

    r122 r123  
    77    Integer recurEvery
    88    Date startDate = new Date()
     9    Date lastExecutedDate
     10    Date nextDueDate
    911    boolean isActive = true
    1012
     
    1517    static constraints = {
    1618        plannedMaintenance(blank:true, nullable:true)
     19        lastExecutedDate(blank:true, nullable:true)
     20        nextDueDate(blank:true, nullable:true)
    1721    }
    1822
  • trunk/grails-app/domain/Task.groovy

    r122 r123  
    4040    }
    4141
    42     String toString() {"${this.description}"}
     42    String toString() {"${this.id} - ${this.description}"}
    4343}
  • trunk/grails-app/views/recurringSchedule/create.gsp

    r122 r123  
    3333                                <td valign="top" class="value ${hasErrors(bean:recurringScheduleInstance,field:'plannedMaintenance','errors')}">
    3434                                    <g:select optionKey="id" from="${PlannedMaintenance.list()}" name="plannedMaintenance.id" value="${recurringScheduleInstance?.plannedMaintenance?.id}" noSelection="['null':'']"></g:select>
     35                                </td>
     36                            </tr>
     37                       
     38                            <tr class="prop">
     39                                <td valign="top" class="name">
     40                                    <label for="lastExecutedDate">Last Executed Date:</label>
     41                                </td>
     42                                <td valign="top" class="value ${hasErrors(bean:recurringScheduleInstance,field:'lastExecutedDate','errors')}">
     43                                    <g:datePicker name="lastExecutedDate" value="${recurringScheduleInstance?.lastExecutedDate}" noSelection="['':'']"></g:datePicker>
     44                                </td>
     45                            </tr>
     46                       
     47                            <tr class="prop">
     48                                <td valign="top" class="name">
     49                                    <label for="nextDueDate">Next Due Date:</label>
     50                                </td>
     51                                <td valign="top" class="value ${hasErrors(bean:recurringScheduleInstance,field:'nextDueDate','errors')}">
     52                                    <g:datePicker name="nextDueDate" value="${recurringScheduleInstance?.nextDueDate}" noSelection="['':'']"></g:datePicker>
    3553                                </td>
    3654                            </tr>
  • trunk/grails-app/views/recurringSchedule/edit.gsp

    r122 r123  
    3636                                <td valign="top" class="value ${hasErrors(bean:recurringScheduleInstance,field:'plannedMaintenance','errors')}">
    3737                                    <g:select optionKey="id" from="${PlannedMaintenance.list()}" name="plannedMaintenance.id" value="${recurringScheduleInstance?.plannedMaintenance?.id}" noSelection="['null':'']"></g:select>
     38                                </td>
     39                            </tr>
     40                       
     41                            <tr class="prop">
     42                                <td valign="top" class="name">
     43                                    <label for="lastExecutedDate">Last Executed Date:</label>
     44                                </td>
     45                                <td valign="top" class="value ${hasErrors(bean:recurringScheduleInstance,field:'lastExecutedDate','errors')}">
     46                                    <g:datePicker name="lastExecutedDate" value="${recurringScheduleInstance?.lastExecutedDate}" noSelection="['':'']"></g:datePicker>
     47                                </td>
     48                            </tr>
     49                       
     50                            <tr class="prop">
     51                                <td valign="top" class="name">
     52                                    <label for="nextDueDate">Next Due Date:</label>
     53                                </td>
     54                                <td valign="top" class="value ${hasErrors(bean:recurringScheduleInstance,field:'nextDueDate','errors')}">
     55                                    <g:datePicker name="nextDueDate" value="${recurringScheduleInstance?.nextDueDate}" noSelection="['':'']"></g:datePicker>
    3856                                </td>
    3957                            </tr>
  • trunk/grails-app/views/recurringSchedule/list.gsp

    r122 r123  
    2626                                <th>Planned Maintenance</th>
    2727                           
     28                                <g:sortableColumn property="lastExecutedDate" title="Last Executed Date" />
     29                       
     30                                <g:sortableColumn property="nextDueDate" title="Next Due Date" />
     31                       
    2832                                <g:sortableColumn property="isActive" title="Is Active" />
    2933                       
    3034                                <th>Period</th>
    3135                           
    32                                 <g:sortableColumn property="recurEvery" title="Recur Every" />
    33                        
    34                                 <g:sortableColumn property="startDate" title="Start Date" />
    35                        
    3636                        </tr>
    3737                    </thead>
     
    4444                            <td>${fieldValue(bean:recurringScheduleInstance, field:'plannedMaintenance')}</td>
    4545                       
     46                            <td>${fieldValue(bean:recurringScheduleInstance, field:'lastExecutedDate')}</td>
     47                       
     48                            <td>${fieldValue(bean:recurringScheduleInstance, field:'nextDueDate')}</td>
     49                       
    4650                            <td>${fieldValue(bean:recurringScheduleInstance, field:'isActive')}</td>
    4751                       
    4852                            <td>${fieldValue(bean:recurringScheduleInstance, field:'period')}</td>
    49                        
    50                             <td>${fieldValue(bean:recurringScheduleInstance, field:'recurEvery')}</td>
    51                        
    52                             <td>${fieldValue(bean:recurringScheduleInstance, field:'startDate')}</td>
    5353                       
    5454                        </tr>
  • trunk/grails-app/views/recurringSchedule/show.gsp

    r122 r123  
    3434                           
    3535                            <td valign="top" class="value"><g:link controller="plannedMaintenance" action="show" id="${recurringScheduleInstance?.plannedMaintenance?.id}">${recurringScheduleInstance?.plannedMaintenance?.encodeAsHTML()}</g:link></td>
     36                           
     37                        </tr>
     38                   
     39                        <tr class="prop">
     40                            <td valign="top" class="name">Last Executed Date:</td>
     41                           
     42                            <td valign="top" class="value">${fieldValue(bean:recurringScheduleInstance, field:'lastExecutedDate')}</td>
     43                           
     44                        </tr>
     45                   
     46                        <tr class="prop">
     47                            <td valign="top" class="name">Next Due Date:</td>
     48                           
     49                            <td valign="top" class="value">${fieldValue(bean:recurringScheduleInstance, field:'nextDueDate')}</td>
    3650                           
    3751                        </tr>
Note: See TracChangeset for help on using the changeset viewer.