refactor: 移除多余的console.log语句以清理代码

清理了多个组件和视图中的console.log语句,以提高代码的可读性和维护性,避免在生产环境中输出不必要的调试信息。
This commit is contained in:
DESKTOP-RQ919RC\Pc 2025-04-10 18:56:24 +08:00
parent a320cb9d97
commit 1ea3894be8
20 changed files with 6 additions and 39 deletions

View File

@ -73,7 +73,6 @@ const timedTransmission = () => {
if (socketTask.readyState != 1) return
// timedTransmissionState = true
socketTask.send(JSON.stringify({ type: "ping" }))
console.log("ping", new Date())
setTimeout(() => timedTransmission(), useSocketInterval)
}

View File

@ -229,7 +229,6 @@ const selectOption = (type, value) => {
break;
}
console.log('pitchValue', pitchValue.value);
emit('handleTransfer', pitchValue)
}

View File

@ -290,7 +290,6 @@ let pitchValue = ref({
watchEffect(() => {
// nearSchoolList = store.state.apartment.school || []
nearSchoolList = store.state.schoolList || []
console.log("nearSchoolList", nearSchoolList)
roomTypeList = store.state.apartment.roomtype || []
roomTypeKey = store.state.roomTypeKey || {}
roomlistingsList = store.state.apartment.roomlistings || []

View File

@ -69,7 +69,6 @@ watchEffect(() => {
show = props.show
list.splice(0, list.length)
list.push(...props.list)
// console.log(show)
if (show && props.clearList) {
checkList.list = []
}

View File

@ -83,7 +83,6 @@ let prev = () => carousel.value.prev()
//
const carouselChange = value => {
console.log("value")
imageTab.value = value
}

View File

@ -38,13 +38,11 @@ export default {
let tab = ref("person"); // person intermediary more
// console.log("props['intermediary']", props['intermediary']);
// if (props['intermediary'] == 1) tab.value = "intermediary"
// else tab.value = "person"
watch(() => props.intermediary, (newValue, oldValue) => {
// popState
// console.log('popState', newValue, oldValue);
if (newValue == 1) tab.value = "intermediary"
else tab.value = "person"

View File

@ -104,7 +104,6 @@ async function init() {
isintermediary.value = data.isintermediary
// isintermediary.value = 1
// console.log("data.isintermediary",data.isintermediary);
// if (data['ispopup'] == 0) overallJump()
if (data['ispopup'] == 0) overallJump()
else popType.value = 'choice'

View File

@ -92,7 +92,6 @@ let closeSeach = () => {
//
let selectSeach = (data) => {
props.checkBtn(data,'location',JSON.stringify(nowSelectArea.data))
// console.log(data)
}
</script>

View File

@ -54,7 +54,6 @@ const submit = () => {
id: props['id'],
message
}).then(res => {
console.log("res", res);
if (res.code == 200) {
ElMessage.success(res.message)
checkList.value = []

View File

@ -55,7 +55,6 @@ const popperOptions = ref({
// if (props['type'] == 'housingTop') popperOptions.value['modifiers'][0]['options']['offset'][0] = 14
if (props['type'] == 'housingTop') popperOptions.value['modifiers'][0]['options']['offset'][0] = 18
if (props['type'] == 'housing') popperOptions.value['modifiers'][0]['options']['offset'][0] = 38
// console.log("newValue", props['type']);
watch(() => props.concatType, (newValue, oldValue) => {

View File

@ -17,7 +17,7 @@ import videojs from "video.js"
import { reactive, onMounted, ref, defineProps, watchEffect, watch, onUnmounted, nextTick } from "vue"
const onCanPlay = event => {
console.log("视频可以播放了")
// console.log("")
//
}
const onError = event => {
@ -47,17 +47,16 @@ watch(
() => props.imageTab,
newVal => {
if (newVal != props.val) {
// console.log("videoRef", videoRef.value)
if (player.value != null) {
player.value.pause() // dispose()Dom
}
if (videoRef.value) {
if (!videoRef.value.paused) {
console.log("视频正在播放,现在停止.")
// console.log(".")
videoRef.value.pause()
} else {
console.log("视频已经暂停.")
// console.log(".")
}
} else {
// console.error("Video element not found.")
@ -75,7 +74,6 @@ let ism3u8 = ref(false) // 是否是 m3u8 格式
onMounted(() => {
if (props.src.indexOf("m3u8") == -1) {
// console.log("mp4")
return
}
ism3u8.value = true

View File

@ -211,7 +211,6 @@ let setLocation = (type, data, isupdate = true) => {
// type: data: second:
let setSeachConditions = (type, data, second = null) => {
console.log("赋值前的数据:", seachAllType)
if (type === "rent") {
seachAllType["rent_min"] = data.min
seachAllType["rent_max"] = data.max
@ -229,12 +228,8 @@ let setSeachConditions = (type, data, second = null) => {
if (type === "school") seachAllType.location = []
if (type === "location") seachAllType.school = ""
if (second) {
seachAllType[second.type] = second.id
}
console.log(type, data, second)
console.log("保存前的处理数据:", seachAllType)
if (second) seachAllType[second.type] = second.id
getDataList(seachAllType)
}

View File

@ -376,9 +376,7 @@ let searchInit = data => {
})
}
})
.catch(err => {
console.log("1111")
})
}
//

View File

@ -290,8 +290,6 @@ const props = defineProps({
const pitchValue = inject('pitchValue') || {}
onMounted(()=>{
console.log("min", pitchValue);
if (pitchValue['gender']) gender.id = pitchValue['gender']
if (pitchValue['publish']) releaseObj.id = pitchValue['publish']
if (pitchValue['leaseterm']) hireDate.id = pitchValue['leaseterm']

View File

@ -80,8 +80,6 @@ api.index()
.then(res => {
const data = res.data
// const url = import("@/assets/homeImage/informationO.png")
// console.log("url", url)
// console.log("data", data.articleList)
store.state.seachTypeData = data.combination
store.state.indexData = data
store.state.ListSelectBtn = data.recommendedTab

View File

@ -151,7 +151,6 @@ router.beforeEach((to, from, next) => {
isInitialNavigation = false;
} else {
// return
// console.log("1111111,", to.path, to.fullPath);
// if (window._hmt) {
// if (to.path) {
// // window._hmt.push(['_trackPageview', '/#' + to.fullPath])

View File

@ -231,7 +231,6 @@ let getRecommendList = () => {
type: ListSelectBtn.selectType,
pagevalue: pagevalue.value,
}).then(res => {
// console.log(res)
if (res.code === 200) {
if (res.data.pagevalue) {
if (pages.value === 1) waterfallList.value = []

View File

@ -834,7 +834,6 @@ let scrollWidth = ref(null)
let scrollMove = false
//
let moveImageList = type => {
console.log("type", type, imgListTab.value, imageLIstLeft)
if (type === "right" && imgScrollBottom()) return
if ((type === "left" && imgListTab.value === 0) || (imgListTab.value === imageLIstLeft.value.length - 1 && type === "right")) return
type === "left" ? imgListTab.value-- : imgListTab.value++

View File

@ -1154,7 +1154,6 @@ export default {
formData.append("name", target.name) //
formData.append("type", type) //
formData.append("data", this.uploadData) //
console.log("formData", formData)
// this.$axios.post('/tenement/pc/api/publish/upload', formData).then(res => {
this.$axios
.post("https://oss.gter.net/upload", formData)

View File

@ -77,9 +77,6 @@ let setInitial = () => {
//
let getDataList = (data, type = true) => {
// console.log("11414");
// console.log(data,type)
// console.log(type);
if (!type) {
//
seachSelectData.data.tabType !== "apartment" ? (pageList.value = []) : (listApartment.value = [])
@ -102,10 +99,8 @@ let getDataList = (data, type = true) => {
} else {
seachApi = api.apartment(postData)
}
// console.log("555");
seachApi.then(res => {
if (res.code === 200) {
// console.log(res.data)
dataList.data = res.data.data
if (res.data.data.length < 20) {
loadingText.value = ` 到底了 `