提交 9a7302f9 authored 作者: 王鹏飞's avatar 王鹏飞

Merge branch 'master' into wuxt

...@@ -23,7 +23,7 @@ export function getSignature() { ...@@ -23,7 +23,7 @@ export function getSignature() {
// 图片上传 // 图片上传
export function uploadFile(data: Record<string, any>) { export function uploadFile(data: Record<string, any>) {
return httpRequest return httpRequest
.post('https://webapp-pub.oss-cn-beijing.aliyuncs.com', data, { .post(data.host || 'https://webapp-pub.ezijing.com', data, {
withCredentials: false, withCredentials: false,
headers: { 'Content-Type': 'multipart/form-data' } headers: { 'Content-Type': 'multipart/form-data' }
}) })
......
...@@ -20,6 +20,7 @@ const ImageUploadHandler = (blobInfo: any) => ...@@ -20,6 +20,7 @@ const ImageUploadHandler = (blobInfo: any) =>
const { accessid, policy, signature, host } = response const { accessid, policy, signature, host } = response
const params = { const params = {
key, key,
host,
OSSAccessKeyId: accessid, OSSAccessKeyId: accessid,
policy, policy,
signature, signature,
......
...@@ -46,6 +46,7 @@ const handleBeforeUpload = async (file: any) => { ...@@ -46,6 +46,7 @@ const handleBeforeUpload = async (file: any) => {
const response: Record<string, any> = await getSignature() const response: Record<string, any> = await getSignature()
uploadData.value = { uploadData.value = {
key, key,
host: response.host,
OSSAccessKeyId: response.accessid, OSSAccessKeyId: response.accessid,
policy: response.policy, policy: response.policy,
signature: response.signature, signature: response.signature,
...@@ -118,7 +119,7 @@ const handlePreview: UploadProps['onPreview'] = uploadFile => { ...@@ -118,7 +119,7 @@ const handlePreview: UploadProps['onPreview'] = uploadFile => {
<template> <template>
<el-upload <el-upload
action="https://webapp-pub.oss-cn-beijing.aliyuncs.com" :action="uploadData?.host"
:data="uploadData" :data="uploadData"
:show-file-list="showFileList" :show-file-list="showFileList"
:before-upload="handleBeforeUpload" :before-upload="handleBeforeUpload"
...@@ -128,8 +129,7 @@ const handlePreview: UploadProps['onPreview'] = uploadFile => { ...@@ -128,8 +129,7 @@ const handlePreview: UploadProps['onPreview'] = uploadFile => {
:on-success="handleSuccess" :on-success="handleSuccess"
:file-list="fileList" :file-list="fileList"
:limit="limit" :limit="limit"
class="uploader" class="uploader">
>
<slot> <slot>
<template v-if="showFileList"> <template v-if="showFileList">
<template v-if="$attrs['list-type'] === 'picture-card'"> <template v-if="$attrs['list-type'] === 'picture-card'">
......
...@@ -4,6 +4,10 @@ import Layout from '@/components/layout/Index.vue' ...@@ -4,6 +4,10 @@ import Layout from '@/components/layout/Index.vue'
const routes: RouteRecordRaw[] = [ const routes: RouteRecordRaw[] = [
{ {
path: '/analyze', path: '/analyze',
redirect: '/analyze/user'
},
{
path: '/analyze/user',
component: Layout, component: Layout,
children: [{ path: '', component: () => import('./views/Index.vue') }] children: [{ path: '', component: () => import('./views/Index.vue') }]
} }
......
<template>
<iframe
src="https://bi.ezijing.com/bi//?proc=1&action=viewer&hback=true&isInPreview=true&db=!7d2b!!8346!!6559!!80b2!!6570!!5b57!!8425!!9500!!5206!!6790!!2f!RIO!7528!!6237!!753b!!50cf!!5206!!6790!.db&platform=PC&browserType=chrome"
class="iframe"></iframe>
</template>
<style lang="scss">
.iframe {
display: block;
padding: 0;
margin: 0;
border: 0;
width: 100%;
height: calc(100vh - 90px);
}
</style>
<template>
<AppCard></AppCard>
</template>
...@@ -32,11 +32,11 @@ const edit = function () { ...@@ -32,11 +32,11 @@ const edit = function () {
<template> <template>
<div class="connect-item"> <div class="connect-item">
<div class="connect-item__edit"> <div class="connect-item__edit">
<!-- <img @click="edit" src="https://webapp-pub.oss-cn-beijing.aliyuncs.com/pages/assa/dml_edit.png" alt="" /> --> <!-- <img @click="edit" src="https://webapp-pub.ezijing.com/pages/assa/dml_edit.png" alt="" /> -->
<el-icon size="20" color="#333" @click="edit"><Edit /></el-icon> <el-icon size="20" color="#333" @click="edit"><Edit /></el-icon>
</div> </div>
<div class="connect-item__remove" @click="handleRemove"> <div class="connect-item__remove" @click="handleRemove">
<!-- <img src="https://webapp-pub.oss-cn-beijing.aliyuncs.com/pages/assa/dml_delete.png" alt="" /> --> <!-- <img src="https://webapp-pub.ezijing.com/pages/assa/dml_delete.png" alt="" /> -->
<el-icon size="20" color="#333"><Delete /></el-icon> <el-icon size="20" color="#333"><Delete /></el-icon>
</div> </div>
<div @click="routerView" style="display: flex; width: 100%; flex-direction: column; align-items: center"> <div @click="routerView" style="display: flex; width: 100%; flex-direction: column; align-items: center">
......
...@@ -86,16 +86,14 @@ const getDate = function (date: string) { ...@@ -86,16 +86,14 @@ const getDate = function (date: string) {
<div <div
:class="item.isActive ? 'content-user_item active' : 'content-user_item'" :class="item.isActive ? 'content-user_item active' : 'content-user_item'"
v-for="item in userList" v-for="item in userList"
@click="handleUser(item)" @click="handleUser(item)">
>
<img <img
:src=" :src="
item?.gender === '1' item?.gender === '1'
? 'https://webapp-pub.oss-cn-beijing.aliyuncs.com/pages/assa/dml_boy.png' ? 'https://webapp-pub.ezijing.com/pages/assa/dml_boy.png'
: 'https://webapp-pub.oss-cn-beijing.aliyuncs.com/pages/assa/dml_girl.png' : 'https://webapp-pub.ezijing.com/pages/assa/dml_girl.png'
" "
alt="" alt="" />
/>
<div class="name">{{ item.name }}</div> <div class="name">{{ item.name }}</div>
</div> </div>
</div> </div>
......
...@@ -44,12 +44,11 @@ const getDate = function (date: string) { ...@@ -44,12 +44,11 @@ const getDate = function (date: string) {
<img <img
:src=" :src="
data?.gender === '1' data?.gender === '1'
? 'https://webapp-pub.oss-cn-beijing.aliyuncs.com/pages/assa/dml_boy.png' ? 'https://webapp-pub.ezijing.com/pages/assa/dml_boy.png'
: 'https://webapp-pub.oss-cn-beijing.aliyuncs.com/pages/assa/dml_girl.png' : 'https://webapp-pub.ezijing.com/pages/assa/dml_girl.png'
" "
alt="" alt="" />
/> <!-- https://webapp-pub.ezijing.com/pages/assa/dml_boy.png -->
<!-- https://webapp-pub.oss-cn-beijing.aliyuncs.com/pages/assa/dml_boy.png -->
<!-- <el-icon :size="50" color="#fff"><UserFilled /></el-icon> --> <!-- <el-icon :size="50" color="#fff"><UserFilled /></el-icon> -->
</div> </div>
<h1>{{ data?.name }}</h1> <h1>{{ data?.name }}</h1>
...@@ -119,8 +118,7 @@ const getDate = function (date: string) { ...@@ -119,8 +118,7 @@ const getDate = function (date: string) {
<el-empty <el-empty
v-if="!data?.static_groups || !data?.static_groups.length" v-if="!data?.static_groups || !data?.static_groups.length"
description="暂无数据" description="暂无数据"
:image-size="80" :image-size="80" />
/>
<div class="scroll" v-else> <div class="scroll" v-else>
<el-tag class="ml-2" type="success" v-for="item in data?.static_groups">{{ item }}</el-tag> <el-tag class="ml-2" type="success" v-for="item in data?.static_groups">{{ item }}</el-tag>
</div> </div>
...@@ -131,8 +129,7 @@ const getDate = function (date: string) { ...@@ -131,8 +129,7 @@ const getDate = function (date: string) {
<el-empty <el-empty
v-if="!data?.dynamic_groups || !data?.static_groups.length" v-if="!data?.dynamic_groups || !data?.static_groups.length"
description="暂无数据" description="暂无数据"
:image-size="80" :image-size="80" />
/>
<div class="scroll" v-else> <div class="scroll" v-else>
<el-tag class="ml-2" type="success" v-for="item in data?.dynamic_groups">{{ item }}</el-tag> <el-tag class="ml-2" type="success" v-for="item in data?.dynamic_groups">{{ item }}</el-tag>
</div> </div>
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
import { Plus, Download, Upload, Delete } from '@element-plus/icons-vue' import { Plus, Download, Upload, Delete } from '@element-plus/icons-vue'
import AppList from '@/components/base/AppList.vue' import AppList from '@/components/base/AppList.vue'
import { getMemberList, deleteMember, getMemberConnectionsList } from '../api' import { getMemberList, deleteMember, getMemberConnectionsList } from '../api'
import { ElMessage, ElMessageBox } from 'element-plus' import { ElMessage, ElMessageBox, ElLoading } from 'element-plus'
import type { MemberProp, ConnectionsProp } from '../types' import type { MemberProp, ConnectionsProp } from '../types'
const UpdateDialog = defineAsyncComponent(() => import('../components/UpdateDialog.vue')) const UpdateDialog = defineAsyncComponent(() => import('../components/UpdateDialog.vue'))
...@@ -125,8 +125,15 @@ const handleRemoves = function () { ...@@ -125,8 +125,15 @@ const handleRemoves = function () {
deleteMembers(ids) deleteMembers(ids)
} }
let loading = $ref<any>()
const deleteMembers = function (ids: string) { const deleteMembers = function (ids: string) {
loading = ElLoading.service({
lock: true,
text: 'Loading',
background: 'rgba(0, 0, 0, 0.7)'
})
deleteMember({ ids: ids }).then(res => { deleteMember({ ids: ids }).then(res => {
loading.close()
ElMessage({ message: '删除成功', type: 'success' }) ElMessage({ message: '删除成功', type: 'success' })
handleRefresh() handleRefresh()
}) })
......
...@@ -189,7 +189,8 @@ const adminMenus: IMenuItem[] = [ ...@@ -189,7 +189,8 @@ const adminMenus: IMenuItem[] = [
{ {
name: '报表分析', name: '报表分析',
path: '/analyze', path: '/analyze',
icon: markRaw(IconAnalyze) icon: markRaw(IconAnalyze),
children: [{ name: '用户画像', path: '/analyze/user' }]
} }
] ]
......
...@@ -6,6 +6,7 @@ export async function upload(blob: Blob) { ...@@ -6,6 +6,7 @@ export async function upload(blob: Blob) {
const response: any = await getSignature() const response: any = await getSignature()
const params = { const params = {
key, key,
host: response.host,
OSSAccessKeyId: response.accessid, OSSAccessKeyId: response.accessid,
policy: response.policy, policy: response.policy,
signature: response.signature, signature: response.signature,
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论