Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Kontrast
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
4
Issues
4
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Package Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Accessibility
Kontrast
Commits
a8169eec
Commit
a8169eec
authored
Dec 12, 2020
by
Carl Schwan
🚴
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix broken sql model
parent
b981903f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
src/savedcolormodel.cpp
src/savedcolormodel.cpp
+2
-2
No files found.
src/savedcolormodel.cpp
View file @
a8169eec
...
...
@@ -26,7 +26,7 @@ SavedColorModel::SavedColorModel(QObject *parent)
BackgroundColor BLOB NOT NULL
)
)RJIENRLWEY"
);
auto
query
=
QSqlQuery
();
auto
query
=
QSqlQuery
(
statement
);
if
(
!
query
.
exec
())
{
qCritical
()
<<
query
.
lastError
()
<<
"while creating table"
;
}
...
...
@@ -46,7 +46,7 @@ QVariant SavedColorModel::data(const QModelIndex &index, int role) const
if
(
role
==
Qt
::
UserRole
+
0
+
1
)
{
// ID
parentColumn
=
0
;
}
else
if
(
role
==
Qt
::
UserRole
+
1
+
1
)
{
// Name
parentColumn
=
0
;
parentColumn
=
1
;
}
else
if
(
role
==
Qt
::
UserRole
+
2
+
1
)
{
// ForegroundColor
parentColumn
=
2
;
}
else
{
// BackgroundColor
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment