mirror of
https://github.com/owntone/owntone-server.git
synced 2024-12-28 08:05:56 -05:00
[db,jsonapi] revert usermark from queue item table
This commit is contained in:
parent
16cf3cb44b
commit
4d5c256327
2
src/db.c
2
src/db.c
@ -295,7 +295,6 @@ static const struct col_type_map qi_cols_map[] =
|
||||
{ "bitrate", qi_offsetof(bitrate), DB_TYPE_INT },
|
||||
{ "samplerate", qi_offsetof(samplerate), DB_TYPE_INT },
|
||||
{ "channels", qi_offsetof(channels), DB_TYPE_INT },
|
||||
{ "usermark", qi_offsetof(usermark), DB_TYPE_INT },
|
||||
};
|
||||
|
||||
/* This list must be kept in sync with
|
||||
@ -456,7 +455,6 @@ static const struct qi_mfi_map qi_mfi_map[] =
|
||||
{ qi_offsetof(bitrate), mfi_offsetof(bitrate), dbmfi_offsetof(bitrate) },
|
||||
{ qi_offsetof(samplerate), mfi_offsetof(samplerate), dbmfi_offsetof(samplerate) },
|
||||
{ qi_offsetof(channels), mfi_offsetof(channels), dbmfi_offsetof(channels) },
|
||||
{ qi_offsetof(usermark), mfi_offsetof(usermark), dbmfi_offsetof(usermark) },
|
||||
};
|
||||
|
||||
/* This list must be kept in sync with
|
||||
|
2
src/db.h
2
src/db.h
@ -514,8 +514,6 @@ struct db_queue_item {
|
||||
|
||||
int64_t songartistid;
|
||||
|
||||
uint32_t usermark;
|
||||
|
||||
/* Not saved in queue table */
|
||||
uint32_t seek;
|
||||
};
|
||||
|
@ -200,8 +200,7 @@
|
||||
" type VARCHAR(8) DEFAULT NULL," \
|
||||
" bitrate INTEGER DEFAULT 0," \
|
||||
" samplerate INTEGER DEFAULT 0," \
|
||||
" channels INTEGER DEFAULT 0," \
|
||||
" usermark INTEGER DEFAULT 0" \
|
||||
" channels INTEGER DEFAULT 0" \
|
||||
");"
|
||||
|
||||
#define Q_PL1 \
|
||||
|
@ -1163,15 +1163,12 @@ static const struct db_upgrade_query db_upgrade_v2106_queries[] =
|
||||
/* ---------------------------- 21.06 -> 21.07 ------------------------------ */
|
||||
#define U_v2107_ALTER_FILES_USERMARK \
|
||||
"ALTER TABLE files ADD COLUMN usermark INTEGER DEFAULT 0;"
|
||||
#define U_v2107_ALTER_QUEUE_USERMARK \
|
||||
"ALTER TABLE queue ADD COLUMN usermark INTEGER DEFAULT 0;"
|
||||
#define U_v2107_SCVER_MINOR \
|
||||
"UPDATE admin SET value = '07' WHERE key = 'schema_version_minor';"
|
||||
|
||||
static const struct db_upgrade_query db_upgrade_v2107_queries[] =
|
||||
{
|
||||
{ U_v2107_ALTER_FILES_USERMARK, "update files adding usermark" },
|
||||
{ U_v2107_ALTER_QUEUE_USERMARK, "update queue adding usermark" },
|
||||
|
||||
{ U_v2107_SCVER_MINOR, "set schema_version_minor to 07" },
|
||||
};
|
||||
|
@ -2222,7 +2222,6 @@ queue_item_to_json(struct db_queue_item *queue_item, char shuffle)
|
||||
json_object_object_add(item, "bitrate", json_object_new_int(queue_item->bitrate));
|
||||
json_object_object_add(item, "samplerate", json_object_new_int(queue_item->samplerate));
|
||||
json_object_object_add(item, "channels", json_object_new_int(queue_item->channels));
|
||||
json_object_object_add(item, "usermark", json_object_new_int(queue_item->usermark));
|
||||
|
||||
return item;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user