wco_models 3.1.0.283 → 3.1.0.284
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/app/controllers/wco/application_controller.rb +4 -0
- data/app/controllers/wco/profiles_controller.rb +12 -0
- data/app/models/ability.rb +0 -2
- data/app/models/wco/newsitem.rb +3 -1
- data/app/models/wco/newsoverlay_config.rb +3 -0
- data/app/models/wco_email/config.rb +3 -1
- data/app/models/wco_email/email_filter.rb +1 -1
- data/app/models/wco_hosting/file.rb +3 -0
- data/app/models/wco_hosting/task.rb +3 -0
- data/app/models/wco_hosting/task_tmpl.rb +3 -0
- data/app/views/wco/profiles/index.haml +1 -0
- data/config/routes.rb +2 -0
- metadata +2 -3
- data/app/models/wco/obfuscated_redirect.rb +0 -21
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: e3cb1ecd7199dc69284f536be5e677c6f9f11adffa4f7241d17120d7e4879a97
|
|
4
|
+
data.tar.gz: 683427ed5cb7b7dc26dd8746a77ba1120a6bf4da263f4884c5042c0dbcf800f5
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 51c34c30ac09071bf026ccf065fba1e1bcbe734ae6ddc9d1b8388d87017f3afa2f8979f461108a62b1caa8de3f90972d5aa2ac6baedb11e3df268d2a1e6ef122
|
|
7
|
+
data.tar.gz: f1c9965e2b84b30ad72110d4c8a8c386b21ab488f2fbd5078ff2f8cbc088a58ddfa065b4108145ef1365d11e687120a52915ee210dae030a9451e58cc16416ce
|
|
@@ -13,6 +13,18 @@ class Wco::ProfilesController < Wco::ApplicationController
|
|
|
13
13
|
end
|
|
14
14
|
end
|
|
15
15
|
|
|
16
|
+
def destroy
|
|
17
|
+
@profile = Wco::Profile.unscoped.find params[:id]
|
|
18
|
+
authorize! :create, @profile
|
|
19
|
+
|
|
20
|
+
if @profile.destroy
|
|
21
|
+
flash_notice 'Deleted Wco::Profile'
|
|
22
|
+
else
|
|
23
|
+
flash_alert "Cannot destroy profile: #{@profile.errors.fill_messages.join(', ')}."
|
|
24
|
+
end
|
|
25
|
+
redirect_to request.referrer || { action: 'index' }
|
|
26
|
+
end
|
|
27
|
+
|
|
16
28
|
def edit
|
|
17
29
|
@profile = Wco::Profile.find params[:id]
|
|
18
30
|
authorize! :update, @profile
|
data/app/models/ability.rb
CHANGED
data/app/models/wco/newsitem.rb
CHANGED
|
@@ -7,5 +7,6 @@
|
|
|
7
7
|
- @profiles.each do |profile|
|
|
8
8
|
%li
|
|
9
9
|
= link_to '[~]', edit_profile_path(profile)
|
|
10
|
+
.d-inline-block= button_to 'x', profile_path(profile), method: :delete, data: { confirm: 'Are you sure?' }
|
|
10
11
|
= profile.email
|
|
11
12
|
<b>Leadset:</b> #{link_to profile.leadset, leadset_path(profile.leadset)}
|
data/config/routes.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: wco_models
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 3.1.0.
|
|
4
|
+
version: 3.1.0.284
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Victor Pudeyev
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-07-
|
|
11
|
+
date: 2026-07-16 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: aws-sdk-s3
|
|
@@ -497,7 +497,6 @@ files:
|
|
|
497
497
|
- app/models/wco/newsoverlay_config.rb
|
|
498
498
|
- app/models/wco/newspartial.rb
|
|
499
499
|
- app/models/wco/newsvideo.rb
|
|
500
|
-
- app/models/wco/obfuscated_redirect.rb
|
|
501
500
|
- app/models/wco/office_action.rb
|
|
502
501
|
- app/models/wco/office_action_template.rb
|
|
503
502
|
- app/models/wco/office_action_template_tie.rb
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
class Wco::ObfuscatedRedirect
|
|
3
|
-
include Mongoid::Document
|
|
4
|
-
include Mongoid::Timestamps
|
|
5
|
-
include Mongoid::Paranoia
|
|
6
|
-
store_in collection: 'office_obfuscated_redirects'
|
|
7
|
-
|
|
8
|
-
field :slug, type: :string
|
|
9
|
-
|
|
10
|
-
field :to_link, type: :string
|
|
11
|
-
validates :to_link, presence: true
|
|
12
|
-
|
|
13
|
-
field :visited_at, type: DateTime
|
|
14
|
-
field :visits, type: :array, default: []
|
|
15
|
-
|
|
16
|
-
def obf_link
|
|
17
|
-
"https://email.wasya.co/api/obf/#{self.id}"
|
|
18
|
-
end
|
|
19
|
-
|
|
20
|
-
end
|
|
21
|
-
Wco::Obf ||= Wco::ObfuscatedRedirect
|