#pragma once
#include "QWidget"
#include "QTableWidget"
#include "QVBoxLayout"
#include "QLineEdit"
#include "QPushButton"
#include "QComboBox"
#include "Subject.h"
#include "Service.h"

class Collector_view : public QWidget , virtual public Observer
{
    Q_OBJECT
    private:
        Service& _subject;
        QTableWidget* _table;
        QTableWidget* _table_item;
        User _user;
        QComboBox* _combo;
        QLineEdit* _bid;
        QPushButton* _bid_button;



    public:
        Collector_view(Service& subject, User& user, QWidget* parent = nullptr);
        void update() override;
        void populate_table();
        void populate_table_item();
        void bid_item();
};