|
@@ -199,7 +199,7 @@
|
|
|
<TitleInfo :content="'工作事项'"></TitleInfo>
|
|
|
</div>
|
|
|
<div class="job-list">
|
|
|
- <div class="job-item" style="margin-right:5px">
|
|
|
+ <div class="job-item" style="margin-right:5px" @click="handlePushRouter(1)">
|
|
|
<el-badge :value="jobData.unreadMailCount" :max="99" style="margin-right:20px;margin-top:10px">
|
|
|
<div style="margin-top:-10px">
|
|
|
<el-icon size="20" color="#fff">
|
|
@@ -209,7 +209,7 @@
|
|
|
</el-badge>
|
|
|
<div>未读邮件</div>
|
|
|
</div>
|
|
|
- <div class="job-item" style="margin-right:5px">
|
|
|
+ <div class="job-item" style="margin-right:5px" @click="handlePushRouter(2)">
|
|
|
<el-badge :value="jobData.waitFlowCount" :max="99" style="margin-right:20px;margin-top:10px">
|
|
|
<div style="margin-top:-10px">
|
|
|
<el-icon size="20" color="#fff">
|
|
@@ -219,7 +219,8 @@
|
|
|
</el-badge>
|
|
|
<div>待审批</div>
|
|
|
</div>
|
|
|
- <div class="job-item">
|
|
|
+ <div class="job-item" v-if="userInfo.roles.includes('salesman') || userInfo.roles.includes('salesDirector') ||
|
|
|
+ userInfo.roles.includes('salesAssistant')" @click="handlePushRouter(3)">
|
|
|
<el-badge :value="jobData.claimCount" :max="99" style="margin-right:20px;margin-top:10px">
|
|
|
<div style="margin-top:-10px">
|
|
|
<el-icon size="20" color="#fff">
|
|
@@ -229,8 +230,8 @@
|
|
|
</el-badge>
|
|
|
<div>待认领</div>
|
|
|
</div>
|
|
|
- <div class="job-item" style="margin-right:5px">
|
|
|
- <el-badge :value="jobData.waitPurchaseCount" :max="99" style="margin-right:20px;margin-top:10px">
|
|
|
+ <div class="job-item" style="margin-right:5px" v-if="userInfo.roles.includes('purchasingOfficer') " @click=" handlePushRouter(4)">
|
|
|
+ <el-badge :value=" jobData.waitPurchaseCount" :max="99" style="margin-right:20px;margin-top:10px">
|
|
|
<div style="margin-top:-10px">
|
|
|
<el-icon size="20" color="#fff">
|
|
|
<ShoppingCart />
|
|
@@ -239,8 +240,8 @@
|
|
|
</el-badge>
|
|
|
<div>待采购</div>
|
|
|
</div>
|
|
|
- <div class="job-item" style="margin-right:5px">
|
|
|
- <el-badge :value="jobData.sampleHandoverCount" :max="99" style="margin-right:20px;margin-top:10px">
|
|
|
+ <div class="job-item" style="margin-right:5px" v-if="userInfo.roles.includes(' purchasingOfficer') " @click=" handlePushRouter(5)">
|
|
|
+ <el-badge :value=" jobData.sampleHandoverCount" :max="99" style="margin-right:20px;margin-top:10px">
|
|
|
<div style="margin-top:-10px">
|
|
|
<el-icon size="20" color="#fff">
|
|
|
<Tickets />
|
|
@@ -249,8 +250,8 @@
|
|
|
</el-badge>
|
|
|
<div>样品交接单</div>
|
|
|
</div>
|
|
|
- <div class="job-item">
|
|
|
- <el-badge :value="jobData.contractHandoverCount" :max="99" style="margin-right:20px;margin-top:10px">
|
|
|
+ <div class="job-item" v-if="userInfo.roles.includes(' purchasingOfficer') " @click=" handlePushRouter(6)">
|
|
|
+ <el-badge :value=" jobData.contractHandoverCount" :max="99" style="margin-right:20px;margin-top:10px">
|
|
|
<div style="margin-top:-10px">
|
|
|
<el-icon size="20" color="#fff">
|
|
|
<Memo />
|
|
@@ -259,8 +260,8 @@
|
|
|
</el-badge>
|
|
|
<div>合同交接单</div>
|
|
|
</div>
|
|
|
- <div class="job-item" style="margin-right:5px">
|
|
|
- <el-badge :value="jobData.waitAccountPayCount" :max="99" style="margin-right:20px;margin-top:10px">
|
|
|
+ <div class="job-item" style="margin-right:5px" v-if="userInfo.roles.includes(' cashier') " @click=" handlePushRouter(7)">
|
|
|
+ <el-badge :value=" jobData.waitAccountPayCount" :max="99" style="margin-right:20px;margin-top:10px">
|
|
|
<div style="margin-top:-10px">
|
|
|
<el-icon size="20" color="#fff">
|
|
|
<Money />
|
|
@@ -288,6 +289,7 @@ import TitleInfo from "@/components/TitleInfo/indexOne.vue";
|
|
|
|
|
|
const router = useRouter();
|
|
|
const userStore = useUserStore();
|
|
|
+const userInfo = useUserStore();
|
|
|
const { proxy } = getCurrentInstance();
|
|
|
const sidebarRouters = ref([]);
|
|
|
const sidebarRoutersCopy = ref([]);
|
|
@@ -506,6 +508,22 @@ const openDrawer = ref(false);
|
|
|
const handleOpenDrawer = () => {
|
|
|
openDrawer.value = true;
|
|
|
};
|
|
|
+
|
|
|
+const handlePushRouter = (type) => {
|
|
|
+ let obj = {
|
|
|
+ 1: "Mail",
|
|
|
+ 2: "Backlog",
|
|
|
+ 3: "Claim",
|
|
|
+ 4: "Purchase",
|
|
|
+ 5: "HandoverSlipSample",
|
|
|
+ 6: "HandoverSlip",
|
|
|
+ 7: "AccountPayment",
|
|
|
+ };
|
|
|
+ router.push({
|
|
|
+ name: obj[type],
|
|
|
+ params: {},
|
|
|
+ });
|
|
|
+};
|
|
|
</script>
|
|
|
|
|
|
<style lang="scss">
|
|
@@ -524,6 +542,7 @@ const handleOpenDrawer = () => {
|
|
|
.job-box {
|
|
|
position: absolute;
|
|
|
bottom: 20px;
|
|
|
+ height: 270px;
|
|
|
.job-list {
|
|
|
display: flex;
|
|
|
flex-wrap: wrap;
|