HW 3 years ago
parent
commit
a6167ae0b6

+ 868 - 0
js/component/manageCenter/customer/NEW/intentionCustomer/channel.jsx

@@ -0,0 +1,868 @@
+import React,{Component} from "react";
+import {
+    AutoComplete,
+    Button,
+    Cascader,
+    DatePicker,
+    Icon,
+    Input,
+    message, Modal,
+    Select,
+    Spin,
+    Table,
+    Tabs,
+    Upload
+} from "antd";
+import {ChooseList} from "../../../order/orderNew/chooseList";
+import $ from "jquery/src/ajax";
+import {
+    getSocialAttribute,
+    ShowModal
+} from "@/tools.js";
+import { citySelect, provinceList } from '@/NewDicProvinceList';
+import moment from "moment";
+import FollowDetail from "./followDetail";
+import IntentionDetail from "./intentionDetail/intentionDetail";
+import TransferRecords from './transferRecords';
+import DuplicateData from './duplicateData';
+
+const {TabPane} = Tabs;
+const { RangePicker } = DatePicker;
+
+class Channel extends Component{
+    constructor(props) {
+        super(props);
+        this.state={
+            columns: [
+                {
+                    title: "客户名称",
+                    dataIndex: "userName",
+                    key: "userName",
+                },
+                {
+                    title: "地区",
+                    dataIndex: "locationProvince",
+                    key: "locationProvince",
+                },
+                {
+                    title: "社会性质",
+                    dataIndex: "societyTag",
+                    key: "societyTag",
+                    render: (text) => {
+                        return getSocialAttribute(text);
+                    },
+                },
+                {
+                    title: "渠道专员",
+                    dataIndex: "aName",
+                    key: "aName",
+                },
+                {
+                    title: "客户联系人",
+                    dataIndex: "contacts",
+                    key: "contacts",
+                },
+                {
+                    title: "联系电话",
+                    dataIndex: "contactMobile",
+                    key: "contactMobile",
+                },
+                {
+                    title: "渠道初始时间",
+                    dataIndex: "createTimes",
+                    key: "createTimes",
+                },
+                {
+                    title: "分配状态",
+                    dataIndex: "status",
+                    key: "status",
+                    render: (text) => (
+                        text === 0 ? '未分配' :
+                            text === 1 ? '已存在' :
+                                text === 2 ? '已分配' : ''
+                    )
+                },
+
+            ],
+            changeList:[],
+            dataSource:[],
+            pagination: {
+                defaultCurrent: 1,
+                defaultPageSize: 10,
+                showQuickJumper: true,
+                pageSize: 10,
+                onChange: function (page) {
+                    this.loadData(page);
+                }.bind(this),
+                showTotal: function (total) {
+                    return "共" + total + "条数据";
+                },
+            },
+            pageNo:1,
+            listLoading:false,
+
+
+            selectedRowKeys:[],
+            selectedRows:[],
+            modalVisible:false,
+            recordt:'',
+
+
+            nameSearch:'',
+            statusSearch:undefined,
+            provinceSearch:undefined,
+            addressSearch:[],
+            releaseDate:[],
+
+            upLoad: {
+                name: "file",
+                action: globalConfig.context + "/api/user/channel/import",
+                headers: {
+                    authorization: "authorization-text"
+                },
+                onChange: info => {
+                    if (info.file.status === "done") {
+                        if (info.file.response && info.file.response.error.length === 0) {
+                            if(info.file.response.data.list.length > 0){
+                                this.setState({
+                                    duplicateData: [],
+                                    duplicateDataVisible: true
+                                })
+                            }else{
+                                message.success("导入成功!");
+                                this.loadData();
+                            }
+                        } else {
+                            message.warning(info.file.response.error[0].message);
+                        }
+                    }
+                }
+            },
+
+            followData: '',
+            visitModul: false,
+            categoryArr:[],
+            tabsKey:'',
+            reasonsTransfer:''
+        }
+        this.loadData = this.loadData.bind(this);
+        this.search = this.search.bind(this);
+        this.reset = this.reset.bind(this);
+        this.changeList = this.changeList.bind(this);
+        this.download = this.download.bind(this);
+        this.category = this.category.bind(this);
+        this.closeDesc = this.closeDesc.bind(this);
+        this.guidanceRead = this.guidanceRead.bind(this);
+        this.tableRowClick = this.tableRowClick.bind(this);
+        this.detailCloseDesc = this.detailCloseDesc.bind(this);
+        this.supervisor = this.supervisor.bind(this);
+        this.httpChange = this.httpChange.bind(this);
+        this.blurChange = this.blurChange.bind(this);
+        this.selectAuto = this.selectAuto.bind(this);
+        this.changeAssigner = this.changeAssigner.bind(this);
+    }
+
+    componentDidMount() {
+        //城市
+        let provinces = [];
+        provinceList.map(function (item) {
+            var id = String(item.id);
+            provinces.push(
+                <Select.Option value={id} key={item.name}>
+                    {item.name}
+                </Select.Option>
+            );
+        });
+        this.setState({
+            provinces
+        })
+        this.loadData();
+        this.category();
+
+        if(this.props.followUp){
+            this.state.columns.push({
+                title: "跟进操作",
+                dataIndex: "abc",
+                key: "abc",
+                render: (text, record, index) => {
+                    return (
+                        <div style={{
+                            display: 'flex',
+                            flexFlow:'row',
+                            alignItems:'center',
+                        }}>
+                            <Button
+                                onClick={(e) => {
+                                    e.stopPropagation();
+                                    if(this.props.isEditGuidanceLv){
+                                        this.visit(record);
+                                    }else{
+                                        this.tableRowClick(record);
+                                    }
+
+                                }}
+                                type="primary"
+                            >
+                                {this.props.isEditGuidanceLv ? '客户跟进' : '查看指导'}
+                            </Button>
+                        </div>
+                    );
+                },
+            });
+            this.state.columns.push({
+                title: "指导意见",
+                dataIndex: "guidance",
+                key: "guidance",
+                render: (text, record, index) => {
+                    return (
+                        <div style={{
+                            display: 'flex',
+                            flexFlow:'row',
+                            alignItems:'center',
+                        }}>
+                            {/*指导 0无 1未读 2已读*/}
+                            {text === 1 || text === 2 ? <Button
+                                style={text === 1 ? {
+                                    background:'#F00000',
+                                    borderColor:'#F00000'
+                                } : {}}
+                                onClick={(e)=>{
+                                    e.stopPropagation();
+                                    this.guidanceRead(record.uid).then(()=>{
+                                        this.setState({
+                                            tabsKey:"4",
+                                        },()=>{
+                                            this.tableRowClick(record)
+                                        })
+                                    })
+                                }}
+                                type="primary"
+                            >
+                                {text === 1 ? '未读' : '查看'}
+                            </Button> : <div>暂无指导</div>}
+                        </div>
+                    );
+                },
+            });
+            this.setState({
+                columns:this.state.columns
+            })
+        }
+    }
+
+    visit(e) {
+        this.setState({
+            followData: e,
+            visitModul: true,
+        });
+    }
+
+    loadData(pageNo) {
+        this.setState({
+            listLoading: true,
+        });
+        $.ajax({
+            method: "post",
+            dataType: "json",
+            crossDomain: false,
+            url: globalConfig.context + '/api/admin/customer/listChannelCustomer',
+            data: {
+                pageNo: pageNo || 1,
+                pageSize: this.state.pagination.pageSize,
+                name: this.state.nameSearch,
+                status:this.state.statusSearch,
+                province: !this.state.addressSearch.length
+                    ? this.state.provinceSearch
+                    : this.state.addressSearch[0],
+                city: !this.state.addressSearch.length
+                    ? ""
+                    : this.state.addressSearch[1],
+                startTime: this.state.releaseDate[0],
+                endTime: this.state.releaseDate[1],
+            },
+            success: function (data) {
+                ShowModal(this);
+                let theArr = [];
+                if (data.error.length > 0) {
+                    message.warning(data.error[0].message);
+                } else {
+                    for (let i = 0; i < data.data.list.length; i++) {
+                        let thisdata = data.data.list[i];
+                        let diqu =
+                            (thisdata.province == null ? "" : thisdata.province) +
+                            (thisdata.city == null ? "" : "-" + thisdata.city) +
+                            (thisdata.area == null ? "" : "-" + thisdata.area);
+                        thisdata.key = i;
+                        thisdata.id = thisdata.uid;
+                        thisdata.lastFollowTime = thisdata.lastFollowTime &&
+                            thisdata.lastFollowTime.split(" ")[0];
+                        thisdata.transferTime= thisdata.transferTime && thisdata.transferTime.split(" ")[0];
+                        thisdata.surplusFollowTime = thisdata.surplusFollowTime && thisdata.surplusFollowTime.split(" ")[0];
+                        thisdata.surplusSignTime = thisdata.surplusSignTime && thisdata.surplusSignTime.split(" ")[0];
+                        thisdata.locationProvince = diqu;
+                        theArr.push(thisdata);
+                    }
+                    this.state.pagination.current = data.data.pageNo;
+                    this.state.pagination.total = data.data.totalCount;
+                    this.setState({
+                        pageNo: data.data.pageNo,
+                        dataSource: theArr,
+                        pagination: this.state.pagination,
+                    })
+                }
+            }.bind(this),
+        }).always(
+            function () {
+                this.setState({
+                    listLoading: false,
+                });
+            }.bind(this)
+        );
+    }
+
+    search(){
+        this.loadData();
+    }
+
+    reset(){
+        this.setState({
+            nameSearch:'',
+            provinceSearch:undefined,
+            addressSearch:[],
+            releaseDate:[],
+            statusSearch:undefined,
+        })
+    }
+
+    download() {
+        window.location.href =
+            globalConfig.context +
+            "/api/user/channel/downloadTemplate?" +
+            "sign=user_channel";
+    }
+
+
+    changeList(arr) {
+        const newArr = [];
+        this.state.columns.forEach(item => {
+            arr.forEach(val => {
+                if (val === item.title) {
+                    newArr.push(item);
+                }
+            });
+        });
+        this.setState({
+            changeList: newArr
+        });
+    }
+
+    category() {
+        $.ajax({
+            method: "get",
+            dataType: "json",
+            crossDomain: false,
+            url: globalConfig.context + "/api/admin/Varieties/getSuperList",
+            data: {},
+            success: function (data) {
+                let thedata = data.data;
+                let theArr = [];
+                if (!thedata) {
+                    if (data.error && data.error.length) {
+                        message.warning(data.error[0].message);
+                    }
+                    thedata = {};
+                } else {
+                    thedata.map(function (item, index) {
+                        theArr.push({
+                            value: item.id,
+                            key: item.cname,
+                        });
+                    });
+                }
+                this.setState({
+                    categoryArr: theArr,
+                });
+            }.bind(this),
+        });
+    }
+
+    closeDesc(){
+        this.setState({
+            categoryArr:[],
+            followData:'',
+            visitModul:false
+        })
+    }
+
+    //已读指导记录
+    guidanceRead(id) {
+        return new Promise((resolve,reject)=>{
+            $.ajax({
+                method: "post",
+                dataType: "json",
+                crossDomain: false,
+                url: globalConfig.context + "/api/admin/customer/pushGuidance",
+                data: {
+                    uid: id,
+                }
+            }).done(function(data) {
+                if(!data.error.length) {
+                    resolve();
+                } else {
+                    message.warning(data.error[0].message);
+                    reject();
+                };
+            }.bind(this));
+        })
+    }
+
+    tableRowClick(record) {
+        this.setState({
+            rowData:record,
+            modalVisible: true,
+            basicState: true,
+            contactState: true,
+            modalName: record.userName
+        })
+    }
+
+    detailCloseDesc(){
+        this.setState({
+            rowData:'',
+            modalVisible: false,
+            basicState: false,
+            contactState: false,
+            modalName: ''
+        })
+    }
+
+    supervisor(e) {
+        $.ajax({
+            method: "get",
+            dataType: "json",
+            crossDomain: false,
+            url: globalConfig.context + "/api/admin/customer/listAdminByName",
+            data: {
+                adminName: e,
+            },
+            success: function (data) {
+                let thedata = data.data;
+                if (!thedata) {
+                    if (data.error && data.error.length) {
+                        message.warning(data.error[0].message);
+                    }
+                    thedata = {};
+                }
+                this.setState({
+                    customerArr: thedata,
+                });
+            }.bind(this),
+        }).always(
+            function () {
+
+            }.bind(this)
+        );
+    }
+
+    httpChange(e) {
+        if (e.length >= 1) {
+            this.supervisor(e);
+        }
+        this.setState({
+            auto: e,
+        });
+    }
+
+    blurChange(e) {
+        let theType = "";
+        let contactLists = this.state.customerArr || [];
+        if (e) {
+            contactLists.map(function (item) {
+                if (item.name == e.toString()) {
+                    theType = item.id;
+                }
+            });
+        }
+        this.setState({
+            theTypes: theType,
+        });
+    }
+
+    selectAuto(value, options) {
+        this.setState({
+            auto: value,
+        });
+    }
+
+    showConfirm() {
+        this.setState({
+            visible:true
+        })
+    }
+
+    changeAssigner() {
+        if(!this.state.reasonsTransfer){
+            message.warning("请输入转交原因");
+            return;
+        }
+        if (this.state.theTypes) {
+            let changeIds  = '';
+            let oldAid = '';
+            for (let idx = 0; idx < this.state.selectedRows.length; idx++) {
+                let rowItem = this.state.selectedRows[idx];
+                if (rowItem.id) {
+                    oldAid = rowItem.aid;
+                    changeIds = this.state.selectedRows.length-1 === idx ? changeIds +rowItem.id : changeIds + rowItem.id + ',' ;
+                }
+            }
+            $.ajax({
+                method: "post",
+                dataType: "json",
+                crossDomain: false,
+                url: globalConfig.context + "/api/admin/customer/channelCustomerDeliver",
+                data: {
+                    userIds: changeIds, //这一行数据的ID
+                    receiveId: this.state.theTypes, //指定转交人的ID
+                    remarks: this.state.reasonsTransfer,
+                },
+            }).done(
+                function (data) {
+                    if (!data.error.length) {
+                        message.success("转交成功!");
+                        this.setState({
+                            auto: "",
+                            loading: false,
+                            selectedRowKeys: [],
+                            reasonsTransfer:'',
+                            visible:false
+                        },()=>{
+                            this.loadData(
+                                Math.min(
+                                    this.state.ispage == undefined ? 1 : this.state.ispage,
+                                    Math.ceil((this.state.pagination.total - 1) / 10)
+                                )
+                            );
+                        });
+                    } else {
+                        message.warning(data.error[0].message);
+                    }
+                }.bind(this)
+            );
+        } else {
+            message.warning("请输入转交人姓名");
+        }
+    }
+
+    render() {
+        const rowSelection = {
+            hideDefaultSelections: true,
+            selectedRowKeys: this.state.selectedRowKeys,
+            onChange: (selectedRowKeys, selectedRows) => {
+                this.setState({
+                    modalVisible: false,
+                    selectedRows: selectedRows,
+                    selectedRowKeys: selectedRowKeys,
+                });
+            },
+            onSelect: (recordt, selected, selectedRows) => {
+                this.setState({
+                    modalVisible: false,
+                    recordt: recordt.id,
+                });
+            },
+        };
+        const dataSources = this.state.customerArr || [];
+        const options = dataSources.map((group) => (
+            <Select.Option key={group.id} value={group.name}>
+                {group.name}
+            </Select.Option>
+        ));
+        const hasSelected = this.state.selectedRowKeys.length > 0;
+        return (
+            <div className="user-content">
+                <div className="content-title">
+                    <span>渠道客户</span>
+                </div>
+                <div className="user-search">
+                    <Tabs
+                        defaultActiveKey="1"
+                        className="test"
+                    >
+                        <TabPane tab="搜索" key="1">
+                            <Input
+                                placeholder="请输入客户名称"
+                                value={this.state.nameSearch}
+                                style={{ width: 150, marginRight: 10, marginLeft: 10 }}
+                                onChange={(e) => {
+                                    this.setState({ nameSearch: e.target.value });
+                                }}
+                            />
+                            {/*0未分配 1已存在 2已分配*/}
+                            <Select
+                                placeholder="状态"
+                                style={{ width: 80 }}
+                                value={this.state.statusSearch}
+                                onChange={(e) => {
+                                    this.setState({ statusSearch: e });
+                                }}
+                            >
+                                <Select.Option value={0}>
+                                    未分配
+                                </Select.Option>
+                                <Select.Option value={1}>
+                                    已存在
+                                </Select.Option>
+                                <Select.Option value={2}>
+                                    已分配
+                                </Select.Option>
+                            </Select>
+                            <Select
+                                placeholder="省"
+                                style={{ width: 80 }}
+                                value={this.state.provinceSearch}
+                                onChange={(e) => {
+                                    this.setState({ provinceSearch: e });
+                                }}
+                            >
+                                {this.state.provinces}
+                            </Select>
+                            <span style={{ marginRight: "10px" }}>
+                              <Cascader
+                                  options={citySelect()}
+                                  value={this.state.addressSearch}
+                                  placeholder="选择城市"
+                                  onChange={(e, pre) => {
+                                      this.setState({ addressSearch: e });
+                                  }}
+                              />
+                            </span>
+                            <RangePicker
+                                value={[
+                                    this.state.releaseDate[0]
+                                        ? moment(this.state.releaseDate[0])
+                                        : null,
+                                    this.state.releaseDate[1]
+                                        ? moment(this.state.releaseDate[1])
+                                        : null,
+                                ]}
+                                onChange={(data, dataString) => {
+                                    this.setState({ releaseDate: dataString });
+                                }}
+                            />
+                            <Button
+                                type="primary"
+                                style={{ marginLeft: "10px", marginRight: 10 }}
+                                onClick={this.search}
+                            >
+                                搜索
+                            </Button>
+                            <Button onClick={this.reset}>重置</Button>
+                        </TabPane>
+                        <TabPane tab="操作" key="2">
+                            <div style={{
+                                marginTop: 10,
+                            }}>
+                                {this.props.deliver ? <AutoComplete
+                                    className="certain-category-search"
+                                    dropdownClassName="certain-category-search-dropdown"
+                                    dropdownMatchSelectWidth={false}
+                                    dropdownStyle={{ width: 120 }}
+                                    style={{ width: "120px" }}
+                                    dataSource={options}
+                                    placeholder={this.props.deliver === 1 ? '输入分配人姓名' : '输入转交人姓名'}
+                                    value={this.state.auto}
+                                    onChange={this.httpChange}
+                                    filterOption={true}
+                                    onBlur={this.blurChange}
+                                    onSelect={this.selectAuto}
+                                    disabled={!hasSelected}
+                                >
+                                    <Input />
+                                </AutoComplete> : ''}
+                                {this.props.deliver ? <Button
+                                    type="primary"
+                                    onClick={(e) => {
+                                        e.stopPropagation();
+                                        this.showConfirm();
+                                    }}
+                                    disabled={!hasSelected}
+                                    style={{ marginRight: 10 }}
+                                >
+                                    {this.props.deliver === 1 ? '分配' : '转交'}
+                                </Button> : ''}
+                                {this.props.deliver === 2 ? <Button
+                                    type="primary"
+                                    onClick={(e) => {
+                                        e.stopPropagation();
+                                        this.setState({
+                                            transferVisible:true,
+                                            transferId: this.state.selectedRows[0].uid
+                                        })
+                                    }}
+                                    disabled={!hasSelected || this.state.selectedRows.length > 1}
+                                    style={{ marginRight: 10 }}
+                                >
+                                    转交记录
+                                </Button> : ''}
+                                {this.props.recovery ? <Button
+                                    type="primary"
+                                    onClick={(e) => {
+                                        e.stopPropagation();
+
+                                    }}
+                                    disabled={!hasSelected}
+                                    style={{ marginRight: 10 }}
+                                >
+                                    回收
+                                </Button> : ''}
+                                {this.props.channel ? <Upload {...this.state.upLoad}>
+                                    <Button
+                                        type="primary"
+                                        style={{ marginRight: "10px" }}
+                                    >
+                                        +批量导入渠道客户
+                                    </Button>
+                                </Upload> : null}
+                                {this.props.channel ? <Button
+                                    onClick={(e) => {
+                                        e.stopPropagation();
+                                        this.download();
+                                    }}
+                                    type="primary"
+                                    style={{
+                                        marginRight: "10px",
+                                        background:'#f49f36',
+                                        borderColor:'#f49f36'
+                                    }}
+                                >
+                                    下载渠道客户模板
+                                </Button> : ''}
+                                {this.props.channel ? <Button
+                                    onClick={(e) => {
+                                        e.stopPropagation();
+                                        this.setState({
+                                            duplicateData: [],
+                                            duplicateDataVisible: true
+                                        })
+                                    }}
+                                    type="primary"
+                                    style={{
+                                        marginRight: "10px",
+                                        background:'#ff2f00',
+                                        borderColor:'#ff2f00'
+                                    }}
+                                >
+                                    查看导入失败列表
+                                </Button> : ''}
+                            </div>
+                        </TabPane>
+                        <TabPane tab="更改表格显示数据" key="3">
+                            <div style={{ marginLeft: 10 }}>
+                                <ChooseList
+                                    columns={this.state.columns}
+                                    changeFn={this.changeList}
+                                    changeList={this.state.changeList}
+                                    top={55}
+                                    margin={11}
+                                />
+                            </div>
+                        </TabPane>
+                    </Tabs>
+                </div>
+                <div className="patent-table">
+                    <Spin spinning={this.state.listLoading}>
+                        <Table
+                            size="middle"
+                            className={'intentionCustomerTable'}
+                            columns={
+                                this.state.changeList.length !== 0
+                                    ? this.state.changeList
+                                    : this.state.columns
+                            }
+                            dataSource={this.state.dataSource}
+                            rowSelection={this.props.deliver ? rowSelection : ''}
+                            pagination={this.state.pagination}
+                            onRowDoubleClick={this.tableRowClick}
+                        />
+                    </Spin>
+                </div>
+                <FollowDetail
+                    categoryArr={this.state.categoryArr}
+                    followData={this.state.followData}
+                    visitModul={this.state.visitModul}
+                    closeDesc={this.closeDesc}
+                />
+                <IntentionDetail
+                    tabsKey={this.state.tabsKey}
+                    categoryArr={this.state.categoryArr}
+                    detailApi={this.props.detailApi}
+                    IntentionData={this.state.rowData}
+                    modalVisible={this.state.modalVisible}
+                    name={this.state.modalName}
+                    closeDesc={this.detailCloseDesc}
+                    basicState={this.state.basicState}
+                    contactState={this.state.contactState}
+                    isGuidanceLv={this.props.isGuidanceLv}
+                    isEditGuidanceLv={this.props.isEditGuidanceLv}
+                />
+                {this.state.duplicateDataVisible ? <DuplicateData
+                    duplicateData={this.state.duplicateData || []}
+                    visible={this.state.duplicateDataVisible}
+                    onCancel={()=>{
+                        this.setState({
+                            duplicateData:[],
+                            duplicateDataVisible: false
+                        })
+                    }}
+                /> : null}
+                {this.state.transferVisible ? <TransferRecords
+                    id={this.state.transferId}
+                    visible={this.state.transferVisible}
+                    cancel={()=>{
+                        this.setState({
+                            transferVisible:false,
+                            transferId:''
+                        })
+                    }}
+                /> : '' }
+                <Modal
+                    title="渠道客户转交"
+                    visible={this.state.visible}
+                    onOk={()=>{
+                        this.changeAssigner()
+                    }}
+                    onCancel={()=>{
+                        this.setState({
+                            reasonsTransfer:'',
+                            visible:false
+                        })
+                    }}
+                >
+                    <span style={{ color: "red" }}>
+                        确定要转交以下客户吗?
+                            {
+                                this.state.selectedRows.map((value,index)=>(
+                                    <div key={index} style={{marginTop:'5px',color: "#000"}}>
+                                        {value.userName}
+                                    </div>
+                                ))
+                            }
+                        <div style={{marginTop:20}}>
+                            <span style={{marginRight:10,color:'#000'}}>转交原因:</span>
+                            <Input
+                                placeholder="转交原因"
+                                value={this.state.reasonsTransfer}
+                                style={{ width: 150 }}
+                                onChange={(e) => {
+                                    this.setState({reasonsTransfer : e.target.value });
+                                }}
+                            />
+                        </div>
+                    </span>
+                </Modal>
+            </div>
+        )
+    }
+}
+
+export default Channel;

+ 265 - 0
js/component/manageCenter/customer/NEW/intentionCustomer/duplicateData.jsx

@@ -0,0 +1,265 @@
+import React,{Component} from "react";
+import {Button, message, Modal, Popconfirm, Spin, Table, Tabs} from "antd";
+import {getSocialAttribute,ShowModal} from "@/tools.js";
+import $ from "jquery/src/ajax";
+
+const {TabPane} = Tabs;
+
+class DuplicateData extends Component{
+    constructor(props) {
+        super(props);
+        this.state={
+            columns: [
+                {
+                    title: "客户名称",
+                    dataIndex: "userName",
+                    key: "userName",
+                },
+                {
+                    title: "地区",
+                    dataIndex: "locationProvince",
+                    key: "locationProvince",
+                },
+                {
+                    title: "社会性质",
+                    dataIndex: "societyTag",
+                    key: "societyTag",
+                    render: (text) => {
+                        return getSocialAttribute(text);
+                    },
+                },
+                {
+                    title: "渠道专员",
+                    dataIndex: "aName",
+                    key: "aName",
+                },
+                {
+                    title: "客户联系人",
+                    dataIndex: "contacts",
+                    key: "contacts",
+                },
+                {
+                    title: "联系电话",
+                    dataIndex: "contactMobile",
+                    key: "contactMobile",
+                },
+                {
+                    title: "导入时间",
+                    dataIndex: "createTimes",
+                    key: "createTimes",
+                },
+                {
+                    title: "备注",
+                    dataIndex: "status",
+                    key: "status",
+                    render: (text) => (
+                        text === 0 ? '未分配' :
+                            text === 1 ? '已存在' :
+                                text === 2 ? '已分配' : ''
+                    )
+                },
+            ],
+            selectedRows:[],
+            selectedRowKeys:[],
+            dataSource:[],
+            pagination: {
+                defaultCurrent: 1,
+                defaultPageSize: 10,
+                showQuickJumper: true,
+                pageSize: 10,
+                onChange: function (page) {
+                    this.loadData(page);
+                }.bind(this),
+                showTotal: function (total) {
+                    return "共" + total + "条数据";
+                },
+            },
+            listLoading:false
+        }
+        this.loadData = this.loadData.bind(this);
+        this.confirmDeletNew = this.confirmDeletNew.bind(this);
+    }
+
+    componentDidMount() {
+        this.loadData();
+    }
+
+    // 删除供应商信息
+    confirmDeletNew() {
+        const hide = message.loading('删除中...', 0);
+        let changeIds = '';
+        for (let idx = 0; idx < this.state.selectedRows.length; idx++) {
+            let rowItem = this.state.selectedRows[idx];
+            if (rowItem.id) {
+                changeIds = this.state.selectedRows.length-1 === idx ? changeIds +rowItem.id : changeIds + rowItem.id + ',' ;
+            }
+        }
+        $.ajax({
+            url: globalConfig.context + '/api/user/channel/delete',
+            method: 'post',
+            data: {
+                ids: changeIds,
+            },
+        }).done(
+            function (data) {
+                hide();
+                if (!data.error.length) {
+                    message.success('删除成功!');
+                    this.setState({
+                        selectedRows:[],
+                        selectedRowKeys:[],
+                    })
+                    this.loadData(this.state.pageNo);
+                } else {
+                    message.warning(data.error[0].message)
+                }
+            }.bind(this)
+        )
+    }
+
+    loadData(pageNo = 1) {
+        if(this.props.duplicateData.length === 0){
+            this.setState({
+                listLoading: true,
+            });
+            $.ajax({
+                method: "get",
+                dataType: "json",
+                crossDomain: false,
+                url: globalConfig.context + '/api/user/channel/erorrList',
+                data: {
+                    pageNo: pageNo || 1,
+                    pageSize: this.state.pagination.pageSize,
+                },
+                success: function (data) {
+                    ShowModal(this);
+                    let theArr = [];
+                    if (data.error.length > 0) {
+                        message.warning(data.error[0].message);
+                    } else {
+                        for (let i = 0; i < data.data.list.length; i++) {
+                            let thisdata = data.data.list[i];
+                            let diqu =
+                                (thisdata.province == null ? "" : thisdata.province) +
+                                (thisdata.city == null ? "" : "-" + thisdata.city) +
+                                (thisdata.area == null ? "" : "-" + thisdata.area);
+                            thisdata.locationProvince = diqu;
+                            theArr.push(thisdata);
+                        }
+                        this.state.pagination.current = data.data.pageNo;
+                        this.state.pagination.total = data.data.totalCount;
+                        this.setState({
+                            pageNo: data.data.pageNo,
+                            dataSource: theArr,
+                            pagination: this.state.pagination,
+                        })
+                    }
+                }.bind(this),
+            }).always(
+                function () {
+                    this.setState({
+                        listLoading: false,
+                    });
+                }.bind(this)
+            );
+        }else{
+            let arr = this.props.duplicateData.slice((pageNo-1)*10,pageNo*10);
+            this.state.pagination.current = pageNo;
+            this.state.pagination.total = this.props.duplicateData.length;
+            for (let i = 0; i < arr.length; i++) {
+                let diqu =
+                    (arr[i].province == null ? "" : arr[i].province) +
+                    (arr[i].city == null ? "" : "-" + arr[i].city) +
+                    (arr[i].area == null ? "" : "-" + arr[i].area);
+                arr[i].locationProvince = diqu
+            }
+            this.setState({
+                pageNo: pageNo,
+                dataSource: arr,
+                pagination: this.state.pagination,
+            })
+        }
+    }
+
+    download() {
+        window.location.href =
+            globalConfig.context +
+            "/api/user/channel/export"
+    }
+
+    render() {
+        const rowSelection = {
+            hideDefaultSelections: true,
+            selectedRowKeys: this.state.selectedRowKeys,
+            onChange: (selectedRowKeys, selectedRows) => {
+                this.setState({
+                    selectedRows: selectedRows,
+                    selectedRowKeys: selectedRowKeys,
+                });
+            },
+        };
+        return (
+            <Modal
+                width={1000}
+                title="错误渠道数据"
+                visible={this.props.visible}
+                footer={false}
+                onCancel={()=>{
+                    this.props.onCancel();
+                }}
+            >
+                <Tabs
+                    defaultActiveKey="1"
+                    className="test"
+                >
+                    <TabPane tab="操作" key="1">
+                        <Button
+                            disabled={!this.state.dataSource.length}
+                            onClick={(e) => {
+                                e.stopPropagation();
+                                this.download();
+                            }}
+                            type="primary"
+                            style={{
+                                marginRight: "10px",
+                                margin: '10px',
+                            }}
+                        >
+                            导出错误渠道客户
+                        </Button>
+                        <Popconfirm
+                            title="是否删除?"
+                            onConfirm={() => {
+                                this.confirmDeletNew()
+                            }}
+                            okText="删除"
+                            cancelText="不删除"
+                        >
+                            <Button
+                                disabled={this.state.selectedRows.length === 0}
+                                onClick={(e) => {
+                                    e.stopPropagation();
+                                }}
+                                type="danger"
+                            >
+                                删除
+                            </Button>
+                        </Popconfirm>
+                    </TabPane>
+                </Tabs>
+                <Spin spinning={this.state.listLoading}>
+                    <Table
+                        size="middle"
+                        className={'intentionCustomerTable'}
+                        columns={this.state.columns}
+                        dataSource={this.state.dataSource}
+                        rowSelection={rowSelection}
+                        pagination={this.state.pagination}
+                    />
+                </Spin>
+            </Modal>
+        )
+    }
+}
+
+export default DuplicateData;

+ 130 - 0
js/component/manageCenter/customer/NEW/intentionCustomer/transferRecords.jsx

@@ -0,0 +1,130 @@
+import React from "react";
+import { Spin, Table, message, Modal } from "antd";
+import $ from "jquery/src/ajax";
+const TransferRecords = React.createClass({
+    getInitialState() {
+        return {
+            loading: false,
+            colunmn: [
+                {
+                    title: "序号",
+                    dataIndex: "id",
+                    key: "id",
+                },
+                {
+                    title: "客户姓名",
+                    dataIndex: "userName",
+                    key: "userName",
+                },
+                {
+                    title: "原管理员",
+                    dataIndex: "usedAName",
+                    key: "usedAName",
+                },
+                {
+                    title: "现管理员",
+                    dataIndex: "newAName",
+                    key: "newAName",
+                },
+                //  0录入 1 领取 2 转交私有客户 3转交业务 4 未跟进丢失(30) 5未签单丢失(270天)6释放  7转交签单客户  8渠道录入  9渠道客户分配  10 渠道客户转交 11渠道释放
+                {
+                    title: "转交类型",
+                    dataIndex: "type",
+                    key: "type",
+                    render: text => {
+                        return (
+                            <span>
+                  {
+                      text === 0 ? "录入":
+                          text === 1 ? "领取":
+                              text === 2 ? "转交私有客户":
+                                  text === 3 ? "转交业务":
+                                      text === 4 ? "未跟进丢失(30天)":
+                                          text === 5 ? "未签单丢失(270天)" :
+                                              text === 6 ? "移除" :
+                                                  text === 7 ? "转交签单客户" :
+                                                      text === 8 ? "渠道录入" :
+                                                          text === 9 ? "渠道客户分配" :
+                                                              text === 10 ? "渠道客户转交" :
+                                                                  text === 11 ? "渠道释放" :
+                                                                      text === 12 ? '回收' : ""
+                  }
+                </span>
+                        )
+                    }
+                },
+                {
+                    title: "项目名称",
+                    dataIndex: "pName",
+                    key: "pName",
+                },
+                {
+                    title: "创建时间",
+                    dataIndex: "createDate",
+                    key: "createDate",
+                },
+            ]
+        };
+    },
+    loadData() {
+        this.setState({
+            loading: true
+        });
+        $.ajax({
+            method: "get",
+            dataType: "json",
+            crossDomain: false,
+            url: globalConfig.context + "/api/admin/customer/transferList",
+            data: {
+                uid: this.props.id,
+            },
+            success: function (data) {
+                if (data.error.length || data.data.list == "") {
+                    if (data.error && data.error.length) {
+                        message.warning(data.error[0].message);
+                    }
+                } else {
+                    this.setState({
+                        dataSource: data.data,
+                    });
+                }
+            }.bind(this),
+        }).always(
+            function () {
+                this.setState({
+                    loading: false,
+                });
+            }.bind(this)
+        );
+
+    },
+    componentWillMount() {
+        this.loadData()
+    },
+    render() {
+        return (
+            <Modal
+                style={{ position: "relative" }}
+                title="转交记录"
+                visible={this.props.visible}
+                onCancel={this.props.cancel}
+                footer={null}
+                width={800}
+                destroyOnClose={true}
+            >
+                <Spin spinning={this.state.loading} >
+                    <Table
+                        columns={this.state.colunmn}
+                        dataSource={this.state.dataSource}
+                        pagination={false}
+                        scroll={{ x: "max-content", y: 0 }}
+                        bordered
+                        size="small"
+                    />
+                </Spin>
+            </Modal>
+        );
+    },
+});
+
+export default TransferRecords;

+ 37 - 1
js/component/manageCenter/customer/NEW/signCustomer/signCustomer.jsx

@@ -50,6 +50,7 @@ const IntentionCustomer = Form.create()(React.createClass({
 				pageNo: pageNo || 1,
 				pageSize: this.state.pagination.pageSize,
 				name: this.state.nameSearch,
+				channel: this.state.channelSearch,
 				province: !(this.state.addressSearch).length ? this.state.provinceSearch : this.state.addressSearch[0],
 				city: !(this.state.addressSearch).length ? '' : this.state.addressSearch[1],
 				startDate: this.state.releaseDate[0],
@@ -71,7 +72,7 @@ const IntentionCustomer = Form.create()(React.createClass({
 						thisdata.transferTime = thisdata.transferTime && thisdata.transferTime.split(" ")[0];
 						thisdata.lastSignTime = thisdata.lastSignTime && thisdata.lastSignTime.split(" ")[0];
 						thisdata.lastFollowTime = thisdata.lastFollowTime && thisdata.lastFollowTime.split(" ")[0];
-						locationProvince : diqu
+						thisdata.locationProvince = diqu
 						theArr.push(thisdata);
 					};
 					this.state.pagination.current = data.data.pageNo;
@@ -129,6 +130,24 @@ const IntentionCustomer = Form.create()(React.createClass({
           title: "客户名称",
           dataIndex: "name",
           key: "name",
+		  render: (text,record) => {
+			return (
+				<span>
+					{record.channel === 1 ? <div style={{
+						background:'#ef7207',
+						color:'#FFF',
+						padding: '1px 7px',
+						borderRadius:'5px',
+						fontSize:'12px',
+						display: 'inline-block',
+						marginRight:'10px'
+					}}>
+						渠道
+					</div> : null}
+					{text}
+				</span>
+			)
+		  },
         },
         {
           title: "地区",
@@ -312,6 +331,7 @@ const IntentionCustomer = Form.create()(React.createClass({
 		this.state.nameSearch = '';
 		this.state.addressSearch = [];
 		this.state.provinceSearch = undefined;
+		this.state.channelSearch = undefined;
 		this.state.citySearch = undefined;
 		this.state.releaseDate[0] = undefined;
 		this.state.releaseDate[1] = undefined;
@@ -371,6 +391,7 @@ const IntentionCustomer = Form.create()(React.createClass({
 			this.state.nameSearch = '';
 			this.state.addressSearch = [];
 			this.state.provinceSearch = undefined;
+			this.state.channelSearch = undefined
 			this.state.citySearch = undefined;
 			this.state.releaseDate[0] = undefined;
 			this.state.releaseDate[1] = undefined;
@@ -548,6 +569,21 @@ const IntentionCustomer = Form.create()(React.createClass({
                   this.setState({ nameSearch: e.target.value });
                 }}
               />
+				<Select
+					placeholder="是否为渠道"
+					style={{ width: 110 }}
+					value={this.state.channelSearch}
+					onChange={(e) => {
+						this.setState({ channelSearch: e });
+					}}
+				>
+					<Select.Option value={0}>
+						非渠道
+					</Select.Option>
+					<Select.Option value={1}>
+						渠道
+					</Select.Option>
+				</Select>
               <Select
                 placeholder="省"
                 style={{ width: 80 }}

+ 119 - 68
js/component/manageCenter/customer/content.jsx

@@ -29,13 +29,13 @@ class Content extends Component {
         };
     }
     getKey(key) {
-        switch (key) {    
+        switch (key) {
 //      	//我的单位客户
 //          case 'myOrganization':
 //              require.ensure([], () => {
 //                  const MyClient = require('./customerData/myClient').default;
 //                  this.setState({
-//                      component: <MyClient ApiUrl={''}/>                      
+//                      component: <MyClient ApiUrl={''}/>
 //                  });
 //              });
 //              break;
@@ -44,7 +44,7 @@ class Content extends Component {
 //              require.ensure([], () => {
 //	                const CompanyCustomer = require('./customerData/companyCustomer').default;
 //	                this.setState({
-//	                    component:<CompanyCustomer ApiUrl={''}/>,	                    	                  
+//	                    component:<CompanyCustomer ApiUrl={''}/>,
 //	                });
 //        	    });
 //        	    break;
@@ -53,27 +53,27 @@ class Content extends Component {
 //              require.ensure([], () => {
 //                  const IndividualCustomer = require('./individualCustomer/individualCustomer').default;
 //                  this.setState({
-//                      component: <IndividualCustomer ApiUrl={''}/>                      
-//                    
+//                      component: <IndividualCustomer ApiUrl={''}/>
+//
 //                  });
 //              });
-//              break; 
+//              break;
             //我的被拒绝客户
             case 'myReject':
                 require.ensure([], () => {
                     const MyReject = require('./individualCustomer/myReject').default;
                     this.setState({
-                        component: <MyReject ApiUrl={''}/>                      
-                      
+                        component: <MyReject ApiUrl={''}/>
+
                     });
                 });
-                break; 
+                break;
 //          //个人客户查询
 //          case 'personalQuery':
 //              require.ensure([], () => {
 //	                const QueryCustomer = require('./individualCustomer/queryCustomer').default;
 //	                this.setState({
-//	                    component:<QueryCustomer ApiUrl={''}/>,	                    	                  
+//	                    component:<QueryCustomer ApiUrl={''}/>,
 //	                });
 //        	    });
 //        	    break;
@@ -82,7 +82,7 @@ class Content extends Component {
                 require.ensure([], () => {
 	                const ExpertQuery = require('./individualCustomer/expertQuery').default;
 	                this.setState({
-	                    component:<ExpertQuery ApiUrl={''}/>,	                    	                  
+	                    component:<ExpertQuery ApiUrl={''}/>,
 	                });
           	    });
           	    break;
@@ -91,7 +91,7 @@ class Content extends Component {
                 require.ensure([], () => {
 	                const Qublicquery = require('./individualCustomer/publicQuery').default;
 	                this.setState({
-	                    component:<Qublicquery ApiUrl={''}/>,	                    	                  
+	                    component:<Qublicquery ApiUrl={''}/>,
 	                });
           	    });
           	    break;
@@ -100,16 +100,16 @@ class Content extends Component {
                 require.ensure([], () => {
 	                const PersonalManage = require('./customerManagement/personalManages').default;
 	                this.setState({
-	                    component:<PersonalManage ApiUrl={''}/>,	                    	                  
+	                    component:<PersonalManage ApiUrl={''}/>,
 	                });
           	    });
           	    break;
-          	//专家管理    
+          	//专家管理
           	case 'expertManage':
                 require.ensure([], () => {
 	                const ExpertManage = require('./customerManagement/expertManage').default;
 	                this.setState({
-	                    component:<ExpertManage ApiUrl={''}/>,	                    	                  
+	                    component:<ExpertManage ApiUrl={''}/>,
 	                });
           	    });
           	    break;
@@ -118,7 +118,7 @@ class Content extends Component {
                 require.ensure([], () => {
 	                const ExpertReview = require('./reviewed/expertReview').default;
 	                this.setState({
-	                    component:<ExpertReview ApiUrl={''}/>,	                    	                  
+	                    component:<ExpertReview ApiUrl={''}/>,
 	                });
           	    });
           	    break;
@@ -127,7 +127,7 @@ class Content extends Component {
                 require.ensure([], () => {
 	                const IdentityAudits = require('./reviewed/identityAudits').default;
 	                this.setState({
-	                    component:<IdentityAudits ApiUrl={''}/>,	                    	                  
+	                    component:<IdentityAudits ApiUrl={''}/>,
 	                });
           	    });
           	    break;
@@ -136,7 +136,7 @@ class Content extends Component {
                 require.ensure([], () => {
 	                const EnteringAudit = require('./reviewed/enteringAudit').default;
 	                this.setState({
-	                    component:<EnteringAudit ApiUrl={''}/>,	                    	                  
+	                    component:<EnteringAudit ApiUrl={''}/>,
 	                });
           	    });
           	    break;
@@ -145,7 +145,7 @@ class Content extends Component {
                 require.ensure([], () => {
 	                const ExpertRelease = require('./release/expertRelease').default;
 	                this.setState({
-	                    component:<ExpertRelease ApiUrl={''}/>,	                    	                  
+	                    component:<ExpertRelease ApiUrl={''}/>,
 	                });
           	    });
           	    break;
@@ -154,7 +154,7 @@ class Content extends Component {
                 require.ensure([], () => {
 	                const ReleaseExpert = require('./release/releaseExpert').default;
 	                this.setState({
-	                    component:<ReleaseExpert ApiUrl={''}/>,	                    	                  
+	                    component:<ReleaseExpert ApiUrl={''}/>,
 	                });
           	    });
           	    break;
@@ -163,7 +163,7 @@ class Content extends Component {
                 require.ensure([], () => {
 	                const PublicManages = require('./customerManagement/publicManages').default;
 	                this.setState({
-	                    component:<PublicManages ApiUrl={''}/>,	                    	                  
+	                    component:<PublicManages ApiUrl={''}/>,
 	                });
           	    });
           	    break;
@@ -172,7 +172,7 @@ class Content extends Component {
 			    require.ensure([], () => {
 			        const AdminCustomerStatistics = require('./customerManagement/adminCustomerStatistics').default;
 			        this.setState({
-			            component:<AdminCustomerStatistics ApiUrl={''}/>,	                    	                  
+			            component:<AdminCustomerStatistics ApiUrl={''}/>,
 			        });
 			    });
 			    break;
@@ -181,7 +181,7 @@ class Content extends Component {
 // 				require.ensure([], () => {
 // 				    const AdminCustomerStatistics3 = require('./customerManagement/adminCustomerStatistics3').default;
 // 				    this.setState({
-// 				        component:<AdminCustomerStatistics3 ApiUrl={''}/>,	                    	                  
+// 				        component:<AdminCustomerStatistics3 ApiUrl={''}/>,
 // 				    });
 // 				});
 // 				break;
@@ -190,7 +190,7 @@ class Content extends Component {
                 require.ensure([], () => {
 	                const OrganizationManage = require('./customerManagement/organizationManages').default;
 	                this.setState({
-	                    component:<OrganizationManage ApiUrl={''}/>,	                    	                  
+	                    component:<OrganizationManage ApiUrl={''}/>,
 	                });
           	    });
           	    break;
@@ -199,7 +199,7 @@ class Content extends Component {
 	            require.ensure([], () => {
 	                const MyBusiness = require('./customerService/myBusiness').default;
 	                this.setState({
-	                    component:<MyBusiness ApiUrl={''}/>,	                                      
+	                    component:<MyBusiness ApiUrl={''}/>,
 	                });
 	      	    });
 	      	    break;
@@ -208,7 +208,7 @@ class Content extends Component {
 	            require.ensure([], () => {
 	                const BusinessMange = require('./customerService/businessManges').default;
 	                this.setState({
-	                    component:<BusinessMange ApiUrl={''}/>,	                                      
+	                    component:<BusinessMange ApiUrl={''}/>,
 	                });
 	      	    });
 	      	    break;
@@ -217,7 +217,7 @@ class Content extends Component {
             require.ensure([], () => {
                 const ServiceQuery = require('./customerService/serviceQuery').default;
                 this.setState({
-                    component:<ServiceQuery ApiUrl={''}/>,	                                      
+                    component:<ServiceQuery ApiUrl={''}/>,
                 });
       	    });
       	    break;
@@ -226,7 +226,7 @@ class Content extends Component {
             require.ensure([], () => {
                 const VisitStatistics = require('./statistics/visitStatistics').default;
                 this.setState({
-                    component:<VisitStatistics ApiUrl={''}/>,	                                      
+                    component:<VisitStatistics ApiUrl={''}/>,
                 });
       	    });
       	    break;
@@ -235,7 +235,7 @@ class Content extends Component {
             require.ensure([], () => {
                 const StatusStatistics = require('./statistics/statusStatistics').default;
                 this.setState({
-                    component:<StatusStatistics ApiUrl={''}/>,	                                      
+                    component:<StatusStatistics ApiUrl={''}/>,
                 });
       	    });
       	    break;
@@ -244,26 +244,26 @@ class Content extends Component {
             require.ensure([], () => {
                 const FollowStatistics = require('./statistics/followStatistics').default;
                 this.setState({
-                    component:<FollowStatistics ApiUrl={''}/>,	                                      
+                    component:<FollowStatistics ApiUrl={''}/>,
                 });
       	    });
       	    break;
       	    /*
-      	     *报表开发 
+      	     *报表开发
       	     */
       	    case 'personalReport':
                 require.ensure([], () => {
                     const Jurisdiction = require('./report/personalReport').default;
                     this.setState({
-                        component: <Jurisdiction ApiUrl={''}/>                      
+                        component: <Jurisdiction ApiUrl={''}/>
                     });
                 });
-                break;  
+                break;
             case 'departmentReport':
                 require.ensure([], () => {
                     const DepartmentReport = require('./report/departmentReport').default;
                     this.setState({
-                        component: <DepartmentReport ApiUrl={''}/>                      
+                        component: <DepartmentReport ApiUrl={''}/>
                     });
                 });
                 break;
@@ -273,16 +273,16 @@ class Content extends Component {
                 require.ensure([], () => {
                     const DiurnalStatistics = require('./customerMarketing/diurnalStatistics').default;
                     this.setState({
-                        component: <DiurnalStatistics ApiUrl={''}/>                      
+                        component: <DiurnalStatistics ApiUrl={''}/>
                     });
                 });
-                break;  
+                break;
             //客户营销时段统计
             case 'timeStatistics':
                 require.ensure([], () => {
                     const TimeStatistics = require('./customerMarketing/timeStatistics').default;
                     this.setState({
-                        component: <TimeStatistics ApiUrl={''}/>                      
+                        component: <TimeStatistics ApiUrl={''}/>
                     });
                 });
                 break;
@@ -300,12 +300,63 @@ class Content extends Component {
                     });
                 });
                 break;
-            //单位意向客户    
+            //渠道-(营销总监)
+            case 'channel':
+                require.ensure([], () => {
+                    const CompanyIntention = require('./NEW/intentionCustomer/channel').default;
+                    this.setState({
+                        component: <CompanyIntention
+                            channel={false}             //是否能导入渠道
+                            deliver={1}                 //是否能转交或分配  0不能 1分配 2跟进
+                            followUp={true}             //是否能跟进
+                            isGuidanceLv={true}         //是否可查看指导  也用于判断是否为跟进管理页面
+                            isEditGuidanceLv={false}    //是否可以编辑指导
+                            recovery={false}             //是否可以回收
+                            detailApi={'/api/admin/customer/findOrganizationCustomerDetail'}
+                        />
+                    });
+                });
+                break;
+            //渠道-(营销员)
+            case 'channelMarketing':
+                require.ensure([], () => {
+                    const CompanyIntention = require('./NEW/intentionCustomer/channel').default;
+                    this.setState({
+                        component: <CompanyIntention
+                            channel={false}   //是否能导入渠道
+                            deliver={2}
+                            followUp={true}
+                            isGuidanceLv={false}         //是否可查看指导  也用于判断是否为跟进管理页面
+                            isEditGuidanceLv={true}     //是否可以编辑指导
+                            recovery={true}             //是否可以回收
+                            detailApi={'/api/admin/customer/findOrganizationCustomerDetail'}
+                        />
+                    });
+                });
+                break;
+            //渠道-(渠道专员)
+            case 'channelCommissioner':
+                require.ensure([], () => {
+                    const CompanyIntention = require('./NEW/intentionCustomer/channel').default;
+                    this.setState({
+                        component: <CompanyIntention
+                            channel={true}   //是否能导入渠道
+                            deliver={0}
+                            followUp={false}
+                            isGuidanceLv={true}         //是否可查看指导  也用于判断是否为跟进管理页面
+                            isEditGuidanceLv={false}     //是否可以编辑指导
+                            recovery={false}             //是否可以回收
+                            detailApi={'/api/admin/customer/findOrganizationCustomerDetail'}
+                        />
+                    });
+                });
+                break;
+            //单位意向客户
             case 'companyIntention':
                 require.ensure([], () => {
                     const CompanyIntention = require('./NEW/intentionCustomer/intentionCustomer').default;
                     this.setState({
-                        component: <CompanyIntention 
+                        component: <CompanyIntention
 	                        		intentionState={0}
 	                        		ApiUrl={'/api/admin/customer/listPrivateOrganizationCustomer'}
 	                        		detailApi={'/api/admin/customer/findOrganizationCustomerDetail'}
@@ -346,12 +397,12 @@ class Content extends Component {
                     });
                 });
                 break;
-            //客户资料    
+            //客户资料
             case 'crm':
                 require.ensure([], () => {
                     const Crm = require('./NEW/crm/crm').default;
                     this.setState({
-                        component: <Crm 
+                        component: <Crm
 	                        		intentionState={0}
 	                        		ApiUrl={'/api/admin/customer/listPrivateOrganizationCustomer'}
 	                        		detailApi={'/api/admin/customer/findOrganizationCustomerDetail'}
@@ -359,12 +410,12 @@ class Content extends Component {
                     });
                 });
                 break;
-             //客户资料    
+             //客户资料
             case 'crmCount':
                 require.ensure([], () => {
                     const CrmCount = require('./NEW/crm/crmCount').default;
                     this.setState({
-                        component: <CrmCount 
+                        component: <CrmCount
 	                        		intentionState={0}
 	                        		ApiUrl={'/api/admin/customer/listPrivateOrganizationCustomer'}
 	                        		detailApi={'/api/admin/customer/findOrganizationCustomerDetail'}
@@ -372,12 +423,12 @@ class Content extends Component {
                     });
                 });
                 break;
-            //客户资料    
+            //客户资料
             case 'crmAll':
                 require.ensure([], () => {
                     const CrmAll = require('./NEW/crm/crmAll').default;
                     this.setState({
-                        component: <CrmAll 
+                        component: <CrmAll
 	                        		intentionState={0}
 	                        		ApiUrl={'/api/admin/customer/listPrivateOrganizationCustomer'}
 	                        		detailApi={'/api/admin/customer/findOrganizationCustomerDetail'}
@@ -385,7 +436,7 @@ class Content extends Component {
                     });
                 });
                 break;
-			//客户资料    
+			//客户资料
 			case 'patentPayment':
 			    require.ensure([], () => {
 			        const PatentPayment = require('./NEW/crm/patentPayment').default;
@@ -412,13 +463,13 @@ class Content extends Component {
                     });
                 });
                 break;
-            /*签单客户*/ 
+            /*签单客户*/
             //个人签单客户
             case 'personalSign':
                 require.ensure([], () => {
                     const PersonalSign = require('./NEW/signCustomer/signCustomer').default;
                     this.setState({
-                        component: <PersonalSign 
+                        component: <PersonalSign
                     			intentionState={1}
                     		    ApiUrl={'/api/admin/customer/listSignPersonalCustomer'}
                     		    //ApiUrl={'/api/admin/customer/listPrivatePersonalCustomer'}
@@ -427,15 +478,15 @@ class Content extends Component {
                     });
                 });
                 break;
-            //单位签单客户    
+            //单位签单客户
             case 'companySign':
                 require.ensure([], () => {
                     const CompanySign =  require('./NEW/signCustomer/signCustomer').default;
                     this.setState({
-                        component: <CompanySign 
+                        component: <CompanySign
                     			intentionState={0}
                         		ApiUrl={'/api/admin/customer/listSignOrganizationCustomer'}
-                        		detailApi={'/api/admin/customer/findOrganizationCustomerDetail'}/>                      
+                        		detailApi={'/api/admin/customer/findOrganizationCustomerDetail'}/>
                     });
                 });
                 break;
@@ -444,61 +495,61 @@ class Content extends Component {
                 require.ensure([], () => {
                     const PersonalQuery = require('./NEW/query/queryCutomer').default;
                     this.setState({
-                        component: <PersonalQuery 
+                        component: <PersonalQuery
                 			intentionState={1}
-                		    ApiUrl={'/api/admin/customer/listAllPersonalCustomer'}	
+                		    ApiUrl={'/api/admin/customer/listAllPersonalCustomer'}
                 		    detailApi={'/api/admin/customer/getLockedProject'}
                         />
                     });
                 });
                 break;
-            //单位客户查询    
+            //单位客户查询
             case 'organizationQuery':
                 require.ensure([], () => {
                     const CompanyQuery =  require('./NEW/query/queryCutomer').default;
                     this.setState({
-                        component: <CompanyQuery 
+                        component: <CompanyQuery
                 			intentionState={0}
                     		ApiUrl={'/api/admin/customer/listAllOrganizationCustomer'}
                     		detailApi={'/api/admin/customer/getLockedProject'}
-                    	/>	
+                    	/>
                     });
                 });
-                break;  
+                break;
              //个人公共客户
             case 'personalPublicCustomer':
                 require.ensure([], () => {
                     const PersonalPublicCustomer = require('./NEW/publicCustomer/publicCustomer').default;
                     this.setState({
-                        component: <PersonalPublicCustomer 
+                        component: <PersonalPublicCustomer
                 			intentionState={1}
-                		    ApiUrl={'/api/admin/customer/listPublicPersonalCustomer'}	
+                		    ApiUrl={'/api/admin/customer/listPublicPersonalCustomer'}
                         />
                     });
                 });
                 break;
-            //单位公共客户    
+            //单位公共客户
             case 'organizationPublicCustomer':
                 require.ensure([], () => {
                     const OrganizationPublicCustomer =  require('./NEW/publicCustomer/publicCustomer').default;
                     this.setState({
-                        component: <OrganizationPublicCustomer 
+                        component: <OrganizationPublicCustomer
                 			intentionState={0}
                     		ApiUrl={'/api/admin/customer/listPublicOrganizationCustomer'}
-                    	/>	
+                    	/>
                     });
                 });
-                break;     
+                break;
       	    default:
             require.ensure([], () => {
                 const Module = require('../module').default;
                 this.setState({
-                    component:<Module ApiUrl={''}/>	    
+                    component:<Module ApiUrl={''}/>
                 	});
-                });  
-           
-           
-                
+                });
+
+
+
         };
         window.location.hash = key;
     }

+ 8 - 2
js/component/zhuanjiaoDetail.jsx

@@ -26,7 +26,7 @@ const ZhuanjiaoDetail = React.createClass({
           dataIndex: "newAName",
           key: "newAName",
         },
-        //  0录入 1 领取 2 转交私有客户 3转交业务 4 未跟进丢失(30) 5未签单丢失(270天)6释放  7转交签单客户
+        //  0录入 1 领取 2 转交私有客户 3转交业务 4 未跟进丢失(30) 5未签单丢失(270天)6释放  7转交签单客户  8渠道录入  9渠道客户分配  10 渠道客户转交 11渠道释放
         {
           title: "转交类型",
           dataIndex: "type",
@@ -42,7 +42,13 @@ const ZhuanjiaoDetail = React.createClass({
                                     text === 4 ? "未跟进丢失(30天)":
                                         text === 5 ? "未签单丢失(270天)" :
                                             text === 6 ? "移除" :
-                                                text === 7 ? "转交签单客户" :""
+                                                text === 7 ? "转交签单客户" :
+                                                    text === 8 ? "渠道录入" :
+                                                        text === 9 ? "渠道客户分配" :
+                                                            text === 10 ? "渠道客户转交" :
+                                                                text === 11 ? "渠道释放" :
+                                                                    text === 12 ? '回收' :""
+
                   }
                 </span>
             )