Bläddra i källkod

猎聘职位赏金展示调整

Xiao_123 6 månader sedan
förälder
incheckning
427adc3d1e

+ 1 - 1
components/PositionList/index.vue

@@ -40,7 +40,7 @@
             <uni-tag
               class="ss-m-l-10"
               v-if="item?.job?.hirePrice && item?.job?.hirePrice > 0" 
-              :text="`赏金:${commissionCalculation(item.job.hirePrice, 1)}元`"
+              :text="`赏金:${commissionCalculation(item.job.hirePrice / 100, 1)}元`"
               inverted="false"
               size="default"
               custom-style="background-color: #e2f0ef; color:#00897B; border-color:#e2f0ef;"

+ 2 - 2
pages/index/position.vue

@@ -164,7 +164,8 @@ const handleGrid = async (e) => {
 const positionListData = ref([])
 const query = reactive({ 
   pageSize: 20, 
-  pageNo: 1, 
+  pageNo: 1,
+  hire: false,
   content: '',
   areaIds: [],
   industryIds: [],
@@ -172,7 +173,6 @@ const query = reactive({
   payScope: [],
   expType: []
 })
-//
 const getData = async () => {
   try {
     const res = await getJobAdvertisedSearch(query)

+ 1 - 1
pagesB/positionDetail/index.vue

@@ -40,7 +40,7 @@
           <!-- 赏金 -->
           <view v-if="info.hire" class="topLine mt-5" style="display: flex; align-items: center;">
             <view class="iconfont icon-a-1_zhaopin" style="color: #e03506; font-size: 30px;"></view>
-            <view class="hirePrice">{{ `赏金:${commissionCalculation(info.hirePrice, 1)}元` }}</view>
+            <view class="hirePrice">{{ `赏金:${commissionCalculation(info.hirePrice / 100, 1)}元` }}</view>
           </view>
           <!-- 企业信息 -->
           <view class="topLine mt-5 d-flex" @click="handleToEnterprise">

+ 1 - 1
utils/position.js

@@ -94,7 +94,7 @@ export const rechargeRatio = () => { return 10 }
 export const commissionCalculation = (count, type) => {
   if (!data || !Object.keys(data).length) return
   // 所占的百分比
-  const ratio = parseFloat(data[list[type]]) / 100 // 所占的百分比-> 50%变为0.5 (不能改)
+  const ratio = parseFloat(data[list[type]]) / 10 // 所占的百分比-> 50%变为0.5 (不能改)
   // 积分变成金额
   const value = count * ratio / rechargeRatio()
   return value % 1 === 0 ? Math.floor(value) : value.toFixed(2)