<!-- 列表下半部分 -->

<view wx:for="{{tree}}">
    <block>

        <view wx:if="{{item[parentIdKey]}}" style="display:flex;align-items:center;margin-left:{{item[itemListKey].length !== 0 ? depth*20 : depth*30}}px;font-size:36rpx;margin-top: 5px;">
            <!--  -->
            <view wx:if="{{isNameImgFlag}}">
                <view class="tree_left" wx:if="{{item[itemListKey].length !== 0}}" data-id="{{item[idKey]}}" data-open="{{item.open}}">
                    <van-image round width="40rpx" height="40rpx" src="/static/image/tree.png" />
                </view>
            </view>
            <view wx:if="{{ischekboxFlag}}">
                <checkbox checked="{{item.selected}}" bindchange="handleCheckboxChange" data-id="{{item.id}}"> </checkbox>
            </view>
            <view class="{{item[itemListKey].length !== 0 ?'parent':'node'}} " style="width: 100%;margin-left: 5vw;font-size: 14px;" data-item="{{item}}" data-type="sub" data-open="{{item.open}}" bindtap="clickName">
                <!-- bindtap="onchange" -->
                {{item[nameKey]}}

                <!-- <view class="selected" wx:if="{{item.category !== 'index'}}" catchtap="handleClick"
        data-id="{{item.id}}" data-value="{{item.name}}">
        <image hidden="{{item.selected === false}}" src="../../pages/image/tick.png"
            style="width:20px;height:20px;"></image>
    </view> -->
            </view>
            <view style="flex:1;">
                <view class="tree_right" wx:if="{{item[itemListKey]}}" data-id="{{item[idKey]}}" data-open="{{item.open}}" bindtap="onchange">
                    <!-- <view class="{{!item.open ? 'icon-right' : 'icon-down'}}"></view> -->
                    <van-icon wx:if="{{!item.open }}" color="#bdb7b7" name="arrow" />
                    <van-icon wx:else name="arrow-down" color="#bdb7b7" />
                </view>
            </view>
        </view>
        <block wx:if="{{item[itemListKey]}}">
            <view hidden="{{!item.open}}">
                <dk-tree bind:clickName="subclickName" treeList="{{item[itemListKey]}}" ischekboxFlag="{{ischekboxFlag}}" isNameImgFlag="{{isNameImgFlag}}" nameKey="{{nameKey}}" idKey="{{idKey}}" parentIdKey="{{parentIdKey}}" itemListKey="{{itemListKey}}" id="treeSelect" bind:onclick="click" depth="{{depth+1}}"></dk-tree>
            </view>
        </block>
    </block>
</view>