update profile and models
This commit is contained in:
@@ -0,0 +1,56 @@
|
||||
const Sequelize = require('sequelize');
|
||||
module.exports = function(sequelize, DataTypes) {
|
||||
return sequelize.define('SingaporeBuildings', {
|
||||
id: {
|
||||
autoIncrement: true,
|
||||
type: DataTypes.INTEGER,
|
||||
allowNull: false,
|
||||
primaryKey: true
|
||||
},
|
||||
address: {
|
||||
type: DataTypes.STRING(150),
|
||||
allowNull: false
|
||||
},
|
||||
blk_no: {
|
||||
type: DataTypes.STRING(10),
|
||||
allowNull: true
|
||||
},
|
||||
building: {
|
||||
type: DataTypes.STRING(100),
|
||||
allowNull: true
|
||||
},
|
||||
latitude: {
|
||||
type: DataTypes.DECIMAL,
|
||||
allowNull: true
|
||||
},
|
||||
longitude: {
|
||||
type: DataTypes.DECIMAL,
|
||||
allowNull: true
|
||||
},
|
||||
postal: {
|
||||
type: DataTypes.STRING(6),
|
||||
allowNull: false
|
||||
},
|
||||
road_name: {
|
||||
type: DataTypes.STRING(40),
|
||||
allowNull: false
|
||||
},
|
||||
searchval: {
|
||||
type: DataTypes.STRING(100),
|
||||
allowNull: false
|
||||
},
|
||||
x: {
|
||||
type: DataTypes.DECIMAL,
|
||||
allowNull: true
|
||||
},
|
||||
y: {
|
||||
type: DataTypes.DECIMAL,
|
||||
allowNull: true
|
||||
}
|
||||
}, {
|
||||
sequelize,
|
||||
tableName: 'singapore_buildings',
|
||||
schema: 'public',
|
||||
timestamps: false
|
||||
});
|
||||
};
|
||||
Reference in New Issue
Block a user