Commit 2d7610c7 by xuyl

更新样式以及组件删除

1 parent 5f1ed479

26.3 KB | W: | H:

26.8 KB | W: | H:

src/assets/leadManage/group.png
src/assets/leadManage/group.png
src/assets/leadManage/group.png
src/assets/leadManage/group.png
  • 2-up
  • Swipe
  • Onion skin
import GLCombiForm from './src/index.vue'
// 为组件提供 install 安装方法,供按需引入
GLCombiForm.install = function(Vue) {
Vue.component(GLCombiForm.name, GLCombiForm)
}
// 默认导出组件
export default GLCombiForm
\ No newline at end of file \ No newline at end of file
/**
* 时间控件-限制月份
*/
export const beforeRangePickerOptions = {
disabledDate(date) {
if (date > new Date()) {
return true
}
return false
}
}
export const afterRangePickerOptions = {
disabledDate(date) {
const yesterday = new Date(new Date().setDate(new Date().getDate() - 1))
if (date < yesterday) {
return true
}
return false
}
}
import GLSearch from './src/index.vue'
// 为组件提供 install 安装方法,供按需引入
GLSearch.install = function(Vue) {
Vue.component(GLSearch.name, GLSearch)
}
// 默认导出组件
export default GLSearch
\ No newline at end of file \ No newline at end of file
<!-- <content> -->
<GLSearch @onOk="handleOkFn" @onRest="handleRestFn">
<GLSearchItem>
<div slot="name">我是文本输入框</div>
<el-input size="small" v-model="input" placeholder="请输入内容"></el-input>
</GLSearchItem>
<GLSearchItem>
<div slot="name">我是文本输入框</div>
<el-select v-model="value" size="small" placeholder="请选择">
<el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value"></el-option>
</el-select>
</GLSearchItem>
<GLSearchItem>
<div slot="name">我是文本输入框</div>
<el-date-picker size="small" v-model="value1" type="datetimerange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期"></el-date-picker>
</GLSearchItem>
<GLSearchItem>
<el-select v-model="selvalue" placeholder="请选择" size="small" slot="name">
<el-option v-for="item in seloptions" :key="item.value" :label="item.label" :value="item.value"></el-option>
</el-select>
<el-input size="small" v-model="input" placeholder="请输入内容"></el-input>
</GLSearchItem>
</GLSearch>
<el-button type="warning" @click="toggleShow(1)">显示代码</el-button>
```js {mixin:true}
{
data() {
return {
demo1: true,
//gl-search数据
input: '',
options: [
{
value: '选项1',
label: '黄金糕'
},
{
value: '选项2',
label: '双皮奶'
},
{
value: '选项3',
label: '蚵仔煎'
},
{
value: '选项4',
label: '龙须面'
},
{
value: '选项5',
label: '北京烤鸭'
}
],
value: '',
value1: [new Date(2000, 10, 10, 10, 10), new Date(2000, 10, 11, 10, 10)],
seloptions: [
{
value: '选项1',
label: '黄金糕'
},
{
value: '选项2',
label: '双皮奶'
},
{
value: '选项3',
label: '蚵仔煎北京烤鸭'
},
{
value: '选项4',
label: '龙须面北京烤鸭'
},
{
value: '选项5',
label: '北京烤鸭北京烤鸭'
}
],
selvalue: ''
}
},
methods:{
toggleShow(num){
// console.log(123)
this['demo' + num] = !this['demo' + num]
},
//gl-search 方法
handleOkFn() {
console.log('您点击了确定')
},
handleRestFn() {
console.log('您点击了取消')
}
}
}
```
# 用来作为 markdown 代码的示例部分
<div v-if="demo1">
```vue
<template>
<GLSearch @onOk="handleOkFn" @onRest="handleRestFn">
<GLSearchItem>
<div slot="name">我是文本输入框</div>
<el-input size="small" v-model="input" placeholder="请输入内容"></el-input>
</GLSearchItem>
<GLSearchItem>
<div slot="name">我是文本输入框</div>
<el-select v-model="value" size="small" placeholder="请选择">
<el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value"></el-option>
</el-select>
</GLSearchItem>
<GLSearchItem>
<div slot="name">我是文本输入框</div>
<el-date-picker size="small" v-model="value1" type="datetimerange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期"></el-date-picker>
</GLSearchItem>
<GLSearchItem>
<el-select v-model="selvalue" placeholder="请选择" size="small" slot="name">
<el-option v-for="item in seloptions" :key="item.value" :label="item.label" :value="item.value"></el-option>
</el-select>
<el-input size="small" v-model="input" placeholder="请输入内容"></el-input>
</GLSearchItem>
</GLSearch>
</template>
<script>
import {GLSearch, GLSearchItem} from 'glsx-components'
// 全局引入一次css即可
import 'glsx-components/dist/glsx-components.css'
export default {
data() {
return {
//gl-search数据
input: '',
options: [
{
value: '选项1',
label: '黄金糕'
},
{
value: '选项2',
label: '双皮奶'
},
{
value: '选项3',
label: '蚵仔煎'
},
{
value: '选项4',
label: '龙须面'
},
{
value: '选项5',
label: '北京烤鸭'
}
],
value: '',
value1: [new Date(2000, 10, 10, 10, 10), new Date(2000, 10, 11, 10, 10)],
seloptions: [
{
value: '选项1',
label: '黄金糕'
},
{
value: '选项2',
label: '双皮奶'
},
{
value: '选项3',
label: '蚵仔煎北京烤鸭'
},
{
value: '选项4',
label: '龙须面北京烤鸭'
},
{
value: '选项5',
label: '北京烤鸭北京烤鸭'
}
],
selvalue: ''
}
},
methods: {
handleOkFn() {
console.log('您点击了确定')
},
handleRestFn() {
console.log('您点击了取消')
}
}
}
</script>
```
</div>
<!-- </content> -->
<template>
<div class="gl-search" id="gl-search" :class="{ transTo: !expand }">
<div class="search-list">
<!-- 默认插槽 -->
<slot></slot>
<!-- <div class="search-item">
<div class="name">我是文本输入框</div>
<div class="input">
<el-input
size="small"
v-model="input"
placeholder="请输入内容"
></el-input>
</div>
</div> -->
<!-- <div class="search-item">
<div class="name">我是文本输入框</div>
<div class="input">
<el-input
size="small"
v-model="input"
placeholder="请输入内容"
></el-input>
</div>
</div> -->
<!-- <div class="search-item">
<div class="name">我是文本输入框</div>
<div class="input">
<el-input
size="small"
v-model="input"
placeholder="请输入内容"
></el-input>
</div>
</div>
<div class="search-item">
<div class="name">我是文本输入框</div>
<div class="input">
<el-input
size="small"
v-model="input"
placeholder="请输入内容"
></el-input>
</div>
</div> -->
</div>
<div class="gl-operate">
<div class="operate">
<el-button size="small" type="primary" @click="handleOk">查询</el-button>
<el-button size="small" @click="handleRest">重置</el-button>
<el-button type="text" size="small" @click="expandFn" v-if="hasExpand">
<span>{{ !expand ? '展开' : '收起' }}</span>
<i class="expand" :class="classIcon"></i>
</el-button>
<!-- <i class="el-icon-arrow-down expand"></i> -->
<!-- <i class="el-icon-arrow-up"></i> -->
</div>
</div>
</div>
</template>
<script>
export default {
name: 'GLSearch',
props: {},
data() {
return {
// input: '',
expand: false,
itemNum: 0,
time: null,
hasExpand: false
}
},
created() {},
mounted() {
this.getItemNum()
// 判断宽度按,是否显示展开收起
this.getClientWith()
window.addEventListener('resize', this.getClientWith, false)
},
computed: {
classIcon() {
return !this.expand ? 'el-icon-arrow-down' : 'el-icon-arrow-up'
}
},
methods: {
// 展开收起
expandFn() {
this.expand = !this.expand
},
// 获取item 输入框 的个数
getItemNum() {
const items = document.getElementById('gl-search').getElementsByClassName('search-item').length
this.itemNum = items
},
// 判断是否有展开收起标志
ifHasExpand(nowCol) {
if (this.itemNum > nowCol) {
return true
}
return false
},
// 监听函数
getClientWith() {
if (this.time) clearTimeout(this.time)
this.time = setTimeout(() => {
const clientWidth = document.documentElement.clientWidth
// console.log('clientWidth: ', clientWidth)
if (clientWidth <= 800) {
// 1列
this.hasExpand = this.ifHasExpand(1)
} else if (clientWidth <= 1440 && clientWidth > 800) {
// 2列
this.hasExpand = this.ifHasExpand(2)
} else if (clientWidth <= 1720 && clientWidth > 1440) {
// 3列
this.hasExpand = this.ifHasExpand(3)
} else {
// 4列
this.hasExpand = this.ifHasExpand(4)
}
}, 300)
},
handleOk() {
// 点击确定的回调
this.$emit('onOk')
},
handleRest() {
// 点击重置的回调
this.$emit('onRest')
}
},
components: {},
watch: {},
beforeDestroy() {
window.removeEventListener('resize', this.getClientWith, false)
this.time = null
}
}
</script>
<style lang="scss">
.gl-search {
&.transTo {
height: 52px;
}
display: flex;
justify-content: space-between;
overflow: hidden;
// @media screen and (max-width: 1062px) {
// .search-list {
// .search-item {
// width: 100%;
// }
// }
// }
// @media screen and (min-width: 1062px) and (max-width: 1440px) {
// .search-list {
// .search-item {
// width: 100%;
// }
// }
// }
// @media screen and (min-width: 1440px) and (max-width: 1720px) {
// .search-list {
// .search-item {
// width: 100%;
// }
// }
// }
// @media screen and (min-width: 1720px) {
// .search-list {
// .search-item {
// width: 100%;
// }
// }
// }
.search-list {
.search-item {
width: 100%;
}
}
.search-list {
flex: 1;
display: flex;
flex-wrap: wrap;
.search-item {
// flex: 1;
// padding-right: 12px;
margin-bottom: 20px;
min-width: 276px;
display: flex;
align-items: center;
box-sizing: border-box;
.name {
width: 112px;
text-align: right;
font-size: 14px;
font-weight: 400;
color: #666;
}
.input {
flex: 1;
// width:100%;
}
.el-input {
width: 100%;
}
.el-select {
width: 100%;
}
.el-date-editor {
width: 100%;
}
}
}
.gl-operate {
display: flex;
align-items: flex-end;
.operate {
text-align: left;
width: 190px;
margin-bottom: 20px;
.expand {
font-size: 14px;
}
.el-button + .el-button {
margin-left: 8px;
}
}
}
}
</style>
import GLSearchItem from './src/index.vue'
// 为组件提供 install 安装方法,供按需引入
GLSearchItem.install = function(Vue) {
Vue.component(GLSearchItem.name, GLSearchItem)
}
// 默认导出组件
export default GLSearchItem
\ No newline at end of file \ No newline at end of file
<template>
<div :style="{ 'padding-right': spacer + 'px' }" class="search-item">
<div class="name">
<!-- {{ label }} -->
<!-- name 插槽 -->
<slot name="name"></slot>
</div>
<div class="input">
<!-- 默认插槽 -->
<slot></slot>
<!-- <el-input
size="small"
v-model="input"
placeholder="请输入内容"
></el-input> -->
</div>
</div>
</template>
<script>
export default {
name: 'GLSearchItem',
props: {
// 每个项间隙
spacer: {
type: Number,
default: 12
}
},
data () {
return {}
},
created () {},
mounted () {},
computed: {},
methods: {},
components: {},
watch: {}
}
</script>
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
<tr class="el-descriptions-row"> <tr class="el-descriptions-row">
<template v-for="(trTtem, idx) in item.colList"> <template v-for="(trTtem, idx) in item.colList">
<th :key="idx" :colspan="trTtem.thColspan" class="el-descriptions-item__cell el-descriptions-item__label is-bordered-label">{{ trTtem.label }}</th> <th :key="idx" :colspan="trTtem.thColspan" class="el-descriptions-item__cell el-descriptions-item__label is-bordered-label">{{ trTtem.label }}</th>
<td :key="idx" :colspan="trTtem.tdColspan" class="el-descriptions-item__cell el-descriptions-item__content" :style="{ color: trTtem.color }">{{ showData[trTtem.name] }}{{ trTtem.unit }}</td> <td :key="idx" :colspan="trTtem.tdColspan" class="el-descriptions-item__cell el-descriptions-item__content" :style="{ color: trTtem.color }">{{ showData[trTtem.name]? showData[trTtem.name] : ' — '}}</td>
</template> </template>
</tr> </tr>
</tbody> </tbody>
......
...@@ -2,25 +2,24 @@ import Vue from 'vue' ...@@ -2,25 +2,24 @@ import Vue from 'vue'
import { message } from '@/plugins/element.js' import { message } from '@/plugins/element.js'
import { fetchConfig } from '@/config' import { fetchConfig } from '@/config'
import ElementUI from 'element-ui' import ElementUI from 'element-ui'
import { GLButton, GLTable } from 'glsx-components' //权限按钮 (根据权限动态创建) import { GLButton, GLTable, GLCombiForm } from 'glsx-components' //权限按钮 (根据权限动态创建)
import { getRoutes } from '@/router' import { getRoutes } from '@/router'
import render from './render' import render from './render'
Vue.use(ElementUI) Vue.use(ElementUI)
Vue.use(GLTable) Vue.use(GLTable)
import GLCombiForm from '@/components/GlCombiForm'
Vue.use(GLCombiForm) Vue.use(GLCombiForm)
import 'glsx-components/dist/glsx-components.css' import 'glsx-components/dist/glsx-components.css'
let routes = [] let routes = []
let router = null let router = null
let instance = null let instance = null
// http:调的是新版标签的接口,http2:调的是客户相关接口;http3:企微授权那边的接口 目前导出接口都测试的:http3 // http:调的是新版标签的接口,http2:调的是客户相关接口;http3:企微授权那边的接口 目前导出接口都测试的:http3
export async function bootstrap({ name, id, history, common, messenger, globalState, routerBase }) { export async function bootstrap({ name, id, history, common, messenger, globalState, routerBase }) {
const { response, request, request2, request3, request4, sign, secret, sign_common, request_common } = await fetchConfig(globalState.configSwitch) //globalState.configSwitch const { response, request, request2, request3, request4, sign, secret, sign_common, request_common } = await fetchConfig(globalState.configSwitch) //globalState.configSwitch
Vue.prototype.$history = history Vue.prototype.$history = history
Vue.prototype.$messenger = messenger Vue.prototype.$messenger = messenger
Vue.prototype.$globalState = globalState Vue.prototype.$globalState = globalState
Vue.prototype.$common = common Vue.prototype.$common = common
Vue.prototype.$http = new common.Http({ response, request, sign, secret, alert: message.error, headers: { token: globalState.session.token } }) Vue.prototype.$http = new common.Http({ response, request, sign, secret, alert: message.error, headers: { token: 'scrm-base-8e25603f-bee5-4cc8-8151-bdce7c61d79e-rop' } })
Vue.prototype.$http2 = new common.Http({ response, request: request2, sign, secret, alert: message.error, headers: { token: globalState.session.token } }) Vue.prototype.$http2 = new common.Http({ response, request: request2, sign, secret, alert: message.error, headers: { token: globalState.session.token } })
Vue.prototype.$http3 = new common.Http({ response, request: request3, sign, secret, alert: message.error, headers: { token: globalState.session.token } }) Vue.prototype.$http3 = new common.Http({ response, request: request3, sign, secret, alert: message.error, headers: { token: globalState.session.token } })
// Vue.prototype.$http4 = new common.Http({ response, request: request4, sign, secret, alert: message.error, headers: { token: 'scrm-base-e2d4f962-4ca3-4044-83e7-01ba314d8e3d-rop' } }) // Vue.prototype.$http4 = new common.Http({ response, request: request4, sign, secret, alert: message.error, headers: { token: 'scrm-base-e2d4f962-4ca3-4044-83e7-01ba314d8e3d-rop' } })
...@@ -45,6 +44,7 @@ export async function unmount() { ...@@ -45,6 +44,7 @@ export async function unmount() {
instance = null instance = null
router = null router = null
} }
function subscribe({ messenger }) { function subscribe({ messenger }) {
messenger.subscribe(v => { messenger.subscribe(v => {
console.log(`监听到子应用${v.from}发来消息:`, v) console.log(`监听到子应用${v.from}发来消息:`, v)
......
...@@ -247,12 +247,5 @@ export default { ...@@ -247,12 +247,5 @@ export default {
border: 1px solid #5850ff; border: 1px solid #5850ff;
} }
} }
/deep/.sub-form-style {
@media screen and (min-width: 1440px) and (max-width: 1720px) {
.glsx-combi-form .el-form-item--small {
width: 50%;
}
}
}
} }
</style> </style>
...@@ -230,12 +230,12 @@ export default { ...@@ -230,12 +230,12 @@ export default {
border: 1px solid #5850ff; border: 1px solid #5850ff;
} }
} }
/deep/.sub-form-style { // /deep/.sub-form-style {
@media screen and (min-width: 1440px) and (max-width: 1720px) { // @media screen and (min-width: 1440px) and (max-width: 1720px) {
.glsx-combi-form .el-form-item--small { // .glsx-combi-form .el-form-item--small {
width: 50%; // width: 50%;
} // }
} // }
} // }
} }
</style> </style>
...@@ -244,12 +244,12 @@ export default { ...@@ -244,12 +244,12 @@ export default {
border: 1px solid #5850ff; border: 1px solid #5850ff;
} }
} }
/deep/ .sub-form-style { // /deep/ .sub-form-style {
@media screen and (min-width: 1440px) and (max-width: 1720px) { // @media screen and (min-width: 1440px) and (max-width: 1720px) {
.glsx-combi-form .el-form-item--small { // .glsx-combi-form .el-form-item--small {
width: 50%; // width: 50%;
} // }
} // }
} // }
} }
</style> </style>
...@@ -158,7 +158,8 @@ export default { ...@@ -158,7 +158,8 @@ export default {
}, },
{ {
label: '群主', label: '群主',
prop: 'groupHostName' prop: 'groupHostName',
minWidth: 130
}, },
{ {
label: '管理员', label: '管理员',
...@@ -388,7 +389,7 @@ export default { ...@@ -388,7 +389,7 @@ export default {
height: 100% !important; //设置高优先,以覆盖内联样式 height: 100% !important; //设置高优先,以覆盖内联样式
} }
} }
padding: 6px 20px 30px; padding: 20px 20px 30px;
box-shadow: 0 10px 20px 0 rgba(88, 80, 255, 0.1); box-shadow: 0 10px 20px 0 rgba(88, 80, 255, 0.1);
// min-width: 1300px; // min-width: 1300px;
background-color: #fff; background-color: #fff;
......
...@@ -448,7 +448,7 @@ export default { ...@@ -448,7 +448,7 @@ export default {
{ {
label: '添加时间', label: '添加时间',
prop: 'addTime', prop: 'addTime',
minWidth: 160, minWidth: 180,
align: 'left' align: 'left'
}, },
{ {
......
...@@ -566,7 +566,7 @@ export default { ...@@ -566,7 +566,7 @@ export default {
border: 1px solid #5850ff; border: 1px solid #5850ff;
} }
} }
padding: 6px 20px 30px; padding: 20px 20px 30px;
box-shadow: 0 10px 20px 0 rgba(88, 80, 255, 0.1); box-shadow: 0 10px 20px 0 rgba(88, 80, 255, 0.1);
// min-width: 1300px; // min-width: 1300px;
background-color: #fff; background-color: #fff;
......
...@@ -82,7 +82,10 @@ export default { ...@@ -82,7 +82,10 @@ export default {
data() { data() {
return { return {
url: url, url: url,
searchForm: {}, searchForm: {
status: '',
type: ''
},
leadManageFormList: [ leadManageFormList: [
{ {
type: 'input', type: 'input',
...@@ -100,7 +103,11 @@ export default { ...@@ -100,7 +103,11 @@ export default {
optionList: [ optionList: [
{ {
label: '全部', label: '全部',
value: null value: ''
},
{
label: '待跟进',
value: 0
}, },
{ {
label: '跟进中', label: '跟进中',
...@@ -129,7 +136,7 @@ export default { ...@@ -129,7 +136,7 @@ export default {
optionList: [ optionList: [
{ {
label: '全部', label: '全部',
value: null value: ''
}, },
// { // {
// label: '客户意见', // label: '客户意见',
...@@ -242,7 +249,10 @@ export default { ...@@ -242,7 +249,10 @@ export default {
}, },
//重置表格 //重置表格
resetTable() { resetTable() {
this.searchForm = {} this.searchForm = {
status: '',
type: ''
}
this.$refs.leadManage.refreshTable() this.$refs.leadManage.refreshTable()
}, },
// 跟进转换 // 跟进转换
......
...@@ -33,7 +33,7 @@ ...@@ -33,7 +33,7 @@
<div class="drainage-form-item"> <div class="drainage-form-item">
<label> <label>
售后线索跟进员工 售后线索跟进员工
<el-popover placement="top" width="400" trigger="hover" content="请在首页-跟进专员模块里创建售前专员,并选择员工来跟进维保预约、救援服务线索。"> <el-popover placement="top" width="400" trigger="hover" content="请在首页-跟进专员模块里创建售后专员,并选择员工来跟进维保预约、救援服务线索。">
<img src="@/assets/leadManage/grayquestion.png" slot="reference" class="count-item-question" /> <img src="@/assets/leadManage/grayquestion.png" slot="reference" class="count-item-question" />
</el-popover> </el-popover>
: :
......
<template> <template>
<div> <div>
<div class="scrm-sub-client-container"> <div class="scrm-sub-client-container" >
<div class="pageContent" :style="{ 'min-height': clientHeight + 'px' }"> <div class="pageContent" :style="{ 'min-height': clientHeight + 'px' }">
<!-- 基本信息 --> <!-- 基本信息 -->
<div class="baseTitle"> <div class="baseTitle">
...@@ -17,14 +17,20 @@ ...@@ -17,14 +17,20 @@
<div class="baseTitle"> <div class="baseTitle">
<p class="title">跟进记录</p> <p class="title">跟进记录</p>
<hr /> <hr />
<div class="timestamp"> <div class="timestamp" v-if="this.leadFollowRecord.length > 0">
<el-timeline> <el-timeline>
<el-timeline-item v-for="(item, index) in leadFollowRecord" :key="index" :timestamp="item.followDate" placement="top" :color="index === 0 ? '#5850FF' : ''"> <el-timeline-item v-for="(item, index) in leadFollowRecord" :key="index" :timestamp="item.followDate" placement="top" :color="index === 0 ? '#5850FF' : ''">
<p class="conductor">处理人:<span>{{ item.userName }}</span></p> <p class="conductor">
处理人:
<span>{{ item.userName }}</span>
</p>
<p class="remark">{{ item.remark }}</p> <p class="remark">{{ item.remark }}</p>
</el-timeline-item> </el-timeline-item>
</el-timeline> </el-timeline>
</div> </div>
<div class="noRecord" v-else>
<img src="@/assets/leadManage/noRecord.png" alt="" />
</div>
</div> </div>
</div> </div>
</div> </div>
...@@ -204,7 +210,6 @@ export default { ...@@ -204,7 +210,6 @@ export default {
box-shadow: 0 10px 20px 0 rgba(88, 80, 255, 0.1); box-shadow: 0 10px 20px 0 rgba(88, 80, 255, 0.1);
// min-width: 1300px; // min-width: 1300px;
background-color: #fff; background-color: #fff;
margin-bottom: 75px;
.leadAllocation { .leadAllocation {
width: 700px; width: 700px;
display: flex; display: flex;
...@@ -235,8 +240,8 @@ export default { ...@@ -235,8 +240,8 @@ export default {
} }
.conductor { .conductor {
font-size: 14px; font-size: 14px;
>span{ > span {
padding-left: 8px; padding-left: 4px;
} }
} }
.remark { .remark {
...@@ -245,6 +250,10 @@ export default { ...@@ -245,6 +250,10 @@ export default {
} }
} }
} }
.noRecord{
display: flex;
justify-content: center;
}
} }
} }
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!