job

package
v2.0.0-alpha.21 Latest Latest
Warning

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

Go to latest
Published: Nov 5, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetTotalJobsCount

func GetTotalJobsCount(dbConnPgx utils.PgxIface) (*int, error)

func InsertJob

func InsertJob(dbConnPgx utils.PgxIface, job *Job) (int, string, error)

func InsertJobList

func InsertJobList(dbConnPgx utils.PgxIface, jobList []Job) error

func RemoveJob

func RemoveJob(dbConnPgx utils.PgxIface, jobID *int) error

func UpdateJob

func UpdateJob(dbConnPgx utils.PgxIface, job *Job) error

Types

type Attrs

type Attrs map[string]interface{}

func (*Attrs) Scan

func (a *Attrs) Scan(value interface{}) error

func (Attrs) Value

func (a Attrs) Value() (driver.Value, error)

type Job

type Job struct {
	ID               *int      `json:"id" db:"id"`                               //1
	UUID             string    `json:"uuid" db:"uuid"`                           //2
	Name             string    `json:"name" db:"name"`                           //3
	AlternateName    string    `json:"alternateName" db:"alternate_name"`        //4
	StartDate        time.Time `json:"startDate" db:"start_date"`                //5
	EndDate          time.Time `json:"endDate" db:"end_date"`                    //6
	Description      string    `json:"description" db:"description"`             //7
	StatusID         *int      `json:"statusId" db:"status_id"`                  //8
	ResponseStatus   string    `json:"responseStatus" db:"response_status"`      //9
	RequestUrl       string    `json:"requestUrl" db:"request_url"`              //10
	RequestBody      string    `json:"requestBody" db:"request_body"`            //11
	RequestMethod    string    `json:"requestMethod" db:"request_method"`        //12
	ResponseData     string    `json:"responseData" db:"response_data"`          //13
	ResponseDataJson Attrs     `json:"responseDataJson" db:"response_data_json"` //14
	JobCategoryID    *int      `json:"jobCategoryId" db:"job_category_id"`       //15
	CreatedBy        string    `json:"createdBy" db:"created_by"`                //16
	CreatedAt        time.Time `json:"createdAt" db:"created_at"`                //17
	UpdatedBy        string    `json:"updatedBy" db:"updated_by"`                //18
	UpdatedAt        time.Time `json:"updatedAt" db:"updated_at"`                //19
}

Job

func GetJob

func GetJob(dbConnPgx utils.PgxIface, jobID *int) (*Job, error)

func GetJobList

func GetJobList(dbConnPgx utils.PgxIface, ids []int) ([]Job, error)

func GetJobListByPagination

func GetJobListByPagination(dbConnPgx utils.PgxIface, _start, _end *int, _order, _sort string, _filters []string) ([]Job, error)

for refinedev

func GetJobListByUUIDs

func GetJobListByUUIDs(dbConnPgx utils.PgxIface, UUIDList []string) ([]Job, error)

func GetStartAndEndDateDiffJobList

func GetStartAndEndDateDiffJobList(dbConnPgx utils.PgxIface, diffInDate *int) ([]Job, error)

Jump to

Keyboard shortcuts

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