Commit cc2bcf2c by mingyuan

fix notifcat faild

parent 7e5b562c
...@@ -2,14 +2,15 @@ source 'https://rubygems.org' ...@@ -2,14 +2,15 @@ source 'https://rubygems.org'
git_source(:github) { |repo| "https://github.com/#{repo}.git" } git_source(:github) { |repo| "https://github.com/#{repo}.git" }
gemspec gemspec
gem 'rails', '7.0.0.alpha.2'
gem 'pg' gem 'pg'
gem 'puma' gem 'puma'
gem 'sidekiq' gem 'sidekiq'
gem 'viter', github: 'qinmingyuan/viter' gem 'rails_com', github: 'work-design/rails_com'
gem 'rails_vite', github: 'work-design/rails_vite'
gem 'rails_design', github: 'work-design/rails_design' gem 'rails_design', github: 'work-design/rails_design'
gem 'rails_extend', github: 'work-design/rails_extend' gem 'rails_extend', github: 'work-design/rails_extend'
gem 'rails_com', github: 'work-design/rails_com'
gem 'amazing_print' gem 'amazing_print'
......
GIT GIT
remote: https://github.com/qinmingyuan/viter.git
revision: 82d46c2eed89cc27b89811e3ded0cb6797f3b807
specs:
viter (0.1)
rails
GIT
remote: https://github.com/work-design/rails_com.git remote: https://github.com/work-design/rails_com.git
revision: 2377ede7104b675247bf7b26bc279591d54d0a21 revision: 2377ede7104b675247bf7b26bc279591d54d0a21
specs: specs:
...@@ -31,11 +24,18 @@ GIT ...@@ -31,11 +24,18 @@ GIT
GIT GIT
remote: https://github.com/work-design/rails_extend.git remote: https://github.com/work-design/rails_extend.git
revision: c51aad1277fff57c53409a2c4c6c4e90461463d5 revision: 55221ffc89fed5836a60bdc037bfa727ef3fd048
specs: specs:
rails_extend (1.0.0) rails_extend (1.0.0)
rails (>= 5.0) rails (>= 5.0)
GIT
remote: https://github.com/work-design/rails_vite.git
revision: ef130e9069c8f980bcc749dfbdeb026c632d4b8a
specs:
rails_vite (0.0.1)
rails
PATH PATH
remote: . remote: .
specs: specs:
...@@ -49,65 +49,64 @@ GEM ...@@ -49,65 +49,64 @@ GEM
specs: specs:
acme-client (2.0.9) acme-client (2.0.9)
faraday (>= 0.17, < 2.0.0) faraday (>= 0.17, < 2.0.0)
actioncable (6.1.4.1) actioncable (7.0.0.alpha2)
actionpack (= 6.1.4.1) actionpack (= 7.0.0.alpha2)
activesupport (= 6.1.4.1) activesupport (= 7.0.0.alpha2)
nio4r (~> 2.0) nio4r (~> 2.0)
websocket-driver (>= 0.6.1) websocket-driver (>= 0.6.1)
actionmailbox (6.1.4.1) actionmailbox (7.0.0.alpha2)
actionpack (= 6.1.4.1) actionpack (= 7.0.0.alpha2)
activejob (= 6.1.4.1) activejob (= 7.0.0.alpha2)
activerecord (= 6.1.4.1) activerecord (= 7.0.0.alpha2)
activestorage (= 6.1.4.1) activestorage (= 7.0.0.alpha2)
activesupport (= 6.1.4.1) activesupport (= 7.0.0.alpha2)
mail (>= 2.7.1) mail (>= 2.7.1)
actionmailer (6.1.4.1) actionmailer (7.0.0.alpha2)
actionpack (= 6.1.4.1) actionpack (= 7.0.0.alpha2)
actionview (= 6.1.4.1) actionview (= 7.0.0.alpha2)
activejob (= 6.1.4.1) activejob (= 7.0.0.alpha2)
activesupport (= 6.1.4.1) activesupport (= 7.0.0.alpha2)
mail (~> 2.5, >= 2.5.4) mail (~> 2.5, >= 2.5.4)
rails-dom-testing (~> 2.0) rails-dom-testing (~> 2.0)
actionpack (6.1.4.1) actionpack (7.0.0.alpha2)
actionview (= 6.1.4.1) actionview (= 7.0.0.alpha2)
activesupport (= 6.1.4.1) activesupport (= 7.0.0.alpha2)
rack (~> 2.0, >= 2.0.9) rack (~> 2.0, >= 2.2.0)
rack-test (>= 0.6.3) rack-test (>= 0.6.3)
rails-dom-testing (~> 2.0) rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.2.0) rails-html-sanitizer (~> 1.0, >= 1.2.0)
actiontext (6.1.4.1) actiontext (7.0.0.alpha2)
actionpack (= 6.1.4.1) actionpack (= 7.0.0.alpha2)
activerecord (= 6.1.4.1) activerecord (= 7.0.0.alpha2)
activestorage (= 6.1.4.1) activestorage (= 7.0.0.alpha2)
activesupport (= 6.1.4.1) activesupport (= 7.0.0.alpha2)
nokogiri (>= 1.8.5) nokogiri (>= 1.8.5)
actionview (6.1.4.1) actionview (7.0.0.alpha2)
activesupport (= 6.1.4.1) activesupport (= 7.0.0.alpha2)
builder (~> 3.1) builder (~> 3.1)
erubi (~> 1.4) erubi (~> 1.4)
rails-dom-testing (~> 2.0) rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.1, >= 1.2.0) rails-html-sanitizer (~> 1.1, >= 1.2.0)
activejob (6.1.4.1) activejob (7.0.0.alpha2)
activesupport (= 6.1.4.1) activesupport (= 7.0.0.alpha2)
globalid (>= 0.3.6) globalid (>= 0.3.6)
activemodel (6.1.4.1) activemodel (7.0.0.alpha2)
activesupport (= 6.1.4.1) activesupport (= 7.0.0.alpha2)
activerecord (6.1.4.1) activerecord (7.0.0.alpha2)
activemodel (= 6.1.4.1) activemodel (= 7.0.0.alpha2)
activesupport (= 6.1.4.1) activesupport (= 7.0.0.alpha2)
activestorage (6.1.4.1) activestorage (7.0.0.alpha2)
actionpack (= 6.1.4.1) actionpack (= 7.0.0.alpha2)
activejob (= 6.1.4.1) activejob (= 7.0.0.alpha2)
activerecord (= 6.1.4.1) activerecord (= 7.0.0.alpha2)
activesupport (= 6.1.4.1) activesupport (= 7.0.0.alpha2)
marcel (~> 1.0.0) marcel (~> 1.0.0)
mini_mime (>= 1.1.0) mini_mime (>= 1.1.0)
activesupport (6.1.4.1) activesupport (7.0.0.alpha2)
concurrent-ruby (~> 1.0, >= 1.0.2) concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 1.6, < 2) i18n (>= 1.6, < 2)
minitest (>= 5.1) minitest (>= 5.1)
tzinfo (~> 2.0) tzinfo (~> 2.0)
zeitwerk (~> 2.3)
acts_as_list (1.0.4) acts_as_list (1.0.4)
activerecord (>= 4.2) activerecord (>= 4.2)
amazing_print (1.3.0) amazing_print (1.3.0)
...@@ -118,7 +117,7 @@ GEM ...@@ -118,7 +117,7 @@ GEM
concurrent-ruby (1.1.9) concurrent-ruby (1.1.9)
connection_pool (2.2.5) connection_pool (2.2.5)
crass (1.0.6) crass (1.0.6)
debug (1.0.0) debug (1.1.0)
irb irb
reline (>= 0.2.7) reline (>= 0.2.7)
default_where (2.3.0) default_where (2.3.0)
...@@ -174,7 +173,7 @@ GEM ...@@ -174,7 +173,7 @@ GEM
nokogiri (>= 1.5.9) nokogiri (>= 1.5.9)
mail (2.7.1) mail (2.7.1)
mini_mime (>= 0.1.1) mini_mime (>= 0.1.1)
marcel (1.0.1) marcel (1.0.2)
method_source (1.0.0) method_source (1.0.0)
mini_mime (1.1.1) mini_mime (1.1.1)
mini_portile2 (2.6.1) mini_portile2 (2.6.1)
...@@ -186,39 +185,44 @@ GEM ...@@ -186,39 +185,44 @@ GEM
nokogiri (1.12.4) nokogiri (1.12.4)
mini_portile2 (~> 2.6.1) mini_portile2 (~> 2.6.1)
racc (~> 1.4) racc (~> 1.4)
nokogiri (1.12.4-x86_64-darwin)
racc (~> 1.4)
nokogiri (1.12.4-x86_64-linux)
racc (~> 1.4)
pg (1.2.3) pg (1.2.3)
puma (5.4.0) puma (5.5.0)
nio4r (~> 2.0) nio4r (~> 2.0)
racc (1.5.2) racc (1.5.2)
rack (2.2.3) rack (2.2.3)
rack-test (1.1.0) rack-test (1.1.0)
rack (>= 1.0, < 3) rack (>= 1.0, < 3)
rails (6.1.4.1) rails (7.0.0.alpha2)
actioncable (= 6.1.4.1) actioncable (= 7.0.0.alpha2)
actionmailbox (= 6.1.4.1) actionmailbox (= 7.0.0.alpha2)
actionmailer (= 6.1.4.1) actionmailer (= 7.0.0.alpha2)
actionpack (= 6.1.4.1) actionpack (= 7.0.0.alpha2)
actiontext (= 6.1.4.1) actiontext (= 7.0.0.alpha2)
actionview (= 6.1.4.1) actionview (= 7.0.0.alpha2)
activejob (= 6.1.4.1) activejob (= 7.0.0.alpha2)
activemodel (= 6.1.4.1) activemodel (= 7.0.0.alpha2)
activerecord (= 6.1.4.1) activerecord (= 7.0.0.alpha2)
activestorage (= 6.1.4.1) activestorage (= 7.0.0.alpha2)
activesupport (= 6.1.4.1) activesupport (= 7.0.0.alpha2)
bundler (>= 1.15.0) bundler (>= 1.15.0)
railties (= 6.1.4.1) railties (= 7.0.0.alpha2)
sprockets-rails (>= 2.0.0) sprockets-rails (>= 2.0.0)
rails-dom-testing (2.0.3) rails-dom-testing (2.0.3)
activesupport (>= 4.2.0) activesupport (>= 4.2.0)
nokogiri (>= 1.6) nokogiri (>= 1.6)
rails-html-sanitizer (1.4.2) rails-html-sanitizer (1.4.2)
loofah (~> 2.3) loofah (~> 2.3)
railties (6.1.4.1) railties (7.0.0.alpha2)
actionpack (= 6.1.4.1) actionpack (= 7.0.0.alpha2)
activesupport (= 6.1.4.1) activesupport (= 7.0.0.alpha2)
method_source method_source
rake (>= 0.13) rake (>= 0.13)
thor (~> 1.0) thor (~> 1.0)
zeitwerk (~> 2.5.0.beta3)
rake (13.0.6) rake (13.0.6)
rdoc (6.3.2) rdoc (6.3.2)
redis (4.4.0) redis (4.4.0)
...@@ -249,7 +253,7 @@ GEM ...@@ -249,7 +253,7 @@ GEM
websocket-extensions (0.1.5) websocket-extensions (0.1.5)
with_advisory_lock (4.6.0) with_advisory_lock (4.6.0)
activerecord (>= 4.2) activerecord (>= 4.2)
zeitwerk (2.4.2) zeitwerk (2.5.0.beta4)
PLATFORMS PLATFORMS
ruby ruby
...@@ -263,13 +267,14 @@ DEPENDENCIES ...@@ -263,13 +267,14 @@ DEPENDENCIES
minitest-hooks minitest-hooks
pg pg
puma puma
rails (= 7.0.0.alpha.2)
rails_com! rails_com!
rails_design! rails_design!
rails_dingtalk! rails_dingtalk!
rails_extend! rails_extend!
rails_vite!
sdoc sdoc
sidekiq sidekiq
viter!
BUNDLED WITH BUNDLED WITH
2.2.22 2.2.22
...@@ -42,8 +42,8 @@ module Dingtalk::Api ...@@ -42,8 +42,8 @@ module Dingtalk::Api
r = post '/message/workNotification', **payload r = post '/message/workNotification', **payload
if r.is_a? Hash if r.is_a?(Hash) && r.dig('success')
r.dig('content', 'data') r.dig('content')
else else
r r
end end
......
...@@ -6,11 +6,11 @@ ENV['NODE_ENV'] ||= ENV['RACK_ENV'] || 'development' ...@@ -6,11 +6,11 @@ ENV['NODE_ENV'] ||= ENV['RACK_ENV'] || 'development'
ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../Gemfile', __dir__) ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../Gemfile', __dir__)
require 'bundler/setup' if File.exist?(ENV['BUNDLE_GEMFILE']) require 'bundler/setup' if File.exist?(ENV['BUNDLE_GEMFILE'])
require 'viter' require 'rails_vite'
require_relative '../test/dummy/config/application' require_relative '../test/dummy/config/application'
Viter::Exporter.export RailsVite::Exporter.export
APP_ROOT = File.expand_path('../test/dummy', __dir__) APP_ROOT = File.expand_path('../test/dummy', __dir__)
Dir.chdir(APP_ROOT) do Dir.chdir(APP_ROOT) do
Viter::DevServerRunner.run(ARGV) RailsVite::DevServerRunner.run(ARGV)
end end
...@@ -18,10 +18,10 @@ class Dingtalk::Admin::AppsControllerTest < ActionDispatch::IntegrationTest ...@@ -18,10 +18,10 @@ class Dingtalk::Admin::AppsControllerTest < ActionDispatch::IntegrationTest
end end
test 'create ok' do test 'create ok' do
assert_difference('App.count') do assert_difference('Dingtalk::App.count') do
post( post(
url_for(controller: 'dingtalk/admin/apps', action: 'create'), url_for(controller: 'dingtalk/admin/apps', action: 'create'),
params: { app: { agent_id: @dingtalk_admin_app.agent_id, app_key: @dingtalk_admin_app.app_key, app_secret: @dingtalk_admin_app.app_secret, corp_id: @dingtalk_admin_app.corp_id } }, params: { app: { agent_id: @app.agent_id, app_key: @app.app_key, app_secret: @app.app_secret, corp_id: @app.corp_id } },
as: :turbo_stream as: :turbo_stream
) )
end end
...@@ -44,7 +44,7 @@ class Dingtalk::Admin::AppsControllerTest < ActionDispatch::IntegrationTest ...@@ -44,7 +44,7 @@ class Dingtalk::Admin::AppsControllerTest < ActionDispatch::IntegrationTest
test 'update ok' do test 'update ok' do
patch( patch(
url_for(controller: 'dingtalk/admin/apps', action: 'update', id: @app.id), url_for(controller: 'dingtalk/admin/apps', action: 'update', id: @app.id),
params: { app: { agent_id: @dingtalk_admin_app.agent_id, app_key: @dingtalk_admin_app.app_key, app_secret: @dingtalk_admin_app.app_secret, corp_id: @dingtalk_admin_app.corp_id } }, params: { app: { agent_id: @app.agent_id, app_key: @app.app_key, app_secret: @app.app_secret, corp_id: @app.corp_id } },
as: :turbo_stream as: :turbo_stream
) )
...@@ -52,7 +52,7 @@ class Dingtalk::Admin::AppsControllerTest < ActionDispatch::IntegrationTest ...@@ -52,7 +52,7 @@ class Dingtalk::Admin::AppsControllerTest < ActionDispatch::IntegrationTest
end end
test 'destroy ok' do test 'destroy ok' do
assert_difference('App.count', -1) do assert_difference('Dingtalk::App.count', -1) do
delete url_for(controller: 'dingtalk/admin/apps', action: 'destroy', id: @app.id), as: :turbo_stream delete url_for(controller: 'dingtalk/admin/apps', action: 'destroy', id: @app.id), as: :turbo_stream
end end
......
Subproject commit 2b3deeebfb0873934280a181a8a4a373bc0ce4e3 Subproject commit 66154deed8b98186debc34595b24bfffbe7141c5
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment