utility

package
v0.0.0-...-1305305 Latest Latest
Warning

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

Go to latest
Published: Jun 30, 2021 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

View Source
const CSV_Head_Delimiter = "/"
View Source
const CSV_Value_Delimiter = ";"

Variables

View Source
var GeoType = []string{"point", "area"}
View Source
var LOGGER = logging.MustGetLogger("payout-service")
View Source
var ReceiveMode = []string{"cash_pickup", "bank_account", "mobile", "delivery", "agency_pickup"}

Functions

func Contains

func Contains(a []string, x string) bool

func ContainsPoint

func ContainsPoint(ids []string, candidatePoints map[string][]model.Coordinate, requestCoordinate model.Coordinate) ([]string, error)

func CreateNode

func CreateNode(session neo4j.Session, payoutRq model.PayoutLocation) error

func CreateNodesByCSV

func CreateNodesByCSV(session neo4j.Session, payoutRqs []model.PayoutLocation) error

func DeleteNode

func DeleteNode(session neo4j.Session, id string) error

func GenerateNodeID

func GenerateNodeID() string

func GetNode

func GetNode(session neo4j.Session, mapClient *maps.Client, id string, name string, payoutType string, image string, url string, telephone string, currency string, child string, parent string, member string, receiveMode string, country string, state string, city string, street string, postalCode string, address string, geo string) (interface{}, error)

func GraphDbInitialize

func GraphDbInitialize(driver neo4j.Driver) error

func IsValid

func IsValid(payload model.PayoutLocation) error

func Neo4jQueryPreprocess

func Neo4jQueryPreprocess(bytes []byte) (map[string]interface{}, error)

func UpdateNode

func UpdateNode(session neo4j.Session, updateRq model.PayoutLocationUpdateRequest) error

Types

This section is empty.

Jump to

Keyboard shortcuts

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