Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ConfigController ¶
type ConfigController struct {
controller.BaseController
Input ReportRequest
Employee *model.Employee
// contains filtered or unexported fields
}
func NewConfigController ¶
func NewConfigController(ctx *controller.BaseController) *ConfigController
func (*ConfigController) ProcessInput ¶
func (c *ConfigController) ProcessInput() error
func (*ConfigController) ShowConfigurationForm ¶
func (c *ConfigController) ShowConfigurationForm() error
type ConfigView ¶
type ConfigView struct {
// contains filtered or unexported fields
}
func (*ConfigView) GetConfigurationValues ¶
func (v *ConfigView) GetConfigurationValues() controller.Values
type ReportRequest ¶
type ReportRequest struct {
Year int `param:"year" form:"year"`
Month int `param:"month" form:"month"`
SearchUser string `form:"username"`
SearchUserEnabled bool
EmployeeReportEnabled bool
EmployeeID int `param:"employee"`
}
ReportRequest contains all relevant input data for generating reports.
func (*ReportRequest) FromRequest ¶
func (i *ReportRequest) FromRequest(e echo.Context) error
FromRequest parses the properties based on the given request echo.Context.
func (ReportRequest) GetFirstDayOfMonth ¶
func (i ReportRequest) GetFirstDayOfMonth() time.Time
GetFirstDayOfMonth returns the first day of the ReportRequest.Month in time.UTC at midnight.
func (ReportRequest) GetFirstDayOfNextMonth ¶
func (i ReportRequest) GetFirstDayOfNextMonth() time.Time
GetFirstDayOfNextMonth returns the last day of the ReportRequest.Month in time.UTC.
func (ReportRequest) GetLastDayFromPreviousMonth ¶
func (i ReportRequest) GetLastDayFromPreviousMonth() time.Time
GetLastDayFromPreviousMonth returns GetFirstDayOfMonth subtracted by 1 day.
func (ReportRequest) GetLastDayOfMonth ¶
func (i ReportRequest) GetLastDayOfMonth() time.Time
GetLastDayOfMonth returns the last day of the ReportRequest.Month in time.UTC at midnight.
Click to show internal directories.
Click to hide internal directories.