Skip to content
This repository has been archived by the owner on May 11, 2022. It is now read-only.

Commit

Permalink
wrap all drafts by comment
Browse files Browse the repository at this point in the history
  • Loading branch information
kamilsk committed Oct 10, 2018
1 parent 00522d1 commit 020a5c1
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 6 deletions.
2 changes: 1 addition & 1 deletion pkg/storage/draft.go
Expand Up @@ -90,4 +90,4 @@ func (storage *Storage) PushWorkplace(ctx context.Context, id domain.Token, data
return storage.exec.Draft(ctx, conn).PushWorkplace(token, data)
}

// }
// issue#draft }
1 change: 0 additions & 1 deletion pkg/storage/draft_test.go

This file was deleted.

6 changes: 3 additions & 3 deletions pkg/storage/executor/api.go
Expand Up @@ -33,7 +33,7 @@ func New(dialect string) *Executor {
exec.factory.NewDraft = func(ctx context.Context, conn *sql.Conn) Draft {
return postgres.NewLicenseContext(ctx, conn)
}
// }
// issue#draft }

case mysqlDialect:
fallthrough
Expand Down Expand Up @@ -78,7 +78,7 @@ type Executor struct {

// TODO issue#draft {
NewDraft func(context.Context, *sql.Conn) Draft
// }
// issue#draft }
}
}

Expand Down Expand Up @@ -118,4 +118,4 @@ type Draft interface {
PushWorkplace(*repository.Token, query.LicenseWorkplace) error
}

// }
// issue#draft }
4 changes: 4 additions & 0 deletions pkg/storage/executor/internal/postgres/draft.go
Expand Up @@ -7,6 +7,8 @@ import (
"github.com/kamilsk/guard/pkg/storage/query"
)

// TODO issue#draft {

// AddEmployee TODO issue#docs
func (scope licenseManager) AddEmployee(token *repository.Token, data query.LicenseEmployee) error {
license, readErr := scope.Read(token, query.ReadLicense{ID: data.ID})
Expand Down Expand Up @@ -89,3 +91,5 @@ func (scope licenseManager) PushWorkplace(token *repository.Token, data query.Li
}
return nil
}

// issue#draft }
1 change: 0 additions & 1 deletion pkg/storage/executor/internal/postgres/draft_test.go

This file was deleted.

4 changes: 4 additions & 0 deletions pkg/transport/grpc/license.proto
Expand Up @@ -119,6 +119,8 @@ service License {
};
}

// TODO issue#draft {

rpc AddEmployee (EmployeeRequest) returns (EmptyResponse) {
option (google.api.http) = {
post: "/api/v1/license/{id}/employee/{employee}"
Expand Down Expand Up @@ -158,3 +160,5 @@ message WorkplaceRequest {
string id = 1;
string workplace = 2;
}

// issue#draft }

0 comments on commit 020a5c1

Please sign in to comment.