重绘
This commit is contained in:
@@ -10,7 +10,7 @@
|
||||
</u-form-item>
|
||||
|
||||
<u-form-item label="走访对象" prop="application" required style="position: relative">
|
||||
<u-input v-model="forms.application" disabled placeholder="请选择走访对象" @click="handerSelecUser" />
|
||||
<u-input v-model="forms.application" disabled placeholder="请选择走访对象" @click="toWalkObject" />
|
||||
<!-- @click="showObject = true" @click="toWalkObject" -->
|
||||
|
||||
<u-select v-model="showObject" :list="Objectlist" @confirm="applicaStatus"></u-select>
|
||||
@@ -37,8 +37,8 @@
|
||||
<div>{{ forms.description.length }}/500</div>
|
||||
</u-form-item>
|
||||
|
||||
<u-form-item label="图片(最多9张)" prop="images" class="avatars" required label-position="top">
|
||||
<AiUploader :def.sync="forms.images" multiple @list="change" placeholder="上传图片" :limit="9"></AiUploader>
|
||||
<u-form-item label="图片(最多9张)" prop="images" class="avatars" label-position="top">
|
||||
<AiUploader :def.sync="forms.images" multiple placeholder="上传图片" :limit="9"></AiUploader>
|
||||
</u-form-item>
|
||||
</u-form>
|
||||
</div>
|
||||
@@ -54,11 +54,12 @@
|
||||
|
||||
<script>
|
||||
import { mapState } from 'vuex'
|
||||
import { mapActions } from 'vuex'
|
||||
import walkObject from './walkObject'
|
||||
|
||||
export default {
|
||||
name: 'add',
|
||||
components: {
|
||||
walkObject,
|
||||
},
|
||||
props: {},
|
||||
data() {
|
||||
@@ -92,48 +93,25 @@ export default {
|
||||
},
|
||||
computed: { ...mapState(['user']) },
|
||||
created() {
|
||||
console.log(this.user)
|
||||
this.areaIdProps = this.user.areaId
|
||||
this.$dict.load('realityStatus').then(() => {})
|
||||
},
|
||||
mounted() {},
|
||||
mounted() {
|
||||
this.$on('black', (data) => {
|
||||
console.log(data)
|
||||
})
|
||||
},
|
||||
methods: {
|
||||
// ...mapActions(['selectEnterpriseContact']),
|
||||
handerSelecUser() {
|
||||
this.$http.post('/app/appapplicationinfo/queryApplicationListByType?type=0').then((res) => {
|
||||
if (res.code == 0) {
|
||||
// this.data = res.data.records
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
// handerSelecUser() {
|
||||
// console.log(this.clickedUserSelect)
|
||||
// if (this.clickedUserSelect) return this.$u.toast('正在打开人员选择器')
|
||||
|
||||
// this.clickedUserSelect = true
|
||||
// this.selectEnterpriseContact({
|
||||
// fromDepartmentId: 0,
|
||||
// type: ['user'],
|
||||
// optionId: this.forms.application?.map((e) => e.id),
|
||||
// })
|
||||
// .then((res) => {
|
||||
// this.change(res?.userList || [])
|
||||
// this.clickedUserSelect = false
|
||||
// })
|
||||
// .catch(() => {
|
||||
// this.clickedUserSelect = false
|
||||
// })
|
||||
// },
|
||||
|
||||
submit() {
|
||||
console.log(1)
|
||||
if (this.flag) return
|
||||
|
||||
this.$refs.uForm.validate((valid) => {
|
||||
if (valid) {
|
||||
if (!this.forms.application) {
|
||||
return this.$u.toast('请选择走访对象')
|
||||
}
|
||||
// if (!this.forms.application) {
|
||||
// return this.$u.toast('请选择走访对象')
|
||||
// }
|
||||
if (!this.forms.title) {
|
||||
return this.$u.toast('请输入入户走访事项')
|
||||
}
|
||||
@@ -149,17 +127,18 @@ export default {
|
||||
|
||||
console.log(3)
|
||||
this.flag = true
|
||||
this.$instance
|
||||
.post(`/appjobresume/addOrUpdate`, {
|
||||
this.$http
|
||||
.post(`/app/appvisitvondolence/addOrUpdate`, {
|
||||
areaId: this.forms.areaId,
|
||||
applicationId: '',
|
||||
// object: this.forms.object,
|
||||
applicationId: '02fcf19c81154f6ea9560d9a9deee9f4',
|
||||
optionId: '4703806718f842a98a28df554c6aa6b2',
|
||||
reality: this.forms.reality == Number ? this.forms.reality : this.forms.realitylabel,
|
||||
title: this.forms.title,
|
||||
description: this.forms.description,
|
||||
images: imgs || [],
|
||||
// education: this.form.education == Number ? this.form.education : this.forms.educationValue,
|
||||
id: '',
|
||||
createUserId: this.user.id,
|
||||
createUserName: this.user.name,
|
||||
images: JSON.stringify(imgs) || [],
|
||||
id: this.id,
|
||||
})
|
||||
.then((res) => {
|
||||
console.log(4)
|
||||
@@ -197,14 +176,10 @@ export default {
|
||||
this.forms.realityValue = e[0].value
|
||||
},
|
||||
|
||||
// toWalkObject() {
|
||||
// this.addList = false
|
||||
// this.comp = 'walkObject'
|
||||
// this.params = 111
|
||||
// },
|
||||
|
||||
change(e) {
|
||||
console.log(e)
|
||||
toWalkObject() {
|
||||
this.addList = false
|
||||
this.comp = 'walkObject'
|
||||
this.params = 111
|
||||
},
|
||||
},
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user