审查视图

public/themes/simpleboot3/portal/order_salesman/get_all.html 59.0 KB
1 2 3
<!DOCTYPE html>
<html lang="en">
王晓刚 authored
4 5 6 7 8 9 10 11 12
<head>
    <meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/>
    <meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" name="viewport"/>
    <meta http-equiv="X-UA-Compatible" content="ie=edge"/>
    <title>学考无忧-订单管理</title>
    <link rel="stylesheet" href="__TMPL__/public/assets/css/mui.min.css"/>
    <link rel="stylesheet" href="__TMPL__/public/assets/css/mui.picker.min.css"/>
    <link rel="stylesheet" href="__TMPL__/public/assets/css/reset.css"/>
    <link rel="stylesheet" href="__TMPL__/public/assets/css/log.css"/>
王晓刚 authored
13 14 15 16 17 18 19 20 21
    <style>
        .tx_masktwo {
            display: none;
            z-index: 2;
            width: 100%;
            height: 100%;
            position: fixed;
            background-color: rgba(0, 0, 0, 0.5);
        }
22 23

        .take_one {
王晓刚 authored
24 25 26 27 28 29 30 31 32 33 34 35 36 37
            margin-top: 0.3rem;
            width: 1.6rem;
            height: 0.48rem;
            background: linear-gradient(328deg, rgba(255, 78, 0, 1) 0%, rgba(255, 157, 45, 1) 100%);
            box-shadow: 0 0.06rem 0.12rem rgba(255, 128, 0, 0.24);
            opacity: 1;
            border-radius: 0.08rem;
            display: flex;
            justify-content: center;
            align-items: center;
            font-size: 0.26rem;
            font-weight: 400;
            color: rgba(255, 255, 255, 1);
        }
anyv authored
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

        .tx_mask_class {
            display: none;
            z-index: 3;
            width: 100%;
            height: 100%;
            position: fixed;
            background-color: rgba(0, 0, 0, 0.5);
        }

        .tx_maskCon_class {
            width: 100%;
            height: 5.16rem;
            background: #fff;
            position: fixed;
            bottom: 0;
        }

        .three_model_class_name {
            height: 0.36rem;
            margin: 0.08rem;
            font-size: 0.24rem;
            font-weight: 400;
            color: #666666;
            opacity: 1;
            padding: 0.2rem 0;
            line-height: 0;
            border-left: none;
            border-right: none
        }
68 69

        .get_Go {
anyv authored
70 71 72 73 74 75 76 77 78 79 80 81
            height: 0.36rem;
            margin: 0.08rem;
            font-size: 0.24rem;
            font-weight: 400;
            cursor: pointer;
            color: #666666;
            opacity: 1;
            padding: 0.2rem 0;
            line-height: 0;
            border-left: none;
            border-right: none;
        }
82
4  
anyv authored
83 84 85 86 87 88 89 90 91 92 93 94 95 96 97
        .mui-poppicker-header,
        .mui-picker {
            background-color: white;
        }

        .mui-btn-blue,
        .mui-btn-primary,
        input[type=submit] {
            background-color: #FF7700;
            border: 0;
        }

        .mui-pciker-list li.highlight {
            color: #FF7700;
        }
98 99

        .mui-dtpicker-header, .mui-dtpicker-title h5 {
4  
anyv authored
100 101
            background-color: white;
        }
102 103

        .dingdan_lianxi_ren {
1  
anyv authored
104 105 106 107 108 109 110
            font-size: 0.28rem;
            cursor: pointer;
            font-family: PingFang SC;
            font-weight: 400;
            color: rgba(102, 102, 102, 1);
            opacity: 1;
        }
111 112 113 114 115 116

        /*.dingdan_detail {*/
            /*padding-top: 0.22rem;*/
        /*}*/

        .dingdan_detail_hao {
1  
anyv authored
117 118 119 120 121 122
            font-size: 0.28rem;
            cursor: pointer;
            font-family: PingFang SC;
            font-weight: 400;
            color: rgba(102, 102, 102, 1);
            opacity: 1;
123
            margin-top:0.2rem;
1  
anyv authored
124
        }
125 126

        .right_dingdan {
1  
anyv authored
127 128 129
            width: 5.6rem;
            margin-left: 0.2rem;
        }
130 131

        .right_dingdan_top {
1  
anyv authored
132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147
            display: flex;
            justify-content: space-between;
            display: -webkit-box; /* Chrome 4+, Safari 3.1, iOS Safari 3.2+ */
            display: -moz-box; /* Firefox 17- */
            display: -webkit-flex; /* Chrome 21+, Safari 6.1+, iOS Safari 7+, Opera 15/16 */
            display: -moz-flex; /* Firefox 18+ */
            display: -ms-flexbox; /* IE 10 */
            display: flex; /* Chrome 29+, Firefox 22+, IE 11+, Opera 12.1/17/18, Android 4.4+ */
            justify-content: space-between;
            -webkit-flex-justify-content: space-between;
            -moz-box-justify-content: space-between;
            -ms-flexbox-justify-content: space-between;
            -webkit-flexalign-align-items: center;
            -moz-box-align-items: center;
            -ms-flexbox-align-items: center;
        }
148 149

        .right_dingdan_center {
1  
anyv authored
150 151
            text-align: right;
        }
152 153

        .right_dingdan_one {
1  
anyv authored
154 155 156 157 158 159
            font-size: 0.26rem;
            cursor: pointer;
            font-weight: 400;
            color: rgba(51, 51, 51, 1);
            opacity: 1;
        }
160 161

        .right_dingdan_two {
1  
anyv authored
162 163 164 165 166 167 168
            font-size: 0.34rem;
            font-weight: 400;
            cursor: pointer;
            line-height: 25px;
            color: rgba(51, 51, 51, 1);
            opacity: 1;
        }
169 170

        .shuju_zongshu {
1  
anyv authored
171 172 173 174 175 176
            padding-left: 0.4rem;
            font-size: 0.28rem;
            font-weight: 600;
            color: #333;
            border-radius: 0.08rem;
        }
王晓刚 authored
177
    </style>
王晓刚 authored
178
</head>
179
4  
anyv authored
180
<body style="cursor:pointer;">
anyv authored
181 182 183 184 185 186 187 188 189 190


<!--学校弹窗-->
<div class="tx_mask_school" onclick="$(this).hide()">
    <div class="tx_maskCon_school" onclick="zZFun(this)">
        <div class="three_model_school">
            <div class="three_model_school_title">
                选择学校
            </div>
            <div class="three_model_school_data there_university" style="display: block;">
4  
anyv authored
191
anyv authored
192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208
            </div>
        </div>
    </div>
</div>
<!--班级弹窗-->
<div class="tx_mask_class" onclick="$(this).hide()">
    <div class="tx_maskCon_class" onclick="zZFun(this)">
        <div class="three_model_school">
            <div class="three_model_school_title">
                选择班级
            </div>
            <div class="three_model_school_data there_university grade" style="display: block;">
            </div>
        </div>
    </div>
</div>
209
王晓刚 authored
210
<!--统一配送-->
2  
anyv authored
211 212
<div class="tx_mask_tongyi" onclick="$(this).hide()">
    <div class="tx_maskCon_tongyi" onclick="zZFun(this)">
王晓刚 authored
213 214
        <div class="three_model_school">
            <div class="three_model_school_data" style="display: block;">
anyv authored
215 216
                <div class="three_modal_kuaidi_name there_unActive" data-id="1">统一配送</div>
                <div class="three_modal_kuaidi_name" data-id="2">快递配送</div>
王晓刚 authored
217
            </div>
王晓刚 authored
218
        </div>
王晓刚 authored
219 220 221 222 223 224 225 226 227 228 229
    </div>
</div>
<!--选择快递-->
<div class="tx_mask_kuaidi">
    <div class="tx_maskCon_school">
        <div class="three_model_school">
            <div class="three_model_school_title">
                选择快递
            </div>
            <div>
                <div class="three_model_school_data" style="display: block;">
anyv authored
230 231 232 233 234 235 236 237 238 239 240 241
                    <div class="get_Go" data-name="SF">顺丰快递</div>
                    <div class="get_Go" data-name="YTO">圆通快递</div>
                    <div class="get_Go" data-name="ZTO">中通快递</div>
                    <div class="get_Go there_unActive" data-name="STO">申通快递</div>
                    <div class="get_Go" data-name="YD">韵达快递</div>
                    <div class="get_Go" data-name="HHTT">天天快递</div>
                    <div class="get_Go" data-name="HTKY">百世快递</div>
                    <div class="get_Go" data-name="YZPY">邮政快递包裹</div>
                    <div class="get_Go" data-name="EMS">EMS</div>
                    <div class="get_Go" data-name="DBL">德邦快递</div>
                    <div class="get_Go" data-name="ZJS">宅急送</div>
                    <div class="get_Go" data-name="TNT">TNT快递</div>
王晓刚 authored
242 243 244 245 246
                </div>
            </div>
        </div>
    </div>
</div>
王晓刚 authored
247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271
<div class="tx_masktwo" style="display: none;">
    <div class="tx_maskCon">
        <div class="tx_maskConImg">
            <img src="__TMPL__/public/assets/images/91.png" alt=""/>
        </div>
        <div class="tx_maskCon2">
            <div class="log_three_model">
                <div class="log_three_model_one time">
                    <div class="log_three_model_left">配送时间</div>
                    <div class="log_psong">
                        <input type="text" id="start_time2" value="" placeholder="请输入开始配送时间"/>
                    </div>
                </div>
                <div class="log_three_model_one time">
                    <div class="log_three_model_left">配送时间</div>
                    <div class="log_psong">
                        <input type="text" id="end_time2" value="" placeholder="请输入结束配送时间"/>
                    </div>
                </div>
            </div>
            <!-- 确定 -->
            <div class="tx_maskOk confirm2" data-is_courier="" data-id="" data-indent-id="">确定</div>
        </div>
    </div>
</div>
2  
anyv authored
272 273
<div class="tx_maskone" onclick="$(this).hide()">
    <div class="tx_maskCon" onclick="zZFun(this)">
王晓刚 authored
274 275 276 277 278
        <div class="tx_maskConImg">
            <img src="__TMPL__/public/assets/images/91.png" alt=""/>
        </div>
        <div class="tx_maskCon2">
            <div class="log_three_model">
王晓刚 authored
279
                <div class="log_three_model_one time">
王晓刚 authored
280 281
                    <div class="log_three_model_left">配送时间</div>
                    <div class="log_psong">
王晓刚 authored
282
                        <input type="text" id="start_time" value="" placeholder="请输入开始配送时间"/>
王晓刚 authored
283 284
                    </div>
                </div>
王晓刚 authored
285
                <div class="log_three_model_one time">
王晓刚 authored
286 287
                    <div class="log_three_model_left">配送时间</div>
                    <div class="log_psong">
王晓刚 authored
288 289 290
                        <input type="text" id="end_time" value="" placeholder="请输入结束配送时间"/>
                    </div>
                </div>
291
                <div class="log_three_model_one logistic">
王晓刚 authored
292 293
                    <div class="log_three_model_left">选择快递</div>
                    <div class="log_psong log_psong_select">
anyv authored
294
                        <div class="log_ps_title2 get_Gofo">请选择快递公司</div>
王晓刚 authored
295
                        <div class="log_ps_img">
王晓刚 authored
296
                            <img src="__TMPL__/public/assets/images/29.png"/>
297
                            <input type="hidden" id="logistic_name" placeholder="请选择快递公司"/>
王晓刚 authored
298 299 300 301 302 303 304
                        </div>
                    </div>
                </div>
                <div class="log_three_model_one logistic" style="padding-bottom: 0;">
                    <div class="log_three_model_left" style="margin-top: -0.3rem;">快递单号</div>
                    <div class="log_three_model_right">
                        <input type="text" id="logistic_code" placeholder="请输入快递单号"/>
王晓刚 authored
305 306 307 308
                    </div>
                </div>
            </div>
            <!-- 确定 -->
王晓刚 authored
309
            <div class="tx_maskOk confirm" data-is_courier="" data-id="" data-indent-id="">确定</div>
王晓刚 authored
310 311 312 313 314 315
        </div>
    </div>
</div>
<div class="log_top_co">
    <!-- 顶部 -->
    <div class=" order_top log_top_co">
anyv authored
316
        <a href="javascript:history.back(-1)">
王晓刚 authored
317 318 319 320 321 322 323
            <img src="__TMPL__/public/assets/images/left.png" alt=""/>
        </a>
        <p>订单管理</p>
    </div>
</div>
<!-- tab切换 -->
<div class="log_three_tab log_three_tab_top">
4  
anyv authored
324 325 326
    <div class="log_three_tab_one log_three_tab_two word_color aaa" data-state="2" style="cursor: pointer">未发货</div>
    <div class="log_three_tab_one" data-state="5" style="cursor: pointer">已发货</div>
    <div class="log_three_tab_one" data-state="3" style="cursor: pointer">已完成</div>
王晓刚 authored
327 328 329
</div>
<!-- 下拉框  -->
<div class="log_three_select">
330 331 332 333 334 335 336 337
    <!-- <div class="log_three_select_one log_three_select_school" style="cursor: pointer">
         <div class="log_three_select_title log_three_select_school2">
             请选择学校/班级
         </div>
         <div class="log_three_select_img">
             <img src="__TMPL__/public/assets/images/75.png" alt=""/>
         </div>
     </div>-->
anyv authored
338 339 340 341 342 343 344


    <div class="log_three_select_one log_three_select_school">
        <div class="log_three_select_title log_three_select_school2">
            请选择学校
        </div>
        <!--<div class="log_three_select_img">-->
345
        <!--<img src="__TMPL__/public/assets/images/75.png" alt="" />-->
anyv authored
346 347 348 349 350 351 352
        <!--</div>-->
    </div>
    <div class="log_three_select_one log_three_select_school">
        <div class="log_three_select_title log_three_select_class2">
            请选择班级
        </div>
        <!--<div class="log_three_select_img">-->
353
        <!--<img src="__TMPL__/public/assets/images/75.png" alt="" />-->
anyv authored
354
        <!--</div>-->
王晓刚 authored
355
    </div>
anyv authored
356 357

4  
anyv authored
358
    <div class="log_three_select_one log_three_select_peisong log_three_select_tongyi" style="cursor: pointer">
王晓刚 authored
359
        <div class="log_three_select_title log_three_select_contant">
360
            统一配送
王晓刚 authored
361
        </div>
anyv authored
362
        <!--<div class="log_three_select_img">-->
363
        <!--<img src="__TMPL__/public/assets/images/75.png" alt=""/>-->
anyv authored
364
        <!--</div>-->
王晓刚 authored
365 366 367 368 369 370
    </div>
    <div class="log_three_select_one log_three_select_btn search">
        搜索
    </div>
    <input type="hidden" id="school" value=""/>
    <input type="hidden" id="grade" value=""/>
371
    <input type="hidden" id="is_courier" value="1"/>
王晓刚 authored
372
</div>
373 374 375 376 377 378 379 380 381 382 383
<php>$arr2 = [];</php>
<foreach name="$data" item="vo">
    <if condition="$vo.state eq 2">
        <php>$arr2[] = $vo;</php>
        <elseif condition="$vo.state eq 5" />
        <php>$arr5[] = $vo;</php>
        <elseif condition="$vo.state eq 3" />
        <php>$arr3[] = $vo;</php>
    </if>
</foreach>
<div class="shuju_zongshu">搜索结果为<span class="count">{:count($arr2)}</span></div>
王晓刚 authored
384 385 386 387 388 389
<!-- 列表内容 -->
<div>
    <!--未发货-->
    <div class="log_three_list_contant" style="display: block;">
        <foreach name="$data" item="vo">
            <if condition="$vo.state eq 2">
390
                <php>$arr1[] = $vo;</php>
391
                <div class="log_three_list order_{$vo.id}">
王晓刚 authored
392 393
                    <div class="log_three_list_top">
                        <div class="log_three_list_top_left">
394 395
                            <if condition="$vo.is_courier eq 1">
                                <div class="log_three_list_top_lo">
王晓刚 authored
396 397
                                    <img src="__TMPL__/public/assets/images/fangkuang.png"
                                         data-indent-id="{$vo['id']}" alt=""/>
398 399
                                </div>
                            </if>
王晓刚 authored
400 401 402 403 404
                            <div class="log_three_list_top_lt">
                                <div class="log_three_zhongbiao">
                                    <img src="__TMPL__/public/assets/images/52.png" alt=""/>
                                </div>
                                <div class="log_three_shijian">
王晓刚 authored
405
                                    {$vo['pay_time']}
王晓刚 authored
406 407 408 409 410 411 412 413 414 415 416 417 418
                                </div>
                            </div>
                        </div>
                        <div class="log_three_list_top_right">
                            <if condition="$vo.state eq 2">
                                待发货
                                <elseif condition="$vo.state eq 5"/>
                                已发货
                                <elseif condition="$vo.state eq 3"/>
                                已完成
                            </if>
                        </div>
                    </div>
王晓刚 authored
419
                    <a href="{:url('get_one',array('id'=>$vo['id']))}">
420 421 422
                        <div class="dingdan_detail_top">
                            <div class="dingdan_detail_hao">订单号:{$vo.order_number}</div>
                        </div>
王晓刚 authored
423
                        <foreach name="$vo.indent_goods" item="i_g">
1  
anyv authored
424 425 426
                            <div class="dingdan_detail">
                                <div class="log_three_list_center" style="display: flex;justify-content: flex-start;">
                                    <div class="log_three_list_center_left" style="width: 1.44rem;height:1.44rem">
427 428
                                        <img src="{:cmf_get_image_url($i_g.thumbnail)}" alt=""
                                             style="width: 100%;height: 100%;"/>
王晓刚 authored
429
                                    </div>
1  
anyv authored
430
                                    <!--<div class="log_three_list_center_right" style="margin-left: 0.16rem;width: 5.6rem">-->
431 432 433 434 435 436 437
                                    <!--<div class="log_three_center_one">-->
                                    <!--{$i_g.book_name}-->
                                    <!--</div>-->
                                    <!--<div class="right_dingdan_money">-->
                                    <!--<div class="log_three_center_three"><span>¥</span>{$i_g.price}</div>-->
                                    <!--<div class="log_three_center_two">×{$i_g.number}</div>-->
                                    <!--</div>-->
1  
anyv authored
438 439 440 441 442 443
                                    <!--</div>-->
                                    <div class="right_dingdan">
                                        <div class="right_dingdan_top">
                                            <div class="right_dingdan_one">{$i_g.book_name}</div>
                                            <div class="right_dingdan_two">¥{$i_g.price}</div>
                                        </div>
444 445 446
                                        <div class="right_dingdan_center">
                                            <div class="right_dindan_three right_dingdan_one">x{$i_g.number}</div>
                                        </div>
4  
anyv authored
447
448 449 450 451 452 453 454
                                        <div class="right_dingdan_four right_dingdan_one">地址:{$vo.school} {$vo.grade}
                                            {$vo.class}
                                        </div>
                                        <div class="right_dingdan_four right_dingdan_one" style="margin-top: -0.05rem;">
                                            {$vo.name}电话:{$vo.phone}
                                        </div>
                                    </div>
王晓刚 authored
455 456
                                </div>
                            </div>
王晓刚 authored
457 458
                        </foreach>
                    </a>
王晓刚 authored
459 460 461
                    <!-- 立即发货 -->
                    <div class="log_three_bottom_btn">
                        <if condition="$vo.state eq 2">
王晓刚 authored
462 463
                            <div class="log_three_bottom send" data-indent-id="{$vo.id}"
                                 data-is_courier="{$vo.is_courier}">
王晓刚 authored
464 465 466 467
                                立即发货
                            </div>
                            <elseif condition="$vo.state eq 5"/>
                            <if condition="$vo.is_courier eq 2">
王晓刚 authored
468
                                <a href="{:url('logistics/index',array('indent_id'=>$vo['id']))}">
王晓刚 authored
469 470 471 472
                                    <div class="log_three_bottom" data-indent-id="{$vo.id}">
                                        查看物流
                                    </div>
                                </a>
473 474 475
                                <div class="log_three_bottom" data-indent-id="{$vo.id}">
                                    完成
                                </div>
王晓刚 authored
476 477
                            </if>
                            <elseif condition="$vo.state eq 3"/>
王晓刚 authored
478
                            <!--<div class="log_three_bottom" data-indent-id="{$vo.id}">-->
479
                            <!--已完成啦-->
王晓刚 authored
480
                            <!--</div>-->
王晓刚 authored
481 482 483 484 485
                        </if>
                    </div>
                </div>
            </if>
        </foreach>
486 487 488
        <empty name="$arr1">
            <div style="text-align: center;width: 100%;height:100%;margin:0 auto;">暂无数据</div>
        </empty>
王晓刚 authored
489
    </div>
1  
anyv authored
490
王晓刚 authored
491 492 493 494
    <!--已发货-->
    <div class="log_three_list_contant">
        <foreach name="$data" item="vo">
            <if condition="$vo.state eq 5">
495
                <php>$arr2[] = $vo;</php>
496
                <div class="log_three_list order_{$vo.id}">
王晓刚 authored
497 498
                    <div class="log_three_list_top">
                        <div class="log_three_list_top_left">
499 500
                            <if condition="$vo.is_courier eq 1">
                                <div class="log_three_list_top_lo">
王晓刚 authored
501 502
                                    <img src="__TMPL__/public/assets/images/fangkuang.png"
                                         data-indent-id="{$vo['id']}" alt=""/>
503 504
                                </div>
                            </if>
王晓刚 authored
505 506 507 508 509
                            <div class="log_three_list_top_lt">
                                <div class="log_three_zhongbiao">
                                    <img src="__TMPL__/public/assets/images/52.png" alt=""/>
                                </div>
                                <div class="log_three_shijian">
510
                                    {$vo['pay_time']}
王晓刚 authored
511 512 513 514 515 516 517 518 519 520 521 522 523
                                </div>
                            </div>
                        </div>
                        <div class="log_three_list_top_right">
                            <if condition="$vo.state eq 2">
                                代发货
                                <elseif condition="$vo.state eq 5"/>
                                已发货
                                <elseif condition="$vo.state eq 3"/>
                                已完成
                            </if>
                        </div>
                    </div>
王晓刚 authored
524 525
                    <a href="{:url('get_one',array('id'=>$vo['id']))}">
                        <foreach name="$vo.indent_goods" item="i_g">
5  
anyv authored
526
                            <div class="log_three_list_center" style="display: flex;justify-content: flex-start;">
527 528 529
                                <div class="log_three_list_center_left" style="width: 1.44rem;height:1.44rem">
                                    <img src="{:cmf_get_image_url($i_g.thumbnail)}" alt=""
                                         style="width: 100%;height: 100%;"/>
王晓刚 authored
530
                                </div>
5  
anyv authored
531
                                <div class="log_three_list_center_right" style="margin-left: 0.16rem;">
王晓刚 authored
532 533 534 535
                                    <div class="log_three_center_one">
                                        {$i_g.book_name}
                                    </div>
                                    <div class="log_three_center_two">×{$i_g.number}</div>
536
                                    <div class="log_three_center_three"><span></span>{$i_g.price}</div>
王晓刚 authored
537 538
                                </div>
                            </div>
王晓刚 authored
539 540
                        </foreach>
                    </a>
王晓刚 authored
541 542 543 544 545 546 547 548
                    <!-- 立即发货 -->
                    <div class="log_three_bottom_btn">
                        <if condition="$vo.state eq 2">
                            <div class="log_three_bottom" data-indent-id="{$vo.id}" data-is_courier="{$vo.is_courier}">
                                立即发货
                            </div>
                            <elseif condition="$vo.state eq 5"/>
                            <if condition="$vo.is_courier eq 2">
王晓刚 authored
549 550 551 552 553
                                <a href="{:url('logistics/index',array('indent_id'=>$vo['id']))}">
                                    <div class="log_three_bottom" data-indent-id="{$vo.id}">
                                        查看物流
                                    </div>
                                </a>
554
                                <else/>
王晓刚 authored
555 556 557
                                <div class="take_one" data-indent-id="{$vo.id}">
                                    完成
                                </div>
王晓刚 authored
558 559
                            </if>
                            <elseif condition="$vo.state eq 3"/>
王晓刚 authored
560
                            <!--<div class="log_three_bottom" data-indent-id="{$vo.id}">-->
561
                            <!--已完成啦-->
王晓刚 authored
562
                            <!--</div>-->
王晓刚 authored
563 564 565 566 567
                        </if>
                    </div>
                </div>
            </if>
        </foreach>
568 569 570
        <empty name="$arr2">
            <div style="text-align: center;width: 100%;height:100%;margin:0 auto;">暂无数据</div>
        </empty>
王晓刚 authored
571 572 573 574 575
    </div>
    <!--已完成-->
    <div class="log_three_list_contant">
        <foreach name="$data" item="vo">
            <if condition="$vo.state eq 3">
576
                <php>$arr3 = $vo;</php>
577
                <div class="log_three_list order_{$vo.id}">
王晓刚 authored
578 579
                    <div class="log_three_list_top">
                        <div class="log_three_list_top_left">
580 581
                            <if condition="$vo.is_courier eq 1">
                                <div class="log_three_list_top_lo">
王晓刚 authored
582 583
                                    <img src="__TMPL__/public/assets/images/fangkuang.png"
                                         data-indent-id="{$vo['id']}" alt=""/>
584 585
                                </div>
                            </if>
王晓刚 authored
586 587 588 589 590
                            <div class="log_three_list_top_lt">
                                <div class="log_three_zhongbiao">
                                    <img src="__TMPL__/public/assets/images/52.png" alt=""/>
                                </div>
                                <div class="log_three_shijian">
591
                                    {$vo['pay_time']}
王晓刚 authored
592 593 594 595 596 597 598 599 600 601 602 603 604
                                </div>
                            </div>
                        </div>
                        <div class="log_three_list_top_right">
                            <if condition="$vo.state eq 2">
                                代发货
                                <elseif condition="$vo.state eq 5"/>
                                已发货
                                <elseif condition="$vo.state eq 3"/>
                                已完成
                            </if>
                        </div>
                    </div>
王晓刚 authored
605 606
                    <a href="{:url('get_one',array('id'=>$vo['id']))}">
                        <foreach name="$vo.indent_goods" item="i_g">
5  
anyv authored
607 608
                            <div class="log_three_list_center" style="display: flex;justify-content: flex-start;">
                                <div class="log_three_list_center_left" style="width: 1.44rem;height:1.44rem">
609 610
                                    <img src="{:cmf_get_image_url($i_g.thumbnail)}" alt=""
                                         style="width: 100%;height: 100%;"/>
王晓刚 authored
611
                                </div>
5  
anyv authored
612
                                <div class="log_three_list_center_right" style="margin-left: 0.16rem;">
王晓刚 authored
613 614 615 616
                                    <div class="log_three_center_one">
                                        {$i_g.book_name}
                                    </div>
                                    <div class="log_three_center_two">×{$i_g.number}</div>
617
                                    <div class="log_three_center_three"><span></span>{$i_g.price}</div>
王晓刚 authored
618 619
                                </div>
                            </div>
王晓刚 authored
620 621
                        </foreach>
                    </a>
王晓刚 authored
622 623 624 625 626 627 628 629
                    <!-- 立即发货 -->
                    <div class="log_three_bottom_btn">
                        <if condition="$vo.state eq 2">
                            <div class="log_three_bottom" data-indent-id="{$vo.id}" data-is_courier="{$vo.is_courier}">
                                立即发货
                            </div>
                            <elseif condition="$vo.state eq 5"/>
                            <if condition="$vo.is_courier eq 2">
王晓刚 authored
630 631 632 633 634
                                <a href="{:url('logistics/index',array('indent_id'=>$vo['id']))}">
                                    <div class="log_three_bottom" data-indent-id="{$vo.id}">
                                        查看物流
                                    </div>
                                </a>
王晓刚 authored
635 636 637
                                <div class="log_three_bottom" data-indent-id="{$vo.id}">
                                    已完成
                                </div>
王晓刚 authored
638 639
                            </if>
                            <elseif condition="$vo.state eq 3"/>
王晓刚 authored
640
                            <!--<div class="log_three_bottom" data-indent-id="{$vo.id}">-->
641
                            <!--已完成啦-->
王晓刚 authored
642
                            <!--</div>-->
王晓刚 authored
643 644 645 646 647
                        </if>
                    </div>
                </div>
            </if>
        </foreach>
648 649 650
        <empty name="$arr3">
            <div style="text-align: center;width: 100%;height:100%;margin:0 auto;">暂无数据</div>
        </empty>
王晓刚 authored
651 652 653
    </div>
</div>
<!-- 底部按钮 -->
654 655 656
<div style="position: fixed;bottom:0;width: 100%;">
    <div class="log_three_list_fixed">
        <div class="log_three_fixed_left">
4  
anyv authored
657
            <div class="log_three_fixed_left_one" style="cursor: pointer">
658 659 660 661 662
                <img src="__TMPL__/public/assets/images/fangkuang.png" alt=""/>
            </div>
            <div class="log_three_fixed_left_two">
                全选
            </div>
王晓刚 authored
663
        </div>
664 665
        <div class="log_three_fixed_right unify_all">
            统一发货
王晓刚 authored
666 667 668 669 670 671 672 673 674
        </div>
    </div>
</div>
<script src="__TMPL__/public/assets/js/jquery.js"></script>
<script src="__TMPL__/public/assets/js/base.js"></script>
<script src="__TMPL__/public/assets/js/mui.min.js"></script>
<script src="__TMPL__/public/assets/js/mui.picker.min.js"></script>
<script src="__TMPL__/public/assets/js/city.data-3.js"></script>
<script>
4  
anyv authored
675 676 677 678
    var schoolpicker = new mui.PopPicker();
    var classpicker = new mui.PopPicker();
    var class_arr = '';
    zujian();
679 680 681

    function zujian(data_class_arr) {
        (function ($, doc) {
4  
anyv authored
682 683
            $.init();
            school_arr = {$school};
684 685
            console.log(data_class_arr, 'dfdfds');
            $.ready(function () {
4  
anyv authored
686 687 688 689 690
                schoolpicker.setData(school_arr);
                classpicker.setData(data_class_arr);
            });
        })(mui, document);
    }
691
4  
anyv authored
692
    var school_name;
693 694
    $(".log_three_select_school2").click(function () {
        schoolpicker.show(function (e) {
4  
anyv authored
695 696
            school_name = e[0].value;
            school_names = e[0].text;
6  
anyv authored
697
            $('#school').val(school_names);
4  
anyv authored
698 699
            $(".log_three_select_school2").text(e[0].text);
            $('.log_three_select_school2').css('color', '#333333');
700 701
            $.post("{:url('Personalcenter/get_grade_class')}", {id: school_name}, function (data) {
                if (data) {
4  
anyv authored
702 703 704 705 706 707 708 709
                    data = JSON.parse(data);
                    zujian(data);
                }

            });
        });

    })
710 711 712 713
    $(".log_three_select_class2").click(function () {
        if (school_name != undefined) {
            classpicker.show(function (e) {
                class_name = e[0].text;
6  
anyv authored
714
                $('#grade').val(class_name);
4  
anyv authored
715 716 717 718 719 720
                $(".log_three_select_class2").text(e[0].text);
                $('.log_three_select_class2').css('color', '#333333');
            });
        } else {
            alert("请先选择学校")
        }
anyv authored
721 722 723
    })
</script>
<script>
2  
anyv authored
724 725 726
    function zZFun(e) {
        window.event ? (window.event.cancelBubble = true) : e.stopPropagation();
    }
727
王晓刚 authored
728
    // 选择学校
729 730 731 732
    //    $(".three_model_school_left").click(function () {
    //        var indexs = $(this).index();
    //        $(".three_model_school_data").eq(indexs).css("display", "block").siblings().css("display", "none");
    //    });
733
王晓刚 authored
734 735 736 737
    $(".log_three_tab_one").click(function () {
        var tabIndex = $(this).index();
        $(this).addClass("log_three_tab_two").addClass("word_color").addClass('aaa').siblings().removeClass("log_three_tab_two").removeClass("word_color").removeClass("aaa");
        $('.log_three_list_contant').eq(tabIndex).css('display', 'block').siblings().css('display', 'none');
王晓刚 authored
738
        search();
739
        $('.log_three_fixed_left_one img').attr('src', "__TMPL__/public/assets/images/fangkuang.png")
王晓刚 authored
740 741 742 743
    });
    $(".three_model_school_tab>div").click(function () {
        $(this).addClass("three_model_school_hover").addClass("word_color").addClass('aaa').siblings().removeClass("three_model_school_hover").removeClass("word_color").removeClass("aaa");
    });
744
王晓刚 authored
745
    $("body").on('click', '.log_three_list_top_lo', function () {
王晓刚 authored
746 747 748 749 750
        if ($(this).find("img").attr("src") == "__TMPL__/public/assets/images/fangkuang.png") {
            $(this).find("img").attr("src", "__TMPL__/public/assets/images/xuanzhong (1).png");
        } else {
            $(this).find("img").attr("src", "__TMPL__/public/assets/images/fangkuang.png");
        }
751 752
        //判断订单是否全选了
        check();
王晓刚 authored
753
    });
754 755

    function check() {
756 757 758
        var index = $(".log_three_tab_top .log_three_tab_one").index($('.aaa'));
        var length = $(".log_three_list_contant").eq(index).find('.log_three_list_top_lo img').length;
        var l = 0;
759
        for (var n = 0; n < length; n++) {
760
            console.log($(".log_three_list_contant").eq(index).find('.log_three_list_top_lo img').eq(n).attr('src'));
761
            if ($(".log_three_list_contant").eq(index).find('.log_three_list_top_lo img').eq(n).attr('src') == "__TMPL__/public/assets/images/xuanzhong (1).png") {
762 763 764
                l++
            }
        }
765 766 767 768 769
        console.log('@@@@@' + l + '@@@@@' + length);
        if (l == length) {
            $('.log_three_fixed_left_one img').attr('src', "__TMPL__/public/assets/images/xuanzhong (1).png")
        } else {
            $('.log_three_fixed_left_one img').attr('src', "__TMPL__/public/assets/images/fangkuang.png")
770 771
        }
    }
772
王晓刚 authored
773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793
    $(".log_three_fixed_left_one").click(function () {
        if (
            $(this)
                .find("img")
                .attr("src") == "__TMPL__/public/assets/images/fangkuang.png"
        ) {
            $(this)
                .find("img")
                .attr("src", "__TMPL__/public/assets/images/xuanzhong (1).png");
            $(".log_three_list_top_lo")
                .find("img")
                .attr("src", "__TMPL__/public/assets/images/xuanzhong (1).png");
        } else {
            $(this)
                .find("img")
                .attr("src", "__TMPL__/public/assets/images/fangkuang.png");
            $(".log_three_list_top_lo")
                .find("img")
                .attr("src", "__TMPL__/public/assets/images/fangkuang.png");
        }
    });
794
王晓刚 authored
795 796 797 798 799
    $(".log_three_select_peisong").click(function () {
        $(".tx_mask").css({
            display: "block"
        });
    });
王晓刚 authored
800 801

    //统一配送
王晓刚 authored
802
    $(".log_three_select_tongyi").click(function () {
王晓刚 authored
803 804 805 806
        $(".tx_mask_tongyi").css({
            display: "block"
        });
    })
anyv authored
807
    $(".tx_mask_tongyi .three_modal_kuaidi_name").click(function () {
王晓刚 authored
808 809 810 811 812 813 814
        var index = $(this).index();
        $(this).addClass('there_unActive').siblings().removeClass('there_unActive');
        $('.log_three_select_contant').text($(this).text()).css("color", "#333");
        $(".tx_mask_tongyi").hide();
        $("#is_courier").val($(this).attr('data-id'))
    })
    //选择快递方式
王晓刚 authored
815
    $(".log_psong_select").click(function () {
王晓刚 authored
816 817 818 819
        $(".tx_mask_kuaidi").css({
            display: "block"
        });
    });
anyv authored
820
    $(".tx_mask_kuaidi .get_Go").click(function () {
王晓刚 authored
821
        var index = $(this).index();
anyv authored
822
        console.log($(this).text());
823
        $(this).addClass('there_unActive').siblings().removeClass('there_unActive');
anyv authored
824
        $('.get_Gofo').text($(this).text()).css("color", "#333");
王晓刚 authored
825
        $(".tx_mask_kuaidi").hide();
anyv authored
826
//        $('#logistic_name').val($(this).attr('data-name'))
王晓刚 authored
827
    });
王晓刚 authored
828
    var index = $(".log_three_bottom").index();
王晓刚 authored
829
    $("body").on('click', '.log_three_bottom', function () {
王晓刚 authored
830 831 832 833 834 835 836 837 838 839 840
        $(".tx_maskone").css({
            display: "block"
        });
    });
    $('body').on('click', ".there_class div", function () {
        var index2 = $(this).index();
        $(this).addClass("there_unActive").siblings().removeClass("there_unActive");
        if ($xuexiao == undefined) {
            alert('请选择学校')
        } else if ($(this).hasClass("there_unActive")) {
            var banji = $(this).text();
王晓刚 authored
841
            $('.log_three_select_school2').text($xuexiao + ' ' + "-" + ' ' + banji);
王晓刚 authored
842 843 844 845 846 847 848 849 850 851 852 853
            $(".log_three_select_school2").css("color", "#333")
            $(".tx_mask_school").hide();
            $('#school').val($xuexiao);
            $('#grade').val(banji);
        }
    })
    // 关闭弹窗
    $(document).mouseup(function (e) {
        var _con = $('.tx_maskCon_school');
        if (!_con.is(e.target) && _con.has(e.target).length === 0) {
            $('.tx_mask_school').hide()
        }
王晓刚 authored
854
    });
王晓刚 authored
855 856

    function search() {
王晓刚 authored
857 858 859
        var school = $('#school').val();
        var grade = $('#grade').val();
        var state = $('.log_three_tab_top .aaa').attr('data-state');
860
        var is_courier = $('#is_courier').val();
4  
anyv authored
861
王晓刚 authored
862 863 864 865 866 867
        $.ajax({
            'url': "{:url('order_salesman/getOrderSalesman')}",
            'type': "GET",
            'data': {'school': school, 'grade': grade, 'state': state, 'is_courier': is_courier},
            'success': (function (data) {
                var index = $('.log_three_tab_top div').index($('.aaa'));
王晓刚 authored
868 869
                console.log(3333);
                console.log(data);
王晓刚 authored
870 871
                if (data.code == 1) {
                    var result = data.data;
872 873
                    console.log(result);
                    if (result == 0) {
874
                        var html = "<div style=\"text-align: center;width: 100%;height:100%;margin:0 auto;\">暂无数据</div>";
875
                    } else {
876 877
                        var html = '';
                    }
王晓刚 authored
878 879 880 881 882 883 884
                    for (var i = 0; i < result.length; i++) {
                        if (result[i]['state'] == 2) {
                            var state = '待发货';
                            if (result[i]['is_courier'] == 1) {
                                var html_bottom = "<div class=\"log_three_bottom_btn\"><div class=\"log_three_bottom send\" data-indent-id=\"" + result[i].id + "\" data-is_courier=\"" + result[i].is_courier + "\">\n" +
                                    "\t\t\t\t\t\t\t\t\t\t立即发货\n" +
                                    "\t\t\t\t\t\t\t\t\t</div></div>";
王晓刚 authored
885
                            } else {
王晓刚 authored
886 887 888
                                var html_bottom = "<div class=\"log_three_bottom_btn\"><div class=\"log_three_bottom send\" data-indent-id=\"" + result[i].id + "\" data-is_courier=\"" + result[i].is_courier + "\">\n" +
                                    "\t\t\t\t\t\t\t\t\t\t立即发货\n" +
                                    "\t\t\t\t\t\t\t\t\t</div></div>";
王晓刚 authored
889
                            }
王晓刚 authored
890 891 892 893 894 895 896 897 898
                        } else if (result[i]['state'] == 5) {
                            var state = '已发货';
                            if (result[i]['is_courier'] == 2) {
                                var html_bottom = "<a href=\"{:url('logistics/index','',false,true)}/indent_id/" + result[i].id + "\">\n" +
                                    "\t\t\t\t\t\t\t\t\t\t\t<div class=\"log_three_bottom_btn\"><div class=\"log_three_bottom\" data-indent-id=\"" + result[i].id + "\">\n" +
                                    "\t\t\t\t\t\t\t\t\t\t\t\t查看物流\n" +
                                    "\t\t\t\t\t\t\t\t\t\t\t</div></div>\n" +
                                    "\t\t\t\t\t\t\t\t\t\t</a>";
                            } else {
899
                                var html_bottom = "<div class=\"take_one\" data-indent-id=\"" + result[i].id + "\">\n" +
王晓刚 authored
900 901
                                    "                                    完成\n" +
                                    "                                </div>";
902
                            }
王晓刚 authored
903 904
                        } else {
                            var state = '已完成';
王晓刚 authored
905
                            var html_bottom = "";
王晓刚 authored
906 907 908 909
                        }
                        var indent_goods_data = result[i].indent_goods;
                        var indent_goods_html = '';
                        for (var i3 = 0; i3 < indent_goods_data.length; i3++) {
910 911 912 913 914 915 916 917 918 919 920 921
                            // indent_goods_html += "<div class=\"log_three_list_center\" style=\"display: flex;justify-content: flex-start;\">\n" +
                            //     "                            <div class=\"log_three_list_center_left\" style=\"width: 1.44rem;height:1.44rem\">\n" +
                            //     "                                <img src=\"" + indent_goods_data[i3].thumbnail + "\" alt=\"\" style=\"width: 100%;height: 100%;\"/>\n" +
                            //     "                            </div>\n" +
                            //     "                            <div class=\"log_three_list_center_right\" style=\"margin-left: 0.16rem;\">\n" +
                            //     "                                <div class=\"log_three_center_one\">\n" +
                            //     "                                    " + indent_goods_data[i3].book_name + "\n" +
                            //     "                                </div>\n" +
                            //     "                                <div class=\"log_three_center_two\">×" + indent_goods_data[i3].number + "</div>\n" +
                            //     "                                <div class=\"log_three_center_three\"><span>¥</span>" + indent_goods_data[i3].price + "</div>\n" +
                            //     "                            </div>\n" +
                            //     "                        </div>";
922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971
                            if(result[i].is_courier == 2){
                                indent_goods_html += "<div class=\"dingdan_detail\">\n" +
                                    "                                <div class=\"log_three_list_center\" style=\"display: flex;justify-content: flex-start;\">\n" +
                                    "                                    <div class=\"log_three_list_center_left\" style=\"width: 1.44rem;height:1.44rem\">\n" +
                                    "                                        <img src=\""+indent_goods_data[i3].thumbnail+"\" alt=\"\"\n" +
                                    "                                             style=\"width: 100%;height: 100%;\"/>\n" +
                                    "                                    </div>\n" +
                                    "                                    <div class=\"right_dingdan\">\n" +
                                    "                                        <div class=\"right_dingdan_top\">\n" +
                                    "                                            <div class=\"right_dingdan_one\">"+indent_goods_data[i3].book_name+"</div>\n" +
                                    "                                            <div class=\"right_dingdan_two\">¥"+indent_goods_data[i3].price+"</div>\n" +
                                    "                                        </div>\n" +
                                    "                                        <div class=\"right_dingdan_center\">\n" +
                                    "                                            <div class=\"right_dindan_three right_dingdan_one\">x"+indent_goods_data[i3].number+"</div>\n" +
                                    "                                        </div>\n" +
                                    "\n" +
                                    "                                        <div class=\"right_dingdan_four right_dingdan_one\">地址:"+result[i].region+" "+result[i].detailed+"\n" +
                                    "                                        </div>\n" +
                                    "                                        <div class=\"right_dingdan_four right_dingdan_one\" style=\"margin-top: -0.05rem;\">\n" +
                                    "                                            "+result[i].name+"电话:"+result[i].phone+"\n" +
                                    "                                        </div>\n" +
                                    "                                    </div>\n" +
                                    "                                </div>\n" +
                                    "                            </div>";
                            }else{
                                indent_goods_html += "<div class=\"dingdan_detail\">\n" +
                                    "                                <div class=\"log_three_list_center\" style=\"display: flex;justify-content: flex-start;\">\n" +
                                    "                                    <div class=\"log_three_list_center_left\" style=\"width: 1.44rem;height:1.44rem\">\n" +
                                    "                                        <img src=\""+indent_goods_data[i3].thumbnail+"\" alt=\"\"\n" +
                                    "                                             style=\"width: 100%;height: 100%;\"/>\n" +
                                    "                                    </div>\n" +
                                    "                                    <div class=\"right_dingdan\">\n" +
                                    "                                        <div class=\"right_dingdan_top\">\n" +
                                    "                                            <div class=\"right_dingdan_one\">"+indent_goods_data[i3].book_name+"</div>\n" +
                                    "                                            <div class=\"right_dingdan_two\">¥"+indent_goods_data[i3].price+"</div>\n" +
                                    "                                        </div>\n" +
                                    "                                        <div class=\"right_dingdan_center\">\n" +
                                    "                                            <div class=\"right_dindan_three right_dingdan_one\">x"+indent_goods_data[i3].number+"</div>\n" +
                                    "                                        </div>\n" +
                                    "\n" +
                                    "                                        <div class=\"right_dingdan_four right_dingdan_one\">地址:"+result[i].school+" "+result[i].grade+"\n" +
                                    "                                            "+result[i].class+"\n" +
                                    "                                        </div>\n" +
                                    "                                        <div class=\"right_dingdan_four right_dingdan_one\" style=\"margin-top: -0.05rem;\">\n" +
                                    "                                            "+result[i].name+"电话:"+result[i].phone+"\n" +
                                    "                                        </div>\n" +
                                    "                                    </div>\n" +
                                    "                                </div>\n" +
                                    "                            </div>";
                            }
王晓刚 authored
972 973 974 975 976 977
                        }
                        if (is_courier == 1) {
                            html += "<div class=\"log_three_list order_" + result[i].id + "\">\n" +
                                "\t\t\t\t\t\t\t<div class=\"log_three_list_top\">\n" +
                                "\t\t\t\t\t\t\t\t<div class=\"log_three_list_top_left\">\n" +
                                "\t\t\t\t\t\t\t\t\t<div class=\"log_three_list_top_lo\">\n" +
978
                                "\t\t\t\t\t\t\t\t\t\t<img src=\"__TMPL__/public/assets/images/fangkuang.png\" data-indent-id=\"" + result[i].id + "\" alt=\"\" />\n" +
王晓刚 authored
979 980 981 982 983 984 985 986 987 988 989 990 991
                                "\t\t\t\t\t\t\t\t\t</div>\n" +
                                "\t\t\t\t\t\t\t\t\t<div class=\"log_three_list_top_lt\">\n" +
                                "\t\t\t\t\t\t\t\t\t\t<div class=\"log_three_zhongbiao\">\n" +
                                "\t\t\t\t\t\t\t\t\t\t\t<img src=\"__TMPL__/public/assets/images/52.png\" alt=\"\" />\n" +
                                "\t\t\t\t\t\t\t\t\t\t</div>\n" +
                                "\t\t\t\t\t\t\t\t\t\t<div class=\"log_three_shijian\">\n" +
                                "\t\t\t\t\t\t\t\t\t\t\t" + result[i].pay_time + "\n" +
                                "\t\t\t\t\t\t\t\t\t\t</div>\n" +
                                "\t\t\t\t\t\t\t\t\t</div>\n" +
                                "\t\t\t\t\t\t\t\t</div>\n" +
                                "\t\t\t\t\t\t\t\t<div class=\"log_three_list_top_right\">\n" +
                                "\t\t\t\t\t\t\t\t\t\t" + state + "\n" +
                                "\t\t\t\t\t\t\t\t</div>\n" +
992 993 994
                                "\t\t\t\t\t\t\t</div><a href=\"{:url('get_one','',false,true)}/id/" + result[i].id + "\"><div class=\"dingdan_detail_top\">\n" +
                                "                            <div class=\"dingdan_detail_hao\">订单号:"+result[i].order_number+"</div>\n" +
                                "                        </div>\n" + indent_goods_html + "</a>" +
王晓刚 authored
995
                                "\t\t\t\t\t\t<div class=\"log_three_bottom_btn\">" + html_bottom + "</div></div>";
王晓刚 authored
996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014
                        } else if (is_courier == 2) {
                            html += "<div class=\"log_three_list order_" + result[i].id + "\">\n" +
                                "\t\t\t\t\t\t\t<div class=\"log_three_list_top\">\n" +
                                "\t\t\t\t\t\t\t\t<div class=\"log_three_list_top_left\">\n" +
                                // "\t\t\t\t\t\t\t\t\t<div class=\"log_three_list_top_lo\">\n" +
                                // "\t\t\t\t\t\t\t\t\t\t<img src=\"__TMPL__/public/assets/images/fangkuang.png\" alt=\"\" />\n" +
                                // "\t\t\t\t\t\t\t\t\t</div>\n" +
                                "\t\t\t\t\t\t\t\t\t<div class=\"log_three_list_top_lt\">\n" +
                                "\t\t\t\t\t\t\t\t\t\t<div class=\"log_three_zhongbiao\">\n" +
                                "\t\t\t\t\t\t\t\t\t\t\t<img src=\"__TMPL__/public/assets/images/52.png\" alt=\"\" />\n" +
                                "\t\t\t\t\t\t\t\t\t\t</div>\n" +
                                "\t\t\t\t\t\t\t\t\t\t<div class=\"log_three_shijian\">\n" +
                                "\t\t\t\t\t\t\t\t\t\t\t" + result[i].pay_time + "\n" +
                                "\t\t\t\t\t\t\t\t\t\t</div>\n" +
                                "\t\t\t\t\t\t\t\t\t</div>\n" +
                                "\t\t\t\t\t\t\t\t</div>\n" +
                                "\t\t\t\t\t\t\t\t<div class=\"log_three_list_top_right\">\n" +
                                "\t\t\t\t\t\t\t\t\t\t" + state + "\n" +
                                "\t\t\t\t\t\t\t\t</div>\n" +
1015 1016 1017
                                "\t\t\t\t\t\t\t</div><a href=\"{:url('get_one','',false,true)}/id/" + result[i].id + "\"><div class=\"dingdan_detail_top\">\n" +
                                "                            <div class=\"dingdan_detail_hao\">订单号:"+result[i].order_number+"</div>\n" +
                                "                        </div>\n" + indent_goods_html + "</a>" +
王晓刚 authored
1018
                                "\t\t\t\t\t\t<div class=\"log_three_bottom_btn\">" + html_bottom + "</div></div>";
王晓刚 authored
1019 1020
                        }
                    }
1021
                    $('.count').html(i);
王晓刚 authored
1022 1023 1024 1025 1026 1027 1028 1029
                    $('.log_three_list_contant').eq(index).html(html);
                    update();
                } else {
                    alert('未知错误');
                }
            }),
            'error': (function () {
                alert('与服务器断开连接');
王晓刚 authored
1030
            })
王晓刚 authored
1031
        })
王晓刚 authored
1032 1033
        // }
    }
王晓刚 authored
1034
王晓刚 authored
1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052
    $(function () {
        $('.school').click(function () {
            var school_id = $(this).attr('data-id');
            $.ajax({
                url: "{:url('order_salesman/getGradeClass')}",
                type: 'GET',
                data: {'school_id': school_id},
                success: (function (data) {
                    if (data.code == 1) {
                        var result = data.data;
                        var html = '';
                        for (var i = 0; i < result.length; i++) {
                            var i2 = Number(result[i].start);
                            var j = Number(result[i].end);
                            for (i2; i2 <= j; i2++) {
                                // if(i == 0){
                                //     html += "<div class=\"three_model_school_name there_unActive\" data-id=\""+result[i].id+"\">"+result[i].grade+"—"+i2+"</div>";
                                // }
anyv authored
1053
                                html += "<div class=\"three_model_class_name\" data-id=\"" + result[i].id + "\">" + result[i].grade + "-" + i2 + "班</div>";
王晓刚 authored
1054 1055 1056 1057 1058 1059 1060 1061 1062 1063
                            }
                        }
                        $('.grade').html(html);
                    } else {
                        alert(data.msg);
                    }
                })
            })
        })
        $('.search').click(function () {
王晓刚 authored
1064
            search();
王晓刚 authored
1065 1066
        });
        //发货
王晓刚 authored
1067
        $("body").on('click', '.send', function () {
王晓刚 authored
1068 1069
            var indent_id = $(this).attr('data-indent-id');
            var is_courier = $(this).attr('data-is_courier');
王晓刚 authored
1070
            if (is_courier == 1) {
王晓刚 authored
1071 1072 1073
                //统一配送
                $('.time').show();
                $('.logistic').hide();
王晓刚 authored
1074
            } else if (is_courier == 2) {
王晓刚 authored
1075 1076 1077
                //快递
                $('.time').hide();
                $('.logistic').show();
王晓刚 authored
1078
            }
王晓刚 authored
1079 1080 1081
            $('.confirm').attr('data-is_courier', is_courier);
            $('.confirm').attr('data-indent-id', indent_id);
            $('.confirm').attr('data-is_courier', is_courier);
王晓刚 authored
1082
        });
王晓刚 authored
1083
        //点击确认
王晓刚 authored
1084
        $("body").on('click', '.confirm', function () {
王晓刚 authored
1085 1086 1087 1088 1089 1090
            var is_courier = $(this).attr('data-is_courier');
            var start_time = $('#start_time').val();
            var end_time = $('#end_time').val();
            var logistic_name = $('#logistic_name').val();
            var logistic_code = $('#logistic_code').val();
            var indent_id = $(this).attr('data-indent-id');
王晓刚 authored
1091 1092 1093
            if (is_courier == 1) {
                if (start_time == '') {
                    alert('请填写配送时间');
1094
                    return false;
王晓刚 authored
1095 1096
                } else if (end_time == '') {
                    alert('请填写配送时间');
1097
                    return false;
王晓刚 authored
1098
                }
王晓刚 authored
1099 1100 1101
            } else if (is_courier == 2) {
                if (logistic_name == '') {
                    alert('请填写快递公司');
1102
                    return false;
王晓刚 authored
1103 1104
                } else if (logistic_code == '') {
                    alert('请填写快递单号');
1105
                    return false;
王晓刚 authored
1106
                }
王晓刚 authored
1107 1108
            } else if (is_courier == '') {
                alert('未知错误');
1109
                return false;
王晓刚 authored
1110 1111
            }
            $.ajax({
王晓刚 authored
1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124
                url: "{:url('order_salesman/send')}",
                type: "GET",
                data: {
                    'start_time': start_time,
                    'end_time': end_time,
                    'logistic_name': logistic_name,
                    'logistic_code': logistic_code,
                    'is_courier': is_courier,
                    'indent_id': indent_id
                },
                success: function (res) {
                    if (res.code == 1) {
                        $('.order_' + indent_id).remove();
1125 1126 1127 1128 1129 1130 1131
                        $(".tx_maskone").css({
                            display: "none"
                        });
                        $(".tx_mask").css({
                            display: "none"
                        });
                    }
王晓刚 authored
1132 1133
                    alert(res.msg)
                },
王晓刚 authored
1134
                error: function (res) {
王晓刚 authored
1135 1136 1137 1138
                    alert('与服务器断开连接')
                }
            })
        });
王晓刚 authored
1139
        $('body').on('click', '.unify_all', function () {
1140
            var index = $(".log_three_tab_top .log_three_tab_one").index($('.aaa'));
1141
            var length = $(".log_three_list_contant").eq(index).find('.log_three_list_top_lo img').length - 1;
王晓刚 authored
1142
            var arr = [];
王晓刚 authored
1143 1144
            for (var i = 0; i <= length; i++) {
                if ($('.log_three_list_top_lo img').eq(i).attr('src') == "__TMPL__/public/assets/images/xuanzhong (1).png") {
王晓刚 authored
1145 1146 1147 1148
                    arr.push($('.log_three_list_top_lo img').eq(i).attr('data-indent-id'));
                }
            }
            $('.confirm2').attr('data-indent-id', arr.join(","));
王晓刚 authored
1149
            var type = $('.unify_all').attr('data-type');
王晓刚 authored
1150
            if (arr.length != 0) {
1151
                if (type == 1) {
王晓刚 authored
1152
                    $.ajax({
1153 1154 1155 1156
                        url: "{:url('take_all')}",
                        type: "GET",
                        data: {'indent_ids': arr.join(",")},
                        success: function (res) {
王晓刚 authored
1157
                            if (res.code == 1) {
1158 1159
                                $(arr).each(function (i, vo) {
                                    $('.order_' + vo).remove();
王晓刚 authored
1160 1161 1162 1163 1164 1165 1166
                                })
                                alert('操作成功')
                            } else {
                                alert(res.msg);
                            }
                        }
                    })
1167
                } else {
王晓刚 authored
1168 1169
                    $('.tx_masktwo').show();
                }
王晓刚 authored
1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198
            } else {
                alert('请至少选择一个订单');
            }
        });
        $('.confirm2').click(function () {
            var start_time2 = $('#start_time2').val();
            var end_time2 = $('#end_time2').val();
            var indent_ids = $(this).attr('data-indent-id');
            if (indent_ids == '') {
                alert('请至少选择一个订单');
            } else if (start_time2 == '') {
                alert('请选择配送时间')
            } else if (end_time2 == '') {
                alert('请选择配送时间')
            } else {
                $.ajax({
                    url: "{:url('order_salesman/send_all')}",
                    type: "GET",
                    data: {'start_time2': start_time2, 'end_time2': end_time2, 'indent_ids': indent_ids},
                    success: function (res) {
                        if (res.code == 1) {
                            alert('发货成功')
                        } else {
                            alert(res.msg);
                        }
                    }
                })
            }
        });
1199 1200
        update();
1201
        $('body').on('click', '.take_one', function () {
王晓刚 authored
1202 1203
            var indent_id = $(this).attr('data-indent-id');
            $.ajax({
1204 1205 1206 1207 1208 1209
                url: "{:url('take_one')}",
                type: "GET",
                data: {'indent_id': indent_id},
                success: function (res) {
                    if (res.code == 1) {
                        $('.order_' + indent_id).remove();
王晓刚 authored
1210
                        alert('操作成功')
1211
                    } else {
王晓刚 authored
1212 1213 1214 1215 1216
                        alert(res.msg)
                    }
                }
            })
        })
王晓刚 authored
1217
    })
王晓刚 authored
1218 1219

    function update() {
1220
        var is_courier = $('#is_courier').val();
王晓刚 authored
1221
        var index = $('.log_three_tab_top').children('.aaa').index();
王晓刚 authored
1222
        if (is_courier == 1 && index == 0) {
1223
            $('.log_three_list_fixed').show();
王晓刚 authored
1224
            $('.unify_all').text('统一发货');
1225
            $('.unify_all').attr('data-type', '')
王晓刚 authored
1226
        } else if (is_courier == 2 || (index != 0 && index != 1)) {
1227
            $('.log_three_list_fixed').hide();
1228
        } else if (index == 1) {
王晓刚 authored
1229
            $('.unify_all').text('统一完成');
1230
            $('.unify_all').attr('data-type', 1)
1231 1232
        }
    }
王晓刚 authored
1233 1234
</script>
</body>
1235 1236

</html>