| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960 |
- vm = new Vue({
- el: "#app",
- data: {
- baseUrl: 'http://lanbo.frp.liuniu946.com',
- company: '',
- bottom: '',
- statement: '',
- servicesList:[]
- }
- ,
- created() {
- let obj = this
- var datas = {
- limit:10000
- };
- var ajaxUrl = 'http://lanbo.frp.liuniu946.com/apis/product';
- AJAX('get', ajaxUrl, datas, function(res) {
- vm.statement = res.data.list.filter(item => item.category_ids == "65")
- console.log(vm.statement)
- })
- var ajaxUrl = 'http://lanbo.frp.liuniu946.com/apis/product';
- AJAX('get', ajaxUrl, datas, function(res) {
- vm.bottom = res.data.list.filter(item => item.category_ids == "64")
- console.log(vm.bottom)
- })
-
- var ajaxUrl = 'http://lanbo.frp.liuniu946.com/apis/product';
- AJAX('get', ajaxUrl, datas, function(res) {
- res.data.list.forEach(item => {
- if(item.category_ids == "45"){
- item.coverimage=obj.baseUrl+item.coverimage
- vm.servicesList.push(item)
- console.log( vm.servicesList)
- }
-
- })
-
-
- console.log(vm.servicesList)
- })
- },
- // var ajaxUrl = 'http://lanbo.frp.liuniu946.com/apis/about/10';
- // AJAX('get',ajaxUrl,datas,function(res){
- // console.log(res)
- // vm.company = res.data.content;
- // })
- methods:{
- dianji(item) {
- // debugger
- console.log(item);
-
- //存储这个localStronge,存储的是点击的这个内容的id,在需要展示的详情页去接收
- localStorage.setItem('id',item);
- }
-
- }
- });
|