<mobile-main frameStyle="{{frameStyle}}" bind:back="back">
    <view slot="info" class="main" style="height:{{infoHeight}}px;">
        <form catchsubmit="formSubmit" catchreset="formReset">
            <view class="form">
                <view class="top">
                    <view class="zero">
                        <view class="text">团队LOGO</view>
                        <upload class="tou" list="{{logo}}" count="{{1}}" bind:imgUpload="imgUpload" bind:imgDel="imgDel"></upload>
                    </view>
                    <view class="one">
                        <view class="text">团队名称</view>
                        <input class="input" name="name" value="{{form.name}}" placeholder="请输入团队名称" />
                    </view>
                    <view class="one" style="display: none;">
                        <view class="text">团队创建人id</view>
                        <input class="input" name="create_id" value="{{form.create_id}}" disabled />
                    </view>
                    <view class="one">
                        <view class="text">团队创建人</view>
                        <input class="input" name="create_user" value="{{form.create_user}}" placeholder="请输入团队创建人" />
                    </view>
                    <view class="one">
                        <view class="text">团队类型</view>
                        <picker mode="selector" bindchange="typeChange" name="type" value="{{form.type}}" range="{{typeList}}">
                            <view class="input">
                                {{form.type||'请选择'}}
                                <image class="back" src="/image/back.png"></image>
                            </view>
                        </picker>
                    </view>
                    <view class="one">
                        <view class="text">创建时间</view>
                        <picker mode="date" name="create_time" value="{{form.create_time}}" start="2022-01-01" end="2100-01-01" bindchange="dataChange">
                            <view class="input">
                                {{form.create_time||'选择时间'}}
                                <image class="back" src="/image/back.png"></image>
                            </view>
                        </picker>
                    </view>
                    <view class="two">
                        <view class="two_title"> 团队队员</view>
                        <view class="two_main">
                            <view class="two_1" wx:for="{{members}}" wx:key="item">
                                <view class="team_1">
                                    <image class="two_logo1" src="{{item.icon[0].url}}"></image>
                                    <image bindtap='memDel' data-id="{{item.id}}" class="two_jian" src="/image/jian.png"></image>
                                </view>
                                <view class="team_text">
                                    <text class="input1" value="{{item.nickname}}"></text>
                                </view>
                            </view>
                            <view class="two_1">
                                <view class="team_1">
                                    <view class="tianjia">
                                        <text bindtap='createMem' class=" icon iconfont icon-jia"></text>
                                    </view>
                                </view>
                            </view>
                        </view>
                    </view>
                </view>
            </view>
            <view class="btn-area">
                <button class="button" formType="submit">创建团队</button>
            </view>
        </form>
    </view>
</mobile-main>
<van-dialog use-slot title="添加成员" show="{{ show }}" :showCancelButton="{{false}}" confirmButtonText="关闭" :closeOnClickOverlay="{{false}}">
    <view class="dialog">
        <view class="dialog_1">
            <checkbox-group bindchange="memChange">
                <view class="userList" wx:for="{{userList}}" wx:key="item">
                    <label>
                        <text>{{item.nickname}}</text>
                        <checkbox value="{{item._id}}" checked="{{item.checked}}" />
                    </label>
                </view>
            </checkbox-group>
        </view>
        <view class="dialog_2">
            <button type="primary" size="mini" bindtap="memfirmSubmit">确定</button>
            <button type="warn" size="mini" bindtap="memClose">取消</button>
        </view>
    </view>
</van-dialog>