Compare commits

...

2 Commits

Author SHA1 Message Date
A1300399510
4a2e1b624e Merge remote-tracking branch 'origin/main'
# Conflicts:
#	package-lock.json
#	yarn.lock
2023-07-10 11:53:44 +08:00
A1300399510
17c1e6b796 提交 2023-07-10 11:48:52 +08:00
5 changed files with 843 additions and 55 deletions

115
package-lock.json generated
View File

@@ -11,7 +11,10 @@
"axios": "^1.4.0",
"core-js": "^3.8.3",
"element-plus": "^2.3.7",
<<<<<<< HEAD
=======
"element-ui": "^2.15.13",
>>>>>>> origin/main
"sass-loader": "^8.0.0",
"vue": "^3.2.13",
"vue-router": "^4.0.3",
@@ -1978,9 +1981,15 @@
"integrity": "sha512-Bu+AMaXNjrpjh41znzHqaz3r2Nr8hHuHZT6V2LBKMhyMl0FgKA62PNYbqnfgmzOhoWZj70Zecisbo4H1rotP5g=="
},
"node_modules/@floating-ui/dom": {
<<<<<<< HEAD
"version": "1.4.4",
"resolved": "https://registry.npmjs.org/@floating-ui/dom/-/dom-1.4.4.tgz",
"integrity": "sha512-21hhDEPOiWkGp0Ys4Wi6Neriah7HweToKra626CIK712B5m9qkdz54OP9gVldUg+URnBTpv/j/bi/skmGdstXQ==",
=======
"version": "1.4.3",
"resolved": "https://registry.npmjs.org/@floating-ui/dom/-/dom-1.4.3.tgz",
"integrity": "sha512-nB/68NyaQlcdY22L+Fgd1HERQ7UGv7XFN+tPxwrEfQL4nKtAP/jIZnZtpUlXbtV+VEGHh6W/63Gy2C5biWI3sA==",
>>>>>>> origin/main
"dependencies": {
"@floating-ui/core": "^1.3.1"
}
@@ -3077,6 +3086,34 @@
"url": "https://github.com/sponsors/antfu"
}
},
<<<<<<< HEAD
"node_modules/@vueuse/core/node_modules/vue-demi": {
"version": "0.14.5",
"resolved": "https://registry.npmjs.org/vue-demi/-/vue-demi-0.14.5.tgz",
"integrity": "sha512-o9NUVpl/YlsGJ7t+xuqJKx8EBGf1quRhCiT6D/J0pfwmk9zUwYkC7yrF4SZCe6fETvSM3UNL2edcbYrSyc4QHA==",
"hasInstallScript": true,
"bin": {
"vue-demi-fix": "bin/vue-demi-fix.js",
"vue-demi-switch": "bin/vue-demi-switch.js"
},
"engines": {
"node": ">=12"
},
"funding": {
"url": "https://github.com/sponsors/antfu"
},
"peerDependencies": {
"@vue/composition-api": "^1.0.0-rc.1",
"vue": "^3.0.0-0 || ^2.6.0"
},
"peerDependenciesMeta": {
"@vue/composition-api": {
"optional": true
}
}
},
=======
>>>>>>> origin/main
"node_modules/@vueuse/metadata": {
"version": "9.13.0",
"resolved": "https://registry.npmjs.org/@vueuse/metadata/-/metadata-9.13.0.tgz",
@@ -3096,6 +3133,34 @@
"url": "https://github.com/sponsors/antfu"
}
},
<<<<<<< HEAD
"node_modules/@vueuse/shared/node_modules/vue-demi": {
"version": "0.14.5",
"resolved": "https://registry.npmjs.org/vue-demi/-/vue-demi-0.14.5.tgz",
"integrity": "sha512-o9NUVpl/YlsGJ7t+xuqJKx8EBGf1quRhCiT6D/J0pfwmk9zUwYkC7yrF4SZCe6fETvSM3UNL2edcbYrSyc4QHA==",
"hasInstallScript": true,
"bin": {
"vue-demi-fix": "bin/vue-demi-fix.js",
"vue-demi-switch": "bin/vue-demi-switch.js"
},
"engines": {
"node": ">=12"
},
"funding": {
"url": "https://github.com/sponsors/antfu"
},
"peerDependencies": {
"@vue/composition-api": "^1.0.0-rc.1",
"vue": "^3.0.0-0 || ^2.6.0"
},
"peerDependenciesMeta": {
"@vue/composition-api": {
"optional": true
}
}
},
=======
>>>>>>> origin/main
"node_modules/@webassemblyjs/ast": {
"version": "1.11.6",
"resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.11.6.tgz",
@@ -5062,6 +5127,8 @@
},
"peerDependencies": {
"vue": "^3.2.0"
<<<<<<< HEAD
=======
}
},
"node_modules/element-ui": {
@@ -5086,6 +5153,7 @@
"integrity": "sha512-tXBM+1m056MAX0E8TL2iCjg8WvSyXu0Zc8LNtYqrVeyoL3+esHRZ4SieE9fKQyyU09uONjnMEjrNBMqT0mbvmA==",
"dependencies": {
"babel-runtime": "6.x"
>>>>>>> origin/main
}
},
"node_modules/emoji-regex": {
@@ -7255,11 +7323,14 @@
"url": "https://github.com/sponsors/sindresorhus"
}
},
<<<<<<< HEAD
=======
"node_modules/normalize-wheel": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/normalize-wheel/-/normalize-wheel-1.0.1.tgz",
"integrity": "sha512-1OnlAPZ3zgrk8B91HyRj+eVv+kS5u+Z0SCsak6Xil/kmgEia50ga7zfkumayonZrImffAxPU/5WcyGhzetHNPA=="
},
>>>>>>> origin/main
"node_modules/normalize-wheel-es": {
"version": "1.2.0",
"resolved": "https://registry.npmjs.org/normalize-wheel-es/-/normalize-wheel-es-1.2.0.tgz",
@@ -11881,7 +11952,12 @@
"@element-plus/icons-vue": {
"version": "2.1.0",
"resolved": "https://registry.npmjs.org/@element-plus/icons-vue/-/icons-vue-2.1.0.tgz",
<<<<<<< HEAD
"integrity": "sha512-PSBn3elNoanENc1vnCfh+3WA9fimRC7n+fWkf3rE5jvv+aBohNHABC/KAR5KWPecxWxDTVT1ERpRbOMRcOV/vA==",
"requires": {}
=======
"integrity": "sha512-PSBn3elNoanENc1vnCfh+3WA9fimRC7n+fWkf3rE5jvv+aBohNHABC/KAR5KWPecxWxDTVT1ERpRbOMRcOV/vA=="
>>>>>>> origin/main
},
"@floating-ui/core": {
"version": "1.3.1",
@@ -11889,9 +11965,15 @@
"integrity": "sha512-Bu+AMaXNjrpjh41znzHqaz3r2Nr8hHuHZT6V2LBKMhyMl0FgKA62PNYbqnfgmzOhoWZj70Zecisbo4H1rotP5g=="
},
"@floating-ui/dom": {
<<<<<<< HEAD
"version": "1.4.4",
"resolved": "https://registry.npmjs.org/@floating-ui/dom/-/dom-1.4.4.tgz",
"integrity": "sha512-21hhDEPOiWkGp0Ys4Wi6Neriah7HweToKra626CIK712B5m9qkdz54OP9gVldUg+URnBTpv/j/bi/skmGdstXQ==",
=======
"version": "1.4.3",
"resolved": "https://registry.npmjs.org/@floating-ui/dom/-/dom-1.4.3.tgz",
"integrity": "sha512-nB/68NyaQlcdY22L+Fgd1HERQ7UGv7XFN+tPxwrEfQL4nKtAP/jIZnZtpUlXbtV+VEGHh6W/63Gy2C5biWI3sA==",
>>>>>>> origin/main
"requires": {
"@floating-ui/core": "^1.3.1"
}
@@ -12812,6 +12894,17 @@
"@vueuse/metadata": "9.13.0",
"@vueuse/shared": "9.13.0",
"vue-demi": "*"
<<<<<<< HEAD
},
"dependencies": {
"vue-demi": {
"version": "0.14.5",
"resolved": "https://registry.npmjs.org/vue-demi/-/vue-demi-0.14.5.tgz",
"integrity": "sha512-o9NUVpl/YlsGJ7t+xuqJKx8EBGf1quRhCiT6D/J0pfwmk9zUwYkC7yrF4SZCe6fETvSM3UNL2edcbYrSyc4QHA==",
"requires": {}
}
=======
>>>>>>> origin/main
}
},
"@vueuse/metadata": {
@@ -12825,6 +12918,17 @@
"integrity": "sha512-UrnhU+Cnufu4S6JLCPZnkWh0WwZGUp72ktOF2DFptMlOs3TOdVv8xJN53zhHGARmVOsz5KqOls09+J1NR6sBKw==",
"requires": {
"vue-demi": "*"
<<<<<<< HEAD
},
"dependencies": {
"vue-demi": {
"version": "0.14.5",
"resolved": "https://registry.npmjs.org/vue-demi/-/vue-demi-0.14.5.tgz",
"integrity": "sha512-o9NUVpl/YlsGJ7t+xuqJKx8EBGf1quRhCiT6D/J0pfwmk9zUwYkC7yrF4SZCe6fETvSM3UNL2edcbYrSyc4QHA==",
"requires": {}
}
=======
>>>>>>> origin/main
}
},
"@webassemblyjs/ast": {
@@ -14283,6 +14387,8 @@
"lodash-unified": "^1.0.2",
"memoize-one": "^6.0.0",
"normalize-wheel-es": "^1.2.0"
<<<<<<< HEAD
=======
}
},
"element-ui": {
@@ -14306,6 +14412,7 @@
"babel-runtime": "6.x"
}
}
>>>>>>> origin/main
}
},
"emoji-regex": {
@@ -15431,7 +15538,12 @@
"lodash-unified": {
"version": "1.0.3",
"resolved": "https://registry.npmjs.org/lodash-unified/-/lodash-unified-1.0.3.tgz",
<<<<<<< HEAD
"integrity": "sha512-WK9qSozxXOD7ZJQlpSqOT+om2ZfcT4yO+03FuzAHD0wF6S0l0090LRPDx3vhTTLZ8cFKpBn+IOcVXK6qOcIlfQ==",
"requires": {}
=======
"integrity": "sha512-WK9qSozxXOD7ZJQlpSqOT+om2ZfcT4yO+03FuzAHD0wF6S0l0090LRPDx3vhTTLZ8cFKpBn+IOcVXK6qOcIlfQ=="
>>>>>>> origin/main
},
"lodash.debounce": {
"version": "4.0.8",
@@ -15923,11 +16035,14 @@
"integrity": "sha512-DlL+XwOy3NxAQ8xuC0okPgK46iuVNAK01YN7RueYBqqFeGsBjV9XmCAzAdgt+667bCl5kPh9EqKKDwnaPG1I7A==",
"dev": true
},
<<<<<<< HEAD
=======
"normalize-wheel": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/normalize-wheel/-/normalize-wheel-1.0.1.tgz",
"integrity": "sha512-1OnlAPZ3zgrk8B91HyRj+eVv+kS5u+Z0SCsak6Xil/kmgEia50ga7zfkumayonZrImffAxPU/5WcyGhzetHNPA=="
},
>>>>>>> origin/main
"normalize-wheel-es": {
"version": "1.2.0",
"resolved": "https://registry.npmjs.org/normalize-wheel-es/-/normalize-wheel-es-1.2.0.tgz",

View File

@@ -10,7 +10,6 @@
"axios": "^1.4.0",
"core-js": "^3.8.3",
"element-plus": "^2.3.7",
"element-ui": "^2.15.13",
"sass-loader": "^8.0.0",
"vue": "^3.2.13",
"vue-router": "^4.0.3",

View File

@@ -62,7 +62,7 @@ export default {
top: 0;
left: 50%;
transform: translateX(-50%);
width: 100vw;
width: 100%;
min-width: 1200px;
max-width: 1920px;
height: 100%;

View File

@@ -58,7 +58,7 @@
</div>
<div class="form-box shadow radius16 flex1">
<div class="form-header">发布出租房源</div>
<div class="form-header">发布{{ intermediary == 6 ? '求' : '出租' }}房源</div>
<div class="form-boxes">
<div class="form-item" v-for="(item) in fieldinfoBasic" :key="item.field">
@@ -311,7 +311,7 @@
<!-- 所在区域 -->
<div class="form-option modeOne flexacenter" v-if="intermediary != 6 && item.field == 'location'">
<div ref="location" class="modeOne-item flexacenter"
<!-- <div ref="location" class="modeOne-item flexacenter"
:class="{ 'pitch': info['location'], 'disabled': verified == 1 }"
style="width: 640px;border-color: rgba(170, 170, 170, 1);"
@click="verified == 1 ? '' : areaPopState = true">
@@ -326,9 +326,9 @@
<img class="arrows-icon" src="@/assets/img/edit/arrows.svg" />
<img class="arrows-icon arrows-disabled-icon" style="transform: rotate(0);"
src="@/assets/img/edit/disabled-icon.svg" />
<img class="arrows-icon-pitch" src="@/assets/img/edit/blue-arrow.svg" />
<img class="arrows-icon-pitch" src="@/assets/img/edit/blue-arrow.svg" /> -->
<!-- 弹窗 -->
<div class="pop area-pop-box radius16" style="position: absolute;top: 58px;height: 614px;"
<!-- <div class="pop area-pop-box radius16" style="position: absolute;top: 58px;height: 614px;"
v-if="areaPopState">
<div class="area-box flexflex" style="height: 100%;">
<div class="area-left">
@@ -337,6 +337,54 @@
@click.stop="handleArea(index)">
<div class="dot"></div>
{{ item.name }}
<div class="semicircle-outside"></div>
</div>
</div>
<div class="area-right flex1">
<div class="area-item flexacenter"
:class="{ 'pitchpitch': info['location'] == index }"
v-for="(item, index) in locationData[locationValue].data" :key="index"
@click.stop="handleArea(index, item)">
<div class="area-item-name">{{ item }}</div>
<img class="area-item-pitch" src="@/assets/img/edit/blue-tick.svg" />
</div>
</div>
</div>
</div> -->
<!-- </div> -->
<el-popover placement="bottom" :width="640" :show-arrow="false" trigger="click" popper-style="padding: 0;border-radius:16px;">
<template #reference>
<div ref="location" class="modeOne-item flexacenter"
:class="{ 'pitch': info['location'], 'disabled': verified == 1 }"
style="width: 640px;border-color: rgba(170, 170, 170, 1);"
@click="verified == 1 ? '' : areaPopState = true">
<div class="modeOne-text flexacenter" v-if="info['location']">
{{ locationData[Math.floor(info.location)].name }}
<img class="form-arrows" src="@/assets/img/edit/thin-arrow.svg" />
<img class="form-arrows form-arrows-disabled"
src="@/assets/img/edit/thin-arrow-disabled.svg" />
{{ locationData[Math.floor(info.location)].data[info.location] }}
</div>
<div class="modeOne-text flexacenter" style="color: #AAAAAA;" v-else>请选择</div>
<img class="arrows-icon" src="@/assets/img/edit/arrows.svg" />
<img class="arrows-icon arrows-disabled-icon" style="transform: rotate(0);"
src="@/assets/img/edit/disabled-icon.svg" />
<img class="arrows-icon-pitch" src="@/assets/img/edit/blue-arrow.svg" />
</div>
</template>
<!-- <div class="pop area-pop-box radius16" style="position: absolute;top: 58px;height: 614px;" -->
<!-- <div class="pop area-pop-box radius16" style="" v-if="areaPopState"> -->
<div class="pop area-pop-box radius16" style="">
<div class="area-box flexflex" style="height: 100%;">
<div class="area-left">
<div class="area-item flexacenter" :class="{ 'pitchpitch': index == locationValue }"
v-for="(item, index) in locationData" :key="index"
@click.stop="handleArea(index)">
<div class="dot"></div>
{{ item.name }}
<div class="semicircle-outside"></div>
</div>
</div>
<div class="area-right flex1">
@@ -350,7 +398,8 @@
</div>
</div>
</div>
</div>
</el-popover>
</div>
<!-- 地址 -->
@@ -461,8 +510,7 @@
<img class="media-cross-icon" @click.stop="deleteMedia('video', index)"
src="@/assets/img/edit/cross-icon.png">
<div class="media-item-box flexcenter">
<video class="media-img" :src="item.image" :autoplay="false"></video>
<!-- <video class="media-img" preload="metadata" :src="item.image" :autoplay="false"></video> -->
<video class="media-img" preload="metadata" :src="item.image" :autoplay="false"></video>
</div>
<img class="media-play-icon" src="@/assets/img/edit/play-icon.svg" />
</div>
@@ -477,7 +525,7 @@
</div>
<!-- 照片 -->
<div class="media-box flexflex" v-if="item.field == 'images'">
<div class="media-box flexflex" v-if="item.field == 'images'" ref="images">
<div class="media-item flexcenter" :class="{ 'pitch': item['aid'] == info['aid'] }"
v-for="(item, index) in info.images" :key="index">
<div class="media-item-box flexcenter">
@@ -526,7 +574,7 @@
<div class="asterisk" v-if="item.required == 1">*</div>
<div class="how" v-if="item.field == 'wechat'" @click="howBoxState = true">如何获取二维码</div>
</div>
<div v-if="item.field == 'wechat'" class="">
<div v-if="item.field == 'wechat'" class="" ref="wechat">
<div class="contact-QRcode-box flexcenter" v-if="info.wechatdata['image']">
<img class="contact-QRcode-img" :src="info.wechatdata['image']" />
</div>
@@ -743,7 +791,7 @@ export default {
uniqid: "",
token: "",
status: 0, // 发布 状态
intermediary: 1,
intermediary: 3,
type: "", // 编辑类型
locationData: [],
locationValue: 1,
@@ -847,6 +895,7 @@ export default {
const urlParams = new URLSearchParams(queryString);
this.uniqid = urlParams.get('uniqid');
this.token = urlParams.get('token');
this.intermediary = urlParams.get('intermediary') || 3; // 默认写房东吧
this.verified = urlParams.get('verified') || 0;
this.init();
@@ -1022,8 +1071,10 @@ export default {
handleType(key, value) {
if (key >>> 0 == key) {
this.typeValue = key
this.info['type'] = null
// this.info['type'] = null
this.typePopState = true
if (this.info['type'] >>> 0 != key) this.info['type'] = null
} else {
this.info['type'] = key
this.typeValueUltimately = value
@@ -1049,7 +1100,6 @@ export default {
handleArea(key, value) {
if (key >>> 0 == key) {
this.locationValue = key
this.info['location'] = null
} else {
this.info['location'] = key
this.areaPopState = false
@@ -1213,6 +1263,11 @@ export default {
if (info['images'] && info['images'].length > 1 && !info['aid']) {
this.$message.error("请选择封面");
// data.field
let data = {
field: "images"
}
this.handleSubmitFailure(data)
return
}
@@ -1262,40 +1317,7 @@ export default {
}
this.$message.error(res.message);
// 获取 myRef 元素的位置信息
let targetElement = this.$refs[data.field]
if (!targetElement) return
if (Array.isArray(targetElement)) {
targetElement.forEach(element => {
element.style.borderColor = "rgba(249, 93, 93, 1)";
})
} else targetElement.style.borderColor = "rgba(249, 93, 93, 1)";
this.$watch(`info.${data.field}`, (newVal, oldVal) => {
if (newVal != null && newVal != undefined) {
if (Array.isArray(targetElement)) {
targetElement.forEach(element => {
element.style.borderColor = "#aaaaaa";
})
} else targetElement.style.borderColor = "#aaaaaa";
}
})
// 设置滚动距离
let top = 0
if (Array.isArray(targetElement)) top = targetElement[0].getBoundingClientRect().top + window.pageYOffset;
else top = targetElement.getBoundingClientRect().top + window.pageYOffsetp;
if (top) top -= 150
else top = 300
// document.body.scrollTop = document.documentElement.scrollTop = top;
window.scrollTo({
top,
behavior: "smooth"
})
this.handleSubmitFailure(data)
return
} else {
@@ -1323,6 +1345,42 @@ export default {
},
// 处理提交失败后的滚动和监听数据
handleSubmitFailure(data) {
// 获取 myRef 元素的位置信息
let targetElement = this.$refs[data.field]
if (!targetElement) return
if (Array.isArray(targetElement)) {
targetElement.forEach(element => {
element.style.borderColor = "rgba(249, 93, 93, 1)";
})
} else targetElement.style.borderColor = "rgba(249, 93, 93, 1)";
this.$watch(`info.${data.field}`, (newVal, oldVal) => {
if (newVal != null && newVal != undefined) {
if (Array.isArray(targetElement)) {
targetElement.forEach(element => {
element.style.borderColor = "#aaaaaa";
})
} else targetElement.style.borderColor = "#aaaaaa";
}
})
// 设置滚动距离
let top = 0
if (Array.isArray(targetElement)) top = targetElement[0].getBoundingClientRect().top + window.pageYOffset;
else top = targetElement.getBoundingClientRect().top + window.pageYOffsetp;
if (top) top -= 150
else top = 300
window.scrollTo({
top,
behavior: "smooth"
})
},
// 租金预算的 下拉框 展开隐藏事件
rentDropDown(callback) {
if (!callback || this.rent_min) return
@@ -2708,13 +2766,13 @@ export default {
}
&.area-pop-box {
width: 640px;
// width: 640px;
height: 695px;
left: 0;
background-color: rgba(255, 255, 255, 1);
-moz-box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.349019607843137);
-webkit-box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.349019607843137);
box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.349019607843137);
// -moz-box-shadow: 0px 0px 8px rgba(0, 0, 0, 0.0784313725490196);
// -webkit-box-shadow: 0px 0px 8px rgba(0, 0, 0, 0.0784313725490196);
// box-shadow: 0px 0px 8px rgba(0, 0, 0, 0.0784313725490196);
overflow: hidden;
z-index: 101;
@@ -2732,7 +2790,6 @@ export default {
height: calc(100% - 98px);
.area-left {
// padding-top: 16px;
background-color: rgba(246, 246, 246, 1);
.area-item {
@@ -2747,8 +2804,6 @@ export default {
padding-left: 48px;
cursor: pointer;
// border-bottom: 1px solid rgba(242, 242, 242, 1);
&:first-of-type {
padding-top: 16px;
height: 86px;
@@ -2765,6 +2820,48 @@ export default {
font-weight: 650 !important;
border: none !important;
.semicircle-outside {
position: absolute;
right: 0;
top: -20px;
width: 20px;
height: 20px;
background: #fff;
&::after {
content: "";
position: absolute;
right: 0;
top: 0;
width: 20px;
height: 20px;
border-radius: 0 0 100% 0;
background: #f6f6f6;
}
}
&::after {
content: "";
position: absolute;
right: 0;
bottom: -20px;
width: 20px;
height: 20px;
border-radius: 0 100% 0 0;
background: #f6f6f6;
}
&::before {
content: "";
position: absolute;
right: 0;
bottom: -20px;
width: 20px;
height: 20px;
background: #fff;
}
.dot {
display: block;
}

577
yarn.lock

File diff suppressed because it is too large Load Diff