mirror of
https://github.com/documize/community.git
synced 2025-07-18 20:59:43 +02:00
Dotcom pricing landing page changes
This commit is contained in:
parent
ce07d4d147
commit
5ec911dce2
2 changed files with 21 additions and 21 deletions
|
@ -159,23 +159,23 @@ func (m *middleware) Authorize(w http.ResponseWriter, r *http.Request, next http
|
|||
End: time.Now().UTC().Add(time.Hour * 24 * 7 * time.Duration(weeks))}
|
||||
} else {
|
||||
// Enterprise edition requires valid subscription data.
|
||||
rc.Subscription = domain.Subscription{Edition: domain.EnterpriseEdition,
|
||||
Seats: domain.Seats6,
|
||||
Trial: false,
|
||||
Start: time.Now().UTC(),
|
||||
End: time.Now().UTC().Add(time.Hour * 24 * 7 * time.Duration(weeks))}
|
||||
// if len(strings.TrimSpace(org.Subscription)) > 0 {
|
||||
// sd := domain.SubscriptionData{}
|
||||
// es1 := json.Unmarshal([]byte(org.Subscription), &sd)
|
||||
// if es1 == nil {
|
||||
// rc.Subscription, err = domain.DecodeSubscription(sd)
|
||||
// if err != nil {
|
||||
// m.Runtime.Log.Error("unable to decode subscription for org "+rc.OrgID, err)
|
||||
// }
|
||||
// } else {
|
||||
// m.Runtime.Log.Error("unable to load subscription for org "+rc.OrgID, es1)
|
||||
// }
|
||||
// }
|
||||
// rc.Subscription = domain.Subscription{Edition: domain.EnterpriseEdition,
|
||||
// Seats: domain.Seats6,
|
||||
// Trial: false,
|
||||
// Start: time.Now().UTC(),
|
||||
// End: time.Now().UTC().Add(time.Hour * 24 * 7 * time.Duration(weeks))}
|
||||
if len(strings.TrimSpace(org.Subscription)) > 0 {
|
||||
sd := domain.SubscriptionData{}
|
||||
es1 := json.Unmarshal([]byte(org.Subscription), &sd)
|
||||
if es1 == nil {
|
||||
rc.Subscription, err = domain.DecodeSubscription(sd)
|
||||
if err != nil {
|
||||
m.Runtime.Log.Error("unable to decode subscription for org "+rc.OrgID, err)
|
||||
}
|
||||
} else {
|
||||
m.Runtime.Log.Error("unable to load subscription for org "+rc.OrgID, es1)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Tag all HTTP calls with subscription status
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue