1.1.6 • Published 6 years ago

stopllc_oracle v1.1.6

Weekly downloads
1
License
ISC
Repository
-
Last release
6 years ago

STOLLC ORACLE HELPERS

A small library that helps maintain stopllc oracle helpers

Installation

npm install --save stopllc_oracle

Usage ES6 style

import BaseModel from 'stopllc_oracle/lib/BaseModel';

const ClassName extends BaseModel {
  constructor(){
    //call super
    super(); //initiates default id field
    // define fields.
    // name = '';
  }
}

const className = new ClassName();
// create loopback data source
const read = className.readDataSource('schema');

read.find(); //loopback
className.write('schema'); //custom procedures
className.read('schema'); //custom read procedures

BASEMODEL overwritable methods

get readData() {
  // gets properties
  return this;
}

get ignoreRead() {
    return ['']; //ignores fields in array when reading using loopback .find()
}

get readProcData() {
  return this;
}

get writeData() {
  return this;
}

get readProcedureName() {
  //gets procedure name for oracle
  return this.constructor.name + 'ReadProc';
}

get procedureName() {
  //gets procedure name for oracle
  return this.constructor.name + 'Write';
}

get viewName() {
  //gets view name for oracle
  return this.constructor.name + 'Read';
}

get validate() {
  return true;
}
1.1.6

6 years ago

1.1.5

6 years ago

1.1.4

6 years ago

1.1.3

7 years ago

1.1.2

7 years ago

1.1.1

7 years ago

1.1.0

7 years ago

1.0.14

7 years ago

1.0.13

7 years ago

1.0.12

7 years ago

1.0.11

7 years ago

1.0.10

7 years ago

1.0.9

7 years ago

1.0.8

7 years ago

1.0.7

7 years ago

1.0.6

7 years ago

1.0.5

7 years ago

1.0.4

7 years ago

1.0.3

7 years ago

1.0.2

7 years ago

1.0.1

7 years ago

1.0.0

7 years ago