homeland-site 0.2.0 → 0.2.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
- SHA1:
3
- metadata.gz: 2769bd3d8d3ddf59d835619916064544950a86a3
4
- data.tar.gz: f542ebcf6c97c115be5b99ea7e64cc438ca928c4
2
+ SHA256:
3
+ metadata.gz: 8d1b94bb5556d9af3cc47d69d51a73730473dc3713c74e1cd0e8c6a5a3743632
4
+ data.tar.gz: fe10814918a2471d20f423a30aa5764669c36b454bd2d2d7c5199d7d0e6c09cb
5
5
  SHA512:
6
- metadata.gz: 3d086ad0526d8f45c36858bbd2c034b17d5c17165cc2c2e54a025f8d4f9c767a846d4ea30cfd609fb9eff3fff6dae5f8370c0fceff36153283eb7f526318af0e
7
- data.tar.gz: c959f77c7241d0892fbb4038e6fddf27a26803704bf70dcd81c6325a4d87341e9ebdeb5c06e3555f50f023ae139b8f4c5424f7a3ca2d3fbc0c63800b54a1dba6
6
+ metadata.gz: d880752a1d77960818fff5290007a9070352a9091dad078a89abe846d92806435d1bb5178e23f5eead04a6ff56b8ca31b9b459d7340aa8f4a50ac4311a967c00
7
+ data.tar.gz: 8ffec9aa3b4fa0a9ff78384be5f9713b95491ba2fb1bf6fa0d8106ece9e44db6512d62294d848ccd495a31018a42481ef86395a2428009025e074b900428ebf0
@@ -8,6 +8,8 @@ class SiteNode < ApplicationRecord
8
8
  after_save :update_cache_version
9
9
  after_destroy :update_cache_version
10
10
 
11
+ form_select :name
12
+
11
13
  def update_cache_version
12
14
  # 记录节点变更时间,用于清除缓存
13
15
  CacheVersion.sites_updated_at = Time.now.to_i
@@ -13,7 +13,7 @@
13
13
 
14
14
  <div class="form-group">
15
15
  <%= f.label :url %>
16
- <%= f.select :site_node_id, SiteNode.all.collect { |t| [t.name, t.id] }, { include_blank: false }, { class: "form-control" } %>
16
+ <%= f.select :site_node_id, SiteNode.name_options, { include_blank: false }, { class: "form-control" } %>
17
17
  </div>
18
18
 
19
19
  <div class="form-group">
@@ -6,7 +6,7 @@
6
6
 
7
7
  <div class="form-group">
8
8
  <%= f.label :site_node_id %>
9
- <%= f.select :site_node_id, SiteNode.all.collect { |t| [t.name, t.id] }, { include_blank: false }, class: "form-control" %>
9
+ <%= f.select :site_node_id, SiteNode.name_options, { include_blank: false }, class: "form-control" %>
10
10
  </div>
11
11
 
12
12
  <div class="form-group">
@@ -1,6 +1,6 @@
1
1
  module Homeland
2
2
  module Site
3
- VERSION = '0.2.0'
3
+ VERSION = '0.2.1'
4
4
  NAME = 'site'
5
5
  DESCRIPTION = 'Site for Homeland.'
6
6
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: homeland-site
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jason Lee
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-04-18 00:00:00.000000000 Z
11
+ date: 2018-10-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -24,6 +24,20 @@ dependencies:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
26
  version: '5'
27
+ - !ruby/object:Gem::Dependency
28
+ name: form-select
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: 0.2.0
34
+ type: :runtime
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ">="
39
+ - !ruby/object:Gem::Version
40
+ version: 0.2.0
27
41
  description: Site for Homeland.
28
42
  email:
29
43
  - huacnlee@gmail.com
@@ -85,7 +99,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
85
99
  version: '0'
86
100
  requirements: []
87
101
  rubyforge_project:
88
- rubygems_version: 2.5.2
102
+ rubygems_version: 2.7.6
89
103
  signing_key:
90
104
  specification_version: 4
91
105
  summary: Site plugin for Homeland