wco_models 3.1.0.50 → 3.1.0.52

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: 1a17b1b5e607a9bd18dd6f5b6f6b4346e8af8b25460bc07a622fd7c54d1cf928
4
- data.tar.gz: c5974d04bbac542b413cf6d444694e5e319271c27a4a399accd8c811a2609166
3
+ metadata.gz: 9ae41306d1c2d1a86acdc705f296feae8ba6cb9d31dcef4c1794cabaa69d8b2c
4
+ data.tar.gz: 1d34eb80dc069bb504a62a08ee25da17c92cebb5805399ff570954c8bd163c3e
5
5
  SHA512:
6
- metadata.gz: f8645a7db623d91cafd9f3a828e2e9ceabea87dcbefecdadfe21cddd74f51cbad6622535466179e9d004b9201d5f89a11157ceeb629bc551def8ea450045fbe2
7
- data.tar.gz: 538e2e1e434bd37a7995f8b51b573f424aa76eb483cc196eb34d3c0dc89f18346f238ebbea244c586db976c8cfdf33be1ae6946a6b69aa6fa3f3b7c45bf7eacb
6
+ metadata.gz: 46d410929c0405cffbd123b8b376a3629fc748e75df699b56bd94d70b9576c22c09358e64c32f3bfea59fc6b1bd7ed471cb70af2c9c4cd60170b75599df4a0d6
7
+ data.tar.gz: 5b7280694b1ba7790c33e70e1f0c8555733f6d2912e7af2bdaba73516adfe6417e1594384ca84896cf1d7b6ea3f9cdd1dcf419188f38dd19f0fc69ce1f20a37c
@@ -11,8 +11,9 @@
11
11
  border-left-width: 0;
12
12
  }
13
13
 
14
- .pagination {
14
+ ul.pagination {
15
15
  border-left: 1px solid #ddd;
16
+ margin: 1em 0;
16
17
 
17
18
  li.active {
18
19
  padding: 0 14px;
@@ -26,6 +26,13 @@ textarea {
26
26
  border-right: 1px solid red !important;
27
27
  }
28
28
 
29
+ .bordered {
30
+ border: 1px solid gray;
31
+ border-radius: 5px;
32
+
33
+ padding: 0.5em;
34
+ }
35
+
29
36
  table.bordered {
30
37
  table-layout:fixed;
31
38
  width: 100%;
@@ -94,6 +101,7 @@ textarea.monospace {
94
101
  .gray,
95
102
  .grey {
96
103
  color: grey;
104
+ display: inline-block;
97
105
  }
98
106
 
99
107
  .green {
@@ -33,7 +33,7 @@ class Wco::Leadset
33
33
  field :customer_id
34
34
  def customer_id
35
35
  if self[:customer_id].blank?
36
- return nil if !email
36
+ return nil if !email.present?
37
37
  existing = Stripe::Customer.search({ query: "email: '#{email}'" })
38
38
  # puts! existing, 'existing'
39
39
  if existing.data.present?
@@ -47,4 +47,8 @@ class Wco::Leadset
47
47
  self[:customer_id]
48
48
  end
49
49
 
50
+ def to_s
51
+ company_url
52
+ end
53
+
50
54
  end
@@ -20,7 +20,14 @@ class Wco::Tag
20
20
  has_and_belongs_to_many :logs
21
21
 
22
22
  INBOX = 'inbox'
23
+ def self.inbox
24
+ find_or_create_by({ slug: INBOX })
25
+ end
26
+
23
27
  TRASH = 'trash'
28
+ def self.trash
29
+ find_or_create_by({ slug: TRASH })
30
+ end
24
31
 
25
32
  def self.list
26
33
  [[nil,nil]] + all.map { |p| [ p.slug, p.id ] }
@@ -17,7 +17,9 @@ class WcoEmail::Message
17
17
 
18
18
  field :in_reply_to_id, type: :string
19
19
 
20
- field :object_key, type: :string ## aka 'filename', use with bucket name + prefix. I need this!
20
+ field :bucket, default: 'ish-ses'
21
+
22
+ field :object_key ## aka 'filename', use with bucket name + prefix. I need this!
21
23
  validates :object_key, presence: true, uniqueness: true
22
24
  index({ object_key: 1 }, { unique: true, name: "object_key_idx" })
23
25
 
@@ -17,6 +17,8 @@ class WcoEmail::MessageStub
17
17
  field :status, default: STATUS_PENDING
18
18
  scope :pending, ->{ where( status: 'status_pending' ) }
19
19
 
20
+ field :bucket # 'ish-ses', 'ish-ses-2024'
21
+
20
22
  field :object_key
21
23
  validates :object_key, presence: true, uniqueness: true
22
24
  index({ object_key: 1 }, { unique: true, name: "object_key_idx" })
@@ -35,14 +37,16 @@ class WcoEmail::MessageStub
35
37
  key = the_mail.message_id || "no-key-#{Time.now.to_i}.#{rand(1000)}"
36
38
 
37
39
  @stub = WcoEmail::MessageStub.create({
40
+ bucket: ::S3_CREDENTIALS[:bucket_ses],
38
41
  object_key: key,
39
42
  status: WcoEmail::MessageStub::STATUS_PENDING,
40
43
  tags: [ @tag ],
41
44
  })
42
45
  if @stub.persisted?
43
- @client.put_object({ bucket: ::S3_CREDENTIALS[:bucket_ses],
44
- key: key,
46
+ @client.put_object({
45
47
  body: message,
48
+ bucket: ::S3_CREDENTIALS[:bucket_ses],
49
+ key: key,
46
50
  })
47
51
  else
48
52
  msg = @stub.errors.full_messages.join(", ")
@@ -1,6 +1,6 @@
1
1
 
2
- .galleries-edit.max-width
3
- = render 'title', :gallery => @gallery
4
- = render 'form', :gallery => @gallery, :url => gallery_path( @gallery )
5
- = render 'thumbs', :gallery => @gallery
6
- = render 'wco/photos/multinew', :gallery => @gallery
2
+ .galleries-edit.maxwidth
3
+ = render 'title', gallery: @gallery
4
+ = render 'form', gallery: @gallery, :url => gallery_path( @gallery )
5
+ = render 'thumbs', gallery: @gallery
6
+ = render 'wco/photos/multinew', gallery: @gallery
@@ -1,3 +1,3 @@
1
1
 
2
- .invoices-index.max-width
2
+ .invoices-index.maxwidth
3
3
  = render 'index_table', invoices: @invoices
@@ -1,5 +1,5 @@
1
1
 
2
- .invoices-new.max-width
2
+ .invoices-new.maxwidth
3
3
 
4
4
  .row
5
5
  .col.s12.col.m6.col-md-offset-3
@@ -3,7 +3,7 @@
3
3
  - url = invoice.persisted? ? invoice_path( invoice.id ) : create_invoice_stripe_path
4
4
 
5
5
 
6
- .invoices-new.max-width
6
+ .invoices-new.maxwidth
7
7
 
8
8
  .row
9
9
  .col.s12.col.m6.col-md-offset-3
@@ -1,7 +1,7 @@
1
1
 
2
2
  - i = @invoice
3
3
 
4
- .invoices-show.max-width
4
+ .invoices-show.maxwidth
5
5
  %h5 Invoice ##{i.number}
6
6
 
7
7
  %ul
@@ -1,7 +1,7 @@
1
1
 
2
- .leads-edit.max-width
2
+ .leads-edit.maxwidth
3
3
  .header
4
- %h2.title Edit lead #{ link_to @lead.name, lead_path(@lead) }
4
+ %h5.title Edit lead #{ link_to @lead.name, lead_path(@lead) }
5
5
 
6
6
  = render 'form', :lead => @lead
7
7
 
@@ -1,5 +1,5 @@
1
1
 
2
- .leads-new.max-width
2
+ .leads-new.maxwidth
3
3
  .row
4
4
  .col-sm-12.col-md-6
5
5
  %h1 New Lead
@@ -7,10 +7,6 @@
7
7
  = f.label :company_url
8
8
  = f.text_field :company_url
9
9
 
10
- .input-field
11
- = f.label :name
12
- = f.text_field :name
13
-
14
10
  .input-field
15
11
  = f.label :email
16
12
  = f.text_field :email
@@ -1,4 +1,4 @@
1
1
 
2
- .leadsets-edit.max-width
3
- %h1 Edit leadset `#{link_to @leadset.name, leadset_path(@leadset)}`
4
- = render 'form', :leadset => @leadset
2
+ .leadsets-edit.maxwidth
3
+ %h1 Edit leadset `#{link_to @leadset.company_url, leadset_path(@leadset)}`
4
+ = render 'form', leadset: @leadset
@@ -1,5 +1,5 @@
1
1
 
2
- .leadsets-new.max-width
2
+ .leadsets-new.maxwidth
3
3
  .row
4
4
  .col.s6.col-sm-offset-3
5
5
  %h5 New Leadset
@@ -1,5 +1,5 @@
1
1
 
2
- .products-edit.max-width
2
+ .products-edit.maxwidth
3
3
  %h5 Edit product
4
4
 
5
5
  = render 'form', product: @product
@@ -1,5 +1,5 @@
1
1
 
2
- .products-show.max-width
2
+ .products-show.maxwidth
3
3
  %h5
4
4
  Show product #{@product.name}
5
5
  = link_to '[~]', edit_product_path( @product )
@@ -1,7 +1,7 @@
1
1
 
2
2
 
3
- .videos-edit.max-width
3
+ .videos-edit.maxwidth
4
4
  .header
5
- %h3.title Edit Video
5
+ %h5.title Edit Video
6
6
 
7
7
  = render 'form', :video => @video
@@ -1,5 +1,5 @@
1
1
 
2
- .videos-new.max-width
2
+ .videos-new.maxwidth
3
3
  .header
4
4
  %h3.title New Video
5
5
 
@@ -1,7 +1,7 @@
1
1
 
2
2
  - video ||= @video
3
3
 
4
- .videos-show.max-width
4
+ .videos-show.maxwidth
5
5
  .row
6
6
  = link_to '[Back]', videos_path
7
7
 
@@ -1,4 +1,4 @@
1
1
 
2
2
  Rails.application.config.assets.version = '1.0'
3
3
 
4
- Rails.application.config.assets.precompile += %w( wco/application.js )
4
+ Rails.application.config.assets.precompile += %w( wco/application.js wco/application.css )
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.50
4
+ version: 3.1.0.52
5
5
  platform: ruby
6
6
  authors:
7
7
  - Victor Pudeyev
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-01-09 00:00:00.000000000 Z
11
+ date: 2024-01-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sdk-s3