Commit 83335715 by 陈超

T

parent 94e6634b
...@@ -359,16 +359,17 @@ ...@@ -359,16 +359,17 @@
url: "{:U('exams/Index/paper')}" + "&api=1&search=" + that.keyword, url: "{:U('exams/Index/paper')}" + "&api=1&search=" + that.keyword,
dataType: "json", dataType: "json",
success: function(res) { success: function(res) {
let array = res.data.length > 0 ? res.data : [] if(res.status == 1) {
console.log(res) let result = res.data
that.options[1].items = array.map( r => { let array = result.data.length > 0 ? result.data : []
return { that.options[1].items = array.map( r => {
id: r.exams_paper_id, return {
title: r.exams_paper_title, id: r.exams_paper_id,
price: r.price title: r.exams_paper_title,
} price: r.price
}) }
console.log(that.options[1].items) })
}
} }
}) })
}, },
......
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