outSpecial.jsx 29 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998
  1. import React from "react";
  2. import $ from "jquery/src/ajax";
  3. import "./public.less";
  4. import {Form, Button, Input, Spin, Table, message, Modal, Upload, Tabs, Popconfirm, Tooltip} from "antd";
  5. import {
  6. getProvinceA,
  7. getInvoiceStatus,
  8. getprovince,
  9. getStatus,
  10. getProcessStatus,
  11. getPeople,
  12. splitUrl
  13. } from "@/tools";
  14. const FormItem = Form.Item;
  15. import OrderDesc from "../orderDetail/orderDesc";
  16. import {ChooseList} from "../../order/orderNew/chooseList";
  17. import {getProjectName} from "../../../tools";
  18. const outSpecial = React.createClass({
  19. loadData(pageNo) {
  20. this.state.data = [];
  21. this.setState({
  22. loading: true
  23. });
  24. $.ajax({
  25. method: "get",
  26. dataType: "json",
  27. crossDomain: false,
  28. url:
  29. globalConfig.context +
  30. "/api/admin/orderInvoice/approvalOrderInvoiceList",
  31. data: {
  32. pageNo: pageNo || 1,
  33. pageSize: this.state.pagination.pageSize,
  34. name: this.state.nameSearch, //客户名称
  35. orderNo: this.state.orderNoSearch,
  36. orderDep: this.state.departmenttList,
  37. type: 1
  38. },
  39. success: function(data) {
  40. let theArr = [];
  41. if (!data.data || !data.data.list) {
  42. if (data.error && data.error.length) {
  43. message.warning(data.error[0].message);
  44. }
  45. } else {
  46. for (let i = 0; i < data.data.list.length; i++) {
  47. let thisdata = data.data.list[i];
  48. theArr.push({
  49. key: i,
  50. id: thisdata.id,
  51. status: thisdata.status,
  52. unitName: thisdata.unitName,
  53. orderNo: thisdata.orderno,
  54. name: thisdata.name,
  55. projectStatus: thisdata.projectStatus,
  56. processStatus: thisdata.processStatus,
  57. amount: thisdata.amount,
  58. sumAmount: thisdata.sumAmount,
  59. createTime: thisdata.createTime
  60. ? new Date(thisdata.createTime).toLocaleString()
  61. : "",
  62. settlementAmount: thisdata.settlementAmount,
  63. notAmount: thisdata.notAmount,
  64. approval: thisdata.approval
  65. });
  66. }
  67. }
  68. this.state.pagination.current = data.data.pageNo;
  69. this.state.pagination.total = data.data.totalCount;
  70. if (data.data && data.data.list && !data.data.list.length) {
  71. this.state.pagination.current = 0;
  72. this.state.pagination.total = 0;
  73. }
  74. this.setState({
  75. totalPage: data.data.totalPage,
  76. dataSource: theArr,
  77. pagination: this.state.pagination
  78. });
  79. }.bind(this)
  80. }).always(
  81. function() {
  82. this.setState({
  83. loading: false
  84. });
  85. }.bind(this)
  86. );
  87. },
  88. invoiceData() {
  89. this.setState({
  90. loading: true
  91. });
  92. $.ajax({
  93. method: "get",
  94. dataType: "json",
  95. crossDomain: false,
  96. url:
  97. globalConfig.context + "/api/admin/orderInvoice/selectByIdOrderInvoice",
  98. data: {
  99. id: this.state.id
  100. },
  101. success: function(data) {
  102. let thisdata = data.data;
  103. this.setState({
  104. orderNo: thisdata.orderNo,
  105. type: thisdata.type,
  106. status: thisdata.status,
  107. remarks: thisdata.remarks,
  108. invoiceType: thisdata.invoiceType,
  109. unitName: thisdata.unitName,
  110. taxNumber: thisdata.taxNumber,
  111. amount: thisdata.amount,
  112. banks: thisdata.banks,
  113. content: thisdata.content,
  114. unitAddress: thisdata.unitAddress,
  115. invoiceRemarks: thisdata.invoiceRemarks,
  116. unitMobile: thisdata.unitMobile,
  117. contractNo: thisdata.contractNo,
  118. post: thisdata.post,
  119. addressee: thisdata.addressee,
  120. addresseeMobile: thisdata.addresseeMobile,
  121. addresseeProvince: thisdata.addresseeProvince,
  122. addresseeCity: thisdata.addresseeCity,
  123. addresseeArea: thisdata.addresseeArea,
  124. alreadyAmount: thisdata.alreadyAmount,
  125. recipientAddress: thisdata.recipientAddress,
  126. orgCodeUrl: thisdata.voucherUrl
  127. ? splitUrl(
  128. thisdata.voucherUrl,
  129. ",",
  130. globalConfig.avatarHost + "/upload"
  131. )
  132. : []
  133. });
  134. }.bind(this)
  135. }).done(
  136. function() {
  137. this.setState({
  138. loading: false
  139. });
  140. }.bind(this)
  141. );
  142. },
  143. getInitialState() {
  144. return {
  145. searchMore: true,
  146. assignVisible: false,
  147. releaseDate: [],
  148. totalPage: 0,
  149. boHuivisible: false,
  150. selectedRowKeys: [],
  151. selectedRows: [],
  152. contractNo: "",
  153. loading: false,
  154. reason: "",
  155. foo: 0,
  156. pagination: {
  157. defaultCurrent: 1,
  158. defaultPageSize: 10,
  159. showQuickJumper: true,
  160. pageSize: 10,
  161. onChange: function(page) {
  162. this.loadData(page);
  163. }.bind(this),
  164. showTotal: function(total) {
  165. return "共" + total + "条数据";
  166. }
  167. },
  168. columns: [
  169. {
  170. title: "编号",
  171. dataIndex: "id",
  172. key: "id",
  173. },
  174. {
  175. title: "客户",
  176. dataIndex: "unitName",
  177. key: "unitName",
  178. width:100,
  179. render: text => {
  180. return (
  181. <Tooltip title={text}>
  182. <div style={{
  183. maxWidth:'100px',
  184. overflow:'hidden',
  185. textOverflow: "ellipsis",
  186. whiteSpace:'nowrap',
  187. }}>{text}</div>
  188. </Tooltip>
  189. )
  190. }
  191. },
  192. {
  193. title: "跟单人/签单人",
  194. dataIndex: "name",
  195. key: "name"
  196. },
  197. {
  198. title: "开票状态",
  199. dataIndex: "status",
  200. key: "status",
  201. render: text => {
  202. return getStatus(text);
  203. }
  204. },
  205. {
  206. title: "流程状态",
  207. dataIndex: "processStatus",
  208. key: "processStatus",
  209. render: text => {
  210. return getProcessStatus(text);
  211. }
  212. },
  213. {
  214. title: "项目状态",
  215. dataIndex: "projectStatus",
  216. key: "projectStatus",
  217. render: text => {
  218. return getProjectName(text);
  219. }
  220. },
  221. {
  222. title: "申请开票(万)",
  223. dataIndex: "amount",
  224. key: "amount"
  225. },
  226. {
  227. title: "已开票(万)",
  228. dataIndex: "sumAmount",
  229. key: "sumAmount"
  230. },
  231. {
  232. title: "已收款",
  233. dataIndex: "settlementAmount",
  234. key: "settlementAmount"
  235. },
  236. {
  237. title: "未收款",
  238. dataIndex: "notAmount",
  239. key: "notAmount"
  240. },
  241. {
  242. title: "申请时间",
  243. dataIndex: "createTime",
  244. key: "createTime"
  245. },
  246. {
  247. title: "操作",
  248. dataIndex: "caozuo",
  249. key: "caouzo",
  250. render: (text, record, index) => {
  251. return (
  252. <div>
  253. {
  254. <Button
  255. type="primary"
  256. onClick={e => {
  257. e.stopPropagation(), this.visit(index);
  258. }}
  259. style={{ background: "deepskyblue", border: "none" }}
  260. >
  261. 申请内容
  262. </Button>
  263. }
  264. {record.approval !== 2 ? (
  265. <Popconfirm placement="top" title="确定要通过吗?" onConfirm={(e)=>{
  266. e.stopPropagation();
  267. this.setState({ examine: 2 }, () => {
  268. this.sende(record);
  269. });
  270. }} okText="确定" cancelText="取消">
  271. <Button
  272. type="primary"
  273. style={{ marginLeft: "10px" }}
  274. onClick={e => {
  275. e.stopPropagation();
  276. }}
  277. >
  278. 通过
  279. </Button>
  280. </Popconfirm>
  281. ) : (
  282. ""
  283. )}
  284. {record.approval !== 2 ? (
  285. <Popconfirm placement="top" title="确定要拒绝吗?" onConfirm={(e)=>{
  286. e.stopPropagation();
  287. this.setState({ examine: 3 }, () => {
  288. this.reject(record);
  289. });
  290. }} okText="确定" cancelText="取消">
  291. <Button
  292. type="danger"
  293. onClick={e => {
  294. e.stopPropagation();
  295. }}
  296. style={{ marginLeft: "10px" }}
  297. >
  298. 拒绝
  299. </Button>
  300. </Popconfirm>
  301. ) : (
  302. ""
  303. )}
  304. {record.approval === 2 ? (
  305. <Button
  306. style={{ marginLeft: "10px", color: "black" }}
  307. disabled={true}
  308. >
  309. 已通过
  310. </Button>
  311. ) : (
  312. ""
  313. )}
  314. {
  315. <Button
  316. type="primary"
  317. style={{
  318. marginLeft: "10px",
  319. background: "orangered",
  320. border: "none"
  321. }}
  322. onClick={e => {
  323. e.stopPropagation(), this.inRecord(record, index);
  324. }}
  325. >
  326. 开票记录
  327. </Button>
  328. }
  329. </div>
  330. );
  331. }
  332. }
  333. ],
  334. columnsDate: [
  335. {
  336. title: "编号",
  337. dataIndex: "id",
  338. key: "id"
  339. },
  340. {
  341. title: "订单编号",
  342. dataIndex: "orderno",
  343. key: "orderno"
  344. },
  345. {
  346. title: "开票金额(万元)",
  347. dataIndex: "amount",
  348. key: "amount"
  349. },
  350. {
  351. title: "申请时间",
  352. dataIndex: "createTime",
  353. key: "createTime"
  354. },
  355. {
  356. title: "开票状态",
  357. dataIndex: "status",
  358. key: "status",
  359. render: text => {
  360. return getInvoiceStatus(text);
  361. }
  362. }
  363. ],
  364. dataSource: [],
  365. searchTime: [,]
  366. };
  367. },
  368. loadSend(record) {
  369. this.setState({
  370. loading: true
  371. });
  372. if (this.state.examine === 3 && this.state.reason === "") {
  373. message.warning("拒绝理由不能为空!");
  374. return;
  375. }
  376. $.ajax({
  377. method: "post",
  378. dataType: "json",
  379. crossDomain: false,
  380. url: globalConfig.context + "/api/admin/orderInvoice/approvalExamine",
  381. data: {
  382. id: this.state.examine === 2 ? record.id : this.state.id,
  383. examine: this.state.examine,
  384. reason: this.state.reason
  385. },
  386. success: function() {}.bind(this)
  387. }).done(
  388. function() {
  389. this.setState({
  390. loading: false
  391. });
  392. if (this.state.examine === 2) {
  393. message.success("通过成功!");
  394. this.loadData();
  395. } else {
  396. message.success("拒绝成功!");
  397. this.resetReason();
  398. this.rejectCancels();
  399. this.loadData();
  400. }
  401. }.bind(this)
  402. );
  403. },
  404. //重置拒绝理由
  405. resetReason() {
  406. this.setState({
  407. reason: ""
  408. });
  409. },
  410. sende(record) {
  411. this.loadSend(record);
  412. },
  413. commit() {
  414. this.loadSend();
  415. this.setState({
  416. avisible: false
  417. });
  418. },
  419. visit(index) {
  420. this.setState(
  421. {
  422. id: this.state.dataSource[index].id,
  423. avisible: true
  424. },
  425. () => {
  426. this.invoiceData();
  427. }
  428. );
  429. },
  430. visitCancels() {
  431. this.setState({
  432. avisible: false
  433. });
  434. },
  435. reject(record) {
  436. this.setState({
  437. visibleR: true,
  438. id: record.id
  439. });
  440. },
  441. rejectCancels() {
  442. this.setState({
  443. visibleR: false
  444. });
  445. },
  446. inRecordData() {
  447. this.setState({
  448. loading: true
  449. });
  450. $.ajax({
  451. method: "get",
  452. dataType: "json",
  453. crossDomain: false,
  454. url:
  455. globalConfig.context +
  456. "/api/admin/orderInvoice/salesmanOrderInvoiceList",
  457. data: {
  458. orderNo: this.state.orderNo2
  459. },
  460. success: function(data) {
  461. let theArr = [];
  462. let sum = 0;
  463. if (!data.data) {
  464. if (data.error && data.error.length) {
  465. message.warning(data.error[0].message);
  466. }
  467. } else {
  468. for (let i = 0; i < data.data.list.length; i++) {
  469. let thisdata = data.data.list[i];
  470. sum += parseFloat(thisdata.amount);
  471. theArr.push({
  472. id: thisdata.id,
  473. orderno: thisdata.orderno, //订单编号
  474. amount: thisdata.amount, //签单金额
  475. createTime: thisdata.createTime, //流程状态
  476. status: thisdata.status, //结算状态
  477. rejectReason: thisdata.rejectReason
  478. });
  479. }
  480. }
  481. this.setState({
  482. recordData: theArr,
  483. sum: sum.toFixed(6)
  484. });
  485. }.bind(this)
  486. }).done(
  487. function() {
  488. this.setState({
  489. loading: false
  490. });
  491. }.bind(this)
  492. );
  493. },
  494. inRecord(record) {
  495. this.setState(
  496. {
  497. bvisible: true,
  498. orderNo2: record.orderNo
  499. },
  500. () => {
  501. this.inRecordData();
  502. }
  503. );
  504. },
  505. inRecordCanl() {
  506. this.setState({
  507. bvisible: false
  508. });
  509. },
  510. search() {
  511. this.loadData();
  512. },
  513. componentWillMount() {
  514. this.loadData();
  515. },
  516. // componentDidMount() {
  517. // window.setTimeout(() => {
  518. // console.log("321", this.state);
  519. // },100)
  520. // },
  521. reset() {
  522. this.state.nameSearch = "";
  523. this.state.releaseDate = [];
  524. this.state.orderNoSearch = "";
  525. this.state.processStatus = [];
  526. this.state.departmenttList = [];
  527. this.loadData();
  528. },
  529. tableRowClick(record) {
  530. this.state.RowData = record;
  531. this.setState({
  532. showDesc: true
  533. });
  534. },
  535. closeDesc(e, s) {
  536. this.state.showDesc = e;
  537. if (s) {
  538. this.loadData(this.state.page);
  539. }
  540. },
  541. changeList(arr) {
  542. const newArr = [];
  543. this.state.columns.forEach(item => {
  544. arr.forEach(val => {
  545. if (val === item.title) {
  546. newArr.push(item);
  547. }
  548. });
  549. });
  550. this.setState({
  551. changeList: newArr
  552. });
  553. },
  554. render() {
  555. const formItemLayout = {
  556. labelCol: { span: 8 },
  557. wrapperCol: { span: 14 }
  558. };
  559. const { TabPane } = Tabs
  560. return (
  561. <div className="user-content">
  562. <div className="content-title">
  563. <span>省外特批</span>
  564. </div>
  565. <Tabs
  566. defaultActiveKey="1"
  567. onChange={this.callback}
  568. className="test">
  569. <TabPane tab="搜索" key="1">
  570. <div className="user-search">
  571. <Input
  572. placeholder="营销员名称"
  573. value={this.state.nameSearch}
  574. style={{marginLeft:10}}
  575. onChange={e => {
  576. this.setState({ nameSearch: e.target.value });
  577. }}
  578. />
  579. <Input
  580. placeholder="订单编号"
  581. value={this.state.orderNoSearch}
  582. onChange={e => {
  583. this.setState({ orderNoSearch: e.target.value });
  584. }}
  585. />
  586. {/*<Select placeholder="订单部门"
  587. style={{ width: 150 ,marginRight:10}}
  588. value={this.state.departmenttList}
  589. onChange={(e) => { this.setState({ departmenttList: e }) }}>
  590. {
  591. departmentArr.map(function (item) {
  592. return <Select.Option key={item.id} >{item.name}</Select.Option>
  593. })
  594. }
  595. </Select>*/}
  596. <Button
  597. type="primary"
  598. onClick={this.search}
  599. style={{ marginLeft: 10 }}
  600. >
  601. 搜索
  602. </Button>
  603. <Button onClick={this.reset}>重置</Button>
  604. </div>
  605. </TabPane>
  606. <TabPane tab="更改表格显示数据" key="2">
  607. <div style={{ marginLeft: 10 }}>
  608. <ChooseList
  609. columns={this.state.columns}
  610. changeFn={this.changeList}
  611. changeList={this.state.changeList}
  612. top={55}
  613. margin={11}
  614. />
  615. </div>
  616. </TabPane>
  617. </Tabs>
  618. <div className="patent-table">
  619. <Spin spinning={this.state.loading}>
  620. <Table
  621. columns={
  622. this.state.changeList
  623. ? this.state.changeList
  624. : this.state.columns
  625. }
  626. style={{
  627. cursor: 'pointer',
  628. }}
  629. scroll={{ x: 1500, y: 0 }}
  630. onRowClick={this.tableRowClick}
  631. dataSource={this.state.dataSource}
  632. pagination={this.state.pagination}
  633. bordered
  634. size="small"
  635. />
  636. </Spin>
  637. </div>
  638. <Modal
  639. visible={this.state.visibleR}
  640. className="admin-desc-content"
  641. footer=""
  642. title="拒绝理由"
  643. width="400px"
  644. onCancel={this.rejectCancels}
  645. >
  646. <Input.TextArea
  647. placeholder="请输入拒绝理由"
  648. rows={4}
  649. value={this.state.reason}
  650. onChange={e => {
  651. this.setState({ reason: e.target.value });
  652. }}
  653. />
  654. <div className="clearfix" style={{ marginTop: "20px" }}>
  655. <Button
  656. type="primary"
  657. onClick={e => {
  658. e.stopPropagation(), this.commit();
  659. }}
  660. style={{ float: "right" }}
  661. >
  662. 提交
  663. </Button>
  664. </div>
  665. </Modal>
  666. <Modal
  667. className="admin-desc-content"
  668. footer=""
  669. title="开具发票申请单"
  670. width="900px"
  671. visible={this.state.avisible}
  672. onOk={this.visitOks}
  673. onCancel={this.visitCancels}
  674. >
  675. <Form
  676. layout="horizontal"
  677. id="demand-form"
  678. style={{ paddingBottom: "40px" }}
  679. >
  680. <Spin spinning={this.state.loading}>
  681. <div className="clearfix">
  682. <div className="clearfix">
  683. <FormItem
  684. className="half-item"
  685. {...formItemLayout}
  686. label="合同编号"
  687. >
  688. <span>{this.state.contractNo}</span>
  689. </FormItem>
  690. <FormItem
  691. className="half-item"
  692. {...formItemLayout}
  693. label="备注"
  694. >
  695. <span>{this.state.remarks}</span>
  696. </FormItem>
  697. </div>
  698. <div className="clearfix">
  699. <FormItem
  700. className="half-item"
  701. {...formItemLayout}
  702. label={
  703. <span>
  704. <strong style={{ color: "#f00" }}>*</strong>省内/外
  705. </span>
  706. }
  707. >
  708. <span>{getProvinceA(this.state.type)}</span>
  709. </FormItem>
  710. </div>
  711. <hr
  712. style={{
  713. border: "1px dashed #aaa",
  714. width: "90%",
  715. margin: "auto"
  716. }}
  717. />
  718. <div style={{ marginTop: "13px", marginLeft: "16px" }}>
  719. <span style={{ fontSize: "14px" }}>发票内容</span>
  720. </div>
  721. <div className="clearfix">
  722. <FormItem
  723. className="half-item"
  724. {...formItemLayout}
  725. label={
  726. <span>
  727. <strong style={{ color: "#f00" }}>*</strong>发票类型
  728. </span>
  729. }
  730. >
  731. <span>
  732. {this.state.invoiceType === 0
  733. ? "增值税专用发票"
  734. : this.state.invoiceType === 1
  735. ? "增值税普通发票"
  736. : "其他"}
  737. </span>
  738. </FormItem>
  739. </div>
  740. <div className="clearfix">
  741. <FormItem
  742. className="half-item"
  743. {...formItemLayout}
  744. label={
  745. <span>
  746. <strong style={{ color: "#f00" }}>*</strong>单位名称
  747. </span>
  748. }
  749. >
  750. <span>{this.state.unitName}</span>
  751. </FormItem>
  752. <FormItem
  753. className="half-item"
  754. {...formItemLayout}
  755. label={
  756. <span>
  757. <strong style={{ color: "#f00" }}>*</strong>税号
  758. </span>
  759. }
  760. >
  761. <span>{this.state.taxNumber}</span>
  762. </FormItem>
  763. <FormItem
  764. className="half-item"
  765. {...formItemLayout}
  766. label={
  767. <span>
  768. <strong style={{ color: "#f00" }}>*</strong>
  769. 开票金额(万元)
  770. </span>
  771. }
  772. >
  773. <span>{this.state.amount}</span>
  774. </FormItem>
  775. <FormItem
  776. className="half-item"
  777. {...formItemLayout}
  778. label={
  779. <span>
  780. <strong style={{ color: "#f00" }}>*</strong>
  781. 开户行银行账号
  782. </span>
  783. }
  784. >
  785. <span>{this.state.banks}</span>
  786. </FormItem>
  787. <FormItem
  788. className="half-item"
  789. {...formItemLayout}
  790. label={
  791. <span>
  792. <strong style={{ color: "#f00" }}>*</strong>
  793. 开票内容及说明
  794. </span>
  795. }
  796. >
  797. <span>{this.state.content}</span>
  798. </FormItem>
  799. <FormItem
  800. className="half-item"
  801. {...formItemLayout}
  802. label={
  803. <span>
  804. <strong style={{ color: "#f00" }}>*</strong>单位地址
  805. </span>
  806. }
  807. >
  808. <span>{this.state.unitAddress}</span>
  809. </FormItem>
  810. <FormItem
  811. className="half-item"
  812. {...formItemLayout}
  813. label="备注"
  814. >
  815. <span>{this.state.invoiceRemarks}</span>
  816. </FormItem>
  817. <FormItem
  818. className="half-item"
  819. {...formItemLayout}
  820. label={
  821. <span>
  822. <strong style={{ color: "#f00" }}>*</strong>单位电话
  823. </span>
  824. }
  825. >
  826. <span>{this.state.unitMobile}</span>
  827. </FormItem>
  828. </div>
  829. <div className="clearfix">
  830. <FormItem
  831. labelCol={{ span: 4 }}
  832. wrapperCol={{ span: 18 }}
  833. label={
  834. <span>
  835. <strong style={{ color: "#f00" }}>*</strong>附件
  836. </span>
  837. }
  838. >
  839. <Upload
  840. className="demandDetailShow-upload"
  841. listType="picture-card"
  842. fileList={this.state.orgCodeUrl}
  843. onPreview={file => {
  844. this.setState({
  845. previewImage: file.url || file.thumbUrl,
  846. previewVisible: true
  847. });
  848. }}
  849. ></Upload>
  850. <Modal
  851. maskClosable={false}
  852. footer={null}
  853. visible={this.state.previewVisible}
  854. onCancel={() => {
  855. this.setState({ previewVisible: false });
  856. }}
  857. >
  858. <img
  859. alt=""
  860. style={{ width: "100%" }}
  861. src={this.state.previewImage || ""}
  862. />
  863. </Modal>
  864. </FormItem>
  865. </div>
  866. <hr
  867. style={{
  868. border: "1px dashed #aaa",
  869. width: "90%",
  870. margin: "auto"
  871. }}
  872. />
  873. <div className="clearfix" style={{ marginTop: "10px" }}>
  874. <FormItem
  875. className="half-item"
  876. {...formItemLayout}
  877. label="发票是否邮寄:"
  878. >
  879. <span>{this.state.post === 0 ? "是" : "否"}</span>
  880. </FormItem>
  881. </div>
  882. {this.state.post === 0 ? (
  883. <div>
  884. <div className="clearfix">
  885. <FormItem
  886. className="half-item"
  887. {...formItemLayout}
  888. label="收信人姓名"
  889. >
  890. <span>{this.state.addressee}</span>
  891. </FormItem>
  892. <FormItem
  893. className="half-item"
  894. {...formItemLayout}
  895. label="电话"
  896. >
  897. <span>{this.state.addresseeMobile}</span>
  898. </FormItem>
  899. </div>
  900. <div className="clearfix">
  901. <FormItem
  902. className="half-item"
  903. {...formItemLayout}
  904. label="省-市-区"
  905. >
  906. <span>
  907. {getprovince(this.state.addresseeProvince)}/
  908. {getprovince(this.state.addresseeCity)}/
  909. {getprovince(this.state.addresseeArea)}
  910. </span>
  911. </FormItem>
  912. </div>
  913. <div className="clearfix">
  914. <FormItem
  915. className="half-item"
  916. {...formItemLayout}
  917. label="详细地址"
  918. >
  919. <span>{this.state.recipientAddress}</span>
  920. </FormItem>
  921. </div>
  922. </div>
  923. ) : (
  924. ""
  925. )}
  926. <FormItem
  927. className="half-item"
  928. {...formItemLayout}
  929. label={
  930. <span>
  931. <strong style={{ color: "#f00" }}>*</strong>开票金额总计
  932. </span>
  933. }
  934. >
  935. <span>{this.state.alreadyAmount}万元</span>
  936. </FormItem>
  937. </div>
  938. </Spin>
  939. </Form>
  940. </Modal>
  941. <Modal
  942. visible={this.state.bvisible}
  943. footer=""
  944. title="开票历史记录"
  945. className="admin-desc-content"
  946. width="900px"
  947. onCancel={this.inRecordCanl}
  948. >
  949. <Spin spinning={this.state.loading}>
  950. <div className="patent-table">
  951. <Table
  952. columns={this.state.columnsDate}
  953. dataSource={this.state.recordData}
  954. pagination={false}
  955. bordered
  956. size="small"
  957. />
  958. <div className="clearfix" style={{ marginTop: "20px" }}>
  959. <FormItem
  960. className="half-item"
  961. {...formItemLayout}
  962. label={<span style={{ fontSize: "14px" }}>开票总计</span>}
  963. >
  964. <span>{this.state.sum}</span>
  965. </FormItem>
  966. </div>
  967. </div>
  968. </Spin>
  969. </Modal>
  970. <OrderDesc
  971. data={this.state.RowData}
  972. showDesc={this.state.showDesc}
  973. closeDesc={this.closeDesc.bind(this)}
  974. />
  975. </div>
  976. );
  977. }
  978. });
  979. export default outSpecial;