提交 f80d52cf 作者: Hao

add

父级 4e581bb4
NODE_ENV=development
VITE_USER_APP_API_URL=192.168.31.135
\ No newline at end of file
VITE_USER_APP_API_URL=192.168.31.112
\ No newline at end of file
NODE_ENV=production
VITE_USER_APP_API_URL=192.168.31.101
\ No newline at end of file
VITE_USER_APP_API_URL=192.168.31.112
\ No newline at end of file
......@@ -99,7 +99,6 @@ export const upLoadHander = async (obj: any) => {
uploadMixin.uploadMixinType = result.uploadType;
staticDomain = result.staticDomain || "https://cdn.tikcos.cn";
if (uploadMixin.uploadMixinType === "txcos") {
console.log(result.response, " result.response");
const ress = res.result.response;
const credentials = ress.credentials;
uploadMixin.uploadMixinCredentials = {
......@@ -109,11 +108,6 @@ export const upLoadHander = async (obj: any) => {
StartTime: ress?.startTime,
ExpiredTime: ress?.expiredTime,
};
console.log(result, "result");
console.log(
uploadMixin.uploadMixinCredentials,
" uploadMixin.uploadMixinCredentials"
);
}
} else {
resResult = false;
......@@ -123,10 +117,7 @@ export const upLoadHander = async (obj: any) => {
if (resResult) {
const query = {};
// const res: any = await getUploadConfigInfo(query);
console.log(
uploadMixin.uploadMixinCredentials,
" console.log(uploadMixin.uploadMixinCredentials)"
);
const result: any = uploadMixin.upLoadMixinResult;
if (uploadMixin.uploadMixinType === "txcos") {
//走对象存储
......@@ -147,17 +138,10 @@ export const upLoadHander = async (obj: any) => {
Key: uploadMixin.uploadMixinPath + tempFolder + folder,
Body: fileInfo.file,
onProgress: function (progressData) {
console.log(progressData, "ada");
obj.onProgress(progressData);
},
},
(err, data) => {
console.log(err, data, "打印一下");
console.log({ success: true });
console.log(
`${staticDomain}/${uploadMixin.uploadMixinPath}${tempFolder}${folder}`,
"打印一下,数据"
);
if (!err && data.statusCode === 200) {
const imgurl = `${staticDomain}/${uploadMixin.uploadMixinPath}${tempFolder}${folder}`;
......@@ -178,7 +162,8 @@ export const upLoadHander = async (obj: any) => {
let formData = new FormData();
formData.append("biz", fileInfo.biz);
formData.append("file", newFile);
const uploadRes = await axios.post(`http://${VUE_APP_API_URL}:8080/sys/common/upload`,
const uploadRes = await axios.post(
`http://${VUE_APP_API_URL}:8080/sys/common/upload`,
formData,
{
headers: { ...obj.headers },
......@@ -193,6 +178,7 @@ export const upLoadHander = async (obj: any) => {
url = uploadRes.message.replaceAll("//", "/");
const pre = url.startsWith("/") ? "" : "/";
url = `http://${VUE_APP_API_URL}/sys/common/static` + pre + url;
console.log(url, "图片上传失败");
obj.onSuccess({ success: true, message: url });
} else {
obj.onError({
......
export type appType = {
sidebar:{
opened:boolean;
withoutAnimation: boolean;
isClickCollapse: boolean;
}
}
export type setType ={
path:string,
name:string,
query?:object
}
\ No newline at end of file
......@@ -32,7 +32,9 @@ export const useUserStore = defineStore("user", {
return new Promise((resolve, reject) => {
const query = {
code: this.userInfo.username,
name:res.nickame
};
console.log(query)
getUserList(query).then(({ success, result, message }: any) => {
if (success) {
this.userList = result.map((item: any) => {
......
......@@ -3,12 +3,11 @@
<el-container>
<el-aside width="280px" class="el-aside-left">
<el-header class="el-header-left">
<el-input placeholder="搜索" />
<el-input placeholder="搜索" v-model="queryParams.nickame" @input="handleInput" />
</el-header>
<div
active-text-color="#000"
background-co
lor="#fff"
background-color="#fff"
class="el-menu-item-box"
>
<div
......@@ -16,7 +15,7 @@
:class="getMenuItem(item)"
:index="item?.id"
:key="item?.id"
v-for="item in list"
v-for="(item, index) in list"
@click="handleMenuClick(item)"
>
<div class="user-info-box">
......@@ -331,7 +330,6 @@ import { InquiryAdd, checkMesssages } from '../axios/model/user'
import useMenu from '@/components/Menu/RightClickMenu'
import ShopList from '@/components/ShopList.vue'
let { showContextMenu } = useMenu()
console.log(useMenu(), 'useMenu')
const ruleForm = ref({})
const ruleFormRef = ref<FormInstance>()
const shopListRef = ref(null)
......@@ -340,7 +338,6 @@ const getUseUserStore = useUserStore()
const list = ref([])
const automaticPromptRef = ref('')
const inquiryInfo = ref([])
console.log(shopListRef)
const rules = reactive({
customerName: [
{
......@@ -391,20 +388,27 @@ let currentInfo = ref({
messages: [],
username: '',
})
let queryParams = ref({})
const connectMsg = () => {
const useUser = useUserStore()
// const useUser = useUserStore()
const toIp = `ws://${
import.meta.env.VITE_USER_APP_API_URL
}:8081?type=kf&code=${getUseUserStore.userInfo?.username}`
useUser.connect()
getUseUserStore.connect()
initWebSocket(toIp)
useUser.setUserListMessages({}).then((res: any) => {
list.value = useUser.userList
})
getUserList()
}
onMounted(() => {
connectMsg()
})
const getUserList = (queryParams:any) => {
getUseUserStore.setUserListMessages(queryParams).then((res: any) => {
list.value = getUseUserStore.userList
})
}
const handleInput = () => {
getUserList(queryParams)
}
//设置message
const isSelf = computed(() => {
return (e: any) => {
......@@ -537,6 +541,7 @@ const handleDelete = (item, index) => {
//提交询价单
const sumbitFuleForm = (formEl: FormInstance | undefined) => {
console.log('sumbitFuleForm', formEl)
if (!formEl) return
formEl.validate(async (valid: boolean) => {
if (valid) {
......@@ -602,7 +607,6 @@ const selectionChange = (arr: any) => {
item.count = 1
return item
})
console.log(inquiryInfo.value)
}
</script>
<style lang="scss" scoped>
......@@ -958,6 +962,9 @@ const selectionChange = (arr: any) => {
.el-input__wrapper {
width: 48px;
}
.query{
}
.avatar-input-box {
:deep(.el-input-number__increase),
:deep(.el-input-number__decrease) {
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论