mirror of
http://ghproxy.cn/https://github.com/multunus/onemdm-server
synced 2025-12-06 02:04:57 +00:00
API for app usage tracking
This commit is contained in:
11
db/migrate/20160204094618_create_app_usages.rb
Normal file
11
db/migrate/20160204094618_create_app_usages.rb
Normal file
@@ -0,0 +1,11 @@
|
||||
class CreateAppUsages < ActiveRecord::Migration
|
||||
def change
|
||||
create_table :app_usages do |t|
|
||||
t.string :package_name, null: false, index: false
|
||||
t.integer :usage_duration_in_seconds, null: false, index: false
|
||||
t.date :used_on, null: false, index: false
|
||||
|
||||
t.timestamps null: false
|
||||
end
|
||||
end
|
||||
end
|
||||
10
db/schema.rb
10
db/schema.rb
@@ -11,7 +11,7 @@
|
||||
#
|
||||
# It's strongly recommended that you check this file into your version control system.
|
||||
|
||||
ActiveRecord::Schema.define(version: 20151118101616) do
|
||||
ActiveRecord::Schema.define(version: 20160204094618) do
|
||||
|
||||
# These are extensions that must be enabled in order to support this database
|
||||
enable_extension "plpgsql"
|
||||
@@ -49,6 +49,14 @@ ActiveRecord::Schema.define(version: 20151118101616) do
|
||||
add_index "admin_users", ["email"], name: "index_admin_users_on_email", unique: true, using: :btree
|
||||
add_index "admin_users", ["reset_password_token"], name: "index_admin_users_on_reset_password_token", unique: true, using: :btree
|
||||
|
||||
create_table "app_usages", force: :cascade do |t|
|
||||
t.string "package_name", null: false
|
||||
t.integer "usage_duration_in_seconds", null: false
|
||||
t.date "used_on", null: false
|
||||
t.datetime "created_at", null: false
|
||||
t.datetime "updated_at", null: false
|
||||
end
|
||||
|
||||
create_table "apps", force: :cascade do |t|
|
||||
t.string "name"
|
||||
t.string "package_name"
|
||||
|
||||
Reference in New Issue
Block a user