123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102 |
- <template>
- <view class="content">
- <block v-if="detail">
- <image class="top" :src="detail.img" mode="widthFix"></image>
- <view class="box">
- <view class="title">{{detail.title}}</view>
- <view class="client">客户:<span>{{detail.client}}</span></view>
- <view class="intro">{{detail.intro}}</view>
- <view class="title t2">效果</view>
- <view class="intro">{{detail.effect}}</view>
- </view>
- </block>
- </view>
- </template>
- <script>
- import { data } from '../plan/data.js'
- export default {
- data(){
- return {
- detail:null
- }
- },
- created() {
- uni.setNavigationBarTitle({
- title:'案例'
- })
- },
- onLoad(option) {
- if(option.id&&option.key){
- this.getDetails(option.id,option.key);
- }
- },
- methods:{
- getDetails(id,key){
- let temp = data[key];
- if(temp.length){
- this.detail = temp.find(t=>t.id == id).details || null;
- }
- }
- }
- }
- </script>
- <style scoped lang="less">
- .content{
- .top{
- width: 100%;
- }
-
- .box{
- width: 100%;
- padding: 0 30rpx 30rpx;
- box-sizing: border-box;
-
- .title{
- font-family: PingFang-SC, PingFang-SC;
- font-weight: bold;
- font-size: 32rpx;
- color: #111111;
- line-height: 45rpx;
- margin-top: 36rpx;
- &.t2{
- margin-top: 48rpx;
- }
- }
-
- .client{
- font-family: PingFangSC, PingFang SC;
- font-weight: bold;
- font-size: 32rpx;
- color: #333333;
- line-height: 45rpx;
- margin-top: 21rpx;
- span{
- font-size: 30rpx;
- line-height: 42rpx;
- color: #134F99;
- }
- }
-
- .intro{
- font-family: PingFangSC, PingFang SC;
- font-weight: 400;
- font-size: 28rpx;
- color: #666666;
- line-height: 48rpx;
- letter-spacing: 2rpx;
- margin-top: 21rpx;
- }
-
- .effect{
- font-family: PingFangSC, PingFang SC;
- font-weight: 400;
- font-size: 28rpx;
- color: #666666;
- line-height: 40rpx;
- margin-top: 6rpx;
- }
- }
- }
- </style>
|