Changelog

  • 3.2.72018.02.28

    Fix this.fail TypeScript definition

    Support `this.post('a,b')` batch get parameter

    In Multi module Controller, `this.service` will search Service file from current module, then common module if not exist.

  • 3.2.62017.12.14

    Add config ts definition for Controller, Logic, Contex and Think

  • 3.2.52017.12.11

    Fix Logic TypeScript definition,Logic inherit all Controller methods.

  • 3.2.42017.11.14

    Fix bug with post data is Array type

    Fix typescript definition for some methods.

  • 3.2.32017.10.25

    Adjust think.app.controllers load order, to fix controller can not get service instance

    Fix typescript definition for some methods.

  • 3.2.22017.10.11

    Fix bug with dynamic config can not fetch through think.beforeStartServer.

    Support obtaining query data through ctx.request._query.

  • 3.2.12017.09.22

    Fix Logic TypeScript definition

    Fix jsonp request Content-Type issue,change to application/javascript

    Support process.env.THINK_UNIT_TEST enviroment variable, identified as unit test environemnt.

  • 3.2.02017.09.19

    Support TypeScript, comes with think-cli version of 1.1.0

  • 3.1.22017.09.12

    Fix model where method not filter some conditions that would cause security issues

  • 3.1.12017.09.06

    Fix isAgent method ivoke error

  • 3.1.02017.09.01

    Logic suport scope feature

    master no loader load extend

    add stickyCluster config

    Remove the default host of 127.0.0.1

    controller.redirect/controller.download return false

  • 3.0.02017.08.17

    release 3.0.0

  • 2.2.132016.10.14

    Create project default to multi-module project.(rollback changes)

    Fix some small issues in PostgreSQL.

    Default config database prefix to null.

    Fix bug with model inside relation model BELONG_TO will be deleted.

    Model buildSql method support if add bracket by parameter.

    Perfect d.ts

    Fix bug with parseType is enum or set.

    CSRF validation can confg by header

  • 2.2.122016.09.27

    Important update: Fix static resource access leak. (some problem is uncover in previous fix)

    Fix PostgreSQL case sensitive issue.

    Default project creation mode to normal and ES6.

  • 2.2.112016.09.14

    Fix bug with Logic auto add empty data.

    Header auto change to lowercase.

    Language auto change to lowercase.

    Add request timeout log

    Fix bug with model instantiation failed if name contains '/'.

  • 2.2.102016.08.25

    Fix bug with database add operation always return id value of 0.

    Fix database read and write abruption issue.

  • 2.2.92016.08.16

    Fix concurrect transaction issue.

    Fix controller fetch method's d.ts descrition issue.

    Fix mongo can't auto-connet after disconnect.

    Remove dynamic install mysql module.

  • 2.2.82016.08.04

    Fix bug with model can't customize.

    Replace node-mysql2 with node-mysql.

    Fix bug with fleeing transaction executing.

    Fix logic add empty default value issue.

    Fix SQLite addMany method return issue.

    Fix bug with cookie value is incorrect after the restart.

    Fix bug with if custom port instance failed to start, the error message is not correct.

    Mongo support ignore default value in update

    Add this.service in Service

  • 2.2.72016.07.28

    Fix bug with pathname can't be found in windows after being fixed.

    Default disable resource_on in production configuration.

  • 2.2.62016.07.28

    Fix PostgreSQL auto-escaping issue.

    Include src folder into install package.

    Fix bug with static resource access arbitrary file.

  • 2.2.52016.06.17

    Fix bug with memory Session timeout lose efficacy.

    Fix bug with think.isNumberString valide empty value return true.

    Fix bug with table field start with _ can't be recognized.

    Fix bug with auto configured DB file missing type causes error.

    Fix bug with SQLite transation syntax error

    Fix bug with DB connection sometimes can not re-connect after connection exceptions.

  • 2.2.42016.05.25

    Fix bug with use keyword as method field in modal increment and decrement method casues error.

    Fix postgreSQL error causes connection close.

    Fix bug with countSelect with order in postgreSQL causes error.

    Fux bug with statusAction larger than 600 result in error in some Node.js versions.

  • 2.2.32016.05.05

    Support dynamic set parameters in where or limit relational modal, and so on.

    Support manual configure Logic validation parameters

    Fix bug with int:0 type validation error.

    Fix bug with view_parse hook result may not be as expected.

  • 2.2.22016.04.27

    socket.io support namespace.

    Fix bug with socket.io config adapter is not working.

    Fix bug with error won't update in auto-compile mode.

    Fix bug with log color display issues in windows.

    http.getPayload support returning Buffer.

    mongo modal support beforeUpdate method.

    Modal supoort beforeSelect, beforeFind and beforeDelete method.

    Fix bug with can not get the right cookie right after set cookie.

    Fix bug with model not auto-update after table field name changed in develop environment.

    Replace node-mysql with node-mysql2 (performance increase times)

    Fix bug result in no warning wihout handle Project reject

    Add method thenUpdate for model.

    Add prop method for http object.

    Fix bug with new user's DB session exception.

    Fix bug with PostgreSQL insert can't get insertId.

    Update dependencies version.

  • 2.2.12016.03.30

    Fix bug with ThinkJS versioning on create project.

    Fix error path missing one hierarchy.

  • 2.2.02016.03.30

    Support ES2015+ Breakpoint Debugging.

    Support error message locate to src/ folder.

    Fix bug with can't fetch I18N error.

    Reomve default field value fetched from database, fix bug with modify specify value reports error.

    Fix bug with error info can't be clear if there are multiple compile errors on the same file.

    Remove retainLines compile option.

    Fix bug with different validation rule incorrect.

    Fix bug with File Session fetch empty content causes Session losed.

    Fix bug with addMany method returning the wrong value.

    Fix bug with empty rules in data validation result in error.

    Fix bug with mongo model aggregate method return incorrect value.

    Fix bug with afterDelete take no effect.

    Fix bug with type of BELONG_TO in Relation Model can't set fKey.

    Change log_sql default to off on production environemnt.

    Fix bug with metheds like sum with expression parameters report error.

    Fix bug with Mysql not recognize database encoding.

    Fix bug with postgresql field type can't be boolean.

  • 2.1.82016.03.15

    Fix bug with Mysql multi-connection reports Connection already Released error.

    Fix bug with create project path partialiy incorrect.

    Optimize when project start check module environment.

    Fix parseGroup with expression reports error.

    Add more error infomation when call non-exist Action.

  • 2.1.72016.03.01

    Fix bug with not properly handle Promise causes error message.

    Fix bug resulting in ObjectID can be class.

    Fix model schema default value not support nesting.

    Add log_error config to decide if print 500 error log.

  • 2.1.62016.02.25

    Fix bug with correlation model failed add due to missing part of data.

    Fix bug with database table name contains keyword reports error.

    Fix bug with model find method return multiple result in some conditions.

    Fix bug with file upload failed causes request can not be ended.

    Remove listening to unhandledRejection event.

    Fix bug with fetch method missing config parameter.

  • 2.1.52016.02.04

    Add think.datetime, think.isFileAsync, think.isDirAsync method.

    Improve uploaded data parsing.

    Fix when creating project, the display project command may be incorrect.

    Fix bug with ID return by Mongo is not a string

    Fix bug with template confiure parsing error

  • 2.1.42016.01.22

    Support default value on data modal update.

    Support trim on data validation.

    Support pre-load on service start, production mode default to turn on.

    nunjucks template now use asynchronous rendering.

    Support genertate test/ foloder on creating project.

    Fix bug with windows not supporting multi-level controller.

    Fix bug with detect project type failed on first compile.

    Fix bug with addMany reports error.

    Fix bug with regx validation on null value casue error.

    Fix bug with SQLite connection data name incorrect.

  • 2.1.32016.01.19

    Added think.isMaster property.

    Service class added method model.

    think.base added method parseModuleFromPath.

    Fix bug with parsing model default value incorrect.

    Fix bug when model where condition is string, add another condition will causes error.

  • 2.1.22016.01.15

    Add --allowSyntheticDefaultImports parameters for TypeScript compiling.

    Fix bug with creating TypeScript project error if file name suffix is not .ts.

  • 2.1.12016.01.15

    Fix bug with database prefix not working.

    Added support Babel set presets and plugins.

    Fix bug with multiple hierachy controller can't be found.

    Added deprected method getTableFields to compatible with former version.

    Fix bug with baseAssign overrides custom settings.

    Fix bug with missing think.RUNTIME_PATH causes path incorrect.

  • 2.1.02016.01.14

    Support TypeScript, see details here.

    Performance increase 90%, better than Koa and express, see benchmark here.

    Added support Controller sub-folder.

    Added support PostgreSQL database.

    Added support set default value in Model schema.

    Change Hook middleware return null will block the rest middleware.

    Added alias method render for http and controller display.

    Added synchronous method think.waterfall.

    Added support Validate with Regex.

    Added support transmit data with fetch.

    Added support Logic to get request type.

    Added support timed task can directly invoke action.

    Upgrade Babel to 6.

    Locale name is not case sensiive.

    Change to asynchronous fetch template file content.

    http object no longer inherit from EventEmitter.

    Drop think.mode_mini mode, controller support sub-folder.

    Rename name to database in database setting.

    Rename fields to schema.

    Rename pwd to password in database setting.

    Optimize http object creation, no need to copy each time.

    Filtered hidden file types like .svn, .git etc.

    Move bin/index.js to src/command.js.

    Move runtime folder to project root, added think.RUNTIME_PATH constant.

    Added support to auto lower case adapter type, with prompt.

    Added thinkData, for frequently-used data caching.

    Combine think.locale and controller.locale.

    Fix bug with nunjucks inherit file can't be found.

    Fix bug with escaped / in pathname causes parsing error.

    Fix bug with modifying data response by http.file will causes source data being modified.

    Add support path / no need to change to \\ in windows.

    Fix bug resulting in nunjucks can place template files not only in root folder.

    Added on production mode, prevent the page from outputting sensitive data.

    Added on development mode, JSON parse failed message will be logged for debugging.

    Fix bug resulting in on view root_path changed will also update the view path.

    Fix bug with incorect required|int rule validation.

    Fix bug with redis cache parsing settings.

    Fix bug resulting in REST API can support logic.

    Fix bug with count method failed when parameter name is keyword.

  • 2.0.162016.01.08

    Added support think.parseConfig method support context.

  • 2.0.152015.12.25

    Fix bug with setting nunjucks root_path logic failing.

  • 2.0.142015.12.25

    Added support MongoDB with multiple host configures.

    Fix bug with nunjucks root_path setting.

    Added support on development mode, print the payload parsing error message.

    Added support when failed to parse payload by JSON, use querystring parsing.

  • 2.0.132015.12.08

    Fix bug with think.parseConfig contains adapter.

    Fix bug resulting in update relation model also update files relative.

    Fix use alias in countSelect reports error.

    Fix bootstrap not being clean and reload on file changed.

    nunjucks enable autoescape by default.

  • 2.0.122015.12.02

    fix file can't autoreload in windows when compiled.

  • 2.0.112015.11.27

    No longer change name to lowercase on parsing configuration.

    Fix save model mapping reports error.

    Fix use SQLite mapping without unique field reports error.

    Fix set cache resulting in incorrect countSelect result.

    Fix validation logic to handle empty conent.

    Fix Session return without completing resulting in not saving.

    Fix think.parallelLimit has memory leak on single task operation.

  • 2.0.102015.11.20

    Support Object type data validation format.

    Fix create controller in normal mode reports file content errors.

    Support thinkjs -v to show version number.

    Replace think.co.wrap with think.co.

    Now when calling another action in action, it will auto modify module/controller/action.

    Support entry file to set retainsFile configure.

    Support jade template compile cache in production.

  • 2.0.92015.11.15

    Fix change route not refreshing.

    Move think.npm installation path to root, and support --save option.

    Fix when count is 0, countSelect reports an error.

    Fix can't use db session.

    Fix socket start too many connections.

  • 2.0.82015.11.14

    Fix tempalte file not refreshing.

    Fix missing dependencies in package.json during set up.

    Fix auto-compile failed to get project env.

    Fix nunjucks template can't set root folder.

    Fix using Babel resulting in errors in module._load on certain platforms.

  • 2.0.72015.11.13

    Drop options from view configuration, and should use adapter from now.

    Suppress loading of non-js bootstrap files.

    Add option to install dependencies during set up.

    No longer keep static resource accessing logs.

    Add think.camelCase method.

    Support custom parsing configuration file, add think.parseConfig method.

    Display error page when output Promise.

    Fix Babel occasionally failed.

    Display page compiled errors on current URL.

    Remove source file will also remove the compiled file.

    Fix mini and normal module can't load bootstrap files.

    Fix file session occasionally errors.

    Fix some children file not refreshing on its parent being modified.

  • 2.0.62015.11.08

    URL parsed Action name support '-' character.

    Add think.mergeConfig method, auto-merged adapter parameters.

    Configuration like Cache, Session accept adapter config.

    Add think.pallelLimit mehotd, to limit the concorrency number.

    Add auto-compile mechanism, remove 'npm run watch-compile' command.

    Add detection for 'common' module only configuration.

    Config support parser, Redis、Memcache support distributed config.

    Add think.adapter.base, all 'Adapter' are inherit from this base class.

    Remove options config in view, and use 'adapter' as a substitution.

    Fix change the bae file the parent will not update iit self.

    Fix third party middleware parse payload causes stop execution.

    Fix if file name contains special character causes the error message could not use uppercase.

    Fix Session sometimes reports an error.

    Fix can not access resource wihich URL contains Chinese Character.

    Fix static resource Range head not handle properly.

  • 2.0.52015.11.02

    Fix Logic rule contains space produces error.

    Improve object structure of Logic rule validation result.

    Rename bootstrap/hook.js to bootstrap/middleware.js during project creation.

    Add config/hook.js during projec creation.

    Babel compile add --retain-lines option, to keep the same code line number after compilation.

    Add auto convert MongoID query string to MongoID object.

    Fix new files not being reloaded.

    Fix think.cache failed to assign object type.

    update module add validation on where query.

    Remove the buildin deny_ip middleware, now it is a seperate module named think-ip-filter middleware.

    Add prerender hook.

    thinkjs add plugin creation command into CLI.

    Fix when environemnt setting is producition or testing, the command can not end itself.

    Add view_filter hook.

    Fix file Session sometimes reports error.

    Note:fix small issues are found during publishment of 2.0.

  • 2.0.02015.10.30

    Can use full features of ES6/7 to develop.

    Support different project structure and environment.

    Support rich database like Mysql, MongoDB, SQLite.

    Code auto reload without restarting Node service.

    Support multiple WebSocket library, like socket.io and sockjs.

    Support multiple Session types, like Memory, like File, Db, Redis etc.

    Support multiple Cache, like MemoryFile, Redis, Memcache etc.

    Support multiple template engine, like ejs, jade, swig, numjucks etc.

    Support Aspect Oriented Programming, support methods like __before, __after etc.

    Support error page customization, like 400, 404, 500, 503 etc.

    CLI support invoking action and timer task.

    Rich Hook and Middleware.

    Support detailed logging of all kinds, like request, error and performance logging.

    REST API auto-generated.

    Support internationalization and theming.

    Comprehensive test cases 1500+, with code coverage > 95%.

  • 1.2.102015.09.17

    Fix if Memcache content contains end, content will be cut off.

    Fix use alias in countSelect will report a SQL error.

  • 1.2.92015.07.30

    Fix URL backslash in Windows can't be parse.

  • 1.2.82015.07.29

    Fix security issue of accessing static resource.

  • 1.2.72015.07.15

    Fix Memcache can not use remote host.

    Fix Memcache complains to some method parameters.

    Change DbSession key to cookie, to prevent error from creating data reports.

  • 1.2.62015.07.07

    Add custom config in jade template.

  • 1.2.52015.06.24

    Fix WebSocket change number to string.

    Fix post field equals null produces error.

  • 1.2.42015.05.29

    Remove the Controller name constrain must start with upper case followed with lower case#166.

  • 1.2.32015.05.18

    Fix redis timeout setting no effect. thx @snadn.

    Fix in debug mode, App.sendError produces error. thx @Zongmin lei.

    Fix OR mapping error if advanace model table field contains underline.

  • 1.2.22015.04.29

    Fix issue of importing MongoDb starts with lowercase, thx @denvey.

    websocket add timeout setting, default to 0 (never stop).

    Fix maliciously upload file causes Temp folder contains files.

    Note: skip npm version of 1.2.1 becuase it is no stable.

  • 1.2.02015.04.21

    Fix file upload not support multpile.

    Add support of custom error handling, thx @Rayi.

    Fix fetching client IP contains ::.

    Add redis session, thx @snadn.

    Add support of jSmart template, thx @snadn.

    Fix error in MongoDB OverwriteModelError, thx @denvey.

  • 1.1.102015.04.14

    Fix UT reports errors in Node version >=0.12.

    Support group and subquery in Model countSelect method.

  • 1.1.92015.03.25

    Fix Model config default to {}, thx @Rayi.

    Fix /resource/css error.

    Upgrade dependency websocket-driver version to 0.5.3.

  • 1.1.82015.03.13

    Fix file naming issue.

  • 1.1.72015.03.13

    Forbid ip request to fetch IP list from database.

    Add timeout mechanism in CLI to avoid unstoppable tasks.

  • 1.1.62015.01.19

    Add auto-delete upload file feature, the config name is post_file_autoremove which defaults to open, you need to move it to other folder if you want to apply this.

  • 1.1.52015.01.12

    Sanitize GET/POST by applying a filter array named C('filter_data'), default to enabled. (Note: strongly suggested to trun on this security feature).

    Auto validate the addAll method in Model.

  • 1.1.42015.01.07

    Change npm version 1.1.2 to 1.1.4.

  • 1.1.22015.01.06

    Fix _404Action can not complete normally if request is not the first time.

  • 1.1.12014.12.24

    Security improvement, to only get the first object if params is array, to avoid developer's improper operation produce security leak.

  • 1.1.02014.11.20

    Move gloabal implemenation to thinkjs-util module.

    Add RMDB data auto-validation support, document.

    Add basic support of MongoDB, document.

    Support pass ip port when starting service.

    Add error handling for Controller download method, thx @snadn.

    In debug mode, change the clear cache interval from 100ms to 500ms.

  • 1.0.72014.11.10

    Fix in CLI can't close database connection.

    Fix database rename does not take effect.

    Add support for swig template.

    Optimize getCallController performance.

    Can pass controller object to template.

    Can pass promise to template, see how to.

    success method support define customize message.

    Fix can not fetch database query cache by S function.

    where condition add ignore value feature.

  • 1.0.62014.11.03

    Optimize the process to fix static resource access leak.

    Fix error D/M method not passing arguments.

    Fix if upload file to a non-existing folder produces error.

    System error now can map to different status code.

  • 1.0.52014.10.29

    Fix bug, in windows, access static resource bug can not access bug fix.

  • 1.0.42014.10.29

    Fix static resource accessing bug, see details here.

  • 1.0.32014.10.27

    Change the params order of Class method, put formal parameter before superClass.

    Fix _call a non-existing Controller action with params produces error.

    Fix undefined in Model where condition will be filtered out.

    Add host binding support on starting service.

    Static resource regex add support for robot.txt.

  • 1.0.22014.10.20

    Change page encoding from UTF8 to UTF-8 for IE.

    Fix if Model contains alias produces error on show columns.

    Add support for Model join on with table prefix.

    Add support for Model join SELECT with table prefix.

    Fix _404Action error.

    Add file upload path config post_file_upload_path, default to App/Runtime/Temp.

  • 1.0.12014.10.09

    Remove Array.prototype.sum extension.

    Fix Model query use lower case select produces error.

    Fix bug in FileSession rm method.

  • 1.0.02014.09.22

    ThinkJS release version 1.0, check here.

ThinkJS versoning strategy:

Small release in 1~2 weeks, e.g. 1.0.1 => 1.0.2 (small features and bug fixes).

Feature release in 1~3 months, e.g. 1.0.0 => 1.1.0 (big features and small refactory).

Major release in 1~2 years, e.g. 1.0.0 => 2.0.0 (framework re-design and refactory).

Small adjustment may apply according to special situation.