#pragma once

#include "../databasemanager.h"
#include <QVector>
#include <optional>
#include "common_structs.h"

class SignatureDao
{
public:
    static bool insert(Signature& sig);
    static bool update(const Signature& sig);
    static bool remove(qint64 id);
    static std::optional<Signature> findById(qint64 id);
    static QVector<Signature> findByAccount(qint64 accountId);
    static QVector<Signature> findGlobal();
    static QVector<Signature> findAll();
    static std::optional<Signature> findDefault(qint64 accountId);
    static bool setDefault(qint64 id, bool isDefault);
};