Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
basic-uniapp-v3
概览
概览
详情
活动
周期分析
版本库
存储库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
问题
0
议题
0
列表
看板
标记
里程碑
合并请求
1
合并请求
1
CI / CD
CI / CD
流水线
作业
日程表
图表
维基
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
Basic
basic-uniapp-v3
Commits
227bef02
提交
227bef02
authored
12月 22, 2025
作者:
王定
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
feat: 完成农资详情页面的制作
上级
14acfbfc
显示空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
85 行增加
和
5 行删除
+85
-5
detail.vue
src/pages/kexinnongzi/detail.vue
+85
-5
product.png
src/static/images/test/product.png
+0
-0
没有找到文件。
src/pages/kexinnongzi/detail.vue
浏览文件 @
227bef02
...
...
@@ -4,10 +4,20 @@
import
{
reactive
,
ref
}
from
'vue'
import
*
as
NongzhiAPI
from
'@/api/model/nongzhi'
const
bgColorData
=
[
"#EEFAEB"
,
"#EFF1FF"
,
"#FFF3F1"
,
"#E8F7F7"
,
"#FFF3E7"
,
"#FAF8EA"
];
let
testDataList
=
[
'营业执照'
,
'食品经营许可证
类选择器允许你根据元素在'
,
'有机产品认证书'
,
'无公害农产品证书'
,
'有机产品认证书'
,
'营业执照
'
]
let
testDataList
=
[
'营业执照'
,
'食品经营许可证
'
,
'有机产品认证书'
,
'无公害农产品证书'
,
'有机产品认证书'
,
'营业执照'
,
'营业执照2'
,
'营业执照3
'
]
const
pageData
=
reactive
({
})
function
getBgColor
(
index
:
any
){
if
(
index
<
6
){
return
bgColorData
[
index
];
}
else
{
return
bgColorData
[
Math
.
floor
(
Math
.
random
()
*
5
)];
}
}
function
handlePublish
()
{
Navigate
.
to
(
'/pages/linghuoyonggong/publishEmployment'
)
}
</
script
>
<
template
>
<view
class=
"w-full h-95vh bg-#E6F5E8 detail_page"
>
...
...
@@ -20,14 +30,30 @@
<view
class=
"module_title"
>
资质证书
</view>
<view
class=
"module_separate"
></view>
<view
class=
"module_qualification"
>
<view
class=
"qualification_item
qualification_bg
"
v-for=
"(item,index) in testDataList"
:key=
"index"
>
<view
class=
"qualification_item
"
:style=
"`background:$
{getBgColor(index)}`
" v-for="(item,index) in testDataList" :key="index">
<image
class=
"enterprise_logo"
mode=
"heightFix"
src=
"/static/images/test/test_business.png"
/>
<view
class=
"qualification_name ellipsis"
>
{{
item
}}
</view>
</view>
</view>
</view>
<view
class=
"module_width footer_content"
>
主营产品
</view>
<view
class=
"module_width footer_content"
>
<view
class=
"module_title"
>
主营产品
</view>
<view
class=
"module_separate"
></view>
<view
class=
"module_business"
>
<view
class=
"business_item"
v-for=
"(item,index) in 5"
:key=
"index"
>
<image
class=
"business_img"
mode=
"heightFix"
src=
"/static/images/test/product.png"
/>
<view
class=
"qualification_name ellipsis"
>
有机砂糖橘
</view>
<view
class=
"qualification_price ellipsis"
>
¥3.2
<text
class=
"qualification_text"
>
/斤
</text></view>
</view>
</view>
</view>
</view>
<fui-fab
position=
"right"
distance=
"10"
bottom=
"240"
width=
"120"
@
click=
"handlePublish"
>
<view
class=
"text-white text-center"
>
<view
class=
"fab-icon"
/>
<view
style=
"font-size: 24rpx"
>
发布产品
</view>
</view>
</fui-fab>
</
template
>
<
style
lang=
"less"
scoped
>
...
...
@@ -37,6 +63,7 @@
justify-content
:
center
;
align-items
:
flex-start
;
align-content
:
flex-start
;
padding-bottom
:
40
rpx
;
.module_width{
width
:
690
rpx
;
margin-top
:
24
rpx
;
...
...
@@ -101,7 +128,7 @@
background
:
linear-gradient
(
233.81deg
,
#5CB56E
0%
,
#64D63E
100%
);
}
.module_qualification
{
margin-top
:
32
rpx
;
margin-top
:
6
rpx
;
display
:
flex
;
flex-wrap
:
wrap
;
align-items
:
flex-start
;
...
...
@@ -112,7 +139,6 @@
margin-left
:
20
rpx
;
margin-top
:
26
rpx
;
border-radius
:
8
rpx
;
background
:
#EEFAEB
;
padding-top
:
8
rpx
;
box-sizing
:
border-box
;
display
:
flex
;
...
...
@@ -135,5 +161,59 @@
}
}
.module_business
{
display
:
flex
;
flex-wrap
:
wrap
;
align-items
:
flex-start
;
align-content
:
flex-start
;
justify-content
:
space-between
;
.business_item{
width
:
310
rpx
;
height
:
292
rpx
;
margin-top
:
24
rpx
;
border-radius
:
16
rpx
;
box-sizing
:
border-box
;
display
:
flex
;
flex-wrap
:
wrap
;
justify-content
:
center
;
background
:
#F9FAFB
;
.business_img{
width
:
310
rpx
;
height
:
180
rpx
;
opacity
:
1
;
border-radius
:
16
rpx
16
rpx
0
rpx
0
rpx
;
}
.qualification_name
{
height
:
48
rpx
;
line-height
:
48
rpx
;
font-size
:
32
rpx
;
color
:
#000000
;
max-width
:
280
rpx
;
margin-top
:
6
rpx
;
}
.qualification_price
{
height
:
48
rpx
;
width
:
280
rpx
;
opacity
:
1
;
font-size
:
32
rpx
;
font-weight
:
400
;
letter-spacing
:
0px
;
line-height
:
48
rpx
;
text-align
:
center
;
color
:
#5DB66F
;
.qualification_text{
font-size
:
12px
;
}
}
}
.business_item
:nth-child
(
odd
)
{
margin-left
:
0
rpx
;
}
}
}
::v-deep
.fui-fab__btn-main
{
background
:
linear-gradient
(
124.25deg
,
#a5d63f
0%
,
#5db66f
100%
)
!important
;
box-shadow
:
0px
1px
8px
#5db66f
;
}
</
style
>
src/static/images/test/product.png
0 → 100644
浏览文件 @
227bef02
123.5 KB
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论