projectvip.jsx 26 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926
  1. import React from "react";
  2. import $ from "jquery/src/ajax";
  3. import "./public.less";
  4. import "./shouKuan.less";
  5. import { AutoComplete, Button, Input, Spin, Table, Select, message, Tabs, Tag, Tooltip, Modal } from "antd";
  6. import OrderDesc from "../orderDetail/orderDesc";
  7. import { ChooseList } from "../../order/orderNew/chooseList"
  8. import ReactToPrint from "react-to-print";
  9. import OrderItemStatus from "../../../common/orderItemStatus";
  10. import { salesList } from "@/dataDic.js";
  11. import ShowModalDiv from "@/showModal.jsx";
  12. import VipLogs from "../../../common/logPopup/viplogs";//会员日志
  13. import { splitUrl } from "@/tools";
  14. import ImgList from "../../../common/imgList";
  15. const { TabPane } = Tabs;
  16. //财务专员会员项目审核
  17. const ProjectVip = React.createClass({
  18. //
  19. getInitialState() {
  20. return {
  21. dvisible: false,
  22. pageNo: 1,
  23. totalPage: 0,
  24. searchValues: {
  25. status: "1"
  26. },//查询条件
  27. loading: false,
  28. changeList: undefined,// 子组件改变的表格title数组
  29. pagination: {
  30. defaultCurrent: 1,
  31. defaultPageSize: 10,
  32. showQuickJumper: true,
  33. pageSize: 10,
  34. onChange: function (page) {
  35. this.setState({
  36. pageNo: page,
  37. });
  38. this.loadData(page);
  39. }.bind(this),
  40. showTotal: function (total) {
  41. return "共" + total + "条数据";
  42. },
  43. },
  44. columns: [
  45. {
  46. title: "销售类型",
  47. dataIndex: "salesType",
  48. key: "salesType",
  49. className: "title-table",
  50. render: (text, record) => {
  51. return (
  52. <Tooltip
  53. title={salesList[text] + ((text == 3 || text == 4 || text == 5) ? (!record.other ? "" : "," + record.other) : "")}
  54. >
  55. <span>
  56. {salesList[text]}
  57. </span>
  58. </Tooltip>
  59. );
  60. },
  61. },
  62. {
  63. title: "合同编号",
  64. dataIndex: "contractNo",
  65. key: "contractNo",
  66. className: "title-table",
  67. width: 160,
  68. render: (text, record) => {
  69. return (
  70. <Tooltip
  71. title={
  72. <Button
  73. type="primary"
  74. onClick={(e) => {
  75. e.stopPropagation();
  76. let input = document.getElementById("copyText");
  77. input.value = text;
  78. input.select();
  79. document.execCommand("copy");
  80. message.success("复制成功");
  81. }}
  82. >
  83. 复制
  84. </Button>
  85. }
  86. >
  87. <div>
  88. {text}
  89. <div style={{ display: "flex" }}>
  90. <OrderItemStatus deleteSign={record.deleteSign} />
  91. {
  92. record.approval == 1
  93. ? <Tag color="#faa755">特批待审</Tag> :
  94. record.approval == 2 && <Tag color="#ff0000">特批通过</Tag>
  95. }
  96. </div>
  97. </div>
  98. </Tooltip>
  99. );
  100. },
  101. },
  102. {
  103. title: "客户名称",
  104. dataIndex: "userName",
  105. key: "userName",
  106. className: "title-table",
  107. width: 200,
  108. render: text => {
  109. return (
  110. <Tooltip title={text}>
  111. <div>{text}</div>
  112. </Tooltip>
  113. )
  114. }
  115. },
  116. {
  117. title: "订单编号",
  118. dataIndex: "orderNo",
  119. key: "orderNo",
  120. className: "title-table",
  121. width: 140,
  122. render: (text, record) => {
  123. return (
  124. <Tooltip
  125. title={
  126. <Button
  127. type="primary"
  128. onClick={(e) => {
  129. e.stopPropagation();
  130. let input = document.getElementById("copyText");
  131. input.value = text;
  132. input.select();
  133. document.execCommand("copy");
  134. message.success("复制成功");
  135. }}
  136. >
  137. 复制
  138. </Button>
  139. }
  140. >
  141. <div>
  142. {text}
  143. <div>
  144. {record.totalAmount >= 10 && <Tag color="#ef7207">大客户</Tag>}
  145. {record.projectType == 1 && <Tag color="rgb(22, 155, 213)">会员</Tag>}
  146. </div>
  147. </div>
  148. </Tooltip>
  149. );
  150. },
  151. },
  152. {
  153. title: "订单部门",
  154. dataIndex: "depName",
  155. key: "depName",
  156. className: "title-table",
  157. },
  158. {
  159. title: "订单负责人",
  160. dataIndex: "salesmanName",
  161. key: "salesmanName",
  162. className: "title-table",
  163. },
  164. {
  165. title: "财务负责人",
  166. dataIndex: "financeName",
  167. key: "financeName",
  168. className: "title-table",
  169. },
  170. {
  171. title: "会员项目",
  172. dataIndex: "projectName",
  173. key: "projectName",
  174. className: "title-table",
  175. render: (text, record) => {
  176. return (
  177. <div>
  178. {text}
  179. {(record.memberType == 1 || record.memberType == 2) && <Tag color="#ff0000">特批项目</Tag>}
  180. </div>
  181. )
  182. }
  183. },
  184. {
  185. title: "数量",
  186. dataIndex: "commodityQuantity",
  187. key: "commodityQuantity",
  188. className: "title-table",
  189. },
  190. {
  191. title: "项目说明",
  192. dataIndex: "taskComment",
  193. key: "taskComment",
  194. className: "title-table",
  195. width: 300,
  196. },
  197. {
  198. title: "状态",
  199. dataIndex: "status",
  200. key: "status",
  201. className: "title-table",
  202. width: 80,
  203. render: (text) => {
  204. return (
  205. <div>
  206. {["", "财务审核", "特批审核", "通过", "驳回"][text]}
  207. </div>
  208. );
  209. }
  210. },
  211. {
  212. title: "操作",
  213. dataIndex: "pictureUrl",
  214. key: "pictureUrl",
  215. className: "title-table",
  216. render: (text, recard) => {
  217. return (
  218. <div>
  219. <Button
  220. type="primary"
  221. style={{ margin: 5 }}
  222. onClick={(e) => {
  223. e.stopPropagation();
  224. let arr = text || [];
  225. this.setState({
  226. pictureUrlArr: splitUrl(arr, ",", globalConfig.avatarHost + "/upload"),
  227. recard,
  228. }, () => {
  229. this.setState({
  230. imgListVisible: true,
  231. })
  232. })
  233. }}
  234. >
  235. 审核
  236. </Button>
  237. <VipLogs id={recard.id} />
  238. </div>
  239. );
  240. },
  241. },
  242. ],
  243. dataSource: [],
  244. fjlist: [],// 营销员列表
  245. checkOrderNo: "",//操作订单编号
  246. checkData: "",//操作描述
  247. checkVisible: "",//审核弹窗开关
  248. checkId: "",//会员项目编号
  249. result: -1,//1同意 0驳回
  250. imgListVisible: false,//附件弹窗
  251. pictureUrlArr: [],//附件
  252. recard: {},
  253. };
  254. },
  255. componentWillMount() {
  256. this.loadData();
  257. this.departmentList();
  258. },
  259. // 获取订单部门
  260. departmentList() {
  261. $.ajax({
  262. method: "get",
  263. dataType: "json",
  264. crossDomain: false,
  265. url: globalConfig.context + "/api/admin/organization/selectSuperId",
  266. data: {},
  267. success: function (data) {
  268. let thedata = data.data;
  269. let theArr = [];
  270. if (!thedata) {
  271. if (data.error && data.error.length) {
  272. message.warning(data.error[0].message);
  273. }
  274. } else {
  275. thedata.map(function (item, index) {
  276. theArr.push({
  277. key: index,
  278. name: item.name,
  279. id: item.id,
  280. });
  281. });
  282. }
  283. this.setState({
  284. departmentArr: theArr,
  285. });
  286. }.bind(this),
  287. }).always(
  288. function () {
  289. }.bind(this)
  290. );
  291. },
  292. // 列表数据
  293. loadData(pageNo, pageSize) {
  294. const { searchValues, pagination } = this.state
  295. this.setState({
  296. loading: true,
  297. });
  298. let datas = Object.assign(searchValues, {
  299. pageNo: pageNo || 1,
  300. pageSize: pageSize || 10,
  301. shiroType: 2, //财务审核
  302. });
  303. $.ajax({
  304. method: "get",
  305. dataType: "json",
  306. crossDomain: false,
  307. url: globalConfig.context + "/api/admin/orderProject/memberList",
  308. data: datas,
  309. success: function (data) {
  310. this.setState({
  311. loading: false,
  312. });
  313. if (data.error && data.error.length === 0) {
  314. if (data.data.list) {
  315. pagination.current = data.data.pageNo;
  316. pagination.total = data.data.totalCount;
  317. if (data.data && data.data.list && !data.data.list.length) {
  318. pagination.current = 0;
  319. pagination.total = 0;
  320. }
  321. this.setState({
  322. dataSource: data.data.list,
  323. pagination: this.state.pagination,
  324. pageNo: data.data.pageNo,
  325. totalPage: data.data.totalPage,
  326. });
  327. } else {
  328. this.setState({
  329. dataSource: data.data,
  330. pagination: false,
  331. });
  332. }
  333. } else {
  334. message.warning(data.error[0].message);
  335. }
  336. }.bind(this),
  337. }).always(
  338. function () {
  339. this.setState({
  340. loading: false,
  341. });
  342. }.bind(this)
  343. );
  344. },
  345. // 点击行
  346. tableRowClick(record) {
  347. this.state.RowData = record;
  348. this.setState({
  349. showDesc: true,
  350. });
  351. },
  352. // 关闭
  353. closeDesc(e, s) {
  354. this.state.showDesc = e;
  355. if (s) {
  356. this.loadData(this.state.pageNo);
  357. }
  358. },
  359. // 搜索
  360. search() {
  361. this.setState({
  362. selectedRowKeys: []
  363. })
  364. this.loadData();
  365. },
  366. // 重置
  367. reset() {
  368. this.setState({
  369. searchValues: JSON.parse(JSON.stringify({})),
  370. }, () => {
  371. this.loadData();
  372. })
  373. },
  374. // 点击审核
  375. checkRemark(nmb) {
  376. this.setState({
  377. checkVisible: true,
  378. checkId: this.state.recard.id,
  379. result: nmb
  380. });
  381. },
  382. // 审核
  383. toExamine() {
  384. if (!this.state.checkData) {
  385. message.warning("请填写审核说明~");
  386. return;
  387. }
  388. this.setState({
  389. loading: true,
  390. });
  391. $.ajax({
  392. method: "POST",
  393. dataType: "json",
  394. crossDomain: false,
  395. url: globalConfig.context + "/api/admin/orderProject/examineMemberProject",
  396. data: {
  397. id: this.state.checkId,
  398. remarks: this.state.checkData,
  399. result: this.state.result, //1同意 0驳回
  400. type: 0, //0财务审核 1特批审核
  401. },
  402. }).done(
  403. function (data) {
  404. if (!data.error.length) {
  405. message.success("审核成功!");
  406. this.setState({
  407. loading: false,
  408. checkVisible: false,
  409. checkData: '',
  410. imgListVisible: false,
  411. });
  412. this.loadData()
  413. } else {
  414. message.warning(data.error[0].message);
  415. }
  416. }.bind(this)
  417. );
  418. },
  419. // 更改表格显示数据
  420. changeList(arr) {
  421. const newArr = [];
  422. this.state.columns.forEach((item) => {
  423. arr.forEach((val) => {
  424. if (val === item.title) {
  425. newArr.push(item);
  426. }
  427. });
  428. });
  429. this.setState({
  430. changeList: newArr,
  431. });
  432. },
  433. // 导出当前列表
  434. exportAll() {
  435. message.config({
  436. duration: 20,
  437. });
  438. let loading = message.loading("下载中...");
  439. this.setState({
  440. exportPendingLoading: true,
  441. });
  442. let data = {
  443. shiroType: 2, //财务审核
  444. };
  445. let obj1 = JSON.parse(JSON.stringify(this.state.searchValues));
  446. data = Object.assign(data, obj1);
  447. $.ajax({
  448. method: "get",
  449. dataType: "json",
  450. crossDomain: false,
  451. url: "/api/admin/orderProject/memberList/export",
  452. data,
  453. success: function (data) {
  454. if (data.error.length === 0) {
  455. this.download(data.data);
  456. } else {
  457. message.warning(data.error[0].message);
  458. }
  459. }.bind(this),
  460. }).always(
  461. function () {
  462. loading();
  463. this.setState({
  464. exportPendingLoading: false,
  465. });
  466. }.bind(this)
  467. );
  468. },
  469. // 打印
  470. printAll() {
  471. this.setState({
  472. dvisible: true,
  473. });
  474. this.loadData(1, 9999999);
  475. },
  476. // 下载
  477. download(fileName) {
  478. window.location.href =
  479. globalConfig.context + "/open/download?fileName=" + fileName;
  480. },
  481. // 查询订单负责人列表
  482. followUp(e) {
  483. const { searchValues } = this.state;
  484. this.setState({
  485. searchValues: Object.assign(searchValues, {
  486. aname: e,
  487. }),
  488. });
  489. $.ajax({
  490. method: "get",
  491. dataType: "json",
  492. crossDomain: false,
  493. url: globalConfig.context + "/api/admin/customer/listAdminByName",
  494. data: {
  495. adminName: e,
  496. },
  497. success: function (data) {
  498. let thedata = data.data;
  499. if (!thedata) {
  500. if (data.error && data.error.length) {
  501. message.warning(data.error[0].message);
  502. }
  503. thedata = {};
  504. }
  505. this.setState({
  506. fjlist: thedata,
  507. });
  508. }.bind(this),
  509. }).always(
  510. function () {
  511. this.setState({
  512. loading: false,
  513. });
  514. }.bind(this)
  515. );
  516. },
  517. // 选中订单负责人
  518. selectF(value) {
  519. const { searchValues, fjlist } = this.state;
  520. const newdataSources = JSON.stringify(fjlist) == "{}" ? [] : fjlist;
  521. this.setState({
  522. searchValues: Object.assign(searchValues, {
  523. salesmanId: newdataSources.find((item) => item.name == value).id,
  524. }),
  525. });
  526. },
  527. // 失去焦点
  528. blurChange(e) {
  529. let theType = "";
  530. let contactLists = this.state.customerArr || [];
  531. if (e) {
  532. contactLists.map(function (item) {
  533. if (item.name == e.toString()) {
  534. theType = item.id;
  535. }
  536. });
  537. }
  538. this.setState({
  539. theTypes: theType,
  540. });
  541. },
  542. // 删除数组最后一项(删除操作列)
  543. truncate(arr) {
  544. return arr.filter(function (v, i, ar) {
  545. return i !== ar.length - 1
  546. })
  547. },
  548. render() {
  549. const { TextArea } = Input
  550. const { searchValues, departmentArr = [] } = this.state
  551. const dataSources = this.state.fjlist || [];
  552. const options = dataSources.map((group) => (
  553. <Select.Option key={group.id} value={group.name}>
  554. {group.name}
  555. </Select.Option>
  556. ));
  557. return (
  558. <div className="user-content">
  559. <ShowModalDiv ShowModal={this.state.showModal} />
  560. <div className="content-title" style={{ marginBottom: 10 }}>
  561. <span style={{ fontWeight: 900, fontSize: 16 }}>会员项目审核</span>
  562. </div>
  563. <Tabs defaultActiveKey="2" onChange={this.callback} className="test">
  564. <TabPane tab="更改表格显示数据" key="1">
  565. <div style={{ marginLeft: 10 }}>
  566. <ChooseList
  567. columns={this.state.columns}
  568. changeFn={this.changeList}
  569. changeList={this.state.changeList}
  570. top={55}
  571. margin={11}
  572. />
  573. </div>
  574. </TabPane>
  575. <TabPane tab="搜索" key="2">
  576. <div className="user-search" style={{ marginLeft: 10 }}>
  577. <Input
  578. placeholder="订单编号"
  579. value={searchValues["orderNo"]
  580. ? searchValues["orderNo"]
  581. : ""}
  582. onChange={(e) => {
  583. searchValues["orderNo"] = e.target.value;
  584. this.setState({
  585. searchValues: searchValues,
  586. });
  587. }}
  588. />
  589. <Input
  590. placeholder="客户名称"
  591. value={searchValues["userName"]
  592. ? searchValues["userName"]
  593. : ""}
  594. onChange={(e) => {
  595. searchValues["userName"] = e.target.value;
  596. this.setState({
  597. searchValues: searchValues,
  598. });
  599. }}
  600. />
  601. <Select
  602. placeholder="订单部门"
  603. style={{ width: 190, marginRight: 10 }}
  604. value={searchValues["depId"]
  605. ? searchValues["depId"]
  606. : undefined}
  607. onChange={(e) => {
  608. searchValues["depId"] = e;
  609. this.setState({
  610. searchValues: searchValues,
  611. });
  612. }}
  613. >
  614. {departmentArr.map(function (item) {
  615. return (
  616. <Select.Option key={item.id}>{item.name}</Select.Option>
  617. );
  618. })}
  619. </Select>
  620. <Input
  621. placeholder="合同编号"
  622. value={searchValues["contractNo"]
  623. ? searchValues["contractNo"]
  624. : ""}
  625. onChange={(e) => {
  626. searchValues["contractNo"] = e.target.value;
  627. this.setState({
  628. searchValues: searchValues,
  629. });
  630. }}
  631. />
  632. <AutoComplete
  633. className="certain-category-search"
  634. dropdownClassName="certain-category-search-dropdown"
  635. dropdownMatchSelectWidth={false}
  636. style={{ width: "120px" }}
  637. dataSource={options}
  638. placeholder="订单负责人"
  639. value={searchValues.aname || undefined}
  640. onChange={this.followUp.bind(this)}
  641. filterOption={true}
  642. onSelect={this.selectF.bind(this)}
  643. >
  644. <Input />
  645. </AutoComplete>
  646. <Input
  647. placeholder="项目名称"
  648. value={searchValues["projectName"]
  649. ? searchValues["projectName"]
  650. : ""}
  651. onChange={(e) => {
  652. searchValues["projectName"] = e.target.value;
  653. this.setState({
  654. searchValues: searchValues,
  655. });
  656. }}
  657. />
  658. <Select
  659. style={{ width: 120 }}
  660. placeholder="签单金额"
  661. value={searchValues["amountStatus"]
  662. ? searchValues["amountStatus"]
  663. : undefined}
  664. onChange={(e) => {
  665. searchValues["amountStatus"] = e;
  666. this.setState({
  667. searchValues: searchValues,
  668. });
  669. }}
  670. >
  671. <Option value="0">10万元以下</Option>
  672. <Option value="1">10~20万元</Option>
  673. <Option value="2">20~30万元</Option>
  674. <Option value="3">30~40万元</Option>
  675. <Option value="4">40万元以上</Option>
  676. </Select>
  677. <Select
  678. style={{ width: 120 }}
  679. placeholder="特批状态"
  680. value={searchValues["approval"]
  681. ? searchValues["approval"]
  682. : undefined}
  683. onChange={(e) => {
  684. searchValues["approval"] = e;
  685. this.setState({
  686. searchValues: searchValues,
  687. });
  688. }}
  689. >
  690. <Option value="0">非特批</Option>
  691. <Option value="1">特批待审</Option>
  692. <Option value="2">特批通过</Option>
  693. <Option value="4">全部特批</Option>
  694. </Select>
  695. <Select
  696. style={{ width: 120 }}
  697. placeholder="审核状态"
  698. value={searchValues["status"]
  699. ? searchValues["status"]
  700. : undefined}
  701. onChange={(e) => {
  702. searchValues["status"] = e;
  703. this.setState({
  704. searchValues: searchValues,
  705. });
  706. }}
  707. >
  708. <Option value="1">财务审核</Option>
  709. <Option value="2">特批审核</Option>
  710. <Option value="3">通过</Option>
  711. <Option value="5">全部</Option>
  712. </Select>
  713. <Button
  714. type="primary"
  715. onClick={this.search}
  716. style={{ marginLeft: 10 }}
  717. disabled={this.state.loading ? true : false}
  718. >
  719. 搜索
  720. </Button>
  721. <Button onClick={this.reset}>重置</Button>
  722. </div>
  723. </TabPane>
  724. <TabPane tab="打印" key="3">
  725. <Button
  726. type="primary"
  727. style={{ margin: "11px 0px 10px 10px" }}
  728. onClick={this.printAll}
  729. >
  730. 打印当前列表
  731. </Button>
  732. </TabPane>
  733. <TabPane tab="导出Excel" key="4">
  734. <Button
  735. type="primary"
  736. style={{ margin: "11px 0px 10px 10px" }}
  737. onClick={this.exportAll}
  738. >
  739. 导出当前列表
  740. </Button>
  741. </TabPane>
  742. </Tabs>
  743. <div className="patent-table">
  744. <Spin spinning={this.state.loading}>
  745. <Table
  746. bordered
  747. columns={
  748. this.state.changeList == undefined
  749. ? this.state.columns
  750. : this.state.changeList
  751. }
  752. dataSource={this.state.dataSource}
  753. pagination={this.state.pagination}
  754. onRowDoubleClick={this.tableRowClick.bind(this)}
  755. size="small"
  756. />
  757. </Spin>
  758. </div>
  759. <textarea id="copyText" style={{ opacity: 0 }} />
  760. {/* 订单详情 */}
  761. <OrderDesc
  762. data={this.state.RowData}
  763. showDesc={this.state.showDesc}
  764. closeDesc={this.closeDesc.bind(this)}
  765. />
  766. {
  767. //打印预览
  768. this.state.dvisible &&
  769. <Modal
  770. visible={this.state.dvisible}
  771. footer=""
  772. title="所有列表信息"
  773. className="admin-desc-content"
  774. width="1300px"
  775. onCancel={() => {
  776. this.loadData();
  777. this.setState({
  778. dvisible: false,
  779. });
  780. }}
  781. >
  782. <Spin spinning={this.state.loading}>
  783. <div
  784. className="patent-table"
  785. style={{
  786. padding: "25px 0 30px 30px",
  787. }}
  788. ref={(e) => {
  789. this.refs.all = e;
  790. }}
  791. >
  792. <Table
  793. columns={this.truncate(this.state.columns)}
  794. dataSource={this.state.dataSource}
  795. pagination={false}
  796. bordered
  797. size="small"
  798. />
  799. </div>
  800. </Spin>
  801. <ReactToPrint
  802. trigger={() => (
  803. <Button
  804. type="primary"
  805. style={{
  806. float: "right",
  807. marginTop: 10,
  808. position: "absolute",
  809. top: 0,
  810. right: 30,
  811. }}
  812. >
  813. 打印
  814. </Button>
  815. )}
  816. content={() => this.refs.all}
  817. />
  818. </Modal>
  819. }
  820. {
  821. //审核弹窗
  822. this.state.checkVisible &&
  823. <Modal
  824. width="400px"
  825. maskClosable={false}
  826. title="审核订单"
  827. confirmLoading={this.state.loading}
  828. visible={this.state.checkVisible}
  829. onOk={this.toExamine}
  830. okText={this.state.result == 1 ? "通过" : this.state.result == 0 && "驳回"}
  831. onCancel={() => {
  832. this.loadData()
  833. this.setState({
  834. checkVisible: false,
  835. checkData: '',
  836. })
  837. }}
  838. >
  839. <TextArea
  840. rows={4}
  841. value={this.state.checkData}
  842. onChange={(e) => {
  843. this.setState({
  844. checkData: e.target.value,
  845. })
  846. }}
  847. placeholder="请填写审核内容"
  848. />
  849. </Modal>
  850. }
  851. {
  852. //查看附件
  853. this.state.imgListVisible &&
  854. <Modal
  855. maskClosable={false}
  856. visible={this.state.imgListVisible}
  857. onOk={() => {
  858. this.setState({
  859. imgListVisible: false,
  860. });
  861. }}
  862. onCancel={() => {
  863. this.setState({
  864. imgListVisible: false,
  865. });
  866. }}
  867. width="600px"
  868. title="审核"
  869. footer=""
  870. >
  871. <div>附件</div>
  872. <div>
  873. <ImgList
  874. fileList={this.state.pictureUrlArr}
  875. domId="publicStatistics"
  876. />
  877. </div>
  878. <div
  879. style={{
  880. display: "flex",
  881. flexDirection: "row",
  882. justifyContent: "center",
  883. }}
  884. >
  885. {
  886. this.state.recard.status == 1 &&
  887. <Button
  888. type="primary"
  889. style={{ margin: '20px 10px 5px' }}
  890. onClick={(e) => {
  891. e.stopPropagation();
  892. this.checkRemark(1);
  893. }}
  894. >
  895. 通过
  896. </Button>
  897. }
  898. {
  899. this.state.recard.status == 1 &&
  900. <Button
  901. type="danger"
  902. style={{ margin: '20px 10px 5px' }}
  903. onClick={(e) => {
  904. e.stopPropagation();
  905. this.checkRemark(0);
  906. }}
  907. >
  908. 驳回
  909. </Button>
  910. }
  911. </div>
  912. </Modal>
  913. }
  914. </div>
  915. );
  916. },
  917. });
  918. export default ProjectVip;