xjchenhao / egg-admin-service Goto Github PK
View Code? Open in Web Editor NEW基于eggjs的node service,用来做前后端分离的后台管理系统的后端服务。
Home Page: http://eas.xjchenhao.cn/
基于eggjs的node service,用来做前后端分离的后台管理系统的后端服务。
Home Page: http://eas.xjchenhao.cn/
经过排查是umi的问题,已向他们提交Issues。
目前的在线地址是,原先的v1.1版代码。构建不通过啊😢
我仿照你的auth/users的页面写了个todolist运行正常, 然后我改成用户只能看到自己的todo, service端只是简单加了一个数据库字段, 前端主要修改了:
@connect(state => ({
user: state.user.currentUser,
pageModel: state.todos,
}))
@Form.create()
export default class TableList extends PureComponent {
state = {
expandForm: false,
selectedRows: [],
formQuery: {},
editModal: {
isVisible: false,
isEdit: false,
},
};
componentDidMount() {console.log(this.props.user.id)
const { dispatch } = this.props;
// 获取列表数据
dispatch({
type: 'todos/fetch',
payload: {
user_id:this.props.user.id,
},
});
}
现在有一个bug, 只要手动刷新页面后会显示所有todo, console.log此时打印undefined, pageModel里的值也不正常. 请教一下,谢谢
另,把上一个提问关了吧,呵呵
建议,把模块管理的搜索部分和面包屑关联一下,提高交互感受
功能模块管理》模块Url 不太明白用途,是权限标识uri吗?是否可以加个模糊搜索,模块名称那里。
前台修改 ''权限管理'' 会导致父模块undefined,小白水平不够搞不定,只能MongoDB后台改 parent_id": "" ,希望可以修复一下.
umi.js:52597 ./src/common/menu.js
Line 23: 'menuData' is assigned a value but never used no-unused-vars
printWarnings @ umi.js:52597
umi.js:52597 ./src/pages/sys/user/register.js
Line 23: componentWillReceiveProps is deprecated since React 16.3.0, use UNSAFE_componentWillReceiveProps instead, see https://reactjs.org/docs/react-component.html#unsafe_componentwillreceiveprops react/no-deprecated
printWarnings @ umi.js:52597
umi.js:52597 ./src/layouts/UserLayout.js
Line 2: 'Redirect' is defined but never used no-unused-vars
Line 2: 'Switch' is defined but never used no-unused-vars
Line 2: 'Route' is defined but never used no-unused-vars
Line 29: 'pathname' is assigned a value but never used no-unused-vars
printWarnings @ umi.js:52597
umi.js:52597 ./src/models/sys/login.js
Line 2: 'router' is defined but never used no-unused-vars
printWarnings @ umi.js:52597
umi.js:52597 ./src/components/SiderMenu/SiderMenu.js
Line 32: componentWillReceiveProps is deprecated since React 16.3.0, use UNSAFE_componentWillReceiveProps instead, see https://reactjs.org/docs/react-component.html#unsafe_componentwillreceiveprops react/no-deprecated
printWarnings @ umi.js:52597
umi.js:52593 There were more warnings in other files.
You can find a complete log in the terminal.
node:10.15.3
npm:6.4.1
centOs:6.9
��� Webpack
Compiled with some errors in 1.63m
ERROR Failed to compile with 14 errors9:21:43 AM
Unhandled rejection TypeError: Cannot read property 'stats' of undefined
at getErrorInfo (/root/.jenkins/workspace/test_3.0/node_modules/af-webpack/lib/build.js:137:14)
at /root/.jenkins/workspace/test_3.0/node_modules/af-webpack/lib/build.js:110:16
at finalCallback (/root/.jenkins/workspace/test_3.0/node_modules/webpack/lib/MultiCompiler.js:254:12)
at runWithDependencies.err (/root/.jenkins/workspace/test_3.0/node_modules/webpack/lib/MultiCompiler.js:275:14)
at /root/.jenkins/workspace/test_3.0/node_modules/neo-async/async.js:2830:7
at done (/root/.jenkins/workspace/test_3.0/node_modules/neo-async/async.js:2925:13)
at err (/root/.jenkins/workspace/test_3.0/node_modules/webpack/lib/MultiCompiler.js:186:23)
at compiler.run (/root/.jenkins/workspace/test_3.0/node_modules/webpack/lib/MultiCompiler.js:267:15)
at finalCallback (/root/.jenkins/workspace/test_3.0/node_modules/webpack/lib/Compiler.js:257:39)
at hooks.done.callAsync.err (/root/.jenkins/workspace/test_3.0/node_modules/webpack/lib/Compiler.js:272:22)
at AsyncSeriesHook.eval [as callAsync] (eval at create (/root/.jenkins/workspace/test_3.0/node_modules/tapable/lib/HookCodeFactory.js:33:10), :30:1)
at AsyncSeriesHook.lazyCompileHook (/root/.jenkins/workspace/test_3.0/node_modules/tapable/lib/Hook.js:154:20)
at onCompiled (/root/.jenkins/workspace/test_3.0/node_modules/webpack/lib/Compiler.js:271:21)
at hooks.afterCompile.callAsync.err (/root/.jenkins/workspace/test_3.0/node_modules/webpack/lib/Compiler.js:681:15)
at AsyncSeriesHook.eval [as callAsync] (eval at create (/root/.jenkins/workspace/test_3.0/node_modules/tapable/lib/HookCodeFactory.js:33:10), :6:1)
at AsyncSeriesHook.lazyCompileHook (/root/.jenkins/workspace/test_3.0/node_modules/tapable/lib/Hook.js:154:20)
Finished: SUCCESS
虽然不影响使用,不过还是改了更舒心,呵呵.
https://github.com/liuxx001/bird-front
里的按钮渲染权限控制有没兴趣加上
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.