Commit 71e2e732 by 杨明

fixed

1 parent e90f6b97
This diff could not be displayed because it is too large.
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
"glsx-table": "^1.0.9", "glsx-table": "^1.0.9",
"vue-draggable-resizable": "^2.3.0", "vue-draggable-resizable": "^2.3.0",
"vuedraggable": "^2.24.3", "vuedraggable": "^2.24.3",
"word-edit": "^1.0.0", "word-edit": "^1.0.2",
"xlsx": "^0.18.5" "xlsx": "^0.18.5"
}, },
"devDependencies": { "devDependencies": {
......
import { http } from '@/main' import { http, http_merchant } from '@/main'
const path = 'entmicro.api.mass.' const path = 'entmicro.api.mass.'
const URL = 'rop-scrm-entmicro/router' const URL = 'rop-scrm-entmicro/router'
//权益卡 //权益卡
...@@ -151,6 +151,15 @@ const getMerchantList = params => { ...@@ -151,6 +151,15 @@ const getMerchantList = params => {
sign: true 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 => { const channelPreview = params => {
params.method = `scrm.api.shopmall.discover.channel.merchant.preview` params.method = `scrm.api.shopmall.discover.channel.merchant.preview`
return http({ return http({
...@@ -177,5 +186,6 @@ export default { ...@@ -177,5 +186,6 @@ export default {
templateSave, templateSave,
bulgeActivity, bulgeActivity,
getMerchantList, getMerchantList,
channelPreview channelPreview,
findMerchantListByPage
} }
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
* @Author: limin * @Author: limin
* @Date: 2021-06-07 14:12:32 * @Date: 2021-06-07 14:12:32
* @LastEditors: yangming yangming@didihu.com.cn * @LastEditors: yangming yangming@didihu.com.cn
* @LastEditTime: 2023-01-09 14:34:58 * @LastEditTime: 2023-01-12 17:27:51
*/ */
// 根据环境引入不同配置 process.env.VUE_APP_ENV // 根据环境引入不同配置 process.env.VUE_APP_ENV
// let request = require('@/http/request.js') // let request = require('@/http/request.js')
...@@ -17,8 +17,8 @@ export const fetchConfig = function(isEnv = true) { ...@@ -17,8 +17,8 @@ export const fetchConfig = function(isEnv = true) {
Object.assign(request, { timeout }) Object.assign(request, { timeout })
return Promise.resolve(cfg) return Promise.resolve(cfg)
} }
return new Http({ request: { timeout: 100000 } }).get('https://oss-config.test.glsx.com.cn/mock/618a32851072f92988f05a17/drainage/config') // return new Http({ request: { timeout: 100000 } }).get('https://oss-config.test.glsx.com.cn/mock/618a32851072f92988f05a17/drainage/config')
// return new Http({ request: { timeout: 100000 } }).get('https://oss-config.dev.glsx.com.cn/mock/618a32851072f92988f05a17/drainage/config') return new Http({ request: { timeout: 100000 } }).get('https://oss-config.dev.glsx.com.cn/mock/618a32851072f92988f05a17/drainage/config')
} }
export const config = { export const config = {
install(vue, cfg) { install(vue, cfg) {
......
...@@ -3,25 +3,26 @@ ...@@ -3,25 +3,26 @@
* @version: 1.0.0 * @version: 1.0.0
* @Author: limin * @Author: limin
* @Date: 2021-08-13 14:12:11 * @Date: 2021-08-13 14:12:11
* @LastEditors: limin * @LastEditors: yangming yangming@didihu.com.cn
* @LastEditTime: 2021-09-14 09:34:52 * @LastEditTime: 2023-01-12 17:24:27
* @FilePath: \scrm\scrm-sub-blog\src\main.js * @FilePath: \scrm\scrm-sub-blog\src\main.js
*/ */
import Vue from "vue"; import Vue from 'vue'
import apis from "./api"; import apis from './api'
import "./public-path"; import './public-path'
import "./components"; import './components'
import filters from "./utils/filters"; import filters from './utils/filters'
// import 'glsx-components/dist/glsx-components.css' // import 'glsx-components/dist/glsx-components.css'
import { start } from "@/setup"; import { start } from '@/setup'
Vue.config.productionTip = false; Vue.config.productionTip = false
Vue.prototype.$apis = apis; Vue.prototype.$apis = apis
//过滤器统一处理预加载 //过滤器统一处理预加载
Object.keys(filters).forEach((key) => { Object.keys(filters).forEach(key => {
Vue.filter(key, filters[key]); Vue.filter(key, filters[key])
}); })
start(); start()
export { bootstrap, mount, unmount } from "@/setup"; export { bootstrap, mount, unmount } from '@/setup'
export const http = (params) => Vue.prototype.$http(params); export const http = params => Vue.prototype.$http(params)
export const http_common = (params) => Vue.prototype.$http_common(params); export const http_common = params => Vue.prototype.$http_common(params)
export const http_tag = (params) => Vue.prototype.$http_tag(params); export const http_tag = params => Vue.prototype.$http_tag(params)
export const http_merchant = params => Vue.prototype.$http_merchant(params)
...@@ -31,6 +31,18 @@ export default { ...@@ -31,6 +31,18 @@ export default {
// Isdraggable: true, //图片拖拽 // Isdraggable: true, //图片拖拽
uploadApi: this.$apis.common.pictureUpload 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: '昵称', name: '昵称',
type: 'nickname', type: 'nickname',
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* @Author: yangming yangming@didihu.com.cn * @Author: yangming yangming@didihu.com.cn
* @Date: 2022-11-25 10:20:02 * @Date: 2022-11-25 10:20:02
* @LastEditors: yangming yangming@didihu.com.cn * @LastEditors: yangming yangming@didihu.com.cn
* @LastEditTime: 2023-01-11 18:10:20 * @LastEditTime: 2023-01-12 18:00:44
* @FilePath: \scrm-micro-drainage\src\setup\qiankun.js * @FilePath: \scrm-micro-drainage\src\setup\qiankun.js
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/ */
...@@ -28,13 +28,14 @@ let routes = [] ...@@ -28,13 +28,14 @@ let routes = []
let router = null let router = null
let instance = null let instance = null
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, 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.$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: ElementUI.Message.error, headers: { token: globalState.session.token } }) 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_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 } }) 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) const routesData = common.utils.deepClone(globalState.routers)
routes = getRoutes(routesData) routes = getRoutes(routesData)
......
...@@ -349,7 +349,7 @@ export default { ...@@ -349,7 +349,7 @@ export default {
name: '插入推荐频道', name: '插入推荐频道',
type: 'channelLink', type: 'channelLink',
funName: 'channelLink', funName: 'channelLink',
getMerchantList: this.$apis.welcomeword.getMerchantList, getMerchantList: this.$apis.welcomeword.findMerchantListByPage,
channelPreview: this.$apis.welcomeword.channelPreview channelPreview: this.$apis.welcomeword.channelPreview
}) })
} }
......
...@@ -156,7 +156,7 @@ export default { ...@@ -156,7 +156,7 @@ export default {
reader.readAsDataURL(file) reader.readAsDataURL(file)
reader.onload = img => { reader.onload = img => {
console.log(file) console.log(file)
let type = fileName.split('.')[1] let type = fileName.split('.').pop()
let imgUrl = img.target.result.split(',')[1] let imgUrl = img.target.result.split(',')[1]
// self.loadingImg = true; // self.loadingImg = true;
self.$apis.common self.$apis.common
......
...@@ -36,7 +36,7 @@ ...@@ -36,7 +36,7 @@
</div> </div>
</div> </div>
<div class="drainage-form-item" v-if="selectType == 3"> <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"> <div class="upload-box">
<el-button size="small" @click="handleCrowd"> <el-button size="small" @click="handleCrowd">
<i class="el-icon-plus"></i> <i class="el-icon-plus"></i>
...@@ -58,7 +58,7 @@ ...@@ -58,7 +58,7 @@
</div> </div>
</div> </div>
<div class="drainage-form-item" v-if="selectType == 2"> <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-box">
<div class="upload-file-panel"> <div class="upload-file-panel">
<div class="image-uploader"> <div class="image-uploader">
...@@ -348,7 +348,7 @@ export default { ...@@ -348,7 +348,7 @@ export default {
}, },
watch: { watch: {
'addForm.content': { 'addForm.content': {
handler: function () { handler: function() {
this.content = [] this.content = []
let str = this.addForm.content let str = this.addForm.content
let num = 70 let num = 70
...@@ -384,7 +384,7 @@ export default { ...@@ -384,7 +384,7 @@ export default {
deep: true deep: true
}, },
tagging: { tagging: {
handler: function () { handler: function() {
this.taggingLength = 0 this.taggingLength = 0
this.tagging.forEach(item => { this.tagging.forEach(item => {
this.taggingLength += item.labelList.length this.taggingLength += item.labelList.length
...@@ -496,7 +496,7 @@ export default { ...@@ -496,7 +496,7 @@ export default {
}, },
uploadFile(e) { uploadFile(e) {
const file = e.srcElement.files[0] const file = e.srcElement.files[0]
let AllImgExt = '.xls|.xlsx' let AllImgExt = '.xls|.xlsx' //文件格式判断
let extName = file.name.substring(file.name.lastIndexOf('.')).toLowerCase() let extName = file.name.substring(file.name.lastIndexOf('.')).toLowerCase()
if (AllImgExt.indexOf(extName) === -1) { if (AllImgExt.indexOf(extName) === -1) {
this.$message.error('上传格式不正确') this.$message.error('上传格式不正确')
...@@ -507,7 +507,10 @@ export default { ...@@ -507,7 +507,10 @@ export default {
reader.onload = event => { reader.onload = event => {
const imgFile = event.target.result const imgFile = event.target.result
const arrBase64 = imgFile.split(',') 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.$apis.common.pictureUpload({ file: fileUrl }).then(res => {
this.importName = file.name this.importName = file.name
this.exportUrl = res this.exportUrl = res
......
...@@ -327,7 +327,7 @@ export default { ...@@ -327,7 +327,7 @@ export default {
reader.onload = event => { reader.onload = event => {
const imgFile = event.target.result const imgFile = event.target.result
const arrBase64 = imgFile.split(',') const arrBase64 = imgFile.split(',')
const fileInfo = file.name.split('.')[1] + '@' + arrBase64[1] const fileInfo = file.name.split('.').pop() + '@' + arrBase64[1]
uploadItem.fileInfo = fileInfo uploadItem.fileInfo = fileInfo
uploadItem.size = size uploadItem.size = size
uploadItem.fileName = file.name 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!