Parcourir la source

入职奖励页面图片地址更换

ZhangWenQiang il y a 6 ans
Parent
commit
8ad7d761aa
2 fichiers modifiés avec 18 ajouts et 17 suppressions
  1. 3 2
      pages/reward/index.js
  2. 15 15
      pages/reward/index.wxml

+ 3 - 2
pages/reward/index.js

@@ -14,6 +14,7 @@ Page({
    * 页面的初始数据
    */
   data: {
+    imgServerUrl: imgServerUrl,
     list: [],
     pageNo: 1, //当前分页
     isScroll: true, //是否可以滚动
@@ -132,7 +133,7 @@ Page({
       that.start();
     } else {
       wx.getSetting({
-        success: function (res) {
+        success: function(res) {
           if (!res.authSetting['scope.userInfo'] || !res.authSetting['scope.userLocation']) {
             wx.hideLoading();
             wx.showModal({
@@ -140,7 +141,7 @@ Page({
               content: '当前服务需要获取您的位置信息,请确认授权',
               confirmText: '去授权',
               cancelText: '暂不授权',
-              success: function (res) {
+              success: function(res) {
                 if (res.confirm) {
                   wx.openSetting();
                 } else if (res.cancel) {

+ 15 - 15
pages/reward/index.wxml

@@ -4,7 +4,7 @@
 <view class='head'>
   <view class='map'>
     <view class='location'>
-      <image src='../../images/happyjob/location.png'></image>
+      <image src='{{imgServerUrl}}/images/happyjob/location.png'></image>
     </view>
     <text class='cityname'>{{cityName}}</text>
   </view>
@@ -13,18 +13,18 @@
     <view class='arrow'>
       <block wx:if="{{selectId == 0}}">
         <block wx:if="{{totalSalary == 2}}">
-          <image src='../../images/happyjob/selected.png'></image>
+          <image src='{{imgServerUrl}}/images/happyjob/selected.png'></image>
         </block>
         <block wx:else>
-          <image src='../../images/happyjob/selected1.png'></image>
+          <image src='{{imgServerUrl}}/images/happyjob/selected1.png'></image>
         </block>
       </block>
       <block wx:else>
         <block wx:if="{{totalSalary == 2}}">
-          <image src='../../images/happyjob/no_selected.png'></image>
+          <image src='{{imgServerUrl}}/images/happyjob/no_selected.png'></image>
         </block>
         <block wx:else>
-          <image src='../../images/happyjob/no_selected1.png'></image>
+          <image src='{{imgServerUrl}}/images/happyjob/no_selected1.png'></image>
         </block>
       </block>
     </view>
@@ -34,18 +34,18 @@
     <view class='arrow'>
       <block wx:if="{{selectId == 1}}">
         <block wx:if="{{sort == 2}}">
-          <image src='../../images/happyjob/selected.png'></image>
+          <image src='{{imgServerUrl}}/images/happyjob/selected.png'></image>
         </block>
         <block wx:else>
-          <image src='../../images/happyjob/selected1.png'></image>
+          <image src='{{imgServerUrl}}/images/happyjob/selected1.png'></image>
         </block>
       </block>
       <block wx:else>
         <block wx:if="{{sort == 2}}">
-          <image src='../../images/happyjob/no_selected.png'></image>
+          <image src='{{imgServerUrl}}/images/happyjob/no_selected.png'></image>
         </block>
         <block wx:else>
-          <image src='../../images/happyjob/no_selected1.png'></image>
+          <image src='{{imgServerUrl}}/images/happyjob/no_selected1.png'></image>
         </block>
       </block>
     </view>
@@ -62,14 +62,14 @@
             {{item.positionName}}
           </view>
           <view class='salary'>
-            <image src='../../images/happyjob/dollor.png'></image>
+            <image src='{{imgServerUrl}}/images/happyjob/dollor.png'></image>
             {{item.totalSalary?item.totalSalary:item.basicSalary}}
           </view>
         </view>
         <view class='four'>
           <view class='commpany'>{{item.hpCompany.companyName}}</view>
           <view class='area'>
-            <image src='../../images/happyjob/address.png'></image>
+            <image src='{{imgServerUrl}}/images/happyjob/address.png'></image>
             <text class='area-name'>{{item.hpPositionAddressList[0].adname}}</text>
           </view>
         </view>
@@ -106,7 +106,7 @@
         <view class='three'>
           <block wx:if="{{item.positionCategory == 3}}">
             <view class='fan' wx:if="{{item.reward}}">
-              <image src='../../images/happyjob/reward.png'></image>
+              <image src='{{imgServerUrl}}/images/happyjob/reward.png'></image>
               <text>入职最高奖励 {{item.reward}}+{{item.platformAllowance}} 元</text>
             </view>
             <view wx:else>
@@ -114,14 +114,14 @@
           </block>
           <block wx:else>
             <view class='fan' wx:if="{{item.reward}}">
-              <image src='../../images/happyjob/reward.png'></image>
+              <image src='{{imgServerUrl}}/images/happyjob/reward.png'></image>
               <text>入职最高奖励 {{item.reward}} 元</text>
             </view>
             <view wx:else>
             </view>
           </block>
           <view class='time'>
-            <image src='../../images/happyjob/time.png'></image>
+            <image src='{{imgServerUrl}}/images/happyjob/time.png'></image>
             <text>{{globalTools.subStr(item.updateDate)}}</text>
           </view>
         </view>
@@ -132,7 +132,7 @@
 </block>
 <block wx:else>
   <view class='no_data'>
-    <image src="../../images/happyjob/no_data.png" class="white" />
+    <image src="{{imgServerUrl}}/images/happyjob/no_data.png" class="white" />
     <view class='no_text'>暂时还没有全职工作 看看其他的吧</view>
   </view>
 </block>