Commit f7158a41 authored by agping's avatar agping

委托转铺

parent b8dce155
...@@ -19,6 +19,12 @@ ...@@ -19,6 +19,12 @@
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-striped table-bordered table-hover table-condensed"> <table class="table table-striped table-bordered table-hover table-condensed">
<thead> <thead>
<tr>
<td colspan="14" class="maintable-top-sub-tr">
<a class="btn btn-info liudan_pic_btn" id="our">我的</a>
<a class="btn btn-default liudan_pic_btn" id="is_show_all">全部</a>
</td>
</tr>
<tr> <tr>
<td colspan="9"> <td colspan="9">
<form id="form_search"> <form id="form_search">
......
...@@ -2,9 +2,10 @@ define (['doT', 'text!temp/transfer_template_tpl.html', 'css!style/home.css','pa ...@@ -2,9 +2,10 @@ define (['doT', 'text!temp/transfer_template_tpl.html', 'css!style/home.css','pa
user = { user = {
pageNo: 1, /*第几页*/ pageNo: 1, /*第几页*/
pageSize: 10, /*每页显示多少条*/ pageSize: 10, /*每页显示多少条*/
urls: '', urls: '',
url: 1,
init: function () { init: function () {
$('#is_guest').hide();
;(function($){ ;(function($){
$.fn.datetimepicker.dates['zh-CN'] = { $.fn.datetimepicker.dates['zh-CN'] = {
...@@ -69,6 +70,24 @@ define (['doT', 'text!temp/transfer_template_tpl.html', 'css!style/home.css','pa ...@@ -69,6 +70,24 @@ define (['doT', 'text!temp/transfer_template_tpl.html', 'css!style/home.css','pa
$("#submit_follow").click(function () { $("#submit_follow").click(function () {
user.addFollow(); user.addFollow();
}); });
$(document).on('click', '.maintable-top-sub-tr>a', function(e){
e.preventDefault();
e.stopPropagation();
var _this = $(this);
_this.removeClass('btn-default').addClass('btn-info').siblings().removeClass('btn-info').addClass('btn-default');
user.mainTabIndex = _this.index();
user.getList(1);
});
$("#our").click(function () {
user.url = 1;
$('#is_guest').hide();//我的委托转铺列表 隐藏是否有客方
});
$("#is_show_all").click(function () {
user.url = 0;
$('#is_guest').show();
});
$('#datetimepicker').datetimepicker({ $('#datetimepicker').datetimepicker({
format: 'yyyy-MM-dd', format: 'yyyy-MM-dd',
language: 'zh-CN', language: 'zh-CN',
...@@ -81,7 +100,11 @@ define (['doT', 'text!temp/transfer_template_tpl.html', 'css!style/home.css','pa ...@@ -81,7 +100,11 @@ define (['doT', 'text!temp/transfer_template_tpl.html', 'css!style/home.css','pa
getList: function (pageNo) { getList: function (pageNo) {
user.pageNo = pageNo; user.pageNo = pageNo;
var params = {}; var params = {};
params.agent_type = $("#is_guest").val();//是否有客方筛选 if(user.url == 1){
params.agent_id = JSON.parse(decodeURIComponent(localStorage.getItem('pcUserInfo'))).id;//是否传经纪人id
}else{
params.agent_type = $("#is_guest").val();//是否有客方筛选
}
params.start_date = $("#start_date").val(); params.start_date = $("#start_date").val();
params.end_date = $("#end_date").val(); params.end_date = $("#end_date").val();
params.name = $("#name").val(); params.name = $("#name").val();
......
<script id="transfer_list_tpl" type="text/template"> <script id="transfer_list_tpl" type="text/template">
[% if(it) { %] [% if(it.length) { %]
[% for(var item in it){ %] [% for(var item in it){ %]
<tr> <tr>
<!--<td>[%= it[item]["shop_name"] %]</td>--> <!--<td>[%= it[item]["shop_name"] %]</td>-->
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment