Browse Source

refactor: 界面样式调整

develop
wally 4 years ago
parent
commit
4367249583
  1. 2
      .env.development
  2. 2
      .env.production
  3. 141
      CHANGELOG.md
  4. 8111
      package-lock.json
  5. 91
      package.json
  6. 11
      src/.hbuilderx/launch.json
  7. 3
      src/common/styles/index.css
  8. 33
      src/components/Globals/Globals.vue
  9. 18
      src/components/Plugin/Plugin.vue
  10. 60
      src/components/TimeLine/TimeLine.vue
  11. 32
      src/components/TimeLine/component/TimeBox.vue
  12. 23
      src/components/TimeLine/component/TimeStatus.vue
  13. 4
      src/main.js
  14. 47
      src/manifest.json
  15. 32
      src/pages.json
  16. 35
      src/pages/project/project.vue
  17. 3
      src/plugins/p-deliverable/p-deliverable.vue
  18. 3
      src/plugins/p-subproject/p-subproject.vue
  19. 2
      src/plugins/p-subtasks/p-subtasks.vue
  20. 3
      src/plugins/p-task-countdown/p-task-countdown.vue
  21. 3
      src/plugins/p-task-description/p-task-description.vue
  22. 12
      src/plugins/p-task-duration-delay/p-task-duration-delay.vue
  23. 6
      src/plugins/p-task-start-time-delay/p-task-start-time-delay.vue
  24. 3
      src/plugins/p-task-title/p-task-title.vue
  25. 8
      src/store/home/mutations.js
  26. 4
      src/store/home/state.js
  27. 9
      tailwind.config.js
  28. 4
      vue.config.js
  29. 13434
      yarn.lock

2
.env.development

@ -2,4 +2,4 @@ VUE_APP_NODE_ENV=development
VUE_APP_BASE_URL=https://test.tall.wiki
VUE_APP_API_URL=https://test.tall.wiki/gateway
VUE_APP_MSG_URL=wss://test.tall.wiki/websocket/message/v4.0/ws
VUE_APP_PUBLIC_PATH=/pt-dev/
VUE_APP_PUBLIC_PATH=/tall/v3.0.0/static/

2
.env.production

@ -2,4 +2,4 @@ VUE_APP_NODE_ENV=production
VUE_APP_BASE_URL=https://www.tall.wiki
VUE_APP_API_URL=https://www.tall.wiki/gateway
VUE_APP_MSG_URL=wss://www.tall.wiki/websocket/message/v4.0/ws
VUE_APP_PUBLIC_PATH=/pt-dev/
VUE_APP_PUBLIC_PATH=/tall/v3.0.0/static/

141
CHANGELOG.md

@ -1,109 +1,110 @@
# 0.1.0 (2021-07-26)
# 0.1.0 (2021-07-28)
### 🌟 新功能
范围|描述|commitId
--|--|--
- | 标题栏变化 | [3898cfe](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/3898cfe)
- | 标题栏变化 | [c0fcd9d](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/c0fcd9d)
- | 标题栏角色栏全局任务组件新建 | [0500cb4](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/0500cb4)
- | 插件数据获取 | [5b91bdc](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/5b91bdc)
- | 存token | [b8a178d](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/b8a178d)
- | 定期任务面板骨架屏添加 | [b2698c0](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/b2698c0)
- | 角色栏实现 | [94cd671](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/94cd671)
- | 模拟接口测试 | [69e7931](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/69e7931)
- | 配置默认插件接口 | [f0c177d](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/f0c177d)
- | 全局插件及默认插件位置修改 | [6c80d08](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/6c80d08)
- | 时间基准线,默认插件 | [a33ba1e](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/a33ba1e)
- | 时间轴界面 | [33927e9](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/33927e9)
- | 时间轴修改状态时提示框增加 | [e841392](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/e841392)
- | 提交到本地 | [9cbe411](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/9cbe411)
- | 添加时间轴上下滚动 | [2b81bbc](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/2b81bbc)
- | 引入dayjs | [29b8b93](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/29b8b93)
- | 字体大小更改 | [82cfdd4](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/82cfdd4)
- | db store | [6414c4f](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/6414c4f)
- | indexedDB | [687394e](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/687394e)
- | post 封装 | [da52e94](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/da52e94)
- | tall插件封装 | [1bcb920](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/1bcb920)
- | ws storage | [21b3a06](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/21b3a06)
富文本插件 | 富文本插件demo测试 | [ed3d644](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/ed3d644)
pinch | alloy finger实现图片的pinch放大缩小 | [de01343](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/de01343)
- | db store | 6414c4f
- | indexedDB | 687394e
pinch | alloy finger实现图片的pinch放大缩小 | de01343
- | post 封装 | da52e94
- | tall插件封装 | 1bcb920
- | ws storage | 21b3a06
- | 全局插件及默认插件位置修改 | 6c80d08
- | 字体大小更改 | 82cfdd4
- | 存token | b8a178d
- | 定期任务面板骨架屏添加 | b2698c0
富文本插件 | 富文本插件demo测试 | ed3d644
- | 引入dayjs | 29b8b93
- | 提交到本地 | 9cbe411
- | 插件数据获取 | 5b91bdc
- | 时间基准线,默认插件 | a33ba1e
- | 时间轴修改状态时提示框增加 | e841392
- | 时间轴界面 | 33927e9
- | 标题栏变化 | 3898cfe
- | 标题栏变化 | c0fcd9d
- | 标题栏角色栏全局任务组件新建 | 0500cb4
- | 模拟接口测试 | 69e7931
- | 添加时间轴上下滚动 | 2b81bbc
- | 角色栏实现 | 94cd671
- | 距调整pc端 | 5069aa1
- | 配置默认插件接口 | f0c177d
### 🎨 代码样式
范围|描述|commitId
--|--|--
- | 代码格式细节调整 | [cb2532b](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/cb2532b)
- | 更新代码 | [8c27e68](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/8c27e68)
- | 更新代码 | [1f40a76](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/1f40a76)
- | 任务快捷方式图标增加 | [4aba872](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/4aba872)
- | 日常任务修改 | [dfa7ee2](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/dfa7ee2)
- | 删除插件携带的多余文件 | [0f392bb](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/0f392bb)
- | 添加插件数据 | [2f11b42](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/2f11b42)
- | 图标修改 | [54bca09](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/54bca09)
- | 无基本变化 | [21ac4bb](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/21ac4bb)
- | 修改角色样式 | [73e268e](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/73e268e)
- | 组件新建 | [89c0035](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/89c0035)
- | 代码格式细节调整 | cb2532b
- | 任务快捷方式图标增加 | 4aba872
- | 修改角色样式 | 73e268e
- | 删除插件携带的多余文件 | 0f392bb
- | 图标修改 | 54bca09
- | 无基本变化 | 21ac4bb
- | 日常任务修改 | dfa7ee2
- | 更新代码 | 8c27e68
- | 更新代码 | 1f40a76
- | 添加插件数据 | 2f11b42
- | 组件新建 | 89c0035
### 🐛 Bug 修复
范围|描述|commitId
--|--|--
- | 定期任务接口 | [aa4981c](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/aa4981c)
- | 骨架屏替换 | [e9fdd71](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/e9fdd71)
- | 角色栏修改 | [19228d6](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/19228d6)
- | 解决时间轴报错 | [da1eece](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/da1eece)
- | 上下滚动时间轴 | [d533a01](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/d533a01)
- | 上下滑动加载定期任务 | [4090d89](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/4090d89)
- | 时间轴插件 | [225d3cc](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/225d3cc)
- | 时间轴上下滚动数据加载bug修改 | [e82ede4](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/e82ede4)
- | 时间轴上下滑动 | [4d0ae46](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/4d0ae46)
- | 提示信息显示bug及日常任务收缩问题 | [f2f06c5](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/f2f06c5)
- | 下拉加载定期任务传参,时间格式化修改 | [0b95a0e](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/0b95a0e)
- | 修改角色栏组件 | [a54c601](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/a54c601)
- | 修改main | [749ae9a](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/749ae9a)
- | 上下滑动加载定期任务 | 4090d89
- | 上下滚动时间轴 | d533a01
- | 下拉加载定期任务传参,时间格式化修改 | 0b95a0e
- | 修改main | 749ae9a
- | 修改角色栏组件 | a54c601
- | 定期任务接口 | aa4981c
- | 提示信息显示bug及日常任务收缩问题 | f2f06c5
- | 时间轴上下滑动 | 4d0ae46
- | 时间轴上下滚动数据加载bug修改 | e82ede4
- | 时间轴插件 | 225d3cc
- | 角色栏修改 | 19228d6
- | 解决时间轴报错 | da1eece
- | 骨架屏替换 | e9fdd71
### 📝 文档
范围|描述|commitId
--|--|--
- | README.md | [ab0eb05](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/ab0eb05)
- | README.md | ab0eb05
### 🔨 代码重构
范围|描述|commitId
--|--|--
- | 下滑时间轴添加备注 | [4fd20e3](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/4fd20e3)
- | project 代码健壮性完善 | [a3202c5](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/a3202c5)
template | eslint prettier sass uview tailwindcss | [9c966a1](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/9c966a1)
- | project 代码健壮性完善 | a3202c5
template | eslint prettier sass uview tailwindcss | 9c966a1
- | 下滑时间轴添加备注 | 4fd20e3
### 🚀 性能优化
范围|描述|commitId
--|--|--
- | 测试接口 | [215e074](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/215e074)
- | 插件查询及展示 | [4dba770](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/4dba770)
- | 角色栏文字颜色修改 | [215c6b3](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/215c6b3)
- | 解决警告 | [c932b09](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/c932b09)
- | 组件文件夹新建 | [22bfe7b](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/22bfe7b)
- | 组件文件夹新建 | [17bb8c9](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/17bb8c9)
- | 组件文件夹新建 | [1421504](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/1421504)
- | 插件查询及展示 | 4dba770
- | 测试接口 | 215e074
- | 组件文件夹新建 | 22bfe7b
- | 组件文件夹新建 | 17bb8c9
- | 组件文件夹新建 | 1421504
- | 角色栏文字颜色修改 | 215c6b3
- | 解决警告 | c932b09
### chore
范围|描述|commitId
--|--|--
- | api 封装 | [8dcb8a2](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/8dcb8a2)
- | env host修改 | [a79a4a5](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/a79a4a5)
- | merge globals | [b0957cc](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/b0957cc)
- | mock | [51c24a5](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/51c24a5)
pwa 小程序 | 移除了pwa,alloyFinger添加平台判断 | [875fab4](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/875fab4)
- | uview-ui | [a9ea34b](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/a9ea34b)
信息配置 | 配置eslint等配置 | [7421443](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/7421443)
- | api 封装 | 8dcb8a2
- | env host修改 | a79a4a5
- | merge globals | b0957cc
- | mock | 51c24a5
pwa 小程序 | 移除了pwa,alloyFinger添加平台判断 | 875fab4
- | uview-ui | a9ea34b
信息配置 | 配置eslint等配置 | 7421443
范围|描述|commitId
--|--|--
- | style:index | [978f272](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/978f272)
- | !2 基础模板v1.1.0 | [f5e61dd](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/f5e61dd)
- | init | [c0f1deb](https://dd.tall.wiki/gitea/wally/TALL-MUI-3/commits/c0f1deb)
- | style:index | 978f272
- | !2 基础模板v1.1.0 | f5e61dd
- | init | c0f1deb

8111
package-lock.json

File diff suppressed because it is too large

91
package.json

@ -9,9 +9,10 @@
"fix": "vue-cli-service lint --fix",
"dev:h5": "cross-env NODE_ENV=development UNI_PLATFORM=h5 vue-cli-service uni-serve --mode development",
"dev:mock": "cross-env NODE_ENV=development UNI_PLATFORM=h5 vue-cli-service uni-serve --mode mock",
"build:h5-test": "cross-env NODE_ENV=production UNI_PLATFORM=h5 vue-cli-service uni-build --mode development",
"build:h5": "cross-env NODE_ENV=production UNI_PLATFORM=h5 vue-cli-service uni-build --mode production",
"build:app-plus": "cross-env NODE_ENV=production UNI_PLATFORM=app-plus vue-cli-service uni-build",
"build:custom": "cross-env NODE_ENV=production uniapp-cli custom",
"build:h5": "cross-env NODE_ENV=production UNI_PLATFORM=h5 vue-cli-service uni-build",
"build:mp-360": "cross-env NODE_ENV=production UNI_PLATFORM=mp-360 vue-cli-service uni-build",
"build:mp-alipay": "cross-env NODE_ENV=production UNI_PLATFORM=mp-alipay vue-cli-service uni-build",
"build:mp-baidu": "cross-env NODE_ENV=production UNI_PLATFORM=mp-baidu vue-cli-service uni-build",
@ -47,33 +48,27 @@
"test:mp-weixin": "cross-env UNI_PLATFORM=mp-weixin jest -i"
},
"dependencies": {
"@dcloudio/uni-app-plus": "^2.0.0-31920210609001",
"@dcloudio/uni-h5": "^2.0.0-31920210609001",
"@dcloudio/uni-i18n": "^2.0.0-31920210609001",
"@dcloudio/uni-mp-360": "^2.0.0-31920210609001",
"@dcloudio/uni-mp-alipay": "^2.0.0-31920210609001",
"@dcloudio/uni-mp-baidu": "^2.0.0-31920210609001",
"@dcloudio/uni-mp-kuaishou": "^2.0.0-31920210609001",
"@dcloudio/uni-mp-qq": "^2.0.0-31920210609001",
"@dcloudio/uni-mp-toutiao": "^2.0.0-31920210609001",
"@dcloudio/uni-mp-vue": "^2.0.0-31920210609001",
"@dcloudio/uni-mp-weixin": "^2.0.0-31920210609001",
"@dcloudio/uni-quickapp-native": "^2.0.0-31920210609001",
"@dcloudio/uni-quickapp-webview": "^2.0.0-31920210609001",
"@dcloudio/uni-stat": "^2.0.0-31920210609001",
"@tailwindcss/postcss7-compat": "^2.2.4",
"@dcloudio/uni-app-plus": "^2.0.0-31920210709003",
"@dcloudio/uni-h5": "^2.0.0-31920210709003",
"@dcloudio/uni-helper-json": "*",
"@dcloudio/uni-i18n": "^2.0.0-31920210709003",
"@dcloudio/uni-mp-360": "^2.0.0-31920210709003",
"@dcloudio/uni-mp-alipay": "^2.0.0-31920210709003",
"@dcloudio/uni-mp-baidu": "^2.0.0-31920210709003",
"@dcloudio/uni-mp-kuaishou": "^2.0.0-31920210709003",
"@dcloudio/uni-mp-qq": "^2.0.0-31920210709003",
"@dcloudio/uni-mp-toutiao": "^2.0.0-31920210709003",
"@dcloudio/uni-mp-vue": "^2.0.0-31920210709003",
"@dcloudio/uni-mp-weixin": "^2.0.0-31920210709003",
"@dcloudio/uni-quickapp-native": "^2.0.0-31920210709003",
"@dcloudio/uni-quickapp-webview": "^2.0.0-31920210709003",
"@dcloudio/uni-stat": "^2.0.0-31920210709003",
"@vue/shared": "^3.0.0",
"alloyfinger": "^0.1.16",
"autoprefixer": "^9.8.6",
"core-js": "^3.6.5",
"lodash": "^4.17.21",
"dayjs": "^1.10.6",
"postcss": "^7",
"postcss-loader": "^6.1.1",
"flyio": "^0.6.2",
"lodash": "^4.17.21",
"regenerator-runtime": "^0.12.1",
"register-service-worker": "^1.7.1",
"right-pad": "^1.0.1",
"tailwindcss": "npm:@tailwindcss/postcss7-compat@^2.2.4",
"uview-ui": "^1.8.4",
"vue": "^2.6.11",
"vuex": "^3.2.0"
@ -81,43 +76,47 @@
"devDependencies": {
"@babel/runtime": "~7.12.0",
"@dcloudio/types": "*",
"@dcloudio/uni-automator": "^2.0.0-31920210609001",
"@dcloudio/uni-cli-shared": "^2.0.0-31920210609001",
"@dcloudio/uni-migration": "^2.0.0-31920210609001",
"@dcloudio/uni-template-compiler": "^2.0.0-31920210609001",
"@dcloudio/vue-cli-plugin-hbuilderx": "^2.0.0-31920210609001",
"@dcloudio/vue-cli-plugin-uni": "^2.0.0-31920210609001",
"@dcloudio/vue-cli-plugin-uni-optimize": "^2.0.0-31920210609001",
"@dcloudio/webpack-uni-mp-loader": "^2.0.0-31920210609001",
"@dcloudio/webpack-uni-pages-loader": "^2.0.0-31920210609001",
"@dcloudio/uni-automator": "^2.0.0-31920210709003",
"@dcloudio/uni-cli-shared": "^2.0.0-31920210709003",
"@dcloudio/uni-migration": "^2.0.0-31920210709003",
"@dcloudio/uni-template-compiler": "^2.0.0-31920210709003",
"@dcloudio/vue-cli-plugin-hbuilderx": "^2.0.0-31920210709003",
"@dcloudio/vue-cli-plugin-uni": "^2.0.0-31920210709003",
"@dcloudio/vue-cli-plugin-uni-optimize": "^2.0.0-31920210709003",
"@dcloudio/webpack-uni-mp-loader": "^2.0.0-31920210709003",
"@dcloudio/webpack-uni-pages-loader": "^2.0.0-31920210709003",
"@tailwindcss/postcss7-compat": "^2.2.7",
"@vue/cli-plugin-babel": "~4.5.0",
"@vue/cli-service": "~4.5.0",
"autoprefixer": "^9.8.6",
"babel-plugin-import": "^1.11.0",
"core-js": "^3.15.2",
"cross-env": "^7.0.2",
"jest": "^25.4.0",
"mini-types": "*",
"miniprogram-api-typings": "*",
"sass-loader": "^8.0.2",
"node-sass": "^4.14.1",
"postcss": "^7.0.36",
"postcss-comment": "^2.0.0",
"tailwindcss": "npm:@tailwindcss/postcss7-compat@^2.2.7",
"vue-template-compiler": "^2.6.11",
"@vue/cli-plugin-eslint": "~4.5.0",
"@vue/cli-plugin-vuex": "~4.5.0",
"@vue/cli-service": "~4.5.0",
"@vue/eslint-config-prettier": "^6.0.0",
"babel-eslint": "^10.1.0",
"babel-plugin-import": "^1.11.0",
"commitizen": "^4.0.3",
"commitlint": "^8.2.0",
"conventional-changelog-cli": "^2.0.28",
"cross-env": "^7.0.2",
"eslint": "^6.7.2",
"eslint-plugin-prettier": "^3.3.1",
"eslint-plugin-vue": "^6.2.2",
"husky": "^3.0.9",
"jest": "^25.4.0",
"lint-staged": "^11.0.0",
"mini-types": "*",
"miniprogram-api-typings": "*",
"node-sass": "^6.0.0",
"right-pad": "^1.0.1",
"postcss-class-rename": "^1.0.1",
"postcss-comment": "^2.0.0",
"prettier": "^2.2.1",
"sass": "^1.35.1",
"sass-loader": "10",
"vue-cli-plugin-commitlint": "~1.0.12",
"vue-cli-plugin-mock": "^1.0.3",
"vue-template-compiler": "^2.6.11"
"vue-cli-plugin-commitlint": "~1.0.12"
},
"browserslist": [
"Android >= 4",

11
src/.hbuilderx/launch.json

@ -0,0 +1,11 @@
{ // launch.json configurations app-plus/h5/mp-weixin/mp-baidu/mp-alipay/mp-qq/mp-toutiao/mp-360/
// launchtypelocalremote, localremote
"version": "0.0",
"configurations": [{
"type": "uniCloud",
"default": {
"launchtype": "local"
}
}
]
}

3
src/common/styles/index.css

@ -1,5 +1,6 @@
/* ./src/common/src/index.css */
/* ./src/common/styles/index.css */
/*! @import */
@tailwind base;
@tailwind components;
@tailwind utilities;

33
src/components/Globals/Globals.vue

@ -1,19 +1,26 @@
<template>
<view class="m-2">
<u-card :show-foot="false" :show-head="false" :style="{ height: isShrink ? '96rpx' : '300rpx' }" border-radius="25" margin="0">
<u-card :show-foot="false" :show-head="false" :style="{ height: isShrink ? '106rpx' : '340rpx' }" border-radius="25" margin="0">
<view slot="body">
<scroll-view :scrollY="true" :style="{ height: isShrink ? '40rpx' : '240rpx' }">
<skeleton :banner="false" :loading="!plugins.length" :row="4" animate class="mt-2 u-line-2 skeleton"></skeleton>
<view class="p-0 u-col-between">
<view class="grid grid-cols-3 gap-2 h-auto" v-if="plugins.length">
<scroll-view :scrollY="true" :style="{ height: isShrink ? '50rpx' : '280rpx' }">
<skeleton :banner="false" :loading="!tasks.length" :row="4" animate class="u-line-2 skeleton"></skeleton>
<view class="grid gap-2">
<template v-for="item in tasks">
<template v-if="item.plugins">
<template v-for="pluginArr in item.plugins">
<template class="p-0 u-col-between" v-if="pluginArr.length">
<Plugin
:class="getClass(plugin.colspan, plugin.rowspan)"
:key="pluginIndex"
:class="getClass(plugin.col, plugin.row)"
:item="item"
:key="plugin.pluginTaskId"
:pluginId="plugin.pluginId"
:styleType="plugin.styleType || 0"
v-for="(plugin, pluginIndex) in plugins"
v-for="plugin in pluginArr"
/>
</view>
</template>
</template>
</template>
</template>
</view>
</scroll-view>
</view>
@ -28,20 +35,16 @@ import Skeleton from '@/components/Skeleton/Skeleton';
export default {
name: 'Global',
components: { Skeleton },
props: { plugins: { type: Array, default: () => [] } },
props: { tasks: { type: Array, default: () => [] } },
data() {
return {
// loading: true,
pluginId: 0,
styleType: 0,
task: null,
};
},
// mounted() {
// setTimeout(() => (this.loading = false), 2000);
// },
computed: mapState('home', ['isShrink']),
methods: {
getClass(col, row) {
return [`row-span-${row}`, `col-span-${col}`];

18
src/components/Plugin/Plugin.vue

@ -9,7 +9,8 @@
<p-task-title :item="item" v-if="pluginId === '1'" />
<p-task-description :item="item" v-if="pluginId === '2'" />
<p-task-duration-delay :item="item" v-if="pluginId === '3'" />
<p-task-start-time-delay :item="item" v-if="pluginId === '4'" />
<p-task-start-time-delay :item="item" />
<!-- <p-task-start-time-delay :item="item" v-if="pluginId === '4'" /> -->
<p-deliverable :item="item" v-if="pluginId === '5'" />
<p-subtasks :item="item" v-if="pluginId === '6'" />
<p-subproject :item="item" v-if="pluginId === '7'" />
@ -29,26 +30,35 @@ export default {
type: Object,
},
pluginId: {
default: '0',
default: '1',
type: String,
},
styleType: {
default: 0,
type: Number,
},
pluginTaskId: {
default: '0',
type: String,
},
},
data() {
return { pluginContent: null };
},
async created() {
await this.getPlugin();
if (this.pluginContent.js) {
let domList = Array.from(document.getElementsByTagName('script'));
const index = domList.findIndex(item => item.id === `p${this.pluginContent.pluginId}`);
if (this.pluginContent.js && index === -1) {
var scriptDom = document.createElement('script');
scriptDom.id = `p${this.pluginContent.pluginId}`;
scriptDom.innerHTML = this.pluginContent.js;
document.body.append(scriptDom);
}
},
methods: {
async getPlugin() {
const { pluginId, styleType } = this;
@ -56,9 +66,7 @@ export default {
pluginId,
styleType,
});
this.$emit('changeLoading', false);
this.pluginContent = res;
console.log(this.pluginContent);
},
},
};

60
src/components/TimeLine/TimeLine.vue

@ -38,7 +38,7 @@ export default {
},
methods: {
...mapMutations('home', ['setScrollTop', 'setShrink', 'setRoleId']),
...mapMutations('home', ['setScrollTop', 'setShrink', 'setRoleId', 'setUpTasks', 'setDownTasks']),
//
scroll(e) {
@ -50,26 +50,79 @@ export default {
//
async handleScrollTop() {
if (this.topEnd) return;
const startTime = this.tasks[0].planStart - 0;
console.log('this.topEnd: ', this.topEnd);
console.log('this.tasks: ', this.tasks);
console.log('this.tasks[0].plugins: ', this.tasks[0].plugins);
if (this.tasks[0].plugins && this.tasks[0].plugins.length === 0 && !this.topEnd) {
//
console.log('没有数据时: ');
const addTasks = [
{
panel: {},
plugins: [],
planStart: this.$t.time.add(startTime, -3, 'day').valueOf(),
},
{
panel: {},
plugins: [],
planStart: this.$t.time.add(startTime, -2, 'day').valueOf(),
},
{
panel: {},
plugins: [],
planStart: this.$t.time.add(startTime, -1, 'day').valueOf(),
},
];
this.setUpTasks([...addTasks.concat(this.tasks)]);
} else {
//
console.log('有数据时: ');
const upQuery = {
timeNode: +this.tasks[0].planStart,
timeNode: startTime,
queryType: 0,
queryNum: 6,
};
await this.$emit('getTasks', upQuery);
}
},
//
async handleScrollBottom() {
if (this.bottomEnd) return;
const startTime = this.tasks[this.tasks.length - 1].planStart - 0;
if (this.tasks[0].plugins && this.tasks[0].plugins.length === 0 && !this.topEnd) {
//
console.log('没有数据时: ');
const addTasks = [
{
panel: {},
plugins: [],
planStart: this.$t.time.add(startTime, 1, 'day').valueOf(),
},
{
panel: {},
plugins: [],
planStart: this.$t.time.add(startTime, 2, 'day').valueOf(),
},
{
panel: {},
plugins: [],
planStart: this.$t.time.add(startTime, 3, 'day').valueOf(),
},
];
this.setDownTasks([...this.tasks.concat(addTasks)]);
} else {
// =+
const cycle = this.$t.time.computeCycle('天');
const timeNode = this.$t.time.add(+this.tasks[this.tasks.length - 1].planStart, 1, cycle).valueOf();
const timeNode = this.$t.time.add(startTime, 1, cycle).valueOf();
const downQuery = {
timeNode,
queryType: 1,
queryNum: 6,
};
await this.$emit('getTasks', downQuery);
}
},
//
@ -80,7 +133,6 @@ export default {
const scrollHeight = document.getElementById('scroll').clientHeight;
let width = document.documentElement.clientWidth;
for (let i = 0; i < 3; i++) {
// TODO:
if (tasks[i].panel && tasks[i].panel.height) {
// + 42
tasksHeight += +tasks[i].panel.height + 42;

32
src/components/TimeLine/component/TimeBox.vue

@ -16,8 +16,8 @@
</view>
</view>
</view>
<view class="plugin border-l-2 border-gray-300 ml-3.5 my-2">
<view class="ml-4 overflow-hidden shadow-lg task-box">
<view class="border-l-2 border-gray-300 plugin">
<view class="ml-3 overflow-hidden shadow-lg task-box">
<u-card
:show-foot="false"
:show-head="false"
@ -25,24 +25,23 @@
@click="changeTimeNode(item.planStart)"
class="h-16"
margin="0"
v-if="item.plugins && item.plugins.length"
v-if="item.plugins"
>
<!-- 任务面板插件 -->
<view slot="body">
<view v-if="!item.plugins && !item.plugins.length && taskLoading">
<view v-if="!item.plugins.length">
<skeleton :banner="false" :loading="true" :row="4" animate class="mt-2 u-line-2 skeleton"></skeleton>
</view>
<view class="p-0 u-col-between" v-else>
<view :key="pIndex" v-for="(p, pIndex) in item.plugins">
<view class="grid gap-2" v-if="p.length">
<Plugin
:class="getClass(plugin.colspan, plugin.rowspan)"
:class="getClass(plugin.col, plugin.row)"
:item="item"
:key="pluginIndex"
:key="plugin.pluginTaskId"
:pluginId="plugin.pluginId"
:styleType="styleType"
@changeLoading="taskLoading = false"
v-for="(plugin, pluginIndex) in p"
:styleType="styleType || 0"
v-for="plugin in p"
/>
</view>
</view>
@ -65,10 +64,10 @@ export default {
name: 'TimeBox',
components: { TimeStatus, Skeleton },
data() {
return { currentComponent: '', styleType: 0, taskLoading: true };
return { currentComponent: '', styleType: 0 };
},
computed: mapState('home', ['roleId', 'timeNode', 'timeUnit', 'tasks']),
computed: mapState('home', ['roleId', 'timeNode', 'timeUnit', 'tasks', 'taskLoading']),
created() {},
@ -108,6 +107,15 @@ export default {
height: 33px;
}
.plugin {
margin: 8px auto;
margin-top: 8px;
margin-bottom: 8px;
margin-left: 15px;
}
/deep/ .ml-2 {
margin-left: 16px;
}
/deep/ .ml-3 {
margin-left: 20px;
}
</style>

23
src/components/TimeLine/component/TimeStatus.vue

@ -1,6 +1,10 @@
<template>
<view class="u-font-14">
<view class="iconColumn flex items-center justify-center text-blue-400 rounded-full" v-if="status === 0" @tap="changeStatus($event, 0)">
<view
class="flex items-center justify-center text-blue-400 rounded-full icon-column"
v-if="status === 0"
@tap="changeStatus($event, 0)"
>
<u-circle-progress :percent="100" active-color="#2979ff" bgColor="rgba(255,255,255,0)" borderWidth="4" width="66">
<view class="u-progress-content">
<view class="u-progress-dot"></view>
@ -10,7 +14,8 @@
</view>
</u-circle-progress>
</view>
<view class="iconColumn flex items-center justify-center text-black rounded-full" v-if="status === 1" @tap="changeStatus($event, 1)">
<view class="flex items-center justify-center text-black rounded-full icon-column" v-if="status === 1" @tap="changeStatus($event, 1)">
<u-circle-progress :percent="80" active-color="#2979ff" bgColor="rgba(255,255,255,0)" borderWidth="6" width="66">
<view class="u-progress-content">
<view class="u-progress-dot"></view>
@ -18,7 +23,11 @@
</view>
</u-circle-progress>
</view>
<view class="iconColumn flex items-center justify-center text-gray-400 rounded-full" v-if="status === 2" @tap="changeStatus($event, 2)">
<view
class="flex items-center justify-center text-gray-400 rounded-full icon-column"
v-if="status === 2"
@tap="changeStatus($event, 2)"
>
<u-circle-progress :percent="40" active-color="#2979ff" bgColor="rgba(255,255,255,0)" borderWidth="6" width="66">
<view class="u-progress-content">
<view class="u-progress-dot"></view>
@ -29,11 +38,11 @@
</u-circle-progress>
</view>
<view
class="iconColumn flex items-center justify-center font-black text-red-800 rounded-full"
v-if="status === 3"
class="flex items-center justify-center font-black text-red-800 rounded-full icon-column"
@tap="changeStatus($event, 3)"
v-if="status === 3"
>
<u-circle-progress :percent="80" active-color="#2979ff" bgColor="rgba(255,255,255,0)" borderWidth="6" width="66">
<u-circle-progress :percent="80" active-color="#2979ff" bg-color="rgba(255,255,255,0)" borderWidth="6" width="66">
<view class="u-progress-content">
<view class="u-progress-dot"></view>
<view class="u-progress-info">
@ -97,7 +106,7 @@ export default {
};
</script>
<style scoped lang="scss">
.iconColumn {
.icon-column {
height: 33px;
width: 33px;
}

4
src/main.js

@ -1,13 +1,13 @@
import Vue from 'vue';
import dayjs from 'dayjs';
import uView from 'uview-ui';
import Tall from '@/utils/tall';
import App from './App';
import './common/styles/index.css';
import store from './store';
import dayjs from 'dayjs';
//#ifdef H5
import './registerServiceWorker';
// import './registerServiceWorker';
import AlloyFinger from 'alloyfinger';
import AlloyFingerPlugin from 'alloyfinger/vue/alloy_finger_vue';
Vue.use(AlloyFingerPlugin, { AlloyFinger });

47
src/manifest.json

@ -5,20 +5,23 @@
"versionName": "1.0.0",
"versionCode": "100",
"transformPx": false,
"app-plus": { /* 5+App */
"usingComponents": true,
"app-plus": {
/* 5+App */ "usingComponents": true,
"splashscreen": {
"alwaysShowBeforeRender": true,
"waiting": true,
"autoclose": true,
"delay": 0
},
"modules": { /* */
"modules": {
/* */
},
"distribute": { /* */
"android": { /* android */
"permissions": ["<uses-permission android:name=\"android.permission.CHANGE_NETWORK_STATE\"/>",
"distribute": {
/* */
"android": {
/* android */
"permissions": [
"<uses-permission android:name=\"android.permission.CHANGE_NETWORK_STATE\"/>",
"<uses-permission android:name=\"android.permission.MOUNT_UNMOUNT_FILESYSTEMS\"/>",
"<uses-permission android:name=\"android.permission.READ_CONTACTS\"/>",
"<uses-permission android:name=\"android.permission.VIBRATE\"/>",
@ -42,19 +45,19 @@
"<uses-permission android:name=\"android.permission.WRITE_SETTINGS\"/>"
]
},
"ios": { /* ios */
"ios": {
/* ios */
},
"sdkConfigs": { /* SDK */
"sdkConfigs": {
/* SDK */
}
}
},
"quickapp": { /* */
"quickapp": {
/* */
},
"mp-weixin": { /* */
"appid": "",
"mp-weixin": {
/* */ "appid": "",
"setting": {
"urlCheck": false
},
@ -71,5 +74,19 @@
},
"mp-qq": {
"usingComponents": true
},
"h5": {
"router": {
"base": "/tall/v3.0.0"
},
"title": "时物链条",
"sdkConfigs": {
"maps": {}
},
"optimization": {
"treeShaking": {
"enable": false
}
}
}
}

32
src/pages.json

@ -2,32 +2,6 @@
"pages": [
{
"path": "pages/project/project",
"style": {
"navigationStyle": "custom" ,
"titleNView": "false",
"navigationBarTextStyle": "white"
}
},
{
"path": "pages/plugin-test/plugin-test",
"style": {
"navigationBarTitleText": "iframe-测试"
}
},
{
"path": "pages/rich-text/rich-text",
"style": {
"navigationBarTitleText": "rich-text 测试"
}
},
{
"path": "pages/pinch/pinch",
"style": {
"navigationBarTitleText": "pinch 测试"
}
},
{
"path": "components/Title/Title",
"style": {
"navigationStyle": "custom" ,
"navigationBarTextStyle": "white"
@ -35,8 +9,10 @@
}
],
"globalStyle": {
"navigationStyle": "custom" ,
"titleNView": "false"
"navigationBarTextStyle": "black",
"navigationBarTitleText": "TALL",
"navigationBarBackgroundColor": "#F8F8F8",
"backgroundColor": "#F8F8F8"
},
"easycom": {
"autoscan": true,

35
src/pages/project/project.vue

@ -5,9 +5,7 @@
<view class="container flex flex-col flex-1 overflow-hidden bg-gray-100" style="margin: auto">
<!-- 角色栏 -->
<Roles @getTasksByRole="getTasksByRole" />
<!-- 日常任务 -->
<Globals :plugins="plugins" />
<!-- 定期任务 -->
<Globals :tasks="allPlugins.concat(timePlugins)" />
<TimeLine @getTasks="getTasks" class="flex-1 overflow-hidden" ref="child" />
</view>
</view>
@ -18,7 +16,7 @@ import { mapState, mapMutations, mapActions } from 'vuex';
export default {
data() {
return { height: '', plugins: [] };
return { height: '', plugins: [], allPlugins: [], timePlugins: [] };
},
computed: {
@ -36,20 +34,24 @@ export default {
* 重新根据时间和角色查询普通日常任务
* 永久日常任务不发生改变
*/
async timeNode() {
async timeNode(val) {
if (val) {
//
await this.getGlobal();
}
},
/**
* 当角色发生变化时
* 重新查询永久日常任务和普通日常任务
*/
async roleId() {
async roleId(val) {
if (val) {
this.setTimeNode(new Date().getTime());
//
await this.getPermanent();
//
await this.getGlobal();
}
},
},
@ -167,10 +169,12 @@ export default {
try {
this.allPlugins = [];
const res = await this.$u.api.getPermanent({ roleId: this.roleId });
for (let item of res) {
this.allPlugins = this.allPlugins.concat(item.plugins);
}
console.log('res', res);
// for (let item of res) {
// if (item.plugins) {
// this.allPlugins = this.allPlugins.concat(item.plugins);
// }
// }
this.allPlugins = res;
} catch (error) {
console.log('error: ', error);
}
@ -188,11 +192,12 @@ export default {
const { roleId, timeNode, timeUnit } = this;
const params = { roleId, timeNode, timeUnit };
const res = await this.$u.api.getGlobal(params);
for (let task of res) {
for (let item of task.plugins) {
this.timePlugins.push(...item);
}
}
// for (let task of res) {
// for (let item of task.plugins) {
// this.timePlugins.push(...item);
// }
// }
this.timePlugins = res;
this.setDailyTasks(res);
} catch (error) {
console.log('error: ', error);

3
src/plugins/p-deliverable/p-deliverable.vue

@ -1,5 +1,6 @@
<template>
<div>交付物</div>
<!-- 交付物 -->
<view>交付物</view>
</template>
<script>

3
src/plugins/p-subproject/p-subproject.vue

@ -1,5 +1,6 @@
<template>
<div>子项目插件显示子项目</div>
<!-- 子项目插件 -->
<view>子项目插件显示子项目</view>
</template>
<script>

2
src/plugins/p-subtasks/p-subtasks.vue

@ -1,5 +1,5 @@
<template>
<div>子任务插件显示子任务</div>
<view>子任务插件显示子任务</view>
</template>
<script>

3
src/plugins/p-task-countdown/p-task-countdown.vue

@ -1,5 +1,6 @@
<template>
<div>任务倒计时插件</div>
<!-- 任务倒计时插件 -->
<view>任务倒计时插件</view>
</template>
<script>

3
src/plugins/p-task-description/p-task-description.vue

@ -1,5 +1,6 @@
<template>
<div>{{ item.description }}</div>
<!-- 任务描述 -->
<view>{{ item.description }}</view>
</template>
<script>

12
src/plugins/p-task-duration-delay/p-task-duration-delay.vue

@ -1,5 +1,15 @@
<template>
<div>任务时长延迟插件+-1min时间格式可设置</div>
<view v-if="item.realDuration && item.planDuration">
<!-- 任务时长延迟插件 -->
<!-- 超时 -->
<span class="text-green-500 font-bold" v-if="+item.realDuration > +item.planDuration"
>+{{ $t.time.formatDuration(+item.realDuration - +item.planDuration) }}</span
>
<!-- 延时 -->
<span class="text-red-500 font-bold" v-if="+item.realDuration < +item.planDuration"
>-{{ $t.time.formatDuration(+item.planDuration - +item.realDuration) }}</span
>
</view>
</template>
<script>

6
src/plugins/p-task-start-time-delay/p-task-start-time-delay.vue

@ -1,5 +1,9 @@
<template>
<div>任务开始时间延迟插件+-1hour</div>
<view v-if="item.realStart && item.planStart">
<!-- 任务开始时间延迟插件 -->
<!-- 超时 -->
<span>{{ $t.time.formatDuration(+item.realStart - +item.planStart) }}</span>
</view>
</template>
<script>

3
src/plugins/p-task-title/p-task-title.vue

@ -1,5 +1,6 @@
<template>
<div>{{ item.name }}</div>
<!-- 任务名插件 -->
<view>{{ item.name }}</view>
</template>
<script>

8
src/store/home/mutations.js

@ -125,7 +125,6 @@ const mutations = {
if (!data || !data.length) {
state.topEnd = true;
}
console.log('!state.tasks.plugins.length: ', !state.tasks[0].name);
if (!state.tasks[0].name) {
state.tasks = [...data];
} else {
@ -154,21 +153,22 @@ const mutations = {
* @param {Object} state
*/
setTasks(state) {
const time = +new Date().getTime();
const data = [
{
panel: {},
plugins: [],
planStart: new Date().getTime(),
planStart: uni.$t.time.add(time, -1, 'day').valueOf(),
},
{
panel: {},
plugins: [],
planStart: new Date().getTime(),
planStart: time,
},
{
panel: {},
plugins: [],
planStart: new Date().getTime(),
planStart: uni.$t.time.add(time, 1, 'day').valueOf(),
},
];
state.tasks = data;

4
src/store/home/state.js

@ -18,7 +18,7 @@ const state = {
{
panel: {},
plugins: [],
planStart: new Date().getTime(),
planStart: uni.$t.time.add(+new Date().getTime(), -1, 'day').valueOf(),
},
{
panel: {},
@ -28,7 +28,7 @@ const state = {
{
panel: {},
plugins: [],
planStart: new Date().getTime(),
planStart: uni.$t.time.add(+new Date().getTime(), 1, 'day').valueOf(),
},
], // 定期任务
topEnd: false, // 时间轴向上查任务到顶了

9
tailwind.config.js

@ -1,12 +1,5 @@
/*
* @Author: aBin
* @email: binbin0314@126.com
* @Date: 2021-07-19 10:09:22
* @LastEditors: aBin
* @LastEditTime: 2021-07-19 11:48:41
*/
module.exports = {
purge: [],
purge: ['./public/index.html', './src/**/*.{vue,js,ts,jsx,tsx}'],
darkMode: false, // or 'media' or 'class'
theme: { extend: {} },
variants: { extend: {} },

4
vue.config.js

@ -1,9 +1,11 @@
const path = require('path');
const CopyWebpackPlugin = require('copy-webpack-plugin'); // 最新版本copy-webpack-plugin插件暂不兼容,推荐v5.0.0
const publicPath = process.env.VUE_APP_PUBLIC_PATH;
module.exports = {
lintOnSave: process.env.NODE_ENV !== 'production',
productionSourceMap: false,
publicPath: process.env.NODE_ENV === 'production' ? publicPath : '/',
devServer: {
// open: true,
// host: '127.0.0.1',
@ -13,6 +15,6 @@ module.exports = {
configureWebpack: { plugins: [] },
// , disable: true
pluginOptions: {
mock: { entry: './src/mock/mock.js', debug: true },
// mock: { entry: './src/mock/mock.js', debug: true, disable: true },
},
};

13434
yarn.lock

File diff suppressed because it is too large
Loading…
Cancel
Save