How to use the class-transformer.serialize function in class-transformer

To help you get started, we’ve selected a few class-transformer examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github google / crmint / frontend / src / app / jobs / shared / jobs.service.ts View on Github external
updateJob(job) {
    return this.http.put(this.getJobUrl(job.id), serialize(job), { headers: this.headers })
                    .toPromise()
                    .then(res => res.json())
                    .catch(this.handleError);
  }
github google / crmint / frontend / src / app / jobs / shared / jobs.service.ts View on Github external
addJob(job) {
    return this.http.post(this.url, serialize(job), { headers: this.headers })
                    .toPromise()
                    .then(res => res.json())
                    .catch(this.handleError);
  }