Ignore:
Timestamp:
07/05/10 12:56:53 (23 months ago)
Author:
dart
Message:

LoReality?:
o Add squadrons, pilots.
o Lot of fix
o Some cosmetics

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/loreality/loreality/templates/component/campaign.html

    r2100 r2104  
    2323</%def> 
    2424 
    25 <%def name="add_pilot(mission_id)"> 
     25<%def name="add_pilot(mission_id, available_pilots)"> 
    2626% if h.auth.authorized(h.auth.is_creator): 
    2727    ${h.form(h.url_for(controller='mission', action='addpilot', id=mission_id))} 
    2828    <fieldset><legend>Add a new pilot</legend> 
    2929 
    30         <label for="name_${name}">Name</label><br /> 
    31     ${h.text(name='name_pilot')} 
    32     ${h.submit(name="action", value='process')} 
     30    ${h.select( 
     31        "Pilot", 
     32        id='pilotid', 
     33        selected_values=[], 
     34        options=available_pilots, 
     35    )} 
     36    ${h.submit(name="action", value='Add')} 
    3337    </fieldset> 
    3438    ${h.end_form()} 
    3539%endif 
    3640</%def> 
     41<%def name="add_pilot_to_squadron(squadron_id, available_pilots)"> 
     42% if h.auth.authorized(h.auth.is_creator): 
     43    ${h.form(h.url_for(controller='squadron', action='addpilot', id=squadron_id))} 
     44    <fieldset><legend>Add a new pilot</legend> 
     45 
     46    ${h.select( 
     47        "Pilot", 
     48        id='pilotid', 
     49        selected_values=[], 
     50        options=available_pilots, 
     51    )} 
     52    ${h.submit(name="action", value='Add')} 
     53    </fieldset> 
     54    ${h.end_form()} 
     55%endif 
     56</%def> 
Note: See TracChangeset for help on using the changeset viewer.