bookyt_salary 0.13.3 → 0.14.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,7 +1,7 @@
1
1
  class SalaryBookingTemplate < BookingTemplate
2
2
  # Obligation flags
3
3
  def self.saldo_inclusion_flags
4
- ['gross_income', 'ahv', 'uvg', 'uvgz', 'ktg', 'deduction_at_source']
4
+ ['gross_income', 'net_income', 'ahv', 'uvg', 'uvgz', 'ktg', 'deduction_at_source']
5
5
  end
6
6
 
7
7
  def to_s
@@ -3,7 +3,7 @@ class SalaryTemplate < ActiveRecord::Base
3
3
 
4
4
  # Salary Items
5
5
  has_many :salary_items
6
- accepts_nested_attributes_for :salary_items, :allow_destroy => true
6
+ accepts_nested_attributes_for :salary_items, :allow_destroy => true, :reject_if => :all_blank
7
7
 
8
8
  def to_s
9
9
  title
@@ -1,6 +1,6 @@
1
1
  %tr.salary_item.nested-form-item
2
2
  %td= salary_item.text_field :position, :required => true, :style => 'width: 3em', :autocomplete => "off"
3
- %td= salary_item.select :salary_booking_template_id, SalaryBookingTemplate.all.map{|template| [template.title, template.id]}, :include_blank => true, :required => true, :style => 'width: 30em'
3
+ %td= salary_item.select :salary_booking_template_id, SalaryBookingTemplate.all.map{|template| [template.title, template.id]}, {:include_blank => true, :required => true}, :class => 'combobox'
4
4
  %td= salary_item.text_field :times, :required => true, :style => 'width: 3em', :autocomplete => "off"
5
5
  %td= salary_item.text_field :price, :required => true, :style => 'width: 5em', :autocomplete => "off"
6
6
  %td.action_links
@@ -2,6 +2,6 @@
2
2
  %table#salary_items
3
3
  %thead
4
4
  = render 'salary_items/list_header', :template => f.object
5
- %tbody
5
+ %tbody.sortable
6
6
  = f.fields_for :salary_items do |salary_item|
7
7
  = render 'salary_items/form', :salary_item => salary_item, :template => f.object
@@ -3,5 +3,4 @@
3
3
  %th{:style => 'padding: 2px'}= t_attr(:salary_booking_template, SalaryItem)
4
4
  %th{:style => 'padding: 2px; width: 3em'}= t_attr(:times, SalaryItem)
5
5
  %th{:style => 'padding: 2px; width: 3em'}= t_attr(:price, SalaryItem)
6
- %th
7
6
  %th.action_links= link_to t_action(:more), [:new_salary_item, template.persisted? ? template : template.class.name.underscore.pluralize.to_sym], :remote => true, :class => 'icon-add-text'
@@ -3,7 +3,7 @@
3
3
  = f.inputs do
4
4
  .row
5
5
  .span8= f.input :title, :input_html => {"data-autofocus" => true}
6
- .span8= f.input :person, :collection => Employee.all
6
+ .span8= f.input :person, :as => :combobox, :collection => Employee.all
7
7
  .row
8
8
  .span16= f.input :remarks, :input_html => {:rows => 2, :class => 'span12'}
9
9
 
@@ -1,3 +1,3 @@
1
1
  module BookytSalary
2
- VERSION = '0.13.3'
2
+ VERSION = '0.14.0'
3
3
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bookyt_salary
3
3
  version: !ruby/object:Gem::Version
4
- hash: 45
4
+ hash: 39
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
- - 13
9
- - 3
10
- version: 0.13.3
8
+ - 14
9
+ - 0
10
+ version: 0.14.0
11
11
  platform: ruby
12
12
  authors:
13
13
  - "Simon H\xC3\xBCrlimann (CyT)"
@@ -180,7 +180,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
180
180
  requirements: []
181
181
 
182
182
  rubyforge_project:
183
- rubygems_version: 1.8.15
183
+ rubygems_version: 1.8.10
184
184
  signing_key:
185
185
  specification_version: 3
186
186
  summary: Salary plugin for bookyt