helpdesk

package module
v0.0.0-...-72cdf1b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 30, 2015 License: MIT Imports: 9 Imported by: 0

README

FKSE Helpdesk

RESTful helpdesk system writen in Go.

Installation

Soon..

MIT see LICENSE.md

Documentation

Index

Constants

This section is empty.

Variables

View Source
var AppRoutes = Routes{
	Route{
		"Index",
		"GET",
		"/",
		controller.DefaultIndex,
	},

	Route{
		"UserList",
		"GET",
		"/users",
		controller.UserList,
	},
	Route{
		"UserCreate",
		"POST",
		"/users",
		controller.UserCreate,
	},
	Route{
		"UserShow",
		"GET",
		"/users/{id:[0-9+]}",
		controller.UserShow,
	},
	Route{
		"UserUpdate",
		"PUT",
		"/users/{id:[0-9+]}",
		controller.UserUpdate,
	},
	Route{
		"UserDelete",
		"DELETE",
		"/users/{id:[0-9+]}",
		controller.UserDelete,
	},
}

Functions

func NewRouter

func NewRouter() (r *mux.Router)

Create and populate router

func RequestLogger

func RequestLogger(h http.Handler, name string) http.Handler

Request logging middleware

func RequestSetup

func RequestSetup(h http.Handler) http.Handler

Request setup

func Run

func Run(c *Configuration)

Types

type ConfigDatabase

type ConfigDatabase struct {
	Driver   string
	Host     string
	Database string
	User     string
	Password string
}

func (*ConfigDatabase) ConnectionString

func (c *ConfigDatabase) ConnectionString() (s string)

type Configuration

type Configuration struct {
	Port     int
	Database ConfigDatabase
}

type Route

type Route struct {
	Name        string
	Method      string
	Pattern     string
	HandlerFunc http.HandlerFunc
}

type Routes

type Routes []Route

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL