|
@@ -53,6 +53,7 @@
|
|
|
<el-table-column prop="Fullname" align="center" label="组织名称" show-overflow-tooltip></el-table-column>
|
|
<el-table-column prop="Fullname" align="center" label="组织名称" show-overflow-tooltip></el-table-column>
|
|
|
<el-table-column prop="Parentname" align="center" label="上级组织" show-overflow-tooltip></el-table-column>
|
|
<el-table-column prop="Parentname" align="center" label="上级组织" show-overflow-tooltip></el-table-column>
|
|
|
<el-table-column prop="Contacts" align="center" label="联系人" show-overflow-tooltip></el-table-column>
|
|
<el-table-column prop="Contacts" align="center" label="联系人" show-overflow-tooltip></el-table-column>
|
|
|
|
|
+ <el-table-column prop="Category" align="center" label="单位级别" show-overflow-tooltip :formatter="formatUnit"></el-table-column>
|
|
|
<el-table-column prop="Phone" align="center" label="联系电话" show-overflow-tooltip></el-table-column>
|
|
<el-table-column prop="Phone" align="center" label="联系电话" show-overflow-tooltip></el-table-column>
|
|
|
<el-table-column prop="Address" align="center" label="地址" show-overflow-tooltip></el-table-column>
|
|
<el-table-column prop="Address" align="center" label="地址" show-overflow-tooltip></el-table-column>
|
|
|
<el-table-column prop="Description" align="center" label="备注" show-overflow-tooltip></el-table-column>
|
|
<el-table-column prop="Description" align="center" label="备注" show-overflow-tooltip></el-table-column>
|
|
@@ -79,6 +80,16 @@
|
|
|
<el-form-item label="组织名称" prop="fullname" label-width="120px">
|
|
<el-form-item label="组织名称" prop="fullname" label-width="120px">
|
|
|
<el-input v-model="organizeform.fullname" auto-complete="off"></el-input>
|
|
<el-input v-model="organizeform.fullname" auto-complete="off"></el-input>
|
|
|
</el-form-item>
|
|
</el-form-item>
|
|
|
|
|
+ <el-form-item label="所在单位级别" label-width="120px">
|
|
|
|
|
+ <el-select v-model="unitvalue" placeholder="请选择">
|
|
|
|
|
+ <el-option
|
|
|
|
|
+ v-for="item in unitoptions"
|
|
|
|
|
+ :key="item.unitvalue"
|
|
|
|
|
+ :label="item.unitlabel"
|
|
|
|
|
+ :value="item.unitvalue">
|
|
|
|
|
+ </el-option>
|
|
|
|
|
+ </el-select>
|
|
|
|
|
+ </el-form-item>
|
|
|
<el-form-item label="联系人" label-width="120px">
|
|
<el-form-item label="联系人" label-width="120px">
|
|
|
<el-input v-model="organizeform.Contacts" auto-complete="off"></el-input>
|
|
<el-input v-model="organizeform.Contacts" auto-complete="off"></el-input>
|
|
|
</el-form-item>
|
|
</el-form-item>
|
|
@@ -128,6 +139,17 @@
|
|
|
|
|
|
|
|
data () {
|
|
data () {
|
|
|
return {
|
|
return {
|
|
|
|
|
+ unitoptions: [{
|
|
|
|
|
+ unitvalue: '',
|
|
|
|
|
+ unitlabel: '无'
|
|
|
|
|
+ }, {
|
|
|
|
|
+ unitvalue: 'unit',
|
|
|
|
|
+ unitlabel: '二级单位'
|
|
|
|
|
+ }, {
|
|
|
|
|
+ unitvalue: 'ThrUnit',
|
|
|
|
|
+ unitlabel: '三级单位'
|
|
|
|
|
+ }],
|
|
|
|
|
+ unitvalue: '',
|
|
|
loading: false,
|
|
loading: false,
|
|
|
loadingTmp: false,
|
|
loadingTmp: false,
|
|
|
syncOrgLoading: false,
|
|
syncOrgLoading: false,
|
|
@@ -145,6 +167,7 @@
|
|
|
IsInnerOrganize: 1,
|
|
IsInnerOrganize: 1,
|
|
|
parentid: 0,
|
|
parentid: 0,
|
|
|
fullname: '',
|
|
fullname: '',
|
|
|
|
|
+ Category: '',
|
|
|
description: '',
|
|
description: '',
|
|
|
Contacts: '',
|
|
Contacts: '',
|
|
|
Phone: '',
|
|
Phone: '',
|
|
@@ -390,10 +413,12 @@
|
|
|
this.$axios.get('organizes/parentlist/' + v.Parentid, {})
|
|
this.$axios.get('organizes/parentlist/' + v.Parentid, {})
|
|
|
.then(res => {
|
|
.then(res => {
|
|
|
if (res.data.code === 0) {
|
|
if (res.data.code === 0) {
|
|
|
|
|
+ console.log(_this.organizeform)
|
|
|
_this.dialogtitle = `编辑组织信息(${v.Fullname})`
|
|
_this.dialogtitle = `编辑组织信息(${v.Fullname})`
|
|
|
_this.organizeform.parentid = v.Parentid
|
|
_this.organizeform.parentid = v.Parentid
|
|
|
_this.organizeform.fullname = v.Fullname
|
|
_this.organizeform.fullname = v.Fullname
|
|
|
_this.organizeform.Contacts = v.Contacts
|
|
_this.organizeform.Contacts = v.Contacts
|
|
|
|
|
+ _this.unitvalue = v.Category
|
|
|
_this.organizeform.Phone = v.Phone
|
|
_this.organizeform.Phone = v.Phone
|
|
|
_this.organizeform.Address = v.Address
|
|
_this.organizeform.Address = v.Address
|
|
|
_this.organizeform.description = v.Description
|
|
_this.organizeform.description = v.Description
|
|
@@ -422,6 +447,7 @@
|
|
|
},
|
|
},
|
|
|
savedata (formName) {
|
|
savedata (formName) {
|
|
|
let _this = this
|
|
let _this = this
|
|
|
|
|
+ _this.organizeform.Category = _this.unitvalue
|
|
|
this.$refs[formName].validate((valid) => {
|
|
this.$refs[formName].validate((valid) => {
|
|
|
if (valid) {
|
|
if (valid) {
|
|
|
_this.organizeform.parentid = parseInt(_this.selectedorg[_this.selectedorg.length - 1])
|
|
_this.organizeform.parentid = parseInt(_this.selectedorg[_this.selectedorg.length - 1])
|
|
@@ -465,6 +491,7 @@
|
|
|
console.error(err)
|
|
console.error(err)
|
|
|
})
|
|
})
|
|
|
} else if (_this.operatingitem === 2) {
|
|
} else if (_this.operatingitem === 2) {
|
|
|
|
|
+ _this.organizeform.Category = _this.unitvalue
|
|
|
_this.organizeform.IsInnerOrganize = 1
|
|
_this.organizeform.IsInnerOrganize = 1
|
|
|
_this.$axios.put('organizes/' + _this.organizeform.id, _this.organizeform)
|
|
_this.$axios.put('organizes/' + _this.organizeform.id, _this.organizeform)
|
|
|
.then(res => {
|
|
.then(res => {
|
|
@@ -540,11 +567,13 @@
|
|
|
parentid: 0,
|
|
parentid: 0,
|
|
|
fullname: '',
|
|
fullname: '',
|
|
|
Contacts: '',
|
|
Contacts: '',
|
|
|
|
|
+ Category: '',
|
|
|
Phone: '',
|
|
Phone: '',
|
|
|
Address: '',
|
|
Address: '',
|
|
|
description: '',
|
|
description: '',
|
|
|
id: 0
|
|
id: 0
|
|
|
}
|
|
}
|
|
|
|
|
+ this.unitvalue = ''
|
|
|
},
|
|
},
|
|
|
searchCommand (command) {
|
|
searchCommand (command) {
|
|
|
if (command == 'clear') {
|
|
if (command == 'clear') {
|
|
@@ -554,6 +583,15 @@
|
|
|
clearSearch () {
|
|
clearSearch () {
|
|
|
this.keyword = ''
|
|
this.keyword = ''
|
|
|
this.initData()
|
|
this.initData()
|
|
|
|
|
+ },
|
|
|
|
|
+ formatUnit (row, column) {
|
|
|
|
|
+ if (row.Category === '') {
|
|
|
|
|
+ return ''
|
|
|
|
|
+ } else if (row.Category === 'unit') {
|
|
|
|
|
+ return '二级单位'
|
|
|
|
|
+ } else {
|
|
|
|
|
+ return '三级单位'
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|