鸭先知测试

This commit is contained in:
DESKTOP-RQ919RC\Pc 2025-04-07 14:31:05 +08:00
parent e09b6bea1d
commit 7bbddc2d07
8 changed files with 399 additions and 56 deletions

View File

@ -0,0 +1,33 @@
// pagesSquare/components/survey-box/survey-box.js
Component({
/**
* 组件的属性列表
*/
properties: {
duckProphet: Object,
newest: {
type: String,
observer(res) {
if (!res) return
this.setData({
newest: res.toLocaleUpperCase()
})
}
}
},
/**
* 组件的初始数据
*/
data: {
},
/**
* 组件的方法列表
*/
methods: {
}
})

View File

@ -0,0 +1,4 @@
{
"component": true,
"usingComponents": {}
}

View File

@ -0,0 +1,131 @@
/* pagesSquare/components/survey-box/survey-box.wxss */
.flexflex {
display: flex;
}
.flexcenter {
display: flex;
justify-content: center;
align-items: center;
}
.flexjcenter {
display: flex;
justify-content: center;
}
.flexacenter {
display: flex;
align-items: center;
}
.flex1 {
flex: 1;
}
.block {
background-color: rgba(255, 255, 255, 1);
border: 1rpx solid rgba(235, 235, 235, 1);
border-radius: 18rpx;
margin-bottom: 60rpx;
margin-left: 36rpx;
}
.survey {
padding: 18rpx;
.head {
.head-icon {
width: 117rpx;
height: 145.5rpx;
margin-top: 2px;
margin-right: 12rpx;
}
.head-title {
width: 300rpx;
height: 66rpx;
margin-top: -12rpx;
}
}
.survey-box {
width: 531rpx;
background-color: rgba(242, 242, 242, 1);
border-radius: 12rpx;
padding: 19.5rpx 30rpx;
margin-bottom: 15rpx;
margin-top: -6rpx;
position: relative;
.title {
text-align: center;
color: #333333;
font-size: 21rpx;
margin: 0 auto 21rpx;
height: 34.5rpx;
.season {
font-family: 'Arial', 'Arial Black', sans-serif;
font-weight: 900;
font-size: 24rpx;
color: #F25D11;
}
}
.across {
justify-content: space-between;
// margin-bottom: 21rpx;
&:not(:last-of-type) {
margin-bottom: 21rpx;
}
.item {
height: 90rpx;
background-color: rgba(253, 223, 109, 1);
border-radius: 7.5rpx;
flex-direction: column;
&:not(:last-of-type) {
margin-right: 21rpx;
}
.date {
font-family: 'Arial', 'Arial-Black', 'Arial Black', sans-serif;
font-weight: 900;
font-style: normal;
font-size: 22.5rpx;
text-align: center;
}
line-height: 39rpx;
.text {
font-family: 'PingFangSC-Regular', 'PingFang SC', sans-serif;
font-weight: 400;
font-style: normal;
font-size: 21rpx;
color: #333333;
text-align: center;
}
}
}
}
.remark {
font-family: 'PingFangSC-Regular', 'PingFang SC', sans-serif;
font-weight: 400;
font-size: 19.5rpx;
color: #555555;
line-height: 28.5rpx;
.remark-ps {
font-family: 'Arial-Black', 'Arial Black', sans-serif;
font-weight: 900;
color: #000000;
font-size: 21rpx;
}
}
}

View File

@ -0,0 +1,42 @@
<!--pagesSquare/components/survey-box/survey-box.wxml-->
<view class="block survey">
<view class="head flexcenter">
<image class="head-icon" src="https://app.gter.net/image/miniApp/offer/duck-ok-icon.png" mode="widthFix"></image>
<image class="head-title" src="https://app.gter.net/image/miniApp/offer/survey-title.png" mode="widthFix"></image>
</view>
<view class="survey-box">
<view class="title flexcenter">
本项目
<view class="season">{{ newest }}</view>
通知下达观察
</view>
<view class="across flexacenter">
<view class="item flex1 flexcenter">
<view class="date">{{ duckProphet.earliestdate || '-' }}</view>
<view class="text">最早通知</view>
</view>
<view class="item flex1 flexcenter">
<view class="date">{{ duckProphet.latestdate || '-' }}</view>
<view class="text">最近通知</view>
</view>
</view>
<view class="across flexacenter">
<view class="item flex1 flexcenter">
<view class="date">{{ duckProphet.studentcount || '-' }}</view>
<view class="text">人数</view>
</view>
<view class="item flex1 flexcenter">
<view class="date">{{ duckProphet.offercount || '-' }}</view>
<view class="text">Offer</view>
</view>
<view class="item flex1 flexcenter">
<view class="date">{{ duckProphet.rejectcount || '-' }}</view>
<view class="text">拒信</view>
</view>
</view>
</view>
<view class="remark">
<text class="remark-ps">P.S. </text>
<text>以上数据统计来源于寄托offer榜、寄托微信群聊、新浪微博、小红书、豆瓣等网络搜索。</text>
</view>
</view>

View File

@ -0,0 +1,107 @@
/* pagesSquare/components/survey-box/survey-box.wxss */
.flexflex {
display: flex;
}
.flexcenter {
display: flex;
justify-content: center;
align-items: center;
}
.flexjcenter {
display: flex;
justify-content: center;
}
.flexacenter {
display: flex;
align-items: center;
}
.flex1 {
flex: 1;
}
.block {
background-color: #ffffff;
border: 1rpx solid #ebebeb;
border-radius: 18rpx;
margin-bottom: 60rpx;
margin-left: 36rpx;
}
.survey {
padding: 18rpx;
}
.survey .head .head-icon {
width: 117rpx;
height: 145.5rpx;
margin-top: 2px;
margin-right: 12rpx;
}
.survey .head .head-title {
width: 300rpx;
height: 66rpx;
margin-top: -12rpx;
}
.survey .survey-box {
width: 531rpx;
background-color: #f2f2f2;
border-radius: 12rpx;
padding: 19.5rpx 30rpx;
margin-bottom: 15rpx;
margin-top: -6rpx;
position: relative;
}
.survey .survey-box .title {
text-align: center;
color: #333333;
font-size: 21rpx;
margin: 0 auto 21rpx;
height: 34.5rpx;
}
.survey .survey-box .title .season {
font-family: 'Arial', 'Arial Black', sans-serif;
font-weight: 900;
font-size: 24rpx;
color: #F25D11;
}
.survey .survey-box .across {
justify-content: space-between;
}
.survey .survey-box .across:not(:last-of-type) {
margin-bottom: 21rpx;
}
.survey .survey-box .across .item {
height: 90rpx;
background-color: #fddf6d;
border-radius: 7.5rpx;
flex-direction: column;
line-height: 39rpx;
}
.survey .survey-box .across .item:not(:last-of-type) {
margin-right: 21rpx;
}
.survey .survey-box .across .item .date {
font-family: 'Arial', 'Arial-Black', 'Arial Black', sans-serif;
font-weight: 900;
font-style: normal;
font-size: 22.5rpx;
text-align: center;
}
.survey .survey-box .across .item .text {
font-family: 'PingFangSC-Regular', 'PingFang SC', sans-serif;
font-weight: 400;
font-style: normal;
font-size: 21rpx;
color: #333333;
text-align: center;
}
.survey .remark {
font-family: 'PingFangSC-Regular', 'PingFang SC', sans-serif;
font-weight: 400;
font-size: 19.5rpx;
color: #555555;
line-height: 28.5rpx;
}
.survey .remark .remark-ps {
font-family: 'Arial-Black', 'Arial Black', sans-serif;
font-weight: 900;
color: #000000;
font-size: 21rpx;
}

View File

@ -127,6 +127,7 @@ Page({
applyListState: false, // 申请信息选择列表状态 applyListState: false, // 申请信息选择列表状态
newest: "", newest: "",
duckProphet: {}, // 鸭先知
}, },
/** /**
@ -286,10 +287,29 @@ Page({
this.handleAmissionsData(admissionsId) this.handleAmissionsData(admissionsId)
this.handleRequirementData(admissionsId) this.handleRequirementData(admissionsId)
this.getRecommendData() this.getRecommendData()
this.getDuckProphet()
}) })
}).finally(() => wx.hideLoading()) }).finally(() => wx.hideLoading())
}, },
// 获取 鸭先知 数据
getDuckProphet() {
util.wxpost("https://api.gter.net/v1/program/duckProphet", {
uniqid: this.data.uniqid,
}).then(res => {
if (res.code != 200) {
common.toast(res.message)
return
}
const data = res.data
this.setData({
duckProphet: data,
})
})
},
// 处理 能力要求信息 // 处理 能力要求信息
handleRequirementData(id) { handleRequirementData(id) {
const admission_requirements = this.data.admission_requirements || [] const admission_requirements = this.data.admission_requirements || []
@ -781,7 +801,7 @@ Page({
this.requestOfferData(limit).then(data => { this.requestOfferData(limit).then(data => {
const list = data.list || [] const list = data.list || []
let side = this.data.side let side = this.data.side
if (list.length == 0) delete side.consult // if (list.length == 0) delete side.consult
let sideNum = this.data.sideNum let sideNum = this.data.sideNum
sideNum['consult'] = data.count sideNum['consult'] = data.count

View File

@ -5,6 +5,7 @@
"go-login": "/component/goLogin/goLogin", "go-login": "/component/goLogin/goLogin",
"perfect-information": "/component/perfectInformation/perfectInformation", "perfect-information": "/component/perfectInformation/perfectInformation",
"index-sidebar": "/component/indexSidebar/indexSidebar", "index-sidebar": "/component/indexSidebar/indexSidebar",
"document-box": "/component/document-box/document-box" "document-box": "/component/document-box/document-box",
"survey-box": "/component/survey-box/survey-box"
} }
} }

View File

@ -496,8 +496,12 @@
</view> </view>
</view> </view>
<view wx:if="{{ offerShowList.length != 0 }}" class="side-item" data-type="consult"> <view class="side-item" data-type="consult">
<view class="side-head flexcenter">录取参考</view> <view class="side-head flexcenter">录取参考</view>
<template is="item-header" data="{{ text: 'Offer观察' }}"></template>
<survey-box duckProphet="{{ duckProphet }}" newest="{{ newest }}"></survey-box>
<block wx:if="{{ offerShowList.length != 0 }}">
<template is="item-header" data="{{ text: '寄托录取参考', type: 'consult' }}"></template> <template is="item-header" data="{{ text: '寄托录取参考', type: 'consult' }}"></template>
<view class="consult-list"> <view class="consult-list">
<navigator class="consult-item" wx:for="{{ offerShowList }}" wx:key="index" target="miniProgram" app-id="wxa9296b07391c2bc7" path="/pages/victoryDetails/victoryDetails?id={{ item.id || item.uniqid }}" hover-class="none"> <navigator class="consult-item" wx:for="{{ offerShowList }}" wx:key="index" target="miniProgram" app-id="wxa9296b07391c2bc7" path="/pages/victoryDetails/victoryDetails?id={{ item.id || item.uniqid }}" hover-class="none">
@ -555,6 +559,7 @@
加载更多 加载更多
<image class="icon" src="https://app.gter.net/image/miniApp/offer/arrow-circle.png" mode="widthFix"></image> <image class="icon" src="https://app.gter.net/image/miniApp/offer/arrow-circle.png" mode="widthFix"></image>
</view> </view>
</block>
</view> </view>
<view class="side-item" data-type="issue" wx:if="{{ detailsInfo.faq && detailsInfo.faq.length != 0 }}"> <view class="side-item" data-type="issue" wx:if="{{ detailsInfo.faq && detailsInfo.faq.length != 0 }}">