#pragma once

#include <QDialog>
#include "ui_QLoginDialog.h"

class QLoginDialog : public QDialog
{
	Q_OBJECT

public:
	QLoginDialog(QWidget *parent = Q_NULLPTR);
	~QLoginDialog();

	typedef enum { OK, EXIT } ReturnCode;
	
	ReturnCode getReturnCode() const
	{
		return returnCode;
	}

protected Q_SLOTS:
	void init();
	void initData();
	void initSignal();
	void initWidgets();

	void onOK();
	void onExit();

private:
	void queryStaffInfo( const QString & systemUserName );

private:
	Ui::QLoginDialog ui;
	ReturnCode returnCode;
	QString systemUserName;
	QString cpicUserName;
	QString cpicP13;
};
