Commit d69b5a4b authored by co_dengxiongwen's avatar co_dengxiongwen

tj

parent e6ffd873
...@@ -43,7 +43,7 @@ ...@@ -43,7 +43,7 @@
</div> </div>
<input @change="fileChange($event)" type="file" id="upload_file" style="display: none"/> <input @change="fileChange($event)" type="file" id="upload_file" style="display: none"/>
</div> </div>
el-button(type='primary' size='medium' @click='dataFormSubmit()' v-if="isAuth('line:station:save')" v-prevent-re-click style="margin-top:10px;margin-left:900px;") 保存 el-button(type='primary' size='medium' @click='dataFormSubmit()' v-if="isAuth('line:station:save')" v-prevent-re-click style="margin-top:10px;margin-left:500px;") 保存
</template> </template>
<script> <script>
...@@ -196,6 +196,8 @@ export default { ...@@ -196,6 +196,8 @@ export default {
type: 'success', type: 'success',
duration: 1500 duration: 1500
}) })
this.visible = false
this.$refs.dataForm.resetFields()
} else { } else {
this.$message.error(data.msg) this.$message.error(data.msg)
} }
......
...@@ -119,7 +119,7 @@ export default { ...@@ -119,7 +119,7 @@ export default {
} }
this.$http({ this.$http({
url: this.$http.adornUrl('/liStation/list'), url: this.$http.adornUrl('/liStation/pageList'),
method: 'post', method: 'post',
data: data data: data
}).then((data) => { }).then((data) => {
......
...@@ -2,10 +2,6 @@ ...@@ -2,10 +2,6 @@
el-dialog(width='60%' :close-on-click-modal='false', :visible.sync='visible' :modal-append-to-body='false' append-to-body) el-dialog(width='60%' :close-on-click-modal='false', :visible.sync='visible' :modal-append-to-body='false' append-to-body)
div.title-bold(slot='title') 详情 div.title-bold(slot='title') 详情
el-form(:model='dataForm', :rules='dataRule', ref='dataForm', label-width='100px') el-form(:model='dataForm', :rules='dataRule', ref='dataForm', label-width='100px')
el-row(:gutter="20")
el-col(:span='12')
el-form-item(label="所属线路:" prop="lineName")
el-input(v-model='dataForm.lineName' readonly)
el-row(:gutter="20") el-row(:gutter="20")
el-col(:span='12') el-col(:span='12')
el-form-item(label="站点名称:" prop="stationName") el-form-item(label="站点名称:" prop="stationName")
...@@ -24,9 +20,10 @@ ...@@ -24,9 +20,10 @@
el-col(:span='24') el-col(:span='24')
el-form-item(label="站点描述:" prop="remark") el-form-item(label="站点描述:" prop="remark")
el-input(v-model='dataForm.remark' type="textarea" :rows=4 resize="none" placeholder="请输入站点描述" readonly) el-input(v-model='dataForm.remark' type="textarea" :rows=4 resize="none" placeholder="请输入站点描述" readonly)
div el-row(style="padding-bottom:15px;" :span="24")
div(style='line-height: 40px;') 站点地图 el-col(:md='23' :sm="5")
el-divider div.title-bold(style='line-height: 40px;') 场景地图
//- el-divider
<div class="fileDiv"> <div class="fileDiv">
<div class="fileList" v-for="(item,index) in fileList"> <div class="fileList" v-for="(item,index) in fileList">
<el-input size="mini" v-model='item.name' readonly></el-input> <el-input size="mini" v-model='item.name' readonly></el-input>
...@@ -39,7 +36,7 @@ ...@@ -39,7 +36,7 @@
<script> <script>
export default { export default {
data () { data() {
return { return {
dataList: [], dataList: [],
dataListLoading: false, dataListLoading: false,
...@@ -69,7 +66,7 @@ export default { ...@@ -69,7 +66,7 @@ export default {
} }
}, },
methods: { methods: {
init (id) { init(id) {
this.visible = true this.visible = true
this.clickFlag = false this.clickFlag = false
this.dataForm.id = id this.dataForm.id = id
...@@ -78,23 +75,23 @@ export default { ...@@ -78,23 +75,23 @@ export default {
this.initDataFrom() this.initDataFrom()
} }
}, },
initDataFrom () { initDataFrom() {
this.$http({ this.$http({
url: this.$http.adornUrl(`/liStation/getId/${this.dataForm.id}`), url: this.$http.adornUrl(`/liStation/getId/${this.dataForm.id}`),
method: 'get', method: 'get',
params: this.$http.adornParams() params: this.$http.adornParams()
}).then(data => { }).then((data) => {
if (data && data.code === 0) { if (data && data.code === 0) {
this.dataForm = data.bean this.dataForm = data.bean
console.log('站点地图:', data.bean.mapList) console.log('站点地图:', data.bean.mapList)
this.fileList = data.bean.mapList this.fileList = data.bean.mapList
this.fileList.forEach(element => { this.fileList.forEach((element) => {
element.readPath = this.urlPath + element.filePath element.readPath = this.urlPath + element.filePath
}) })
} }
}) })
}, },
initData () { initData() {
this.typeList = [ this.typeList = [
{ id: '1', name: '正线站点' }, { id: '1', name: '正线站点' },
{ id: '2', name: '换乘站点' } { id: '2', name: '换乘站点' }
...@@ -103,7 +100,7 @@ export default { ...@@ -103,7 +100,7 @@ export default {
} }
} }
</script> </script>
<style lang='scss' scoped> <style lang="scss" scoped>
.fileDiv { .fileDiv {
height: 200px; height: 200px;
width: 100%; width: 100%;
......
<template lang="pug"> <template lang="pug">
el-dialog( :close-on-click-modal='false', :visible.sync='visible' append-to-body :modal-append-to-body='false') el-dialog( :close-on-click-modal='false', :visible.sync='visible' append-to-body :modal-append-to-body='false')
div.title-bold(slot='title') 预览站点地图 div.title-bold(slot='title') 预览场景地图
el-carousel(:interval="5000" arrow="always") el-carousel(:interval="5000" arrow="always")
el-carousel-item(v-for="item in mapList" :key="item.id" :label="item.name") el-carousel-item(v-for="item in mapList" :key="item.id" :label="item.name")
el-image(:src="item.readPath" fit='scale-down') el-image(:src="item.readPath" fit='scale-down')
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
<script> <script>
export default { export default {
data () { data() {
return { return {
clickFlag: false, clickFlag: false,
visible: false, visible: false,
...@@ -21,7 +21,7 @@ export default { ...@@ -21,7 +21,7 @@ export default {
} }
}, },
methods: { methods: {
init (id) { init(id) {
this.visible = true this.visible = true
this.stationId = id this.stationId = id
if (this.stationId) { if (this.stationId) {
...@@ -29,11 +29,11 @@ export default { ...@@ -29,11 +29,11 @@ export default {
url: this.$http.adornUrl(`/liStation/getId/${this.stationId}`), url: this.$http.adornUrl(`/liStation/getId/${this.stationId}`),
method: 'get', method: 'get',
params: this.$http.adornParams() params: this.$http.adornParams()
}).then(data => { }).then((data) => {
if (data && data.code === 0) { if (data && data.code === 0) {
console.log('站点地图:', data.bean.mapList) console.log('站点地图:', data.bean.mapList)
this.mapList = data.bean.mapList this.mapList = data.bean.mapList
this.mapList.forEach(element => { this.mapList.forEach((element) => {
element.readPath = this.urlPath + element.filePath element.readPath = this.urlPath + element.filePath
}) })
} }
...@@ -44,7 +44,7 @@ export default { ...@@ -44,7 +44,7 @@ export default {
} }
</script> </script>
<style> <style>
.el-carousel__container{ .el-carousel__container {
height: 570px; height: 570px;
} }
.el-carousel__item h3 { .el-carousel__item h3 {
...@@ -59,7 +59,7 @@ export default { ...@@ -59,7 +59,7 @@ export default {
background-color: #99a9bf; background-color: #99a9bf;
} }
.el-carousel__item:nth-child(2n+1) { .el-carousel__item:nth-child(2n + 1) {
background-color: #d3dce6; background-color: #d3dce6;
} }
</style> </style>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment