tsk-29: Change type of Response from MessageEventResponse (#35)
Closes #29 Reviewed-on: phoenix/textsender-models#35 Co-authored-by: phoenix <kundeng00@pm.me> Co-committed-by: phoenix <kundeng00@pm.me>
This commit is contained in:
@@ -25,7 +25,7 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
echo "Creating version"
|
echo "Creating version"
|
||||||
|
|
||||||
VERSION="0.1.1"
|
VERSION="0.1.3"
|
||||||
PROJECT_COMMIT_HASH=$(git rev-parse HEAD | cut -c 1-10)
|
PROJECT_COMMIT_HASH=$(git rev-parse HEAD | cut -c 1-10)
|
||||||
BRANCH_REF="${{ gitea.ref }}"
|
BRANCH_REF="${{ gitea.ref }}"
|
||||||
BRANCH_NAME=$(echo "$BRANCH_REF" | cut -d '/' -f 3)
|
BRANCH_NAME=$(echo "$BRANCH_REF" | cut -d '/' -f 3)
|
||||||
|
|||||||
@@ -4,17 +4,15 @@ import (
|
|||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/google/uuid"
|
"github.com/google/uuid"
|
||||||
|
|
||||||
"git.kundeng.us/phoenix/textsender-models/tx0/types"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type MessageEventResponse struct {
|
type MessageEventResponse struct {
|
||||||
Id uuid.UUID `json:"id,omitempty"`
|
Id uuid.UUID `json:"id,omitempty"`
|
||||||
ScheduledMessageEventId uuid.UUID `json:"scheduled_message_event_id,omitempty"`
|
ScheduledMessageEventId uuid.UUID `json:"scheduled_message_event_id,omitempty"`
|
||||||
Response types.JSONB `json:"response"`
|
Response map[string]any `json:"response"`
|
||||||
UserId uuid.UUID `json:"user_id,omitempty"`
|
UserId uuid.UUID `json:"user_id,omitempty"`
|
||||||
ContactId *uuid.UUID `json:"contact_id,omitempty"`
|
ContactId *uuid.UUID `json:"contact_id,omitempty"`
|
||||||
MessageId *uuid.UUID `json:"message_id,omitempty"`
|
MessageId *uuid.UUID `json:"message_id,omitempty"`
|
||||||
Status string `json:"status"`
|
Status string `json:"status"`
|
||||||
Sent time.Time `json:"sent"`
|
Sent time.Time `json:"sent"`
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -6,6 +6,7 @@ import (
|
|||||||
"fmt"
|
"fmt"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
// NOTE: Might end up removing this
|
||||||
type JSONB json.RawMessage
|
type JSONB json.RawMessage
|
||||||
|
|
||||||
// Scan implements sql.Scanner
|
// Scan implements sql.Scanner
|
||||||
|
|||||||
Reference in New Issue
Block a user