Mercurial > gemma
view pkg/imports/wg.go @ 1903:7247ac316cb7 dev-pdf-generation
client: pdf-gen: improve layout and ui
* Remove download or display options, because they are not working anyway.
* Add page info and about box.
* Use a fixed generic logo text image and a placer holder text for the
disclaimer.
* Add string to translation files.
* Adjust scale bar layout.
author | Bernhard Reiter <bernhard@intevation.de> |
---|---|
date | Fri, 18 Jan 2019 16:52:20 +0100 |
parents | 77582da3adb0 |
children | 7ee9bdaac336 |
line wrap: on
line source
// This is Free Software under GNU Affero General Public License v >= 3.0 // without warranty, see README.md and license for details. // // SPDX-License-Identifier: AGPL-3.0-or-later // License-Filename: LICENSES/AGPL-3.0.txt // // Copyright (C) 2018 by via donau // – Österreichische Wasserstraßen-Gesellschaft mbH // Software engineering by Intevation GmbH // // Author(s): // * Sascha L. Teichmann <sascha.teichmann@intevation.de> package imports import ( "context" "database/sql" "errors" "gemma.intevation.de/gemma/pkg/common" ) type WaterwayGauge struct { // URL is the URL of the SOAP service. URL string `json:"url"` // Username is the username used to authenticate. Username string `json:"username"` // Passwort is the password to authenticate. Password string `json:"password"` // Insecure indicates if HTTPS traffic // should validate certificates or not. Insecure bool `json:"insecure"` } const WGJobKind JobKind = "wg" type wgJobCreator struct{} func init() { RegisterJobCreator(WGJobKind, wgJobCreator{}) } func (wgJobCreator) Description() string { return "waterway gauges" } func (wgJobCreator) AutoAccept() bool { return false } func (wgJobCreator) Create(_ JobKind, data string) (Job, error) { wg := new(WaterwayGauge) if err := common.FromJSONString(data, wg); err != nil { return nil, err } return wg, nil } func (wgJobCreator) Depends() []string { return []string{ "gauges", } } func (wgJobCreator) StageDone( ctx context.Context, tx *sql.Tx, id int64, ) error { // TODO: Implement me! return nil } func (*WaterwayGauge) CleanUp() error { return nil } func (wg *WaterwayGauge) Do( ctx context.Context, importID int64, conn *sql.Conn, feedback Feedback, ) (interface{}, error) { // TODO: Implement me! return nil, errors.New("Not implemented, yet!") }