Jelajahi Sumber

认证通页面接口修改

喻文俊 3 tahun lalu
induk
melakukan
7910fdd255

+ 0 - 2
src/main/resources/static/js/activity/attestation.js

@@ -15,9 +15,7 @@ new Vue({
         ],
         // 认证通快捷入口
         firstEntryList: [
-             // { logo: '/img/activity/attestation/1.jpg', appId: 'wxdef0c3c369ff7013', name: '品辉机构认证', title: '品辉机构认证' },
             { logo: '/img/activity/attestation/shuishu.jpg', appId: 'wxdef0c3c369ff7013', name: '水素水设备认证', title: '水素水设备认证', type: 'device' },
-            // { logo: '/img/activity/attestation/3.jpg', appId: '', name: 'LDM机构认证', title: 'LDM机构认证' },
             { logo: '/img/activity/attestation/3.jpg', appId: 'ldm', name: 'LDM设备认证', title: 'LDM正品认证' , type: 'other'},
         ]
     },

+ 14 - 2
src/main/resources/static/js/product/alliance-page.js

@@ -100,7 +100,19 @@ var zplm = new Vue({
         // 获取授权信息
         fetchProductAuthInfo: function fetchProductAuthInfo() {
             var that = this;
-            ProductApi.GetAuthProductDeatil({ productId: that.productId }, function (res) {
+            var data = {productId:that.productId}
+            $.ajax({
+                url: 'https://zplma-b.caimei365.com/wx/auth/product/details',
+                data: data,
+                xhrFields: {//此处为跨域后台保持session一致,切勿删除!!!
+                    withCredentials: true
+                },
+                type: 'GET',
+                dataType: "json",
+                async: false,
+                // contentType: contentType,
+                contentType: 'application/json;charset=UTF-8',
+            }).then(res => {
                 // 获取授权信息失败
                 if (res.code) {
                     that.isRequest = false;
@@ -109,7 +121,7 @@ var zplm = new Vue({
                 // 获取授权信息成功
                 that.productAuthInfo = res.data;
                 that.isRequest = false;
-            });
+            })
             setTimeout(function(){
                 if(that.isRequest){
                     that.isRequest = false;

+ 29 - 6
src/main/resources/static/js/product/qualityauthorize.js

@@ -40,7 +40,20 @@ var qualityAuthorize = new Vue({
         //获取商品参数对象
         initParams:function(){
            var _that = this;
-           ProductApi.GetAuthProductDeatil({productId:_that.productId},function(res){
+            var NODE_ENV_BASE_URL = $("#coreServer").val();
+            var data = {productId:_that.productId}
+            $.ajax({
+                url: NODE_ENV_BASE_URL + '/wx/auth/product/details',
+                data: data,
+                xhrFields: {//此处为跨域后台保持session一致,切勿删除!!!
+                    withCredentials: true
+                },
+                type: 'GET',
+                dataType: "json",
+                async: false,
+                // contentType: contentType,
+                contentType: 'application/json;charset=UTF-8',
+            }).then(res =>{
                 if(res.code === 0){
                     _that.parameters = res.data;
                     console.log(_that.parameters)
@@ -49,11 +62,21 @@ var qualityAuthorize = new Vue({
                     _that.message = res.msg;
                     _that.isLoading = true;
                 }
-                // else{
-                //     //如果该产品不存在,跳转到404页面
-                //     window.location.href = '/404.html'
-                // }
-           });
+            })
+           // ProductApi.GetAuthProductDeatil({productId:_that.productId},function(res){
+           //      if(res.code === 0){
+           //          _that.parameters = res.data;
+           //          console.log(_that.parameters)
+           //          _that.isLoading = true;
+           //      }else{
+           //          _that.message = res.msg;
+           //          _that.isLoading = true;
+           //      }
+           //      // else{
+           //      //     //如果该产品不存在,跳转到404页面
+           //      //     window.location.href = '/404.html'
+           //      // }
+           // });
         },
         // 代理声明弹出框
         openStatementDialog:function(flag){

+ 0 - 1
src/main/resources/templates/product/alliance-page.html

@@ -10,7 +10,6 @@
 		<link th:href="@{/css/product/alliance-page.css(v=${version})}" rel="stylesheet" type="text/css">
 	</head>
 	<body>
-	    <input type="hidden" th:value="${coreServer}" id="coreServer">
 		<div id="zplm" v-cloak v-loading="isRequest">
 			<template v-if="!isRequest && !errorMessage">
 				<!-- 顶部 -->