Comments (5)
To disable timestamps, just add a config file .sequelize-auto.cfg.js with
module.exports = { timestamps: false }
and then execute your sequelize-auto command with options
-a .sequelize-auto.cfg.js
and it should work.
from sequelize-auto.
Somehow now it worked, go figure.
from sequelize-auto.
Glad to that it's working for you.. the additional configs should allow more options for you (-c/--config
) which you would enter in options within the define
property of that.
https://sequelize.readthedocs.org/en/latest/api/sequelize/
from sequelize-auto.
Yes, I didn't got how the -c and the -a worked, just got into the code for a minute and understood how it works. Pretty simple. Used the same -a flag with the exactly the same json and it worked.
from sequelize-auto.
I have the opposite problem :) I have about 150 MySQL table, and in all of them the createdAt
field is known as created
and the updatedAt
field is known as modified
. Is there an option that I missed in sequelize-auto
so that it automatically creates:
sequelize.define(name, { ... }, { createdAt: 'created', updatedAt: modified'});
for my 150+ models?
Thank you for the great work.
from sequelize-auto.
Related Issues (20)
- Dead link in -c / -config HOT 1
- build.test can never be red
- Treat a single column, nonnull unique index as a primary key if no primary key was found
- New dialects in sequelize 6.x break the ts build in sequelize-auto
- Using --noAlias still keeps the name of association property as if it was aliased HOT 1
- allow catching errors from SequelizeAuto.run()
- Cannot generate model from existing PostgreSQL database
- JSDoc for commonJS models
- Setting paranoid property for particular tables only
- createdAt / updateAt in table; missing in Model with timestamps = true; Postgres HOT 1
- support for overriding entity name, suppressing extra metadata such as *Mixin, InitModel, ?, ! and others
- Simplification proposal for the output formats. HOT 1
- Using getAttributes to re-initialize models with customizations (getters/setters)
- Documentation for additional option ?
- how to generate model for V7 format HOT 1
- Text default value not escaped when extracted from custom type
- Option to separate typescript definition to a file
- How to use imports and exports HOT 2
- install pg module manually
- unknown bug on sequelize auto HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sequelize-auto.