myTaskOutsource.jsx 115 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361336233633364336533663367336833693370337133723373337433753376337733783379338033813382338333843385338633873388338933903391339233933394339533963397339833993400340134023403340434053406340734083409341034113412341334143415341634173418341934203421342234233424342534263427342834293430343134323433
  1. import React from "react";
  2. import $ from "jquery";
  3. import moment from "moment";
  4. import Picture from "@/manageCenter/publicComponent/picture";
  5. import ResolutionDetail from "@/resolutionDetail";
  6. import "@/manageCenter/financialManage/distribute/public.less";
  7. import "@/manageCenter/financialManage/distribute/shouKuan.less";
  8. import {
  9. Button,
  10. Form,
  11. Input,
  12. Select,
  13. Spin,
  14. Table,
  15. message,
  16. DatePicker,
  17. Modal,
  18. Radio,
  19. Cascader,
  20. Popconfirm,
  21. Tabs,
  22. Tag,
  23. notification
  24. } from "antd";
  25. import Assign from "@/manageCenter/publicComponent/assign";
  26. import { areaSelect } from "@/NewDicProvinceList";
  27. import { ChooseList } from "../../order/orderNew/chooseList";
  28. import OrderRiZi from "@/orderRiZi.jsx";
  29. import "./table.less";
  30. import {
  31. getProcessStatus,
  32. getApproval,
  33. getTaskStatus,
  34. getLiquidationStatus,
  35. getProjectStatus,
  36. splitUrl,
  37. getboutique,
  38. getprovince,
  39. moneyVerify,
  40. ShowModal
  41. } from "@/tools";
  42. import { taskStatus, projectStatus } from "@/dataDic.js";
  43. import ShowModalDiv from "@/showModal.jsx";
  44. const FormItem = Form.Item;
  45. const { TabPane } = Tabs;
  46. const { MonthPicker, RangePicker } = DatePicker;
  47. const MyTaskOutsource = React.createClass({
  48. loadData(pageNo) {
  49. this.state.data = [];
  50. this.setState({
  51. page: pageNo,
  52. loading: true
  53. });
  54. $.ajax({
  55. method: "get",
  56. dataType: "json",
  57. crossDomain: false,
  58. url: globalConfig.context + "/api/admin/orderProject/orderTaskList",
  59. data: {
  60. pageNo: pageNo || this.state.page || 1,
  61. pageSize: this.state.pagination.pageSize,
  62. specially: 0, //个人
  63. name: this.state.nameSearch, //客户名称
  64. depId: this.state.departmenttSearch, //订单部门
  65. orderNo: this.state.orderNoSearch, //订单编号
  66. contractNo: this.state.contractNoSearch, //合同编号
  67. taskId: this.state.taskNoSearch, //项目编号
  68. taskStatus: this.state.taskStatuSearch, //项目状态
  69. projectStatus: this.state.projectStatusSearch, //项目状态
  70. adminName: this.state.adminName, //项目受理人
  71. outsource: 1,
  72. approval: this.state.approvalSearch //特批状态搜索
  73. },
  74. success: function(data) {
  75. ShowModal(this);
  76. let theArr = [];
  77. if (!data.data || !data.data.list) {
  78. if (data.error && data.error.length) {
  79. message.warning(data.error[0].message);
  80. }
  81. } else {
  82. for (let i = 0; i < data.data.list.length; i++) {
  83. let thisdata = data.data.list[i];
  84. theArr.push({
  85. key: i,
  86. orderNo: thisdata.orderNo, //订单编号
  87. id: thisdata.id, //项目ID
  88. taskName: thisdata.taskName, //名称
  89. cname: thisdata.cname, //项目品类
  90. receiverName: thisdata.receiverName, //受理人
  91. projectStatus: thisdata.projectStatus, //项目状态
  92. taskStatus: thisdata.taskStatus, //项目状态
  93. taskDate: thisdata.taskDate, //分配时间
  94. userName:
  95. thisdata.taskName.substring(0, 5) === "软件著作权"
  96. ? thisdata.userName +
  97. "(" +
  98. thisdata.commodityQuantity.toString() +
  99. "/" +
  100. thisdata.alreadyNumber +
  101. ")"
  102. : thisdata.userName, //用户名
  103. depName: thisdata.depName, //部门名称
  104. commodityQuantity: thisdata.commodityQuantity, //项目数量
  105. outsourceName: thisdata.outsourceName,
  106. hours: thisdata.hours,
  107. contractNo: thisdata.contractNo,
  108. approval: thisdata.approval, //特批状态
  109. outsourceStatus: thisdata.outsourceStatus, //外包审核状态
  110. splitStatus: thisdata.splitStatus, //是否为子项目 2是 1主项目
  111. splitSuper: thisdata.splitSuper,
  112. splitId: thisdata.splitId
  113. });
  114. }
  115. }
  116. if (data.data && data.data.list && !data.data.list.length) {
  117. this.state.pagination.current = 0;
  118. this.state.pagination.total = 0;
  119. }
  120. this.setState({
  121. dataSource: theArr,
  122. pagination: this.state.pagination
  123. });
  124. }.bind(this)
  125. }).always(
  126. function() {
  127. this.setState({
  128. loading: false
  129. });
  130. }.bind(this)
  131. );
  132. },
  133. getInitialState() {
  134. return {
  135. page: 1,
  136. timeVisible: false,
  137. searchMore: true,
  138. assignVisible: false,
  139. releaseDate: [],
  140. // 判断是否是退回给咨询师经理
  141. flag: false,
  142. roleName: "",
  143. modKey: "1",
  144. testFlag: true,
  145. boHuivisible: false,
  146. companyProvinceArr: [],
  147. selectedRowKeys: [],
  148. departmentArr: [],
  149. selectedRows: [],
  150. attachmentUrl: [],
  151. contactList: [],
  152. //特批状态搜索
  153. approvalSearch: undefined,
  154. paginations: false,
  155. loading: false,
  156. pagination: {
  157. defaultCurrent: 1,
  158. defaultPageSize: 10,
  159. showQuickJumper: true,
  160. pageSize: 10,
  161. onChange: function(page) {
  162. this.loadData(page);
  163. this.setState({
  164. page
  165. });
  166. }.bind(this),
  167. showTotal: function(total) {
  168. return "共" + total + "条数据";
  169. }
  170. },
  171. // 子组件改变的表格title数组
  172. changeList: undefined,
  173. columnsTime: [
  174. {
  175. title: "工作时长(小时)",
  176. dataIndex: "hours",
  177. key: "hours"
  178. },
  179. {
  180. title: "工作时间",
  181. dataIndex: "taskDays",
  182. key: "taskDays"
  183. },
  184. // {
  185. // title: "项目负责人",
  186. // dataIndex: "remarks",
  187. // key: "remarks"
  188. // },
  189. {
  190. title: "备注",
  191. dataIndex: "remarks",
  192. key: "remarks"
  193. }
  194. ],
  195. columns: [
  196. {
  197. title: "项目编号",
  198. dataIndex: "id",
  199. key: "id",
  200. render: (text, record) => {
  201. if (record.splitStatus == 2) {
  202. return <span>{record.splitSuper + "-" + record.splitId}</span>;
  203. } else {
  204. return text;
  205. }
  206. }
  207. },
  208. {
  209. title: "项目名称",
  210. dataIndex: "taskName",
  211. key: "taskName",
  212. render: text => {
  213. return text && text.length > 8 ? text.substr(0, 8) + "…" : text;
  214. }
  215. },
  216. {
  217. title: "项目数量",
  218. dataIndex: "commodityQuantity",
  219. key: "commodityQuantity"
  220. },
  221. {
  222. title: "订单编号",
  223. dataIndex: "orderNo",
  224. key: "orderNo"
  225. },
  226. {
  227. title: "合同编号",
  228. dataIndex: "contractNo",
  229. key: "contractNo"
  230. },
  231. {
  232. title: "业务类别",
  233. dataIndex: "cname",
  234. key: "cname"
  235. },
  236. {
  237. title: "客户名称",
  238. dataIndex: "userName",
  239. key: "userName",
  240. className: "userName"
  241. },
  242. {
  243. title: "外包公司",
  244. dataIndex: "outsourceName",
  245. key: "outsourceName"
  246. },
  247. {
  248. title: "分配状态",
  249. dataIndex: "taskStatus",
  250. key: "taskStatus",
  251. render: text => {
  252. return getTaskStatus(text);
  253. }
  254. },
  255. {
  256. title: "项目状态",
  257. dataIndex: "projectStatus",
  258. key: "projectStatus",
  259. render: text => {
  260. return getProjectStatus(text);
  261. }
  262. },
  263. {
  264. title: "特批状态",
  265. dataIndex: "approval",
  266. key: "approval",
  267. render: text => {
  268. return getApproval(text, true);
  269. }
  270. },
  271. {
  272. title: "分配时间",
  273. dataIndex: "taskDate",
  274. key: "taskDate"
  275. },
  276. {
  277. title: "订单部门",
  278. dataIndex: "depName",
  279. key: "depName"
  280. },
  281. {
  282. title: "累计工时(小时)",
  283. dataIndex: "hours",
  284. key: "hours"
  285. },
  286. {
  287. title: "操作",
  288. dataIndex: "caozuo",
  289. key: "caozuo",
  290. render: (text, record) => {
  291. return (
  292. <div>
  293. <Button
  294. type="primary"
  295. onClick={e => {
  296. e.stopPropagation(), this.evaluate(record, "咨询师");
  297. }}
  298. >
  299. 转交
  300. </Button>
  301. <Button
  302. type="primary"
  303. style={{ marginLeft: 10 }}
  304. onClick={e => {
  305. e.stopPropagation(),
  306. this.evaluate(record, "咨询师经理", true);
  307. }}
  308. >
  309. 回退
  310. </Button>
  311. <Button
  312. type="primary"
  313. style={{ margin: "0 10px" }}
  314. onClick={e => {
  315. e.stopPropagation(), this.okCancel(record);
  316. }}
  317. >
  318. 添加工时
  319. </Button>
  320. <Button
  321. type="primary"
  322. onClick={e => {
  323. e.stopPropagation();
  324. this.setState({
  325. timeVisible: true
  326. });
  327. this.timeDetail(record);
  328. }}
  329. >
  330. 工时记录
  331. </Button>
  332. </div>
  333. );
  334. }
  335. }
  336. ],
  337. dataSource: [],
  338. searchTime: [],
  339. columnsX: [
  340. {
  341. title: "业务项目名称",
  342. dataIndex: "commodityName",
  343. key: "commodityName"
  344. },
  345. {
  346. title: "项目类别",
  347. dataIndex: "cname",
  348. key: "cname"
  349. },
  350. {
  351. title: "项目数量",
  352. dataIndex: "commodityQuantity",
  353. key: "commodityQuantity",
  354. render: (text, record) => {
  355. if (record.splitStatus == 1) {
  356. return (
  357. <span>
  358. {text}{" "}
  359. <Tag
  360. color="#108ee9"
  361. onClick={e => {
  362. e.stopPropagation();
  363. this.showRes(record);
  364. }}
  365. >
  366. 已拆
  367. </Tag>
  368. </span>
  369. );
  370. } else {
  371. return text;
  372. }
  373. }
  374. },
  375. {
  376. title: "金额(万元)",
  377. dataIndex: "commodityPrice",
  378. key: "commodityPrice"
  379. },
  380. {
  381. title: "负责人",
  382. dataIndex: "contacts",
  383. key: "contacts"
  384. },
  385. {
  386. title: "负责人电话",
  387. dataIndex: "contactsMobile",
  388. key: "contactsMobile"
  389. },
  390. {
  391. title: "主要项目",
  392. dataIndex: "main",
  393. key: "main",
  394. render: text => {
  395. return text ? "是" : "否";
  396. }
  397. },
  398. {
  399. title: "项目说明",
  400. dataIndex: "taskComment",
  401. key: "taskComment",
  402. render: text => {
  403. return text && text.length > 8 ? text.substr(0, 8) + "…" : text;
  404. }
  405. }
  406. ],
  407. columnsA: [
  408. {
  409. title: "流程",
  410. dataIndex: "content",
  411. key: "content",
  412. align: "center"
  413. },
  414. {
  415. title: "操作人",
  416. dataIndex: "aName",
  417. key: "aName",
  418. align: "center"
  419. },
  420. {
  421. title: "时间",
  422. dataIndex: "createTimes",
  423. key: "createTimes",
  424. align: "center"
  425. }
  426. ],
  427. dataSourceX: [],
  428. dataSourceA: [],
  429. companys: [],
  430. ContactsLists: [
  431. {
  432. title: "批次",
  433. dataIndex: "num",
  434. key: "num"
  435. },
  436. {
  437. title: "下证时间",
  438. dataIndex: "licenceTimes",
  439. key: "licenceTimes",
  440. render: (text, record) => {
  441. return (
  442. <div>
  443. <DatePicker
  444. style={{ marginTop: "5px" }}
  445. showTime
  446. format="YYYY-MM-DD"
  447. onOk={() => {}}
  448. value={
  449. record.licenceTimes ? moment(record.licenceTimes) : null
  450. }
  451. onChange={(data, dataString) => {
  452. record.licenceTimes = dataString;
  453. this.setState({ contactList: this.state.contactList });
  454. }}
  455. />
  456. </div>
  457. );
  458. }
  459. },
  460. {
  461. title: "下证数量",
  462. dataIndex: "alreadyNumber",
  463. key: "alreadyNumber",
  464. render: (text, record) => {
  465. return (
  466. <div>
  467. {
  468. <Input
  469. value={record.alreadyNumber}
  470. placeholder="请输入下证数量"
  471. key={record.id}
  472. required="required"
  473. onChange={e => {
  474. record.alreadyNumber = e.target.value;
  475. this.setState({ contactList: this.state.contactList });
  476. }}
  477. style={{ width: "120px" }}
  478. />
  479. }
  480. </div>
  481. );
  482. }
  483. },
  484. {
  485. title: "未下证数量",
  486. dataIndex: "notCount",
  487. key: "notCount"
  488. },
  489. {
  490. title: "操作",
  491. dataIndex: "dels",
  492. key: "dels",
  493. render: (text, record, index) => {
  494. return (
  495. <div>
  496. {
  497. <Popconfirm
  498. title="是否删除?"
  499. onConfirm={() => {
  500. this.confirmDelet(record);
  501. }}
  502. okText="删除"
  503. cancelText="不删除"
  504. >
  505. <Button
  506. style={{
  507. marginRight: "10px",
  508. color: "#ffffff",
  509. background: "#f00",
  510. border: "none"
  511. }}
  512. >
  513. 删除
  514. </Button>
  515. </Popconfirm>
  516. }
  517. {record.flag ? (
  518. ""
  519. ) : (
  520. <Button
  521. type="primary"
  522. onClick={e => {
  523. e.stopPropagation(), this.contactSave(record, index);
  524. }}
  525. >
  526. 保存
  527. </Button>
  528. )}
  529. </div>
  530. );
  531. }
  532. }
  533. ],
  534. companyColumns: [
  535. {
  536. title: "公司",
  537. dataIndex: "name",
  538. key: "name",
  539. //fixed:'left',
  540. width: 160
  541. },
  542. {
  543. title: "联系人",
  544. dataIndex: "contacts",
  545. key: "contacts"
  546. },
  547. {
  548. title: "联系人电话",
  549. dataIndex: "contactsMobile",
  550. key: "contactsMobile"
  551. },
  552. {
  553. title: "地址",
  554. dataIndex: "companyProvinceArr",
  555. key: "companyProvinceArr",
  556. width: 140,
  557. render: test => {
  558. return test[0] === null
  559. ? ""
  560. : getprovince(test[0]) +
  561. "/" +
  562. getprovince(test[1]) +
  563. "/" +
  564. getprovince(test[2]);
  565. }
  566. },
  567. {
  568. title: "详细地址",
  569. dataIndex: "address",
  570. key: "address"
  571. },
  572. {
  573. title: "操作",
  574. width: 160,
  575. render: (text, record) => {
  576. return (
  577. <div>
  578. <Button
  579. type="primary"
  580. onClick={() => {
  581. this.setState({
  582. companyId: record.id,
  583. updataSwicth: true,
  584. cName: record.name,
  585. companyContacts: record.contacts,
  586. companyContactsMobile: record.contactsMobile,
  587. companyProvinceArr: record.companyProvinceArr,
  588. companyAddress: record.address,
  589. companyRemarks: record.remarks
  590. });
  591. this.openNotification();
  592. }}
  593. >
  594. 修改
  595. </Button>
  596. <Popconfirm
  597. title="是否确认删除?"
  598. okText="确定"
  599. onConfirm={() => {
  600. this.deleteCompany(record.id);
  601. }}
  602. cancelText="取消"
  603. >
  604. <Button type="danger" style={{ marginLeft: "10px" }}>
  605. 删除
  606. </Button>
  607. </Popconfirm>
  608. </div>
  609. );
  610. }
  611. }
  612. ]
  613. };
  614. },
  615. /* 分派 */
  616. evaluate(record, nub, flag) {
  617. this.state.assignData = record;
  618. this.setState(
  619. {
  620. nub,
  621. assignData: record,
  622. flag
  623. },
  624. () => {
  625. this.setState({
  626. assignVisible: true
  627. });
  628. }
  629. );
  630. },
  631. componentWillMount() {
  632. this.departmentList();
  633. this.loadData();
  634. },
  635. componentDidMount() {
  636. this.setColor();
  637. },
  638. setColor() {
  639. $(".userName span").after(
  640. "(<span class='ruanzhu'>软著数</span>/<span class='xiazheng'>下证数</span>)"
  641. );
  642. },
  643. tableRowClick(record) {
  644. this.state.RowData = record;
  645. if (record.taskName.substring(0, 5) === "软件著作权") {
  646. this.setState({
  647. speVisible: true,
  648. id: record.id,
  649. splitStatus: record.splitStatus,
  650. splitSuper: record.splitSuper,
  651. splitId: record.splitId,
  652. dataArr: record,
  653. commodityQuantity: record.commodityQuantity
  654. });
  655. } else {
  656. this.setState({
  657. visible: true,
  658. splitStatus: record.splitStatus,
  659. splitSuper: record.splitSuper,
  660. splitId: record.splitId
  661. });
  662. }
  663. this.xiangqing(record.id, record.taskName);
  664. this.xiangqings(record.orderNo);
  665. this.xiangmu(record.orderNo);
  666. this.loaduserss(record);
  667. },
  668. //点击修改项目详情
  669. tijiaoOk() {
  670. if (moneyVerify(this.state.setUpAmount)) {
  671. return;
  672. }
  673. let attachmentUrls = [];
  674. if (this.state.attachmentUrl.length) {
  675. let picArr = [];
  676. this.state.attachmentUrl.map(function(item) {
  677. if (item.response && item.response.data && item.response.data.length) {
  678. picArr.push(item.response.data);
  679. }
  680. });
  681. attachmentUrls = picArr.join(",");
  682. }
  683. $.ajax({
  684. method: "POST",
  685. dataType: "json",
  686. crossDomain: false,
  687. url: globalConfig.context + "/api/admin/orderProject/updateOrderTask",
  688. data: {
  689. id: this.state.id, //项目编号
  690. orderNo: this.state.orderNo, //订单编号
  691. projectStatus: this.state.projectStatus, //项目状态
  692. taskStatus: this.state.taskStatus, //项目状态
  693. taskComment: this.state.taskComment, //说明
  694. startDate: this.state.startDate, //启动日期
  695. endDate: this.state.endDate, //结束日期
  696. acceptDate: this.state.acceptDate, //受理日期
  697. reviewDate: this.state.reviewDate, //评审日期
  698. publicityDate: this.state.publicityDate, //公示日期
  699. licenceDate: this.state.licenceDate, //发证日期
  700. attachmentUrl: attachmentUrls.length ? attachmentUrls : "", //附件
  701. contacts: this.state.contacts, //联系人
  702. contactMobile: this.state.contactMobile, //联系人电话
  703. legalPerson: this.state.legalPerson, //法人
  704. legalPersonTel: this.state.legalPersonTel, //法人电话
  705. certificateNumber: this.state.certificateNumber, //证书编号
  706. status: this.state.status, //状态
  707. formRetrieve: this.state.formRetrieve, //满意度表格
  708. taskRefund: this.state.taskRefund, //退单
  709. refundContent: this.state.refundContent, //退单信息
  710. retrieveContent: this.state.retrieveContent, //回收信息
  711. locationProvince: this.state.ProvinceCity[0],
  712. locationCity: this.state.ProvinceCity[1],
  713. locationArea: this.state.ProvinceCity[2],
  714. postalAddress: this.state.postalAddress, //详细地址
  715. arrivalMoney: this.state.arrivalMoney, //是否到款
  716. setUpAmount: this.state.setUpAmount, //立项金额
  717. declareUser: this.state.declareUser, //账号
  718. declarePwd: this.state.declarePwd, //密码
  719. outsourceName: this.state.outsourceName, //外包公司名称
  720. outsourcePrice: this.state.outsourcePrice //外包价格
  721. }
  722. }).done(
  723. function(data) {
  724. this.setState({
  725. loading: false
  726. });
  727. if (!data.error.length) {
  728. message.success("保存成功!");
  729. this.visitCancel();
  730. } else {
  731. message.warning(data.error[0].message);
  732. }
  733. }.bind(this)
  734. );
  735. },
  736. //点击修改项目详情
  737. tianjiaOk() {
  738. if (this.state.attachmentUrl.length) {
  739. let picArr = [];
  740. this.state.attachmentUrl.map(function(item) {
  741. if (item.response && item.response.data && item.response.data.length) {
  742. picArr.push(item.response.data);
  743. }
  744. });
  745. }
  746. $.ajax({
  747. method: "POST",
  748. dataType: "json",
  749. crossDomain: false,
  750. url: globalConfig.context + "/api/admin/orderProject/addTaskHours",
  751. data: {
  752. taskId: this.state.taskId, //项目编号
  753. hours: this.state.hours, //工时
  754. remarks: this.state.remarks, //说明
  755. taskDate: this.state.taskDate, //日期
  756. taskComment: this.state.taskComment //说明
  757. }
  758. }).done(
  759. function(data) {
  760. this.setState({
  761. loading: false
  762. });
  763. if (!data.error.length) {
  764. message.success("保存成功!");
  765. this.noCancel();
  766. } else {
  767. message.warning(data.error[0].message);
  768. }
  769. }.bind(this)
  770. );
  771. },
  772. //订单详情
  773. xiangqing(id) {
  774. $.ajax({
  775. method: "get",
  776. dataType: "json",
  777. crossDomain: false,
  778. url: globalConfig.context + "/api/admin/orderProject/orderTaskDetail",
  779. data: {
  780. id: id
  781. },
  782. success: function(data) {
  783. let thisdata = data.data;
  784. if (data.error.length || data.data.list == "") {
  785. if (data.error && data.error.length) {
  786. message.warning(data.error[0].message);
  787. }
  788. } else {
  789. this.setState({
  790. id: thisdata.id, //ID
  791. orderNo: thisdata.orderNo, //订单编号
  792. userName: thisdata.userName, //客户名称
  793. taskName: thisdata.taskName, //项目名称
  794. cname: thisdata.cname, //项目品类
  795. contractNo: thisdata.contractNo, //合同编号
  796. projectStatus: thisdata.projectStatus.toString(), //项目状态
  797. taskStatus: thisdata.taskStatus.toString(), //项目状态
  798. taskDate: thisdata.taskDate, //分配时间
  799. taskComment: thisdata.taskComment, //说明
  800. attachmentUrl: thisdata.attachmentUrl
  801. ? splitUrl(
  802. thisdata.attachmentUrl,
  803. ",",
  804. globalConfig.avatarHost + "/upload"
  805. )
  806. : [], //图片地址
  807. salesmanName: thisdata.salesmanName, //订单负责人
  808. startDate: thisdata.startDate, //启动日期
  809. endDate: thisdata.endDate, //结束日期
  810. acceptDate: thisdata.acceptDate, //受理日期
  811. reviewDate: thisdata.reviewDate, //评审日期
  812. publicityDate: thisdata.publicityDate, //公示日期
  813. licenceDate: thisdata.licenceDate, //发证日期
  814. contacts: thisdata.contacts, //联系人
  815. contactMobile: thisdata.contactMobile, //联系人电话
  816. legalPerson: thisdata.legalPerson, //法人
  817. legalPersonTel: thisdata.legalPersonTel, //法人电话
  818. certificateNumber: thisdata.certificateNumber, //证书编号
  819. status: thisdata.status, //状态
  820. formRetrieve: thisdata.formRetrieve, //满意度表格
  821. taskRefund: thisdata.taskRefund, //退单
  822. refundContent: thisdata.refundContent, //退单信息
  823. retrieveContent: thisdata.retrieveContent, //回收信息
  824. arrivalMoney: thisdata.arrivalMoney, //是否到款
  825. setUpAmount: thisdata.setUpAmount, //立项金额
  826. declareUser: thisdata.declareUser, //账号
  827. declarePwd: thisdata.declarePwd, //密码
  828. outsourceName: thisdata.outsourceName, //外包公司名称
  829. outsourcePrice: thisdata.outsourcePrice, //外包价格
  830. });
  831. }
  832. }.bind(this)
  833. }).always(
  834. function() {
  835. this.setState({
  836. loading: false
  837. });
  838. }.bind(this)
  839. );
  840. },
  841. //订单详情
  842. xiangqings(orderNos) {
  843. $.ajax({
  844. method: "get",
  845. dataType: "json",
  846. crossDomain: false,
  847. url: globalConfig.context + "/api/admin/newOrder/getOrderNewDetail",
  848. data: {
  849. orderNo: orderNos
  850. },
  851. success: function(data) {
  852. let thisdata = data.data;
  853. let ProvinceCityArr = [];
  854. let ProvinceS = thisdata.locationProvince; //省
  855. let citys = thisdata.locationCity; //市
  856. let Areas = thisdata.locationArea; //区
  857. ProvinceCityArr.push(ProvinceS, citys, Areas);
  858. if (data.error.length || data.data.list == "") {
  859. if (data.error && data.error.length) {
  860. message.warning(data.error[0].message);
  861. }
  862. } else {
  863. this.setState({
  864. processStatus: thisdata.processStatus, //流程状态
  865. liquidationStatus: thisdata.liquidationStatus, //结算状态
  866. approval: thisdata.approval, //特批状态
  867. orderRemarks: thisdata.orderRemarks, //订单留言
  868. salesmanName: thisdata.salesmanName, //营销员名称
  869. salesmanMobile: thisdata.salesmanMobile, //营销员电话
  870. oldSalesmanName: thisdata.oldSalesmanName, //营销员名称
  871. oldSalesmanMobile: thisdata.oldSalesmanMobile, //营销员电话
  872. financeName: thisdata.financeName, //财务名称
  873. financeMobile: thisdata.financeMobile, //财务电话
  874. nowFinance: thisdata.nowFinance, //财务名称
  875. nowFinanceMobile: thisdata.nowFinanceMobile, //财务电话
  876. depName: thisdata.depName, //订单部门
  877. ProvinceCity: ProvinceCityArr[0] === null ? [] : ProvinceCityArr,
  878. postalAddress: thisdata.postalAddress //详细地址
  879. });
  880. }
  881. }.bind(this)
  882. }).always(
  883. function() {
  884. this.setState({
  885. loading: false
  886. });
  887. }.bind(this)
  888. );
  889. },
  890. //项目列表
  891. xiangmu(orderNos) {
  892. $.ajax({
  893. method: "get",
  894. dataType: "json",
  895. crossDomain: false,
  896. url: globalConfig.context + "/api/admin/newOrder/getOrderTask",
  897. data: {
  898. orderNo: orderNos
  899. },
  900. success: function(data) {
  901. let theArr = [];
  902. if (data.error.length || data.data.list == "") {
  903. if (data.error && data.error.length) {
  904. message.warning(data.error[0].message);
  905. }
  906. } else {
  907. for (let i = 0; i < data.data.length; i++) {
  908. let thisdata = data.data[i];
  909. theArr.push({
  910. key: i,
  911. id: thisdata.id,
  912. orderNo: thisdata.orderNo, //订单编号
  913. commodityId: thisdata.commodityId, //项目ID
  914. commodityName: thisdata.commodityName, //项目名称
  915. cname: thisdata.cname, //项目类别
  916. commodityPrice: thisdata.commodityPrice, //项目价格
  917. commodityQuantity: thisdata.commodityQuantity, //项目数量
  918. main: thisdata.main, //是否为主要项目
  919. taskComment: thisdata.taskComment, //项目说明
  920. contacts: thisdata.contacts, //联系人
  921. contactsMobile: thisdata.contactsMobile, //联系人电话
  922. taskStatus: thisdata.taskStatus, //是否分配
  923. contractNo: thisdata.contractNo, //合同编号
  924. certificateNumber: thisdata.certificateNumber,
  925. splitStatus: thisdata.splitStatus, //是否为子项目 2是 1主项目
  926. splitSuper: thisdata.splitSuper,
  927. splitId: thisdata.splitId
  928. });
  929. }
  930. }
  931. this.setState({
  932. dataSourceX: theArr
  933. });
  934. }.bind(this)
  935. }).always(
  936. function() {
  937. this.setState({
  938. loading: false
  939. });
  940. }.bind(this)
  941. );
  942. },
  943. //导出
  944. exportExec() {
  945. let departmentName = "",
  946. depart = this.state.departmentArr || [];
  947. depart.map(item => {
  948. if (this.state.departmentId == item.id) {
  949. departmentName = item.name;
  950. return;
  951. }
  952. });
  953. let data = {
  954. departmentId: this.state.departmentId,
  955. departmentName: departmentName,
  956. salesName: this.state.orderRefundSearch, //订单负责人
  957. startTime: this.state.releaseDate[0],
  958. endTime: this.state.releaseDate[1],
  959. grantStatus: this.state.grantStatus
  960. };
  961. window.location.href =
  962. globalConfig.context +
  963. "/api/admin/orderProject/exportMyTaskList?" +
  964. $.param(data);
  965. },
  966. //关闭详情
  967. visitCancel() {
  968. this.setState({
  969. visible: false,
  970. speVisible: false,
  971. modKey: "1",
  972. updataSwicth: false
  973. });
  974. this.companyReset();
  975. this.reset();
  976. },
  977. visitOk() {
  978. this.setState({
  979. visible: false,
  980. speVisible: false
  981. });
  982. this.reset();
  983. },
  984. closeDesc(e, s) {
  985. this.state.showDesc = e;
  986. if (s) {
  987. this.loadData(this.state.page);
  988. }
  989. },
  990. closeAssign(e, s) {
  991. this.state.roleName = "";
  992. this.state.assignVisible = e;
  993. if (s) {
  994. this.loadData(this.state.page);
  995. }
  996. },
  997. //添加工时
  998. okCancel(record) {
  999. this.setState({
  1000. lookVisible: true,
  1001. taskId: record.id
  1002. });
  1003. },
  1004. //测试
  1005. getOrgCodeUrl(e) {
  1006. this.setState({ orgCodeUrl: e });
  1007. },
  1008. //查看下证信息
  1009. loaduserss(record) {
  1010. $.ajax({
  1011. method: "get",
  1012. dataType: "json",
  1013. crossDomain: false,
  1014. url: globalConfig.context + "/api/admin/orderProject/selectTaskProgress",
  1015. data: {
  1016. tid: record.id
  1017. },
  1018. success: function(data) {
  1019. let theArr = [];
  1020. let thisData = [];
  1021. if (!thisData) {
  1022. if (data.error && data.error.length) {
  1023. message.warning(data.error[0].message);
  1024. }
  1025. thisData = {};
  1026. } else {
  1027. for (let i = 0; i < data.data.length; i++) {
  1028. thisData = data.data[i];
  1029. theArr.push({
  1030. num: i + 1,
  1031. key: i,
  1032. id: thisData.id, //编号
  1033. alreadyNumber: thisData.alreadyNumber, //下证数
  1034. licenceTimes: thisData.licenceTimes, //下证时间
  1035. notCount: thisData.notCount, //未下证数
  1036. flag: true
  1037. });
  1038. }
  1039. this.setState({
  1040. contactList: theArr
  1041. });
  1042. }
  1043. }.bind(this)
  1044. }).always(
  1045. function() {
  1046. this.setState({
  1047. loading: false
  1048. });
  1049. }.bind(this)
  1050. );
  1051. },
  1052. //下证信息保存
  1053. contactSave(record) {
  1054. if (!record.licenceTimes) {
  1055. message.warning("下证日期不能为空");
  1056. return;
  1057. }
  1058. if (!record.alreadyNumber) {
  1059. message.warning("下证数量不能为空");
  1060. return;
  1061. }
  1062. this.setState({
  1063. loading: true
  1064. });
  1065. $.ajax({
  1066. url: globalConfig.context + "/api/admin/orderProject/createTaskProgress",
  1067. method: "post",
  1068. data: {
  1069. taskId: this.state.id,
  1070. licenceTimes: record.licenceTimes,
  1071. alreadyNumber: record.alreadyNumber
  1072. }
  1073. }).done(
  1074. function(data) {
  1075. this.setState({
  1076. loading: false
  1077. });
  1078. if (!data.error.length) {
  1079. message.success("保存成功!");
  1080. record.flag = true;
  1081. this.loaduserss(this.state.dataArr);
  1082. } else {
  1083. message.warning(data.error[0].message);
  1084. }
  1085. }.bind(this)
  1086. );
  1087. },
  1088. //下证信息删除
  1089. contactDele(record) {
  1090. this.setState({
  1091. loading: true
  1092. });
  1093. $.ajax({
  1094. url: globalConfig.context + "/api/admin/orderProject/delectTaskProgress",
  1095. method: "post",
  1096. data: {
  1097. id: record.id
  1098. }
  1099. }).done(
  1100. function(data) {
  1101. this.setState({
  1102. loading: false
  1103. });
  1104. if (!data.error.length) {
  1105. this.loaduserss(this.state.dataArr);
  1106. } else {
  1107. message.warning(data.error[0].message);
  1108. }
  1109. }.bind(this)
  1110. );
  1111. },
  1112. //点击新增下证信息
  1113. addcontact() {
  1114. this.state.contactList.push({
  1115. num: this.state.contactList.length + 1,
  1116. key: this.state.contactList.length,
  1117. licenceTimes: "",
  1118. alreadyNumber: "",
  1119. notCount: "",
  1120. dels: "",
  1121. flag: false,
  1122. aflag: false
  1123. });
  1124. this.setState({
  1125. contactList: this.state.contactList
  1126. });
  1127. },
  1128. //删除下证信息
  1129. confirmDelet(record) {
  1130. this.state.contactList.splice(record.key, 1);
  1131. this.setState({
  1132. contactList: this.state.contactList
  1133. });
  1134. if (record.id) {
  1135. this.contactDele(record);
  1136. }
  1137. },
  1138. caozuorizhi() {
  1139. this.setState({
  1140. visibleA: true
  1141. });
  1142. $.ajax({
  1143. method: "get",
  1144. dataType: "json",
  1145. crossDomain: false,
  1146. url: globalConfig.context + "/api/admin/orderProject/TaskLogList",
  1147. data: {
  1148. id: this.state.id
  1149. },
  1150. success: function(data) {
  1151. let theArr = [];
  1152. if (data.error.length || data.data.list == "") {
  1153. if (data.error && data.error.length) {
  1154. message.warning(data.error[0].message);
  1155. }
  1156. } else {
  1157. for (let i = 0; i < data.data.length; i++) {
  1158. let thisdata = data.data[i];
  1159. theArr.push({
  1160. key: i,
  1161. id: thisdata.id, //日志ID
  1162. content: thisdata.content, //流程
  1163. taskId: thisdata.taskId, //项目ID
  1164. aName: thisdata.aName, //负责人
  1165. createTimes: thisdata.createTimes //时间
  1166. });
  1167. }
  1168. }
  1169. this.setState({
  1170. dataSourceA: theArr
  1171. });
  1172. }.bind(this)
  1173. }).always(
  1174. function() {
  1175. this.setState({
  1176. loading: false
  1177. });
  1178. }.bind(this)
  1179. );
  1180. },
  1181. //通知提醒
  1182. openNotification() {
  1183. notification.open({
  1184. message: "提醒",
  1185. description: "请在输入框中重新输入需要修改的选项!"
  1186. });
  1187. },
  1188. //关闭操作工时
  1189. visitCancelA() {
  1190. this.setState({
  1191. visibleA: false
  1192. });
  1193. },
  1194. callBack(e) {
  1195. this.setState({
  1196. modKey: e
  1197. });
  1198. this.loadCompany();
  1199. },
  1200. //添加公司
  1201. addCompany() {
  1202. this.setState({
  1203. switch: true
  1204. });
  1205. },
  1206. //保存和修改公司
  1207. saveCompany(id) {
  1208. if (this.companyJugle()) {
  1209. let upAndde = this.state.updataSwicth
  1210. ? {
  1211. api: "/api/admin/outsourceOrg/updateOutsourceOrg",
  1212. warn: "修改成功",
  1213. data: {
  1214. id: id,
  1215. name: this.state.cName,
  1216. contacts: this.state.companyContacts,
  1217. contactsMobile: this.state.companyContactsMobile,
  1218. province: this.state.companyProvinceArr[0],
  1219. city: this.state.companyProvinceArr[1],
  1220. area: this.state.companyProvinceArr[2],
  1221. address: this.state.companyAddress,
  1222. remarks: this.state.companyRemarks
  1223. }
  1224. }
  1225. : {
  1226. api: "/api/admin/outsourceOrg/addOutsourceOrg",
  1227. warn: "保存成功",
  1228. data: {
  1229. name: this.state.cName,
  1230. tid: this.state.RowData.id,
  1231. contacts: this.state.companyContacts,
  1232. contactsMobile: this.state.companyContactsMobile,
  1233. orderNo: this.state.orderNo,
  1234. province: this.state.companyProvinceArr[0],
  1235. city: this.state.companyProvinceArr[1],
  1236. area: this.state.companyProvinceArr[2],
  1237. address: this.state.companyAddress,
  1238. remarks: this.state.companyRemarks
  1239. }
  1240. };
  1241. $.ajax({
  1242. method: "post",
  1243. dataType: "json",
  1244. crossDomain: false,
  1245. url: globalConfig.context + upAndde.api,
  1246. data: upAndde.data,
  1247. success: function(data) {
  1248. if (data.error.length || data.data.list == "") {
  1249. if (data.error && data.error.length) {
  1250. message.warning(data.error[0].message);
  1251. }
  1252. }
  1253. }.bind(this)
  1254. }).done(
  1255. function() {
  1256. this.setState({
  1257. loading: false,
  1258. updataSwicth: false
  1259. });
  1260. this.companyReset();
  1261. message.success(upAndde.warn);
  1262. this.loadCompany();
  1263. }.bind(this)
  1264. );
  1265. }
  1266. },
  1267. //判断
  1268. companyJugle() {
  1269. if (this.state.cName === undefined) {
  1270. console.log(2345);
  1271. message.warning("公司名称不能为空!");
  1272. return;
  1273. }
  1274. if (this.state.companyContacts === undefined) {
  1275. message.warning("联系人不能为空!");
  1276. return;
  1277. }
  1278. if (this.state.companyContactsMobile === undefined) {
  1279. message.warning("联系人电话不能为空!");
  1280. return;
  1281. }
  1282. return true;
  1283. },
  1284. //删除外包
  1285. deleteCompany(id) {
  1286. $.ajax({
  1287. method: "post",
  1288. dataType: "json",
  1289. crossDomain: false,
  1290. url: globalConfig.context + "/api/admin/outsourceOrg/deleteOutsourceOrg",
  1291. data: {
  1292. id: id
  1293. },
  1294. success: function() {}.bind(this)
  1295. }).done(
  1296. function() {
  1297. this.setState({
  1298. loading: false
  1299. });
  1300. message.warning("删除成功");
  1301. this.loadCompany();
  1302. }.bind(this)
  1303. );
  1304. },
  1305. //重置外包
  1306. companyReset() {
  1307. this.setState({
  1308. cName: undefined,
  1309. companyContacts: undefined,
  1310. companyContactsMobile: undefined,
  1311. companyProvinceArr: [],
  1312. companyAddress: undefined,
  1313. companyRemarks: undefined
  1314. });
  1315. },
  1316. //加载外包
  1317. loadCompany() {
  1318. this.setState({
  1319. loading: true
  1320. });
  1321. $.ajax({
  1322. method: "get",
  1323. dataType: "json",
  1324. crossDomain: false,
  1325. url: globalConfig.context + "/api/admin/outsourceOrg/selectOutsourceOrg",
  1326. data: {
  1327. orderNo: this.state.RowData.orderNo,
  1328. tid: this.state.RowData.id
  1329. },
  1330. success: function(data) {
  1331. let theArr = [];
  1332. if (data.error.length || data.data.list == "") {
  1333. if (data.error && data.error.length) {
  1334. message.warning(data.error[0].message);
  1335. }
  1336. } else {
  1337. for (let i = 0; i < data.data.length; i++) {
  1338. let thisdata = data.data[i];
  1339. let ProvinceCityArr = [];
  1340. let ProvinceS = thisdata.province; //省
  1341. let citys = thisdata.city; //市
  1342. let Areas = thisdata.area; //区
  1343. ProvinceCityArr.push(ProvinceS, citys, Areas);
  1344. theArr.push({
  1345. key: i,
  1346. id: thisdata.id, //外包Id
  1347. name: thisdata.name, //名称
  1348. contacts: thisdata.contacts, //联系人
  1349. contactsMobile: thisdata.contactsMobile, //联系人电话
  1350. companyProvinceArr: ProvinceCityArr,
  1351. address: thisdata.address,
  1352. remarks: thisdata.remarks
  1353. });
  1354. }
  1355. }
  1356. this.setState({
  1357. companys: theArr
  1358. });
  1359. }.bind(this)
  1360. }).always(
  1361. function() {
  1362. this.setState({
  1363. loading: false
  1364. });
  1365. }.bind(this)
  1366. );
  1367. },
  1368. foo2() {
  1369. this.setState({
  1370. testFlag1: false
  1371. });
  1372. },
  1373. foo1() {
  1374. this.setState({
  1375. testFlag1: true
  1376. });
  1377. },
  1378. foo() {
  1379. this.setState({
  1380. testFlag: false
  1381. });
  1382. },
  1383. nextCancel() {
  1384. this.setState({
  1385. addnextVisible: false
  1386. });
  1387. },
  1388. //点击打卡项目详情
  1389. tableRowClickX(record) {
  1390. this.setState({
  1391. jid: record.id, //项目ID
  1392. kid: record.commodityId, //商品ID
  1393. commodityName: record.commodityName, //金额
  1394. commodityPrice: record.commodityPrice, //金额
  1395. commodityQuantity: record.commodityQuantity, //数量
  1396. taskComment: record.taskComment, //备注
  1397. main: record.main.toString(), //是否为主要
  1398. addnextVisible: true,
  1399. addState: 0
  1400. });
  1401. },
  1402. //关闭添加工时
  1403. noCancel() {
  1404. this.setState({
  1405. lookVisible: false
  1406. });
  1407. this.reset();
  1408. },
  1409. search() {
  1410. this.loadData();
  1411. },
  1412. reset() {
  1413. this.state.id = ""; //项目编号
  1414. this.state.orderNo = ""; //订单编号
  1415. this.state.contractNoSearch = undefined; //订单编号
  1416. this.state.projectStatus = undefined; //项目状态
  1417. this.state.projectStatusSearch = undefined; //项目状态
  1418. this.state.taskStatuSearch = undefined; //项目状态
  1419. this.state.taskComment = ""; //说明
  1420. this.state.startDate = ""; //启动日期
  1421. this.state.endDate = ""; //结束日期
  1422. this.state.acceptDate = ""; //受理日期
  1423. this.state.reviewDate = ""; //评审日期
  1424. this.state.publicityDate = ""; //公示日期
  1425. this.state.licenceDate = ""; //发证日期
  1426. attachmentUrl: []; //附件
  1427. this.state.contacts = ""; //联系人
  1428. this.state.contactMobile = ""; //联系人电话
  1429. this.state.legalPerson = ""; //法人
  1430. this.state.legalPersonTel = ""; //法人电话
  1431. this.state.taskId = ""; //项目编号
  1432. this.state.hours = ""; //工时
  1433. this.state.remarks = ""; //说明
  1434. this.state.taskDate = ""; //日期
  1435. this.state.taskComment = ""; //说明
  1436. this.state.nameSearch = "";
  1437. this.state.releaseDate = [];
  1438. this.state.orderNoSearch = "";
  1439. this.state.taskNoSearch = "";
  1440. this.state.distribution = undefined;
  1441. this.state.departmenttSearch = undefined;
  1442. this.state.outsourceName = ""; //外包公司名称
  1443. this.state.outsourcePrice = ""; //外包价格
  1444. this.loadData(this.state.page);
  1445. this.state.approvalSearch = undefined;
  1446. },
  1447. searchSwitch() {
  1448. this.setState({
  1449. searchMore: !this.state.searchMore
  1450. });
  1451. },
  1452. // 拆分详细
  1453. showRes(record) {
  1454. this.setState({
  1455. resVisible: true,
  1456. resRecord: record
  1457. });
  1458. },
  1459. resCancel() {
  1460. this.setState({
  1461. resVisible: false
  1462. });
  1463. },
  1464. //部门
  1465. departmentList() {
  1466. this.setState({
  1467. loading: true
  1468. });
  1469. $.ajax({
  1470. method: "get",
  1471. dataType: "json",
  1472. crossDomain: false,
  1473. url: globalConfig.context + "/api/admin/organization/selectSuperId",
  1474. data: {},
  1475. success: function(data) {
  1476. let thedata = data.data;
  1477. let theArr = [];
  1478. if (!thedata) {
  1479. if (data.error && data.error.length) {
  1480. message.warning(data.error[0].message);
  1481. }
  1482. thedata = {};
  1483. } else {
  1484. thedata.map(function(item, index) {
  1485. theArr.push({
  1486. key: index,
  1487. name: item.name,
  1488. id: item.id
  1489. });
  1490. });
  1491. }
  1492. this.setState({
  1493. departmentArr: theArr
  1494. });
  1495. }.bind(this)
  1496. }).always(
  1497. function() {
  1498. this.setState({
  1499. loading: false
  1500. });
  1501. }.bind(this)
  1502. );
  1503. },
  1504. changeList(arr) {
  1505. const newArr = [];
  1506. this.state.columns.forEach(item => {
  1507. arr.forEach(val => {
  1508. if (val === item.title) {
  1509. newArr.push(item);
  1510. }
  1511. });
  1512. });
  1513. this.setState({
  1514. changeList: newArr
  1515. });
  1516. },
  1517. timeClose() {
  1518. this.setState({
  1519. timeVisible: false
  1520. });
  1521. },
  1522. timeDetail(record) {
  1523. console.log(record);
  1524. this.setState({
  1525. loading: true,
  1526. recordHour: record.hours
  1527. });
  1528. $.ajax({
  1529. method: "get",
  1530. dataType: "json",
  1531. crossDomain: false,
  1532. url:
  1533. globalConfig.context + "/api/admin/orderProject/taskHoursDetailsList",
  1534. data: {
  1535. taskId: record.id
  1536. },
  1537. success: function(data) {
  1538. if (data.error && data.error.length) {
  1539. message.warning(data.error[0].message);
  1540. } else {
  1541. this.setState({
  1542. dataSourceTime: data.data
  1543. });
  1544. console.log(this.state.dataSourceTime);
  1545. }
  1546. }.bind(this)
  1547. }).always(
  1548. function() {
  1549. this.setState({
  1550. loading: false
  1551. });
  1552. }.bind(this)
  1553. );
  1554. },
  1555. render() {
  1556. const { TabPane } = Tabs;
  1557. const formItemLayout = {
  1558. labelCol: { span: 8 },
  1559. wrapperCol: { span: 14 }
  1560. };
  1561. let departmentArr = this.state.departmentArr || [];
  1562. return (
  1563. <div className="user-content">
  1564. {this.state.resVisible ? (
  1565. <ResolutionDetail
  1566. cancel={this.resCancel}
  1567. detail={this.state.resRecord}
  1568. visible={this.state.resVisible}
  1569. id={this.state.resRecord.orderNo}
  1570. />
  1571. ) : (
  1572. ""
  1573. )}
  1574. <ShowModalDiv ShowModal={this.state.showModal} />
  1575. <div className="content-title" style={{ marginBottom: 10 }}>
  1576. <span style={{ fontWeight: 900, fontSize: 16 }}>我的外包项目</span>
  1577. </div>
  1578. <Tabs defaultActiveKey="2" onChange={this.callback} className="test">
  1579. <TabPane tab="更改表格显示数据" key="1">
  1580. <div style={{ marginLeft: 10 }}>
  1581. <ChooseList
  1582. columns={this.state.columns}
  1583. changeFn={this.changeList}
  1584. changeList={this.state.changeList}
  1585. top={55}
  1586. margin={11}
  1587. />
  1588. </div>
  1589. </TabPane>
  1590. <TabPane tab="搜索" key="2">
  1591. <div className="user-search" style={{ marginLeft: 10 }}>
  1592. <Input
  1593. placeholder="客户名称"
  1594. value={this.state.nameSearch}
  1595. onChange={e => {
  1596. this.setState({ nameSearch: e.target.value });
  1597. }}
  1598. />
  1599. <Input
  1600. placeholder="订单编号"
  1601. value={this.state.orderNoSearch}
  1602. onChange={e => {
  1603. this.setState({ orderNoSearch: e.target.value });
  1604. }}
  1605. />
  1606. <Input
  1607. placeholder="合同编号"
  1608. value={this.state.contractNoSearch}
  1609. onChange={e => {
  1610. this.setState({ contractNoSearch: e.target.value });
  1611. }}
  1612. />
  1613. <Input
  1614. placeholder="项目编号"
  1615. value={this.state.taskNoSearch}
  1616. onChange={e => {
  1617. this.setState({ taskNoSearch: e.target.value });
  1618. }}
  1619. />
  1620. <Select
  1621. placeholder="选择部门"
  1622. style={{ width: 150, marginRight: "10px" }}
  1623. value={this.state.departmenttSearch}
  1624. onChange={e => {
  1625. this.setState({ departmenttSearch: e });
  1626. }}
  1627. >
  1628. {departmentArr.map(function(item) {
  1629. return (
  1630. <Select.Option key={item.id}>{item.name}</Select.Option>
  1631. );
  1632. })}
  1633. </Select>
  1634. <Select
  1635. placeholder="项目状态"
  1636. style={{ width: 150, marginRight: "10px" }}
  1637. value={this.state.projectStatusSearch}
  1638. onChange={e => {
  1639. this.setState({ projectStatusSearch: e });
  1640. console.log(this.state.projectStatusSearch);
  1641. }}
  1642. >
  1643. {projectStatus.map(function(item) {
  1644. return (
  1645. <Select.Option key={item.value}>{item.key}</Select.Option>
  1646. );
  1647. })}
  1648. </Select>
  1649. <Select
  1650. placeholder="特批状态"
  1651. style={{ width: 150, marginRight: "10px" }}
  1652. value={this.state.approvalSearch}
  1653. onChange={e => {
  1654. this.setState({ approvalSearch: e });
  1655. console.log(this.state.approvalSearch);
  1656. }}
  1657. >
  1658. <Select.Option key={0}>非特批</Select.Option>
  1659. <Select.Option key={1}>特批</Select.Option>
  1660. </Select>
  1661. <Button type="primary" onClick={this.search}>
  1662. 搜索
  1663. </Button>
  1664. <Button onClick={this.reset}>重置</Button>
  1665. {/* <span>更多搜索<Switch defaultChecked={false} onChange={this.searchSwitch.bind(this)} /></span>
  1666. <div className="search-more" style={this.state.searchMore ? { display: 'none' } : {}}>
  1667. <span>订单时间 :</span>
  1668. <RangePicker
  1669. value={[this.state.releaseDate[0] ? moment(this.state.releaseDate[0]) : null,
  1670. this.state.releaseDate[1] ? moment(this.state.releaseDate[1]) : null]}
  1671. onChange={(data, dataString) => { this.setState({ releaseDate: dataString }); }} />
  1672. </div> */}
  1673. </div>
  1674. </TabPane>
  1675. <TabPane tab="导出Excel" key="3">
  1676. <Button
  1677. type="primary"
  1678. style={{ margin: "11px 0 10px 10px" }}
  1679. onClick={this.exportExec}
  1680. >
  1681. 导出Excel
  1682. </Button>
  1683. </TabPane>
  1684. {/* <TabPane tab="批量操作" key="6">
  1685. <Button
  1686. type="primary"
  1687. disabled={this.state.selectedRowKeys.length == 0}
  1688. style={{ margin: "0px 0px 10px 10px" }}
  1689. onClick={e => {
  1690. e.stopPropagation(),
  1691. this.evaluateY(this.state.selectedRowKeys, "财务专员");
  1692. }}
  1693. >
  1694. 转交
  1695. </Button>
  1696. </TabPane> */}
  1697. </Tabs>
  1698. <div className="patent-table">
  1699. <Spin spinning={this.state.loading}>
  1700. <Table
  1701. columns={
  1702. this.state.changeList == undefined
  1703. ? this.state.columns
  1704. : this.state.changeList
  1705. }
  1706. dataSource={this.state.dataSource}
  1707. pagination={this.state.pagination}
  1708. onRowClick={this.tableRowClick.bind(this)}
  1709. scroll={{ x: "max-content", y: 0 }}
  1710. bordered
  1711. size={"small"}
  1712. />
  1713. </Spin>
  1714. </div>
  1715. <Assign
  1716. title="项目"
  1717. selApi={"/api/admin/orderProject/projectDistribution"}
  1718. data={this.state.assignData}
  1719. showDesc={this.state.assignVisible}
  1720. closeDesc={this.closeAssign.bind(this)}
  1721. fenpaiData={8}
  1722. specially={0}
  1723. roleName={this.state.nub}
  1724. requestMethod={"post"}
  1725. flag={this.state.flag}
  1726. isZhuan={this.state.isZhuan} //是否转交
  1727. />
  1728. <Modal
  1729. className="customeDetails"
  1730. footer=""
  1731. title=""
  1732. width="900px"
  1733. visible={this.state.visible}
  1734. onOk={this.visitOk}
  1735. onCancel={this.visitCancel}
  1736. >
  1737. <Tabs
  1738. onChange={this.callBack}
  1739. type="card"
  1740. activeKey={this.state.modKey}
  1741. >
  1742. <TabPane tab="项目概况" key="1">
  1743. <Form
  1744. layout="horizontal"
  1745. onSubmit={this.handleSubmit}
  1746. id="demand-form"
  1747. style={{ paddingBottom: "00px" }}
  1748. >
  1749. <Spin spinning={this.state.loading}>
  1750. <div className="clearfix">
  1751. <div className="clearfix">
  1752. <FormItem
  1753. className="half-item"
  1754. {...formItemLayout}
  1755. label="当前项目情况"
  1756. >
  1757. <Radio.Group
  1758. value={this.state.status}
  1759. onChange={e => {
  1760. this.setState({ status: e.target.value });
  1761. }}
  1762. >
  1763. <Radio value={0}>开启</Radio>
  1764. <Radio value={1}>暂停</Radio>
  1765. </Radio.Group>
  1766. <Button
  1767. type="primary"
  1768. size="small"
  1769. style={{ marginTop: "5px", position: "absolute" }}
  1770. onClick={this.caozuorizhi}
  1771. >
  1772. 操作日志
  1773. </Button>
  1774. </FormItem>
  1775. <FormItem
  1776. className="half-item"
  1777. {...formItemLayout}
  1778. label="合同编号"
  1779. >
  1780. <span>{this.state.contractNo}</span>
  1781. </FormItem>
  1782. </div>
  1783. <div className="clearfix">
  1784. <FormItem
  1785. className="half-item"
  1786. {...formItemLayout}
  1787. label="项目状态"
  1788. >
  1789. <Select
  1790. placeholder="选择项目状态"
  1791. style={{ width: "200px" }}
  1792. value={this.state.projectStatus}
  1793. onChange={e => {
  1794. this.setState({ projectStatus: e });
  1795. }}
  1796. >
  1797. {projectStatus.map(function(item) {
  1798. return (
  1799. <Select.Option key={item.value}>
  1800. {item.key}
  1801. </Select.Option>
  1802. );
  1803. })}
  1804. </Select>
  1805. </FormItem>
  1806. <FormItem
  1807. className="half-item"
  1808. {...formItemLayout}
  1809. label="是否特批"
  1810. >
  1811. <span>{getApproval(this.state.approval)}</span>
  1812. </FormItem>
  1813. <FormItem
  1814. className="half-item"
  1815. {...formItemLayout}
  1816. label="结算状态"
  1817. >
  1818. <span>
  1819. {getLiquidationStatus(this.state.liquidationStatus)}
  1820. </span>
  1821. </FormItem>
  1822. <FormItem
  1823. className="half-item"
  1824. {...formItemLayout}
  1825. label="流程状态"
  1826. >
  1827. <span>
  1828. {getProcessStatus(this.state.processStatus)}
  1829. </span>
  1830. </FormItem>
  1831. <FormItem
  1832. className="half-item"
  1833. {...formItemLayout}
  1834. label="订单编号"
  1835. >
  1836. <span>{this.state.orderNo}</span>
  1837. </FormItem>
  1838. </div>
  1839. <div className="clearfix">
  1840. <FormItem
  1841. className="half-item"
  1842. {...formItemLayout}
  1843. label="满意度表格"
  1844. >
  1845. <Radio.Group
  1846. value={this.state.formRetrieve}
  1847. onChange={e => {
  1848. this.setState({ formRetrieve: e.target.value });
  1849. }}
  1850. >
  1851. <Radio value={0}>未收回</Radio>
  1852. <Radio value={1}>已收回</Radio>
  1853. <Radio value={2}>其他</Radio>
  1854. </Radio.Group>
  1855. </FormItem>
  1856. <FormItem
  1857. className="half-item"
  1858. {...formItemLayout}
  1859. label="退单"
  1860. >
  1861. <Radio.Group
  1862. value={this.state.taskRefund}
  1863. onChange={e => {
  1864. this.setState({ taskRefund: e.target.value });
  1865. }}
  1866. >
  1867. <Radio value={0}>已完成</Radio>
  1868. <Radio value={1}>未完成</Radio>
  1869. <Radio value={2}>其他</Radio>
  1870. </Radio.Group>
  1871. </FormItem>
  1872. </div>
  1873. <div className="clearfix">
  1874. {
  1875. <FormItem
  1876. className="half-item"
  1877. {...formItemLayout}
  1878. label="(满意度)备注"
  1879. >
  1880. <Input
  1881. type="textarea"
  1882. placeholder="请输入备注"
  1883. rows={2}
  1884. value={this.state.retrieveContent}
  1885. onChange={e => {
  1886. this.setState({
  1887. retrieveContent: e.target.value
  1888. });
  1889. }}
  1890. />
  1891. </FormItem>
  1892. }
  1893. {
  1894. <FormItem
  1895. className="half-item"
  1896. {...formItemLayout}
  1897. label="(退单)备注"
  1898. >
  1899. <Input
  1900. type="textarea"
  1901. placeholder="请输入备注"
  1902. rows={2}
  1903. value={this.state.refundContent}
  1904. onChange={e => {
  1905. this.setState({ refundContent: e.target.value });
  1906. }}
  1907. />
  1908. </FormItem>
  1909. }
  1910. </div>
  1911. <div className="clearfix">
  1912. <h3 className="sub-title">订单负责人信息</h3>
  1913. <FormItem
  1914. className="half-item"
  1915. {...formItemLayout}
  1916. label="负责人"
  1917. >
  1918. <span>
  1919. {this.state.salesmanName +
  1920. "(" +
  1921. this.state.depName +
  1922. ")"}
  1923. </span>
  1924. </FormItem>
  1925. <FormItem
  1926. className="half-item"
  1927. {...formItemLayout}
  1928. label="负责人电话"
  1929. >
  1930. <span>{this.state.salesmanMobile}</span>
  1931. </FormItem>
  1932. <FormItem
  1933. className="half-item"
  1934. {...formItemLayout}
  1935. label="当前财务负责人"
  1936. >
  1937. <span>{this.state.nowFinance}</span>
  1938. </FormItem>
  1939. <FormItem
  1940. className="half-item"
  1941. {...formItemLayout}
  1942. label="当前财务负责人电话"
  1943. >
  1944. <span>{this.state.nowFinanceMobile}</span>
  1945. </FormItem>
  1946. <FormItem
  1947. className="half-item"
  1948. {...formItemLayout}
  1949. style={{ opacity: ".5" }}
  1950. label="原负责人"
  1951. >
  1952. <span>{this.state.oldSalesmanName}</span>
  1953. </FormItem>
  1954. <FormItem
  1955. className="half-item"
  1956. {...formItemLayout}
  1957. style={{ opacity: ".5" }}
  1958. label="原负责人电话"
  1959. >
  1960. <span>{this.state.oldSalesmanMobile}</span>
  1961. </FormItem>
  1962. <FormItem
  1963. className="half-item"
  1964. {...formItemLayout}
  1965. style={{ opacity: ".5" }}
  1966. label="实际财务操作人"
  1967. >
  1968. <span>{this.state.financeName}</span>
  1969. </FormItem>
  1970. <FormItem
  1971. className="half-item"
  1972. {...formItemLayout}
  1973. style={{ opacity: ".5" }}
  1974. label="实际财务操作人电话"
  1975. >
  1976. <span>{this.state.financeMobile}</span>
  1977. </FormItem>
  1978. </div>
  1979. {/*<hr style={{border:'1px dashed #aaa', width:"90%",margin:'auto'}}/>*/}
  1980. <div className="clearfix">
  1981. <h3 className="sub-title">联系信息</h3>
  1982. <FormItem
  1983. className="half-item"
  1984. {...formItemLayout}
  1985. label="客户名称"
  1986. >
  1987. <span>{this.state.userName}</span>
  1988. </FormItem>
  1989. <FormItem
  1990. className="half-item"
  1991. {...formItemLayout}
  1992. label="企业法人"
  1993. >
  1994. <Input
  1995. placeholder="请输入法人名称"
  1996. value={this.state.legalPerson}
  1997. style={{ width: "200px" }}
  1998. onChange={e => {
  1999. this.setState({ legalPerson: e.target.value });
  2000. }}
  2001. ref="commodityQuantity"
  2002. />
  2003. </FormItem>
  2004. <FormItem
  2005. className="half-item"
  2006. {...formItemLayout}
  2007. label="法人电话"
  2008. >
  2009. <Input
  2010. placeholder="请输入法人电话"
  2011. value={this.state.legalPersonTel}
  2012. style={{ width: "200px" }}
  2013. onChange={e => {
  2014. this.setState({ legalPersonTel: e.target.value });
  2015. }}
  2016. ref="commodityQuantity"
  2017. />
  2018. </FormItem>
  2019. <FormItem
  2020. className="half-item"
  2021. {...formItemLayout}
  2022. label="客户联系人"
  2023. >
  2024. <Input
  2025. placeholder="请输入联系人名称"
  2026. value={this.state.contacts}
  2027. style={{ width: "200px" }}
  2028. onChange={e => {
  2029. this.setState({ contacts: e.target.value });
  2030. }}
  2031. ref="commodityQuantity"
  2032. />
  2033. </FormItem>
  2034. <FormItem
  2035. className="half-item"
  2036. {...formItemLayout}
  2037. label="联系人电话"
  2038. >
  2039. <Input
  2040. placeholder="请输入联系人电话"
  2041. value={this.state.contactMobile}
  2042. style={{ width: "200px" }}
  2043. onChange={e => {
  2044. this.setState({ contactMobile: e.target.value });
  2045. }}
  2046. ref="commodityQuantity"
  2047. />
  2048. </FormItem>
  2049. <FormItem
  2050. className="half-item"
  2051. {...formItemLayout}
  2052. label="企业地址"
  2053. >
  2054. <Cascader
  2055. options={areaSelect()}
  2056. value={this.state.ProvinceCity}
  2057. placeholder="选择城市"
  2058. style={{ width: "200px" }}
  2059. onChange={e => {
  2060. this.setState({ ProvinceCity: e });
  2061. }}
  2062. />
  2063. </FormItem>
  2064. <FormItem
  2065. className="half-item"
  2066. {...formItemLayout}
  2067. label=""
  2068. ></FormItem>
  2069. <FormItem
  2070. className="half-item"
  2071. {...formItemLayout}
  2072. label=""
  2073. >
  2074. <Input
  2075. placeholder="请输入详细地址"
  2076. value={this.state.postalAddress}
  2077. style={{ width: "200px", marginLeft: "12em" }}
  2078. onChange={e => {
  2079. this.setState({ postalAddress: e.target.value });
  2080. }}
  2081. ref="commodityQuantity"
  2082. />
  2083. </FormItem>
  2084. </div>
  2085. {/*<hr style={{border:'1px dashed #aaa', width:"90%",margin:'auto'}}/>*/}
  2086. <div className="clearfix">
  2087. <h3 className="sub-title">项目信息</h3>
  2088. <FormItem
  2089. className="half-item"
  2090. {...formItemLayout}
  2091. label="项目编号"
  2092. >
  2093. <span>
  2094. {this.state.splitStatus == 2
  2095. ? this.state.splitSuper + "-" + this.state.splitId
  2096. : this.state.id}
  2097. </span>
  2098. </FormItem>
  2099. <FormItem
  2100. className="half-item"
  2101. {...formItemLayout}
  2102. label="项目名称"
  2103. >
  2104. <span>{this.state.taskName}</span>
  2105. </FormItem>
  2106. <FormItem
  2107. className="half-item"
  2108. {...formItemLayout}
  2109. label="项目状态"
  2110. >
  2111. <Select
  2112. placeholder="选择项目状态"
  2113. style={{ width: "200px" }}
  2114. value={this.state.taskStatus}
  2115. onChange={e => {
  2116. this.setState({ taskStatus: e });
  2117. }}
  2118. >
  2119. {taskStatus.map(function(item) {
  2120. return (
  2121. <Select.Option key={item.value}>
  2122. {item.key}
  2123. </Select.Option>
  2124. );
  2125. })}
  2126. </Select>
  2127. </FormItem>
  2128. <FormItem
  2129. className="half-item"
  2130. {...formItemLayout}
  2131. label="项目类别"
  2132. >
  2133. <span>{this.state.cname}</span>
  2134. </FormItem>
  2135. <FormItem
  2136. className="half-item"
  2137. {...formItemLayout}
  2138. label="证书编号"
  2139. >
  2140. <Input
  2141. placeholder="请输入证书编号"
  2142. value={this.state.certificateNumber}
  2143. style={{ width: "200px" }}
  2144. onChange={e => {
  2145. this.setState({
  2146. certificateNumber: e.target.value
  2147. });
  2148. }}
  2149. ref="commodityQuantity"
  2150. />
  2151. </FormItem>
  2152. </div>
  2153. <div className="clearfix">
  2154. <h3 className="sub-title">申报系统账户信息</h3>
  2155. {/*<span style={{color:'red'}}>注:仅技术部可见</span>*/}
  2156. <FormItem
  2157. className="half-item"
  2158. {...formItemLayout}
  2159. label="用户名"
  2160. >
  2161. <Input
  2162. placeholder="请输入用户名"
  2163. value={this.state.declareUser}
  2164. style={{ width: "200px" }}
  2165. onChange={e => {
  2166. this.setState({ declareUser: e.target.value });
  2167. }}
  2168. />
  2169. </FormItem>
  2170. <FormItem
  2171. className="half-item"
  2172. {...formItemLayout}
  2173. label="密码"
  2174. >
  2175. <Input
  2176. placeholder="请输入密码"
  2177. value={this.state.declarePwd}
  2178. style={{ width: "200px" }}
  2179. onChange={e => {
  2180. this.setState({ declarePwd: e.target.value });
  2181. }}
  2182. />
  2183. </FormItem>
  2184. </div>
  2185. <div className="clearfix">
  2186. <h3 className="sub-title">项目申报进度</h3>
  2187. <FormItem
  2188. className="half-item"
  2189. {...formItemLayout}
  2190. label="启动时间"
  2191. >
  2192. <DatePicker
  2193. style={{
  2194. marginTop: "2px",
  2195. width: "200px",
  2196. height: "32px"
  2197. }}
  2198. showTime
  2199. format="YYYY-MM-DD"
  2200. onOk={() => {}}
  2201. value={
  2202. this.state.startDate
  2203. ? moment(this.state.startDate)
  2204. : null
  2205. }
  2206. onChange={(data, dataString) => {
  2207. this.setState({ startDate: dataString });
  2208. }}
  2209. />
  2210. </FormItem>
  2211. <FormItem
  2212. className="half-item"
  2213. {...formItemLayout}
  2214. label="完成时间"
  2215. >
  2216. <DatePicker
  2217. style={{
  2218. marginTop: "2px",
  2219. width: "200px",
  2220. height: "32px"
  2221. }}
  2222. showTime
  2223. format="YYYY-MM-DD"
  2224. onOk={() => {}}
  2225. value={
  2226. this.state.endDate
  2227. ? moment(this.state.endDate)
  2228. : null
  2229. }
  2230. onChange={(data, dataString) => {
  2231. this.setState({ endDate: dataString });
  2232. }}
  2233. />
  2234. </FormItem>
  2235. <FormItem
  2236. className="half-item"
  2237. {...formItemLayout}
  2238. label="受理时间"
  2239. >
  2240. <DatePicker
  2241. style={{
  2242. marginTop: "2px",
  2243. width: "200px",
  2244. height: "32px"
  2245. }}
  2246. showTime
  2247. format="YYYY-MM-DD"
  2248. onOk={() => {}}
  2249. value={
  2250. this.state.acceptDate
  2251. ? moment(this.state.acceptDate)
  2252. : null
  2253. }
  2254. onChange={(data, dataString) => {
  2255. this.setState({ acceptDate: dataString });
  2256. }}
  2257. />
  2258. </FormItem>
  2259. <FormItem
  2260. className="half-item"
  2261. {...formItemLayout}
  2262. label="评审时间"
  2263. >
  2264. <DatePicker
  2265. style={{
  2266. marginTop: "2px",
  2267. width: "200px",
  2268. height: "32px"
  2269. }}
  2270. showTime
  2271. format="YYYY-MM-DD"
  2272. onOk={() => {}}
  2273. value={
  2274. this.state.reviewDate
  2275. ? moment(this.state.reviewDate)
  2276. : null
  2277. }
  2278. onChange={(data, dataString) => {
  2279. this.setState({ reviewDate: dataString });
  2280. }}
  2281. />
  2282. </FormItem>
  2283. <FormItem
  2284. className="half-item"
  2285. {...formItemLayout}
  2286. label="公示时间"
  2287. >
  2288. <DatePicker
  2289. style={{
  2290. marginTop: "2px",
  2291. width: "200px",
  2292. height: "32px"
  2293. }}
  2294. showTime
  2295. format="YYYY-MM-DD"
  2296. onOk={() => {}}
  2297. value={
  2298. this.state.publicityDate
  2299. ? moment(this.state.publicityDate)
  2300. : null
  2301. }
  2302. onChange={(data, dataString) => {
  2303. this.setState({ publicityDate: dataString });
  2304. }}
  2305. />
  2306. </FormItem>
  2307. <FormItem
  2308. className="half-item"
  2309. {...formItemLayout}
  2310. label="发证时间"
  2311. >
  2312. <DatePicker
  2313. style={{
  2314. marginTop: "2px",
  2315. width: "200px",
  2316. height: "32px"
  2317. }}
  2318. showTime
  2319. format="YYYY-MM-DD"
  2320. onOk={() => {}}
  2321. value={
  2322. this.state.licenceDate
  2323. ? moment(this.state.licenceDate)
  2324. : null
  2325. }
  2326. onChange={(data, dataString) => {
  2327. this.setState({ licenceDate: dataString });
  2328. }}
  2329. />
  2330. </FormItem>
  2331. <FormItem
  2332. className="half-item"
  2333. {...formItemLayout}
  2334. label="立项金额(万元)"
  2335. >
  2336. <Input
  2337. placeholder="请输入立项金额"
  2338. value={this.state.setUpAmount}
  2339. style={{ width: "200px" }}
  2340. onChange={e => {
  2341. this.setState({ setUpAmount: e.target.value });
  2342. }}
  2343. ref="commodityQuantity"
  2344. />
  2345. </FormItem>
  2346. <FormItem
  2347. className="half-item"
  2348. {...formItemLayout}
  2349. label="是否到款"
  2350. >
  2351. <Radio.Group
  2352. value={this.state.arrivalMoney}
  2353. onChange={e => {
  2354. this.setState({ arrivalMoney: e.target.value });
  2355. }}
  2356. >
  2357. <Radio value={0}>未到企业</Radio>
  2358. <Radio value={1}>已到企业</Radio>
  2359. </Radio.Group>
  2360. </FormItem>
  2361. </div>
  2362. <div className="clearfix">
  2363. <FormItem
  2364. labelCol={{ span: 3 }}
  2365. wrapperCol={{ span: 16 }}
  2366. label="附件"
  2367. >
  2368. <Picture
  2369. fileList={e => {
  2370. this.setState({ attachmentUrl: e });
  2371. }}
  2372. pictureUrl={this.state.attachmentUrl}
  2373. visible={this.props.visible}
  2374. data={{
  2375. sign: "order_task_file",
  2376. url: "/api/admin/orderProject/uploadOrderTaskFile",
  2377. number: 8
  2378. }}
  2379. />
  2380. </FormItem>
  2381. </div>
  2382. <div className="clearfix">
  2383. <FormItem
  2384. labelCol={{ span: 3 }}
  2385. wrapperCol={{ span: 16 }}
  2386. label="备注"
  2387. >
  2388. <Input
  2389. type="textarea"
  2390. placeholder="请输入备注"
  2391. rows={4}
  2392. value={this.state.taskComment}
  2393. onChange={e => {
  2394. this.setState({ taskComment: e.target.value });
  2395. }}
  2396. />
  2397. </FormItem>
  2398. </div>
  2399. <div>
  2400. <h3 className="sub-title">项目业务</h3>
  2401. {this.state.processStatus == 0 ? (
  2402. <Button
  2403. type="primary"
  2404. onClick={this.addDetailed}
  2405. style={{
  2406. float: "right",
  2407. marginRight: "50px",
  2408. marginBottom: "15px"
  2409. }}
  2410. >
  2411. 添加项目明细
  2412. </Button>
  2413. ) : (
  2414. ""
  2415. )}
  2416. </div>
  2417. <div className="patent-table">
  2418. <Spin spinning={this.state.loading}>
  2419. <Table
  2420. columns={this.state.columnsX}
  2421. dataSource={this.state.dataSourceX}
  2422. pagination={this.state.paginations}
  2423. onRowClick={this.tableRowClickX}
  2424. bordered
  2425. size="small"
  2426. />
  2427. </Spin>
  2428. </div>
  2429. <div className="clearfix">
  2430. <Button
  2431. className="cancel"
  2432. type="primary"
  2433. onClick={this.tijiaoOk}
  2434. style={{ marginLeft: "200px", marginTop: "10px" }}
  2435. htmlType="submit"
  2436. >
  2437. 保存
  2438. </Button>
  2439. <Button
  2440. className="cancel"
  2441. type="ghost"
  2442. onClick={this.visitCancel}
  2443. style={{ marginLeft: "50px", marginTop: "10px" }}
  2444. >
  2445. 取消
  2446. </Button>
  2447. </div>
  2448. </div>
  2449. </Spin>
  2450. </Form>
  2451. </TabPane>
  2452. <TabPane tab="外包接单公司信息" key="2">
  2453. {/*<Button type="primary" onClick={this.addCompany} style={{float:'right',marginBottom:'10px'}}>+新增接单公司</Button>*/}
  2454. {
  2455. <div className="clearfix">
  2456. <h3 className="sub-title" style={{ marginBottom: "10px" }}>
  2457. 新增(编辑)接单公司
  2458. </h3>
  2459. <FormItem
  2460. className="three-item"
  2461. {...formItemLayout}
  2462. label={
  2463. <span>
  2464. <strong style={{ color: "#f00" }}>*</strong>公司名称
  2465. </span>
  2466. }
  2467. >
  2468. <Input
  2469. placeholder="请输入公司名称"
  2470. value={this.state.cName}
  2471. style={{ width: "200px" }}
  2472. onChange={e => {
  2473. this.setState({ cName: e.target.value });
  2474. }}
  2475. className="height-input"
  2476. />
  2477. </FormItem>
  2478. <FormItem
  2479. className="three-item"
  2480. {...formItemLayout}
  2481. label={
  2482. <span>
  2483. <strong style={{ color: "#f00" }}>*</strong>联系人
  2484. </span>
  2485. }
  2486. >
  2487. <Input
  2488. placeholder="请输入联系人名称"
  2489. value={this.state.companyContacts}
  2490. style={{ width: "200px" }}
  2491. onChange={e => {
  2492. this.setState({ companyContacts: e.target.value });
  2493. }}
  2494. className="height-input"
  2495. />
  2496. </FormItem>
  2497. <FormItem
  2498. className="three-item"
  2499. {...formItemLayout}
  2500. label={
  2501. <span>
  2502. <strong style={{ color: "#f00" }}>*</strong>联系人电话
  2503. </span>
  2504. }
  2505. >
  2506. <Input
  2507. placeholder="请输入联系人电话"
  2508. value={this.state.companyContactsMobile}
  2509. style={{ width: "200px" }}
  2510. onChange={e => {
  2511. this.setState({
  2512. companyContactsMobile: e.target.value
  2513. });
  2514. }}
  2515. className="height-input"
  2516. />
  2517. </FormItem>
  2518. <FormItem
  2519. className="three-item"
  2520. {...formItemLayout}
  2521. label="企业地址"
  2522. >
  2523. <Cascader
  2524. options={areaSelect()}
  2525. value={this.state.companyProvinceArr}
  2526. placeholder="选择城市"
  2527. style={{ width: "200px" }}
  2528. onChange={e => {
  2529. this.setState({ companyProvinceArr: e });
  2530. }}
  2531. />
  2532. </FormItem>
  2533. <FormItem className="three-item" {...formItemLayout} label="">
  2534. <Input
  2535. placeholder="请输入详细地址"
  2536. value={this.state.companyAddress}
  2537. style={{ width: "200px", marginLeft: "12em" }}
  2538. onChange={e => {
  2539. this.setState({ companyAddress: e.target.value });
  2540. }}
  2541. className="height-input"
  2542. />
  2543. </FormItem>
  2544. <FormItem
  2545. className="three-item"
  2546. {...formItemLayout}
  2547. label=""
  2548. ></FormItem>
  2549. <div className="clearfix">
  2550. <FormItem
  2551. labelCol={{ span: 3 }}
  2552. wrapperCol={{ span: 16 }}
  2553. label="备注"
  2554. >
  2555. <Input
  2556. type="textarea"
  2557. placeholder="请输入备注"
  2558. rows={4}
  2559. value={this.state.companyRemarks}
  2560. onChange={e => {
  2561. this.setState({ companyRemarks: e.target.value });
  2562. }}
  2563. />
  2564. </FormItem>
  2565. </div>
  2566. <Button
  2567. type="primary"
  2568. style={{
  2569. float: "right",
  2570. marginTop: "10px",
  2571. marginRight: "50px"
  2572. }}
  2573. onClick={() => {
  2574. this.saveCompany(this.state.companyId);
  2575. }}
  2576. >
  2577. 保存
  2578. </Button>
  2579. </div>
  2580. }
  2581. <p style={{ color: "red" }}>
  2582. 提示:查看备注请点击表格左侧加号按钮~
  2583. </p>
  2584. <div className="patent-table" style={{ marginTop: "10px" }}>
  2585. <Spin spinning={this.state.loading}>
  2586. <Table
  2587. columns={this.state.companyColumns}
  2588. dataSource={this.state.companys}
  2589. scroll={{ x: 300, y: 0 }}
  2590. bordered
  2591. size="small"
  2592. expandedRowRender={record => {
  2593. return <p>{record.remarks}</p>;
  2594. }}
  2595. pagination={false}
  2596. />
  2597. </Spin>
  2598. </div>
  2599. </TabPane>
  2600. </Tabs>
  2601. </Modal>
  2602. <Modal
  2603. maskClosable={false}
  2604. visible={this.state.lookVisible}
  2605. onOk={this.noCancel}
  2606. onCancel={this.noCancel}
  2607. width="500px"
  2608. title={"添加工时"}
  2609. footer=""
  2610. className="admin-desc-content"
  2611. >
  2612. <Form layout="horizontal" id="demand-form">
  2613. <Spin spinning={this.state.loading}>
  2614. <div className="clearfix">
  2615. <FormItem {...formItemLayout} label="工作日期">
  2616. <DatePicker
  2617. style={{ marginTop: "2px", width: "200px", height: "32px" }}
  2618. showTime
  2619. format="YYYY-MM-DD"
  2620. onOk={() => {}}
  2621. value={
  2622. this.state.taskDate ? moment(this.state.taskDate) : null
  2623. }
  2624. onChange={(data, dataString) => {
  2625. this.setState({ taskDate: dataString });
  2626. }}
  2627. />
  2628. </FormItem>
  2629. </div>
  2630. <div className="clearfix">
  2631. <FormItem {...formItemLayout} label="工作时长">
  2632. <Input
  2633. placeholder="请输入工作时长"
  2634. value={this.state.hours}
  2635. style={{ width: "200px" }}
  2636. onChange={e => {
  2637. this.setState({ hours: e.target.value });
  2638. }}
  2639. ref="commodityQuantity"
  2640. />
  2641. </FormItem>
  2642. </div>
  2643. <div className="clearfix">
  2644. <FormItem {...formItemLayout} label="工作内容">
  2645. <Input
  2646. type="textarea"
  2647. placeholder="请输入备注"
  2648. rows={4}
  2649. value={this.state.remarks}
  2650. onChange={e => {
  2651. this.setState({ remarks: e.target.value });
  2652. }}
  2653. />
  2654. </FormItem>
  2655. </div>
  2656. <div className="clearfix">
  2657. <Button
  2658. className="cancel"
  2659. type="primary"
  2660. onClick={this.tianjiaOk}
  2661. style={{ marginLeft: "100px", marginTop: "10px" }}
  2662. htmlType="submit"
  2663. >
  2664. 确定
  2665. </Button>
  2666. <Button
  2667. className="cancel"
  2668. type="ghost"
  2669. onClick={this.noCancel}
  2670. style={{ marginLeft: "50px" }}
  2671. >
  2672. 取消
  2673. </Button>
  2674. </div>
  2675. </Spin>
  2676. </Form>
  2677. </Modal>
  2678. <Modal
  2679. maskClosable={false}
  2680. visible={this.state.addnextVisible}
  2681. onOk={this.nextCancel}
  2682. onCancel={this.nextCancel}
  2683. width="800px"
  2684. title="项目项目详情"
  2685. footer=""
  2686. className="admin-desc-content"
  2687. >
  2688. <Form layout="horizontal" onSubmit={this.nextSubmit} id="demand-form">
  2689. <Spin spinning={this.state.loading}>
  2690. <div className="clearfix">
  2691. <FormItem
  2692. className="half-item"
  2693. {...formItemLayout}
  2694. label="项目名称"
  2695. >
  2696. <span>{this.state.commodityName}</span>
  2697. </FormItem>
  2698. <FormItem
  2699. className="half-item"
  2700. {...formItemLayout}
  2701. label="项目数量"
  2702. >
  2703. <span>{this.state.commodityQuantity}</span>
  2704. </FormItem>
  2705. <FormItem
  2706. className="half-item"
  2707. {...formItemLayout}
  2708. label="金额(万元)"
  2709. >
  2710. <span>{this.state.commodityPrice}</span>
  2711. </FormItem>
  2712. <FormItem
  2713. className="half-item"
  2714. {...formItemLayout}
  2715. label="主要项目"
  2716. >
  2717. <span>{getboutique(this.state.main)}</span>
  2718. </FormItem>
  2719. <div className="clearfix">
  2720. <FormItem
  2721. labelCol={{ span: 3 }}
  2722. wrapperCol={{ span: 18 }}
  2723. label="服务说明"
  2724. >
  2725. <span>{this.state.taskComment}</span>
  2726. </FormItem>
  2727. </div>
  2728. </div>
  2729. </Spin>
  2730. </Form>
  2731. </Modal>
  2732. <Modal
  2733. maskClosable={false}
  2734. visible={this.state.speVisible}
  2735. onOk={this.visitOk}
  2736. onCancel={this.visitCancel}
  2737. width="900px"
  2738. title=""
  2739. footer=""
  2740. className="admin-desc-content"
  2741. >
  2742. <Tabs
  2743. activeKey={this.state.modKey}
  2744. onChange={this.callBack}
  2745. type="card"
  2746. >
  2747. <TabPane tab="项目概况" key="1">
  2748. <div className="clearfix">
  2749. <FormItem
  2750. className="half-item"
  2751. {...formItemLayout}
  2752. label="当前项目情况"
  2753. >
  2754. <Radio.Group
  2755. value={this.state.status}
  2756. onChange={e => {
  2757. this.setState({ status: e.target.value });
  2758. }}
  2759. >
  2760. <Radio value={0}>开启</Radio>
  2761. <Radio value={1}>暂停</Radio>
  2762. </Radio.Group>
  2763. <Button
  2764. type="primary"
  2765. size="small"
  2766. style={{ marginTop: "5px", position: "absolute" }}
  2767. onClick={this.caozuorizhi}
  2768. >
  2769. 操作日志
  2770. </Button>
  2771. </FormItem>
  2772. <FormItem
  2773. className="half-item"
  2774. {...formItemLayout}
  2775. label="合同编号"
  2776. >
  2777. <span>{this.state.contractNo}</span>
  2778. </FormItem>
  2779. </div>
  2780. <div className="clearfix">
  2781. <FormItem
  2782. className="half-item"
  2783. {...formItemLayout}
  2784. label="项目状态"
  2785. >
  2786. <Select
  2787. placeholder="选择项目状态"
  2788. style={{ width: "200px" }}
  2789. value={this.state.projectStatus}
  2790. onChange={e => {
  2791. this.setState({ projectStatus: e });
  2792. }}
  2793. >
  2794. {projectStatus.map(function(item) {
  2795. return (
  2796. <Select.Option key={item.value}>
  2797. {item.key}
  2798. </Select.Option>
  2799. );
  2800. })}
  2801. </Select>
  2802. </FormItem>
  2803. <FormItem
  2804. className="half-item"
  2805. {...formItemLayout}
  2806. label="是否特批"
  2807. >
  2808. <span>{getApproval(this.state.approval)}</span>
  2809. </FormItem>
  2810. <FormItem
  2811. className="half-item"
  2812. {...formItemLayout}
  2813. label="结算状态"
  2814. >
  2815. <span>
  2816. {getLiquidationStatus(this.state.liquidationStatus)}
  2817. </span>
  2818. </FormItem>
  2819. <FormItem
  2820. className="half-item"
  2821. {...formItemLayout}
  2822. label="流程状态"
  2823. >
  2824. <span>{getProcessStatus(this.state.processStatus)}</span>
  2825. </FormItem>
  2826. <FormItem
  2827. className="half-item"
  2828. {...formItemLayout}
  2829. label="订单编号"
  2830. >
  2831. <span>{this.state.orderNo}</span>
  2832. </FormItem>
  2833. </div>
  2834. <div className="clearfix">
  2835. <FormItem
  2836. className="half-item"
  2837. {...formItemLayout}
  2838. label="满意度表格"
  2839. >
  2840. <Radio.Group
  2841. value={this.state.formRetrieve}
  2842. onChange={e => {
  2843. this.setState({ formRetrieve: e.target.value });
  2844. }}
  2845. >
  2846. <Radio value={0}>未收回</Radio>
  2847. <Radio value={1}>已收回</Radio>
  2848. <Radio value={2}>其他</Radio>
  2849. </Radio.Group>
  2850. </FormItem>
  2851. <FormItem
  2852. className="half-item"
  2853. {...formItemLayout}
  2854. label="退单"
  2855. >
  2856. <Radio.Group
  2857. value={this.state.taskRefund}
  2858. onChange={e => {
  2859. this.setState({ taskRefund: e.target.value });
  2860. }}
  2861. >
  2862. <Radio value={0}>已完成</Radio>
  2863. <Radio value={1}>未完成</Radio>
  2864. <Radio value={2}>其他</Radio>
  2865. </Radio.Group>
  2866. </FormItem>
  2867. </div>
  2868. <div className="clearfix">
  2869. {
  2870. <FormItem
  2871. className="half-item"
  2872. {...formItemLayout}
  2873. label="(满意度)备注"
  2874. >
  2875. <Input
  2876. type="textarea"
  2877. placeholder="请输入备注"
  2878. rows={2}
  2879. value={this.state.retrieveContent}
  2880. onChange={e => {
  2881. this.setState({ retrieveContent: e.target.value });
  2882. }}
  2883. />
  2884. </FormItem>
  2885. }
  2886. {
  2887. <FormItem
  2888. className="half-item"
  2889. {...formItemLayout}
  2890. label="(退单)备注"
  2891. >
  2892. <Input
  2893. type="textarea"
  2894. placeholder="请输入备注"
  2895. rows={2}
  2896. value={this.state.refundContent}
  2897. onChange={e => {
  2898. this.setState({ refundContent: e.target.value });
  2899. }}
  2900. />
  2901. </FormItem>
  2902. }
  2903. </div>
  2904. <div className="clearfix">
  2905. <h3 className="sub-title">订单负责人信息</h3>
  2906. <FormItem
  2907. className="half-item"
  2908. {...formItemLayout}
  2909. label="负责人"
  2910. >
  2911. <span>
  2912. {this.state.salesmanName + "(" + this.state.depName + ")"}
  2913. </span>
  2914. </FormItem>
  2915. <FormItem
  2916. className="half-item"
  2917. {...formItemLayout}
  2918. label="负责人电话"
  2919. >
  2920. <span>{this.state.salesmanMobile}</span>
  2921. </FormItem>
  2922. <FormItem
  2923. className="half-item"
  2924. {...formItemLayout}
  2925. label="财务负责人"
  2926. >
  2927. <span>{this.state.financeName}</span>
  2928. </FormItem>
  2929. <FormItem
  2930. className="half-item"
  2931. {...formItemLayout}
  2932. label="财务负责人电话"
  2933. >
  2934. <span>{this.state.financeMobile}</span>
  2935. </FormItem>
  2936. </div>
  2937. {/*<hr style={{border:'1px dashed #aaa', width:"90%",margin:'auto'}}/>*/}
  2938. <div className="clearfix">
  2939. <h3 className="sub-title">联系信息</h3>
  2940. <FormItem
  2941. className="half-item"
  2942. {...formItemLayout}
  2943. label="客户名称"
  2944. >
  2945. <span>{this.state.userName}</span>
  2946. </FormItem>
  2947. <FormItem
  2948. className="half-item"
  2949. {...formItemLayout}
  2950. label="企业法人"
  2951. >
  2952. <Input
  2953. placeholder="请输入法人名称"
  2954. value={this.state.legalPerson}
  2955. style={{ width: "200px" }}
  2956. onChange={e => {
  2957. this.setState({ legalPerson: e.target.value });
  2958. }}
  2959. ref="commodityQuantity"
  2960. />
  2961. </FormItem>
  2962. <FormItem
  2963. className="half-item"
  2964. {...formItemLayout}
  2965. label="法人电话"
  2966. >
  2967. <Input
  2968. placeholder="请输入法人电话"
  2969. value={this.state.legalPersonTel}
  2970. style={{ width: "200px" }}
  2971. onChange={e => {
  2972. this.setState({ legalPersonTel: e.target.value });
  2973. }}
  2974. ref="commodityQuantity"
  2975. />
  2976. </FormItem>
  2977. <FormItem
  2978. className="half-item"
  2979. {...formItemLayout}
  2980. label="客户联系人"
  2981. >
  2982. <Input
  2983. placeholder="请输入联系人名称"
  2984. value={this.state.contacts}
  2985. style={{ width: "200px" }}
  2986. onChange={e => {
  2987. this.setState({ contacts: e.target.value });
  2988. }}
  2989. ref="commodityQuantity"
  2990. />
  2991. </FormItem>
  2992. <FormItem
  2993. className="half-item"
  2994. {...formItemLayout}
  2995. label="联系人电话"
  2996. >
  2997. <Input
  2998. placeholder="请输入联系人电话"
  2999. value={this.state.contactMobile}
  3000. style={{ width: "200px" }}
  3001. onChange={e => {
  3002. this.setState({ contactMobile: e.target.value });
  3003. }}
  3004. ref="commodityQuantity"
  3005. />
  3006. </FormItem>
  3007. <FormItem
  3008. className="half-item"
  3009. {...formItemLayout}
  3010. label="企业地址"
  3011. >
  3012. <Cascader
  3013. options={areaSelect()}
  3014. value={this.state.ProvinceCity}
  3015. placeholder="选择城市"
  3016. style={{ width: "200px" }}
  3017. onChange={e => {
  3018. this.setState({ ProvinceCity: e });
  3019. }}
  3020. />
  3021. </FormItem>
  3022. <FormItem
  3023. className="half-item"
  3024. {...formItemLayout}
  3025. label=""
  3026. ></FormItem>
  3027. <FormItem className="half-item" {...formItemLayout} label="">
  3028. <Input
  3029. placeholder="请输入详细地址"
  3030. value={this.state.postalAddress}
  3031. style={{ width: "200px", marginLeft: "12em" }}
  3032. onChange={e => {
  3033. this.setState({ postalAddress: e.target.value });
  3034. }}
  3035. ref="commodityQuantity"
  3036. />
  3037. </FormItem>
  3038. </div>
  3039. {/*<hr style={{border:'1px dashed #aaa', width:"90%",margin:'auto'}}/>*/}
  3040. <div className="clearfix">
  3041. <h3 className="sub-title">项目信息</h3>
  3042. <FormItem
  3043. className="half-item"
  3044. {...formItemLayout}
  3045. label="项目编号"
  3046. >
  3047. <span>{this.state.id}</span>
  3048. </FormItem>
  3049. <FormItem
  3050. className="half-item"
  3051. {...formItemLayout}
  3052. label="项目名称"
  3053. >
  3054. <span>{this.state.taskName}</span>
  3055. </FormItem>
  3056. <FormItem
  3057. className="half-item"
  3058. {...formItemLayout}
  3059. label="项目状态"
  3060. >
  3061. <Select
  3062. placeholder="选择项目状态"
  3063. style={{ width: "200px" }}
  3064. value={this.state.taskStatus}
  3065. onChange={e => {
  3066. this.setState({ taskStatus: e });
  3067. }}
  3068. >
  3069. {taskStatus.map(function(item) {
  3070. return (
  3071. <Select.Option key={item.value}>
  3072. {item.key}
  3073. </Select.Option>
  3074. );
  3075. })}
  3076. </Select>
  3077. </FormItem>
  3078. <FormItem
  3079. className="half-item"
  3080. {...formItemLayout}
  3081. label="项目类别"
  3082. >
  3083. <span>{this.state.cname}</span>
  3084. </FormItem>
  3085. <FormItem
  3086. className="half-item"
  3087. {...formItemLayout}
  3088. label="证书编号"
  3089. >
  3090. <Input
  3091. placeholder="请输入证书编号"
  3092. value={this.state.certificateNumber}
  3093. style={{ width: "200px" }}
  3094. onChange={e => {
  3095. this.setState({ certificateNumber: e.target.value });
  3096. }}
  3097. ref="commodityQuantity"
  3098. />
  3099. </FormItem>
  3100. </div>
  3101. <div className="clearfix" style={{ marginTop: "10px" }}>
  3102. <FormItem
  3103. labelCol={{ span: 3 }}
  3104. wrapperCol={{ span: 14 }}
  3105. label="附件"
  3106. >
  3107. <Picture
  3108. fileList={e => {
  3109. this.setState({ attachmentUrl: e });
  3110. }}
  3111. pictureUrl={this.state.attachmentUrl}
  3112. visible={this.props.visible}
  3113. data={{
  3114. sign: "order_task_file",
  3115. url: "/api/admin/orderProject/uploadOrderTaskFile",
  3116. number: 8
  3117. }}
  3118. />
  3119. </FormItem>
  3120. </div>
  3121. <div className="clearfix">
  3122. <FormItem
  3123. labelCol={{ span: 3 }}
  3124. wrapperCol={{ span: 16 }}
  3125. label="备注"
  3126. >
  3127. <Input
  3128. type="textarea"
  3129. placeholder="请输入备注"
  3130. rows={4}
  3131. value={this.state.taskComment}
  3132. onChange={e => {
  3133. this.setState({ taskComment: e.target.value });
  3134. }}
  3135. />
  3136. </FormItem>
  3137. </div>
  3138. <div className="clearfix">
  3139. <h3 className="sub-title">项目申报进度</h3>
  3140. <FormItem
  3141. className="half-item"
  3142. {...formItemLayout}
  3143. label="启动时间"
  3144. >
  3145. <DatePicker
  3146. style={{ marginTop: "5px" }}
  3147. showTime
  3148. format="YYYY-MM-DD"
  3149. onOk={() => {}}
  3150. value={
  3151. this.state.startDate ? moment(this.state.startDate) : null
  3152. }
  3153. onChange={(data, dataString) => {
  3154. this.setState({ startDate: dataString });
  3155. }}
  3156. />
  3157. </FormItem>
  3158. <FormItem
  3159. className="half-item"
  3160. {...formItemLayout}
  3161. label="软著派单数量"
  3162. >
  3163. <span>{this.state.commodityQuantity}</span>
  3164. <Button
  3165. type="primary"
  3166. size="small"
  3167. style={{ marginLeft: "45px" }}
  3168. onClick={this.addcontact}
  3169. >
  3170. +增加下证信息
  3171. </Button>
  3172. </FormItem>
  3173. <div className="patent-table">
  3174. <Spin spinning={this.state.loading}>
  3175. <Table
  3176. columns={this.state.ContactsLists}
  3177. dataSource={this.state.contactList}
  3178. pagination={false}
  3179. bordered
  3180. size="small"
  3181. />
  3182. </Spin>
  3183. </div>
  3184. </div>
  3185. <div className="clearfix">
  3186. <h3 className="sub-title">项目业务</h3>
  3187. <div className="patent-table">
  3188. <Spin spinning={this.state.loading}>
  3189. <Table
  3190. columns={this.state.columnsX}
  3191. dataSource={this.state.dataSourceX}
  3192. pagination={this.state.paginations}
  3193. onRowClick={this.tableRowClickX}
  3194. bordered
  3195. size="small"
  3196. />
  3197. </Spin>
  3198. </div>
  3199. </div>
  3200. <div className="clearfix">
  3201. <Button
  3202. className="cancel"
  3203. type="primary"
  3204. onClick={this.tijiaoOk}
  3205. style={{ marginLeft: "200px", marginTop: "10px" }}
  3206. htmlType="submit"
  3207. >
  3208. 保存
  3209. </Button>
  3210. <Button
  3211. className="cancel"
  3212. type="ghost"
  3213. onClick={this.visitCancel}
  3214. style={{ marginLeft: "50px", marginTop: "10px" }}
  3215. >
  3216. 取消
  3217. </Button>
  3218. </div>
  3219. </TabPane>
  3220. <TabPane tab="外包接单公司信息" key="2">
  3221. {/*<Button type="primary" onClick={this.addCompany} style={{float:'right',marginBottom:'10px'}}>+新增接单公司</Button>*/}
  3222. {
  3223. <div className="clearfix">
  3224. <h3 className="sub-title" style={{ marginBottom: "10px" }}>
  3225. 新增(编辑)接单公司
  3226. </h3>
  3227. <FormItem
  3228. className="three-item"
  3229. {...formItemLayout}
  3230. label={
  3231. <span>
  3232. <strong style={{ color: "#f00" }}>*</strong>公司名称
  3233. </span>
  3234. }
  3235. >
  3236. <Input
  3237. placeholder="请输入公司名称"
  3238. value={this.state.cName}
  3239. style={{ width: "200px" }}
  3240. onChange={e => {
  3241. this.setState({ cName: e.target.value });
  3242. }}
  3243. className="height-input"
  3244. />
  3245. </FormItem>
  3246. <FormItem
  3247. className="three-item"
  3248. {...formItemLayout}
  3249. label={
  3250. <span>
  3251. <strong style={{ color: "#f00" }}>*</strong>联系人
  3252. </span>
  3253. }
  3254. >
  3255. <Input
  3256. placeholder="请输入联系人名称"
  3257. value={this.state.companyContacts}
  3258. style={{ width: "200px" }}
  3259. onChange={e => {
  3260. this.setState({ companyContacts: e.target.value });
  3261. }}
  3262. className="height-input"
  3263. />
  3264. </FormItem>
  3265. <FormItem
  3266. className="three-item"
  3267. {...formItemLayout}
  3268. label={
  3269. <span>
  3270. <strong style={{ color: "#f00" }}>*</strong>联系人电话
  3271. </span>
  3272. }
  3273. >
  3274. <Input
  3275. placeholder="请输入联系人电话"
  3276. value={this.state.companyContactsMobile}
  3277. style={{ width: "200px" }}
  3278. onChange={e => {
  3279. this.setState({
  3280. companyContactsMobile: e.target.value
  3281. });
  3282. }}
  3283. className="height-input"
  3284. />
  3285. </FormItem>
  3286. <FormItem
  3287. className="three-item"
  3288. {...formItemLayout}
  3289. label="企业地址"
  3290. >
  3291. <Cascader
  3292. options={areaSelect()}
  3293. value={this.state.companyProvinceArr}
  3294. placeholder="选择城市"
  3295. style={{ width: "200px" }}
  3296. onChange={e => {
  3297. this.setState({ companyProvinceArr: e });
  3298. }}
  3299. />
  3300. </FormItem>
  3301. <FormItem className="three-item" {...formItemLayout} label="">
  3302. <Input
  3303. placeholder="请输入详细地址"
  3304. value={this.state.companyAddress}
  3305. style={{ width: "200px", marginLeft: "12em" }}
  3306. onChange={e => {
  3307. this.setState({ companyAddress: e.target.value });
  3308. }}
  3309. className="height-input"
  3310. />
  3311. </FormItem>
  3312. <FormItem
  3313. className="three-item"
  3314. {...formItemLayout}
  3315. label=""
  3316. ></FormItem>
  3317. <div className="clearfix">
  3318. <FormItem
  3319. labelCol={{ span: 3 }}
  3320. wrapperCol={{ span: 16 }}
  3321. label="备注"
  3322. >
  3323. <Input
  3324. type="textarea"
  3325. placeholder="请输入备注"
  3326. rows={4}
  3327. value={this.state.companyRemarks}
  3328. onChange={e => {
  3329. this.setState({ companyRemarks: e.target.value });
  3330. }}
  3331. />
  3332. </FormItem>
  3333. </div>
  3334. <Button
  3335. type="primary"
  3336. style={{
  3337. float: "right",
  3338. marginTop: "10px",
  3339. marginRight: "50px"
  3340. }}
  3341. onClick={() => {
  3342. this.saveCompany(this.state.companyId);
  3343. }}
  3344. >
  3345. 保存
  3346. </Button>
  3347. </div>
  3348. }
  3349. <p style={{ color: "red" }}>
  3350. 提示:查看备注请点击表格左侧加号按钮~
  3351. </p>
  3352. <div className="patent-table" style={{ marginTop: "10px" }}>
  3353. <Spin spinning={this.state.loading}>
  3354. <Table
  3355. columns={this.state.companyColumns}
  3356. dataSource={this.state.companys}
  3357. scroll={{ x: 300, y: 0 }}
  3358. expandedRowRender={record => {
  3359. return <p>{record.remarks}</p>;
  3360. }}
  3361. bordered
  3362. size="small"
  3363. pagination={false}
  3364. />
  3365. </Spin>
  3366. </div>
  3367. </TabPane>
  3368. </Tabs>
  3369. </Modal>
  3370. {/* <Modal
  3371. width="800px"
  3372. visible={this.state.visibleA}
  3373. onCancel={this.visitCancelA}
  3374. title="操作日志"
  3375. footer=""
  3376. className="admin-desc-content"
  3377. >
  3378. <div className="patent-table patent-table-center">
  3379. <Spin spinning={this.state.loading}>
  3380. <Table
  3381. columns={this.state.columnsA}
  3382. dataSource={this.state.dataSourceA}
  3383. pagination={false}
  3384. />
  3385. </Spin>
  3386. </div>
  3387. </Modal> */}
  3388. <OrderRiZi
  3389. dataSourcerizhi={this.state.dataSourceA}
  3390. closeOrderLog={this.visitCancelA}
  3391. visible={this.state.visibleA}
  3392. loading={this.state.loading}
  3393. />
  3394. <Modal
  3395. title="工时记录"
  3396. visible={this.state.timeVisible}
  3397. onCancel={this.timeClose}
  3398. width={800}
  3399. footer={null}
  3400. >
  3401. <Spin spinning={this.state.loading}>
  3402. <Table
  3403. columns={this.state.columnsTime}
  3404. dataSource={this.state.dataSourceTime}
  3405. pagination={false}
  3406. scroll={{ x: "max-content", y: 0 }}
  3407. bordered
  3408. size={"small"}
  3409. />
  3410. <p style={{ marginTop: 10, color: "red" }}>
  3411. 累计工时(小时):{this.state.recordHour}
  3412. </p>
  3413. </Spin>
  3414. </Modal>
  3415. </div>
  3416. );
  3417. }
  3418. });
  3419. export default MyTaskOutsource;