| | |
| | | <u-button type="success" plain class="add-person" @click="addPerson">在加一人</u-button>
|
| | | <view class="btn-group">
|
| | | <u-button class="btn-item" type="primary" @click="submit">提交</u-button>
|
| | | <u-button class="btn-item">我上报的事件</u-button>
|
| | | <u-button class="btn-item" @click="pushPage">我上报的事件</u-button>
|
| | | </view>
|
| | | </div>
|
| | | </template>
|
| | |
| | | data() {
|
| | | return {
|
| | | form: { |
| | | id: '',
|
| | | id: '', |
| | | placeId: '',
|
| | | localtion: '',
|
| | | placeName: '',
|
| | | legalPerson: '',
|
| | |
| | | }
|
| | | },
|
| | | personNum: 1,
|
| | | curSelectSite: {}, |
| | | placeId: '',
|
| | | curSelectSite: {},
|
| | | }
|
| | | },
|
| | | onShow() {
|
| | |
| | | }) |
| | | return |
| | | } |
| | | this.placeId = data.placeId |
| | | const placePractitioner = data?.placePractitioner || [] |
| | | Object.keys(this.form).forEach(key => { |
| | | this.form[key] = data[key] |
| | |
| | | }) |
| | | this.personNum = placePractitioner.length |
| | | this.$nextTick(() => { |
| | | console.log(placePractitioner); |
| | | this.$refs.formItemRef.forEach((item, index) => { |
| | | item.form = this.$refs.formItemRef[index].form |
| | | item.form = placePractitioner[index] |
| | | }) |
| | | }) |
| | | }) |
| | |
| | | submit() {
|
| | | const placePractitioner = []
|
| | | this.$refs.formItemRef.forEach(item => { |
| | | item.form.placeId = this.placeId
|
| | | item.form.placeId = this.form.placeId
|
| | | placePractitioner.push(item.form)
|
| | | })
|
| | | this.form.placePractitioner = placePractitioner |
| | | this.updatePlaceExt(this.form)
|
| | | }, |
| | | pushPage() { |
| | | this.$u.func.globalNavigator('/subPackage/workbench/views/cshw') |
| | | }
|
| | | }
|
| | | }
|