工作协同

This commit is contained in:
2026-09-24 14:31:24 +08:00
parent 471cfe6188
commit fb312af2fc
3 changed files with 39 additions and 21 deletions
+2 -2
View File
@@ -95,11 +95,11 @@ export default {
.stage { flex: 1; position: relative; } .stage { flex: 1; position: relative; }
.wv { position: absolute; inset: 0; } .wv { position: absolute; inset: 0; }
.wait { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; } .wait { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.av { width: 160rpx; height: 160rpx; border-radius: 50%; background: #1677FF; display: flex; align-items: center; justify-content: center; font-size: 64rpx; font-weight: 700; } .av { width: 160rpx; height: 160rpx; border-radius: 40rpx; background: #E8F1FF; color: #1677FF; display: flex; align-items: center; justify-content: center; font-size: 64rpx; font-weight: 700; }
.name { margin-top: 24rpx; font-size: 36rpx; font-weight: 700; } .name { margin-top: 24rpx; font-size: 36rpx; font-weight: 700; }
.st { margin-top: 8rpx; color: rgba(255,255,255,0.65); } .st { margin-top: 8rpx; color: rgba(255,255,255,0.65); }
.acts { display: flex; justify-content: center; gap: 32rpx; padding: 32rpx 24rpx calc(32rpx + env(safe-area-inset-bottom)); } .acts { display: flex; justify-content: center; gap: 32rpx; padding: 32rpx 24rpx calc(32rpx + env(safe-area-inset-bottom)); }
.btn { min-width: 200rpx; height: 80rpx; border-radius: 999rpx; display: flex; align-items: center; justify-content: center; font-size: 28rpx; font-weight: 600; } .btn { min-width: 200rpx; height: 80rpx; border-radius: 999rpx; display: flex; align-items: center; justify-content: center; font-size: 28rpx; font-weight: 600; }
.ok { background: #006c49; } .ok { background: #16A34A; }
.no { background: #DC2626; } .no { background: #DC2626; }
</style> </style>
+21 -15
View File
@@ -7,20 +7,24 @@
</fy-header> </fy-header>
<fy-scroll class="edge-scroll" @refresh="load"> <fy-scroll class="edge-scroll" @refresh="load">
<view class="sec">待我办理</view> <view class="sec">待我办理</view>
<view v-if="!pending.length" class="empty">暂无</view> <wd-status-tip v-if="!pending.length" image="content" tip="暂无待办" />
<view v-for="t in pending" :key="t.id" class="card item" @click="open(t)"> <view v-for="t in pending" :key="t.id" class="card item" @click="open(t)">
<view class="stripe" /> <view class="main">
<view class="body"> <text class="type">待办理</text>
<text class="t">{{ t.title }}</text> <text class="t">{{ t.title }}</text>
<text class="s">{{ t.assignerName || '' }} · {{ t.dueAt || '' }}</text> <text class="s">{{ lineOf(t.assignerName, t.dueAt) }}</text>
</view> </view>
<text class="arr"></text>
</view> </view>
<view class="sec">我发起的</view> <view class="sec">我发起的</view>
<wd-status-tip v-if="!mine.length" image="content" tip="暂无发起" />
<view v-for="t in mine" :key="'m' + t.id" class="card item" @click="open(t)"> <view v-for="t in mine" :key="'m' + t.id" class="card item" @click="open(t)">
<view class="body wide"> <view class="main">
<text class="type">协同</text>
<text class="t">{{ t.title }}</text> <text class="t">{{ t.title }}</text>
<text class="s">{{ t.assigneeName || '' }} · {{ t.status || '' }}</text> <text class="s">{{ lineOf(t.assigneeName, t.status) }}</text>
</view> </view>
<text class="arr"></text>
</view> </view>
</fy-scroll> </fy-scroll>
</view> </view>
@@ -49,6 +53,9 @@ export default {
this.mine = asList(await oaGet('/work-tasks?tab=review', store.token)) this.mine = asList(await oaGet('/work-tasks?tab=review', store.token))
} catch (_) {} } catch (_) {}
}, },
lineOf(a, b) {
return [a, b].filter(Boolean).join(' · ')
},
open(t) { open(t) {
uni.navigateTo({ url: '/pages/coop/detail?id=' + encodeURIComponent(t.id) }) uni.navigateTo({ url: '/pages/coop/detail?id=' + encodeURIComponent(t.id) })
}, },
@@ -60,13 +67,12 @@ export default {
</script> </script>
<style scoped> <style scoped>
.sec { padding: 24rpx 24rpx 8rpx; font-size: 28rpx; font-weight: 700; } .sec { padding: 24rpx 32rpx 4rpx; font-size: 26rpx; font-weight: 650; color: #6B7280; }
.item { margin: 12rpx 24rpx; display: flex; overflow: hidden; } .item { margin: 16rpx 24rpx; padding: 24rpx; display: flex; align-items: center; }
.stripe { width: 8rpx; background: #1677FF; } .main { flex: 1; min-width: 0; }
.body { flex: 1; padding: 24rpx; } .type { display: inline-block; font-size: 22rpx; color: #1677FF; background: #E8F1FF; border-radius: 8rpx; padding: 2rpx 10rpx; }
.body.wide { padding: 24rpx; } .t { display: block; margin-top: 10rpx; font-size: 28rpx; font-weight: 650; color: #111827; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.t { display: block; font-size: 28rpx; font-weight: 600; } .s { display: block; margin-top: 6rpx; font-size: 24rpx; color: #6B7280; }
.s { font-size: 22rpx; color: #6B7280; } .arr { color: #C4C9D4; font-size: 32rpx; margin-left: 8rpx; }
.empty { padding: 24rpx; text-align: center; color: #6B7280; } .add { color: #1677FF; font-size: 26rpx; font-weight: 650; padding: 8rpx; }
.add { color: #1677FF; font-size: 26rpx; font-weight: 700; padding: 8rpx; }
</style> </style>
+16 -4
View File
@@ -2,8 +2,12 @@
<view class="page"> <view class="page">
<fy-header title="附件预览" back /> <fy-header title="附件预览" back />
<view class="body"> <view class="body">
<text class="name">{{ name || '附件' }}</text> <view class="card sheet">
<view class="btn-primary" @click="open">打开 / 预览</view> <view class="mark"></view>
<text class="name">{{ name || '附件' }}</text>
<text class="hint">系统会用本机应用打开这个附件</text>
</view>
<wd-button type="primary" block size="large" @click="open">打开 / 预览</wd-button>
</view> </view>
</view> </view>
</template> </template>
@@ -31,6 +35,14 @@ export default {
</script> </script>
<style scoped> <style scoped>
.body { padding: 48rpx 32rpx; } .body { padding: 32rpx 24rpx; }
.name { display: block; font-size: 28rpx; margin-bottom: 32rpx; text-align: center; } .sheet { padding: 48rpx 32rpx; margin-bottom: 32rpx; display: flex; flex-direction: column; align-items: center; }
.mark {
width: 112rpx; height: 112rpx; border-radius: 28rpx;
background: #E8F1FF; color: #1677FF;
display: flex; align-items: center; justify-content: center;
font-size: 44rpx; font-weight: 650;
}
.name { display: block; margin-top: 24rpx; font-size: 30rpx; font-weight: 650; color: #111827; text-align: center; word-break: break-all; }
.hint { display: block; margin-top: 12rpx; font-size: 24rpx; color: #6B7280; text-align: center; }
</style> </style>