From 79e1608ecedfd465171629b3eb67d6ce102dc78a Mon Sep 17 00:00:00 2001 From: zuiidea Date: Tue, 6 Dec 2016 23:34:11 +0800 Subject: [PATCH] readme --- README.md | 20 ++++++++++++++++---- src/components/dashboard/quote.less | 2 +- src/routes/dashboard.js | 16 +++++++++------- 3 files changed, 26 insertions(+), 12 deletions(-) diff --git a/README.md b/README.md index 8fd3331..889757d 100644 --- a/README.md +++ b/README.md @@ -10,13 +10,14 @@ - 基于[Mock](https://github.com/nuysoft/Mock)实现脱离后端独立开发。 - 基于Antd UI 设计语言,提供后台管理系统常见使用场景。 -## to do list +## To do list - [x] 登录示例 - [x] 主布局示例 - [x] 数据列表 +- [ ] 数据列表交互动效 - [x] 表单相关 -- [ ] dashbord首页 -- [ ] 可视化图表 +- [ ] dashbord页面(部分完成) +- [ ] 可视化图表示例 ## 开发及构建 @@ -70,9 +71,20 @@ npm run build 生成dist目录 ``` +### 注意事项 + +- 生产环境中,已有数据接口,请将`src/utils/index.js`第四行 `require('./mock.js')`注释 +- 开发环境中,如再mock目录新增文件,请在`src/utils/mock.js`第二行的`mockData`数组中添加 +- 如需重写异步请求函数,请修改`src/utils/request.js` +- 如需重写antd样式配置,请修改`src/theme.js` +- 项目配置文件在`src/utils/config.js` + + ## 参考 -https://github.com/dvajs/dva/tree/master/examples/user-dashboard +用户列表:https://github.com/dvajs/dva/tree/master/examples/user-dashboard + +dashboard设计稿: ## 截屏 diff --git a/src/components/dashboard/quote.less b/src/components/dashboard/quote.less index c7e63e8..e24d172 100644 --- a/src/components/dashboard/quote.less +++ b/src/components/dashboard/quote.less @@ -28,7 +28,7 @@ overflow: hidden; text-overflow: ellipsis; white-space: nowrap; - margin-right: 60px; + margin-right: 64px; text-align: right; &:last-child{ font-weight: 100; diff --git a/src/routes/dashboard.js b/src/routes/dashboard.js index f882d2e..edc8497 100644 --- a/src/routes/dashboard.js +++ b/src/routes/dashboard.js @@ -34,16 +34,18 @@ const numberCardData = [ } ] +const quoteProps={ + name:'Joho Doe', + title:'Graphic Designer', + content:`I'm selfish, impatient and a little insecure. I make mistakes, I am out of control and at times hard to handle. But if you can't handle me at my worst, then you sure as hell don't deserve me at my best.`, + avatar:'http://img.hb.aicdn.com/bc442cf0cc6f7940dcc567e465048d1a8d634493198c4-sPx5BR_fw236', +} + function Dashboard() { const numberCards = numberCardData.map((item,key) => ) - const quoteProps={ - name:'Joho Doe', - title:'Graphic Designer', - content:`I'm selfish, impatient and a little insecure. I make mistakes, I am out of control and at times hard to handle. But if you can't handle me at my worst, then you sure as hell don't deserve me at my best.`, - avatar:'http://img.hb.aicdn.com/bc442cf0cc6f7940dcc567e465048d1a8d634493198c4-sPx5BR_fw236', - } + return ( {numberCards} @@ -59,7 +61,7 @@ function Dashboard() { - +