Commit f9a4f0f5 by 前端

Merge branch 'v3.4.0' into 'master'

V3.4.0

See merge request !44
2 parents 536277c0 8930f830
This diff could not be displayed because it is too large.
......@@ -14,10 +14,10 @@
"el-tree-transfer": "^2.2.6",
"glsx-common": "^1.4.6",
"glsx-components": "^1.5.4",
"glsx-components_beta": "^1.0.3",
"glsx-table": "^1.0.9",
"vue-draggable-resizable": "^2.3.0",
"vuedraggable": "^2.24.3",
"word-edit": "^1.0.6",
"xlsx": "^0.18.5"
},
"devDependencies": {
......
import { http } from '@/main'
import { http, http_merchant } from '@/main'
const path = 'entmicro.api.mass.'
const URL = 'rop-scrm-entmicro/router'
//权益卡
......@@ -151,6 +151,15 @@ const getMerchantList = params => {
sign: true
})
}
const findMerchantListByPage = params => {
params.method = 'merchants.api.open.findMerchantListByPage'
return http_merchant({
url: '/rop-merchants/router',
method: 'POST',
data: params,
sign: true
})
}
const channelPreview = params => {
params.method = `scrm.api.shopmall.discover.channel.merchant.preview`
return http({
......@@ -177,5 +186,6 @@ export default {
templateSave,
bulgeActivity,
getMerchantList,
channelPreview
channelPreview,
findMerchantListByPage
}
......@@ -4,7 +4,7 @@
* @Author: limin
* @Date: 2021-06-07 14:12:32
* @LastEditors: yangming yangming@didihu.com.cn
* @LastEditTime: 2023-01-09 14:34:58
* @LastEditTime: 2023-01-14 16:04:28
*/
// 根据环境引入不同配置 process.env.VUE_APP_ENV
// let request = require('@/http/request.js')
......
......@@ -3,25 +3,26 @@
* @version: 1.0.0
* @Author: limin
* @Date: 2021-08-13 14:12:11
* @LastEditors: limin
* @LastEditTime: 2021-09-14 09:34:52
* @LastEditors: yangming yangming@didihu.com.cn
* @LastEditTime: 2023-01-12 17:24:27
* @FilePath: \scrm\scrm-sub-blog\src\main.js
*/
import Vue from "vue";
import apis from "./api";
import "./public-path";
import "./components";
import filters from "./utils/filters";
import Vue from 'vue'
import apis from './api'
import './public-path'
import './components'
import filters from './utils/filters'
// import 'glsx-components/dist/glsx-components.css'
import { start } from "@/setup";
Vue.config.productionTip = false;
Vue.prototype.$apis = apis;
import { start } from '@/setup'
Vue.config.productionTip = false
Vue.prototype.$apis = apis
//过滤器统一处理预加载
Object.keys(filters).forEach((key) => {
Vue.filter(key, filters[key]);
});
start();
export { bootstrap, mount, unmount } from "@/setup";
export const http = (params) => Vue.prototype.$http(params);
export const http_common = (params) => Vue.prototype.$http_common(params);
export const http_tag = (params) => Vue.prototype.$http_tag(params);
Object.keys(filters).forEach(key => {
Vue.filter(key, filters[key])
})
start()
export { bootstrap, mount, unmount } from '@/setup'
export const http = params => Vue.prototype.$http(params)
export const http_common = params => Vue.prototype.$http_common(params)
export const http_tag = params => Vue.prototype.$http_tag(params)
export const http_merchant = params => Vue.prototype.$http_merchant(params)
......@@ -22,6 +22,7 @@ export default {
name: '图片',
funcName: '',
type: 'img',
// limitPx: 1555200,
// togetherItem: [ATT_TYPE.TEXT], //只允许文本和图片
// limitSize: 10, //限制图片大小
// limitNum: 2, //限制图片数量
......@@ -30,6 +31,18 @@ export default {
// Isdraggable: true, //图片拖拽
uploadApi: this.$apis.common.pictureUpload
},
// {
// name: '视频',
// funcName: '',
// type: 'video',
// limitSize: 10, //限制视频大小
// togetherItem: [ATT_TYPE.TEXT], //只允许文本和图片
// isReplace: 1, //限制视频数量
// limitWidth: 1280, //限制视频宽度
// limitHeight: 720, //限制视频高度
// limitTime: 30, //限制视频时长
// uploadApi: this.$apis.common.pictureUpload
// },
{
name: '昵称',
type: 'nickname',
......
......@@ -2,7 +2,7 @@
* @Author: yangming yangming@didihu.com.cn
* @Date: 2022-11-25 10:20:02
* @LastEditors: yangming yangming@didihu.com.cn
* @LastEditTime: 2023-01-09 14:34:52
* @LastEditTime: 2023-01-16 15:59:09
* @FilePath: \scrm-micro-drainage\src\setup\qiankun.js
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/
......@@ -11,7 +11,7 @@ import Vue from 'vue'
import { fetchConfig } from '@/config'
import ElementUI from 'element-ui'
import { GLTable, GLButton, GLFooter, GLCombiForm } from 'glsx-components' //权限按钮 (根据权限动态创建)
import GLEditor from 'glsx-components_beta/src/packages/Editor'
import { GLEditor } from 'word-edit'
import { getRoutes } from '@/router'
import render from './render'
Vue.use(ElementUI)
......@@ -19,21 +19,23 @@ Vue.use(GLTable)
Vue.use(GLFooter)
Vue.use(GLCombiForm)
Vue.use(GLEditor)
// import GLTable from '@/components/glsx-table/index'
// import GLTable from '@/components/glsx-table/index'30293853
// import 'glsx-components/src/theme/theme.scss'
import 'glsx-components/dist/glsx-components.css'
import 'word-edit/dist/glsx-components.css'
import '@/assets/css/common.scss'
let routes = []
let router = null
let instance = null
export async function bootstrap({ name, id, history, common, messenger, globalState, routerBase }) {
const { response, request, sign, secret, request_common, sign_common, request_tag } = await fetchConfig(false)
const { response, request, sign, secret, request_common, sign_common, request_merchant, request_tag } = await fetchConfig(false)
Vue.prototype.$history = history
Vue.prototype.$messenger = messenger
Vue.prototype.$globalState = globalState
Vue.prototype.$common = common
Vue.prototype.$http = new common.Http({ response, request, sign, secret, alert: ElementUI.Message.error, headers: { token: globalState.session.token } })
Vue.prototype.$http_tag = new common.Http({ response, request: request_tag, sign, secret, alert: ElementUI.Message.error, headers: { token: globalState.session.token } })
Vue.prototype.$http_merchant = new common.Http({ response, request: request_merchant, sign, secret, alert: ElementUI.Message.error, headers: { token: globalState.session.token } })
Vue.prototype.$http_common = new common.Http({ response, signWay: 'md5', request: request_common, sign: sign_common, secret, alert: ElementUI.Message.error, headers: { TGT: globalState.session.token } })
const routesData = common.utils.deepClone(globalState.routers)
routes = getRoutes(routesData)
......
......@@ -122,17 +122,7 @@ util.isShowBtn = function(value, permissions) {
if (value && itm.path == value) {
isShowStatus = true
}
if (
!value &&
itm.path ==
'/' +
location.pathname
.split('/')
.slice(-2)
.join('/') &&
itm.meta &&
itm.meta.permissions.includes(permissions)
) {
if (!value && itm.meta && itm.meta.permissions.includes(permissions)) {
isShowStatus = true
}
if (itm.children) {
......
......@@ -253,6 +253,8 @@ export default {
}
})
param.tagging = JSON.stringify(tagging)
} else {
param.tagging = ''
}
param.autoWelcome = this.autoWelcome ? 1 : 0
param.codeSystem = 0
......@@ -282,6 +284,7 @@ export default {
return item
})
param.welcomeInfo = attachmentList
console.log(param.tagging)
this.$apis.channel[channel](param).then(res => {
if (res) this.$router.push('/channel/index')
})
......@@ -340,22 +343,23 @@ export default {
// window.removeEventListener('resize', this.resize)
// },
mounted() {
console.log(util.isShowBtn(null, '插入推荐频道'))
if (util.isShowBtn(null, '插入推荐频道')) {
this.btnList.push({
name: '插入推荐频道',
type: 'channelLink',
funName: 'channelLink',
getMerchantList: this.$apis.welcomeword.getMerchantList,
getMerchantList: this.$apis.welcomeword.findMerchantListByPage,
channelPreview: this.$apis.welcomeword.channelPreview
})
}
this.btnList.push({
name: '插入推荐频道',
type: 'channelLink',
funName: 'channelLink',
getMerchantList: this.$apis.welcomeword.getMerchantList,
channelPreview: this.$apis.welcomeword.channelPreview
})
// this.btnList.push({
// name: '插入推荐频道',
// type: 'channelLink',
// funName: 'channelLink',
// getMerchantList: this.$apis.welcomeword.getMerchantList,
// channelPreview: this.$apis.welcomeword.channelPreview
// })
const { id, codeUuid } = this.$route.params
if (id) {
this.codeId = id
......
......@@ -23,7 +23,18 @@
</div>
<div slot="staffInfo" slot-scope="scope">
<el-popover trigger="hover" placement="top" v-if="staffNameSplit(scope.scope.staffName).length > 3">
<GLFull :labelWidth="110" :label="item" textType="user" :identi="`text_${Math.random().toString().replace('.', '')}`" v-for="(item, index) in staffNameSplit(scope.scope.staffName)" :key="index"></GLFull>
<GLFull
:labelWidth="110"
:label="item"
textType="user"
:identi="
`text_${Math.random()
.toString()
.replace('.', '')}`
"
v-for="(item, index) in staffNameSplit(scope.scope.staffName)"
:key="index"
></GLFull>
<div slot="reference" class="name-wrapper">
<div style="display: inline-block" v-for="(item, index) in staffNameSplit(scope.scope.staffName)" :key="index" v-show="index < 4">
<template v-if="index == 3 && staffNameSplit(scope.scope.staffName).length > 3">
......@@ -36,7 +47,19 @@
</div>
</div>
</el-popover>
<GLFull :labelWidth="110" :label="item" textType="user" :identi="`text_${Math.random().toString().replace('.', '')}`" v-for="(item, index) in staffNameSplit(scope.scope.staffName)" :key="index" v-else></GLFull>
<GLFull
:labelWidth="110"
:label="item"
textType="user"
:identi="
`text_${Math.random()
.toString()
.replace('.', '')}`
"
v-for="(item, index) in staffNameSplit(scope.scope.staffName)"
:key="index"
v-else
></GLFull>
<!-- <div v-for="(item, index) in staffNameSplit(scope.scope.staffName)" :key="index" v-else>
<div class="accountType-row">
<i class="el-icon-user-solid"></i>
......@@ -45,7 +68,7 @@
</div> -->
</div>
<div slot="qrCode" slot-scope="scope">
<el-popover placement="bottom" trigger="click">
<el-popover placement="bottom" trigger="click">
<div>
<img :src="scope.scope.qrCode" style="width: 140px; height: 140px" />
<div class="download-link" @click="downloadIamge(scope.scope.qrCode)">下载二维码</div>
......@@ -80,7 +103,7 @@
</div>
</GLTable>
</div>
<GLDialog title="提示" @onOk="handleSure" @onCancel="dialogVisibleDel = false" type="error" content="是否删除?" :visible.sync="dialogVisibleDel" mode="small"></GLDialog>
<GLDialog title="提示" @onOk="handleSure" @onCancel="dialogVisibleDel = false" type="error" content="是否确定删除?" :visible.sync="dialogVisibleDel" mode="small"></GLDialog>
<emp-detail ref="empDetailForm"></emp-detail>
</div>
</template>
......
......@@ -156,7 +156,7 @@ export default {
reader.readAsDataURL(file)
reader.onload = img => {
console.log(file)
let type = fileName.split('.')[1]
let type = fileName.split('.').pop()
let imgUrl = img.target.result.split(',')[1]
// self.loadingImg = true;
self.$apis.common
......
......@@ -21,8 +21,9 @@
</el-row>
</el-form>
<GLTable v-loading="loading" ref="table" @refreshTable="handleSearch" :searchForm="tableSearchForm" :layout="layout" :tableData="tableData" :tableTotal="tableTotal" :pageConf="pageConf" :tableParams="tableParams">
<div slot="status" slot-scope="scope">
<span :class="['task_icon',scope.scope.status==1?'green-icon':'yellow-icon']">{{ scope.scope.statusName }}</span>
<div slot="status" slot-scope="scope">
<span :class="['task_icon', scope.scope.status == 1 ? 'green-icon' : 'yellow-icon']"></span>
{{ scope.scope.statusName }}
</div>
<div class="table-btns" slot="optionBtns" slot-scope="scope">
<el-button type="text" @click="handleDetail(scope.scope)">短信内容</el-button>
......@@ -177,6 +178,12 @@ export default {
color: #999999;
line-height: 20px;
}
.green-icon {
background: #2cca74;
}
.yellow-icon {
background: #fdb757;
}
.tag-panel {
.tag-item {
border-radius: 4px;
......
......@@ -36,7 +36,7 @@
</div>
</div>
<div class="drainage-form-item" v-if="selectType == 3">
<label style="margin: 0 0 0 32px">客户信息:</label>
<label style="margin: 0 0 0 32px">客户信息:</label>
<div class="upload-box">
<el-button size="small" @click="handleCrowd">
<i class="el-icon-plus"></i>
......@@ -58,7 +58,7 @@
</div>
</div>
<div class="drainage-form-item" v-if="selectType == 2">
<label style="margin: 0 0 0 32px">客户信息:</label>
<label style="margin: 0 0 0 32px">客户信息:</label>
<div class="upload-box">
<div class="upload-file-panel">
<div class="image-uploader">
......@@ -348,7 +348,7 @@ export default {
},
watch: {
'addForm.content': {
handler: function () {
handler: function() {
this.content = []
let str = this.addForm.content
let num = 70
......@@ -384,7 +384,7 @@ export default {
deep: true
},
tagging: {
handler: function () {
handler: function() {
this.taggingLength = 0
this.tagging.forEach(item => {
this.taggingLength += item.labelList.length
......@@ -496,7 +496,7 @@ export default {
},
uploadFile(e) {
const file = e.srcElement.files[0]
let AllImgExt = '.xls|.xlsx'
let AllImgExt = '.xls|.xlsx' //文件格式判断
let extName = file.name.substring(file.name.lastIndexOf('.')).toLowerCase()
if (AllImgExt.indexOf(extName) === -1) {
this.$message.error('上传格式不正确')
......@@ -507,7 +507,10 @@ export default {
reader.onload = event => {
const imgFile = event.target.result
const arrBase64 = imgFile.split(',')
const fileUrl = file.name.split('.')[1] + '@' + arrBase64[1]
const fileName = file.name.split('.')
//fileUrl: 文件名 + @ + base64拼接
const fileUrl = fileName.pop() + '@' + arrBase64[1]
//this.$apis.common.pictureUpload 调用接口api
this.$apis.common.pictureUpload({ file: fileUrl }).then(res => {
this.importName = file.name
this.exportUrl = res
......
......@@ -16,9 +16,10 @@
<div class="square-tabel-form">
<GLCombiForm :rowNumber="1" ref="formSearch" :formObj="tableSearchForm" :formData="searchFormData" @handleOk="handleSearch" @handleRest="handleReset"></GLCombiForm>
<GLTable ref="employeeRef" :getListApi="getListApi" :searchForm="tableSearchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn">
<div slot="imStatus" slot-scope="scope">
<span :class="['task_icon',scope.scope.imStatus==3?'green-icon':'yellow-icon']">{{ scope.scope.imStatusName }}</span>
</div>
<div slot="imStatus" slot-scope="scope">
<span :class="['task_icon', scope.scope.imStatus == 3 ? 'green-icon' : 'yellow-icon']"></span>
{{ scope.scope.imStatusName }}
</div>
<div class="table-btns" slot="optionBtns" slot-scope="scope">
<GLButton type="text" @click="handleDetail(scope.scope)" fn="智能营销配置">查看配置</GLButton>
<!-- <GLButton :disabled="scope.scope.imStatus!=1" type="text" @click="handleStatistics(scope.scope)" fn="营销统计">营销统计</GLButton> -->
......@@ -106,7 +107,7 @@ export default {
{
label: '状态',
prop: 'imStatusName',
addHtml:'imStatus'
addHtml: 'imStatus'
},
{
label: '创建时间',
......@@ -190,6 +191,12 @@ export default {
margin-top: 8px;
}
}
.green-icon {
background: #2cca74;
}
.yellow-icon {
background: #fdb757;
}
.dialog-wrap-box {
z-index: 2001;
position: fixed;
......
......@@ -327,7 +327,7 @@ export default {
reader.onload = event => {
const imgFile = event.target.result
const arrBase64 = imgFile.split(',')
const fileInfo = file.name.split('.')[1] + '@' + arrBase64[1]
const fileInfo = file.name.split('.').pop() + '@' + arrBase64[1]
uploadItem.fileInfo = fileInfo
uploadItem.size = size
uploadItem.fileName = file.name
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!