Commit 5ff69798a6564d8525e09eb9e92ecd3590208e34

Authored by wangfan
1 parent f88d6011

cookbook

... ... @@ -2,56 +2,55 @@
<slot></slot>
</view>
<view hidden="{{hiddenFoodSpec}}" class="hiddenFoodSpec">
<view class="toast-mask"></view>
<view class="toast-content">
<form bindsubmit="formSubmit">
<input value="{{cookbook_id}}" name="cookbookid" hidden="true"/>
<view class="toast-content-title">{{cookbook_name}}</view>
<block wx:if="{{kind.length>0}}">
<view class="toast-content-kind" style="margin-bottom:{{foodMenu.length==0 ? '80rpx' : '0rpx'}}">
<view class="toast-kind-title">规格</view>
<view class="toast-kind-menu">
<view class="toast-kind-single {{item.iskind==true?'kind-active':''}}" wx:for="{{kind}}" wx:key="kind-key" data-key="{{index}}" id="{{item.id}}" data-price="{{item.price}}" bindtap="kindSelect">{{item.title}}</view>
<input value="{{specs_id}}" name="specs_id" hidden="true"/>
<input value="{{selectPrice}}" name="price" hidden="true"/>
<view class="toast-mask flex-vc" bindtap="close">
<view class="toast-content" catchtap="catchtap">
<form bindsubmit="formSubmit">
<input value="{{cookbook_id}}" name="cookbookid" hidden="true"/>
<view class="toast-content-title">{{cookbook_name}}</view>
<block wx:if="{{kind.length>0}}">
<view class="toast-content-kind" style="margin-bottom:{{foodMenu.length==0 ? '80rpx' : '0rpx'}}">
<view class="toast-kind-title">规格</view>
<view class="toast-kind-menu flex-ll">
<view class="toast-kind-single {{item.iskind==true?'kind-active':''}}" wx:for="{{kind}}" wx:key="kind-key" data-key="{{index}}" id="{{item.id}}" data-price="{{item.price}}" bindtap="kindSelect">{{item.title}}</view>
<input value="{{specs_id}}" name="specs_id" hidden="true"/>
<input value="{{selectPrice}}" name="price" hidden="true"/>
</view>
</view>
</view>
</block>
<block wx:if="{{foodMenu.length>0}}">
<view class="toast-content-kind" style="margin-bottom:{{kind.length==0 ? '235rpx' : '40rpx'}};">
<view class="toast-kind-title">做法</view>
<view class="toast-kind-menu">
<view class="toast-kind-single {{item.iskind==true?'kind-active':''}}" wx:for="{{foodMenu}}" wx:key="foodmenu-key" data-key="{{index}}" id="{{item.id}}" data-price="{{item.price}}" bindtap='menuSelect'>{{item.title}}</view>
<input value="{{practice_id}}" name="practice_id" hidden="true"/>
</block>
<block wx:if="{{foodMenu.length>0}}">
<view class="toast-content-kind" style="margin-bottom:{{kind.length==0 ? '235rpx' : '40rpx'}};">
<view class="toast-kind-title">做法</view>
<view class="toast-kind-menu">
<view class="toast-kind-single {{item.iskind==true?'kind-active':''}}" wx:for="{{foodMenu}}" wx:key="foodmenu-key" data-key="{{index}}" id="{{item.id}}" data-price="{{item.price}}" bindtap='menuSelect'>{{item.title}}</view>
<input value="{{practice_id}}" name="practice_id" hidden="true"/>
</view>
</view>
</block>
<view class="toast-content-end">
<view class="toast-content-money" hidden="{{showSpecsPrice}}">¥{{selectPrice}}</view>
<button class="toast-content-add" formType="submit" hidden="{{showAdd}}">确定</button>
</view>
</block>
<block wx:else>
<view class="toast-content-kind" style="height:73px;">
</view>
</block>
<view class="toast-content-end">
<view class="toast-content-money" hidden="{{showSpecsPrice}}">¥{{selectPrice}}</view>
<button class="toast-content-add" formType="submit" hidden="{{showAdd}}">确定</button>
</view>
</form>
</form>
</view>
<image class="toast-content-close" bindtap="close" src="http://qn.colorcun.com/custom/lite/image/close.png" background-size="cover"></image>
</view>
</view>
<view hidden="{{hiddenFoodSpecReduce}}" class="hiddenFoodSpec">
<view class="reduce-mask"></view>
<view class="reduce-conent">
<view class="reduce-content-title">{{item.name}}</view>
<view class="reduce-content-list">
<view class='reduce-content-large' wx:for="{{selectKind}}" wx:key="selectKind-key" wx:for-item="kindItem">
<view class="reduce-list-title">{{kindItem.title?kindItem.title:''}}{{kindItem.title?':':''}}{{kindItem.ptitle?kindItem.ptitle:''}}</view>
<view class="reduce-list-info flex-rr">
<image class="reduce-list-reduce reduce-list-first" data-index="{{index}}" data-cookbookid="{{kindItem.cookbookid}}" data-practiceid="{{kindItem.practiceid}}" data-specid="{{kindItem.specid}}" data-price="{{kindItem.price}}" bindtap="reduce" src="http://qn.colorcun.com/custom/lite/image/subtractCook.png" style="padding-right:18rpx;"></image>
<view class="reduce-list-reduce">{{kindItem.foodNum}}</view>
<image class="reduce-list-reduce reduce-list-last" data-index="{{index}}" data-cookbookid="{{kindItem.cookbookid}}" data-practiceid="{{kindItem.practiceid}}" data-specid="{{kindItem.specid}}" data-price="{{kindItem.price}}" bindtap='add' src="http://qn.colorcun.com/custom/lite/image/add.png"></image>
<view class="reduce-mask flex-vc" bindtap="close">
<view class="reduce-conent" catchtap="catchtap">
<view class="reduce-content-title">{{item.name}}</view>
<view class="reduce-content-list">
<view class='reduce-content-large' wx:for="{{selectKind}}" wx:key="selectKind-key" wx:for-item="kindItem">
<view class="reduce-list-title">{{kindItem.title?kindItem.title:''}}{{kindItem.title?':':''}}{{kindItem.ptitle?kindItem.ptitle:''}}</view>
<view class="reduce-list-info flex-rr">
<image class="reduce-list-reduce reduce-list-first" data-index="{{index}}" data-cookbookid="{{kindItem.cookbookid}}" data-practiceid="{{kindItem.practiceid}}" data-specid="{{kindItem.specid}}" data-price="{{kindItem.price}}" bindtap="reduce" src="http://qn.colorcun.com/custom/lite/image/subtractCook.png" style="padding-right:18rpx;"></image>
<view class="reduce-list-reduce">{{kindItem.foodNum}}</view>
<image class="reduce-list-reduce reduce-list-last" data-index="{{index}}" data-cookbookid="{{kindItem.cookbookid}}" data-practiceid="{{kindItem.practiceid}}" data-specid="{{kindItem.specid}}" data-price="{{kindItem.price}}" bindtap='add' src="http://qn.colorcun.com/custom/lite/image/add.png"></image>
</view>
</view>
</view>
</view>
<image src="http://qn.colorcun.com/custom/lite/image/close.png" class="reduce-close" bindtap="close"></image>
</view>
</view>
\ No newline at end of file
... ...
... ... @@ -13,17 +13,9 @@
}
.toast-content{
width:542rpx;
min-height: 300px;
height:auto;
background: #fff;
border-radius: 10rpx;
position: fixed;
top: 35%;
left:0;
right:0;
margin:0 auto;
margin-top:-150px;
z-index: 9999;
/* overflow: hidden; */
}
.toast-content-title{
... ... @@ -36,7 +28,7 @@
.toast-content-kind{
width: 100%;
height: auto;
padding:0 19rpx;
padding:0 42rpx;
box-sizing: border-box;
padding-top: 20px;
}
... ... @@ -44,8 +36,7 @@
width: 100%;
color:#353535;
font-size:16px;
padding-left:19rpx;
box-sizing:border-box;
margin-bottom: 24rpx;
}
.toast-kind-menu{
width: 100%;
... ... @@ -61,17 +52,14 @@
clear:both;
}
.toast-kind-single{
float:left;
width: 130rpx;
height: 25px;
border:1px solid #ccc;
box-sizing: border-box;
color:#353535;
font-size:14px;
line-height: 23px;
width: 102rpx;
height: 42rpx;
border:1px solid #C8B16D;
color:#C8B16D;
font-size:28rpx;
line-height: 42rpx;
text-align: center;
margin:0 19rpx;
margin-top: 10px;
margin-right: 38rpx;
}
.toast-kind-single:last-child{
margin-right: 0;
... ... @@ -88,7 +76,7 @@
}
.toast-content-money{
float: left;
color: #e14553;
color: #C8B16D;
font-size:17px;
line-height: 28px;
}
... ... @@ -96,7 +84,7 @@
float: right;
width: 95px;
height: 28px;
background: #e14553;
background: #C8B16D;
border-radius:28px;
color: #fff;
font-size:13px;
... ... @@ -104,18 +92,14 @@
text-align: center;
}
.toast-kind-single.kind-active{
border:1px solid #e14553;
color:#e14553;
border-width:0;
color:#ffffff;
background: linear-gradient(to right, #ECDB99, #C8B16D);
}
.toast-content-close{
width: 60rpx;
height: 60rpx;
position: absolute;
left: 0;
right: 0;
bottom:-140rpx;
margin:0 auto;
background: transparent;
margin-top: 160rpx;
}
/*删除规格遮罩*/
... ...