Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ include:

.node-actions:
- gls-action
- shopify-action

test-node:
image: node:24.10.0
Expand Down
8 changes: 4 additions & 4 deletions actions/gls-action/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion actions/gls-action/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"start": "node dist/index.js"
},
"dependencies": {
"@code0-tech/hercules": "^1.0.2",
"@code0-tech/hercules": "^1.0.3",
"axios": "^1.7.7"
},
"devDependencies": {
Expand Down
4 changes: 2 additions & 2 deletions actions/gls-action/src/data_types/glsCustomContent.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ import { DisplayMessage, Identifier, Name, Schema } from "@code0-tech/hercules";
import { z } from "zod";

export const CustomContentSchema = z.object({
CustomerLogo: z.string(),
BarcodeContentType: z.enum(["TRACK_ID", "GLS_SHIPMENT_REFERENCE"]),
CustomerLogo: z.string().nullish(),
BarcodeContentType: z.enum(["TRACK_ID", "GLS_SHIPMENT_REFERENCE"]).nullish(),
Barcode: z.string().nullish(),
BarcodeType: z.enum(["EAN_128", "CODE_39"]).nullish(),
HideShipperAddress: z.boolean().nullish(),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import {
import {CustomContent} from "../../data_types/glsCustomContent.js";

@Identifier("createCustomContent")
@Signature("(barcodeContentType: \"TRACK_ID\"|\"GLS_SHIPMENT_REFERENCE\", customerLogo: string, hideShipperAddress?: boolean, barcodeType?: \"EAN_128\"|\"CODE_39\", barcode?: string): GLS_CUSTOM_CONTENT")
@Signature("(barcodeContentType?: \"TRACK_ID\"|\"GLS_SHIPMENT_REFERENCE\", customerLogo?: string, hideShipperAddress?: boolean, barcodeType?: \"EAN_128\"|\"CODE_39\", barcode?: string): GLS_CUSTOM_CONTENT")
@Name({code: "en-US", content: "Create GLS custom label content"})
@DisplayIcon("codezero:gls")
@DisplayMessage({code: "en-US", content: "Create GLS custom label content"})
Expand All @@ -25,6 +25,7 @@ import {CustomContent} from "../../data_types/glsCustomContent.js";
})
@Parameter({
runtimeName: "barcodeContentType",
optional: true,
name: [{code: "en-US", content: "Barcode content type"}],
description: [{
code: "en-US",
Expand All @@ -33,29 +34,33 @@ import {CustomContent} from "../../data_types/glsCustomContent.js";
})
@Parameter({
runtimeName: "customerLogo",
optional: true,
name: [{code: "en-US", content: "Customer logo"}],
description: [{code: "en-US", content: "Base64-encoded customer logo to print on the label."}],
})
@Parameter({
runtimeName: "hideShipperAddress",
optional: true,
name: [{code: "en-US", content: "Hide shipper address"}],
description: [{code: "en-US", content: "Whether to hide the shipper address on the label."}],
})
@Parameter({
runtimeName: "barcodeType",
optional: true,
name: [{code: "en-US", content: "Barcode type"}],
description: [{code: "en-US", content: "Type of barcode to use (EAN_128 or CODE_39)."}],
})
@Parameter({
runtimeName: "barcode",
optional: true,
name: [{code: "en-US", content: "Barcode"}],
description: [{code: "en-US", content: "Barcode value to print on the label."}],
})
export class CreateCustomContentFunction {
run(
_context: unknown,
barcodeContentType: CustomContent["BarcodeContentType"],
customerLogo: string,
barcodeContentType?: CustomContent["BarcodeContentType"],
customerLogo?: string,
hideShipperAddress?: boolean,
barcodeType?: CustomContent["BarcodeType"],
barcode?: string
Expand Down
3 changes: 3 additions & 0 deletions actions/shopify-action/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
.env
node_modules/
dist/
13 changes: 13 additions & 0 deletions actions/shopify-action/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
FROM node:24-alpine

WORKDIR /app

COPY package.json package-lock.json* ./

RUN npm install

COPY . .

RUN npm run build

CMD ["npm", "run", "start"]
Empty file.
Loading