|
@@ -11,42 +11,59 @@
|
|
|
{{ item }}
|
|
|
</el-tag>
|
|
|
</span>
|
|
|
- <span class="add-tag" @click="addTag">添加</span>
|
|
|
+ <span class="add-tag" @click="addTag">打标</span>
|
|
|
|
|
|
- <Modal title="添加标签" :visible="visible" :bg="false">
|
|
|
- <el-select
|
|
|
- ref="select"
|
|
|
- v-model="tagSelectValue"
|
|
|
- style="width: 100%"
|
|
|
- multiple
|
|
|
- remote
|
|
|
- filterable
|
|
|
- allow-create
|
|
|
- default-first-option
|
|
|
- :placeholder="placeholder"
|
|
|
- :remote-method="remoteMethod"
|
|
|
- @click.stop
|
|
|
- @change="change"
|
|
|
- >
|
|
|
- <el-option
|
|
|
- v-for="(item, itemIndex) in options"
|
|
|
- :key="itemIndex"
|
|
|
- :label="item"
|
|
|
- :value="item"
|
|
|
- >
|
|
|
- {{ item }}
|
|
|
- </el-option>
|
|
|
- </el-select>
|
|
|
+ <!-- 弹窗 -->
|
|
|
+ <div v-if="visible" class="dialogbox">
|
|
|
+ <div class="box">
|
|
|
+ <div class="title">
|
|
|
+ <span class="line" />
|
|
|
+ <span class="name">设置标签</span>
|
|
|
+ <i class="el-icon-close icon" />
|
|
|
+ </div>
|
|
|
+ <div class="body">
|
|
|
+ <el-form-item style="width: 100%;margin-right: 0;" :rules="[{ required: true, message: '标签不能为空'}]" label="标签:" class="tag-from">
|
|
|
+ <el-select
|
|
|
+ style="width: 100%;"
|
|
|
+ ref="select"
|
|
|
+ v-model="tagSelectValue"
|
|
|
+ multiple
|
|
|
+ remote
|
|
|
+ filterable
|
|
|
+ allow-create
|
|
|
+ default-first-option
|
|
|
+ :placeholder="placeholder"
|
|
|
+ :remote-method="remoteMethod"
|
|
|
+ @click.stop
|
|
|
+ @change="change"
|
|
|
+ >
|
|
|
+ <el-option
|
|
|
+ v-for="(item, itemIndex) in options"
|
|
|
+ :key="itemIndex"
|
|
|
+ :label="item"
|
|
|
+ :value="item"
|
|
|
+ >
|
|
|
+ {{ item }}
|
|
|
+ </el-option>
|
|
|
+ </el-select>
|
|
|
<template slot="footer">
|
|
|
- <el-button @click="close">取消</el-button>
|
|
|
- <el-button @click="ok">添加</el-button>
|
|
|
+ <el-button size="small" @click="close">取消</el-button>
|
|
|
+ <el-button size="small" type="primary" @click="ok">确定</el-button>
|
|
|
</template>
|
|
|
- </Modal>
|
|
|
+ </el-form-item>
|
|
|
+ </div>
|
|
|
+ <div class="footer">
|
|
|
+ <el-button size="small" @click="close">取消</el-button>
|
|
|
+ <el-button size="small" type="primary" @click="ok">确定</el-button>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div class="bg" />
|
|
|
+ </div>
|
|
|
</div>
|
|
|
</template>
|
|
|
<script>
|
|
|
import Clickoutside from 'element-ui/src/utils/clickoutside'
|
|
|
-import { desDecryptId } from '@/utils/crypto-js'
|
|
|
+import { EncryptId, analysisBizId_id } from '@/utils/crypto-js.js'
|
|
|
import { taskGetTag } from '@/api/common'
|
|
|
import Modal from '@/components/modal'
|
|
|
|
|
@@ -106,8 +123,10 @@ export default {
|
|
|
this.visible = true
|
|
|
},
|
|
|
remoteMethod(searchTag = '') {
|
|
|
+ if (!this.$route.query.bizId) return
|
|
|
+ // const bizId_id = analysisBizId_id(this.$route.query.bizId)
|
|
|
// const bizId_id = window.localStorage.getItem('bizId')
|
|
|
- const bizId_id = desDecryptId(this.$route.query.bizId_id).replace(/_.*/, '')
|
|
|
+ const bizId_id = desDecryptId(this.$route.query.bizId).replace(/_.*/, '')
|
|
|
console.log(bizId_id)
|
|
|
taskGetTag({
|
|
|
type: this.type,
|
|
@@ -147,4 +166,73 @@ export default {
|
|
|
border: 1px solid rgba(220, 223, 230) !important;
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
+.dialogbox {
|
|
|
+ .box {
|
|
|
+ position: fixed;
|
|
|
+ top:20vh;
|
|
|
+ left: calc(50% - 250px);
|
|
|
+ width: 500px;
|
|
|
+ min-height: 180px;
|
|
|
+ // overflow: auto;
|
|
|
+ background: #fff;
|
|
|
+ z-index: 1000;
|
|
|
+ border-radius: 4px;
|
|
|
+ display: flex;
|
|
|
+ flex-direction: column;
|
|
|
+ box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
|
|
|
+ .title {
|
|
|
+ padding: 5px 0px 5px 18px;
|
|
|
+ // border-bottom: 1px solid #eee;
|
|
|
+ position: relative;
|
|
|
+ .line {
|
|
|
+ display: inline-block;
|
|
|
+ width: 4px;
|
|
|
+ height: 18px;
|
|
|
+ background: #409eff;
|
|
|
+ border-radius: 1px;
|
|
|
+ vertical-align: text-top;
|
|
|
+ }
|
|
|
+ .name {
|
|
|
+ margin-left: 6px;
|
|
|
+ color: rgba(0,0,0,.85);
|
|
|
+ font-weight: 500;
|
|
|
+ font-size: 16px;
|
|
|
+ line-height: 22px;
|
|
|
+ word-wrap: break-word;
|
|
|
+ }
|
|
|
+ .icon {
|
|
|
+ position: absolute;
|
|
|
+ top: 20px;
|
|
|
+ right: 20px;
|
|
|
+ font-size: 16px;
|
|
|
+ color: #909399;
|
|
|
+ cursor: pointer;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ .body {
|
|
|
+ padding: 15px 20px;
|
|
|
+ color: #606266;
|
|
|
+ font-size: 14px;
|
|
|
+ word-break: break-all;
|
|
|
+ // height: calc(80vh - 118px);
|
|
|
+ overflow: auto;
|
|
|
+ }
|
|
|
+ .footer {
|
|
|
+ padding: 15px 20px;
|
|
|
+ text-align: right;
|
|
|
+ // border-top: 1px solid #eee;
|
|
|
+ background: #fff;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ .bg {
|
|
|
+ background: rgba(000, 000, 000, 0.5);
|
|
|
+ position: fixed;
|
|
|
+ top: 0;
|
|
|
+ left: 0;
|
|
|
+ bottom: 0;
|
|
|
+ right: 0;
|
|
|
+ z-index: 100;
|
|
|
+ }
|
|
|
+}
|
|
|
</style>
|