暂存
This commit is contained in:
@@ -68,7 +68,8 @@
|
||||
</view>
|
||||
</template>
|
||||
<script>
|
||||
import $http from '@/config/requestConfig.js';
|
||||
import { parse } from 'qs';
|
||||
import $http from '@/config/requestConfig.js';
|
||||
import permission from "@/js_sdk/wa-permission/permission.js"
|
||||
import {
|
||||
mapState,
|
||||
@@ -87,6 +88,7 @@
|
||||
content: '', // 描述
|
||||
img: '', //图片
|
||||
type: undefined, // 反馈类型
|
||||
sort:undefined
|
||||
},
|
||||
range:[
|
||||
{ value: '0', text: "班内作业",name:"班内作业"},
|
||||
@@ -123,13 +125,15 @@
|
||||
|
||||
},
|
||||
pageType: '',
|
||||
pageName:''
|
||||
pageName:''
|
||||
};
|
||||
},
|
||||
//第一次加载
|
||||
onLoad(e) {
|
||||
console.log('收到的值', e);
|
||||
|
||||
if(e.sort){
|
||||
this.form.sort = e.sort+''
|
||||
}
|
||||
this.pageType = e.type
|
||||
this.form.classId = e.classId
|
||||
this.form.type = e.type
|
||||
@@ -269,7 +273,21 @@
|
||||
this.form.img = _list.join(',')
|
||||
}else{
|
||||
this.form.img = ''
|
||||
}
|
||||
}
|
||||
var newSort = undefined
|
||||
console.log('this.sort',this.form.sort);
|
||||
if(this.form.sort != undefined) {
|
||||
console.log('this.sort',this.form.sort);
|
||||
var oldsort = this.form.sort.split('')
|
||||
if(oldsort[oldsort.length-1] == '9'){
|
||||
oldsort.push('0')
|
||||
}else{
|
||||
console.log('符合');
|
||||
oldsort[oldsort.length-1] = ( parseInt(oldsort[oldsort.length-1]) + 1) + ''
|
||||
}
|
||||
newSort = oldsort.join('')
|
||||
}
|
||||
// console.log('this.sort',newSort);
|
||||
var _url = ""
|
||||
this.form.id ? _url = "common/class/editClassTask" : _url = "common/class/addClassTask"
|
||||
$http.request({
|
||||
@@ -282,7 +300,8 @@
|
||||
"display": this.form.display, //0不展示1展示
|
||||
"title": this.form.title,
|
||||
"content": this.form.content,
|
||||
"img": this.form.img
|
||||
"img": this.form.img,
|
||||
"sort": newSort
|
||||
},
|
||||
header: { //默认 无 说明:请求头
|
||||
'Content-Type': 'application/json'
|
||||
|
||||
Reference in New Issue
Block a user