welkinwong / nodercms Goto Github PK
View Code? Open in Web Editor NEW轻量级内容管理系统,基于 Node.js + MongoDB 开发,拥有灵活的内容模型以及完善的权限角色机制。
Home Page: http://www.nodercms.com
License: MIT License
轻量级内容管理系统,基于 Node.js + MongoDB 开发,拥有灵活的内容模型以及完善的权限角色机制。
Home Page: http://www.nodercms.com
License: MIT License
请教一下,模板写好后,如何像hugo那样将网站前端批量生成html
{{#foreach navigation}}
{{#if current}}
{{#if nodes}}
{{#foreach nodes}}
{{#if isShow}}
{{current}}这个为空
{{/if}}
{{/foreach}}
{{/if}}
{{/if}}
{{/foreach}}
手机端访问后台,左边的菜单栏占得很大,右边的内容页面都被挤塌了。小米3S上
安装过程中连接mongodb需要用户名和密码,能否设为可选,一般开发环境下monogodb是不需要认证的。
还有连接数据库有个ERROR:DeprecationWarning: open()
is deprecated in mongoose >= 4.11.0, use openUri()
instead, or set the useMongoClient
option if using connect()
or createConnection()
. See http://mongoosejs.com/docs/connections.html#use-mongo-client
请问是否支持MongoDB集群,如何配置?
安装好后,第二次怎样打开nodercms网站呢?
[2017-07-10 12:21:41.966] [ERROR] database - { Error: Trying to open unclosed connection.
at NativeConnection.Connection._handleOpenArgs (/home/wwwroot/default/nodercms/node_modules/mongoose/lib/connection.js:213:11)
at NativeConnection.<anonymous> (/home/wwwroot/default/nodercms/node_modules/mongoose/lib/connection.js:308:37)
at NativeConnection.deprecated [as open] (internal/util.js:67:15)
at Mongoose.connect (/home/wwwroot/default/nodercms/node_modules/mongoose/lib/index.js:272:47)
at /home/wwwroot/default/nodercms/lib/database.lib.js:103:16
at fn (/home/wwwroot/default/nodercms/node_modules/async/lib/async.js:746:34)
at /home/wwwroot/default/nodercms/node_modules/async/lib/async.js:1213:16
at /home/wwwroot/default/nodercms/node_modules/async/lib/async.js:166:37
at /home/wwwroot/default/nodercms/node_modules/async/lib/async.js:706:43
at /home/wwwroot/default/nodercms/node_modules/async/lib/async.js:167:37
at /home/wwwroot/default/nodercms/node_modules/async/lib/async.js:1209:30
at /home/wwwroot/default/nodercms/lib/database.lib.js:99:9
at FSReqWrap.readFileAfterClose [as oncomplete] (fs.js:445:3) state: 1, type: 'database' }
[2017-07-10 12:21:41.968] [WARN] console - Unhandled rejection Error: Trying to open unclosed connection.
at NativeConnection.Connection._handleOpenArgs (/home/wwwroot/default/nodercms/node_modules/mongoose/lib/connection.js:213:11)
at NativeConnection.<anonymous> (/home/wwwroot/default/nodercms/node_modules/mongoose/lib/connection.js:308:37)
at NativeConnection.deprecated [as open] (internal/util.js:67:15)
at Mongoose.connect (/home/wwwroot/default/nodercms/node_modules/mongoose/lib/index.js:272:47)
at /home/wwwroot/default/nodercms/lib/database.lib.js:103:16
at fn (/home/wwwroot/default/nodercms/node_modules/async/lib/async.js:746:34)
at /home/wwwroot/default/nodercms/node_modules/async/lib/async.js:1213:16
at /home/wwwroot/default/nodercms/node_modules/async/lib/async.js:166:37
at /home/wwwroot/default/nodercms/node_modules/async/lib/async.js:706:43
at /home/wwwroot/default/nodercms/node_modules/async/lib/async.js:167:37
at /home/wwwroot/default/nodercms/node_modules/async/lib/async.js:1209:30
at /home/wwwroot/default/nodercms/lib/database.lib.js:99:9
at FSReqWrap.readFileAfterClose [as oncomplete] (fs.js:445:3)
[2017-07-10 12:21:41.968] [ERROR] access - POST /api/install
node: 6.9.1
mongodb: 3.4.6
db.auth()认证通过,返回1.
网站需要简体中文、繁体中文、英文切换,请给建议,谢谢!
代码直接连接MongoDB Atlas数据库配置是可以连接上的
但是初始化CMS的时候使用相同的数据库配置连接不上
如题,请问轮播图怎么设置?
可能是因为没备案
[2019-05-28 03:25:55.455] [INFO] system - 正在监听 port 3000
[2019-05-28 03:26:00.425] [INFO] access - GET /admin/install
[2019-05-28 03:26:00.427] [ERROR] console - (node:870) [DEP0066] DeprecationWarning: OutgoingMessage.prototype._headers is deprecated
[2019-05-28 03:26:00.527] [INFO] access - GET /assets/admin/main.css
[2019-05-28 03:26:00.552] [INFO] access - GET /assets/admin/main.js
[2019-05-28 03:26:00.554] [INFO] access - GET /assets/admin/vendor.css
[2019-05-28 03:26:00.561] [INFO] access - GET /assets/admin/views.js
[2019-05-28 03:26:00.582] [INFO] access - GET /assets/admin/vendor.js
[2019-05-28 03:26:00.810] [WARN] access - GET /api/install
[2019-05-28 03:26:00.903] [INFO] access - GET /assets/admin/images/logo-lg.png
[2019-05-28 03:26:00.908] [INFO] access - GET /assets/admin/images/sponsor/weixin99.jpg
[2019-05-28 03:26:00.910] [INFO] access - GET /assets/admin/images/sponsor/weixin199.jpg
[2019-05-28 03:26:00.918] [INFO] access - GET /assets/admin/images/sponsor/weixin499.jpg
[2019-05-28 03:26:00.929] [INFO] access - GET /assets/admin/images/sponsor/weixin999.jpg
[2019-05-28 03:26:00.931] [INFO] access - GET /assets/admin/images/sponsor/alipay199.jpg
[2019-05-28 03:26:00.932] [INFO] access - GET /assets/admin/images/sponsor/alipay99.jpg
[2019-05-28 03:26:00.938] [INFO] access - GET /assets/admin/images/sponsor/alipay499.jpg
[2019-05-28 03:26:00.941] [INFO] access - GET /assets/admin/images/sponsor/alipay999.jpg
[2019-05-28 03:26:01.048] [WARN] access - GET /api/install/themes
[2019-05-28 03:26:02.855] [ERROR] console - (node:870) DeprecationWarning: `open()` is deprecated in mongoose >= 4.11.0, use `openUri()` instead, or set the `useMongoClient` option if using `connect()` or `createConnection()`. See http://mongoosejs.com/docs/connections.html#use-mongo-client
[2019-05-28 03:26:02.864] [WARN] console - Db.prototype.authenticate method will no longer be available in the next major release 3.x as MongoDB 3.6 will only allow auth against users in the admin db and will no longer allow multiple credentials on a socket. Please authenticate using MongoClient.connect with auth credentials.
[2019-05-28 03:26:02.868] [ERROR] access - PUT /api/install/test-database
[2019-05-28 03:26:02.872] [WARN] console - Unhandled rejection MongoError: Authentication failed.
at Function.MongoError.create (/home/nodercms/node_modules/mongoose/node_modules/mongodb-core/lib/error.js:31:11)
at /home/nodercms/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:497:72
at authenticateStragglers (/home/nodercms/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:443:16)
at Connection.messageHandler (/home/nodercms/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:477:5)
at Socket.<anonymous> (/home/nodercms/node_modules/mongoose/node_modules/mongodb-core/lib/connection/connection.js:331:22)
at Socket.emit (events.js:200:13)
at addChunk (_stream_readable.js:290:12)
at readableAddChunk (_stream_readable.js:271:11)
at Socket.Readable.push (_stream_readable.js:226:10)
at TCP.onStreamRead (internal/stream_base_commons.js:166:17)
[2019-05-28 03:26:02.888] [INFO] access - GET /assets/admin/fonts/fontawesome-webfont.woff2?v=4.6.1
单页模版的media对象中的src不存在,无法读取
没有菜单的权限管理
{{#features 'rc-home-solution'}}
{{#foreach extensions.pic}}
<a href="{{url}}" style="background-image: url('{{src}}')">
{{/foreach}}
{{/features}}
基于nodejs的CMS,noder算做得很出色了,但用得NODEJS的都是技术牛人,往往忽略了外观模板,只要引入H5外观设计师协助,noder才能广泛使用起来,并进行收费,因为网站说白了都是外观模板为先,功能再强大也不会超越那些
我的ui是基于vue/nuxt.js开发的,如何将cms嵌入到我已有的ui框架内?
想要在centos上安装发布,请问需要安装哪些依赖包!
[2022-11-22 18:52:57.070] [INFO] system - 正在监听 port 3000
[2022-11-22 18:53:00.106] [ERROR] console - (node:178720) DeprecationWarning: `open()` is deprecated in mongoose >= 4.11.0, use `openUri()` instead, or set the `useMongoClient` option if using `connect()` or `createConnection()`. See http://mongoosejs.com/docs/connections.html#use-mongo-client
(Use `node --trace-deprecation ...` to show where the warning was created)
[2022-11-22 18:53:00.116] [WARN] console - Db.prototype.authenticate method will no longer be available in the next major release 3.x as MongoDB 3.6 will only allow auth against users in the admin db and will no longer allow multiple credentials on a socket. Please authenticate using MongoClient.connect with auth credentials.
[2022-11-22 18:53:00.122] [ERROR] access - PUT /api/install/test-database
[2022-11-22 18:53:00.122] [ERROR] console - (node:178720) [DEP0066] DeprecationWarning: OutgoingMessage.prototype._headers is deprecated
[2022-11-22 18:53:00.135] [WARN] console - Unhandled rejection MongoError: Authentication failed.
at Function.MongoError.create (G:\workspace\realworld\cms\nodercms\nodercms\node_modules\mongoose\node_modules\mongodb-core\lib\error.js:31:11)
at G:\workspace\realworld\cms\nodercms\nodercms\node_modules\mongoose\node_modules\mongodb-core\lib\connection\pool.js:497:72
at authenticateStragglers (G:\workspace\realworld\cms\nodercms\nodercms\node_modules\mongoose\node_modules\mongodb-core\lib\connection\pool.js:443:16)
at Connection.messageHandler (G:\workspace\realworld\cms\nodercms\nodercms\node_modules\mongoose\node_modules\mongodb-core\lib\connection\pool.js:477:5)
at Socket.<anonymous> (G:\workspace\realworld\cms\nodercms\nodercms\node_modules\mongoose\node_modules\mongodb-core\lib\connection\connection.js:331:22)
at Socket.emit (node:events:520:28)
at addChunk (node:internal/streams/readable:315:12)
at readableAddChunk (node:internal/streams/readable:289:9)
at Socket.Readable.push (node:internal/streams/readable:228:10)
at TCP.onStreamRead (node:internal/stream_base_commons:190:23)
我把代码部署到了阿里云上,但现在不能通过IP和端口,访问到网站,是什么原因
老铁做的超级好
各种分离
像极了php的很成熟的项目
不过有一点就是async包有点过时
没有用上es6新特性 async/await 这样会没有更多的回调嵌套
非常感谢作者
链接类型的分类只能加载顶级分类下,如果在频道或者栏目下新增就会报错:
categories.controller.js { type: 'system', error: '上级分类不存在' }
在启动的时候log4js会提示找不到文件或目录,要改成酱紫:
var path = require("path");
var dir = path.join(__dirname, '../');
module.exports = {
appenders: [
{
type: 'console'
},
{
type: 'dateFile',
category: 'access',
filename: dir+'logs/access/access',
pattern: '-dd--hh.log',
alwaysIncludePattern: true
},
{
type: 'dateFile',
category: 'system',
filename: dir+'logs/system/system',
pattern: '-dd.log',
alwaysIncludePattern: true
},
{
type: 'dateFile',
category: 'database',
filename: dir+'logs/database/database',
pattern: '-dd.log',
alwaysIncludePattern: true
},
{
type: 'logLevelFilter',
level: 'ERROR',
appender: {
type: 'dateFile',
filename: dir+'logs/errors/error',
pattern: '-MM-dd.log',
alwaysIncludePattern: true
}
}
],
replaceConsole: true
};
改了src/views/x.html 不生效
admin文件夹下的main.js中结构是这样:
angular.module('nodercms',[....])
.config(.....)
.run(['checkSign', '$templateCache', function (checkSign) {
console.log('111');
checkSign();
}]);
请问为什么我在这个地方log(111) node控制台中打印不出来?我主要想看看这个run中是在什么时候执行的。谢谢!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.