提交 6d5bf912 编写于 作者: fdj.'s avatar fdj.

发布签到页面进行修改

上级 1a202452
......@@ -157,7 +157,7 @@ export default {
mounted() {
this.initEcharts();
this.buildings = this.loadAll();
axios.post('http://36.139.166.61:19260/admin/signIn/search',{params:{}})
axios.post('http://36.139.166.61:19260/admin/signIn/search',{})
.then(response=>{
if (response.data.status ===1000){
this.options=response.data.data;
......
......@@ -9,7 +9,7 @@
</el-form-item>
<el-form-item label="开始时间">
<el-col :span="11">
<el-date-picker type="date" placeholder="选择日期" v-model="form.startdate1" format="yyyy-MM-dd" value-format="yyyy-MM-dd" style="width: 100%;"></el-date-picker>
<el-date-picker type="date" placeholder="选择日期" v-model="form.startdate1" format="yyyy-MM-dd" value-format="yyyy-MM-dd " style="width: 100%;"></el-date-picker>
</el-col>
<el-col class="line" :span="2">-</el-col>
<el-col :span="11">
......@@ -18,7 +18,7 @@
</el-form-item>
<el-form-item label="结束时间">
<el-col :span="11">
<el-date-picker type="date" placeholder="选择日期" value-format="yyyy-MM-dd" v-model="form.enddate1" style="width: 100%;"></el-date-picker>
<el-date-picker type="date" placeholder="选择日期" value-format="yyyy-MM-dd " v-model="form.enddate1" style="width: 100%;"></el-date-picker>
</el-col>
<el-col class="line" :span="2">-</el-col>
<el-col :span="11">
......@@ -195,14 +195,14 @@ export default {
this.form.islocation =1;
}
if (this.form.islocation) {
axios.post('http://36.139.166.61:19261/admin/signIn/add',
this.longitude = this.longitude-0;
this.latitude = this.latitude-0;
axios.post('http://36.139.166.61:19260/admin/signIn/add',
{
name: this.form.name, starttime: this.form.startdate1 + this.form.startdate2,
endtime: this.form.enddate1 + this.form.enddate2, location: this.form.islocation,
cycle: this.form.cyclestate, longitude: this.longitude, latitude: this.latitude,
}).then(response => {
alert(this.form.cyclestate);
alert(this.form.islocation);
if (response.data.status===1000){
this.$message({
message: '任务发布成功',
......@@ -216,6 +216,8 @@ export default {
})
}
else {
this.longitude = this.longitude-0;
this.latitude = this.latitude-0;
axios.post('http://36.139.166.61:19260/admin/signIn/add',
{name:this.form.name,starttime:this.form.startdate1+this.form.startdate2,
endtime:this.form.enddate1+this.form.enddate2,location:this.form.islocation,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册