1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
<template>
<div class="app-content" style="height:100%;overflow:auto;">
<div style="height: calc(100% - 32px);overflow:auto;margin-top: 16px;">
<a-spin :spinning="loading" style="width: 100%;height: 100%;">
<info-edit :formData.sync="formData" @load="onLoad" ref="infoEdit" />
<a-row style="text-align: center;margin-top: 6px;">
<a-col :span="24">
<a-button type="primary" @click="submit">保存</a-button>
</a-col>
</a-row>
</a-spin>
</div>
</div>
</template>
<script>
import infoEdit from '@/views/basicSetting/unit/components/infoEdit'
export default {
name: "unitInfoEdit",
components: {
infoEdit
},
data () {
return {
formData: {
id: null,
unitName: null,
unitType: null,
unitAddress: null,
linkName: null,
telephone: null,
email: null,
fax: null,
organizationCode: null,
registeredAddress: null,
postCode: null,
legalPerson: null,
workforce: null,
specializedPersonnel: null,
researchPersonnel: null,
depositBank: null,
bankAccount: null,
depositBankAddress: null,
interbankNumber: null,
},
loading: false
}
},
created () {
this.getCurrentUnitInfo()
},
methods: {
getCurrentUnitInfo () {
this.loading = true
this.$api.unit.getCurrentUnitInfo().then(({ data = {} }) => {
if (data) {
this.formData = data
}
this.loading = false
}).catch(() => {
this.loading = false
})
},
submit () {
this.$refs.infoEdit.submit()
},
onLoad (value) {
this.loading = value
},
}
}
</script>