dev-zcx
zcxee 1 year ago
parent 7b1afb53da
commit b27a46f037
  1. 14
      src/api/sch/place.js
  2. 13
      src/views/sch/place/index.vue
  3. 4
      src/views/zs/clue/ClueForm/components/ClassTypeDialog.vue
  4. 2
      src/views/zs/clue/index.vue
  5. 4
      src/views/zs/sign/components/CheckDialog/index.vue

@ -17,8 +17,8 @@ export async function updateSchoolStatus(data) {
}); });
} }
// 保存场地状态 // 新增
export function savePlace(data) { export function addPlace(data) {
return request({ return request({
url: '/sch/place', url: '/sch/place',
method: 'post', method: 'post',
@ -27,6 +27,16 @@ export function savePlace(data) {
} }
// 修改场地
export function updatePlace(data) {
return request({
url: '/sch/place',
method: 'put',
data: data
});
}
// 查询场地 // 查询场地
export function getAllPlaces(param) { export function getAllPlaces(param) {
return request({ return request({

@ -145,7 +145,7 @@
</template> </template>
<!-- eslint-disable no-undef --> <!-- eslint-disable no-undef -->
<script> <script>
import { getMapData, savePlace, updateSchoolStatus } from '@/api/sch/place'; import { getMapData, addPlace, updatePlace, updateSchoolStatus } from '@/api/sch/place';
export default { export default {
name: 'Place', name: 'Place',
data() { data() {
@ -427,7 +427,7 @@ export default {
// //
if (this.checkPlaceFormValidate()) { if (this.checkPlaceFormValidate()) {
// 访idplaceForm // 访idplaceForm
const resp = await savePlace(this.placeForm); const resp = this.savePlace(this.placeForm);
if (resp.code != 200) { if (resp.code != 200) {
return; return;
} else { } else {
@ -473,6 +473,13 @@ export default {
this.placeMarkerList = tmpArr1; this.placeMarkerList = tmpArr1;
} }
}, },
async savePlace(item) {
if (item.placeId) {
return updatePlace(item);
} else {
return addPlace(item)
}
},
checkPlaceFormValidate() { checkPlaceFormValidate() {
const valid = []; const valid = [];
if (!this.placeForm.name) { if (!this.placeForm.name) {
@ -570,7 +577,7 @@ export default {
}, },
// //
async changePlaceStatus(item) { async changePlaceStatus(item) {
const resp = await savePlace(item); const resp = await updatePlace(item);
if (resp.code == 200) { if (resp.code == 200) {
this.resetMarkers(); this.resetMarkers();
} }

@ -27,13 +27,13 @@ export default {
methods: { methods: {
async init(info) { async init(info) {
this.title = info.schoolName + '-' + info.name + '-班型报价'; this.title = info.schoolName + '-' + info.name + '-班型报价';
const resp = await getClassTypeTableList({ const resp = await getAllList({
schoolId: info.schoolId, schoolId: info.schoolId,
placeId: info.placeId, placeId: info.placeId,
status: '0' status: '0'
}); });
if (resp.code == 200) { if (resp.code == 200) {
this.getAllList = resp.data this.classTypeList = resp.data
} }
this.visible = true this.visible = true
}, },

@ -165,7 +165,7 @@ export default {
}, },
// 线 // 线
handleDiscard(item) { handleDiscard(item) {
his.$confirm('是否确认释放该条线索(“' + item.name + '/' + item.phone + '”)到公海?', '警告', { this.$confirm('是否确认释放该条线索(“' + item.name + '/' + item.phone + '”)到公海?', '警告', {
confirmButtonText: '确定', confirmButtonText: '确定',
cancelButtonText: '取消', cancelButtonText: '取消',
type: 'warning' type: 'warning'

@ -10,8 +10,8 @@
</el-tab-pane> </el-tab-pane>
</el-tabs> </el-tabs>
<span slot="footer"> <span slot="footer">
<el-button type="primary" v-if="modalForm.state == 1 && checkTab == 'two'" :disabled="!canSubmit" :loading="loading" @click="handleCheck(2)">通过</el-button> <el-button type="primary" v-if="modalForm.checkState == 1 && checkTab == 'two'" :disabled="!canSubmit" :loading="loading" @click="handleCheck(2)">通过</el-button>
<el-button type="primary" v-if="modalForm.state == 1 && checkTab == 'two'" :disabled="!canSubmit" :loading="loading" @click="handleCheck(3)">驳回</el-button> <el-button type="primary" v-if="modalForm.checkState == 1 && checkTab == 'two'" :disabled="!canSubmit" :loading="loading" @click="handleCheck(3)">驳回</el-button>
<el-button @click="visible = false"> </el-button> <el-button @click="visible = false"> </el-button>
</span> </span>
</el-dialog> </el-dialog>

Loading…
Cancel
Save