<nav navName="申请开药"></nav>
<view class="page {{show?'':'active'}}">
  <van-transition show="{{ show }}" custom-style="width:100%;height:auto;">
    <view class="wraper">
      <view class="searchband">
        <view class="brandtitle">
          <image src="{{img_host+'/blackss.png'}}" class="ssimg"></image>
          <view class="name">添加需购买的药品</view>
        </view>
        <view class="iptbox">
          <view class="tipbox" hidden="{{hideInput}}">
            <view class="tips">
              <view class="title placeholderIpt">请输入药品名称</view>
              <image src="{{img_host+'/ss.png'}}"  class="ssimg"></image>
            </view>
          </view>
          <input type="text" class="ipt" value="" disabled="{{true}}" bindtap="handleFcous" placeholder="" placeholder-class="placeholderIpt" />
        </view>
      </view>
    </view>
  </van-transition>
  <van-transition show="{{ !show }}" name="slide-right" custom-style="width:100%;height:auto;">
    <view class="wrapercon">
      <view class="searchbox">
        <input type="text" value="{{product_keyword}}" focus="{{isFocus}}" confirm-type="search" bindconfirm="goSearch" placeholder="请输入药品名称" confirm-type="search" placeholder-class="placeholderIpt" />
        <image  src="{{img_host+'/greenss.png'}}" ></image>
      </view>
      <view class="listbox" wx:if="{{medinceSearchList.length>0}}">
        <view class="titlebox">
          <view class="name">搜索历史</view>
          <image src="{{img_host+'/del.png'}}"  class="del" bindtap="delSearch"></image>
        </view>
        <view class="listUl">
          <view class="cell" wx:for="{{medinceSearchList}}" wx:for-index="idx" wx:key="idx" bindtap="selectHistroy" data-id="{{item}}"> {{item}} </view>
        </view>
      </view>
      <view class="medincebox">
      {{list.length}}
        <view class="cell"  wx:for="{{list}}" wx:key="product_id">
        <view class="imgbox">
          <image src="{{img_host+'/nomedince.png'}}" class="yaoimg"></image>
          <view class="desc">
            <view class="tip">处方药品</view>
            <view class="tip">依据法规不展示包装</view>
          </view>
        </view>
        <view class="rightinfo">
          <view class="name">复方乌鸡口服液补气血，益肝，主治气血两虚<text class="namenum">6g*10袋</text></view>
          <view class="own">
            <view class="company">¥34</view>
            <image src="{{img_host+'/add.png'}}"  class="add"></image>
          </view>
        </view>
      </view>
        <!-- <view class="cell" wx:for="{{list}}" wx:key="product_id" wx:for-index="index">
          <view>{{item.product_id}}</view>
          <view class="imgbox">
            <image src="{{img_host+'/nomedince.png'}}" class="yaoimg"></image>
            <view class="desc">
              <view class="tip">处方药品</view>
              <view class="tip">依据法规不展示包装</view>
            </view>
          </view>
          <view class="rightinfo">
            <view class="name">{{item.product_name}}<text class="namenum" wx:if="{{item.product_spec}}">{{item.product_spec}}{{item.packaging_unit}}</text></view>
            <view class="yaodian">{{item.manufacturer}}</view>
            <view class="own">
              <view class="company">¥{{item.product_price}}</view>
              <view class="handle">
                <view class="addbox  min" data-id="{{index}}" bindtap="minusGoods">
                  <image src="https://img.applets.igandanyiyuan.com/applet/patient/static/jian.png" class="add" hidden="{{item.shopping_cart_num==0}}"></image>
                </view>
                <view class="number" hidden="{{item.shopping_cart_num==0}}">{{item.shopping_cart_num}}</view>
                <view class="addbox" bindtap="addGoods" data-id="{{index}}">
                  <image src="https://img.applets.igandanyiyuan.com/applet/patient/static/add.png" class="add {{item.shopping_cart_num>=5?'disabled':''}}"></image>
                </view>

              </view>
            </view>
          </view>
        </view> -->

      </view>
      <!-- <view wx:elif="{{list.length==0 && toggle}}" class="nonedata">暂无数据！</view> -->
    </view>
  </van-transition>

  <view class="btnbox">
    <view class="btn" bindtap="goMedinceList">查看已添加的药品并开具处方</view>
    <view class="bage" hidden="{{totalNumber==0}}">{{totalNumber}}</view>
  </view>
</view>
