myQuestion.vue
4.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
<template>
<view class="myQuestion">
<view class="myQuestion-1">
<view @click="switchItem(MYQUESTIONTYPE.ANSWERED)" :class="{'myQuestion-i': true, 'myQuestion-is': type === MYQUESTIONTYPE.ANSWERED}">已解答</view>
<view @click="switchItem(MYQUESTIONTYPE.UNANSWERED)" :class="{'myQuestion-i': true, 'myQuestion-is': type === MYQUESTIONTYPE.UNANSWERED}">未解答</view>
</view>
<view class="myQuestion-2">
<view class="myQuestion-2-i" @click="toAnswerDetails">
<view class="myQuestion-2-i-1">
<view class="myQuestion-2-i-1-l">
<image class="myQuestion-2-i-1-l-i" src="@/static/images/tx.png" mode="widthFix"></image>
</view>
<view class="myQuestion-2-i-1-r">
<view class="myQuestion-2-i-1-r-1">李晋心</view>
<view class="myQuestion-2-i-1-r-2">2023-12-10发布</view>
</view>
</view>
<view class="myQuestion-2-i-2">
老师你好请问工商管理专业的应届生可以报考工商管理
内的二级专业吗?比如说会计学,旅游管理?
</view>
<view class="myQuestion-2-i-4">
<u--image
v-for="(item, index) in []"
:key="index"
radius="15rpx"
height="145rpx"
width="145rpx"
@click.native="seeImg(index)"
:src="item"></u--image>
</view>
<view class="myQuestion-2-i-3">
<view class="myQuestion-2-i-3-l">
<view class="myQuestion-2-i-3-l-1" v-if="false">已解答</view>
<view class="myQuestion-2-i-3-l-1 myQuestion-2-i-3-l-1s" v-else>已解答</view>
<view class="myQuestion-2-i-3-l-t">程菲</view>
</view>
<view class="myQuestion-2-i-3-r">
2023-12-11
</view>
</view>
</view>
</view>
</view>
</template>
<script>
import { MYQUESTIONTYPE } from "@/emit/index.js"
export default {
components: {
},
data() {
return {
MYQUESTIONTYPE,
type: MYQUESTIONTYPE.ANSWERED,
}
},
methods: {
toAnswerDetails() {
uni.navigateTo({
url: '/pagesStu/answerDetails/answerDetails'
})
},
switchItem(type) {
this.type = type
},
seeImg(index) {
uni.previewImage({
current: index, // 当前显示图片的链接,不填则默认为 urls 的第一张图片
urls: [] // 需要预览的图片链接列表
})
}
}
}
</script>
<style lang="scss" scoped>
.myQuestion{
.myQuestion-1{
position: absolute;
top: 0;
border-top:1rpx solid #f3f4f6;
display: flex;
background: #fff;
justify-content: space-around;
width: 100%;
.myQuestion-i{
font-size: 28rpx;
color: #323232;
height: 88rpx;
display: flex;
align-items: center;
justify-content: center;
}
.myQuestion-is{
color: #2D81FF;
position: relative;
&:before{
content: '';
position: absolute;
bottom: 0;
left: 50%;
background-image: url(@/static/imagesV2/icon23.png);
background-size: 100% 100%;
transform: translateX(-50%);
height: 24rpx;
width: 24rpx;
}
}
}
.myQuestion-2{
padding: 20rpx 25rpx;
width: 100%;
padding-top: calc(88rpx + 20rpx);
.myQuestion-2-i{
padding: 30rpx;
background-color: #FFFFFF;
box-sizing: border-box;
border-radius: 20rpx;
.myQuestion-2-i-1{
display: flex;
align-items: center;
.myQuestion-2-i-1-l{
.myQuestion-2-i-1-l-i{
height: 60rpx;
width: 60rpx;
border-radius: 100%;
}
}
.myQuestion-2-i-1-r{
margin-left: 30rpx;
.myQuestion-2-i-1-r-1{
font-size: 26rpx;
color: #323232;
font-weight: bold;
}
.myQuestion-2-i-1-r-2{
font-size: 24rpx;
color: #979797;
margin-top: 5rpx;
}
}
}
.myQuestion-2-i-2{
line-height: 39rpx;
color: #323232;
font-size: 26rpx;
margin: 30rpx 0;
}
}
}
.myQuestion-2-i-3{
padding-top: 20rpx;
border-top: 1rpx solid #F3F3F7;
display: flex;
justify-content: space-between;
align-items: center;
.myQuestion-2-i-3-l{
display: flex;
.myQuestion-2-i-3-l-1{
border-radius: 20rpx 20rpx 0px 20rpx;
height: 40rpx;
line-height: 40rpx;
color: #FFFFFF;
background: linear-gradient(0deg, #0AC49C 0%, #34D5AA 100%);
font-size: 22rpx;
padding: 0 11rpx;
}
.myQuestion-2-i-3-l-1s{
background: linear-gradient(0deg, #BEBEBE 0%, #AAAAAA 100%);
}
.myQuestion-2-i-3-l-t{
font-size: 26rpx;
color: #323232;
margin-left: 15rpx;
font-weight: bold;
}
}
.myQuestion-2-i-3-r{
font-size: 24rpx;
color: #979797;
}
}
.myQuestion-2-i-4{
display: grid;
grid-template-columns: repeat(4, 1fr);
grid-row-gap: 20rpx;
grid-column-gap: 20rpx;
margin-top: 30rpx;
}
}
</style>