highTech.jsx 33 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955
  1. import React, { Component } from "react";
  2. import {
  3. Button,
  4. DatePicker,
  5. Input,
  6. message,
  7. Select,
  8. Spin,
  9. Table,
  10. Tabs,
  11. Cascader,
  12. AutoComplete,
  13. } from "antd";
  14. import { ShowModal } from "@/tools";
  15. import { ChooseList } from "../../order/orderNew/chooseList";
  16. import $ from "jquery/src/ajax";
  17. import moment from "moment";
  18. import {
  19. member,
  20. highTechColumns,
  21. doubleSoft,
  22. softWriting,
  23. patent,
  24. audit,
  25. currency,
  26. } from "./highTechConfig";
  27. import { projectStatusList } from "@/dataDic";
  28. import ProjectDetails from "./projectDetails";
  29. import Cascaders from "../../../common/cascaders";
  30. const { TabPane } = Tabs;
  31. const { RangePicker } = DatePicker;
  32. const { Option } = Select;
  33. class HighTech extends Component {
  34. constructor(props) {
  35. super(props);
  36. this.state = {
  37. tbaindex: 1,
  38. loading: false,
  39. changeList: undefined,
  40. columns: currency,
  41. status: 0,
  42. page: 1,
  43. pagination: {
  44. defaultCurrent: 1,
  45. defaultPageSize: 10,
  46. showQuickJumper: true,
  47. pageSize: 10,
  48. onChange: function (page) {
  49. this.loadData(page);
  50. }.bind(this),
  51. showTotal: function (total) {
  52. return "共" + total + "条数据";
  53. },
  54. },
  55. dataSource: [],
  56. releaseDate: [],
  57. searchOrderNo: "",
  58. searchContractNo: "",
  59. searchEnterpriseName: "",
  60. declarationBatch: "",
  61. projectSituation: "",
  62. projectAmount: "",
  63. deps: "",
  64. thchDeps: "",
  65. projectType: "",
  66. projectStatus: "",
  67. departmentArr: [],
  68. contactsOption: [],
  69. contactsOptionData: [],
  70. visible: false,
  71. };
  72. this.resetAll = this.resetAll.bind(this);
  73. this.changeList = this.changeList.bind(this);
  74. this.loadData = this.loadData.bind(this);
  75. this.selectSuperId = this.selectSuperId.bind(this);
  76. this.supervisor = this.supervisor.bind(this);
  77. this.httpChange = this.httpChange.bind(this);
  78. this.selectAuto = this.selectAuto.bind(this);
  79. this.blurChange = this.blurChange.bind(this);
  80. }
  81. changeList(arr) {
  82. const newArr = [];
  83. this.state.columns.forEach((item) => {
  84. arr.forEach((val) => {
  85. if (val === item.title) {
  86. newArr.push(item);
  87. }
  88. });
  89. });
  90. this.setState({
  91. changeList: newArr,
  92. });
  93. }
  94. loadData(pageNo = "") {
  95. this.setState({
  96. loading: true,
  97. });
  98. $.ajax({
  99. method: "get",
  100. dataType: "json",
  101. crossDomain: false,
  102. url: globalConfig.context + "/api/admin/statistis/selectTaskList",
  103. data: this.props.searchData
  104. ? Object.assign(
  105. {
  106. pageNo: pageNo || 1,
  107. pageSize: this.state.pagination.pageSize || 10,
  108. },
  109. this.props.searchData
  110. )
  111. :
  112. {
  113. pageNo: pageNo || 1,
  114. pageSize: this.state.pagination.pageSize || 10,
  115. startDate:
  116. this.state.releaseDate.length > 0
  117. ? this.state.releaseDate[0]
  118. : undefined, //开始时间
  119. endDate:
  120. this.state.releaseDate.length > 0
  121. ? this.state.releaseDate[1]
  122. : undefined, //结束时间
  123. deps: this.state.deps || undefined, //部门ID
  124. thchDeps: this.state.thchDeps || undefined, //责任部门ID
  125. projectStatus: this.state.projectStatus || undefined, //项目类别
  126. projectType: !this.state.projectType ? undefined : this.state.projectType, //项目分类
  127. orderNo: this.state.searchOrderNo || undefined, //订单编号
  128. contractNo: this.state.searchContractNo || undefined, //合同编号
  129. userName: this.state.searchEnterpriseName || undefined, //企业名称
  130. declarationBatch: this.state.declarationBatch || undefined, //申报批次
  131. projectSituation:
  132. typeof this.state.projectSituation === "number"
  133. ? this.state.projectSituation
  134. : undefined, //项目分类
  135. projectAmount: this.state.projectAmount || undefined, //项目金额
  136. status: this.state.status,
  137. thchId: this.state.thchId || undefined, //咨询师/咨询经理id
  138. taskProjectStatus: this.state.taskProjectStatus || undefined,//项目状态
  139. sdStatus: this.state.sdStatus,//满意度
  140. },
  141. success: function (data) {
  142. ShowModal(this);
  143. let theArr = [];
  144. if (!data.data || !data.data.list) {
  145. if (data.error && data.error.length) {
  146. message.warning(data.error[0].message);
  147. }
  148. } else {
  149. for (let i = 0; i < data.data.list.length; i++) {
  150. let thisdata = data.data.list[i];
  151. thisdata.key = (data.data.pageNo - 1) * data.data.pageSize + i + 1;
  152. theArr.push(thisdata);
  153. }
  154. this.state.pagination.current = data.data.pageNo;
  155. this.state.pagination.total = data.data.totalCount;
  156. if (data.data && data.data.list && !data.data.list.length) {
  157. this.state.pagination.current = 0;
  158. this.state.pagination.total = 0;
  159. }
  160. this.setState({
  161. pagination: this.state.pagination,
  162. page: pageNo,
  163. dataSource: theArr,
  164. });
  165. }
  166. }.bind(this),
  167. }).always(
  168. function () {
  169. this.setState({
  170. loading: false,
  171. });
  172. }.bind(this)
  173. );
  174. }
  175. resetAll() {
  176. this.setState(
  177. {
  178. newArray: [],
  179. releaseDate: [],
  180. searchOrderNo: "",
  181. searchContractNo: "",
  182. searchEnterpriseName: "",
  183. declarationBatch: "",
  184. projectSituation: "",
  185. projectAmount: "",
  186. projectType: "",
  187. deps: "",
  188. thchDeps: "",
  189. projectStatus: "",
  190. columns: currency,
  191. status: 0,
  192. thchId: "",
  193. auto: "",
  194. taskProjectStatus: "",
  195. sdStatus: undefined,
  196. },
  197. () => {
  198. this.Cascaders1.empty();
  199. this.Cascaders2.empty();
  200. this.defaultcolumns();
  201. this.loadData();
  202. }
  203. );
  204. }
  205. //项目类别
  206. selectSuperId() {
  207. $.ajax({
  208. method: "get",
  209. dataType: "json",
  210. crossDomain: false,
  211. url: globalConfig.context + "/api/admin/ProjectSize/getAllCname",
  212. data: {
  213. flag: 0,
  214. },
  215. success: function (data) {
  216. let theArr = [];
  217. let newTheArr = []
  218. let thedata = data.data;
  219. if (!thedata) {
  220. if (data.error && data.error.length) {
  221. message.warning(data.error[0].message);
  222. }
  223. }
  224. for (let i = 0; i < data.data.length; i++) {
  225. let theData = data.data[i];
  226. theArr.push(
  227. <Select.Option value={theData.id} key={theData.cname}>
  228. {theData.cname}
  229. </Select.Option>
  230. );
  231. let newChildren = []
  232. for (let j = 0; j < theData.typeList.length; j++) {
  233. newChildren.push({
  234. label: theData.typeList[j].name,
  235. value: theData.typeList[j].id,
  236. })
  237. }
  238. newTheArr.push({
  239. label: theData.cname,
  240. value: theData.id,
  241. children: newChildren
  242. })
  243. }
  244. this.setState({
  245. contactsOption: theArr,
  246. contactsOptionData: newTheArr,
  247. // contactsOptionData: data.data,
  248. });
  249. }.bind(this),
  250. }).always();
  251. }
  252. // 设置默认table(用来默认不显示某列数据 isNoD:true)
  253. defaultcolumns() {
  254. const newArr = [];
  255. this.state.columns.forEach((item) => {
  256. if (item.isNoD) {
  257. return
  258. } else {
  259. newArr.push(item);
  260. }
  261. });
  262. this.setState({
  263. changeList: newArr,
  264. }, () => {
  265. this.loadData();
  266. });
  267. }
  268. // 导出excel
  269. exportExec() {
  270. message.config({
  271. duration: 20,
  272. });
  273. let loading = message.loading("下载中...");
  274. this.setState({
  275. exportPendingLoading: true,
  276. });
  277. let data = {
  278. startDate:
  279. this.state.releaseDate.length > 0
  280. ? this.state.releaseDate[0]
  281. : undefined, //开始时间
  282. endDate:
  283. this.state.releaseDate.length > 0
  284. ? this.state.releaseDate[1]
  285. : undefined, //结束时间
  286. deps: this.state.deps || undefined, //部门ID
  287. thchDeps: this.state.thchDeps || undefined, //责任部门ID
  288. projectStatus: this.state.projectStatus || undefined, //项目类别
  289. projectType: !this.state.projectType ? undefined : this.state.projectType, //项目分类
  290. status: this.state.status,
  291. orderNo: this.state.searchOrderNo || undefined, //订单编号
  292. contractNo: this.state.searchContractNo || undefined, //合同编号
  293. userName: this.state.searchEnterpriseName || undefined, //企业名称
  294. declarationBatch: this.state.declarationBatch || undefined, //申报批次
  295. projectAmount: this.state.projectAmount || undefined, //项目金额
  296. thchId: this.state.thchId || undefined, //咨询师/咨询经理id
  297. taskProjectStatus: this.state.taskProjectStatus || undefined,//项目状态
  298. sdStatus: this.state.sdStatus,//满意度
  299. };
  300. $.ajax({
  301. method: "get",
  302. dataType: "json",
  303. crossDomain: false,
  304. url: "/api/admin/statistis/exporTaskList",
  305. data,
  306. success: function (data) {
  307. if (data.error.length === 0) {
  308. this.download(data.data);
  309. } else {
  310. message.warning(data.error[0].message);
  311. }
  312. }.bind(this),
  313. }).always(
  314. function () {
  315. loading();
  316. this.setState({
  317. exportPendingLoading: false,
  318. });
  319. }.bind(this)
  320. );
  321. }
  322. // 下载
  323. download(fileName) {
  324. window.location.href =
  325. globalConfig.context + "/open/download?fileName=" + fileName;
  326. }
  327. // 查询用户
  328. supervisor(e) {
  329. $.ajax({
  330. method: "get",
  331. dataType: "json",
  332. crossDomain: false,
  333. url: globalConfig.context + "/api/admin/customer/listAdminByName",
  334. data: {
  335. adminName: e,
  336. },
  337. success: function (data) {
  338. let thedata = data.data;
  339. if (!thedata) {
  340. if (data.error && data.error.length) {
  341. message.warning(data.error[0].message);
  342. }
  343. thedata = {};
  344. }
  345. this.setState({
  346. customerArr: thedata,
  347. });
  348. }.bind(this),
  349. }).always(
  350. function () {
  351. }.bind(this)
  352. );
  353. }
  354. // 输入触发
  355. httpChange(e) {
  356. if (e.length >= 1) {
  357. this.supervisor(e);
  358. }
  359. this.setState({
  360. auto: e,
  361. });
  362. }
  363. // 选中
  364. selectAuto(value, options) {
  365. let thchId = ""
  366. let contactLists = this.state.customerArr || [];
  367. if (value) {
  368. contactLists.map(function (item) {
  369. if (item.name == value.toString()) {
  370. thchId = item.id;
  371. }
  372. });
  373. }
  374. this.setState({
  375. auto: value,
  376. thchId: thchId,
  377. });
  378. }
  379. // 失去焦点
  380. blurChange(e) {
  381. let thchId = ""
  382. let contactLists = this.state.customerArr || [];
  383. if (e) {
  384. contactLists.map(function (item) {
  385. if (item.name == e.toString()) {
  386. thchId = item.id;
  387. }
  388. });
  389. }
  390. this.setState({
  391. thchId: thchId,
  392. });
  393. }
  394. componentWillMount() {
  395. //
  396. if (!this.props.introduce) {
  397. this.defaultcolumns();
  398. this.selectSuperId();
  399. }
  400. if (this.props.searchData) {
  401. let e = this.props.searchData.projectType;
  402. this.setState({
  403. columns:
  404. e == "0"
  405. ? currency : e == "1"
  406. ? patent : e == "2"
  407. ? softWriting : e == "3"
  408. ? audit : e == "4"
  409. ? doubleSoft : e == "5"
  410. ? highTechColumns : e == "6"
  411. ? currency : e == "7"
  412. ? member : currency,
  413. }, () => {
  414. this.defaultcolumns();
  415. });
  416. }
  417. }
  418. // 暂停项目 颜色
  419. suspendColor(record) {
  420. if (record.projectStatus == 29) {
  421. return 'light'
  422. } else {
  423. return 'dark'
  424. }
  425. }
  426. render() {
  427. const dataSources = this.state.customerArr || [];
  428. const options = dataSources.map((group) => (
  429. <Select.Option key={group.id} value={group.name}>
  430. {group.name}
  431. </Select.Option>
  432. ));
  433. return (
  434. <div className="user-content">
  435. {this.props.introduce ? (
  436. this.props.introduce()
  437. ) : (
  438. <div>
  439. <div className="content-title" style={{ marginBottom: 10 }}>
  440. <span style={{ fontWeight: 900, fontSize: 16 }}>
  441. 项目汇总表 (
  442. {this.state.status === 1
  443. ? "高新" : this.state.status === 2
  444. ? "双软" : this.state.status === 3
  445. ? "软著" : this.state.status === 4
  446. ? "专利" : this.state.status === 5
  447. ? "会员" : this.state.status === 6
  448. ? "审计" : "通用"}
  449. )
  450. </span>
  451. </div>
  452. <Tabs defaultActiveKey="1" className="test"
  453. onChange={e => {
  454. this.setState({
  455. tbaindex: e
  456. })
  457. }}
  458. >
  459. <TabPane tab="搜索" key="1">
  460. <div
  461. className="user-search"
  462. style={{
  463. marginTop: "10px",
  464. marginLeft: "10px",
  465. marginRight: "10px",
  466. }}
  467. >
  468. <Input
  469. placeholder="订单编号"
  470. style={{
  471. width: 220,
  472. marginRight: "10px",
  473. }}
  474. value={this.state.searchOrderNo}
  475. onChange={(e) => {
  476. this.setState({ searchOrderNo: e.target.value });
  477. }}
  478. />
  479. <Input
  480. placeholder="合同编号"
  481. style={{
  482. width: 220,
  483. marginRight: "10px",
  484. }}
  485. value={this.state.searchContractNo}
  486. onChange={(e) => {
  487. this.setState({ searchContractNo: e.target.value });
  488. }}
  489. />
  490. <Input
  491. placeholder="企业名称"
  492. style={{
  493. width: 220,
  494. marginRight: "10px",
  495. }}
  496. value={this.state.searchEnterpriseName}
  497. onChange={(e) => {
  498. this.setState({ searchEnterpriseName: e.target.value });
  499. }}
  500. />
  501. <span style={{ display: "inline-block" }}>
  502. <span style={{ marginRight: "10px" }}>项目分类:</span>
  503. <Cascader
  504. options={this.state.contactsOptionData}
  505. value={this.state.newArray}
  506. placeholder="请选择"
  507. style={{ width: 150, marginRight: 10 }}
  508. onChange={(e, pre) => {
  509. let first = e[0];
  510. let two = e[1];
  511. this.setState({
  512. newArray: e,
  513. projectStatus: first,
  514. projectType: two,
  515. changeList: undefined,
  516. dataSource: [],
  517. status:
  518. two == "4"
  519. ? 2 : two == "3"
  520. ? 6 : two == "2"
  521. ? 3 : two == "1"
  522. ? 4 : two == "5"
  523. ? 1 : two == "7"
  524. ? 5 : 0,
  525. columns:
  526. two == "0"
  527. ? currency : two == "1"
  528. ? patent : two == "2"
  529. ? softWriting : two == "3"
  530. ? audit : two == "4"
  531. ? doubleSoft : two == "5"
  532. ? highTechColumns : two == "6"
  533. ? currency : two == "7"
  534. ? member : currency,
  535. }, () => {
  536. this.defaultcolumns()
  537. })
  538. }}
  539. />
  540. </span>
  541. {/* <span style={{ display: "inline-block" }}>
  542. <span style={{ marginRight: "10px" }}>
  543. 项目类别 :
  544. </span>
  545. <Select
  546. value={this.state.projectStatus || undefined}
  547. placeholder="请选择项目类别"
  548. notFoundContent="未获取到上级品类列表"
  549. style={{
  550. width: 150,
  551. marginRight: "10px",
  552. }}
  553. onChange={(e) => {
  554. let infor = this.state.contactsOptionData.filter(
  555. (v) => v.id === e
  556. );
  557. this.setState(
  558. {
  559. projectStatus: e,
  560. },
  561. // () => {
  562. // if (infor[0].cname === '高新会员服务' && typeof this.state.projectType !== 'number') {
  563. // this.setState({
  564. // columns: highTechColumns,
  565. // dataSource: [],
  566. // changeList: [],
  567. // status: 1,
  568. // }, () => {
  569. // this.loadData();
  570. // })
  571. // } else if (typeof this.state.projectType !== 'number') {
  572. // this.setState({
  573. // columns: currency,
  574. // dataSource: [],
  575. // changeList: [],
  576. // status: 0,
  577. // }, () => {
  578. // this.loadData();
  579. // })
  580. // } else {
  581. // this.loadData();
  582. // }
  583. // }
  584. );
  585. }}
  586. >
  587. {this.state.contactsOption}
  588. </Select>
  589. </span>
  590. <span style={{ display: "inline-block" }}>
  591. <span style={{ marginRight: "10px", marginBottom: "10px" }}>
  592. 项目分类 :
  593. </span>
  594. <Select
  595. value={
  596. typeof this.state.projectType === "number"
  597. ? this.state.projectType
  598. : undefined
  599. }
  600. placeholder="请选择项目分类"
  601. style={{
  602. width: 150,
  603. marginRight: "10px",
  604. }}
  605. onChange={(e) => {
  606. this.setState(
  607. {
  608. columns:
  609. e === 0
  610. ? currency : e === 1
  611. ? patent : e === 2
  612. ? softWriting : e === 3
  613. ? currency : e === 4
  614. ? doubleSoft : e === 5
  615. ? highTechColumns : e === 6
  616. ? currency : currency,
  617. changeList: [],
  618. projectType: e,
  619. status:
  620. e === 4
  621. ? 2 : e === 2
  622. ? 3 : e === 1
  623. ? 4 : e === 5
  624. ? 1 : 0,
  625. dataSource: [],
  626. },
  627. () => {
  628. this.defaultcolumns();
  629. this.loadData();
  630. }
  631. );
  632. }}
  633. >
  634. <Option value={0}>通用</Option>
  635. <Option value={1}>专利</Option>
  636. <Option value={2}>软著</Option>
  637. <Option value={3}>审计</Option>
  638. <Option value={4}>双软</Option>
  639. <Option value={5}>高新</Option>
  640. <Option value={6}>商标</Option>
  641. <Option value={7}>会员</Option>
  642. </Select>
  643. </span> */}
  644. <span
  645. style={{
  646. display: "inline-block",
  647. }}
  648. >
  649. <span style={{ marginBottom: "10px" }}>订单部门:</span>
  650. <Cascaders
  651. ref={ref => this.Cascaders1 = ref}
  652. placeholder="请选择订单部门"
  653. height={28}
  654. width={150}
  655. onSel={(e) => {
  656. this.setState({
  657. deps: JSON.stringify(e)
  658. })
  659. }}
  660. />
  661. </span>
  662. <span
  663. style={{
  664. display: "inline-block",
  665. }}
  666. >
  667. <span style={{ marginBottom: "10px" }}>负责部门:</span>
  668. <Cascaders
  669. ref={ref => this.Cascaders2 = ref}
  670. placeholder="请选择负责部门"
  671. height={28}
  672. width={150}
  673. onSel={(e) => {
  674. this.setState({
  675. thchDeps: JSON.stringify(e)
  676. })
  677. }}
  678. />
  679. </span>
  680. <span style={{ display: "inline-block" }}>
  681. <span style={{ marginRight: "10px", marginBottom: "10px" }}>
  682. 咨询师/经理:
  683. </span>
  684. <AutoComplete
  685. className="certain-category-search"
  686. dropdownClassName="certain-category-search-dropdown"
  687. dropdownMatchSelectWidth={false}
  688. style={{ width: 130 }}
  689. dataSource={options}
  690. placeholder='请输入姓名'
  691. value={this.state.auto}
  692. onChange={this.httpChange}
  693. filterOption={true}
  694. onBlur={this.blurChange}
  695. onSelect={this.selectAuto}
  696. >
  697. <Input />
  698. </AutoComplete>
  699. </span>
  700. <span style={{ display: "inline-block" }}>
  701. <span style={{ marginRight: "10px", marginBottom: "10px" }}>
  702. 申报批次:
  703. </span>
  704. <Select
  705. value={this.state.declarationBatch || undefined}
  706. placeholder="请选择批次"
  707. style={{
  708. width: 150,
  709. marginRight: "10px",
  710. }}
  711. onChange={(e) => {
  712. this.setState({
  713. declarationBatch: e,
  714. });
  715. }}
  716. >
  717. <Option value={1}>第一批</Option>
  718. <Option value={2}>第二批</Option>
  719. <Option value={3}>第三批</Option>
  720. <Option value={4}>第四批</Option>
  721. </Select>
  722. </span>
  723. <span style={{ display: "inline-block" }}>
  724. <span style={{ marginRight: "10px" }}>
  725. 项目金额:
  726. </span>
  727. <Select
  728. value={this.state.projectAmount || undefined}
  729. placeholder="请选择项目金额"
  730. style={{
  731. width: 150,
  732. marginRight: "10px",
  733. }}
  734. onChange={(e) => {
  735. this.setState({
  736. projectAmount: e,
  737. });
  738. }}
  739. >
  740. <Option value={1}>0~0.5万</Option>
  741. <Option value={2}>0.5~1万</Option>
  742. <Option value={3}>1~2万</Option>
  743. <Option value={4}>2~5万</Option>
  744. <Option value={5}>5~10万</Option>
  745. <Option value={6}>10~30万</Option>
  746. <Option value={7}>30~50万</Option>
  747. <Option value={8}>50~80万</Option>
  748. <Option value={9}>80万上</Option>
  749. </Select>
  750. </span>
  751. <span style={{ display: "inline-block" }}>
  752. <span style={{ marginRight: "10px" }}>
  753. 项目状态:
  754. </span>
  755. <Select
  756. value={this.state.taskProjectStatus || undefined}
  757. placeholder="请选择项目状态"
  758. style={{
  759. width: 150,
  760. marginRight: "10px",
  761. }}
  762. onChange={(e) => {
  763. this.setState({
  764. taskProjectStatus: e,
  765. });
  766. }}
  767. >
  768. {
  769. projectStatusList.map((item) =>
  770. <Option value={item.value} key={item.value}>{item.label}</Option>
  771. )
  772. }
  773. </Select>
  774. </span>
  775. {/* <span style={{display:"inline-block"}}>*/}
  776. {/* <span style={{marginRight:'10px',marginBottom:'10px'}}>项目情况 :</span>*/}
  777. {/* <Select*/}
  778. {/* value={typeof this.state.projectSituation === 'number' ? this.state.projectSituation : undefined}*/}
  779. {/* placeholder="请选择项目情况"*/}
  780. {/* style={{ width: 200,marginRight:'10px',marginBottom:'10px' }}*/}
  781. {/* onChange={(e) => {*/}
  782. {/* this.setState({*/}
  783. {/* projectSituation: e,*/}
  784. {/* });*/}
  785. {/* }}*/}
  786. {/* >*/}
  787. {/* <Option value={0}>未开始</Option>*/}
  788. {/* <Option value={1}>进行中</Option>*/}
  789. {/* <Option value={2}>已暂停</Option>*/}
  790. {/* <Option value={3}>已驳回(专利、软著项目编写)</Option>*/}
  791. {/* <Option value={4}>已完成</Option>*/}
  792. {/* <Option value={5}>项目已完成 已退单</Option>*/}
  793. {/* <Option value={6}>项目未完成 已退单</Option>*/}
  794. {/* </Select>*/}
  795. {/*</span>*/}
  796. <span style={{ display: "inline-block" }}>
  797. <span style={{ marginRight: "10px" }}>
  798. 满&nbsp;&nbsp;意&nbsp;&nbsp;度:
  799. </span>
  800. <Select
  801. value={this.state.sdStatus}
  802. placeholder="请选择满意度"
  803. style={{
  804. width: 150,
  805. marginRight: "10px",
  806. }}
  807. onChange={(e) => {
  808. this.setState({
  809. sdStatus: e,
  810. });
  811. }}
  812. >
  813. <Option value={0}>未发放</Option>
  814. <Option value={1}>已发放</Option>
  815. <Option value={2}>已回收(非常满意)</Option>
  816. <Option value={3}>已回收(满意)</Option>
  817. <Option value={4}>已回收(一般)</Option>
  818. <Option value={5}>已回收(不满意)</Option>
  819. </Select>
  820. </span>
  821. <span style={{ display: "inline-block" }}>
  822. <span style={{ marginRight: "10px" }}>
  823. 派单时间:
  824. </span>
  825. <RangePicker
  826. allowClear={false}
  827. style={{ marginRight: "10px" }}
  828. value={[
  829. this.state.releaseDate[0]
  830. ? moment(this.state.releaseDate[0])
  831. : null,
  832. this.state.releaseDate[1]
  833. ? moment(this.state.releaseDate[1])
  834. : null,
  835. ]}
  836. onChange={(data, dataString) => {
  837. this.setState({ releaseDate: dataString });
  838. }}
  839. />
  840. </span>
  841. <Button
  842. type="primary"
  843. onClick={() => {
  844. this.loadData();
  845. }}
  846. style={{ marginRight: "10px", marginBottom: "10px" }}
  847. >
  848. 搜索
  849. </Button>
  850. <Button
  851. onClick={this.resetAll}
  852. style={{ marginRight: "10px", marginBottom: "10px" }}
  853. >
  854. 重置
  855. </Button>
  856. </div>
  857. </TabPane>
  858. <TabPane tab="更改表格显示数据" key="2">
  859. {
  860. this.state.tbaindex == 2 &&
  861. <div style={{ marginLeft: 10 }}>
  862. <ChooseList
  863. columns={this.state.columns}
  864. changeFn={this.changeList}
  865. changeList={this.state.changeList}
  866. top={55}
  867. margin={11}
  868. />
  869. </div>
  870. }
  871. </TabPane>
  872. <TabPane tab="导出EXCEL" key="3">
  873. <Button
  874. type="primary"
  875. style={{ margin: "10px" }}
  876. onClick={this.exportExec.bind(this)}
  877. >
  878. 导出excel
  879. </Button>
  880. </TabPane>
  881. </Tabs>
  882. </div>
  883. )}
  884. <div className="patent-table">
  885. <Spin spinning={this.state.loading}>
  886. <Table
  887. bordered
  888. size="middle"
  889. scroll={{
  890. x:
  891. this.state.status === 4 || this.state.status === 3
  892. ? 1800
  893. : 1000,
  894. y: 0,
  895. }}
  896. columns={
  897. (this.state.changeList && this.state.changeList.length != 0)
  898. ? this.state.changeList
  899. : this.state.columns
  900. }
  901. dataSource={this.state.dataSource}
  902. pagination={this.state.pagination}
  903. style={{
  904. cursor: "pointer",
  905. }}
  906. rowClassName={this.suspendColor}
  907. onRowClick={(record) => {
  908. this.setState({
  909. projectdetailsId: record.id,
  910. projectdetailsOrderNo: record.orderNo,
  911. pname: record.pname,
  912. visible: true,
  913. });
  914. }}
  915. />
  916. </Spin>
  917. </div>
  918. {this.state.visible ? (
  919. <ProjectDetails
  920. visible={this.state.visible}
  921. id={this.state.projectdetailsId}
  922. orderNo={this.state.projectdetailsOrderNo}
  923. taskName={this.state.pname}
  924. visitOk={() => {
  925. this.setState({
  926. visible: false,
  927. });
  928. }}
  929. visitCancel={() => {
  930. this.loadData(this.state.page);
  931. this.setState({
  932. visible: false,
  933. });
  934. }}
  935. />
  936. ) : null}
  937. </div>
  938. );
  939. }
  940. }
  941. export default HighTech;