adding categories works
This commit is contained in:
parent
2100573a14
commit
109b91c13d
@ -1950,7 +1950,7 @@ void DatabaseQueries::createOverwriteCategory(const QSqlDatabase& db, Category*
|
||||
|
||||
q.next();
|
||||
|
||||
int next_order = (q.value(0).isNull() ? 0 : q.value(0).toInt()) + 1;
|
||||
int next_order = (q.value(0).isNull() ? -1 : q.value(0).toInt()) + 1;
|
||||
|
||||
category->setSortOrder(next_order);
|
||||
q.finish();
|
||||
|
@ -110,6 +110,11 @@ void FormCategoryDetails::apply() {
|
||||
|
||||
m_serviceRoot->requestItemReassignment(m_category, parent);
|
||||
m_serviceRoot->itemChanged({ m_category });
|
||||
|
||||
if (m_creatingNew) {
|
||||
m_serviceRoot->requestItemExpand({ parent }, true);
|
||||
}
|
||||
|
||||
accept();
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user