Initial commit
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
#ifndef CREATE_GENRE_REQUEST_H
|
||||
#define CREATE_GENRE_REQUEST_H
|
||||
|
||||
#include <QString>
|
||||
|
||||
class CreateGenreRequest {
|
||||
private:
|
||||
QString genreName_; // Genre name
|
||||
|
||||
public:
|
||||
// Constructors
|
||||
explicit CreateGenreRequest() = default;
|
||||
explicit CreateGenreRequest(const QString &genreName)
|
||||
: genreName_(genreName) {}
|
||||
|
||||
// Setters (inline methods)
|
||||
inline void setGenreName(const QString &genreName) { genreName_ = genreName; }
|
||||
|
||||
// Getters (inline methods)
|
||||
inline QString genreName() const { return genreName_; }
|
||||
};
|
||||
|
||||
#endif // CREATE_GENRE_REQUEST_H
|
||||
|
||||
@@ -0,0 +1,26 @@
|
||||
#ifndef CREATE_HALL_REQUEST_H
|
||||
#define CREATE_HALL_REQUEST_H
|
||||
|
||||
#include <QString>
|
||||
|
||||
class CreateHallRequest {
|
||||
private:
|
||||
QString hallName_; // Hall name
|
||||
qint32 capacity_; // Hall capacity
|
||||
|
||||
public:
|
||||
// Constructors
|
||||
explicit CreateHallRequest() = default;
|
||||
explicit CreateHallRequest(const QString &hallName, qint32 capacity)
|
||||
: hallName_(hallName), capacity_(capacity) {}
|
||||
|
||||
// Setters (inline methods)
|
||||
inline void setHallName(const QString &hallName) { hallName_ = hallName; }
|
||||
inline void setCapacity(qint32 capacity) { capacity_ = capacity; }
|
||||
|
||||
// Getters (inline methods)
|
||||
inline QString hallName() const { return hallName_; }
|
||||
inline qint32 capacity() const { return capacity_; }
|
||||
};
|
||||
|
||||
#endif // CREATE_HALL_REQUEST_H
|
||||
@@ -0,0 +1,30 @@
|
||||
#ifndef CREATE_MOVIE_REQUEST_H
|
||||
#define CREATE_MOVIE_REQUEST_H
|
||||
|
||||
#include <QString>
|
||||
|
||||
class CreateMovieRequest {
|
||||
private:
|
||||
QString title_; // Movie title
|
||||
qint32 duration_; // Movie duration
|
||||
qint32 genreId_; // Genre ID
|
||||
|
||||
public:
|
||||
// Constructors
|
||||
explicit CreateMovieRequest() = default;
|
||||
explicit CreateMovieRequest(const QString &title, qint32 duration,
|
||||
qint32 genreId)
|
||||
: title_(title), duration_(duration), genreId_(genreId) {}
|
||||
|
||||
// Setters (inline methods)
|
||||
inline void setTitle(const QString &title) { title_ = title; }
|
||||
inline void setDuration(qint32 duration) { duration_ = duration; }
|
||||
inline void setGenreId(qint32 genreId) { genreId_ = genreId; }
|
||||
|
||||
// Getters (inline methods)
|
||||
inline QString title() const { return title_; }
|
||||
inline qint32 duration() const { return duration_; }
|
||||
inline qint32 genreId() const { return genreId_; }
|
||||
};
|
||||
|
||||
#endif // CREATE_MOVIE_REQUEST_H
|
||||
@@ -0,0 +1,32 @@
|
||||
#ifndef CREATE_REFUND_REQUEST_H
|
||||
#define CREATE_REFUND_REQUEST_H
|
||||
|
||||
#include <QDateTime>
|
||||
|
||||
class CreateRefundRequest {
|
||||
private:
|
||||
QDateTime refundAt_; // Refund date and time
|
||||
double refundAmount_; // Refund amount
|
||||
qint32 ticketId_; // Ticket ID
|
||||
|
||||
public:
|
||||
// Constructors
|
||||
explicit CreateRefundRequest() = default;
|
||||
explicit CreateRefundRequest(const QDateTime &refundAt, double refundAmount,
|
||||
qint32 ticketId)
|
||||
: refundAt_(refundAt), refundAmount_(refundAmount), ticketId_(ticketId) {}
|
||||
|
||||
// Setters (inline methods)
|
||||
inline void setRefundAt(const QDateTime &refundAt) { refundAt_ = refundAt; }
|
||||
inline void setRefundAmount(double refundAmount) {
|
||||
refundAmount_ = refundAmount;
|
||||
}
|
||||
inline void setTicketId(qint32 ticketId) { ticketId_ = ticketId; }
|
||||
|
||||
// Getters (inline methods)
|
||||
inline QDateTime refundAt() const { return refundAt_; }
|
||||
inline double refundAmount() const { return refundAmount_; }
|
||||
inline qint32 ticketId() const { return ticketId_; }
|
||||
};
|
||||
|
||||
#endif // CREATE_REFUND_REQUEST_H
|
||||
@@ -0,0 +1,27 @@
|
||||
#ifndef CREATE_ROLE_REQUEST_H
|
||||
#define CREATE_ROLE_REQUEST_H
|
||||
|
||||
#include <QString>
|
||||
|
||||
class CreateRoleRequest {
|
||||
private:
|
||||
QString roleName_; // Role name
|
||||
qint32 accessLevel_; // Access level
|
||||
|
||||
public:
|
||||
// Constructors
|
||||
explicit CreateRoleRequest() = default;
|
||||
explicit CreateRoleRequest(const QString &roleName, qint32 accessLevel)
|
||||
: roleName_(roleName), accessLevel_(accessLevel) {}
|
||||
|
||||
// Setters (inline methods)
|
||||
inline void setRoleName(const QString &roleName) { roleName_ = roleName; }
|
||||
inline void setAccessLevel(qint32 accessLevel) { accessLevel_ = accessLevel; }
|
||||
|
||||
// Getters (inline methods)
|
||||
inline QString roleName() const { return roleName_; }
|
||||
inline qint32 accessLevel() const { return accessLevel_; }
|
||||
};
|
||||
|
||||
#endif // CREATE_ROLE_REQUEST_H
|
||||
|
||||
@@ -0,0 +1,34 @@
|
||||
#ifndef CREATE_SESSION_REQUEST_H
|
||||
#define CREATE_SESSION_REQUEST_H
|
||||
|
||||
#include <QDateTime>
|
||||
|
||||
class CreateSessionRequest {
|
||||
private:
|
||||
QDateTime beginAt_; // Session start time
|
||||
double ticketPrice_; // Ticket price
|
||||
qint32 hallId_; // Hall ID
|
||||
qint32 movieId_; // Movie ID
|
||||
|
||||
public:
|
||||
// Constructors
|
||||
explicit CreateSessionRequest() = default;
|
||||
explicit CreateSessionRequest(const QDateTime &beginAt, double ticketPrice,
|
||||
qint32 hallId, qint32 movieId)
|
||||
: beginAt_(beginAt), ticketPrice_(ticketPrice), hallId_(hallId),
|
||||
movieId_(movieId) {}
|
||||
|
||||
// Setters (inline methods)
|
||||
inline void setBeginAt(const QDateTime &beginAt) { beginAt_ = beginAt; }
|
||||
inline void setTicketPrice(double ticketPrice) { ticketPrice_ = ticketPrice; }
|
||||
inline void setHallId(qint32 hallId) { hallId_ = hallId; }
|
||||
inline void setMovieId(qint32 movieId) { movieId_ = movieId; }
|
||||
|
||||
// Getters (inline methods)
|
||||
inline QDateTime beginAt() const { return beginAt_; }
|
||||
inline double ticketPrice() const { return ticketPrice_; }
|
||||
inline qint32 hallId() const { return hallId_; }
|
||||
inline qint32 movieId() const { return movieId_; }
|
||||
};
|
||||
|
||||
#endif // CREATE_SESSION_REQUEST_H
|
||||
@@ -0,0 +1,30 @@
|
||||
#ifndef CREATE_TICKET_REQUEST_H
|
||||
#define CREATE_TICKET_REQUEST_H
|
||||
|
||||
#include <QDateTime>
|
||||
|
||||
class CreateTicketRequest {
|
||||
private:
|
||||
QDateTime soldAt_; // Ticket sold date and time
|
||||
qint32 seatNumber_; // Seat number
|
||||
qint32 sessionId_; // Session ID
|
||||
|
||||
public:
|
||||
// Constructors
|
||||
explicit CreateTicketRequest() = default;
|
||||
explicit CreateTicketRequest(const QDateTime &soldAt, qint32 seatNumber,
|
||||
qint32 sessionId)
|
||||
: soldAt_(soldAt), seatNumber_(seatNumber), sessionId_(sessionId) {}
|
||||
|
||||
// Setters (inline methods)
|
||||
inline void setSoldAt(const QDateTime &soldAt) { soldAt_ = soldAt; }
|
||||
inline void setSeatNumber(qint32 seatNumber) { seatNumber_ = seatNumber; }
|
||||
inline void setSessionId(qint32 sessionId) { sessionId_ = sessionId; }
|
||||
|
||||
// Getters (inline methods)
|
||||
inline QDateTime soldAt() const { return soldAt_; }
|
||||
inline qint32 seatNumber() const { return seatNumber_; }
|
||||
inline qint32 sessionId() const { return sessionId_; }
|
||||
};
|
||||
|
||||
#endif // CREATE_TICKET_REQUEST_H
|
||||
@@ -0,0 +1,36 @@
|
||||
#ifndef CREATE_USER_REQUEST_H
|
||||
#define CREATE_USER_REQUEST_H
|
||||
|
||||
#include <QString>
|
||||
|
||||
class CreateUserRequest {
|
||||
private:
|
||||
QString passwordHash_; // Hashed password
|
||||
QString salt_; // Salt for password hashing
|
||||
QString username_; // Username
|
||||
qint32 roleId_; // Role ID
|
||||
|
||||
public:
|
||||
// Constructors
|
||||
explicit CreateUserRequest() = default;
|
||||
explicit CreateUserRequest(const QString &passwordHash, const QString &salt,
|
||||
const QString &username, qint32 roleId)
|
||||
: passwordHash_(passwordHash), roleId_(roleId), salt_(salt),
|
||||
username_(username) {}
|
||||
|
||||
// Setters (inline methods)
|
||||
inline void setUsername(const QString &username) { username_ = username; }
|
||||
inline void setPasswordHash(const QString &passwordHash) {
|
||||
passwordHash_ = passwordHash;
|
||||
}
|
||||
inline void setSalt(const QString &salt) { salt_ = salt; }
|
||||
inline void setRoleId(qint32 roleId) { roleId_ = roleId; }
|
||||
|
||||
// Getters (inline methods)
|
||||
inline QString username() const { return username_; }
|
||||
inline QString passwordHash() const { return passwordHash_; }
|
||||
inline QString salt() const { return salt_; }
|
||||
inline qint32 roleId() const { return roleId_; }
|
||||
};
|
||||
|
||||
#endif // CREATE_USER_REQUEST_H
|
||||
@@ -0,0 +1,26 @@
|
||||
#ifndef UPDATE_GENRE_REQUEST_H
|
||||
#define UPDATE_GENRE_REQUEST_H
|
||||
|
||||
#include <QString>
|
||||
|
||||
class UpdateGenreRequest {
|
||||
private:
|
||||
QString genreName_; // Genre name
|
||||
qint32 genreId_; // Genre ID
|
||||
|
||||
public:
|
||||
// Constructors
|
||||
explicit UpdateGenreRequest() = default;
|
||||
explicit UpdateGenreRequest(const QString &genreName, qint32 genreId)
|
||||
: genreName_(genreName), genreId_(genreId) {}
|
||||
|
||||
// Setters (inline methods)
|
||||
inline void setGenreId(qint32 genreId) { genreId_ = genreId; }
|
||||
inline void setGenreName(const QString &genreName) { genreName_ = genreName; }
|
||||
|
||||
// Getters (inline methods)
|
||||
inline qint32 genreId() const { return genreId_; }
|
||||
inline QString genreName() const { return genreName_; }
|
||||
};
|
||||
|
||||
#endif // UPDATE_GENRE_REQUEST_H
|
||||
@@ -0,0 +1,30 @@
|
||||
#ifndef UPDATE_HALL_REQUEST_H
|
||||
#define UPDATE_HALL_REQUEST_H
|
||||
|
||||
#include <QString>
|
||||
|
||||
class UpdateHallRequest {
|
||||
private:
|
||||
QString hallName_; // Hall name
|
||||
qint32 capacity_; // Hall capacity
|
||||
qint32 hallId_; // Hall ID
|
||||
|
||||
public:
|
||||
// Constructors
|
||||
explicit UpdateHallRequest() = default;
|
||||
explicit UpdateHallRequest(const QString &hallName, qint32 capacity,
|
||||
qint32 hallId)
|
||||
: capacity_(capacity), hallId_(hallId), hallName_(hallName) {}
|
||||
|
||||
// Setters (inline methods)
|
||||
inline void setHallId(qint32 hallId) { hallId_ = hallId; }
|
||||
inline void setHallName(const QString &hallName) { hallName_ = hallName; }
|
||||
inline void setCapacity(qint32 capacity) { capacity_ = capacity; }
|
||||
|
||||
// Getters (inline methods)
|
||||
inline qint32 hallId() const { return hallId_; }
|
||||
inline QString hallName() const { return hallName_; }
|
||||
inline qint32 capacity() const { return capacity_; }
|
||||
};
|
||||
|
||||
#endif // UPDATE_HALL_REQUEST_H
|
||||
@@ -0,0 +1,35 @@
|
||||
#ifndef UPDATE_MOVIE_REQUEST_H
|
||||
#define UPDATE_MOVIE_REQUEST_H
|
||||
|
||||
#include <QString>
|
||||
|
||||
class UpdateMovieRequest {
|
||||
private:
|
||||
QString title_; // Movie title
|
||||
qint32 duration_; // Movie duration
|
||||
qint32 genreId_; // Genre ID
|
||||
qint32 movieId_; // Movie ID
|
||||
|
||||
public:
|
||||
// Constructors
|
||||
explicit UpdateMovieRequest() = default;
|
||||
explicit UpdateMovieRequest(qint32 movieId, const QString &title,
|
||||
qint32 duration, qint32 genreId)
|
||||
: movieId_(movieId), title_(title), duration_(duration),
|
||||
genreId_(genreId) {}
|
||||
|
||||
// Setters (inline methods)
|
||||
inline void setDuration(qint32 duration) { duration_ = duration; }
|
||||
inline void setGenreId(qint32 genreId) { genreId_ = genreId; }
|
||||
inline void setMovieId(qint32 movieId) { movieId_ = movieId; }
|
||||
inline void setTitle(const QString &title) { title_ = title; }
|
||||
|
||||
// Getters (inline methods)
|
||||
inline QString title() const { return title_; }
|
||||
inline qint32 duration() const { return duration_; }
|
||||
inline qint32 genreId() const { return genreId_; }
|
||||
inline qint32 movieId() const { return movieId_; }
|
||||
};
|
||||
|
||||
#endif // UPDATE_MOVIE_REQUEST_H
|
||||
|
||||
@@ -0,0 +1,37 @@
|
||||
#ifndef UPDATE_REFUND_REQUEST_H
|
||||
#define UPDATE_REFUND_REQUEST_H
|
||||
|
||||
#include <QDateTime>
|
||||
|
||||
class UpdateRefundRequest {
|
||||
private:
|
||||
QDateTime refundAt_; // Refund date and time
|
||||
double refundAmount_; // Refund amount
|
||||
qint32 refundId_; // Refund ID
|
||||
qint32 ticketId_; // Ticket ID
|
||||
|
||||
public:
|
||||
// Constructors
|
||||
explicit UpdateRefundRequest() = default;
|
||||
explicit UpdateRefundRequest(const QDateTime &refundAt, double refundAmount,
|
||||
qint32 refundId, qint32 ticketId)
|
||||
: refundAmount_(refundAmount), refundAt_(refundAt), refundId_(refundId),
|
||||
ticketId_(ticketId) {}
|
||||
|
||||
// Setters (inline methods)
|
||||
inline void setRefundAmount(double refundAmount) {
|
||||
refundAmount_ = refundAmount;
|
||||
}
|
||||
inline void setRefundAt(const QDateTime &refundAt) { refundAt_ = refundAt; }
|
||||
inline void setRefundId(qint32 refundId) { refundId_ = refundId; }
|
||||
inline void setTicketId(qint32 ticketId) { ticketId_ = ticketId; }
|
||||
|
||||
// Getters (inline methods)
|
||||
inline QDateTime refundAt() const { return refundAt_; }
|
||||
inline double refundAmount() const { return refundAmount_; }
|
||||
inline qint32 refundId() const { return refundId_; }
|
||||
inline qint32 ticketId() const { return ticketId_; }
|
||||
};
|
||||
|
||||
#endif // UPDATE_REFUND_REQUEST_H
|
||||
|
||||
@@ -0,0 +1,30 @@
|
||||
#ifndef UPDATE_ROLE_REQUEST_H
|
||||
#define UPDATE_ROLE_REQUEST_H
|
||||
|
||||
#include <QString>
|
||||
|
||||
class UpdateRoleRequest {
|
||||
private:
|
||||
QString roleName_; // Role name
|
||||
qint32 accessLevel_; // Access level
|
||||
qint32 roleId_; // Role ID
|
||||
|
||||
public:
|
||||
// Constructors
|
||||
explicit UpdateRoleRequest() = default;
|
||||
explicit UpdateRoleRequest(const QString &roleName, qint32 accessLevel,
|
||||
qint32 roleId)
|
||||
: accessLevel_(accessLevel), roleId_(roleId), roleName_(roleName) {}
|
||||
|
||||
// Setters (inline methods)
|
||||
inline void setRoleId(qint32 roleId) { roleId_ = roleId; }
|
||||
inline void setRoleName(const QString &roleName) { roleName_ = roleName; }
|
||||
inline void setAccessLevel(qint32 accessLevel) { accessLevel_ = accessLevel; }
|
||||
|
||||
// Getters (inline methods)
|
||||
inline qint32 roleId() const { return roleId_; }
|
||||
inline QString roleName() const { return roleName_; }
|
||||
inline qint32 accessLevel() const { return accessLevel_; }
|
||||
};
|
||||
|
||||
#endif // UPDATE_ROLE_REQUEST_H
|
||||
@@ -0,0 +1,38 @@
|
||||
#ifndef UPDATE_SESSION_REQUEST_H
|
||||
#define UPDATE_SESSION_REQUEST_H
|
||||
|
||||
#include <QDateTime>
|
||||
|
||||
class UpdateSessionRequest {
|
||||
private:
|
||||
QDateTime beginAt_; // Session start time
|
||||
double ticketPrice_; // Ticket price
|
||||
qint32 hallId_; // Hall ID
|
||||
qint32 movieId_; // Movie ID
|
||||
qint32 sessionId_; // Session ID
|
||||
|
||||
public:
|
||||
// Constructors
|
||||
explicit UpdateSessionRequest() = default;
|
||||
explicit UpdateSessionRequest(const QDateTime &beginAt, double ticketPrice,
|
||||
qint32 hallId, qint32 movieId, qint32 sessionId)
|
||||
: beginAt_(beginAt), hallId_(hallId), movieId_(movieId),
|
||||
sessionId_(sessionId), ticketPrice_(ticketPrice) {}
|
||||
|
||||
// Setters (inline methods)
|
||||
inline void setBeginAt(const QDateTime &beginAt) { beginAt_ = beginAt; }
|
||||
inline void setHallId(qint32 hallId) { hallId_ = hallId; }
|
||||
inline void setMovieId(qint32 movieId) { movieId_ = movieId; }
|
||||
inline void setSessionId(qint32 sessionId) { sessionId_ = sessionId; }
|
||||
inline void setTicketPrice(double ticketPrice) { ticketPrice_ = ticketPrice; }
|
||||
|
||||
// Getters (inline methods)
|
||||
inline QDateTime beginAt() const { return beginAt_; }
|
||||
inline double ticketPrice() const { return ticketPrice_; }
|
||||
inline qint32 hallId() const { return hallId_; }
|
||||
inline qint32 movieId() const { return movieId_; }
|
||||
inline qint32 sessionId() const { return sessionId_; }
|
||||
};
|
||||
|
||||
#endif // UPDATE_SESSION_REQUEST_H
|
||||
|
||||
@@ -0,0 +1,35 @@
|
||||
#ifndef UPDATE_TICKET_REQUEST_H
|
||||
#define UPDATE_TICKET_REQUEST_H
|
||||
|
||||
#include <QDateTime>
|
||||
|
||||
class UpdateTicketRequest {
|
||||
private:
|
||||
QDateTime soldAt_; // Ticket sold date and time
|
||||
qint32 seatNumber_; // Seat number
|
||||
qint32 sessionId_; // Session ID
|
||||
qint32 ticketId_; // Ticket ID
|
||||
|
||||
public:
|
||||
// Constructors
|
||||
explicit UpdateTicketRequest() = default;
|
||||
explicit UpdateTicketRequest(const QDateTime &soldAt, qint32 seatNumber,
|
||||
qint32 sessionId, qint32 ticketId)
|
||||
: seatNumber_(seatNumber), sessionId_(sessionId), soldAt_(soldAt),
|
||||
ticketId_(ticketId) {}
|
||||
|
||||
// Setters (inline methods)
|
||||
inline void setSeatNumber(qint32 seatNumber) { seatNumber_ = seatNumber; }
|
||||
inline void setSessionId(qint32 sessionId) { sessionId_ = sessionId; }
|
||||
inline void setSoldAt(const QDateTime &soldAt) { soldAt_ = soldAt; }
|
||||
inline void setTicketId(qint32 ticketId) { ticketId_ = ticketId; }
|
||||
|
||||
// Getters (inline methods)
|
||||
inline QDateTime soldAt() const { return soldAt_; }
|
||||
inline qint32 seatNumber() const { return seatNumber_; }
|
||||
inline qint32 sessionId() const { return sessionId_; }
|
||||
inline qint32 ticketId() const { return ticketId_; }
|
||||
};
|
||||
|
||||
#endif // UPDATE_TICKET_REQUEST_H
|
||||
|
||||
@@ -0,0 +1,40 @@
|
||||
#ifndef UPDATE_USER_REQUEST_H
|
||||
#define UPDATE_USER_REQUEST_H
|
||||
|
||||
#include <QString>
|
||||
|
||||
class UpdateUserRequest {
|
||||
private:
|
||||
QString passwordHash_; // Hashed password
|
||||
QString salt_; // Salt for password hashing
|
||||
QString username_; // Username
|
||||
qint32 roleId_; // Role ID
|
||||
qint32 userId_; // Unique user ID
|
||||
|
||||
public:
|
||||
// Constructors
|
||||
explicit UpdateUserRequest() = default;
|
||||
explicit UpdateUserRequest(const QString &passwordHash, const QString &salt,
|
||||
const QString &username, qint32 roleId,
|
||||
qint32 userId)
|
||||
: passwordHash_(passwordHash), roleId_(roleId), salt_(salt),
|
||||
userId_(userId), username_(username) {}
|
||||
|
||||
// Setters (inline methods)
|
||||
inline void setUserId(qint32 userId) { userId_ = userId; }
|
||||
inline void setUsername(const QString &username) { username_ = username; }
|
||||
inline void setPasswordHash(const QString &passwordHash) {
|
||||
passwordHash_ = passwordHash;
|
||||
}
|
||||
inline void setSalt(const QString &salt) { salt_ = salt; }
|
||||
inline void setRoleId(qint32 roleId) { roleId_ = roleId; }
|
||||
|
||||
// Getters (inline methods)
|
||||
inline qint32 userId() const { return userId_; }
|
||||
inline QString username() const { return username_; }
|
||||
inline QString passwordHash() const { return passwordHash_; }
|
||||
inline QString salt() const { return salt_; }
|
||||
inline qint32 roleId() const { return roleId_; }
|
||||
};
|
||||
|
||||
#endif // UPDATE_USER_REQUEST_H
|
||||
Reference in New Issue
Block a user