diff --git a/CHANGELOG.md b/CHANGELOG.md
index a64ce2c..3432451 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,4 +1,4 @@
-# 0.1.0 (2021-09-06)
+# 0.1.0 (2021-09-07)
### 🌟 新功能
范围|描述|commitId
@@ -36,6 +36,7 @@
- | 提交到本地 | [9cbe411](https://dd.tall.wiki/gitea/wally/tall-mui-3-project/commits/9cbe411)
- | 插件参数处理调整 | [a3e68d3](https://dd.tall.wiki/gitea/wally/tall-mui-3-project/commits/a3e68d3)
- | 插件数据获取 | [5b91bdc](https://dd.tall.wiki/gitea/wally/tall-mui-3-project/commits/5b91bdc)
+ - | 新建任务 部分提交参数 | [25c78b8](https://dd.tall.wiki/gitea/wally/tall-mui-3-project/commits/25c78b8)
- | 新建任务 部分提交参数 | [6a422f6](https://dd.tall.wiki/gitea/wally/tall-mui-3-project/commits/6a422f6)
- | 新建任务,分享项目弹出层样式修改 | [efbc679](https://dd.tall.wiki/gitea/wally/tall-mui-3-project/commits/efbc679)
- | 新建形目 | [f7d7108](https://dd.tall.wiki/gitea/wally/tall-mui-3-project/commits/f7d7108)
diff --git a/src/__MACOSX/components/._.DS_Store b/src/__MACOSX/components/._.DS_Store
new file mode 100644
index 0000000..a5b28df
Binary files /dev/null and b/src/__MACOSX/components/._.DS_Store differ
diff --git a/src/__MACOSX/components/p-inputSearch/._.DS_Store b/src/__MACOSX/components/p-inputSearch/._.DS_Store
new file mode 100644
index 0000000..a5b28df
Binary files /dev/null and b/src/__MACOSX/components/p-inputSearch/._.DS_Store differ
diff --git a/src/apis/plugin.js b/src/apis/plugin.js
index 47114ca..e01ef1e 100644
--- a/src/apis/plugin.js
+++ b/src/apis/plugin.js
@@ -4,7 +4,7 @@ const url = process.env.VUE_APP_API_URL;
const install = (Vue, vm) => {
vm.$u.api = { ...vm.$u.api } || {};
// 获取插件信息
- vm.$u.api.getOtherPlugin = param => vm.$u.post(`${url}/pluginshop/plugin/query`, param);
+ vm.$u.api.getOtherPlugin = param => vm.$u.post(`${url}/pluginshop/plugin/query?pluginId=${param.pluginId}&styleType=${param.styleType}`);
// 查询子任务
vm.$u.api.findSonTask = param => vm.$u.post(`${uni.$t.domain}/task/findSonTask`, param);
// 查询子项目
diff --git a/src/apis/task.js b/src/apis/task.js
index baa8d40..b11d0a3 100644
--- a/src/apis/task.js
+++ b/src/apis/task.js
@@ -10,6 +10,8 @@ const install = (Vue, vm) => {
vm.$u.api.saveTask = param => vm.$u.post(`${uni.$t.domain}/task/save`, param);
//克隆任务
vm.$u.api.cloneTask = param => vm.$u.post(`${uni.$t.domain}/task/clone`, param);
+ //模糊查询 查找项目下的任务
+ vm.$u.api.queryTaskOfProject = param => vm.$u.post(`${uni.$t.domain}/task/queryTaskOfProject`, param);
};
export default { install };
diff --git a/src/components/Globals/Globals.vue b/src/components/Globals/Globals.vue
index 6b25305..2d95005 100644
--- a/src/components/Globals/Globals.vue
+++ b/src/components/Globals/Globals.vue
@@ -22,6 +22,7 @@
:key="plugin.pluginTaskId"
:plugin-task-id="plugin.pluginTaskId"
:plugin-id="plugin.pluginId"
+ :param="plugin.param"
:style-type="plugin.styleType || 0"
v-for="plugin in pluginArr"
/>
diff --git a/src/components/InputSearch/InputSearch.vue b/src/components/InputSearch/InputSearch.vue
new file mode 100644
index 0000000..133446b
--- /dev/null
+++ b/src/components/InputSearch/InputSearch.vue
@@ -0,0 +1,101 @@
+
+
+
+
+ {{ item.name }}
+
+
+
+
+
+
+
diff --git a/src/components/Plugin/Plugin.vue b/src/components/Plugin/Plugin.vue
index b41d05c..6e5560b 100644
--- a/src/components/Plugin/Plugin.vue
+++ b/src/components/Plugin/Plugin.vue
@@ -9,10 +9,10 @@
:data-pstart="task.planStart"
:data-rdu="task.realDuration"
:data-rid="roleId"
- :data-rstart="task.realStart"
:data-tid="task.id"
:data-tname="task.name"
:data-token="token"
+ :data-rstart="task.realStart"
:data-uid="userId"
style="height: 100%"
v-html="pluginContent"
diff --git a/src/components/TimeLine/component/TaskTools.vue b/src/components/TimeLine/component/TaskTools.vue
index 11eb964..a5d31fb 100644
--- a/src/components/TimeLine/component/TaskTools.vue
+++ b/src/components/TimeLine/component/TaskTools.vue
@@ -1,11 +1,185 @@
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+ 新建任务
+
+
+ 克隆任务
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/components/TimeLine/component/TimeBox.vue b/src/components/TimeLine/component/TimeBox.vue
index cc2e4ba..4378346 100644
--- a/src/components/TimeLine/component/TimeBox.vue
+++ b/src/components/TimeLine/component/TimeBox.vue
@@ -10,7 +10,7 @@
{{ $moment(+task.planStart).format('D日') }}
-
+
diff --git a/src/components/TimeLine/component/TimeStatus.vue b/src/components/TimeLine/component/TimeStatus.vue
index d595e16..7055166 100644
--- a/src/components/TimeLine/component/TimeStatus.vue
+++ b/src/components/TimeLine/component/TimeStatus.vue
@@ -18,7 +18,7 @@
- {{ computeDurationText() }}
+ {{ durationText }}
@@ -31,7 +31,7 @@
- {{ computeDurationText() }}
+ {{ durationText }}
@@ -54,6 +54,7 @@ export default {
proceed: [{ text: '暂停' }, { text: '重新开始任务', color: 'blue' }, { text: '结束' }],
again: [{ text: '重新开始任务', color: 'blue' }],
timer: null,
+ durationText: 0,
};
},
@@ -110,6 +111,19 @@ export default {
},
},
+ mounted() {
+ // TODO: 计算在不在窗口内显示
+ const time = this.computeDurationText();
+ this.updateDurationText(time);
+ },
+
+ destroyed() {
+ if (this.timer) {
+ clearInterval(this.timer);
+ this.timer = null;
+ }
+ },
+
methods: {
...mapMutations('task', ['setTip']),
@@ -167,20 +181,26 @@ export default {
// 剩余时间 = 预计结束时间 - 当前时间
// 剩余时间 = realStart + planDuration - Date.now()
computeDurationText() {
- if (this.timer) {
- clearTimeout(this.timer);
- this.timer = null;
- }
const { realStart, planDuration } = this.task;
const leftTime = +realStart + +planDuration - Date.now(); // 剩余时间
const { num, time } = this.$t.time.computeDurationText(leftTime);
- this.$nextTick(() => {
- if (!time) return;
- this.timer = setTimeout(() => {
- this.computeDurationText();
- }, time);
- });
- return num;
+ if (num <= 0) {
+ clearInterval(this.timer);
+ this.timer = null;
+ }
+ this.durationText = num;
+ return time;
+ },
+
+ updateDurationText(time) {
+ if (this.timer) {
+ clearInterval(this.timer);
+ this.timer = null;
+ }
+ if (!time) return;
+ setInterval(() => {
+ this.computeDurationText();
+ }, time);
},
},
};
diff --git a/src/components/Title/Title.vue b/src/components/Title/Title.vue
index 320acfa..d189f74 100644
--- a/src/components/Title/Title.vue
+++ b/src/components/Title/Title.vue
@@ -1,6 +1,6 @@
-
+
{{ project.name }}
@@ -21,7 +21,7 @@
- 新建任务
+ 新建任务
@@ -69,7 +69,7 @@ export default {
day: true,
hour: true,
minute: true,
- second: false,
+ second: true,
},
};
},
@@ -86,13 +86,13 @@ export default {
// 选择开始时间
confirmStartTime(e) {
- this.startTime = `${e.year}-${e.month}-${e.day} ${e.hour}:${e.minute}`;
+ this.startTime = `${e.year}-${e.month}-${e.day} ${e.hour}:${e.minute}:${e.second}`;
this.showEnd = true;
},
// 选择结束时间
confirmEndTime(e) {
- this.endTime = `${e.year}-${e.month}-${e.day} ${e.hour}:${e.minute}`;
+ this.endTime = `${e.year}-${e.month}-${e.day} ${e.hour}:${e.minute}:${e.second}`;
},
// 点击返回按钮
@@ -125,7 +125,7 @@ export default {
},
// 新建项目
- newprojects() {
+ createTask() {
// 关闭 ... 弹窗
this.show = false;
// 打开遮罩
diff --git a/src/components/Title/components/CreateTask.vue b/src/components/Title/components/CreateTask.vue
index ba63fee..f9fba7a 100644
--- a/src/components/Title/components/CreateTask.vue
+++ b/src/components/Title/components/CreateTask.vue
@@ -5,20 +5,19 @@
新建任务
负责人*:
-
-
+ {{ roleName }}
+
+
@@ -53,14 +52,20 @@
{{ project.name }}
-
+
所属任务:
-
+
{{ task.name }}
@@ -109,7 +114,7 @@