|
@@ -16,6 +16,7 @@
|
|
|
:inline="true"
|
|
|
class="searchForm"
|
|
|
@submit="search"
|
|
|
+ @reset="onReset"
|
|
|
:model="searchForm"
|
|
|
>
|
|
|
<el-form-item>
|
|
@@ -42,7 +43,19 @@
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
<el-form-item>
|
|
|
+ <el-select
|
|
|
+ v-model.trim="searchForm.publicFlag"
|
|
|
+ clearable
|
|
|
+ filterable
|
|
|
+ placeholder="可用状态"
|
|
|
+ >
|
|
|
+ <el-option label="个人" value="0"></el-option>
|
|
|
+ <el-option label="公用" value="1"></el-option>
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item>
|
|
|
<el-button native-type="submit" type="danger">搜索</el-button>
|
|
|
+ <el-button native-type="reset" type="primary">重置</el-button>
|
|
|
</el-form-item>
|
|
|
</save-form>
|
|
|
<!-- 列表 -->
|
|
@@ -67,6 +80,11 @@
|
|
|
{{ scope.row.cooperationOrganId ? scope.row.cooperationOrganId : '租赁' }}
|
|
|
</template> -->
|
|
|
</el-table-column>
|
|
|
+ <el-table-column align="center" label="可用状态" width="120px">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ {{ scope.row.userId ? scope.row.realName : "公共" }}
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
<el-table-column align="center" width="120px" label="租赁费用">
|
|
|
<template slot-scope="scope">
|
|
|
{{ scope.row.cooperationOrganId ? "免费" : scope.row.remark }}
|
|
@@ -97,13 +115,19 @@
|
|
|
>修改</el-button
|
|
|
>
|
|
|
<el-button
|
|
|
- v-if="scope.row.delFlag == 0 && $helpers.permission('school/update/stop')"
|
|
|
+ v-if="
|
|
|
+ scope.row.delFlag == 0 &&
|
|
|
+ $helpers.permission('school/update/stop')
|
|
|
+ "
|
|
|
@click="onUpdateSubmit(scope.row, 2)"
|
|
|
type="text"
|
|
|
>停用</el-button
|
|
|
>
|
|
|
<el-button
|
|
|
- v-if="scope.row.delFlag == 2 && $helpers.permission('school/update/open')"
|
|
|
+ v-if="
|
|
|
+ scope.row.delFlag == 2 &&
|
|
|
+ $helpers.permission('school/update/open')
|
|
|
+ "
|
|
|
@click="onUpdateSubmit(scope.row, 0)"
|
|
|
type="text"
|
|
|
>启用</el-button
|
|
@@ -193,20 +217,33 @@
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
<el-form-item
|
|
|
+ v-if="formActionTitle == 'update'"
|
|
|
+ prop="user"
|
|
|
+ label="可用状态"
|
|
|
+ :label-width="formLabelWidth"
|
|
|
+ >
|
|
|
+ <el-input v-model="form.user" disabled></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item
|
|
|
v-if="form.source == 2"
|
|
|
prop="remark"
|
|
|
label="租赁费用"
|
|
|
:label-width="formLabelWidth"
|
|
|
>
|
|
|
- <el-input v-model.trim="form.remark" type="number" autocomplete="off"></el-input>
|
|
|
+ <el-input
|
|
|
+ v-model.trim="form.remark"
|
|
|
+ type="number"
|
|
|
+ autocomplete="off"
|
|
|
+ ></el-input>
|
|
|
</el-form-item>
|
|
|
+ <!-- v-if="form.source == 2" -->
|
|
|
<el-form-item
|
|
|
- v-if="form.source == 2"
|
|
|
prop="organId"
|
|
|
label="所属分部"
|
|
|
:label-width="formLabelWidth"
|
|
|
>
|
|
|
<el-select
|
|
|
+ :disabled="form.source != 2"
|
|
|
v-model.trim="form.organId"
|
|
|
clearable
|
|
|
style="width: 100% !important"
|
|
@@ -220,10 +257,9 @@
|
|
|
></el-option>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
- <!-- :show-message="addressMessage" -->
|
|
|
+ <!-- :show-message="addressMessage" -->
|
|
|
<el-form-item
|
|
|
prop="address"
|
|
|
-
|
|
|
label="上课地点"
|
|
|
:label-width="formLabelWidth"
|
|
|
>
|
|
@@ -353,6 +389,7 @@ export default {
|
|
|
searchForm: {
|
|
|
search: null,
|
|
|
organId: null,
|
|
|
+ publicFlag:null,
|
|
|
},
|
|
|
searchLsit: [],
|
|
|
tableList: [],
|
|
@@ -388,7 +425,9 @@ export default {
|
|
|
source: [
|
|
|
{ required: true, message: "请选择教学点来源", trigger: "change" },
|
|
|
],
|
|
|
- remark: [{ required: true, message: "请输入租赁费用", trigger: "blur" }],
|
|
|
+ remark: [
|
|
|
+ { required: true, message: "请输入租赁费用", trigger: "blur" },
|
|
|
+ ],
|
|
|
address: [
|
|
|
{ required: true, message: "请选择上课地点", trigger: "blur" },
|
|
|
],
|
|
@@ -481,8 +520,8 @@ export default {
|
|
|
this.mapStatus = true;
|
|
|
// let poi = this.addressDetail.poi
|
|
|
// let address = this.addressDetail.address
|
|
|
- this.addressDetail.address = this.form.address
|
|
|
- this.addressDetail.poi = this.form.longitudeLatitude
|
|
|
+ this.addressDetail.address = this.form.address;
|
|
|
+ this.addressDetail.poi = this.form.longitudeLatitude;
|
|
|
let poi = this.form.longitudeLatitude;
|
|
|
let address = this.form.address;
|
|
|
// 获取经纬度
|
|
@@ -509,6 +548,7 @@ export default {
|
|
|
}
|
|
|
},
|
|
|
onCooperationChange(value) {
|
|
|
+ this.form.organId = null;
|
|
|
this.cooperationList.forEach((item) => {
|
|
|
if (item.value == value) {
|
|
|
// this.selectOrganId = item.organId
|
|
@@ -537,10 +577,10 @@ export default {
|
|
|
},
|
|
|
getpoient(e) {
|
|
|
// let geocoder = new AMap.Geocoder()
|
|
|
- let geocoder = null
|
|
|
- AMap.plugin(["AMap.Geocoder"], function() {
|
|
|
- geocoder = new AMap.Geocoder()
|
|
|
- })
|
|
|
+ let geocoder = null;
|
|
|
+ AMap.plugin(["AMap.Geocoder"], function () {
|
|
|
+ geocoder = new AMap.Geocoder();
|
|
|
+ });
|
|
|
let that = this;
|
|
|
geocoder.getAddress(e.lnglat, function (status, result) {
|
|
|
if (status === "complete" && result.regeocode) {
|
|
@@ -559,7 +599,7 @@ export default {
|
|
|
ct.streetNumber,
|
|
|
poi: e.lnglat.lng + "," + e.lnglat.lat,
|
|
|
};
|
|
|
- that.onSearchResult([{lng:e.lnglat.lng,lat:e.lnglat.lat}])
|
|
|
+ that.onSearchResult([{ lng: e.lnglat.lng, lat: e.lnglat.lat }]);
|
|
|
// console.log(that.form.address,that.form.longitudeLatitude)
|
|
|
// that.form.address = result.regeocode.formattedAddress;
|
|
|
// that.mapStatus = false
|
|
@@ -589,6 +629,7 @@ export default {
|
|
|
let params = {
|
|
|
search: searchForm.search ? searchForm.search : null,
|
|
|
organId: searchForm.organId ? searchForm.organId : null,
|
|
|
+ publicFlag:searchForm.publicFlag ? searchForm.publicFlag : null,
|
|
|
rows: this.pageInfo.limit,
|
|
|
page: this.pageInfo.page,
|
|
|
};
|
|
@@ -651,7 +692,8 @@ export default {
|
|
|
address: row.address.split(",").join(""), // 上课地点
|
|
|
subsidy: row.subsidy, // 课酬补贴
|
|
|
organId: row.organId,
|
|
|
- longitudeLatitude:row.longitudeLatitude
|
|
|
+ longitudeLatitude: row.longitudeLatitude,
|
|
|
+ user: row.realName ? row.realName : "公共",
|
|
|
};
|
|
|
}
|
|
|
},
|
|
@@ -717,6 +759,14 @@ export default {
|
|
|
this.pageInfo.page = 1;
|
|
|
this.getList();
|
|
|
},
|
|
|
+ onReset(){
|
|
|
+ this.searchForm = {
|
|
|
+ search: null,
|
|
|
+ organId: null,
|
|
|
+ publicFlag:null,
|
|
|
+ }
|
|
|
+ this.search()
|
|
|
+ }
|
|
|
},
|
|
|
};
|
|
|
</script>
|