ajax_error_renderer 0.1.0 → 0.1.1

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
  SHA256:
3
- metadata.gz: 958d956880a60a471ed3beca4298c61b36c2ff18dd214df644e7903ad0021508
4
- data.tar.gz: e800de870af5c1236d08df7fd03a4e54d8d3989faebd605d5148896c0598bfc7
3
+ metadata.gz: 74c3bea151360e5fd94ff5b4e4cf666dea499628e5a3985af94ad53ac0515aeb
4
+ data.tar.gz: 2e4b67917e6e7005117c405fc082f8590c2eb3f70bf1a6bd8c071ac185f0f32e
5
5
  SHA512:
6
- metadata.gz: 0e9d4ec34b94ee4696e22f7d217b9f3a2b8958a192155784bda7ee6ae4890e9542b71f0a8c8bfcd94085ff023b7bbd5f97a72250526e2266c2cb95a11c61299a
7
- data.tar.gz: b0b7e3ba2393a731fa7fa0f45a8ee087b36b566a18434eb856b69b999dab046afaefc0d6e763922dfd35b130f5b113c1b4a01bca1a011d3cde1d5cd96b64b8dd
6
+ metadata.gz: 4b5b4e06d20d9544870e894233ca4c1b4e2776f7f14b6cb330b49c209ec42586fbf5cbe8fdf6fa8e9745864a192182d7364571cfb60190b885bc00dce7aff679
7
+ data.tar.gz: de11bdf7531d75639ab2ef7e126984727cf5788a2631f445b99780d3f539a1aff1407a71521847afe38ebf13b0bf013efb0439b0dcfbcc9e5b2ea059f8f9ca8a
data/README.md CHANGED
@@ -1,5 +1,7 @@
1
1
  # AjaxErrorRenderer
2
2
 
3
+ [![Gem Version](https://badge.fury.io/rb/ajax_error_renderer.svg)](https://badge.fury.io/rb/ajax_error_renderer)
4
+
3
5
  [![CircleCI](https://circleci.com/gh/willnet/ajax_error_renderer/tree/master.svg?style=svg)](https://circleci.com/gh/willnet/ajax_error_renderer/tree/master)
4
6
 
5
7
  AjaxErrorRenderer is a validation error renderer for ajax request.
@@ -1,9 +1,9 @@
1
1
  require "ajax_error_renderer/engine"
2
2
 
3
3
  module AjaxErrorRenderer
4
- def render_ajax_error(location: '#error', model:)
4
+ def render_ajax_error(location: '#error', model:, status: 422)
5
5
  @location = location
6
6
  @model = model
7
- render 'ajax_errors/error', formats: :js
7
+ render 'ajax_errors/error', formats: :js, status: status
8
8
  end
9
9
  end
@@ -1,3 +1,3 @@
1
1
  module AjaxErrorRenderer
2
- VERSION = '0.1.0'
2
+ VERSION = '0.1.1'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ajax_error_renderer
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - willnet
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-11-29 00:00:00.000000000 Z
11
+ date: 2018-11-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails