Compare commits

...

18 Commits

Author SHA1 Message Date
bfc646c308 1.0.18 2017-11-09 12:41:51 +01:00
ab008d16e8 break out address from contact 2017-11-09 12:41:49 +01:00
7f5b86864d 1.0.17 2017-11-09 12:13:29 +01:00
825148442b update Invoice interface 2017-11-09 12:13:27 +01:00
2a18ec1555 1.0.16 2017-11-09 02:20:25 +01:00
c5284ff813 update internal structure 2017-11-09 02:20:21 +01:00
498934237d 1.0.15 2017-11-09 02:17:00 +01:00
ac73badd76 update ci 2017-11-09 02:16:56 +01:00
90698230ae 1.0.14 2017-11-09 02:06:12 +01:00
04f37d5665 update ci 2017-11-09 02:06:08 +01:00
0f26791ee2 1.0.13 2017-11-09 01:46:49 +01:00
34e65462e2 start invoice interface 2017-11-09 01:46:45 +01:00
f55ac65e20 1.0.12 2017-06-11 20:57:32 +02:00
474ce92b88 update structure 2017-06-11 20:57:30 +02:00
de95e03699 1.0.11 2017-06-11 20:54:17 +02:00
1e4adeede6 structure + dns record type 2017-06-11 20:54:06 +02:00
ca67505870 1.0.10 2017-06-10 12:48:16 +02:00
18eabb11af update compilation 2017-06-10 12:48:11 +02:00
30 changed files with 158 additions and 38 deletions

View File

@ -7,60 +7,75 @@ cache:
key: "$CI_BUILD_STAGE"
stages:
- mirror
- test
- release
- trigger
- pages
mirror:
stage: mirror
script:
- npmci git mirror
tags:
- docker
testLEGACY:
stage: test
script:
- npmci test legacy
- npmci node install legacy
- npmci npm install
- npmci npm test
coverage: /\d+.?\d+?\%\s*coverage/
tags:
- docker
- docker
allow_failure: true
testLTS:
stage: test
script:
- npmci test lts
- npmci node install lts
- npmci npm install
- npmci npm test
coverage: /\d+.?\d+?\%\s*coverage/
tags:
- docker
- docker
testSTABLE:
stage: test
script:
- npmci test stable
- npmci node install stable
- npmci npm install
- npmci npm test
coverage: /\d+.?\d+?\%\s*coverage/
tags:
- docker
- docker
release:
stage: release
script:
- npmci publish
- npmci npm prepare
- npmci npm publish
only:
- tags
- tags
tags:
- docker
- docker
trigger:
stage: trigger
script:
- npmci trigger
- npmci trigger
only:
- tags
- tags
tags:
- docker
- docker
pages:
image: hosttoday/ht-docker-node:npmci
stage: pages
script:
- npmci command yarn global add npmpage
- npmci command npmpage --publish gitlab
- npmci command npmpage
tags:
- docker
only:

8
dist/business/address.d.ts vendored Normal file
View File

@ -0,0 +1,8 @@
export interface IAddress {
name?: string;
streetName: string;
houseNumber: string;
postalCode: string;
city: string;
country: string;
}

3
dist/business/address.js vendored Normal file
View File

@ -0,0 +1,3 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYWRkcmVzcy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uL3RzL2J1c2luZXNzL2FkZHJlc3MudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiJ9

View File

@ -1,4 +1,4 @@
import { IDate } from './index';
import { IDate } from '../index';
/**
* describes a company's lifecycle state
*/

View File

@ -1,3 +1,3 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29tcGFueS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uL3RzL2NvbXBhbnkudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiJ9
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29tcGFueS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uL3RzL2J1c2luZXNzL2NvbXBhbnkudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiJ9

13
dist/business/contact.d.ts vendored Normal file
View File

@ -0,0 +1,13 @@
import { IAddress } from '../index';
export declare type TContactSalutation = 'Mr' | 'Ms' | 'Mrs';
export declare type TContactType = 'person' | 'company';
export declare type TContactTitle = 'Doctor' | 'Professor';
export interface IContact {
salutation?: TContactSalutation;
type: TContactType;
title: TContactTitle;
name: string;
address: IAddress;
vatId?: string;
accountNumber?: string;
}

3
dist/business/contact.js vendored Normal file
View File

@ -0,0 +1,3 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29udGFjdC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uL3RzL2J1c2luZXNzL2NvbnRhY3QudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiJ9

14
dist/business/invoice.d.ts vendored Normal file
View File

@ -0,0 +1,14 @@
import { IContact } from '../index';
export declare type TInvoiceStatus = 'draft' | 'invoice' | 'paid' | 'refunded';
export interface IInvoiceItem {
name: string;
unitType: string;
quantity: number;
vatPercentage: number;
}
export interface IInvoice {
billedBy: IContact;
billedTo: IContact;
status: TInvoiceStatus;
items: IInvoiceItem[];
}

View File

@ -1,3 +1,3 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW52b2ljZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uL3RzL2ludm9pY2UudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiJ9
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW52b2ljZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uL3RzL2J1c2luZXNzL2ludm9pY2UudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiJ9

1
dist/cloud/dns.d.ts vendored Normal file
View File

@ -0,0 +1 @@
export declare type TDnsRecord = 'A' | 'AAAA' | 'CNAME' | 'TXT' | 'SRV' | 'LOC' | 'MX' | 'NS' | 'SPF';

3
dist/cloud/dns.js vendored Normal file
View File

@ -0,0 +1,3 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZG5zLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vdHMvY2xvdWQvZG5zLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiIifQ==

View File

@ -1,4 +1,4 @@
import { IAuthor } from './author';
import { IAuthor } from '../index';
export interface IArticle {
/**
* the title of an article

View File

@ -1,3 +1,3 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYXJ0aWNsZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uL3RzL2FydGljbGUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiJ9
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYXJ0aWNsZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uL3RzL2NvbnRlbnQvYXJ0aWNsZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiIn0=

View File

@ -1,5 +1,5 @@
import { IDate } from './date';
import { IArticle } from './article';
import { IDate } from '../index';
import { IArticle } from '../index';
export interface IAuthor {
/**
* the first name of an author

View File

@ -1,3 +1,3 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYXV0aG9yLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vdHMvYXV0aG9yLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiIifQ==
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYXV0aG9yLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vdHMvY29udGVudC9hdXRob3IudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiJ9

View File

@ -1,3 +1,3 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGF0ZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uL3RzL2RhdGUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiJ9
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGF0ZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uL3RzL2dlbmVyYWwvZGF0ZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiIn0=

View File

@ -1,3 +1,3 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidGltZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uL3RzL3RpbWUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiJ9
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidGltZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uL3RzL2dlbmVyYWwvdGltZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiIn0=

15
dist/index.d.ts vendored
View File

@ -1,6 +1,9 @@
export * from './article';
export * from './author';
export * from './company';
export * from './date';
export * from './invoice';
export * from './time';
export * from './business/address';
export * from './business/company';
export * from './business/contact';
export * from './business/invoice';
export * from './cloud/dns';
export * from './content/article';
export * from './content/author';
export * from './general/date';
export * from './general/time';

2
dist/invoice.d.ts vendored
View File

@ -1,2 +0,0 @@
export interface IInvoice {
}

0
docs/index.md Normal file
View File

View File

@ -1,6 +1,6 @@
{
"npmci": {
"globalNpmTools": [
"npmGlobalTools": [
"npmts"
]
}

View File

@ -1,11 +1,11 @@
{
"name": "tsclass",
"version": "1.0.9",
"version": "1.0.18",
"description": "common classes for TypeScript",
"main": "dist/index.js",
"typings": "dist/index.d.ts",
"scripts": {
"test": "(npmts)"
"test": "(npmts --notest)"
},
"repository": {
"type": "git",
@ -20,5 +20,6 @@
"bugs": {
"url": "https://github.com/tsclass/tsclass/issues"
},
"homepage": "https://github.com/tsclass/tsclass#readme"
"homepage": "https://github.com/tsclass/tsclass#readme",
"dependencies": {}
}

8
ts/business/address.ts Normal file
View File

@ -0,0 +1,8 @@
export interface IAddress {
name?: string
streetName: string
houseNumber: string
postalCode: string
city: string
country: string
}

View File

@ -1,3 +1,4 @@
import { IContact } from '../index'
import { IDate } from '../index'
/**

24
ts/business/contact.ts Normal file
View File

@ -0,0 +1,24 @@
import { IAddress } from '../index'
export type TContactSalutation = 'Mr' | 'Ms' | 'Mrs'
export type TContactType = 'person' | 'company'
export type TContactTitle = 'Doctor' | 'Professor'
export interface IContact {
// =======
// general
// =======
salutation?: TContactSalutation
type: TContactType
title: TContactTitle
name: string
address: IAddress
// =========
// financial
// =========
vatId?: string
accountNumber?: string
}

View File

@ -1,3 +1,17 @@
export interface IInvoice {
import { IContact } from '../index'
export type TInvoiceStatus = 'draft' | 'invoice' | 'paid' | 'refunded'
export interface IInvoiceItem {
name: string
unitType: string
quantity: number
vatPercentage: number
}
export interface IInvoice {
billedBy: IContact
billedTo: IContact
status: TInvoiceStatus,
items: IInvoiceItem[]
}

View File

@ -0,0 +1 @@
export type TDnsRecord = 'A' | 'AAAA' | 'CNAME' | 'TXT' | 'SRV' | 'LOC' | 'MX' | 'NS' | 'SPF'

View File

@ -1,6 +1,16 @@
// Business
export * from './business/address'
export * from './business/company'
export * from './business/contact'
export * from './business/invoice'
// Cloud
export * from './cloud/dns'
// Content
export * from './content/article'
export * from './content/author'
export * from './business/company'
// General
export * from './general/date'
export * from './business/invoice'
export * from './general/time'