add user_agent to channels
This commit is contained in:
@ -265,6 +265,8 @@ class ChannelsController < ApplicationController
|
||||
entry_id = channel.next_entry_id
|
||||
channel.last_entry_id = entry_id
|
||||
feed.entry_id = entry_id
|
||||
# set user agent
|
||||
channel.user_agent = get_header_value('USER_AGENT')
|
||||
|
||||
# try to get created_at datetime if appropriate
|
||||
if params[:created_at].present?
|
||||
|
@ -1,3 +1,22 @@
|
||||
# == Schema Information
|
||||
#
|
||||
# Table name: admin_users
|
||||
#
|
||||
# id :integer not null, primary key
|
||||
# email :string(255) default(""), not null
|
||||
# encrypted_password :string(255) default(""), not null
|
||||
# reset_password_token :string(255)
|
||||
# reset_password_sent_at :datetime
|
||||
# remember_created_at :datetime
|
||||
# sign_in_count :integer default(0), not null
|
||||
# current_sign_in_at :datetime
|
||||
# last_sign_in_at :datetime
|
||||
# current_sign_in_ip :string(255)
|
||||
# last_sign_in_ip :string(255)
|
||||
# created_at :datetime
|
||||
# updated_at :datetime
|
||||
#
|
||||
|
||||
class AdminUser < ActiveRecord::Base
|
||||
# Include default devise modules. Others available are:
|
||||
# :token_authenticatable, :encryptable, :confirmable, :lockable, :timeoutable and :omniauthable
|
||||
|
@ -45,6 +45,7 @@
|
||||
# video_type :string(255)
|
||||
# clearing :boolean default(FALSE), not null
|
||||
# ranking :integer
|
||||
# user_agent :string(255)
|
||||
#
|
||||
|
||||
class Channel < ActiveRecord::Base
|
||||
|
@ -23,6 +23,7 @@
|
||||
# remember_created_at :datetime
|
||||
# sign_in_count :integer default(0), not null
|
||||
# authentication_token :string(255)
|
||||
# terms_agreed_at :datetime
|
||||
#
|
||||
|
||||
####### NOTE #######
|
||||
|
Reference in New Issue
Block a user