|
@@ -25,40 +25,42 @@ const toggleKey = ref(0)
|
|
|
const showFiled = ref(['Product', 'User Name', 'Email', 'Team', 'License Code', 'Status', 'Remaining Activatable Devices', 'Number of Activated Devices', 'Action'])
|
|
|
const fieldSelect = ref(['Product', 'User Name', 'Email', 'Team', 'License Code', 'Status', 'Remaining Activatable Devices', 'Number of Activated Devices', 'Action'])
|
|
|
const fieldOptions = ref([{
|
|
|
- value: 'Product',
|
|
|
- label: 'Product'
|
|
|
- }, {
|
|
|
- value: 'User Name',
|
|
|
- label: 'User Name'
|
|
|
- }, {
|
|
|
- value: 'Email',
|
|
|
- label: 'Email'
|
|
|
- }, {
|
|
|
- value: 'Team',
|
|
|
- label: 'Team'
|
|
|
- }, {
|
|
|
- value: 'License Code',
|
|
|
- label: 'License Code'
|
|
|
- }, {
|
|
|
- value: 'Status',
|
|
|
- label: 'Status'
|
|
|
- }, {
|
|
|
- value: 'Operated Date',
|
|
|
- label: 'Operated Date'
|
|
|
- }, {
|
|
|
- value: 'Expiration Data',
|
|
|
- label: 'Expiration Data'
|
|
|
- }, {
|
|
|
- value: 'Action',
|
|
|
- label: 'Action'
|
|
|
- }, {
|
|
|
- value: 'Remaining Activatable Devices',
|
|
|
- label: 'Remaining Activatable Devices'
|
|
|
- }, {
|
|
|
- value: 'Number of Activated Devices',
|
|
|
- label: 'Number of Activated Devices'
|
|
|
- }])
|
|
|
+ value: 'Product',
|
|
|
+ label: 'Product'
|
|
|
+}, {
|
|
|
+ value: 'User Name',
|
|
|
+ label: 'User Name'
|
|
|
+}, {
|
|
|
+ value: 'Email',
|
|
|
+ label: 'Email'
|
|
|
+}, {
|
|
|
+ value: 'Team',
|
|
|
+ label: 'Team'
|
|
|
+}, {
|
|
|
+ value: 'License Code',
|
|
|
+ label: 'License Code'
|
|
|
+}, {
|
|
|
+ value: 'Status',
|
|
|
+ label: 'Status'
|
|
|
+}, {
|
|
|
+ value: 'Operated Date',
|
|
|
+ label: 'Operated Date'
|
|
|
+}, {
|
|
|
+ value: 'Expiration Data',
|
|
|
+ label: 'Expiration Data'
|
|
|
+}, {
|
|
|
+ value: 'Action',
|
|
|
+ label: 'Action'
|
|
|
+}, {
|
|
|
+ value: 'Remaining Activatable Devices',
|
|
|
+ label: 'Remaining Activatable Devices'
|
|
|
+}, {
|
|
|
+ value: 'Number of Activated Devices',
|
|
|
+ label: 'Number of Activated Devices'
|
|
|
+}])
|
|
|
const downloadLoading = ref(false)
|
|
|
+const isFirstTimeLogin = localStorage.getItem('isFirstTimeLogin') === 'true'
|
|
|
+
|
|
|
onMounted(() => {
|
|
|
let pageText = document.getElementsByClassName('el-pagination__jump')[0]
|
|
|
if (pageText) {
|
|
@@ -73,22 +75,22 @@ const pagingQuery = (val) => {
|
|
|
tableData.value = []
|
|
|
get(
|
|
|
'/pdf-tech/vppLicenseCode/page?page=' +
|
|
|
- currentPage.value +
|
|
|
- '&' +
|
|
|
- 'pageSize=' +
|
|
|
- size.value +
|
|
|
- '&' +
|
|
|
- 'productId=' +
|
|
|
- productId.value +
|
|
|
- '&' +
|
|
|
- 'teamId=' +
|
|
|
- teamId.value +
|
|
|
- '&' +
|
|
|
- 'status=' +
|
|
|
- status.value +
|
|
|
- '&' +
|
|
|
- 'queryString=' +
|
|
|
- queryString.value
|
|
|
+ currentPage.value +
|
|
|
+ '&' +
|
|
|
+ 'pageSize=' +
|
|
|
+ size.value +
|
|
|
+ '&' +
|
|
|
+ 'productId=' +
|
|
|
+ productId.value +
|
|
|
+ '&' +
|
|
|
+ 'teamId=' +
|
|
|
+ teamId.value +
|
|
|
+ '&' +
|
|
|
+ 'status=' +
|
|
|
+ status.value +
|
|
|
+ '&' +
|
|
|
+ 'queryString=' +
|
|
|
+ queryString.value
|
|
|
).then((res) => {
|
|
|
const data = res.data.result.list
|
|
|
for (let i = 0; i < data.length; i++) {
|
|
@@ -108,6 +110,7 @@ const pagingQuery = (val) => {
|
|
|
data[i].validFlag = 'Canceled'
|
|
|
// data[i].endDate = ''
|
|
|
}
|
|
|
+ data[i].stepIndex = i
|
|
|
}
|
|
|
tableData.value = productListNameMapping(data)
|
|
|
total.value = res.data.result.total
|
|
@@ -185,13 +188,13 @@ const download = () => {
|
|
|
urlencoded.append("productId", productId.value)
|
|
|
urlencoded.append("teamId", teamId.value)
|
|
|
urlencoded.append("status", status.value)
|
|
|
- downLoad('/pdf-tech/vppLicenseCode/download',urlencoded).then(
|
|
|
+ downLoad('/pdf-tech/vppLicenseCode/download', urlencoded).then(
|
|
|
(res) => {
|
|
|
setTimeout(() => {
|
|
|
downloadLoading.value = false
|
|
|
}, 2000)
|
|
|
let url = window.URL.createObjectURL(new Blob([res.data], { type: '.xlsx' }))
|
|
|
- let a= document.createElement('a')
|
|
|
+ let a = document.createElement('a')
|
|
|
a.style.display = 'none'
|
|
|
a.href = url
|
|
|
// 自定义文件名
|
|
@@ -201,7 +204,7 @@ const download = () => {
|
|
|
a.click()
|
|
|
// 释放内存
|
|
|
url = window.URL.revokeObjectURL(url)
|
|
|
- document.body.removeChild(a)
|
|
|
+ document.body.removeChild(a)
|
|
|
}
|
|
|
)
|
|
|
}
|
|
@@ -253,8 +256,7 @@ const searchInfo = (val) => {
|
|
|
<div class="flex flex-col items-center">
|
|
|
<div class="w-full">
|
|
|
<h1 class="leading-40px">Manage License</h1>
|
|
|
- <div
|
|
|
- class="
|
|
|
+ <div class="
|
|
|
mt-36px
|
|
|
mb-16px
|
|
|
leading-20px
|
|
@@ -262,19 +264,11 @@ const searchInfo = (val) => {
|
|
|
font-bold
|
|
|
flex
|
|
|
justify-between
|
|
|
- "
|
|
|
- >
|
|
|
+ ">
|
|
|
<span>Content</span>
|
|
|
<div class="flex">
|
|
|
- <el-tooltip
|
|
|
- class="item"
|
|
|
- effect="dark"
|
|
|
- content="Export Data (.xlsx)"
|
|
|
- placement="bottom"
|
|
|
- >
|
|
|
- <span
|
|
|
- @click="download()"
|
|
|
- class="
|
|
|
+ <el-tooltip class="item" effect="dark" content="Export Data (.xlsx)" placement="bottom">
|
|
|
+ <span @click="download()" class="
|
|
|
flex
|
|
|
justify-center
|
|
|
items-center
|
|
@@ -282,14 +276,11 @@ const searchInfo = (val) => {
|
|
|
min-w-28px min-h-28px
|
|
|
bg-[#fff]
|
|
|
cursor-pointer
|
|
|
- "
|
|
|
- >
|
|
|
- <Download />
|
|
|
- </span>
|
|
|
+ ">
|
|
|
+ <Download />
|
|
|
+ </span>
|
|
|
</el-tooltip>
|
|
|
- <router-link
|
|
|
- to="/assign-license"
|
|
|
- class="
|
|
|
+ <router-link to="/assign-license" class="
|
|
|
bg-[#1460F3]
|
|
|
h-28px
|
|
|
w-111px
|
|
@@ -302,13 +293,10 @@ const searchInfo = (val) => {
|
|
|
rounded-4px
|
|
|
text-[#fff]
|
|
|
hover:opacity-80
|
|
|
- "
|
|
|
- >
|
|
|
+ ">
|
|
|
Assign License
|
|
|
</router-link>
|
|
|
- <router-link
|
|
|
- to="/batch-cancel-license"
|
|
|
- class="
|
|
|
+ <router-link to="/batch-cancel-license" class="
|
|
|
bg-[#1460F3]
|
|
|
h-28px
|
|
|
w-111px
|
|
@@ -321,21 +309,17 @@ const searchInfo = (val) => {
|
|
|
rounded-4px
|
|
|
text-[#fff]
|
|
|
hover:opacity-80
|
|
|
- "
|
|
|
- >
|
|
|
+ ">
|
|
|
Batch Remove
|
|
|
</router-link>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="w-full bg-[#fff] rounded-t-8px pt-32px px-24px">
|
|
|
<span>Header Display Fields</span>
|
|
|
- <el-select v-model="fieldSelect" @change='changeSelectField' @remove-tag='removeTag' multiple placeholder="Please select" class="w-600px mx-20px">
|
|
|
+ <el-select v-model="fieldSelect" @change='changeSelectField' @remove-tag='removeTag' multiple
|
|
|
+ placeholder="Please select" class="w-600px mx-20px">
|
|
|
<el-option v-if="fieldOptions.length" value="all" label="all" @click.native='selectAllField'></el-option>
|
|
|
- <el-option
|
|
|
- v-for="item in fieldOptions"
|
|
|
- :key="item.value"
|
|
|
- :label="item.label"
|
|
|
- :value="item.value">
|
|
|
+ <el-option v-for="item in fieldOptions" :key="item.value" :label="item.label" :value="item.value">
|
|
|
</el-option>
|
|
|
</el-select>
|
|
|
<el-button type="primary" @click="changeTableField">Confirm</el-button>
|
|
@@ -343,11 +327,7 @@ const searchInfo = (val) => {
|
|
|
<div class="flex bg-[#fff] pt-32px px-24px w-full" :class="fieldSelect ? 'p-20px rounded-b-8px' : ''">
|
|
|
<select class="w-140px" v-model="productId" :class="{ '!text-[#232A40]': productId !== '' }">
|
|
|
<option value="" selected>Product</option>
|
|
|
- <option
|
|
|
- v-for="item in productList"
|
|
|
- :key="item.value"
|
|
|
- :value="item.id"
|
|
|
- >
|
|
|
+ <option v-for="item in productList" :key="item.value" :value="item.id">
|
|
|
{{ item.name }}
|
|
|
</option>
|
|
|
</select>
|
|
@@ -367,19 +347,14 @@ const searchInfo = (val) => {
|
|
|
</option>
|
|
|
</select>
|
|
|
<div class="relative">
|
|
|
- <el-input
|
|
|
- v-model="queryString"
|
|
|
- size="mini"
|
|
|
- class="!w-316px ml-16px input-with-select"
|
|
|
- placeholder="Search User Name / Email / License Code"
|
|
|
- >
|
|
|
+ <el-input v-model="queryString" size="mini" class="!w-316px ml-16px input-with-select"
|
|
|
+ placeholder="Search User Name / Email / License Code">
|
|
|
</el-input>
|
|
|
- <button class="absolute top-8px right-8px" @click="searchInfo()"><Search /></button>
|
|
|
+ <button class="absolute top-8px right-8px" @click="searchInfo()">
|
|
|
+ <Search />
|
|
|
+ </button>
|
|
|
</div>
|
|
|
- <button
|
|
|
- type="button"
|
|
|
- @click="searchInfo()"
|
|
|
- class="
|
|
|
+ <button type="button" @click="searchInfo()" class="
|
|
|
w-70px
|
|
|
h-28px
|
|
|
border-1px border-[#1460F3]
|
|
@@ -387,38 +362,49 @@ const searchInfo = (val) => {
|
|
|
ml-16px
|
|
|
text-[#1460F3]
|
|
|
hover:opacity-80
|
|
|
- "
|
|
|
- >
|
|
|
+ ">
|
|
|
Confirm
|
|
|
</button>
|
|
|
</div>
|
|
|
- <el-table :data="tableData" class="px-24px rounded-b-8px w-full" :key="toggleKey">
|
|
|
+ <el-table :data="tableData" class="step_part1_table px-24px rounded-b-8px w-full" :key="toggleKey">
|
|
|
<el-table-column v-if="showFiled.includes('Product')" prop="productName" label="Product"> </el-table-column>
|
|
|
- <el-table-column v-if="showFiled.includes('User Name')" prop="userName" label="User Name" label-class-name="wordBreak"> </el-table-column>
|
|
|
+ <el-table-column v-if="showFiled.includes('User Name')" prop="userName" label="User Name"
|
|
|
+ label-class-name="wordBreak"> </el-table-column>
|
|
|
<el-table-column v-if="showFiled.includes('Email')" prop="email" label="Email"> </el-table-column>
|
|
|
<el-table-column v-if="showFiled.includes('Team')" prop="teamName" label="Team"> </el-table-column>
|
|
|
- <el-table-column v-if="showFiled.includes('License Code')" prop="cdkey" label="License Code" label-class-name="wordBreak"> </el-table-column>
|
|
|
+ <el-table-column v-if="showFiled.includes('License Code')" prop="cdkey" label="License Code"
|
|
|
+ label-class-name="wordBreak">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <div :class="{ step_part1_first: scope.row.stepIndex === 0 && isFirstTimeLogin }" class="step_part1">
|
|
|
+ {{ scope.row.cdkey }}
|
|
|
+ <img src="@/assets/images/step_arrow.png" alt="step_arrow">
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
<el-table-column v-if="showFiled.includes('Status')" prop="validFlag" label="Status"> </el-table-column>
|
|
|
- <el-table-column v-if="showFiled.includes('Operated Date')" prop="updatedAt" label="Operated Date" label-class-name="wordBreak"></el-table-column>
|
|
|
- <el-table-column v-if="showFiled.includes('Expiration Data')" prop="endDate" label="Expiration Data" label-class-name="wordBreak"> </el-table-column>
|
|
|
- <el-table-column v-if="showFiled.includes('Remaining Activatable Devices')" prop="availableDevices" label="Remaining Activatable Devices" label-class-name="wordBreak"> </el-table-column>
|
|
|
- <el-table-column v-if="showFiled.includes('Number of Activated Devices')" prop="activatedDevices" label="Number of Activated Devices" label-class-name="wordBreak"> </el-table-column>
|
|
|
+ <el-table-column v-if="showFiled.includes('Operated Date')" prop="updatedAt" label="Operated Date"
|
|
|
+ label-class-name="wordBreak"></el-table-column>
|
|
|
+ <el-table-column v-if="showFiled.includes('Expiration Data')" prop="endDate" label="Expiration Data"
|
|
|
+ label-class-name="wordBreak"> </el-table-column>
|
|
|
+ <el-table-column v-if="showFiled.includes('Remaining Activatable Devices')" prop="availableDevices"
|
|
|
+ label="Remaining Activatable Devices" label-class-name="wordBreak"> </el-table-column>
|
|
|
+ <el-table-column v-if="showFiled.includes('Number of Activated Devices')" prop="activatedDevices"
|
|
|
+ label="Number of Activated Devices" label-class-name="wordBreak"> </el-table-column>
|
|
|
<el-table-column v-if="showFiled.includes('Action')" prop="operate" label="Action" min-width="120">
|
|
|
- <p slot="label">Action<Down /></p>
|
|
|
+ <p slot="label">Action
|
|
|
+ <Down />
|
|
|
+ </p>
|
|
|
<template slot-scope="scope">
|
|
|
<button
|
|
|
v-if="scope.row.validFlag === 'Assigned' || scope.row.validFlag === 'Activated' || scope.row.validFlag === 'Partially activated'"
|
|
|
- @click="handleClick(scope.row)"
|
|
|
- type="text"
|
|
|
- class="
|
|
|
+ @click="handleClick(scope.row)" type="text" class="
|
|
|
w-70px
|
|
|
h-20px
|
|
|
rounded-4px
|
|
|
border-1px border-[#1460F3]
|
|
|
text-[#1460F3]
|
|
|
leading-12px
|
|
|
- "
|
|
|
- >
|
|
|
+ ">
|
|
|
Remove
|
|
|
</button>
|
|
|
<el-dialog :visible.sync="dialogVisible" width="376px" top="30vh" center :show-close="false">
|
|
@@ -438,17 +424,10 @@ const searchInfo = (val) => {
|
|
|
</el-table-column>
|
|
|
<p slot="empty">No Data Available</p>
|
|
|
</el-table>
|
|
|
- <el-pagination
|
|
|
- @size-change="handleSizeChange"
|
|
|
- @current-change="handleCurrentChange"
|
|
|
- :current-page.sync="currentPage"
|
|
|
- :page-sizes="[5, 10, 20]"
|
|
|
- :page-size="size"
|
|
|
- :background="true"
|
|
|
- layout="prev, pager, next, sizes, jumper"
|
|
|
- :total="total"
|
|
|
- class="px-24px !rounded-0 rounded-b-8px mt-20px flex justify-end"
|
|
|
- >
|
|
|
+ <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange"
|
|
|
+ :current-page.sync="currentPage" :page-sizes="[5, 10, 20]" :page-size="size" :background="true"
|
|
|
+ layout="prev, pager, next, sizes, jumper" :total="total"
|
|
|
+ class="px-24px !rounded-0 rounded-b-8px mt-20px flex justify-end">
|
|
|
</el-pagination>
|
|
|
</div>
|
|
|
</div>
|
|
@@ -465,7 +444,7 @@ const searchInfo = (val) => {
|
|
|
width: 1100px !important;
|
|
|
}
|
|
|
|
|
|
-.el-table::v-deep .el-table__cell{
|
|
|
+.el-table::v-deep .el-table__cell {
|
|
|
padding-right: 20px !important;
|
|
|
padding-left: 20px !important;
|
|
|
}
|
|
@@ -473,21 +452,58 @@ const searchInfo = (val) => {
|
|
|
.el-table::v-deep thead {
|
|
|
color: #000 !important;
|
|
|
}
|
|
|
+
|
|
|
+::v-deep .step_part1_table {
|
|
|
+ overflow: unset;
|
|
|
+
|
|
|
+ .cell {
|
|
|
+ overflow: unset;
|
|
|
+
|
|
|
+ & .step_part1 {
|
|
|
+ margin: -10px;
|
|
|
+ padding: 10px;
|
|
|
+ img {
|
|
|
+ display: none;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ .step_part1_first {
|
|
|
+ position: relative;
|
|
|
+ z-index: 10001;
|
|
|
+ background: #fff;
|
|
|
+ border-radius: 6px;
|
|
|
+
|
|
|
+ img {
|
|
|
+ display: block;
|
|
|
+ position: absolute;
|
|
|
+ z-index: 10001;
|
|
|
+ top: -10px;
|
|
|
+ left: -30px;
|
|
|
+ transform: translate(-100%, 0);
|
|
|
+ width: 100px;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
::v-deep .input-with-select .el-input__inner {
|
|
|
padding: 0 20px 0 8px;
|
|
|
border-color: #d9d9d9;
|
|
|
font-size: 14px;
|
|
|
color: #232A40;
|
|
|
}
|
|
|
+
|
|
|
::v-deep .input-with-select .el-input__inner::placeholder {
|
|
|
font-size: 14px;
|
|
|
font-weight: 400;
|
|
|
color: #808185;
|
|
|
}
|
|
|
-.el-table::v-deep .el-table__cell .wordBreak{
|
|
|
- word-break: normal!important;
|
|
|
+
|
|
|
+.el-table::v-deep .el-table__cell .wordBreak {
|
|
|
+ word-break: normal !important;
|
|
|
}
|
|
|
-.el-table::v-deep .cell{
|
|
|
+
|
|
|
+.el-table::v-deep .cell {
|
|
|
word-break: break-word;
|
|
|
}
|
|
|
</style>
|