Commit 72abe1c5 authored by 黄奎's avatar 黄奎

下载修改

parent 83747c65
<style> <style>
.CarrierList { .CarrierList {
border-bottom: 1px dashed #eee; border-bottom: 1px dashed #eee;
padding-bottom: 5px; padding-bottom: 5px;
margin-bottom: 5px; margin-bottom: 5px;
} }
.CarrierList span {
display: inline-block;
margin-right: 10px;
}
.CarrierList span {
display: inline-block;
margin-right: 10px;
}
</style> </style>
<template> <template>
<div class="VehicleManagement"> <div class="VehicleManagement">
<div class="head-title"> <div class="head-title">
载体管理 载体管理
<!-- <el-button style="float:right;margin-top: -5px;" size="small" type="primary" @click="CommonJump('editVehicle')">
新增载体</el-button> -->
 
<div> <div>
<el-button <el-button @click="checkAll=false,dialogVisible = true" style="float: right; margin-top: -25px" size="small" type="primary">
@click="dialogVisible = true" 批量导出
style="float: right; margin-top: -25px"
size="small"
type="primary"
>批量导出
</el-button> </el-button>
</div> </div>
<div> <div>
<el-button <el-button type="primary" style="float: right; margin: -25px 10px 0px 0px" class="el-button--small"
type="primary" @click="CommonJump('editVehicle')">新增载体</el-button>
style="float: right; margin: -25px 10px 0px 0px"
class="el-button--small"
@click="CommonJump('editVehicle')"
>新增载体</el-button
>
</div> </div>
</div> </div>
<div class="content"> <div class="content">
<div> <div>
<div class="searchInput" style="width: 250px; margin-bottom: 10px"> <div class="searchInput" style="width: 250px; margin-bottom: 10px">
<el-input <el-input @keyup.enter.native="(msg.pageIndex = 1), getList()" @clear="(msg.pageIndex = 1), getList()"
@keyup.enter.native="(msg.pageIndex = 1), getList()" style="display: inline-block; width: 225px; height: 30px" placeholder="项目名称" v-model="msg.CarrierName"
@clear="(msg.pageIndex = 1), getList()" size="small" clearable>
style="display: inline-block; width: 225px; height: 30px"
placeholder="项目名称"
v-model="msg.CarrierName"
size="small"
clearable
>
</el-input> </el-input>
<span <span @click="(msg.pageIndex = 1), getList()" class="el-icon-search" style="
@click="(msg.pageIndex = 1), getList()"
class="el-icon-search"
style="
color: #979dad; color: #979dad;
font-size: 14px; font-size: 14px;
position: relative; position: relative;
top: 1px; top: 1px;
" "></span>
></span>
</div> </div>
<div class="searchInput" style="width: 250px; margin-bottom: 10px"> <div class="searchInput" style="width: 250px; margin-bottom: 10px">
<el-input <el-input @keyup.enter.native="(msg.pageIndex = 1), getList()" @clear="(msg.pageIndex = 1), getList()"
@keyup.enter.native="(msg.pageIndex = 1), getList()" style="display: inline-block; width: 225px; height: 30px" placeholder="开发商" v-model="msg.Developers"
@clear="(msg.pageIndex = 1), getList()" size="small" clearable>
style="display: inline-block; width: 225px; height: 30px"
placeholder="开发商"
v-model="msg.Developers"
size="small"
clearable
>
</el-input> </el-input>
<span <span @click="(msg.pageIndex = 1), getList()" class="el-icon-search" style="
@click="(msg.pageIndex = 1), getList()"
class="el-icon-search"
style="
color: #979dad; color: #979dad;
font-size: 14px; font-size: 14px;
position: relative; position: relative;
top: 1px; top: 1px;
" "></span>
></span>
</div> </div>
<div class="searchInput" style="width: 250px; margin-bottom: 10px"> <div class="searchInput" style="width: 250px; margin-bottom: 10px">
<el-input <el-input @keyup.enter.native="(msg.pageIndex = 1), getList()" @clear="(msg.pageIndex = 1), getList()"
@keyup.enter.native="(msg.pageIndex = 1), getList()" style="display: inline-block; width: 225px; height: 30px" @keyup.native="checkInteger(msg, 'MetroNum')"
@clear="(msg.pageIndex = 1), getList()" placeholder="地铁线路" v-model="msg.MetroNum" size="small" clearable>
style="display: inline-block; width: 225px; height: 30px"
@keyup.native="checkInteger(msg, 'MetroNum')"
placeholder="地铁线路"
v-model="msg.MetroNum"
size="small"
clearable
>
</el-input> </el-input>
<span <span @click="(msg.pageIndex = 1), getList()" class="el-icon-search" style="
@click="(msg.pageIndex = 1), getList()"
class="el-icon-search"
style="
color: #979dad; color: #979dad;
font-size: 14px; font-size: 14px;
position: relative; position: relative;
top: 1px; top: 1px;
" "></span>
></span>
</div> </div>
<div class="searchInput" style="width: 250px; margin-bottom: 10px"> <div class="searchInput" style="width: 250px; margin-bottom: 10px">
<el-input <el-input @keyup.enter.native="(msg.pageIndex = 1), getList()" @clear="(msg.pageIndex = 1), getList()"
@keyup.enter.native="(msg.pageIndex = 1), getList()" style="display: inline-block; width: 225px; height: 30px" placeholder="地铁站名称" v-model="msg.MetroName"
@clear="(msg.pageIndex = 1), getList()" size="small" clearable>
style="display: inline-block; width: 225px; height: 30px"
placeholder="地铁站名称"
v-model="msg.MetroName"
size="small"
clearable
>
</el-input> </el-input>
<span <span @click="(msg.pageIndex = 1), getList()" class="el-icon-search" style="
@click="(msg.pageIndex = 1), getList()"
class="el-icon-search"
style="
color: #979dad; color: #979dad;
font-size: 14px; font-size: 14px;
position: relative; position: relative;
top: 1px; top: 1px;
" "></span>
></span>
</div> </div>
<div class="searchInput" style="width: 200px; margin-bottom: 10px"> <div class="searchInput" style="width: 200px; margin-bottom: 10px">
<el-select size="small" v-model="msg.UserId" :filter-method="ChangeListName" filterable @change="(msg.pageIndex = 1), getList()" <el-select size="small" v-model="msg.UserId" :filter-method="ChangeListName" filterable
placeholder="请选择"> @change="(msg.pageIndex = 1), getList()" placeholder="请选择">
<el-option label="不限" :value="0"></el-option> <el-option label="不限" :value="0"></el-option>
<el-option v-for="item in userList" :key="item.Id" :label="item.Name" :value="item.Id"> <el-option v-for="item in userList" :key="item.Id" :label="item.Name" :value="item.Id">
</el-option> </el-option>
</el-select> </el-select>
</div> </div>
<el-date-picker <el-date-picker class="indataPicker" type="daterange" v-model="dateStr" range-separator="至"
class="indataPicker" start-placeholder="开业日期" end-placeholder="开业日期" size="small" @change="getList" value-format="yyyy-MM-dd">
type="daterange"
v-model="dateStr"
range-separator="至"
start-placeholder="开业日期"
end-placeholder="开业日期"
size="small"
@change="getList"
value-format="yyyy-MM-dd"
>
</el-date-picker> </el-date-picker>
</div> </div>
<el-table <el-table :data="tableData" v-loading="loading" border style="width: 100%; margin: 20px 0">
:data="tableData"
v-loading="loading"
border
style="width: 100%; margin: 20px 0"
>
<el-table-column prop="CarrierName" width="200" label="项目名称"> <el-table-column prop="CarrierName" width="200" label="项目名称">
</el-table-column> </el-table-column>
<el-table-column prop="CarrierMetroList" label="地铁信息" width="200"> <el-table-column prop="CarrierMetroList" label="地铁信息" width="200">
<template slot-scope="scope"> <template slot-scope="scope">
<div <div v-for="(item, index) in scope.row.CarrierMetroList" :key="index" class="CarrierList">
v-for="(item, index) in scope.row.CarrierMetroList" <span>{{ item.MetroNum }}号线</span><span>{{ item.MetroName }}</span><span>{{ item.Distance }}</span>
:key="index"
class="CarrierList"
>
<span>{{ item.MetroNum }}号线</span
><span>{{ item.MetroName }}</span
><span>{{ item.Distance }}</span>
</div> </div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="Logo" width="100" label="logo"> <el-table-column prop="Logo" width="100" label="logo">
<template slot-scope="scope"> <template slot-scope="scope">
<el-image <el-image :src="scope.row.Logo" style="width: 50px" :preview-src-list="scope.row.LogoList">
:src="scope.row.Logo"
style="width: 50px"
:preview-src-list="scope.row.LogoList"
>
</el-image> </el-image>
</template> </template>
</el-table-column> </el-table-column>
...@@ -195,286 +119,305 @@ ...@@ -195,286 +119,305 @@
<el-table-column prop="UserName" width="100" label="认证用户"></el-table-column> <el-table-column prop="UserName" width="100" label="认证用户"></el-table-column>
<el-table-column label="操作" width="100"> <el-table-column label="操作" width="100">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tooltip <el-tooltip class="item" effect="dark" content="修改" placement="top">
class="item" <img @click="CommonJump('editVehicle', { ID: scope.row.ID })" src="../../assets/img/userman/edit.png"
effect="dark" alt="" />
content="修改"
placement="top"
>
<img
@click="CommonJump('editVehicle', { ID: scope.row.ID })"
src="../../assets/img/userman/edit.png"
alt=""
/>
</el-tooltip> </el-tooltip>
<el-tooltip <el-tooltip class="item" effect="dark" content="删除" placement="top">
class="item" <img @click="delManage(scope.row)" src="../../assets/img/userman/del.png" alt="" />
effect="dark"
content="删除"
placement="top"
>
<img
@click="delManage(scope.row)"
src="../../assets/img/userman/del.png"
alt=""
/>
</el-tooltip> </el-tooltip>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<el-pagination <el-pagination style="text-align: right" background @current-change="handleCurrentChange"
style="text-align: right" :page-size="msg.pageSize" :current-page.sync="msg.pageIndex" layout="total,prev, pager, next" :total="total">
background
@current-change="handleCurrentChange"
:page-size="msg.pageSize"
:current-page.sync="msg.pageIndex"
layout="total,prev, pager, next"
:total="total"
>
</el-pagination> </el-pagination>
</div> </div>
<!-- 选择导出信息 --> <!-- 选择导出信息 -->
<el-dialog title="选择导出信息" :visible.sync="dialogVisible" width="960px"> <el-dialog title="选择导出信息" :visible.sync="dialogVisible" width="960px">
<el-form <div v-loading="downLoadLoading" :element-loading-text="loadingText">
style="border: 1px solid #f0f2f7" <el-form style="border: 1px solid #f0f2f7" :model="addMsg" ref="addMsg" label-width="100px">
:model="addMsg" <div style="
ref="addMsg"
label-width="100px"
>
<div
style="
box-sizing: border-box; box-sizing: border-box;
background-color: #f3f5f6; background-color: #f3f5f6;
width: 100%; width: 100%;
padding-left: 20px; padding-left: 20px;
height: 50px; height: 50px;
line-height: 50px; line-height: 50px;
" ">
> <el-checkbox :indeterminate="isIndeterminate" v-model="checkAll" @change="handleCheckAllChange">全选
<el-checkbox </el-checkbox>
:indeterminate="isIndeterminate" </div>
v-model="checkAll" <div style="margin: 15px 0"></div>
@change="handleCheckAllChange" <div style="padding: 10px 25px 20px">
>全选 <el-checkbox-group v-model="checkedCities" @change="handleCheckedCitiesChange">
</el-checkbox> <el-checkbox style="margin-bottom: 10px; width: 135px" v-for="city in cities" :label="city.Id"
</div> :key="city.Name">
<div style="margin: 15px 0"></div> {{ city.Name }}</el-checkbox>
<div style="padding: 10px 25px 20px"> </el-checkbox-group>
<el-checkbox-group </div>
v-model="checkedCities" </el-form>
@change="handleCheckedCitiesChange" <div style="text-align: right; margin-top: 20px">
> <el-button size="small" type="primary" @click="downLoadCarrier">导出</el-button>
<el-checkbox
style="margin-bottom: 10px; width: 135px"
v-for="city in cities"
:label="city.Id"
:key="city.Name"
>
{{ city.Name }}</el-checkbox
>
</el-checkbox-group>
</div> </div>
</el-form>
<div style="text-align: right; margin-top: 20px">
<el-button size="small" type="primary" @click="Export">导出</el-button>
</div> </div>
</el-dialog> </el-dialog>
</div> </div>
</template> </template>
<script> <script>
export default { import {
data() { setInterval,
return { clearInterval
msg: { } from 'timers';
MetroName: "", //地铁站名称 export default {
pageIndex: 1, data() {
pageSize: 15, return {
CarrierName: "", //载体名称 msg: {
MetroNum: "", //地铁线路 MetroName: "", //地铁站名称
Developers: "", //开发商 pageIndex: 1,
StartOpenTime: "", //开业开始时间 pageSize: 15,
EndOpenTime: "", // 开业截止时间 CarrierName: "", //载体名称
ExcelEnumIds: [], MetroNum: "", //地铁线路
UserId:0, Developers: "", //开发商
}, StartOpenTime: "", //开业开始时间
usermsg: { EndOpenTime: "", // 开业截止时间
pageIndex: 1, ExcelEnumIds: [],
pageSize: 20, UserId: 0,
Name: '', },
Source: 0, usermsg: {
MemberGrade: 0, pageIndex: 1,
Id: 0, pageSize: 20,
Moblie: '' Name: '',
}, Source: 0,
userList:[], MemberGrade: 0,
addMsg: {}, Id: 0,
dialogVisible: false, Moblie: ''
dateStr: [], //日期 },
total: 0, userList: [],
tableData: [], //数据列表 addMsg: {},
isShowAdd: false, //新增修改载体 dialogVisible: false,
ProjectTypeList: [], //项目类型 dateStr: [], //日期
checkAll: false, total: 0,
checkedCities: [], tableData: [], //数据列表
cities: [], isShowAdd: false, //新增修改载体
cityOptions: [], ProjectTypeList: [], //项目类型
isIndeterminate: false, checkAll: false,
}; checkedCities: [],
}, cities: [],
created() { cityOptions: [],
this.getList(); isIndeterminate: false,
this.getTypeEnumList(); downLoadLoading: false, //导出Loading
this.getDown(); download_timer: null, //下载文件timer
this.getuserList() loadingText: "", //下载文件提示名称
}, };
methods: { },
ChangeListName(val) { created() {
this.getList();
this.getTypeEnumList();
this.getDown();
this.getuserList()
},
methods: {
ChangeListName(val) {
this.usermsg.Name = val; this.usermsg.Name = val;
this.getuserList(); this.getuserList();
}, },
getuserList() { getuserList() {
this.apipost("/api/user/GetMemberUserDropDownList", this.usermsg, res => { this.apipost("/api/user/GetMemberUserDropDownList", this.usermsg, res => {
if (res.data.resultCode == 1) { if (res.data.resultCode == 1) {
let pageData = res.data.data.pageData; let pageData = res.data.data.pageData;
this.userList = pageData; this.userList = pageData;
} }
}) })
}, },
getList() { getList() {
this.loading = true; this.loading = true;
if (this.dateStr && this.dateStr.length > 0) { if (this.dateStr && this.dateStr.length > 0) {
this.msg.StartOpenTime = this.dateStr[0]; this.msg.StartOpenTime = this.dateStr[0];
this.msg.EndOpenTime = this.dateStr[1]; this.msg.EndOpenTime = this.dateStr[1];
} else { } else {
this.msg.StartOpenTime = ""; this.msg.StartOpenTime = "";
this.msg.EndOpenTime = ""; this.msg.EndOpenTime = "";
}
this.apipost("/api/Trade/GetCarrierPageList", this.msg, (res) => {
this.loading = false;
if (res.data.resultCode == 1) {
this.total = res.data.data.count;
let pageData = res.data.data.pageData;
this.tableData = pageData;
this.tableData.forEach((x) => {
x.LogoList = [];
x.LogoList.push(x.Logo);
});
}
});
},
handleCheckAllChange(val) {
this.checkedCities = val ? this.cityOptions : [];
this.isIndeterminate = false;
},
handleCheckedCitiesChange(value) {
let checkedCount = value.length;
this.checkAll = checkedCount === this.cities.length;
this.isIndeterminate =
checkedCount > 0 && checkedCount < this.cities.length;
},
Export() {
this.msg.ExcelEnumIds = this.checkedCities;
let msg = JSON.parse(JSON.stringify(this.msg));
if (!msg.Id || msg.Id == "") {
msg.Id = 0;
}
this.GetLocalFile(
"/api/Trade/GetCarrierListToExcel",
msg,
"载体信息.xls",
null,
() => {
this.checkedCities = [];
} }
); this.apipost("/api/Trade/GetCarrierPageList", this.msg, (res) => {
}, this.loading = false;
getDown() { if (res.data.resultCode == 1) {
this.cityOptions = []; this.total = res.data.data.count;
this.apipost("/api/Trade/GetCarrierExportEnumList", {}, (res) => { let pageData = res.data.data.pageData;
this.cities = res.data.data; this.tableData = pageData;
let data = res.data.data; this.tableData.forEach((x) => {
data.forEach((item) => { x.LogoList = [];
this.cityOptions.push(item.Id); x.LogoList.push(x.Logo);
});
}
}); });
}); },
}, handleCheckAllChange(val) {
this.checkedCities = val ? this.cityOptions : [];
//删除 this.isIndeterminate = false;
delManage(obj) { },
let that = this; handleCheckedCitiesChange(value) {
that.Confirm("是否删除?", function () { let checkedCount = value.length;
that.apipost( this.checkAll = checkedCount === this.cities.length;
"/api/Trade/RemoveCarrier", this.isIndeterminate =
{ checkedCount > 0 && checkedCount < this.cities.length;
CarrierId: obj.ID, },
Status: 1, //下载载体文件
}, downLoadCarrier() {
this.msg.ExcelEnumIds = this.checkedCities;
let msg = JSON.parse(JSON.stringify(this.msg));
if (!msg.Id || msg.Id == "") {
msg.Id = 0;
}
this.downLoadLoading = true;
this.loadingText = "正在生成载体文件,请勿关闭或刷新页面...";
var that = this;
this.download_timer = setInterval(function () {
that.checkCarrierFile(msg)
}, 2000);
},
checkCarrierFile(msg) {
var fileName = "载体信息.xls";
var that = this;
this.apipost(
"/api/Trade/CheckCarrierFile",
msg,
(res) => { (res) => {
if (res.data.resultCode == 1) { if (res.data.resultCode == 1) {
that.Success(res.data.message); clearInterval(this.download_timer);
that.getList(); this.checkedCities = [];
} else { this.loadingText = "正在下载载体文件,请勿关闭或刷新页面...";
that.Error(res.data.message); var fileUrl = res.data.data.fileUrl;
var filepath = res.data.data.filePath;
var key = res.data.message;
var params = {
fileUrl: fileUrl
}
//删除缓存和Key
var deleteparams = {
key: key,
fileUrl: fileUrl,
filepath: filepath,
};
var apiurl = that.domainManager().DomainUrl + "/api/Trade/GetFile";
var postData = that.GetPostData("", params, "");
that.$http.post(apiurl, postData, {
responseType: 'arraybuffer',
onDownloadProgress: (progressEvent) => {
const progress = Math.round((progressEvent.loaded / progressEvent.total) * 100);
that.loadingText = `正在下载载体文件` + progress + `%,请勿关闭或刷新页面...`;
// 在这里处理下载进度, 如更新界面上的进度条
}
}).then((res) => {
let blob = new Blob([res.data], {
type: "application/vnd.ms-excel"
})
let url = URL.createObjectURL(blob);
let link = document.createElement('a');
link.href = url;
link.setAttribute("download", fileName);
document.body.appendChild(link);
link.click();
that.downLoadLoading = false;
that.loadingText = "";
that.apipost("/api/Trade/DeleteKey", deleteparams, (res) => {})
that.dialogVisible = false;
}).catch(function (res) {
console.log(res);
});
} }
} }
); );
}); },
},
handleCurrentChange(val) {
this.msg.pageIndex = val;
this.getList();
},
//获取项目类型
getTypeEnumList() {
this.apipost("/api/Trade/GetProjectTypeEnumList", {}, (res) => {
if (res.data.resultCode == 1) {
this.ProjectTypeList = res.data.data;
}
});
},
//获取项目类型 getDown() {
getProject(type) { this.cityOptions = [];
let str = ""; this.apipost("/api/Trade/GetCarrierExportEnumList", {}, (res) => {
this.ProjectTypeList.forEach((x) => { this.cities = res.data.data;
if (x.Id == type) { let data = res.data.data;
str = x.Name; data.forEach((item) => {
} this.cityOptions.push(item.Id);
}); });
return str; });
},
//删除
delManage(obj) {
let that = this;
that.Confirm("是否删除?", function () {
that.apipost(
"/api/Trade/RemoveCarrier", {
CarrierId: obj.ID,
Status: 1,
},
(res) => {
if (res.data.resultCode == 1) {
that.Success(res.data.message);
that.getList();
} else {
that.Error(res.data.message);
}
}
);
});
},
handleCurrentChange(val) {
this.msg.pageIndex = val;
this.getList();
},
//获取项目类型
getTypeEnumList() {
this.apipost("/api/Trade/GetProjectTypeEnumList", {}, (res) => {
if (res.data.resultCode == 1) {
this.ProjectTypeList = res.data.data;
}
});
},
//获取项目类型
getProject(type) {
let str = "";
this.ProjectTypeList.forEach((x) => {
if (x.Id == type) {
str = x.Name;
}
});
return str;
},
}, },
}, mounted() {},
mounted() {}, };
};
</script> </script>
<style> <style>
.VehicleManagement .content .searchInput { .VehicleManagement .content .searchInput {
border: 1px solid #dcdfe6; border: 1px solid #dcdfe6;
border-radius: 4px; border-radius: 4px;
} }
.VehicleManagement .content .searchInput .el-input__inner {
border: none;
outline: none;
height: 30px;
line-height: 30px;
}
.VehicleManagement .content .searchInput .el-input__inner { .VehicleManagement .content .searchInput {
border: none; line-height: normal;
outline: none; display: inline-table;
height: 30px; width: 100%;
line-height: 30px; border-collapse: separate;
} border-spacing: 0;
width: 250px;
margin-right: 20px;
}
.VehicleManagement .content .searchInput { .VehicleManagement .content {
line-height: normal; background: #fff;
display: inline-table; margin-top: 10px;
width: 100%; padding: 20px;
border-collapse: separate; box-sizing: border-box;
border-spacing: 0; }
width: 250px;
margin-right: 20px;
}
.VehicleManagement .content {
background: #fff;
margin-top: 10px;
padding: 20px;
box-sizing: border-box;
}
</style> </style>
...@@ -196,10 +196,8 @@ ...@@ -196,10 +196,8 @@
<div style="text-align: right; margin-top: 20px"> <div style="text-align: right; margin-top: 20px">
<el-button size="small" type="primary" @click="downloadBrandFile">导出</el-button> <el-button size="small" type="primary" @click="downloadBrandFile">导出</el-button>
</div> </div>
</div> </div>
</el-dialog> </el-dialog>
<a id="downloadLink" href="" download="品牌信息.xls" style="display:none">下载 Excel 文件</a>
</div> </div>
</template> </template>
<script> <script>
...@@ -300,7 +298,7 @@ ...@@ -300,7 +298,7 @@
} }
); );
}, },
//批量导出 //下载品牌文件
downloadBrandFile() { downloadBrandFile() {
this.msg.ExcelEnumIds = this.checkedCities; this.msg.ExcelEnumIds = this.checkedCities;
let msg = JSON.parse(JSON.stringify(this.msg)); let msg = JSON.parse(JSON.stringify(this.msg));
...@@ -337,16 +335,6 @@ ...@@ -337,16 +335,6 @@
fileUrl: fileUrl, fileUrl: fileUrl,
filepath: filepath, filepath: filepath,
}; };
// that.downLoadLoading = false;
// that.loadingText = "";
// that.dialogVisible = false;
// var newUrl = that.domainManager().DomainUrl + fileUrl;
// var linkObj = document.getElementById("downloadLink");
// linkObj.href = newUrl;
// linkObj.setAttribute("download", fileName);
// linkObj.click();
var apiurl = that.domainManager().DomainUrl + "/api/Trade/GetFile"; var apiurl = that.domainManager().DomainUrl + "/api/Trade/GetFile";
var postData = that.GetPostData("", params, ""); var postData = that.GetPostData("", params, "");
that.$http.post(apiurl, postData, { that.$http.post(apiurl, postData, {
...@@ -383,10 +371,8 @@ ...@@ -383,10 +371,8 @@
var tempData = []; var tempData = [];
let data = res.data.data; let data = res.data.data;
data.forEach((item) => { data.forEach((item) => {
this.cityOptions.push(item.Id);
this.cityOptions.push(item.Id); tempData.push(item);
tempData.push(item);
}); });
this.cities = tempData; this.cities = tempData;
}); });
......
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