<%-# Fedena
#Copyright 2010 Foradian Technologies Private Limited
#
#This product includes software developed at
#Project Fedena - http://www.projectfedena.org/
#
#Licensed under the Apache License, Version 2.0 (the "License");
#you may not use this file except in compliance with the License.
#You may obtain a copy of the License at
#
#  http://www.apache.org/licenses/LICENSE-2.0
#
#Unless required by applicable law or agreed to in writing,
#software distributed under the License is distributed on an
#"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
#KIND, either express or implied.  See the License for the
#specific language governing permissions and limitations
#under the License. -%>

<div id="page-yield">
  <div class="box">
    <% form_remote_for @weightage,:url=>{:controller=>"cce_weightages",:id=>@weightage.id,:action=>'update'} do |f| %>
      <div id="form-errors"></div>
      <%= error_messages_for :weightage %>
      <div class="label-field-pair">
        <label for="category_name">Weightage</label>
        <div class="text-input-bg"><%= f.text_field :weightage %></div>
      </div>
      <div class="label-field-pair">
        <label for="category_name">Type</label>
        <div class="text-input-bg">
          <%= f.select :criteria_type,@criteria  %>
        </div>
      </div>
      <div class="label-field-pair">
        <label for="category_name">Exam Category</label>
        <div class="text-input-bg">
          <%= f.select :cce_exam_category_id ,@exam_categories.map{|m| [m.name,m.id]} ,:prompt=>"Select a category" %>
        </div>
      </div>
      <%= f.submit "", :value => "► Update", :class => "submit_button" %>
    <% end %>
    <div class="extender"></div>
  </div>
</div>