freelancer4r 1.0.5 → 1.0.6

Sign up to get free protection for your applications and to get access to all the features.
data/CHANGELOG CHANGED
@@ -1,3 +1,6 @@
1
+ == Freelancer4r 1.0.6 (2010.07.23)
2
+ * Api changes (new Project budget option added, see Freelancer::Employer class)
3
+
1
4
  == Freelancer4r 1.0.5 (2010.07.21)
2
5
  * Widget documentation changes
3
6
 
@@ -20,7 +20,7 @@ require 'net/http'
20
20
  #
21
21
  #Load all Freelancer modules
22
22
  module Freelancer
23
- VERSION = "1.0.5"
23
+ VERSION = "1.0.6"
24
24
  #Initialize the Freelancer Wrapper Class
25
25
  #
26
26
  #Parameters
@@ -9,7 +9,15 @@ module Freelancer
9
9
  # :projectname => Project name to post
10
10
  # :projectdesc => Project description
11
11
  # :jobtypecsv => Job category associated with project
12
- # :budget => Budget of the project
12
+ # :budgetoption =>
13
+ # 0 - Customised Budget, only for FEATURED or FULLTIME project
14
+ # 1 - $250-750
15
+ # 2 - $750-1500
16
+ # 3 - $1500-3000
17
+ # 4 - $3000-5000
18
+ # 5 - $30-$250
19
+ # 6 - >$5000
20
+ # :budget => Budget of the project, Required if using customised budget.
13
21
  # :duration => Period of the project
14
22
  #
15
23
  #<b>Optional:</b> (available on :normal and :draft)
@@ -22,6 +30,7 @@ module Freelancer
22
30
  :projectname,
23
31
  :projectdesc,
24
32
  :jobtypecsv,
33
+ :budgetoption,
25
34
  :budget,
26
35
  :duration,
27
36
  :isfeatured,
@@ -32,10 +41,13 @@ module Freelancer
32
41
  :projectname,
33
42
  :projectdesc,
34
43
  :jobtypecsv,
35
- :budget,
44
+ :budgetoption,
36
45
  :duration
37
46
  ],*args
38
47
  type=options.delete(:projectType)
48
+ if options[:budgetoption]==0 && options[:budget]==nil
49
+ raise "Custom budget option, budget parameter required"
50
+ end
39
51
  case type
40
52
  when :normal
41
53
  request "/Employer/postNewProject.json",options
@@ -119,7 +131,7 @@ module Freelancer
119
131
  options=fill_args [:projectid,:projectdesc,:jobtypecsv],[:projectid],*args
120
132
  request "/Employer/updateProjectDetails.json", options
121
133
  end
122
-
134
+
123
135
  #Retrieve the eligibility for current user to post a trial project.
124
136
  #
125
137
  #http://developer.freelancer.com/EligibleForTrialProject
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: freelancer4r
3
3
  version: !ruby/object:Gem::Version
4
- hash: 29
4
+ hash: 27
5
5
  prerelease: false
6
6
  segments:
7
7
  - 1
8
8
  - 0
9
- - 5
10
- version: 1.0.5
9
+ - 6
10
+ version: 1.0.6
11
11
  platform: ruby
12
12
  authors:
13
13
  - Janos Haber
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2010-07-21 00:00:00 +02:00
18
+ date: 2010-07-23 00:00:00 +02:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency