cb_alllist.wxml
7.57 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
<scroll-view class="all-cook" style="height:{{totalHeight}}px;" bindscroll="menuscroll" scroll-y scroll-top="{{scrollTop}}" scroll-into-view="{{toView}}" enable-back-to-top="true">
<nav backgroundColor="#199095" color="#ffffff">菜品管理</nav>
<block wx:if="{{cooklist}}">
<block wx:for="{{cooklist}}" wx:for-item="cookbooklist">
<view class="all-single-cook">
<view class="all-single-title flex-cc" style="padding-top:{{index==0 ? '35rpx' : '0'}}">
<block wx:if="{{cookbooklist.style==true}}">
<view class="all-single-circle"></view>
</block>
<view class="all-single-line" style="width:{{cookbooklist.style==true ? '80rpx' : '90rpx'}};"></view>
<text class="font32r black-font smooth" style="padding:0 10rpx;">{{cookbooklist.class_name}}</text>
<view class="all-single-line" style="width:{{cookbooklist.style==true ? '80rpx' : '90rpx'}};"></view>
<block wx:if="{{cookbooklist.style==true}}">
<view class="all-single-circle"></view>
</block>
</view>
<view class="all-single-food flex-lr">
<block wx:for="{{cookbooklist.cook_bg}}" wx:for-item="foodlist">
<view class="all-single-block" style="height:{{foodlist.height}}rpx;">
<block wx:for="{{foodlist.border}}">
<view class="all-single-food-block" data-id="{{item.id}}" data-cid="{{item.cid}}" bindtap="editcook" data-url="alllist">
<view id="{{'into'+item.cid+'view'+item.id}}"></view>
<block wx:if="{{item.image}}">
<view class="food-image">
<image src="{{item.image}}" class="all-single-image" mode="aspectFill" lazy-load="true"></image>
<block wx:if="{{item.status==1 && item.clear_num && item.clear_num!=0}}">
<view class="food-clear flex-ll" style="bottom:0;">
<view class="food-clear-angel">
<view class="angel angel-top"></view>
<view class="angel angel-bottom"></view>
</view>
<view class="food-clear-num white-font smooth font20r flex-cc">剩余:{{item.clear_num}}</view>
</view>
</block>
</view>
</block>
<view class="all-single-info {{item.image ? '' : item.bg_color}} {{item.image ? '' : 'flex-vc'}}" style="height:{{item.image ? '175rpx' : '220rpx'}};padding:{{item.image ? '15rpx' : '30rpx'}} 0;padding-left:{{item.image ? '10rpx' : '30rpx'}};padding-right:10rpx;border-radius:{{item.image ? '0' : '8rpx'}};box-sizing:border-box;">
<view class="all-single-food-title font36r black-font font-bold flex-ll">{{item.name}}</view>
<block wx:if="{{item.labelList}}">
<view class="all-single-label flex-ll">
<block wx:for="{{item.labelList}}" wx:for-item="label">
<image src="{{label.icon}}" mode="aspectFit" class="all-label-image"></image>
</block>
</view>
</block>
<view class="all-single-price font28r black-font smooth flex-lr" style="margin-top:{{item.labelList || item.image ? '14rpx' : '32rpx'}}">
<view>{{item.spec.length>0 ? item.spec[0].price : item.price}}元/{{item.unit}}</view>
<block wx:if="{{item.status==1 && item.clear_num && item.clear_num==0}}">
<image src="../image/clear.png" style="width:82rpx;height:52rpx;background:transparent;margin-right:10rpx;position:relative;top:-6rpx;"></image>
</block>
<block wx:if="{{item.status==0}}">
<image src="../image/stop-sell.png" style="width:82rpx;height:52rpx;background:transparent;margin-right:10rpx;position:relative;top:-6rpx;"></image>
</block>
</view>
<block wx:if="{{item.status==1 && !item.image && item.clear_num && item.clear_num!=0}}">
<view class="food-clear flex-ll" style="top:0;">
<view class="food-clear-angel">
<view class="angel angel-top"></view>
<view class="angel angel-bottom"></view>
</view>
<view class="food-clear-num white-font smooth font20r flex-cc">剩余:{{item.clear_num}}</view>
</view>
</block>
</view>
</view>
</block>
</view>
</block>
</view>
</view>
</block>
</block>
<block wx:else>
<block wx:if="{{hiddenLoading==true}}">
<view class="flex-vc" style="height:{{totalHeight}}px;">
<image src="../image/nothing.png" class="order-nothing" style="width:266rpx;height:288rpx;background:transparent;margin-top:-30rpx;"></image>
<view class="font34r smooth black-font" style="width:466rpx;margin:0 auto;margin-top:60rpx;height:76rpx;line-height:38rpx;" bindtap="cookClass">菜品是空哒,快点击<text style="color:#199095;">分类管理</text>添加分类和菜品~ </view>
</view>
</block>
</block>
</scroll-view>
<view class="fixed-bottom white-font font28r {{kind==true ? 'flex-lr' : 'flex-rr'}} smooth" style="box-shadow:{{cooklist && showshadow==true ? '0 -2px 5px rgba(0,0,0,.08)' : ''}}">
<block wx:if="{{kind==true}}">
<view class="all-list-action flex-vc" hover-class="none" url="cb_fadd?url=alllist" bindtap="addcook">
<text class="flex-cc">添加</text>
<text class="flex-cc">菜品</text>
</view>
<navigator class="all-list-action flex-vc" hover-class="none" url="cb_list?tid={{cooklist[0].id}}">
<text class="flex-cc">菜品</text>
<text class="flex-cc">管理</text>
</navigator>
</block>
<navigator class="all-list-action flex-vc" hover-class="none" url="../cooktype/ct_list">
<text class="flex-cc">分类</text>
<text class="flex-cc">管理</text>
</navigator>
</view>
<loading hidden="{{hiddenLoading}}">正在努力加载中</loading>
<confirmAlert id="alert"></confirmAlert>
<netWork bind:netchange="netchange" id="network"></netWork>