diff --git a/api/notice.js b/api/notice.js
index 956456c..516a6ea 100644
--- a/api/notice.js
+++ b/api/notice.js
@@ -4,4 +4,7 @@ import oahttp from "@/utils/oahttp.js";
* 公告列表
*/
export const noticeList = (data) => oahttp.get('/article/lists', data)
-export const noticeDetail = (data) => oahttp.get('/article/detail', data)
\ No newline at end of file
+export const noticeDetail = (data) => oahttp.get('/article/detail', data)
+
+// 任务通知
+export const taskStartNoticeApi = (data) => oahttp.get('/task/taskStartNotice', data)
\ No newline at end of file
diff --git a/components/task/taskItem.vue b/components/task/taskItem.vue
index 007723a..5b69f13 100644
--- a/components/task/taskItem.vue
+++ b/components/task/taskItem.vue
@@ -100,6 +100,11 @@
{{ datas.directorInfo.nickname}}
指定人员
+
@@ -173,6 +178,14 @@
},
methods: {
+ taskProgressColor(value) {
+ if (value < 100) return "#FF7C32"
+ else {
+ return '#1BA035'
+ }
+ },
+
+
navTo(url) {
if (url) {
uni.showLoading({
diff --git a/config/app.js b/config/app.js
index f9a2622..1978f0a 100644
--- a/config/app.js
+++ b/config/app.js
@@ -2,7 +2,7 @@ let httpApiThree;
let httpApi; // 总域名
let httpApiTwo; // 物流系统域名
-const env = 'local'; // 开发
+const env = 'dev'; // 开发
// const env = 'prod'; // 生产
// const env = 'prew'; // 预上线
// const env = 'local'; // 本地
diff --git a/pages/oaHome/oaHome.vue b/pages/oaHome/oaHome.vue
index c5baa82..d065292 100644
--- a/pages/oaHome/oaHome.vue
+++ b/pages/oaHome/oaHome.vue
@@ -76,8 +76,14 @@
+
+
+
+
+
+
-
+
@@ -188,7 +194,8 @@
oaHomeData
} from "@/static/server/server.js";
import {
- noticeList
+ noticeList,
+ taskStartNoticeApi
} from "@/api/notice.js";
import {
getAreaManagerApi
@@ -219,7 +226,7 @@
},
data() {
return {
-
+ taskNotice: '',
brange: 0,
options: {
data: '',
@@ -270,6 +277,7 @@
};
},
async onLoad() {
+ this.getTaskNotice()
// console.log('asdashg')
if (uni.getStorageSync('USER_INFO')) {
let userData = JSON.parse(uni.getStorageSync('USER_INFO'))
@@ -277,11 +285,12 @@
this.initUserInfo(userData);
// console.log(545)
}
- console.log(7787878)
await this.$onLaunched;
this.is_captain = JSON.parse(uni.getStorageSync("USER_INFO") || '{}')?.is_captain
this.options.data = bj;
+
+
//#ifdef APP-PLUS
let that = this;
jpushModule.addNotificationListener(function(result) {
@@ -330,7 +339,6 @@
let user_id = JSON.parse(uni.getStorageSync("USER_INFO")).id
this.getOrderList();
- console.log("show")
getAreaManagerApi({
user_id
}).then(res => {
@@ -414,6 +422,14 @@
}
},
methods: {
+
+ // 任务通知
+ async getTaskNotice() {
+ let res = await taskStartNoticeApi()
+ this.taskNotice = res.data?.template?.title ?
+ `您的${res.data.template.title}任务即将于${res.data.template.cron_time}日开始` : ""
+ },
+
// 通知
noticeFn() {
jpushModule.addNotificationListener(res => {
@@ -600,6 +616,9 @@
await this.getOrderList();
await this.$store.dispatch('initConfig');
await this.getApproveList();
+ await this.getTaskNotice();
+
+
// this.getIndexList()
uni.stopPullDownRefresh();
},