tzispa 0.5.11 → 0.5.12

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 9e70cadefd940ba6c29f9e922288ae5d6e26f806
4
- data.tar.gz: 9d0803b6898b4f23d8117ee20c5854e13bca99ab
3
+ metadata.gz: 5434cb0372b31a22ac790e800a54f67dbea1036d
4
+ data.tar.gz: 3aea5a8b92fbbbd0a77c7d1a0142c36be0c990a1
5
5
  SHA512:
6
- metadata.gz: 83d6b14372cd570718a36f4a68f7480591923033c91046ece2d3c27742c9686872b69457e9534127385ba3ee0f23690cdcc614578be2dedf63c68bc1c851da17
7
- data.tar.gz: e7ae49e10763e8bdcf4655a15c3ca68dad2651fba71b0e9d96245820a69b75b2cdcb92c9608202d8aea7dd17ea1ae562637f33889e20d1ba3e27a45260dffcee
6
+ metadata.gz: 88f7fd5fde4718878066c129b0ab2859627e97aad65730caefb2b583cfdc09b704d42c1248b026baefd686ccf5e7c67440cf099f3a9d45102c12678860fdabcc
7
+ data.tar.gz: 2c4da7af4b0045fad1c5c2183f6f2cbb8b58630f18d7e130b30cb502a4f9d560d842f524d35aa2257587129998cae5362334ad9a4925b9b0d61fb21e15250b2f
data/CHANGELOG.md CHANGED
@@ -2,6 +2,10 @@ Tzispa
2
2
 
3
3
  General purpose web framework
4
4
 
5
+ ## v0.5.12
6
+ - minor bug fixes
7
+ - added new class run method to improve DSL usage
8
+
5
9
  ## v0.5.11
6
10
  - moved app config files location
7
11
  - moved app locales base dir
@@ -47,8 +47,8 @@ module Tzispa
47
47
  @error = error
48
48
  end
49
49
 
50
- def result_json(data, status: nil)
51
- result response_verb: :json, data: data.to_json, status: status
50
+ def result_json(data, status: nil, error: nil)
51
+ result response_verb: :json, data: data, status: status, error: error
52
52
  end
53
53
 
54
54
  def result_download(data, status: nil)
data/lib/tzispa/app.rb CHANGED
@@ -53,6 +53,11 @@ module Tzispa
53
53
  end
54
54
  end
55
55
 
56
+ def run(domain_name, builder: nil, on: nil, &block)
57
+ theapp = self.new domain_name, on: on, &block
58
+ theapp.run builder
59
+ end
60
+
56
61
  end
57
62
 
58
63
  def initialize(domain_name, on: nil, &block)
data/lib/tzispa/routes.rb CHANGED
@@ -59,7 +59,7 @@ module Tzispa
59
59
  end
60
60
 
61
61
  def route_rig_layout(layout, path, controller: nil, methods: nil)
62
- routing layout.to_sym, path, controller || 'layout:render!', methods: methods, matching: {layout: layout.to_s}
62
+ routing layout, path, controller || 'layout:render!', methods: methods, matching: {layout: layout.to_s}
63
63
  end
64
64
 
65
65
  end
@@ -1,7 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Tzispa
4
- VERSION = '0.5.11'
4
+ VERSION = '0.5.12'
5
5
  FRAMEWORK_NAME = 'Tzispa'
6
6
  GEM_NAME = 'tzispa'
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tzispa
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.11
4
+ version: 0.5.12
5
5
  platform: ruby
6
6
  authors:
7
7
  - Juan Antonio Piñero
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-10-31 00:00:00.000000000 Z
11
+ date: 2016-11-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rack