mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-08 21:05:34 +08:00
Ref T658, model list utility functions (to be exposed as Js object)
This commit is contained in:
@@ -261,6 +261,17 @@ namespace BlackMisc
|
||||
return false;
|
||||
}
|
||||
|
||||
template<class OBJ, class CONTAINER, typename KEYTYPE>
|
||||
bool IDatastoreObjectList<OBJ, CONTAINER, KEYTYPE>::containsDbKey(KEYTYPE key) const
|
||||
{
|
||||
for (const OBJ &obj : ITimestampObjectList<OBJ, CONTAINER>::container())
|
||||
{
|
||||
if (!obj.hasValidDbKey()) { continue; }
|
||||
if (obj.getDbKey() == key) { return true; }
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
template<class OBJ, class CONTAINER, typename KEYTYPE>
|
||||
CONTAINER IDatastoreObjectList<OBJ, CONTAINER, KEYTYPE>::fromMultipleJsonFormats(const QJsonObject &jsonObject)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user