diff --git a/CHANGELOG.md b/CHANGELOG.md
index 9f3f357..e21f35a 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -40,6 +40,7 @@
### 📦 持续集成
范围|描述|commitId
--|--|--
+ - | 修改.drone.yml | [f5b52e3](https://101.201.226.163:50022/TALL/TALL-MUI-4/commits/f5b52e3)
- | 添加drone.yml | [9fbae89](https://101.201.226.163:50022/TALL/TALL-MUI-4/commits/9fbae89)
diff --git a/apis/plugin.js b/apis/plugin.js
new file mode 100644
index 0000000..7d18f99
--- /dev/null
+++ b/apis/plugin.js
@@ -0,0 +1,10 @@
+import Config from '@/common/js/config.js'
+
+const apiUrl = Config.apiUrl;
+const defaultwbs = `${apiUrl}`;
+
+export function setupPlugin(app) {
+ uni.$u.api = { ...uni.$u.api } || {};
+ // 获取插件信息
+ uni.$u.api.getOtherPlugin = param => uni.$u.post(`${defaultwbs}/pluginshop/plugin/query?pluginId=${param.pluginId}&styleType=${param.styleType}`);
+};
diff --git a/apis/wbs.js b/apis/wbs.js
index 2816f08..d3d0a20 100644
--- a/apis/wbs.js
+++ b/apis/wbs.js
@@ -3,5 +3,5 @@ import Config from "@/common/js/config.js"
export function setupWbs(app) {
uni.$u.api = { ...uni.$u.api } || {};
// 导入wbs
- uni.$u.api.import = formData => this.$upload.chooseAndUpload(`${Config.apiUrl}/wbs`, formData);
+ uni.$u.api.import = formData => uni.$upload.chooseAndUpload(`${Config.apiUrl}/wbs`, formData);
}
\ No newline at end of file
diff --git a/common/styles/tailwind.scss b/common/styles/tailwind.scss
index 62fc09b..aff246f 100644
--- a/common/styles/tailwind.scss
+++ b/common/styles/tailwind.scss
@@ -2425,6 +2425,18 @@
grid-auto-flow: column dense;
}
+.gap-1{
+ gap: 0.25rem;
+}
+
+.gap-2{
+ gap: 0.5rem;
+}
+
+.gap-3{
+ gap: 0.75rem;
+}
+
.auto-rows-auto {
grid-auto-rows: auto;
}
diff --git a/common/styles/theme/default.scss b/common/styles/theme/default.scss
index 29733e9..f851f5a 100644
--- a/common/styles/theme/default.scss
+++ b/common/styles/theme/default.scss
@@ -1,8 +1,16 @@
// 默认主题文件
.theme-default {
- background-color: #333;
+ background-color: #007aff;
+ color: #fff;
.u-card {
font-size: 24px !important;
color: #0f0;
}
+ .u-navbar {
+ background-color: #007aff !important;
+ color: #fff;
+ .uicon-nav-back {
+ color: #fff !important;
+ }
+ }
}
diff --git a/common/styles/theme/test.scss b/common/styles/theme/test.scss
index e29dddc..33db59c 100644
--- a/common/styles/theme/test.scss
+++ b/common/styles/theme/test.scss
@@ -5,4 +5,7 @@
font-size: 24px !important;
background-color: #ff0 !important;
}
+ .u-navbar {
+ background-color: #ff0 !important;
+ }
}
diff --git a/components/ChooseChecker/ChooseChecker.vue b/components/ChooseChecker/ChooseChecker.vue
new file mode 100644
index 0000000..e4bbe93
--- /dev/null
+++ b/components/ChooseChecker/ChooseChecker.vue
@@ -0,0 +1,89 @@
+
+
+
+
+
+ ...
+
+
+
+
+
+
+
+
+
+
+
diff --git a/components/Globals/Globals.vue b/components/Globals/Globals.vue
index e8d5f9c..07c37c9 100644
--- a/components/Globals/Globals.vue
+++ b/components/Globals/Globals.vue
@@ -11,8 +11,7 @@
>
-
-
+
@@ -53,8 +52,8 @@ const sysHeight = uni.getSystemInfoSync().screenHeight; // 屏幕的高度
const globalsHeight = Math.floor(((sysHeight - 44 - 30 - 10) / 5) * 4); // 全局任务的最大高度
const store = useStore();
const isShrink = computed(() => store.state.task.isShrink); // 全局任务是否收缩
+const showGlobalSkeleton = computed(() => store.state.task.showGlobalSkeleton); // 全局任务骨架屏
const globals = computed(() => store.getters['task/globals']);
-console.log('globals: ', globals.value);
// 手动展开日常任务
function openCard() {
diff --git a/components/Plugin/Plugin.vue b/components/Plugin/Plugin.vue
index 6382c31..5c4df41 100644
--- a/components/Plugin/Plugin.vue
+++ b/components/Plugin/Plugin.vue
@@ -1,29 +1,10 @@
- 插件面板
-
-
-
+
+
-
-
+
+
+
+
diff --git a/components/TimeLine/component/TimeBox.vue b/components/TimeLine/component/TimeBox.vue
index 040143d..6aed7b6 100644
--- a/components/TimeLine/component/TimeBox.vue
+++ b/components/TimeLine/component/TimeBox.vue
@@ -1,6 +1,6 @@
-
-
+
+
@@ -18,26 +18,22 @@
-
-
-
+
-
-
-
+
-
+
-
+
-
+
@@ -68,10 +64,10 @@ import { computed, reactive } from 'vue';
import TimeStatus from './TimeStatus.vue';
import TaskTools from './TaskTools.vue';
-// const data = reactive({
-// currentComponent: '',
-// styleType: 0,
-// });
+const data = reactive({
+ currentComponent: '',
+ styleType: 0,
+});
const store = useStore();
const roleId = computed(() => store.state.role.roleId);
diff --git a/components/Tips/Tips.vue b/components/Tips/Tips.vue
index ad48ca0..e7ef1cd 100644
--- a/components/Tips/Tips.vue
+++ b/components/Tips/Tips.vue
@@ -24,7 +24,8 @@
+
+
diff --git a/components/uni-popup/uni-popup-message.vue b/components/uni-popup/uni-popup-message.vue
new file mode 100644
index 0000000..fe401a7
--- /dev/null
+++ b/components/uni-popup/uni-popup-message.vue
@@ -0,0 +1,115 @@
+
+
+
+
+
+
diff --git a/components/uni-popup/uni-popup-share.vue b/components/uni-popup/uni-popup-share.vue
new file mode 100644
index 0000000..224a9b7
--- /dev/null
+++ b/components/uni-popup/uni-popup-share.vue
@@ -0,0 +1,171 @@
+
+
+
+
+
+
diff --git a/components/uni-popup/uni-popup.vue b/components/uni-popup/uni-popup.vue
new file mode 100644
index 0000000..4d3b867
--- /dev/null
+++ b/components/uni-popup/uni-popup.vue
@@ -0,0 +1,289 @@
+
+
+
+
+
+
diff --git a/config/plugin.js b/config/plugin.js
new file mode 100644
index 0000000..a12856b
--- /dev/null
+++ b/config/plugin.js
@@ -0,0 +1,97 @@
+// 定义插件相关信息
+/* eslint-disable */
+export default {
+ defaults: [
+ {
+ id: 1,
+ name: 'TASK_NAME',
+ description: '任务名插件',
+ component: 'p-task-title',
+ },
+ {
+ id: 2,
+ name: 'TASK_DESCRIPTION',
+ description: '任务描述插件',
+ component: 'p-task-description',
+ },
+ {
+ id: 3,
+ name: 'TASK_DURATION_DELAY',
+ description: '任务时长延迟插件(+-1min)时间格式可设置',
+ component: 'p-task-duration-delay',
+ },
+ {
+ id: 4,
+ name: 'TASK_START_TIME_DELAY',
+ description: '任务开始时间延迟插件(+-1hour)',
+ component: 'p-task-start-time-delay',
+ },
+ {
+ id: 5,
+ name: 'DELIVERABLE',
+ description: '交付物插件(人 + 交付物)可配置【仅人】 or 【仅交付物】 or 【人+交付物】',
+ component: 'p-deliverable',
+ },
+ {
+ id: 6,
+ name: 'SUBTASKS',
+ description: '子任务插件:显示子任务',
+ component: 'p-subtasks',
+ },
+ {
+ id: 7,
+ name: 'SUB_PROJECT',
+ description: '子项目插件:显示子项目',
+ component: 'p-sub-project',
+ },
+ {
+ id: 8,
+ name: 'TASK_COUNTDOWN',
+ description: '任务倒计时插件',
+ component: 'p-task-countdown',
+ },
+ {
+ id: 9,
+ name: 'MANAGE_PROJECT',
+ description: '项目信息管理插件',
+ component: 'p-manage-project',
+ },
+
+ {
+ id: 10,
+ name: 'MANAGE_ROLE',
+ description: '角色信息管理插件',
+ component: 'p-manage-role',
+ },
+ {
+ id: 11,
+ name: 'MANAGE_MEMBER',
+ description: '成员信息管理插件',
+ component: 'p-manage-member',
+ },
+ {
+ id: 12,
+ name: 'MANAGE_TASK',
+ description: '任务信息管理插件',
+ component: 'p-manage-task',
+ },
+ {
+ id: 13,
+ name: 'WBS_IMPORT',
+ description: '导入WBS新建项目',
+ component: 'p-wbs-import',
+ },
+ {
+ id: 14,
+ name: 'WBS_IMPORT_UPDATE',
+ description: '导入WBS更新项目',
+ component: 'p-wbs-update',
+ },
+ {
+ id: 15,
+ name: 'DELIVER_CHECK',
+ description: '交付物检查',
+ component: 'p-deliver-check',
+ },
+ ], // 默认插件id列表
+};
diff --git a/main.js b/main.js
index 06e6f74..8f37209 100644
--- a/main.js
+++ b/main.js
@@ -9,12 +9,14 @@ import { setupRole } from '@/apis/role.js';
import { setupTall } from '@/apis/tall.js';
import { setupTask } from '@/apis/task.js';
import { setupWbs } from '@/apis/wbs.js';
+import { setupPlugin } from '@/apis/plugin.js';
import storage from '@/utils/storage.js';
import store from './store';
import task from '@/utils/task.js';
import time from '@/utils/time.js';
import timeConfig from '@/config/time';
import taskConfig from '@/config/task';
+import pluginConfig from '@/config/plugin';
import uView from './uni_modules/vk-uview-ui'; // 引入 uView UI
import ui from '@/utils/ui.js';
import upload from '@/utils/upload.js';
@@ -31,6 +33,7 @@ export function createApp() {
app.config.globalProperties.$task = task;
app.config.globalProperties.$timeConfig = timeConfig;
app.config.globalProperties.$taskConfig = taskConfig;
+ app.config.globalProperties.$pluginConfig = pluginConfig;
uni.$cache = cache;
uni.$catchReq = cacheAndRequest;
@@ -41,6 +44,7 @@ export function createApp() {
uni.$task = task;
uni.$timeConfig = timeConfig;
uni.$taskConfig = taskConfig;
+ uni.$pluginConfig = pluginConfig;
setupDayjs(app);
app.use(uView); // 使用 uView UI
@@ -51,6 +55,7 @@ export function createApp() {
setupRole(app);
setupTask(app);
setupWbs(app);
+ setupPlugin(app);
return {
app,
diff --git a/pages/index/index.vue b/pages/index/index.vue
index 5b0349e..d2108d7 100644
--- a/pages/index/index.vue
+++ b/pages/index/index.vue
@@ -75,20 +75,22 @@ const onDateChange = event => {
// 导入成功
const onUploadSuccess = () => {
- uTips.show({
- title: '导入成功,即将打开新项目',
- type: 'success',
- duration: '3000',
- });
+ uni.$ui.showToast('导入成功,即将打开新项目', 3000);
+ // uTips.show({
+ // title: '导入成功,即将打开新项目',
+ // type: 'success',
+ // duration: '3000',
+ // });
};
// 导入失败
const onUploadError = error => {
- uTips.show({
- title: error || '导入失败',
- type: 'error',
- duration: '6000',
- });
+ uni.$ui.showToast('导入失败', 6000);
+ // uTips.show({
+ // title: error || '导入失败',
+ // type: 'error',
+ // duration: '6000',
+ // });
};
// 监听触摸滑动 切换日历的模式 月/周
diff --git a/plugins/p-deliver-check/p-deliver-check.vue b/plugins/p-deliver-check/p-deliver-check.vue
new file mode 100644
index 0000000..2bbab16
--- /dev/null
+++ b/plugins/p-deliver-check/p-deliver-check.vue
@@ -0,0 +1,62 @@
+
+
+
+
+ {{ wordNum }}/140
+
+
+
+
+
+
+
+ 提交
+ 取消
+
+
+
+
+
+
+
diff --git a/plugins/p-delivery-history/p-delivery-history.vue b/plugins/p-delivery-history/p-delivery-history.vue
new file mode 100644
index 0000000..e57fd21
--- /dev/null
+++ b/plugins/p-delivery-history/p-delivery-history.vue
@@ -0,0 +1,131 @@
+
+
+
+
+
+
+
+ {{ list.name }}
+ {{ $moment(+list.time).format('YYYY-MM-DD HH:mm:ss') }}
+
+
+ {{ list.content }}
+ {{ list.content }}
+
+
+
+
+ {{ checker.checkerName }}
+ (我)
+
+
+ 通过
+ 驳回
+ {{ checker.score }}分
+ 未审核
+
+ 驳回
+ 通过
+
+
+
+ {{ checker.remark }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/plugins/p-delivery-history/p-delivery-history1.vue b/plugins/p-delivery-history/p-delivery-history1.vue
new file mode 100644
index 0000000..f97cb1c
--- /dev/null
+++ b/plugins/p-delivery-history/p-delivery-history1.vue
@@ -0,0 +1,149 @@
+
+
+
+
+
+
+ {{ list.name }}
+ {{ $moment(+list.time).format('YYYY-MM-DD HH:mm:ss') }}
+
+
+ {{
+ list.content
+ }}
+ {{ list.content }}
+
+
+
+
+ {{ checker.checkerName }}
+ (我)
+
+
+ 通过
+ 驳回
+ {{ checker.score }}分
+ 未审核
+
+
+ 通过
+
+ 驳回
+
+
+
+ {{ checker.remark }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/plugins/p-manage-member/p-manage-member.vue b/plugins/p-manage-member/p-manage-member.vue
new file mode 100644
index 0000000..220e966
--- /dev/null
+++ b/plugins/p-manage-member/p-manage-member.vue
@@ -0,0 +1,6 @@
+
+ 成员管理
+
+
+
diff --git a/plugins/p-manage-project/p-manage-project.vue b/plugins/p-manage-project/p-manage-project.vue
new file mode 100644
index 0000000..65a16bb
--- /dev/null
+++ b/plugins/p-manage-project/p-manage-project.vue
@@ -0,0 +1,6 @@
+
+ 项目管理
+
+
+
diff --git a/plugins/p-manage-role/p-manage-role.vue b/plugins/p-manage-role/p-manage-role.vue
new file mode 100644
index 0000000..51558a0
--- /dev/null
+++ b/plugins/p-manage-role/p-manage-role.vue
@@ -0,0 +1,6 @@
+
+ 角色管理
+
+
+
diff --git a/plugins/p-manage-task/p-manage-task.vue b/plugins/p-manage-task/p-manage-task.vue
new file mode 100644
index 0000000..575e828
--- /dev/null
+++ b/plugins/p-manage-task/p-manage-task.vue
@@ -0,0 +1,6 @@
+
+ 任务管理
+
+
+
diff --git a/plugins/p-subproject/p-subproject.vue b/plugins/p-subproject/p-subproject.vue
new file mode 100644
index 0000000..27423c5
--- /dev/null
+++ b/plugins/p-subproject/p-subproject.vue
@@ -0,0 +1,54 @@
+
+
+
+
+ {{ item.name }}
+
+
+
+
+
+
+
diff --git a/plugins/p-subtasks/p-subtasks.vue b/plugins/p-subtasks/p-subtasks.vue
new file mode 100644
index 0000000..fc998b9
--- /dev/null
+++ b/plugins/p-subtasks/p-subtasks.vue
@@ -0,0 +1,31 @@
+
+
+
+ {{ item.name }}
+
+
+
+
+
+
+
diff --git a/plugins/p-task-countdown/p-task-countdown.vue b/plugins/p-task-countdown/p-task-countdown.vue
new file mode 100644
index 0000000..ee7bf8f
--- /dev/null
+++ b/plugins/p-task-countdown/p-task-countdown.vue
@@ -0,0 +1,10 @@
+
+
+ 任务倒计时插件
+
+
+
+
+
diff --git a/plugins/p-task-description/p-task-description.vue b/plugins/p-task-description/p-task-description.vue
new file mode 100644
index 0000000..7f75ba8
--- /dev/null
+++ b/plugins/p-task-description/p-task-description.vue
@@ -0,0 +1,11 @@
+
+
+ {{ task.description }}
+
+
+
diff --git a/plugins/p-task-duration-delay/p-task-duration-delay.vue b/plugins/p-task-duration-delay/p-task-duration-delay.vue
new file mode 100644
index 0000000..0bab35d
--- /dev/null
+++ b/plugins/p-task-duration-delay/p-task-duration-delay.vue
@@ -0,0 +1,23 @@
+
+
+
+
+
+ +{{ $time.formatDuration(realDuration - planDuration) }}
+
+
+
+ -{{ $time.formatDuration(planDuration - realDuration) }}
+
+
+
+
+
diff --git a/plugins/p-task-start-time-delay/p-task-start-time-delay.vue b/plugins/p-task-start-time-delay/p-task-start-time-delay.vue
new file mode 100644
index 0000000..b93a91f
--- /dev/null
+++ b/plugins/p-task-start-time-delay/p-task-start-time-delay.vue
@@ -0,0 +1,18 @@
+
+
+
+
+
+ {{ $time.formatDuration(+realStart - +planStart) }}
+
+
+
+
diff --git a/plugins/p-task-title/p-task-title.vue b/plugins/p-task-title/p-task-title.vue
index 2cf8195..d69afa9 100644
--- a/plugins/p-task-title/p-task-title.vue
+++ b/plugins/p-task-title/p-task-title.vue
@@ -6,5 +6,7 @@
diff --git a/plugins/p-upload-deliverable/p-upload-deliverable.vue b/plugins/p-upload-deliverable/p-upload-deliverable.vue
new file mode 100644
index 0000000..a9f6053
--- /dev/null
+++ b/plugins/p-upload-deliverable/p-upload-deliverable.vue
@@ -0,0 +1,90 @@
+
+
+
+
+
+
+
+
+
+ 提交
+
+
+
+
+
+
+
+
+
+
+
diff --git a/plugins/p-wbs-import/p-wbs-import.vue b/plugins/p-wbs-import/p-wbs-import.vue
new file mode 100644
index 0000000..bbdedb4
--- /dev/null
+++ b/plugins/p-wbs-import/p-wbs-import.vue
@@ -0,0 +1,71 @@
+
+
+ {{ task.name }}
+ {{ task.name }}
+
+
+
+
+
+
diff --git a/store/task/actions.js b/store/task/actions.js
index 2ff1f56..15a5909 100644
--- a/store/task/actions.js
+++ b/store/task/actions.js
@@ -5,7 +5,9 @@ const actions = {
* @param {string} roleId 角色id
*/
getPermanent({ commit }, param) {
+ commit('setShowGlobalSkeleton', true);
uni.$catchReq.getPermanent(param, (err, data) => {
+ commit('setShowGlobalSkeleton', false);
if (err) {
console.error('err: ', err);
} else {
@@ -20,7 +22,9 @@ const actions = {
* @param {object} param 请求参数 roleId, timeNode, timeUnit
*/
getGlobal({ commit }, param) {
+ commit('setShowGlobalSkeleton', true);
uni.$catchReq.getGlobal(param, (err, data) => {
+ commit('setShowGlobalSkeleton', false);
if (err) {
console.error('err: ', err);
} else {
diff --git a/store/task/mutations.js b/store/task/mutations.js
index 01d9dd7..af17063 100644
--- a/store/task/mutations.js
+++ b/store/task/mutations.js
@@ -225,6 +225,15 @@ const mutations = {
state.showSkeleton = show;
},
+ /**
+ * 设置日常任务骨架屏是否显示
+ * @param {Object} state
+ * @param {Boolean} show
+ */
+ setShowGlobalSkeleton(state, show) {
+ state.showGlobalSkeleton = show;
+ },
+
/**
* 是否设置时间轴自动滚动的位置
* @param {Object} state
diff --git a/store/task/state.js b/store/task/state.js
index 023378d..ae3cca5 100644
--- a/store/task/state.js
+++ b/store/task/state.js
@@ -18,6 +18,7 @@ const state = {
dailyTasks: [], // 日常任务
tasks: [], // 所有的定期任务
showSkeleton: false, // 定期任务骨架屏
+ showGlobalSkeleton: false, // 日常任务骨架屏
newProjectInfo: {},
showScrollTo: false, // 是否可以设置时间轴自动滚动的位置
};
diff --git a/utils/cacheAndRequest.js b/utils/cacheAndRequest.js
index f04baa7..cb0598a 100644
--- a/utils/cacheAndRequest.js
+++ b/utils/cacheAndRequest.js
@@ -83,7 +83,6 @@ export default {
uni.$cache
.getStorageRegularTask(params)
.then(data => {
- console.log('cache data: ', data);
!remote && fn(null, data);
})
.catch(err => !remote && fn(err));
@@ -93,7 +92,6 @@ export default {
uni.$u.api
.getRegularTask(params)
.then(data => {
- console.log('api data: ', uni.$u.deepClone(data));
remote = true;
fn(null, uni.$u.deepClone(data));
diff --git a/utils/upload.js b/utils/upload.js
index 91139d3..60e4d25 100644
--- a/utils/upload.js
+++ b/utils/upload.js
@@ -55,8 +55,8 @@ export default {
*/
chooseAndUpload(url, formData = {}, extension = ['.xls', '.xlsx'], name = 'param') {
uni.hideLoading();
- clearTimeout(timer);
let timer = null;
+ clearTimeout(timer);
return new Promise((resolve, reject) => {
const token = uni.$storage.getStorageSync('anyringToken');
if (!token) {