major updates to security and hacking logick
This commit is contained in:
@@ -6,6 +6,8 @@ class Supplier
|
||||
property :name
|
||||
property :open, type: :boolean, default: false
|
||||
property :night_offset, type: Float
|
||||
|
||||
#LOCATION
|
||||
property :lat, type: Float, default: 52.08062426379751
|
||||
property :lng, type: Float, default: 4.312562942504883
|
||||
|
||||
@@ -15,6 +17,9 @@ class Supplier
|
||||
property :wifi_type
|
||||
property :wifi_password
|
||||
|
||||
#REVIEWS
|
||||
property :iens_profile
|
||||
|
||||
#has_many :orders, through: :lists
|
||||
has_many :products, dependent: :destroy
|
||||
has_many :product_categories, dependent: :destroy
|
||||
@@ -29,6 +34,7 @@ class Supplier
|
||||
view :by_email, key: :email
|
||||
|
||||
validates :name, presence: true
|
||||
validates :iens_profile, numericality: true
|
||||
|
||||
def location=(val)
|
||||
lat, lng = val.strip.split(/[ ,]+/).map(&:to_f)
|
||||
|
||||
+1
-1
@@ -3,7 +3,7 @@ class User
|
||||
include Devise::Orm::SimplyStored
|
||||
property :active_list_id
|
||||
|
||||
devise :database_authenticatable, :recoverable, :rememberable, :trackable, :registerable, :token_authenticatable
|
||||
devise :database_authenticatable, :recoverable, :rememberable, :trackable, :token_authenticatable # , :registerable
|
||||
|
||||
has_and_belongs_to_many :lists, storing_keys: false
|
||||
has_many :orders
|
||||
|
||||
Reference in New Issue
Block a user