web

package
v1.1.1-alpha Latest Latest
Warning

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

Go to latest
Published: Dec 16, 2021 License: Apache-2.0 Imports: 4 Imported by: 11

Documentation

Index

Constants

View Source
const (
	AdminAuthorityId   uint = 1 // 管理员用户
	TenancyAuthorityId uint = 2 // 商户用户
	LiteAuthorityId    uint = 3 // 小程序用户
	DeviceAuthorityId  uint = 4 // 床旁设备用户
)

Variables

This section is empty.

Functions

func Start

func Start(wf WebFunc)

Start 启动 web 服务

func StartTest

func StartTest(wf WebFunc)

StartTest 启动 web 服务

Types

type WebFunc

type WebFunc interface {
	GetTestClient(t *testing.T) *httptest.Client
	GetTestLogin(t *testing.T, url string, res httptest.Responses, datas ...interface{}) *httptest.Client

	AddWebStatic()
	AddUploadStatic()
	InitDriver() error
	InitRouter() error
	Run()
}

WebFunc 框架服务接口 - GetTestClient 测试客户端 - GetTestLogin 测试登录 - AddWebStatic 添加静态页面 - InitDriver 初始化认证 - AddUploadStatic 上传文件路径 - Run 启动

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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