|
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687 |
- // pages/component/service/index.js
- const app = getApp()
- Component({
- /**
- * 组件的属性列表
- */
- properties: {
-
- },
-
- /**
- * 组件的初始数据
- */
- data: {
- imgUrl: app.globalData.urlStatic,//图片路径
- maskState: false,//遮罩显示状态
- placing: false,
- buyState: false,
- nowPage: '0',
- yuyueShow: false,
- },
- attached:function(){
- setTimeout(()=>{
- this.setData({
- nowPage:app.globalData.nowPage,
- buyState: app.globalData.getBuyState?app.globalData.getBuyState.success:false
- })
- },50)
- },
- /**
- * 组件的方法列表
- */
- methods: {
- maskShow:function(e){//打开遮罩
- this.setData({
- maskState: true,
- })
- },
- closeService: function (e) {//关闭遮罩
- this.setData({
- maskState: false,
- })
- },
- newCarConsultation:function(e){//新车咨询
- console.log("小程序跳转");
- wx.navigateToMiniProgram({
- appId:'wx1d585c8c2fffe589',
- path:"/pages/take/takeHome/takeHome",
- success(res) {
- // 打开成功
- },
- complete(res){
- console.log(res);
- }
- })
- },
- placingControl: function () {
- if (app.globalData.getBuyState){
- if (app.globalData.getBuyState.success != this.data.buyState) {
- this.setData({
- buyState: app.globalData.getBuyState.success
- })
- }
- }
- this.setData({
- placing: !this.data.placing
- })
- },
- openYuyue: function () {//预约
- this.setData({
- yuyueShow: !this.data.yuyueShow
- })
- },
- lookOrder:function(){//跳转到智趣启辰小程序的订单页面
- wx.navigateToMiniProgram({
- appId:'wx1d585c8c2fffe589',
- path:"/activity_module/pages/carorder_info/carorder_info",
- success(res) {
- // 打开成功
- },
- complete(res){
- console.log(res);
- }
- })
- }
- }
- })
|