ITaskManager.java 154 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400440144024403440444054406440744084409441044114412441344144415441644174418441944204421442244234424442544264427442844294430443144324433443444354436443744384439444044414442444344444445444644474448444944504451445244534454445544564457445844594460446144624463446444654466446744684469447044714472447344744475447644774478447944804481448244834484448544864487448844894490449144924493449444954496449744984499450045014502450345044505450645074508450945104511451245134514451545164517451845194520452145224523452445254526452745284529453045314532453345344535453645374538453945404541454245434544454545464547454845494550455145524553455445554556455745584559456045614562456345644565456645674568456945704571457245734574457545764577457845794580458145824583458445854586458745884589459045914592459345944595459645974598459946004601460246034604460546064607460846094610461146124613461446154616461746184619462046214622462346244625462646274628462946304631463246334634463546364637463846394640464146424643464446454646464746484649465046514652465346544655465646574658465946604661466246634664466546664667466846694670467146724673467446754676467746784679468046814682468346844685468646874688468946904691469246934694469546964697
  1. /*
  2. * Copyright (c) 2014, 2023, Chengdu Minto Technology Co.,LTD. All rights reserved.
  3. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  4. */
  5. package com.minto.app.task.manager;
  6. import com.github.pagehelper.PageInfo;
  7. import com.minto.app.task.dto.TaskPanelOutput;
  8. import com.minto.app.task.dto.TaskSummaryDto;
  9. import com.minto.bff.home.dto.GenericParam;
  10. import com.minto.tap.task.dto.TaskSummaryInfo;
  11. import com.minto.tip.affair.po.TipAffair;
  12. import com.minto.app.behavior.beans.BehSummaryBean;
  13. import com.minto.app.dm.beans.MatrixTableColumnDefinition;
  14. import com.minto.app.message.beans.MessageTypeBean;
  15. import com.minto.app.organization.beans.OrgPersonBean;
  16. import com.minto.app.organization.beans.OrgUnitBean;
  17. import com.minto.app.resource.beans.CommonResourceRelationBean;
  18. import com.minto.app.task.beans.*;
  19. import com.minto.app.task.bo.*;
  20. import com.minto.app.task.dto.SaveDraftParam;
  21. import com.minto.app.task.dto.TaskInfo;
  22. import com.minto.app.task.enums.TaskEnum;
  23. import com.minto.app.task.enums.TaskEnum.TaskMemberRelTypeEnum;
  24. import com.minto.app.task.enums.TaskEnum.TaskSummaryProgressStatusEnum;
  25. import com.minto.app.task.enums.TaskPhaseStateEnum;
  26. import com.minto.app.task.vo.*;
  27. import com.minto.tip.affair.enums.AffairEnum;
  28. import com.minto.app.space.beans.SpaceFileBean;
  29. import com.minto.app.tipenum.po.TipEnumBean;
  30. import com.minto.core.base.ListObject;
  31. import com.minto.tip.common.exceptions.BusinessException;
  32. import org.hibernate.criterion.Criterion;
  33. import org.springframework.lang.NonNull;
  34. import java.sql.SQLException;
  35. import java.text.ParseException;
  36. import java.util.*;
  37. public interface ITaskManager {
  38. /**
  39. * 获取指定任务下的所有子孙任务,包含自身
  40. * @author inspired
  41. * @param superTaskId
  42. * @return
  43. */
  44. List<TaskSummaryBean> findAllTaskByParentId(Long superTaskId);
  45. /**
  46. * 根据任务名称查询对应资源id集合 (精准匹配 ,需要like)
  47. * @author inspired
  48. * @param titleStr 可以是多个 以(,|,)隔开
  49. * @return ids
  50. */
  51. List<Long> findTaskInfosByTitleStr(String titleStr);
  52. /**
  53. * 保存任务与矩阵数据的关联关系,关系不启用(启用了关系列表才能查到关联数据)
  54. * @author inspired
  55. * @param taskId
  56. * @param relTableId
  57. * @param relDataId
  58. * @throws BusinessException
  59. */
  60. void saveTaskMatrixDataRel(Long taskId, Long relTableId, Long relDataId) throws BusinessException;
  61. /**
  62. * 保存任务与关联数据的关联关系,关系不启用(启用了关系列表才能查到关联数据)
  63. * @author inspired
  64. * @param taskId
  65. * @throws BusinessException
  66. */
  67. void saveTaskLinkedData(Long taskId, SaveDraftParam param) throws BusinessException;
  68. /**
  69. * 启用任务与矩阵数据的关联关系(没有关联则会直接新建一条启用的数据关联)
  70. * @author inspired
  71. * @param taskId
  72. * @param relTableId
  73. * @param relDataId
  74. * @throws BusinessException
  75. */
  76. void applyTaskMatrixDataRel(Long taskId, Long relTableId, Long relDataId) throws BusinessException;
  77. /**
  78. * 启用任务与关联数据的关联关系(没有关联则会直接新建一条启用的数据关联)
  79. * @param taskId
  80. * @param param
  81. * @throws BusinessException
  82. */
  83. void applyTaskLinkedData(Long taskId, SaveDraftParam param) throws BusinessException;
  84. /**
  85. * 检查目标集组织对象在事项中是否有共享督办权限
  86. * @author inspired
  87. * @param taskId
  88. * @param targetIds
  89. * @return
  90. * @throws BusinessException
  91. */
  92. List<Long> findTaskSuperviseShare(Long taskId,List<Long> targetIds) throws BusinessException;
  93. Integer findTaskTypeMaxSort(Long accountId);
  94. /**
  95. * 更新事项状态和发消息
  96. * @param summaryBean
  97. * @param memberBeanList
  98. * @param updateMembers
  99. * @throws BusinessException
  100. */
  101. void updateStateAndSendMsg(TaskSummaryBean summaryBean, List<TaskMemberBean> memberBeanList, List<TaskMemberBean> updateMembers) throws BusinessException;
  102. /**
  103. * 处理子任务撤回
  104. * @author inspired
  105. * @param summaryBean
  106. * @param updateMembers
  107. * @param updateSummaries
  108. * @param updateSummaryIds
  109. * @param managerRel
  110. * @throws BusinessException
  111. */
  112. void processBackSubTasks(TaskSummaryBean summaryBean,List<TaskMemberBean> updateMembers, List<TaskSummaryBean> updateSummaries,List<Long> updateSummaryIds, List<Integer> managerRel) throws BusinessException;
  113. /**
  114. * @author inspired (胡启林)
  115. * @param
  116. * @describe 生成listColumn数据
  117. * @createTime 2021/6/23 17:53
  118. */
  119. ListColumnBean addColumn2ListColumn(MatrixTableColumnDefinition field, Integer type) throws BusinessException;
  120. /**
  121. * @author inspired (胡启林)
  122. * @param
  123. * @describe 分类获取批量催办成员
  124. * @createTime 2021/5/12 10:32
  125. */
  126. Map<String,Object> findAllUrgeByteType(Integer searchType) throws BusinessException;
  127. /**
  128. * @author inspired (胡启林)
  129. * @param
  130. * @describe 保存任务关联数据
  131. * @createTime 2021/4/30 10:26
  132. */
  133. void saveTaskFileRelation(Map<String,Object> param) throws BusinessException;
  134. /**
  135. * @author inspired (胡启林)
  136. * @param
  137. * @describe 外来任务列表
  138. * @createTime 2021/4/26 11:37
  139. */
  140. com.minto.tip.common.util.PageInfo findOutAccountTask(com.minto.tip.common.util.PageInfo info,Map<String,Object> param) throws BusinessException;
  141. /**
  142. * @author inspired (胡启林)
  143. * @param
  144. * @describe 获取单位顶级事项类型
  145. * @createTime 2021/4/13 9:48
  146. */
  147. TaskTypeBean findRootTypeByAccountId(Long accountId);
  148. /**
  149. * @author inspired (胡启林)
  150. * @param
  151. * @describe 修改任务阶段
  152. * @createTime 2021/4/6 17:10
  153. */
  154. Boolean updatePhaseByTaskId(Long taskId, Map<String,Object> param) throws BusinessException, SQLException, ParseException;
  155. /**
  156. * 根据任务获取某个汇报阶段的成员配置信息
  157. */
  158. List<TaskMemberPhaseReportConfig> findTaskMPRCByMemberIdsAndReportConfigId(Long taskId,List<Long> memberIds,Long reportConfigId);
  159. /**
  160. * @author inspired (胡启林)
  161. * @param taskMemberPhaseReportConfig
  162. * @describe 组装成员汇报灯
  163. * @createTime 2021/3/31 9:43
  164. */
  165. TaskPhaseStateEnum processTaskMemberPhaseReportConfig(TaskMemberPhaseReportConfig taskMemberPhaseReportConfig,TaskMemberBean memberBean) throws BusinessException;
  166. /**
  167. * @author inspired (胡启林)
  168. * @param tasks 任务
  169. * @param subType {@link AffairEnum.SubTypeEnum}
  170. * @param pid
  171. * @describe 生成事项待办
  172. * @createTime 2021/3/12 15:21
  173. */
  174. Integer saveTaskAffair(List<TaskSummaryBean> tasks, Long pid) throws BusinessException;
  175. /**
  176. * 根据任务基本数据结构添加待办数据(新建时使用)
  177. * @author inspired
  178. * @param taskInfo {@link TaskInfo}
  179. * @return
  180. * @throws BusinessException
  181. */
  182. void addTaskAffair(TaskInfo taskInfo) throws BusinessException;
  183. /**
  184. * 获取当前阶段
  185. * @author inspired
  186. * @param
  187. * @return
  188. */
  189. TaskPhase processCurrentTaskPhase(List<TaskPhase> taskPhases);
  190. /**
  191. * 根据大阶段里的汇报阶段获取当前汇报阶段;阶段里需要包含小阶段数据
  192. * @author inspired
  193. * @param
  194. * @return
  195. */
  196. TaskPhaseReportConfig processCurrentReportConfig(TaskPhase taskPhase);
  197. /**
  198. * @author inspired (胡启林)
  199. * @param
  200. * @describe 获取我督办的未完成的事项
  201. * @createTime 2021/3/10 15:30
  202. */
  203. com.minto.tip.common.util.PageInfo findPageMySuperviseTasks(com.minto.tip.common.util.PageInfo info, Map<String,Object> param) throws BusinessException;
  204. /**
  205. * 获取不同状态任务数量任务
  206. * @param param
  207. * @return
  208. */
  209. List<Map<String, Object>> findTaskCount(Map<String, Object> param) throws BusinessException;
  210. /**
  211. * @author inspired (胡启林)
  212. * @param
  213. * @describe 督办首页任务管理数据统计
  214. * @createTime 2021/3/19 9:16
  215. */
  216. Map<String,Object> countAllTaskByTaskState(Map<String,Object> param) throws BusinessException;
  217. /**
  218. * 撤销汇总操作
  219. * @author inspired
  220. * @param taskId
  221. * @param reportId
  222. * @throws BusinessException
  223. */
  224. void processCollectReport(Long taskId,Long reportId) throws BusinessException;
  225. /**
  226. * 新首页任务管理统计
  227. * @param param
  228. * @return
  229. * @throws BusinessException
  230. */
  231. Map<String, Object> countAllTaskByTaskStateNew(Map<String, Object> param) throws BusinessException;
  232. List<Integer> getTaskBehTypes();
  233. /**
  234. * @author inspired (胡启林)
  235. * @param
  236. * @describe 督办事项统计
  237. * @createTime 2020/12/15 18:38
  238. */
  239. Map<String,Integer> countTaskByParam(Map<String,Object> param) throws BusinessException;
  240. com.minto.tip.common.util.PageInfo findAllTaskByParam(com.minto.tip.common.util.PageInfo info, Map<String,Object> param) throws BusinessException;
  241. /**
  242. * @author inspired (胡启林)
  243. * @param
  244. * @describe 督办首页饼图穿透数据列表
  245. * @createTime 2021/4/21 19:41
  246. */
  247. com.minto.tip.common.util.PageInfo findSupervisionTaskByParam(com.minto.tip.common.util.PageInfo info, Map<String,Object> param) throws BusinessException;
  248. /**
  249. * @author inspired (胡启林)
  250. * @param
  251. * @describe 查询分管的事项
  252. * @createTime 2020/12/15 10:07
  253. */
  254. com.minto.tip.common.util.PageInfo findPageInChargeByParam(com.minto.tip.common.util.PageInfo info, Map<String,Object> params);
  255. /**
  256. * 承办工作任务
  257. * @author inspired
  258. * @param info
  259. * @param param
  260. * @return
  261. */
  262. com.minto.tip.common.util.PageInfo<TaskSummaryDto> findManagerTask4Param(com.minto.tip.common.util.PageInfo info, Map param) throws BusinessException;
  263. /**
  264. * 自定义查询承办事项
  265. * @author inspired
  266. * @param param {"title":"","relationType":[],"tstate":[],"mstate":[],"accountId":"","year":2023,"taskTypeIds":[],"resourceIds":[]}
  267. * @return
  268. */
  269. com.minto.tip.common.util.PageInfo<TaskSummaryInfo> findTask4Param(com.minto.tip.common.util.PageInfo info, Map param);
  270. /**
  271. * 根据状态获取任务数量
  272. * @param params
  273. * @return
  274. */
  275. Map<String, Integer> findTaskCountByState(Map<String, Object> params);
  276. Integer countInChargeByParam(Map<String,Object> params) throws BusinessException;
  277. /**
  278. * @author inspired (胡启林)
  279. * @param
  280. * @describe 分页查询事项关注数据 领导关注跟我的关注
  281. * @describe type : 1 我的关注 ; 2 领导关注
  282. * @createTime 2020/12/11 11:29
  283. */
  284. com.minto.tip.common.util.PageInfo findPageFollowsByParams(com.minto.tip.common.util.PageInfo info,Map<String,Object> params);
  285. Integer findCountFollowsByParams(Map<String,Object> params);
  286. /**
  287. * @author inspired (胡启林)
  288. * @param taskTemplateId 模板名称
  289. * @param extend 自定义数据
  290. * @describe 根据任务模板id发布新的任务
  291. * @createTime 2020/10/16 15:52
  292. */
  293. Long saveTaskForTaskTemplateId(Long taskTemplateId,Map<String,Object> extend);
  294. /**
  295. * 修改模板基本信息(节点任务使用)
  296. * @author inspired
  297. * @param param
  298. * @return 模板id
  299. * @throws BusinessException
  300. */
  301. Map<String,Object> updateTaskTemplateInfo(Map<String,Object> param) throws BusinessException, ParseException, ReflectiveOperationException;
  302. Map<String,Object> saveTaskTemplateInfo(Map<String,Object> param) throws BusinessException, ParseException, ReflectiveOperationException;
  303. /**
  304. * @author inspired (胡启林)
  305. * @param templateIds
  306. * @describe 根据模板id查找下发的任务
  307. * @createTime 2020/11/30 11:19
  308. */
  309. Boolean findUseFlagByTemplateIds(List<Long> templateIds);
  310. /**查询牵头单位及责任单位的完成时限扩展字段*/
  311. Map<String,Object> findExtendDataByTaskId(Long taskId, String param) throws BusinessException;
  312. Boolean checkBasicExtendValueByTaskIdAndField() throws BusinessException;
  313. /**批量修改完成时限*/
  314. Integer updateEndDataByTaskIds(List<Map<String, Object>> params,Boolean editEndDate) throws BusinessException;
  315. /**
  316. * 修改单位
  317. */
  318. Integer updateTaskDataByParam(List<Map<String, Object>> params) throws BusinessException;
  319. /**
  320. * @author inspired (胡启林)
  321. * @param taskIds
  322. * @param status {@link TaskSummaryProgressStatusEnum}
  323. * @describe 修改任务进度状态
  324. * @createTime 2020/11/18 20:04
  325. */
  326. Integer updateTaskProcessStatus(List<Long> taskIds,Integer status);
  327. /**
  328. * 添加成员至指定任务,通用方法
  329. * @param taskId
  330. * @param resourceType
  331. * @param resourceId
  332. * @param relationType
  333. * @param taskTypeBean
  334. * @return
  335. */
  336. Long addTaskMemberInfo(Long taskId, Integer resourceType, Long resourceId, Integer relationType, TaskTypeBean taskTypeBean, String node);
  337. /**
  338. * @author inspired (胡启林)
  339. * @param
  340. * @describe 重大项目挂图督办处理地图数据
  341. * @createTime 2019/10/9 10:04
  342. */
  343. List<Map<String,Object>> processMapData(List<Map<String, Object>> summaryList) throws BusinessException;
  344. /**
  345. * 返回经纬度数组
  346. */
  347. Double[] getAllAddrIpsByTaskId(Long taskId) throws BusinessException;
  348. public List<TaskProcessBO> findSubProcessBos(Long parentId, Long parentType) throws BusinessException;
  349. public void releaseTask(String ids) throws BusinessException;
  350. /**
  351. * 查询截止到当前时间时间进度刚好到一半的任务(时间差不得超过一分钟)
  352. * @return
  353. * @throws BusinessException
  354. */
  355. public List<TaskBO> findTaskByHalfTImeProcess() throws BusinessException;
  356. /**
  357. * 根据事项状态和事项关联类型查询即将到期的事项数量
  358. */
  359. public Integer findTaskByHalfTImeProcessByCount(Long cid, Long pid, Integer[] states, Integer[] memberRelations) throws BusinessException;
  360. public List<TaskSummaryBean> findTaskByHalfTImeProcessByCountList(Long cid, Long pid, Integer[] states, Integer[] memberRelations) throws BusinessException;
  361. public List<TaskSummaryBean> findTaskByHalfTImeProcessByList(Long cid, Long pid, Long cuurentPid, Integer[] states, Integer[] memberRelations) throws BusinessException;
  362. /**
  363. * 查询截止到指定时间的到期任务
  364. * @param endDate
  365. * @return
  366. * @throws BusinessException
  367. * @throws BusinessException
  368. */
  369. public List<TaskSummaryBean> findExpireTaskSummary(Date endDate, Map<String, Object> params) throws BusinessException;
  370. /**
  371. * 查询某时间段到期任务
  372. * @param beginDate
  373. * @param endDate
  374. * @return
  375. * @throws BusinessException
  376. */
  377. public List<TaskSummaryBean> findExpireTaskSummary(Date beginDate, Date endDate, Map<String, Object> params) throws BusinessException;
  378. /**
  379. * 添加任务
  380. * @param taskBO 任务bo对象
  381. * @throws BusinessException
  382. */
  383. public List<TaskMemberBean> addTask(TaskBO taskBO) throws BusinessException;
  384. public List<OrgUnitBean> findAllDepByType(Integer type) throws BusinessException;
  385. /**
  386. * 添加任务关联
  387. * @param tid 任务id
  388. * @param perIds 人员id 必须和type的个数位置相同
  389. * @param type 关联类型 参见枚举{@link TaskMemberRelTypeEnum} 必须和perIds的个数位置相同
  390. * @param pid 当前人员id
  391. * @return
  392. * @throws BusinessException
  393. */
  394. public List<TaskMemberBean> addTaskMember(Long cid, Long tid, String[] perIds, Integer[] type, Long pid, String errorSaveDeptFlag) throws BusinessException;
  395. /**
  396. * 添加任务的动态信息
  397. * @param processBO 任务处理信息
  398. * @param isHide 是否隐藏
  399. * @throws BusinessException
  400. */
  401. public void addTaskProcess(TaskProcessBO processBO, Boolean isHide) throws BusinessException;
  402. /**
  403. * 添加任务汇报
  404. * @param reportSummaries
  405. * @throws SQLException
  406. */
  407. public void addTaskReportSummarys(TaskReportBO reportBO) throws BusinessException;
  408. /**
  409. * 更新任务公告
  410. * @param taskId
  411. * @param notice
  412. * @param personId
  413. * @throws BusinessException
  414. */
  415. public void addTaskNotice(Long taskId, String notice, Long personId) throws BusinessException;
  416. /**
  417. * 更新红旗标记
  418. * @param taskIds 任务id
  419. * @param personId 人员id
  420. * @param redFlag 标记
  421. * @throws BusinessException
  422. */
  423. public void updateRedFlagByTaskIdAndPersonId(Long taskId, Long personId, Integer redFlag) throws BusinessException;
  424. /**
  425. * 根据任务id修改状态为
  426. * @param ids 任务id
  427. * @param state 任务状态 TaskSummaryStateEnum
  428. * @param pid
  429. * @param isSys 是否是系统动作
  430. * @throws BusinessException
  431. */
  432. public void updateTaskSummaryStateById(Long id, Integer state, Long pid, Boolean isSys) throws BusinessException;
  433. /**
  434. * 根据任务id修改状态为
  435. * @param ids 任务ids
  436. * @param state 任务状态 TaskSummaryStateEnum
  437. * @param pid
  438. * @param isSys 是否是系统动作
  439. * @throws BusinessException
  440. */
  441. public void updateTaskSummaryStateById(Long[] ids, Integer state, Long pid, Boolean isSys) throws BusinessException;
  442. /**
  443. * 更新任务成员信息
  444. * @param taskMemberBeans
  445. * @throws SQLException
  446. */
  447. public void updateTaskMemberReadDate(Long meberId, Date date) throws BusinessException;
  448. /**
  449. * 更新任务成员阅读时间
  450. * @param meberId
  451. * @throws BusinessException
  452. */
  453. public void updateTaskMemberReadDate(Long[] meberId) throws BusinessException;
  454. /**
  455. * 更新任务成员信息
  456. * @param memberBeans
  457. * @throws BusinessException
  458. */
  459. public void updateTaskMember(List<TaskMemberBean> memberBeans) throws BusinessException;
  460. /**
  461. * 根据id查找任务基本信息 查找任务
  462. * @param id 任务id
  463. * @return 成功返回任务基本信息,否则null
  464. * @throws BusinessException
  465. */
  466. public TaskSummaryBean findTaskSummaryBeanById(Long id) throws BusinessException;
  467. /**
  468. * 获取任务类型超时事项
  469. * @param taskTypes 任务类型id
  470. * @throws BusinessException
  471. */
  472. List<TaskSummaryBean> findOverdueTaskByTaskType(List<Long> taskTypes) throws BusinessException, SQLException;
  473. /**
  474. * 检查当前人在当前事项中状态,进行汇报验证,如果事项已经办结,则无法汇报,如果成员被办结,则事项无法再次汇报
  475. * @param id
  476. * @return
  477. * @throws BusinessException
  478. */
  479. Map<String,Object> checkTaskAndMemberStatus(Long id)throws BusinessException;
  480. /**
  481. * 任务id查询TaskBO
  482. * @param id 任务id
  483. * @return 成功返回任务信息,否则null
  484. * @throws BusinessException
  485. *
  486. */
  487. public TaskBO findTaskBOById(Long id) throws BusinessException;
  488. /**
  489. * 根据父id查询子任务
  490. * @param parentId
  491. * @return
  492. * @throws BusinessException
  493. */
  494. public List<TaskBO> findTaskBOByParentId(Long parentId) throws BusinessException;
  495. /**
  496. * 根据各种复合条件查询任务动态 查询条件和{@link #findTaskProcess(String, String, String, Integer, Integer, String, String, Long, Long, Long, Integer, Integer) 一样}
  497. * @param doType
  498. * @param keyword
  499. * @param keywordShow
  500. * @param roleType
  501. * @param actionType
  502. * @param dateFrom
  503. * @param dateTo
  504. * @param cid
  505. * @param taskId
  506. * @param personId
  507. * @return
  508. * @throws BusinessException
  509. */
  510. Integer countTaskProcess(String doType, String keyword, String keywordShow, Integer roleType, Integer actionType, String dateFrom, String dateTo, Long cid, Long taskId, Long personId) throws BusinessException;
  511. /**
  512. * 根据各种复合条件查询任务动态
  513. * @param doType 查询表示
  514. * @param keyword 人员id(key_id)
  515. * @param keywordShow 标题
  516. * @param roleType 角色,参见枚举TaskMemberRelTypeEnum
  517. * @param actionType 查询动态的分类,参见枚举BehSummaryBehTypeEnum
  518. * @param dateFrom 开始时间
  519. * @param dateTo 结束时间
  520. * @param cid 单位id
  521. * @param taskId 任务id
  522. * @param personId 人员id
  523. * @param start 开始页码
  524. * @param range 页大小
  525. * @return
  526. * @throws BusinessException
  527. */
  528. public ListObject<Object> findTaskProcess(String doType, String keyword, String keywordShow, Integer roleType, Integer actionType, String dateFrom, String dateTo, Long cid, Long taskId,
  529. Long personId, Integer start, Integer range) throws BusinessException;
  530. /**
  531. * 查询任务列表
  532. * @param redFlag 红旗标识,参见枚举TaskMemberRedFlag 全部(-1),只选红旗(TaskEnum.TaskMemberRedFlag.RedFlag)
  533. * @param doType 查询方式 标题(title),状态(state),时间范围(endDate),责任人(manager,暂未使用)
  534. * @param keyword 责任人的id 暂未使用
  535. * @param keywordShow 任务标题
  536. * @param dateFrom 开始时间
  537. * @param dateTo 结束时间
  538. * @param personId 当前人员id
  539. * @param memberRelTypes 任务member关联状态,参见TaskMemberBean的relationType字段,及TaskMemberRelTypeEnum枚举 全部(责任,关注,参与),责任,关注,参与
  540. * @param states 任务summary的状态,参见TaskSummaryBean的tstate字段,及TaskSummaryStateEnum枚举
  541. * @param tCategory 任务summary的类型,参见TaskSummaryBean的tcategory字段,及TaskSummaryTcategoryEnum枚举
  542. * @param cid 单位id
  543. * @param start 开始页码
  544. * @param pageSize 结束页码
  545. * @return 任务列表
  546. * @throws BusinessException
  547. */
  548. public ListObject<TaskBO> findTaskBos(Integer redFlag, String doType, String keyword, String keywordShow, String dateFrom, String dateTo, Long personId, Integer[] memberRelTypes,
  549. Integer[] states, Integer tCategory, Long cid, Integer start, Integer pageSize) throws BusinessException;
  550. /**
  551. * 查询任务列表
  552. * @param redFlag 红旗标识,参见枚举TaskMemberRedFlag 全部(-1),只选红旗(TaskEnum.TaskMemberRedFlag.RedFlag)
  553. * @param doType 查询方式 标题(title),状态(state),时间范围(endDate),责任人(manager,暂未使用)
  554. * @param keyword 责任人的id 暂未使用
  555. * @param keywordShow 任务标题
  556. * @param dateFrom 开始时间
  557. * @param dateTo 结束时间
  558. * @param personId 当前人员id
  559. * @param memberRelTypes 任务member关联状态,参见TaskMemberBean的relationType字段,及TaskMemberRelTypeEnum枚举 全部(责任,关注,参与),责任,关注,参与
  560. * @param states 任务summary的状态,参见TaskSummaryBean的tstate字段,及TaskSummaryStateEnum枚举
  561. * @param tCategory 任务summary的类型,参见TaskSummaryBean的tcategory字段,及TaskSummaryTcategoryEnum枚举
  562. * @param cid 单位id
  563. * @param currentPid 当前人员的id
  564. * @param pid 某人的id
  565. * @param start 开始页码
  566. * @param pageSize 结束页码
  567. * @return 任务列表
  568. * @throws BusinessException
  569. */
  570. public ListObject<TaskBO> findTaskBos(Integer redFlag, String doType, String keyword, String keywordShow, String dateFrom, String dateTo, Long curentPid, Integer[] memberRelTypes,
  571. Integer[] states, Integer tCategory, Long cid, Long pid, Integer start, Integer pageSize) throws BusinessException;
  572. /**
  573. * 查询任务列表
  574. * @param redFlag 红旗标识,参见枚举TaskMemberRedFlag 全部(-1),只选红旗(TaskEnum.TaskMemberRedFlag.RedFlag)
  575. * @param doType 查询方式 标题(title),状态(state),时间范围(endDate),责任人(manager,暂未使用)
  576. * @param keyword 责任人的id 暂未使用
  577. * @param keywordShow 任务标题
  578. * @param dateFrom 开始时间
  579. * @param dateTo 结束时间
  580. * @param personId 当前人员id
  581. * @param memberRelTypes 任务member关联状态,参见TaskMemberBean的relationType字段,及TaskMemberRelTypeEnum枚举 全部(责任,关注,参与),责任,关注,参与
  582. * @param states 任务summary的状态,参见TaskSummaryBean的tstate字段,及TaskSummaryStateEnum枚举
  583. * @param tCategory 任务summary的类型,参见TaskSummaryBean的tcategory字段,及TaskSummaryTcategoryEnum枚举
  584. * @param cid 单位id
  585. * @param currentPid 当前人员的id
  586. * @param pid 某人的id
  587. * @param findState状态
  588. * @param start 开始页码
  589. * @param pageSize 结束页码
  590. * @return 任务列表
  591. * @throws BusinessException
  592. */
  593. public ListObject<TaskBO> findTaskBos(Integer redFlag, String doType, String keyword, String keywordShow, String dateFrom, String dateTo, Long curentPid, Integer[] memberRelTypes,
  594. Integer[] states, Integer tCategory, Long cid, Long pid, Integer findState, Integer start, Integer pageSize) throws BusinessException;
  595. public List<TaskSummaryBean> findTaskListByIds(Long[] ids) throws BusinessException;
  596. /**
  597. * 任务id查询TaskBO
  598. * @param ids 任务id
  599. * @return 成功返回任务信息,否则null
  600. * @throws BusinessException
  601. */
  602. public List<TaskBO> findTaskBOByIds(Long[] ids) throws BusinessException;
  603. /**
  604. * @param ids
  605. * @return
  606. * @throws BusinessException
  607. */
  608. public List<TaskBO> findTaskBOByIdsWithoutOrder(Long[] ids) throws BusinessException;
  609. /**
  610. * 根据任务id查询任务汇报
  611. * @param taskIds
  612. * @param start
  613. * @param range
  614. * @return
  615. * @throws SQLException
  616. */
  617. public ListObject<TaskReportBO> findTaskReportSummaryByTaskId(Long taskId, Integer start, Integer range) throws BusinessException;
  618. /**
  619. * @param taskId
  620. * @return
  621. * @throws BusinessException
  622. */
  623. public List<TaskReportBO> findTaskReportBOByTaskId(Long taskId) throws BusinessException;
  624. /**
  625. * 任务id查询任务关联人员信息
  626. * @param taskIds 任务ID
  627. * @return 成功返回任务信息,否则null
  628. * @throws BusinessException
  629. */
  630. public List<TaskMemberBean> findTaskMembersByTaskId(Long taskId) throws BusinessException;
  631. /**
  632. * 任务id查询任务关联人员信息
  633. * @param taskId 任务ID
  634. * @param includeDeleted 是否包含已删除的成员
  635. * @return 成功返回任务成员信息,否则null
  636. * @throws BusinessException
  637. */
  638. public List<TaskMemberBean> findTaskMembersByTaskId(Long taskId, boolean includeDeleted) throws BusinessException;
  639. /**包含已删除的成员*/
  640. public List<TaskMemberBean> findAllTaskMembersByTaskId(Long taskId) throws BusinessException;
  641. /**
  642. * 任务taskId查询相关批示
  643. * @param taskId 任务ID
  644. * @return 成功返回批示,否则null
  645. * @throws BusinessException
  646. */
  647. public TaskProcessSummaryBean findTaskProcessBeansByTaskId(Long id) throws BusinessException;
  648. /**
  649. * @param taskId
  650. * @param memberType
  651. * @return
  652. * @throws BusinessException
  653. */
  654. public List<TaskMemberBean> findTaskMembersByTaskIdAndType(Long taskId, Integer memberType) throws BusinessException;
  655. public List<TaskMemberBean> findTaskMembersByTaskIdAndType(Long taskId, Integer[] memberType) throws BusinessException;
  656. public List<TaskMemberBean> findTaskMembersByTaskIdAndType(Long[] taskId, Integer[] memberType) throws BusinessException;
  657. public Map<String,Object> findIsErrorMemberByTaskIdAndType(String taskIds, Integer memberType) throws BusinessException;
  658. /**
  659. * 查找下级任务列表
  660. * @param taskId 任务ID
  661. * @throws BusinessException
  662. */
  663. public List<TaskBO> findTasksOfNextLevel(Long taskId) throws BusinessException;
  664. /**
  665. * 根据标题查找任务
  666. * @param cid 单位id
  667. * @param personId 人员id
  668. * @param memberRelTypes 任务人员关联类型
  669. * @param title 标题
  670. * @param start 分页起始位置,最小值>=0
  671. * @param range 分页范围参数
  672. * @return 返回查询到的任务信息列表对象,否则返回空列表对象:count=0,list.size()=0
  673. * @throws BusinessException
  674. */
  675. public ListObject<TaskBO> findTaskBOsByMemberAndTitle(Long cid, Long personId, Integer[] memberRelTypes, String title, Integer start, Integer range) throws BusinessException;
  676. /**
  677. * 根据多个人员查询多个单位的任务
  678. * @param cid 单位id
  679. * @param personId 人员id
  680. * @param memberRelTypes 任务人员关联类型
  681. * @param title 标题
  682. * @param category TODO
  683. * @param start 分页起始位置,最小值>=0
  684. * @param range 分页范围参数
  685. * @return 返回查询到的任务信息列表对象,否则返回空列表对象:count=0,list.size()=0
  686. * @throws BusinessException
  687. */
  688. public ListObject<TaskBO> findTaskBOsByMemberAndTitle(Long[] cid, Long[] personId, Integer[] memberRelTypes, String title, Integer category, Integer start, Integer range) throws BusinessException;
  689. /**
  690. * 根据多个人员查询多个单位的任务
  691. * @param cid 单位id
  692. * @param personId 人员id
  693. * @param memberRelTypes 任务人员关联类型
  694. * @param title 标题
  695. * @param category TODO
  696. * @param start 分页起始位置,最小值>=0
  697. * @param range 分页范围参数
  698. * @return 返回查询到的任务信息列表对象,否则返回空列表对象:count=0,list.size()=0
  699. * @throws BusinessException
  700. */
  701. public ListObject<TaskBO> findTaskBOsByMemberAndTitle(Long[] cid, Long[] personId, Integer[] memberRelTypes, String title, Integer category, Integer taskState, Integer start, Integer range)
  702. throws BusinessException;
  703. /**
  704. *
  705. * 根据多个人员查询多个单位的任务
  706. * @param cid 单位id
  707. * @param personId 人员id
  708. * @param memberRelTypes 任务人员关联类型
  709. * @param title 标题
  710. * @param category TODO
  711. * @param ids 事项id
  712. * @param start 分页起始位置,最小值>=0
  713. * @param range 分页范围参数
  714. * @return
  715. * @throws BusinessException
  716. */
  717. public ListObject<TaskBO> findTaskBOsByMemberAndTitle(Long[] cid, Long[] personId, Integer[] memberRelTypes, String title, Integer category, Integer taskState, Long[] ids, Integer start,
  718. Integer range) throws BusinessException;
  719. public ListObject<TaskBO> findTaskBOs(Long[] cid, Long[] personId, Integer[] memberRelTypes, String title, Integer category, Integer taskState, Long[] ids, Integer[] state, Long taskTypeId, Integer start, Integer range, String year, String sortFinishDate)throws BusinessException ;
  720. /**
  721. * 修改任务的正文
  722. * @param taskId 任务的id
  723. * @param contentId 正文的id
  724. * @throws BusinessException
  725. */
  726. public void updateContent(Long taskId, Long contentId) throws BusinessException;
  727. /**
  728. * 添加任务的附言
  729. * @param taskPostscriptBO
  730. * @throws BusinessException
  731. */
  732. public void addTaskPostscriptBo(TaskPostscriptBO taskPostscriptBO) throws BusinessException;
  733. /**
  734. * 根据单位id,时间查询所有任务
  735. * @param orgId
  736. * @param startDate
  737. * @param endDate
  738. * @return
  739. * @throws BusinessException
  740. */
  741. public int findTaskBOsByOrgIdAndDate(Long orgId, Date startDate, Date endDate) throws BusinessException;
  742. /**
  743. * 根据id查询任务动态
  744. * @return List
  745. * @throws BusinessException
  746. */
  747. public List<TaskProcessSummaryBean> findTaskProcessByIds(Long[] ids) throws BusinessException;
  748. /**
  749. * 根据processResourceId 查询
  750. * @param taskId
  751. * @param processResourceId
  752. * @return
  753. * @throws BusinessException
  754. */
  755. List<TaskProcessSummaryBean> findTaskProcessByProResourceId(Long taskId , Long processResourceId)throws BusinessException;
  756. /**
  757. * 根据任务查询动态信息
  758. * @param taskId 任务id
  759. * @param cid 单位id
  760. * @param start 页码
  761. * @param pageSize 页大小
  762. * @return ListObject
  763. * @throws BusinessException
  764. */
  765. public ListObject<TaskProcessSummaryBean> findTaskProcessBeansByTaskId(Long taskId, Integer start, Integer pageSize) throws BusinessException;
  766. /**
  767. * 根据父id查询回复的留言
  768. * @param parentIds
  769. * @return
  770. * @throws BusinessException
  771. */
  772. public List<TaskProcessSummaryBean> findTaskProcessByparentIds(Long[] parentIds) throws BusinessException;
  773. /**
  774. * 根据最后一次访问时间查询最新动态的条数
  775. * @param taskId 任务id
  776. * @param lastDate 最后一次访问时间,参看TaskMember
  777. * @return
  778. * @throws BusinessException
  779. */
  780. public Integer findTaskProcessNewestCount(Long taskId, Date lastDate) throws BusinessException;
  781. /**
  782. * 根据任务id和汇报id查询汇报信息
  783. * @param taskId
  784. * @param reportId
  785. * @return
  786. * @throws BusinessException
  787. */
  788. public TaskReportBO findTaskReportBOByTaskIdAndReportId(Long taskId, Long reportId) throws BusinessException;
  789. /**
  790. *
  791. * @param personId
  792. * @param roles
  793. * @param title
  794. * @param important
  795. * @param ucgency
  796. * @param onlyFlag
  797. * @return
  798. * @throws BusinessException
  799. */
  800. public List<Long> findTaskIdsByCri(Long cid, Long personId, Integer[] roles, String title, Integer important, Integer ucgency, Boolean onlyFlag, Integer tCategory, Integer[] taskStates, Long[] ids)
  801. throws BusinessException;
  802. /**
  803. * 查找正在进行中的红旗任务
  804. * @param personId
  805. * @param cid
  806. * @param ids
  807. * @return
  808. * @throws BusinessException
  809. */
  810. public List<TaskBO> findRedFlagTaskOfRecent(Long cid, Long personId, List<Long> ids) throws BusinessException;
  811. /**
  812. * 批量添加留言关系表
  813. * @param relationBeans
  814. * @throws BusinessException
  815. */
  816. public void addTaskProcessRelation(List<TaskProcessRelationBean> relationBeans) throws BusinessException;
  817. /**
  818. * 根据任务id和留言id查询留言关系
  819. * @param taskId
  820. * @param processId
  821. * @return
  822. * @throws BusinessException
  823. */
  824. public List<TaskProcessRelationBean> findTaskProcessRelationByProcessIdAndTaskId(Long taskId, Long processId) throws BusinessException;
  825. /**
  826. * 删除任务下面指定人员的关联信息
  827. * @param beans
  828. * @throws BusinessException
  829. */
  830. public void deleteTaskMemberByTaskIdAndPersonIds(List<TaskMemberBean> beans) throws BusinessException;
  831. public void deleteTaskMembers(List<TaskMemberBean> beans) throws BusinessException;
  832. /**
  833. * 添加和删除指定的关联
  834. * @param cid
  835. * @param tid
  836. * @param addPersons
  837. * @param types
  838. * @param pid
  839. * @param deletePerson
  840. * @return
  841. * @throws BusinessException
  842. */
  843. public List<TaskMemberBean> addAndDeleteTaskMemberBean(Long cid, Long tid, String[] addPersons, Integer[] types, Long pid, Long[] deletePersons, Integer type) throws BusinessException;
  844. public void updateTaskSummary(TaskSummaryBean summerBean) throws BusinessException;
  845. /**
  846. * 添加任务委托
  847. * @param deputeBeans
  848. * @throws BusinessException
  849. */
  850. // public void addTaskDepute(List<TaskDeputeBean> deputeBeans) throws ModuleException;
  851. // /**
  852. // * 修改委托任务状态
  853. // * @param resouceIds 任务id
  854. // * @param targetIds 被委托人的id
  855. // * @param dstate 状态 0未删除,1删除
  856. // * @throws ModuleException
  857. // */
  858. // public void updateTaskDeputeState(Long[] resouceIds, Long[] targetIds , Integer dstate) throws ModuleException;
  859. /**
  860. * 添加任务委托
  861. * @param pids 被委托的人,格式为:type_id ,如(100003_123456789)
  862. * @param endDate 被委托的结束时间
  863. * @param description 描述
  864. * @param pid 当前登陆人的id
  865. * @param taskId 任务id
  866. * @throws BusinessException
  867. */
  868. public void addTaskDepute(Long[] pids, String endDate, String description, Long pid, Long taskId, Long cid) throws BusinessException;
  869. /**
  870. * 根据任务id查询TaskDeputeBean
  871. * @param taskId
  872. * @param cid
  873. * @return
  874. * @throws BusinessException
  875. */
  876. public TaskDeputeBean findTaskDeputeByResouceId(Long taskId, Long cid) throws BusinessException;
  877. /**
  878. * @param cid 圈子ID
  879. * @param ids ID取值范围
  880. * @return 圈子最近发布的公告
  881. * @throws BusinessException
  882. */
  883. public List<TaskBO> findNoticeTaskOfRecent(Long cid, List<Long> ids) throws BusinessException;
  884. /**
  885. * 管理员删除人员或审核不通过时处理人员作为负责人的任务
  886. * 1. 是任务责任人但不是创建人,将任务委托给任务创建人
  887. * 2. 是任务责任人又是创建人,将任务委托给任务参与人
  888. * @param perIds 人员ID列表
  889. * @throws BusinessException
  890. */
  891. public void handleTaskWithDelMember(Long[] perIds) throws BusinessException;
  892. /**
  893. * 根据人员id和单位id,查询所有委托给我事项id
  894. * @param cid 单位id
  895. * @param personId 人员id
  896. * @return 事项id集合
  897. * @throws BusinessException
  898. */
  899. public List<Long> getTaskDeputTaskIds(Long cid, Long personId) throws BusinessException;
  900. /**
  901. * 分享任务到其他圈子
  902. * @param taskId 要分享的任务
  903. * @param cid 目标圈子的ID
  904. * @throws BusinessException
  905. */
  906. public void shareTask(Long taskId, Long cid) throws BusinessException;
  907. /**
  908. * 分享任务到其他圈子
  909. * @param taskId
  910. * @param cid
  911. * @param title
  912. * @param taskRelationType
  913. * @param labels
  914. * @param iconId
  915. * @throws BusinessException
  916. */
  917. public void shareTask(Long taskId, Long cid, String title, Integer taskRelationType, String labels, Long iconId) throws BusinessException;
  918. /**
  919. * 统计任务条数
  920. * @param pid 人员id
  921. * @param cid 单位id
  922. * @return
  923. * @throws BusinessException
  924. */
  925. public Integer findTaskCount(Long pid, Long pid2, Long cid, Integer[] states, Integer findState, Date startDate, Date endDate,Integer[] progressState) throws BusinessException;
  926. public Integer findTaskCount(Long pid, Long pid2, Long cid, Integer[] states, Integer findState,Integer[] progressState) throws BusinessException;
  927. /**
  928. *
  929. * @param pid
  930. * @param pid2
  931. * @param cid
  932. * @param states
  933. * @param findState
  934. * @param startDate
  935. * @param endDate
  936. * @param start TODO
  937. * @param pageSize TODO
  938. * @return
  939. * @throws BusinessException
  940. */
  941. public ListObject<TaskSummaryBean> findTaskCountByList(Long pid, Long pid2, Long cid, Integer[] states, Integer findState, Date startDate, Date endDate, Integer start, Integer pageSize,Integer[] progressState)
  942. throws BusinessException;
  943. /**
  944. * 根据多个人员和查询标志,返回多个人员的事项数量
  945. * @param ids 人员id数组
  946. * @param TaskFindTypeEnum 参考枚举{@link TaskEnum.TaskFindTypeEnum}
  947. * @return Map key为人员id,value为事项数量
  948. * @throws BusinessException
  949. */
  950. public Map<Long, Integer> findTaskByCount(Long[] ids, Integer TaskFindTypeEnum) throws BusinessException;
  951. /**
  952. * 提供给移动端查询事项
  953. * @param findState
  954. * @param pid
  955. * @param cid
  956. * @param type
  957. * @param title
  958. * @param start
  959. * @param pageSize
  960. * @return
  961. * @throws BusinessException
  962. */
  963. public ListObject<TaskSummaryBean> findTaskByExtends(Integer findState, Long pid, Long cid, Integer type, String title, Integer start, Integer pageSize) throws BusinessException;
  964. /**
  965. *
  966. * findTask(查询公共圈子分享)
  967. * @param relationType 分类枚举
  968. * @param themeLabel 标签名称(模糊查询)
  969. * @param title 分享标题(模糊查询)
  970. * @param createDate 创建时间
  971. * @param start 页下标
  972. * @param pageSize 条数
  973. * @return ListObject
  974. * @throws BusinessException
  975. *ListObject<TaskShareBean>
  976. * @exception
  977. * @since 1.0.0
  978. */
  979. public ListObject<TaskShareBean> findTaskShare(Integer relationType, String themeLabel, String title, Date createDate, Integer start, Integer pageSize) throws BusinessException;
  980. /**
  981. * 根据id查询事项分享
  982. * @param id
  983. * @return
  984. * @throws BusinessException
  985. */
  986. public TaskShareBean findTaskShareById(Long id) throws BusinessException;
  987. /**
  988. * 根据某人资源查询条数
  989. * @param id
  990. * @param targetType
  991. * @param targetId
  992. * @return
  993. * @throws BusinessException
  994. */
  995. public Integer findTaskShareCount(Long id, Integer targetType, Long targetId) throws BusinessException;
  996. /**
  997. * 修改任务分享实体
  998. * @param shareBean
  999. * @throws BusinessException
  1000. */
  1001. public void updateTaskShare(TaskShareBean shareBean) throws BusinessException;
  1002. /**
  1003. * 根据分页查询分享
  1004. * @param start
  1005. * @param findCount
  1006. * @return
  1007. * @throws BusinessException
  1008. */
  1009. public ListObject<TaskShareBean> findTaskShareByHot(Integer start, Integer findCount) throws BusinessException;
  1010. public ListObject<TaskShareBean> findTaskShareByRecommend(Long sourceId, Integer start, Integer findCount) throws BusinessException;
  1011. public ListObject<TaskShareBean> findTaskShareByHot(Long sourceId, Integer start, Integer findCount) throws BusinessException;
  1012. /**
  1013. * 修改事项属性
  1014. * @param taskId
  1015. * @param nowAttrBean
  1016. * @return
  1017. * @throws BusinessException
  1018. */
  1019. public List<TaskMemberBean> updateTaskAttr(Long taskId, TaskAttrBean nowAttrBean) throws BusinessException;
  1020. /**
  1021. * 根据单位查询接收消息的事项
  1022. * @param cid
  1023. * @return
  1024. * @throws BusinessException
  1025. */
  1026. public List<TaskSummaryBean> findTaskByReceiveMsg() throws BusinessException;
  1027. List<TaskAttrBean> findTaskAttrByReceiveMsg() throws BusinessException;
  1028. public void clearTaskReceiveMsgState(Long[] ids) throws BusinessException;
  1029. public void clearTaskReceiveMsgState(List<Long> ids) throws BusinessException;
  1030. public ListObject<TaskProcessBO> findTaskProcessBosByTaskId(Long taskId, Integer start, Integer pageSize) throws BusinessException;
  1031. /**
  1032. * 添加事项评价
  1033. * 时间,评论ID,评论状态都被写了
  1034. * @param taskAssess 事项评价对象
  1035. * @throws BusinessException
  1036. */
  1037. public void addTaskAssess(TaskAssessBean taskAssess) throws BusinessException;
  1038. /**注意:在调用这个方法前要进行判断taskId!=null&&assessPersonId!=null&&assessPersonEdId!=null
  1039. * ,否则不能判断是否评论1
  1040. * 通过对事项评价taskId, assessPersonId,assessPersonEdId他们间的and关系查找
  1041. * @param
  1042. * @throws BusinessException
  1043. */
  1044. List<TaskSummaryBean> findTaskSummaryBeansWithoutOrder(Long[] ids) throws BusinessException;
  1045. /**
  1046. * 根据部门id查询责任人是当前部门的任务
  1047. * @param deptId 部门id
  1048. * @param start 分页起始位置,最小值>=0
  1049. * @param range 分页范围参数
  1050. * @return 返回查询到的任务信息列表对象,否则返回空列表对象:count=0,list.size()=0
  1051. * @throws BusinessException
  1052. */
  1053. public ListObject<TaskBO> findTaskBOsByDeptId(Long deptId, Integer start, Integer range) throws BusinessException;
  1054. public List<TaskAssessBean> findTaskAssessBean(Long taskId, Long assessPersonId, Long assessPersonEdId) throws BusinessException;
  1055. /**
  1056. * 通过对事项评价taskId, assessPersonEdId他们间的and关系查找
  1057. * 得出这件事,这人被那些人评论过评论了那些人
  1058. * @param
  1059. * @throws BusinessException
  1060. */
  1061. public List<TaskAssessBean> findTaskAssessList1(Long taskId, Long assessPersonEdId) throws BusinessException;
  1062. /**
  1063. * 通过对事项评价两个Id,他们间的and关系查找
  1064. * 得出这件事,这人被那些人评论过评论了那些人
  1065. * @param id1
  1066. * @param value1:id1的属性名
  1067. * @param id2
  1068. * @param value2:id2的属性名
  1069. * @throws BusinessException
  1070. */
  1071. public List<TaskAssessBean> findTaskAssessList(Long id1, String value1, Long id2, String value2) throws BusinessException;
  1072. /**
  1073. * 通过id来删除
  1074. * @param
  1075. * @throws BusinessException
  1076. */
  1077. public void deleteTaskAssessById(Long id) throws BusinessException;
  1078. /**
  1079. *
  1080. * @param value为属性的字段名,查询平均
  1081. * @throws BusinessException
  1082. */
  1083. public Double findTaskAssessListAvg(Long id1, String value1, Long id2, String value2, String value) throws BusinessException;
  1084. /**
  1085. * 根据部门id查询部门所有和我相关的事项(缺省排除结束的事项)
  1086. * @param departmentId
  1087. * @param pid
  1088. * @throws BusinessException
  1089. */
  1090. public List<TaskSummaryBean> findTaskByDepartment(Long departmentId, Long pid) throws BusinessException;
  1091. /**
  1092. * 根据部门id查询部门所有和我相关的事项(缺省排除结束的事项)
  1093. * @param departmentId
  1094. * @param pid
  1095. * @throws BusinessException
  1096. */
  1097. public List<TaskBO> findTaskByDepartmentByPage(Long departmentId, Long pid, Integer start, Integer range) throws BusinessException;
  1098. /**
  1099. * 根据指定人查询和我相光的事项(缺省排除结束的事项)
  1100. * @param targetPid
  1101. * @param pid
  1102. * @throws BusinessException
  1103. */
  1104. public List<TaskBO> findTaskByPersonTogether(Long targetPid, Long pid, Integer start, Integer range) throws BusinessException;
  1105. /**
  1106. * @throws BusinessException
  1107. */
  1108. public List<TaskSummaryBean> findTaskSummaryBeans(Long[] ids) throws BusinessException;
  1109. public ListObject<TaskSummaryBean> findTaskSummaryBeans(Long[] ids, Integer start, Integer range) throws BusinessException;
  1110. /**
  1111. * 撤销任务
  1112. * @param taskId
  1113. * @param perId 当前登录人ID
  1114. * @throws BusinessException
  1115. */
  1116. public void cancleTask(Long taskId, Long perId, Long cid) throws BusinessException;
  1117. /**
  1118. * @param memberId
  1119. * @throws BusinessException
  1120. */
  1121. public TaskMemberBean findTaskMemberById(Long memberId) throws BusinessException;
  1122. public List<TaskMemberBean> findTaskMemberByParentId(Long parentMemberId) throws BusinessException;
  1123. /**
  1124. * 查询出所有的taskMember
  1125. * @return
  1126. * @throws BusinessException
  1127. */
  1128. public List<TaskMemberBean> findAllTaskMember() throws BusinessException;
  1129. /**
  1130. * 用于指派任务给他人
  1131. * @param cid
  1132. * @param tid
  1133. * @param perIds
  1134. * @param type
  1135. * @param pid
  1136. * @param isDepute 是否是被委托
  1137. * @param parentId 委托的member ID
  1138. * @return
  1139. * @throws BusinessException
  1140. */
  1141. public List<TaskMemberBean> addTaskMember(Long cid, Long tid, Long[] perIds, Integer[] type, Long pid, Boolean isDepute, Long parentId) throws BusinessException;
  1142. /**
  1143. * 转发事项
  1144. * @param pid
  1145. * @param cid
  1146. * @param taskId
  1147. * @param supervisePersonId 督办人,格式为100003_1000000001
  1148. * @param managerPersonId 责任人,格式为100003_1000000001
  1149. * @param participantPersonId 参与人,格式为100003_1000000001
  1150. * @param title 转发的标题
  1151. * @param description 留言
  1152. * @throws BusinessException
  1153. */
  1154. public Long forwardTask(Long pid, Long cid, Long taskId, String supervisePersonId, String managerPersonId, String participantPersonId, String title, String description) throws BusinessException;
  1155. /**
  1156. * 根据taskIds查询List
  1157. * @param taskIds
  1158. * @return
  1159. * @throws BusinessException
  1160. */
  1161. public List<TaskMemberBean> findTaskMembersByTaskIds(List<Long> taskIds) throws BusinessException;
  1162. /**
  1163. * 根据taskIds查询成员集合
  1164. * @param taskIds 事项ID
  1165. * @param includeDeleted 是否包含被删除的成员
  1166. * @return 成员集合
  1167. * @throws BusinessException
  1168. */
  1169. public List<TaskMemberBean> findTaskMembersByTaskIds(List<Long> taskIds, boolean includeDeleted) throws BusinessException;
  1170. /**
  1171. * 根据orgPersonIdsByBeans查询事项数量,包含所有参与的
  1172. * @param orgPersonIdsByBeans 人员id集合
  1173. * @return
  1174. * @throws BusinessException
  1175. */
  1176. //public Integer findTaskCountByPersonIds(List<Long> orgPersonIdsByBeans, String startDate, String endDate) throws ModuleException;
  1177. /**
  1178. * 根据orgPersonIdsByBeans查询超期数量,包含超期和超期完成
  1179. * @param orgPersonIdsByBeans 人员id集合
  1180. * @return
  1181. * @throws BusinessException
  1182. */
  1183. //public Integer findOverdueTaskCountByPersonIds(List<Long> orgPersonIdsByBeans, String startDate, String endDate) throws ModuleException;
  1184. //保存,更新
  1185. /**
  1186. * 保存催办
  1187. * @param pid 催办人id
  1188. * @param memberId taskMemberId
  1189. * @param taskId 事项id
  1190. * @param content 内容
  1191. * @param cid 单位id
  1192. * @throws BusinessException
  1193. */
  1194. public void addTaskRemind(Long pid, Long memberId, Long taskId, String content, Long cid) throws BusinessException;
  1195. /**
  1196. * 保存任务意见信息
  1197. * 2016-5-7 上午11:14:39
  1198. *
  1199. * 增加返回值
  1200. * modify by huzy 2017/9/22 上午11:54
  1201. * addTaskOption
  1202. * @param pid 创建人id
  1203. * @param taskId 任务id
  1204. * @param content 内容
  1205. * @param cid 单位id
  1206. * @param type 意见类型
  1207. * @param sendMsg 是否发送短信
  1208. * @param recevice 短信接收人
  1209. * @param files TODO
  1210. * @throws BusinessException
  1211. *void
  1212. * @exception
  1213. * @since 2.0
  1214. */
  1215. public Long addTaskOption(Long pid, Long taskId, String content, Long cid , Integer type , Boolean sendMsg , String recevice, String[] files) throws BusinessException;
  1216. /**
  1217. * 处理催办
  1218. * @param taskRemindId 催办id
  1219. * @param state 状态,参考枚举
  1220. * @param content 内容
  1221. * @param reportId 汇报id
  1222. * @throws BusinessException
  1223. */
  1224. public void handleTaskRemind(Long taskRemindId, String content, Long reportId, Long pid) throws BusinessException;
  1225. /**
  1226. * 根据memberId查询所有状态的催办记录
  1227. * @param memberId
  1228. * @param start 分页参数
  1229. * @param range 分页参数
  1230. * @return
  1231. * @throws BusinessException
  1232. */
  1233. public ListObject<TaskRemindMemberBean> findTaskRemindMember(Long memberId, Integer start, Integer range) throws BusinessException;
  1234. /**
  1235. * 根据memberId查询所有状态的催办条数
  1236. * @param memberId
  1237. * @return
  1238. * @throws BusinessException
  1239. */
  1240. public Integer findTaskRemindMemberCount(Long memberId) throws BusinessException;
  1241. /**
  1242. * 根据memberId和state查询催办记录
  1243. * @param memberId
  1244. * @param state
  1245. * @return
  1246. * @throws BusinessException
  1247. */
  1248. public List<TaskRemindMemberBean> findTaskRemindMemberByState(Long memberId, Integer state) throws BusinessException;
  1249. /**
  1250. * 根据memberIds查询催办记录
  1251. * 2015-10-8 下午5:51:46
  1252. *
  1253. * findTaskRemindMemberByState
  1254. * @param memberIds
  1255. * @param state
  1256. * @return
  1257. * @throws BusinessException
  1258. *List<TaskRemindMemberBean>
  1259. * @exception
  1260. * @since 1.0.0
  1261. */
  1262. public List<TaskRemindMemberBean> findTaskRemindMemberByState(List<Long> memberIds, Integer state) throws BusinessException;
  1263. /**
  1264. * 根据memberId和state查询催办记录条数
  1265. * @param memberId
  1266. * @param state
  1267. * @return
  1268. * @throws BusinessException
  1269. */
  1270. public Integer findTaskRemindMemberByStateCount(Long memberId, Integer state) throws BusinessException;
  1271. /**
  1272. * 查找所有的催办信息
  1273. * @return
  1274. * @throws BusinessException
  1275. */
  1276. public List<TaskRemindMemberBean> findTaskRemindMember() throws BusinessException;
  1277. /**
  1278. * 根据memberIds和state查询催办记录条数
  1279. * 2015-10-8 下午5:59:22
  1280. *
  1281. * findTaskRemindMemberByStateCount
  1282. * @param memberIds
  1283. * @param state
  1284. * @return
  1285. * @throws BusinessException
  1286. *Integer
  1287. * @exception
  1288. * @since 1.0.0
  1289. */
  1290. public Integer findTaskRemindMemberByStateCount(List<Long> memberIds, Integer state) throws BusinessException;
  1291. /**
  1292. *
  1293. * 2015-9-25 上午10:33:15
  1294. * 根据taskProcessSummaryId查询TaskProcessBO
  1295. * findTaskProcessBOById
  1296. * @param taskProcessSummaryId
  1297. * @return
  1298. * @throws BusinessException
  1299. *TaskProcessBO
  1300. * @exception
  1301. * @since 1.0.0
  1302. */
  1303. public TaskProcessBO findTaskProcessBOById(Long taskProcessSummaryId) throws BusinessException;
  1304. /**
  1305. * 根据taskId和pid查询事项动态
  1306. * 2015-9-29 下午3:23:00
  1307. *
  1308. * findTaskProcessBeansByTaskId
  1309. * @param taskId 事项id
  1310. * @param pid 人员
  1311. * @return
  1312. * @throws BusinessException
  1313. *TaskProcessSummaryBean
  1314. * @exception
  1315. * @since 1.0.0
  1316. */
  1317. public TaskProcessSummaryBean findTaskProcessBeansByTaskId(Long taskId, Long pid) throws BusinessException;
  1318. /**
  1319. * 根据任务ID和reportId
  1320. * 查询留言信息
  1321. * memberID
  1322. * @param taskId
  1323. * @param pid
  1324. * @param reportId
  1325. * @return
  1326. */
  1327. public TaskProcessSummaryBean findTaskProcessBeansByTaskIdAndReportId(Long taskId, Long pid,Long reportId) throws BusinessException;
  1328. /**
  1329. * @author inspired (胡启林)
  1330. * @param
  1331. * @describe 根据任务ID和reportId查对应阶段的汇报留言
  1332. * @createTime 2021/6/4 10:06
  1333. */
  1334. public TaskProcessSummaryBean findTaskProcessByTaskIdAndReportIdAndPhaseId(Long taskId, Long pid,Long reportId,Long phaseId) throws BusinessException;
  1335. public TaskProcessSummaryBean findTaskProcessBeansByReportId(Long reportId) throws BusinessException;
  1336. public TaskProcessSummaryBean findTaskProcessBeanByReportIdAndPhaseId(Long reportId,Long phaseId) throws BusinessException;
  1337. public List<TaskProcessSummaryBean> findTaskProcessBeanByReportIdAndPhaseId(Long taskId,Long reportId,Long phaseId) throws BusinessException;
  1338. public TaskProcessSummaryBean findTaskProcessSummaryById(Long id) throws BusinessException;
  1339. /**
  1340. * 根据任务ID和memberID
  1341. * 查询主办或协办信息
  1342. * memberID
  1343. * @param taskId
  1344. * @param memberId
  1345. * @param startIndex
  1346. * @param range
  1347. * @return
  1348. */
  1349. public ListObject<TaskReportBO> findTaskReportSummaryByTaskIdAndMemberId(Long taskId, Long memberId, int startIndex, int range) throws BusinessException;
  1350. /**
  1351. * 查找任务最新进度汇报的时间
  1352. * 用于任务时间视图展示超期的时间段
  1353. * @param taskIds 任务ID
  1354. * @return {@code Map<任务ID, 汇报的时间>}
  1355. * @throws SQLException
  1356. */
  1357. public Map<Long, String> findLatestUpdateDateOfTask(List<Long> taskIds) throws BusinessException;
  1358. /**
  1359. * zhangzy
  1360. * @param tid
  1361. * @param key
  1362. * @param faildtime
  1363. */
  1364. public void updateTaskReportSummaryBytaskIdAndMembrId(Long id, int key, Date faildtime) throws BusinessException;
  1365. /**
  1366. * zhangzy
  1367. * 保存打回信息
  1368. * @param tbm
  1369. */
  1370. public void saveTaskBackMessage(TaskBackMessageBean tbm) throws BusinessException;
  1371. /**
  1372. * zhangzy
  1373. * @param taskId
  1374. * @param memeberId
  1375. * @param did
  1376. * @param i
  1377. * @param j
  1378. * @return
  1379. */
  1380. public ListObject<TaskReportBO> findTaskReportSummaryByTaskIdAndMemberIdDid(Long taskId, Long memeberId, Long did, int i, int j) throws BusinessException;
  1381. /**
  1382. * zhangzy
  1383. * @param reportBO
  1384. * @param ismanager
  1385. */
  1386. public void addTaskReportSummarys(TaskReportBO reportBO, boolean ismanager) throws BusinessException;
  1387. /**
  1388. * 单位下最新的一条汇报记录
  1389. * zhangzy
  1390. * @param taskId
  1391. * @param did
  1392. * @param i
  1393. * @param j
  1394. * @return
  1395. * @throws BusinessException
  1396. */
  1397. public ListObject<TaskReportBO> findTaskReportSummaryByTaskIdAndDid(Long taskId, Long did, int i, int j) throws BusinessException;
  1398. /**
  1399. * 根据汇报ID 查询对应打回记录
  1400. * @param id
  1401. * @return
  1402. * @throws BusinessException
  1403. */
  1404. public List<TaskBackMessageBean> findtaskbackmessageByTaskreportId(Long id) throws BusinessException;
  1405. /**
  1406. * @param taskId
  1407. * @return 当前任务根据member组合最新的进度汇报情况
  1408. * @throws SQLException
  1409. */
  1410. public List<TaskReportBO> findLastestReportByTaskId(Long taskId) throws BusinessException;
  1411. /**
  1412. * @param taskId
  1413. * @return 事项中按照单位统计的进度情况
  1414. * @throws BusinessException
  1415. */
  1416. public List<Map<String, Object>> getTaskReportStatics(Long taskId) throws BusinessException;
  1417. /**
  1418. * 根据tasskId和pids查询汇报
  1419. * 2016-1-26 下午2:44:20
  1420. *
  1421. * findTaskReportBosByTaskIdAndPids
  1422. * @param taskId
  1423. * @param pids
  1424. * @return
  1425. * @throws BusinessException
  1426. *List<TaskReportBO>
  1427. * @exception
  1428. * @since 2.0
  1429. */
  1430. public List<TaskReportBO> findTaskReportBosByTaskIdAndPids(Long taskId, Long[] pids) throws BusinessException;
  1431. /**
  1432. * 根据taskId和taskMemberIdsByBeans查询催办记录
  1433. * 2016-1-26 下午4:58:23
  1434. *
  1435. * findTaskRemindMember
  1436. * @param taskId
  1437. * @param taskMemberIdsByBeans
  1438. * @return
  1439. * @throws BusinessException
  1440. *List<TaskRemindMemberBean>
  1441. * @exception
  1442. * @since 2.0
  1443. */
  1444. public Integer findTaskRemindMember(Long taskId, List<Long> taskMemberIdsByBeans) throws BusinessException;
  1445. /**
  1446. * 添加汇报审核信息
  1447. * 2016-3-8 下午5:58:45
  1448. *
  1449. * addTaskReportMemberBeans
  1450. * @param reportMembersBeans
  1451. * @throws BusinessException
  1452. *void
  1453. * @exception
  1454. * @since 2.0
  1455. */
  1456. public void addTaskReportMemberBeans(List<TaskReportMemberBean> reportMembersBeans) throws BusinessException;
  1457. /**
  1458. * 根据事项id和人员id查询未处理的汇报审批
  1459. * 2016-3-8 下午8:06:09
  1460. *
  1461. * findTaskReportMemberBeans
  1462. * @param taskId
  1463. * @param personId
  1464. * @return
  1465. * @throws BusinessException
  1466. *List<TaskRemindMemberBean>
  1467. * @exception
  1468. * @since 2.0
  1469. */
  1470. public List<TaskReportMemberBean> findTaskReportMemberBeans(Long taskId, Long personId) throws BusinessException;
  1471. /**
  1472. * 根据taskId和examine状态查询未审核或者已审核的汇报审批
  1473. * 2016-3-26 下午2:15:54
  1474. *
  1475. * findTaskReportMemberBeans
  1476. * @param taskId
  1477. * @param personId
  1478. * @return
  1479. * @throws BusinessException
  1480. *List<TaskReportMemberBean>
  1481. * @exception
  1482. * @since 2.0
  1483. */
  1484. public List<TaskReportMemberBean> findTaskReportMemberBeans(Long taskId, Integer examine) throws BusinessException;
  1485. /**
  1486. * 根据reportMemberId查询bean
  1487. * 2016-3-9 下午8:17:30
  1488. *
  1489. * findTaskReportMemberById
  1490. * @param reportMemberId
  1491. * @return
  1492. * @throws BusinessException
  1493. *TaskReportMemberBean
  1494. * @exception
  1495. * @since 2.0
  1496. */
  1497. public TaskReportMemberBean findTaskReportMemberById(Long reportMemberId)throws BusinessException;
  1498. /**
  1499. *
  1500. * 2016-3-9 下午8:17:34
  1501. * 根据taskReportId查询bo
  1502. * findTaskReportBo
  1503. * @param taskReportId
  1504. * @return
  1505. * @throws BusinessException
  1506. *TaskReportBO
  1507. * @exception
  1508. * @since 2.0
  1509. */
  1510. public TaskReportBO findTaskReportBo(Long taskReportId) throws BusinessException;
  1511. /**
  1512. * 处理汇报审核
  1513. * 2016-3-10 下午6:45:59
  1514. *
  1515. * handleTaskReport
  1516. * @param reportMemberId
  1517. * @param option
  1518. * @param state
  1519. * @param pid
  1520. * @param leaderManager TODO
  1521. * @param memberType TODO
  1522. * @throws BusinessException
  1523. *void
  1524. * @exception
  1525. * @since 2.0
  1526. */
  1527. public void handleTaskReport(Long reportMemberId, String option, Integer state, Long pid, String leaderManager, Integer memberType) throws BusinessException;
  1528. /**
  1529. * 根据条件查询汇报审批记录
  1530. * 2016-3-10 下午8:01:19
  1531. *
  1532. * findTaskReportMemberBeans
  1533. * @param taskId 事项id
  1534. * @param personId 人员id
  1535. * @param state 0代表未查看,1代表已查看
  1536. * @return
  1537. * @throws BusinessException
  1538. *List<TaskReportMemberBean>
  1539. * @exception
  1540. * @since 2.0
  1541. */
  1542. public List<TaskReportMemberBean> findTaskReportMemberBeans(Long taskId, Long personId, Integer state) throws BusinessException;
  1543. /**
  1544. * 添加汇报的审批
  1545. * 2016-3-14 下午2:13:36
  1546. *
  1547. * addTaskReportExamine
  1548. * @param reportBO
  1549. * @param
  1550. * @param colIds TODO
  1551. * @throws BusinessException
  1552. *void
  1553. * @exception
  1554. * @since 2.0
  1555. */
  1556. public void addTaskReportExamine(TaskReportBO reportBO , Integer state , Integer process, String sendColType, String colIds) throws BusinessException;
  1557. /**
  1558. * 根据事项id和汇报id查询汇报审批记录
  1559. * 2016-3-15 下午4:23:36
  1560. *
  1561. * findTaskReportMemberBean
  1562. * @param l 任务id
  1563. * @param m 汇报的id
  1564. * @return
  1565. * @throws BusinessException
  1566. *TaskReportMemberBean
  1567. * @exception
  1568. * @since 2.0
  1569. */
  1570. public TaskReportMemberBean findTaskReportMemberBean(Long l, Long m) throws BusinessException;
  1571. public List<TaskAttrBean> findTaskAttr(Long cid, Integer taskCategory) throws BusinessException;
  1572. // ---任务类型管理
  1573. /**
  1574. * 新增任务类别或来源
  1575. *
  1576. * @param taskType
  1577. * @throws BusinessException
  1578. */
  1579. public void addTaskType(TaskTypeBean taskType) throws BusinessException;
  1580. /**
  1581. * 批量新增任务类别
  1582. * @param taskTypeBeans
  1583. * @param account
  1584. * @throws BusinessException
  1585. */
  1586. void addTaskTypes(List<TaskTypeBean> taskTypeBeans, OrgUnitBean account) throws BusinessException;
  1587. /**
  1588. * 更新任务类型或来源
  1589. *
  1590. * @param taskType
  1591. * @throws BusinessException
  1592. */
  1593. public void updateTaskType(TaskTypeBean taskType) throws BusinessException;
  1594. /**
  1595. * 批量更新任务类型或来源
  1596. *
  1597. * @param taskType
  1598. * @throws BusinessException
  1599. */
  1600. void updateTaskTypes(List<TaskTypeBean> taskType) throws BusinessException;
  1601. /**
  1602. * @param ids
  1603. * @param status
  1604. * @throws BusinessException
  1605. */
  1606. public void updateTaskTypeStatus(Long[] ids, Integer status) throws BusinessException;
  1607. /**
  1608. * 在缓存中查找指定id数组任务类型下是否存在子任务类型
  1609. * @param ids
  1610. * @return true:存在 false:不存在
  1611. */
  1612. public boolean findIsChildTaskType(Long[] ids) throws BusinessException;
  1613. /**
  1614. * 根据类型Id更新该类型的使用范围
  1615. * @param ids
  1616. * @param users
  1617. * @throws BusinessException
  1618. */
  1619. public void updateTaskTypeUsers(Long[] ids, String users) throws BusinessException;
  1620. /**
  1621. * 根据任务类型id查询任务类型
  1622. *
  1623. * @param id
  1624. * @return
  1625. * @throws BusinessException
  1626. */
  1627. public TaskTypeBean findTaskTypeBean(Long id) throws BusinessException;
  1628. /**
  1629. * 获取回报情况
  1630. * @param tasktype_id
  1631. * @return 指标总数及未汇报数量
  1632. */
  1633. Map<String,Object> getReportNum(String tasktype_id) throws BusinessException;
  1634. /**
  1635. * 根据任务remark查询任务类型
  1636. *
  1637. * @param remark
  1638. * @return
  1639. * @throws BusinessException
  1640. */
  1641. public TaskTypeBean findTaskTypeBeanByRemark(String remark,Long accountId) throws BusinessException;
  1642. TaskTypeBean findTaskTypeByNameAndPName(String name, String parentName, Long accountId) throws BusinessException;
  1643. /**
  1644. * @author inspired (胡启林)
  1645. * @param subType {@link TaskEnum.TaskTypeSub}
  1646. * @describe 根据subType查询所有类型
  1647. * @createTime 2020/11/26 16:44
  1648. */
  1649. public List<TaskTypeBean> findTaskTypeBeansBySubType(Integer subType,Long accountId) throws BusinessException;
  1650. public List<TaskTypeBean> findTaskTypeBeansBySubTypes(List<Integer> subTypes,Long accountId) throws BusinessException;
  1651. /**
  1652. * @param subType {@link TaskEnum.TaskTypeSub}
  1653. * @describe 根据subType查询所有类型,针对前端树的生成
  1654. * @createTime 2021/2/25
  1655. * @return
  1656. */
  1657. public List<Map<String, Object>> findTaskTypeBeansBySubTypeForZtree(Integer subType) throws BusinessException;
  1658. List<Map<String, Object>> findTaskTypebeansBySubTypeAndRourcetype(Integer subType,Integer rouceType)throws BusinessException;
  1659. /**
  1660. * @author inspired (胡启林)
  1661. * @param
  1662. * @describe 获取能够参与统计的督办类型
  1663. * @createTime 2021/1/25 14:57
  1664. */
  1665. public List<TaskTypeBean> findCanCountTaskTypeBeans(Long accountId) throws BusinessException;
  1666. /**
  1667. * @author inspired (胡启林)
  1668. * @param
  1669. * @describe 获取专项工作任务类型
  1670. * @createTime 2020/12/30 11:30
  1671. */
  1672. public List<TaskTypeBean> findSpecificWorkTaskTypeBeans() throws BusinessException;
  1673. /**
  1674. * 根据任务类型id查询任务类型
  1675. *
  1676. * @param id
  1677. * @return
  1678. * @throws BusinessException
  1679. */
  1680. public List<Map<String, Object>> findTaskTypeBeanList(Long id) throws BusinessException;
  1681. /**
  1682. * 根据任务类型id查询任务类型
  1683. * @param ids
  1684. * @return
  1685. * @throws BusinessException
  1686. */
  1687. public List<TaskTypeBean> findTaskTypeBean(Collection<Long> ids)throws BusinessException;
  1688. /**
  1689. * 根据单位id和子类别查询任务类型或来源
  1690. *
  1691. * @param cid
  1692. * @param resourceType TODO
  1693. * @param subType
  1694. * @param status
  1695. * TODO
  1696. * @param start
  1697. * TODO
  1698. * @param range
  1699. * TODO
  1700. * @return
  1701. * @throws BusinessException
  1702. */
  1703. public ListObject<TaskTypeBean> findTaskType(Long cid, Integer resourceType, Integer subType, Integer status, Integer start, Integer range,Long accountId)
  1704. throws BusinessException;
  1705. List<TaskTypeBean> findtasktypeByKeyProject(Integer isKeyProject) throws BusinessException;
  1706. /**
  1707. * 根据id查询子类型
  1708. * @param parentId
  1709. * @param resourceType TODO
  1710. * @param subType TODO
  1711. * @return
  1712. * @throws BusinessException
  1713. */
  1714. public ListObject<TaskTypeBean> findTaskTypesByParentId(Long parentId,Integer resourceType, Integer subType, Integer start, Integer range,Long accountId) throws BusinessException;
  1715. /**
  1716. * @author inspired (胡启林)
  1717. * @param taskTypeId
  1718. * @param start
  1719. * @param range
  1720. * @describe 根据任务类型分页查询任务模板
  1721. * @createTime 2020/10/14 16:40
  1722. */
  1723. public ListObject<TaskSummaryBean> findTaskTemplateByTaskTypeId(Long taskTypeId, Integer start, Integer range) throws BusinessException, SQLException;
  1724. /**
  1725. * 查询单位的所有任务类型和来源
  1726. *
  1727. * @param cid
  1728. * @param status
  1729. * TODO
  1730. * @return
  1731. * @throws BusinessException
  1732. */
  1733. public List<TaskTypeBean> findTaskTypes(Long cid, Integer status,Long accountId) throws BusinessException;
  1734. /**
  1735. * @param cid
  1736. * @param resourceType TODO
  1737. * @param subType
  1738. * @return
  1739. * @throws BusinessException
  1740. */
  1741. public List<TaskTypeBean> findTaskTypes(Long cid, Integer resourceType, Integer subType, Integer status,Long accountId) throws BusinessException;
  1742. /**
  1743. * @param cid
  1744. * @param resourceType
  1745. * @param subType
  1746. * @return
  1747. * @throws BusinessException
  1748. */
  1749. public List<TaskTypeBean> findTaskTypes(Long cid, Integer resourceType, Integer subType,Long accountId)throws BusinessException;
  1750. /**
  1751. * @param cid 单位id
  1752. * @param personId 人员id
  1753. * @param resourceType 资源ID:任务、会议等
  1754. * @param subType 来源-2,类型-1
  1755. * @param status TaskEnum.TaskTypeStatus
  1756. * @return
  1757. * @throws BusinessException
  1758. */
  1759. public List<TaskTypeBean> findTaskTypes(Long cid,Long personId, Integer resourceType, Integer subType, Integer status,Long accountId) throws BusinessException;
  1760. /**
  1761. * 根据taskId查询所有文件
  1762. * 2016-5-24 上午10:50:05
  1763. *
  1764. * findTaskFilesById
  1765. * @param taskId 事项id
  1766. * @return
  1767. * @throws BusinessException
  1768. *List<SpaceFileBean>
  1769. * @exception
  1770. * @since 2.0
  1771. */
  1772. public List<SpaceFileBean> findTaskFilesById(Long taskId) throws BusinessException;
  1773. /**
  1774. * 增加问题
  1775. * @param taskProblemBean
  1776. * @throws SQLException
  1777. */
  1778. public void addTaskProblem(TaskProblemBean taskProblemBean) throws BusinessException;
  1779. /**
  1780. * 更新问题
  1781. * @param taskProblemBean
  1782. * @throws SQLException
  1783. */
  1784. public void updateTaskProblem(TaskProblemBean taskProblemBean) throws BusinessException;
  1785. /**
  1786. * 根据id查询问题
  1787. * @param id
  1788. * @return TODO
  1789. * @throws BusinessException
  1790. */
  1791. public TaskProblemBean findTaskProblemById(Long id) throws BusinessException;
  1792. /**
  1793. * 添加签收处理意见
  1794. * 2016-6-16 下午2:59:26
  1795. *
  1796. * addTaskReceiveMemberBean
  1797. * @param receiveMemberBean
  1798. * @param leanderManager TODO
  1799. * @return
  1800. * @throws BusinessException
  1801. *TaskReceiveMemberBean
  1802. * @exception
  1803. * @since 2.0
  1804. */
  1805. public void addTaskexamineByReceive(TaskExamineMemberBean receiveMemberBean, String leanderManager) throws BusinessException;
  1806. /**
  1807. * 根据taskExaminId查询实体
  1808. * 2016-6-17 下午5:15:16
  1809. *
  1810. * findTaskExamineBeanById
  1811. * @param taskExaminId
  1812. * @return
  1813. *TaskExamineMemberBean
  1814. * @exception
  1815. * @since 2.0
  1816. */
  1817. public TaskExamineMemberBean findTaskExamineBeanById(Long taskExaminId) throws BusinessException;
  1818. /**
  1819. * 退回审核
  1820. * 2016-6-17 下午5:15:48
  1821. *
  1822. * submitTaskReceiveExamine
  1823. * @param taskExamineMemberBean
  1824. * @param manager
  1825. * @param startDate TODO
  1826. * @param endDate TODO
  1827. * @throws BusinessException
  1828. *void
  1829. * @exception
  1830. * @since 2.0
  1831. */
  1832. public void submitTaskReceiveExamine(TaskExamineMemberBean taskExamineMemberBean, String manager, String startDate, String endDate) throws BusinessException;
  1833. /**
  1834. * 领导任务审核
  1835. * 2016-6-20 下午1:35:18
  1836. *
  1837. * submitTaskExamine
  1838. * @param taskExamineMemberBean
  1839. * @param difficulty
  1840. * @throws BusinessException
  1841. *void
  1842. * @exception
  1843. * @since 2.0
  1844. */
  1845. public void submitTaskExamine(TaskExamineMemberBean taskExamineMemberBean, String difficulty) throws BusinessException;
  1846. /**
  1847. * 查询我提交的签收处理
  1848. * 2016-6-21 上午11:02:44
  1849. *
  1850. * findTaskExamineBeansBySubmitRecevice
  1851. * @param personId
  1852. * @param memberId
  1853. * @param taskId
  1854. * @return
  1855. * @throws BusinessException
  1856. *List<TaskExamineMemberBean>
  1857. * @exception
  1858. * @since 2.0
  1859. */
  1860. public List<TaskExamineMemberBean> findTaskExamineBeansBySubmitRecevice(Long personId, Long memberId, Long taskId) throws BusinessException;
  1861. /**
  1862. * 查询我待审核的退回
  1863. * 2016-6-21 上午11:03:41
  1864. *
  1865. * findTaskExamineBeansByWaitRecevice
  1866. * @param personId
  1867. * @param memberId
  1868. * @param taskId
  1869. * @return
  1870. * @throws BusinessException
  1871. *List<TaskExamineMemberBean>
  1872. * @exception
  1873. * @since 2.0
  1874. */
  1875. public List<TaskExamineMemberBean> findTaskExamineBeansByWaitRecevice(Long personId, Long memberId, Long taskId) throws BusinessException;
  1876. /**
  1877. * 查询我提交的领导审核
  1878. * 2016-6-21 上午11:31:57
  1879. *
  1880. * findTaskExamineBeansByLeader
  1881. * @param personId
  1882. * @param memberId
  1883. * @param taskId
  1884. * @return
  1885. * @throws BusinessException
  1886. *List<TaskExamineMemberBean>
  1887. * @exception
  1888. * @since 2.0
  1889. */
  1890. public List<TaskExamineMemberBean> findTaskExamineBeansByLeader(Long personId, Long memberId, Long taskId) throws BusinessException;
  1891. /**
  1892. *
  1893. * 2016-6-21 上午11:32:08
  1894. * 查询我待审核的任务
  1895. * findTaskExamineBeansByWaitLeader
  1896. * @param personId
  1897. * @param memberId
  1898. * @param taskId
  1899. * @return
  1900. * @throws BusinessException
  1901. *List<TaskExamineMemberBean>
  1902. * @exception
  1903. * @since 2.0
  1904. */
  1905. public List<TaskExamineMemberBean> findTaskExamineBeansByWaitLeader(Long personId, Long memberId, Long taskId) throws BusinessException;
  1906. /**
  1907. * 查询任务所有签收的实体
  1908. * 2016-6-21 下午5:37:09
  1909. *
  1910. * findTaskIsRecevice
  1911. * @param taskId
  1912. * @return
  1913. * @throws BusinessException
  1914. *List<TaskExamineMemberBean>
  1915. * @exception
  1916. * @since 2.0
  1917. */
  1918. public List<TaskExamineMemberBean> findTaskIsRecevice(Long taskId) throws BusinessException;
  1919. public List<TaskExamineMemberBean> findTaskIsLeader(Long taskId) throws BusinessException;
  1920. public List<TaskRemindMemberBean> findTaskRemindMemberByTaskId(Long taskId) throws BusinessException;
  1921. /**
  1922. * 替换任务的member
  1923. * @param taskId
  1924. * @param selectType
  1925. * @param person
  1926. * @param pid TODO
  1927. * @throws BusinessException
  1928. */
  1929. public void updateTaskMember(Long taskId, Integer selectType, String person, Long pid) throws BusinessException;
  1930. public void addTaskScroeMember(TaskScoreMemberBean scoreMemberBean) throws BusinessException;
  1931. public TaskScoreMemberBean findTaskScoreMemberBean(Long id) throws BusinessException;
  1932. public void submitTaskScoreHandle(Long taskScoreMemberId , Integer leaderScore , Long pid , String option) throws BusinessException;
  1933. public TaskScoreMemberBean findTaskScoreMemberBeanByLastTime(Long taskId) throws BusinessException;
  1934. public void updateTaskScoreMemberBean(TaskScoreMemberBean scoreMemberBean) throws BusinessException;
  1935. /**
  1936. * 查询事项领导未处理的审批
  1937. * 2016-7-13 上午12:34:00
  1938. *
  1939. * findTaskIsLeaderNoSubmit
  1940. * @param taskId
  1941. * @return
  1942. * @throws BusinessException
  1943. *List<TaskExamineMemberBean>
  1944. * @exception
  1945. * @since 2.0
  1946. */
  1947. public List<TaskExamineMemberBean> findTaskIsLeaderNoSubmit(Long taskId) throws BusinessException;
  1948. /**
  1949. * 根据taskId查询所有签收的实体,包含已经处理过的签收
  1950. * 2016-7-13 下午2:43:59
  1951. *
  1952. * findTaskIsAllRecevice
  1953. * @param taskId
  1954. * @return
  1955. * @throws BusinessException
  1956. *List<TaskExamineMemberBean>
  1957. * @exception
  1958. * @since 2.0
  1959. */
  1960. public List<TaskExamineMemberBean> findTaskIsAllRecevice(Long taskId) throws BusinessException;
  1961. /**
  1962. * 查询所有领导审批
  1963. * 2016-7-13 下午3:14:52
  1964. *
  1965. * findTaskExamineBeansByAllLeader
  1966. * @param personId
  1967. * @param memberId
  1968. * @param taskId
  1969. * @return
  1970. * @throws BusinessException
  1971. *List<TaskExamineMemberBean>
  1972. * @exception
  1973. * @since 2.0
  1974. */
  1975. public List<TaskExamineMemberBean> findTaskExamineBeansByAllLeader(Long taskId) throws BusinessException;
  1976. public List<TaskExamineMemberBean> findTaskExamineBeans(Criterion c) throws BusinessException;
  1977. public List<TaskReportMemberBean> findTaskReportMemberBeans(Criterion c) throws BusinessException;
  1978. public List<TaskScoreMemberBean> findTaskScoreMemberBeans(Criterion c) throws BusinessException;
  1979. public List<TaskScoreMemberBean> findTaskScoreMemberBeansByTaskId(Long taskId) throws BusinessException;
  1980. /**
  1981. * 根据人员id查询所有任务
  1982. * @param personId
  1983. * @param cid TODO
  1984. * @param relTypes TODO
  1985. * @param redFlag TODO
  1986. * @return
  1987. * @throws BusinessException
  1988. */
  1989. public List<TaskSummaryBean> findTasksByPersonId(Long personId, Long cid, Integer[] relTypes, Integer[] redFlag) throws BusinessException;
  1990. /**
  1991. * 根据人员ID查询所有事项ID
  1992. * @param deparIds
  1993. * @throws BusinessException
  1994. */
  1995. public List<Long> findTaskMembersByResourceIds(List<Long> deparIds) throws BusinessException;
  1996. /**
  1997. * 根据tcode查询所有事项
  1998. * @param tcode
  1999. * @throws BusinessException
  2000. */
  2001. public List<TaskSummaryBean> findTaskSummaryByTcode(String tcode);
  2002. /**
  2003. * 根据组织id查询所有事项ID
  2004. * @param deparIds
  2005. * @return
  2006. * @throws BusinessException
  2007. */
  2008. public List<TaskMemberBean> findTaskMembersByResourceIds(List<Long> orgIds,Integer[] relTypes) throws BusinessException;
  2009. /**
  2010. * @param taskId
  2011. * @param orgIds
  2012. * @param relTypes
  2013. * @return
  2014. * @throws BusinessException
  2015. */
  2016. public List<TaskMemberBean> findTaskMembersByResourceIds(Long taskId, List<Long> orgIds,Integer[] relTypes) throws BusinessException;
  2017. /**
  2018. * 指定事项阶段汇总数据
  2019. * @author inspired
  2020. * @param taskId
  2021. * @param phaseId
  2022. * @return
  2023. * @throws BusinessException
  2024. */
  2025. List<TaskReportBean> findTaskCollectReports(Long taskId,Long phaseId) throws BusinessException;
  2026. /**
  2027. * 查询承办单位未签收的人员名称
  2028. * @param taskId
  2029. * @param orgIds
  2030. * @param relTypes
  2031. * @return
  2032. * @throws BusinessException
  2033. */
  2034. public String[] findUnreceiptedManagerTaskMembersByResourceIds(Long taskId, List<Long> orgIds,Integer[] relTypes) throws BusinessException;
  2035. /**
  2036. * 查询距离当前时间最接近的3条数据
  2037. * @return
  2038. * @throws BusinessException
  2039. */
  2040. public ListObject<TaskSummaryBean> findTaskSummaryBeansByCreateDate(Date createdate,Integer pageSize ,Integer start) throws BusinessException;
  2041. /**
  2042. * 统计事项各状态数量
  2043. * @param key
  2044. * @return
  2045. * @throws BusinessException
  2046. */
  2047. public int countTaskSummaryByTstate(int key) throws BusinessException;
  2048. /**
  2049. * 通过父类来源获取子类来源数据
  2050. * @param from
  2051. * @param taskYear
  2052. * @return
  2053. * @throws BusinessException
  2054. */
  2055. public List<Map<String, Object>> findTaskSubFromByFrom(Long from, String taskYear) throws BusinessException;
  2056. /**
  2057. * 根据人员和状态查询任务条数
  2058. * @param personId
  2059. * @param state
  2060. * @param memberRel
  2061. * @return
  2062. */
  2063. public Integer findTaskCountByPerson(Long cid,Long personId,Integer[] state,Integer memberRel) throws BusinessException;
  2064. /**
  2065. *
  2066. * @param pid 用户id
  2067. * @return 通过用户id查询相关事项
  2068. */
  2069. public List<TaskMemberBean> findTaskByPersonId(Long pid,Integer memberRelType);
  2070. //----------------------------------20161018------------------------------------------------
  2071. /**
  2072. * 根据单位查询任务
  2073. * @param cid 单位id
  2074. * @param from 创建时间
  2075. * @param to 创建时间
  2076. * @return
  2077. * @throws BusinessException
  2078. */
  2079. public List<TaskSummaryBean> findTasksByCid(Long cid,Date from,Date to)throws BusinessException;
  2080. /**
  2081. * @param personId 人员id
  2082. * @param from 创建时间
  2083. * @param to 创建时间
  2084. * @return
  2085. * @throws BusinessException
  2086. */
  2087. public List<TaskSummaryBean> findTasksByDept(Long[] deptId,Date from,Date to)throws BusinessException;
  2088. /**
  2089. * @param personId 人员id
  2090. * @param from 创建时间
  2091. * @param to 创建时间
  2092. * @return
  2093. * @throws BusinessException
  2094. */
  2095. public List<TaskSummaryBean> findTasksByPer(Long[] personId,Date from,Date to)throws BusinessException;
  2096. /**
  2097. * 根据任务id查询催办记录
  2098. * @param taskIds
  2099. * @return
  2100. * @throws BusinessException
  2101. */
  2102. public List<TaskRemindMemberBean> findTaskRemindMemberByTaskId(Long[] taskIds)throws BusinessException;
  2103. /**
  2104. * 根据任务Id删除任务
  2105. * @param ids
  2106. * @throws BusinessException
  2107. */
  2108. public void deleteTaskById(Long[] ids)throws BusinessException;
  2109. void deleteTaskById(Long[] ids, boolean isLogic) throws BusinessException;
  2110. /**
  2111. * 判断人员是否为任务领导角色
  2112. * @param pid 人员ID
  2113. * @return
  2114. *
  2115. */
  2116. Boolean isLeader(Long pid) throws BusinessException;
  2117. List<TaskMemberBean> findTaskMembersByTaskIdsAndRelationType(List<Long> taskIds, Integer[] relationTypes)
  2118. throws BusinessException;
  2119. public List<TaskMemberBean> findTaskMembersByTaskIdsAndResourceType(List<Long> taskIds, Integer[] resourceTypes) throws BusinessException;
  2120. /**
  2121. * 领导id和relationType查询包保事项详情
  2122. * @param perId
  2123. * @param key
  2124. * @return
  2125. */
  2126. public List<TaskMemberBean> findTaskMembersByResourceIdsAndRelationType(
  2127. Long perId, int key) throws BusinessException;
  2128. /**
  2129. * 通过事项id查询表JnFgwProjectBean的详情
  2130. * @param id
  2131. * @return
  2132. */
  2133. public JnFgwProjectBean findJnFgwProjectBeanByTaskId(Long id) throws BusinessException;
  2134. /**
  2135. * 领导批示
  2136. * @param id
  2137. * @return
  2138. * @throws BusinessException
  2139. */
  2140. public List<TaskCommandBean> findTaskCommand(Long id) throws BusinessException;
  2141. /**
  2142. * 重点项目展示
  2143. * @return
  2144. */
  2145. public List<JnTaskPublishBean> findAllPublished() throws BusinessException;
  2146. /**
  2147. * 查询最新有效的汇报信息
  2148. * @param taskId
  2149. * @return
  2150. */
  2151. public TaskReportBean findNewestReport4Task(Long taskId) throws BusinessException;
  2152. /**
  2153. * 批量查询最新汇报
  2154. * @param taskIds 事项ID
  2155. * @return key 为事项ID,value为最新汇报
  2156. * @throws BusinessException
  2157. */
  2158. public Map<Long, TaskReportBean> findNewestReport4Task(Collection<Long> taskIds) throws BusinessException;
  2159. /**
  2160. * 根据任务id查询项目
  2161. * @param taskId
  2162. * @return
  2163. * @throws BusinessException
  2164. */
  2165. public JnFgwProjectBean findProjectByTaskId(Long taskId) throws BusinessException;
  2166. /**
  2167. * 根据任务id查询所有有效(非被打回的汇报)汇报图片
  2168. * @param taskId
  2169. * @return
  2170. */
  2171. public List<Map<String, Object>> findReportImgsByTaskId(Long taskId) throws BusinessException;
  2172. /**
  2173. * 通过事项状态tstate查询事项
  2174. * 添加二级查询 by chenx
  2175. * @param i
  2176. * @return
  2177. */
  2178. List<TaskSummaryBean> findAllTaskSummaryBeans(Integer[] i, Integer[] j) throws BusinessException;
  2179. /**
  2180. * 通过承办单位查询其所参与的所有事项
  2181. * @param object
  2182. * @param mstate
  2183. * @return
  2184. */
  2185. List<TaskMemberBean> findTaskMembersByResourceIdAndMstate(Long depId, Integer mstate) throws BusinessException;
  2186. /**
  2187. * 通过id查询事项的所有汇报
  2188. * @param id
  2189. * @return
  2190. * @throws BusinessException
  2191. */
  2192. List<TaskReportBean> findAllTaskReportBean(Long id) throws BusinessException;
  2193. /**
  2194. * 检查事项有无暂存汇报内容
  2195. * @param taskId
  2196. * @return
  2197. * @throws BusinessException
  2198. */
  2199. Boolean findAllHistoryTaskReportBeans(Long[] ids) throws BusinessException;
  2200. /**
  2201. * 通过事项id和部门Id查询事项的所有汇报
  2202. * @param id
  2203. * @param depId
  2204. * @return
  2205. * @throws BusinessException
  2206. */
  2207. List<TaskReportBean> findAllTaskReportBean(Long id, Long departmentId) throws BusinessException;
  2208. /**
  2209. * 通过事项id和部门Id查询事项的所有汇报
  2210. * @param id
  2211. * @param depId
  2212. * @return
  2213. * @throws BusinessException
  2214. */
  2215. List<TaskReportBean> findAllTaskReportBeanBydepartmentIds(Long id, List<Long> departmentId) throws BusinessException;
  2216. /**
  2217. * 根据任务类型查询事项
  2218. * @return
  2219. * @throws BusinessException
  2220. */
  2221. List<TaskSummaryBean> findTaskSummaryBeanByTaskTypeId(Long typeId, Integer[] i) throws BusinessException;
  2222. List<TaskSummaryBean> findTaskSummaryBean(String taskTypeId) throws BusinessException;
  2223. ListObject<TaskSummaryBean> findTaskSummaryBeanByTaskTypeId(Long typeId, Integer[] i, Integer start, Integer range) throws BusinessException;
  2224. /**
  2225. * 根据任务类型name查血任务类型id
  2226. * @param name
  2227. * @return
  2228. */
  2229. TaskTypeBean findTaskTypeBeanByName(String name) throws BusinessException;
  2230. TaskTypeBean findTaskTypeBeanByName(String name, Integer subType) throws BusinessException;
  2231. TaskTypeBean findTaskTypeBeanLikeName(String name, Integer subType) throws BusinessException;
  2232. TaskTypeBean findTaskTypeByNameAndSubType(String name, Integer subType, Long accountId) throws BusinessException;
  2233. TaskTypeBean findTaskTypeByParam(Map<String, Object> map , Long accountId) throws BusinessException;
  2234. /**
  2235. * 根据事项id查询关注信息
  2236. * @param id
  2237. * @return
  2238. * @throws BusinessException
  2239. */
  2240. List<TaskAttention> findDzdbAeeentionsByTaskId(Long id) throws BusinessException;
  2241. /**
  2242. * 添加领导批示
  2243. * @param taskCommandBean
  2244. * @throws BusinessException
  2245. */
  2246. void addTaskCommand(TaskCommandBean taskCommandBean) throws BusinessException;
  2247. TaskSummaryBean findTaskSummaryBeanByIdAndTaskType(Long taskId,
  2248. Long l) throws BusinessException;
  2249. /**
  2250. * 通过事项id和责任单位查询事项的责任单位
  2251. * @param taskId
  2252. * @param key
  2253. * @return
  2254. * @throws BusinessException
  2255. */
  2256. TaskMemberBean findTaskMembersByTaskIdAndRelationType(Long taskId, Integer key) throws BusinessException;
  2257. List<TaskMemberBean> findTaskMembersByTaskIdAndRelType(Long taskId, Integer key) throws BusinessException;
  2258. /**
  2259. * 通过事项id和责任单位查询事项的责任单位
  2260. * @param taskId
  2261. * @param key
  2262. * @return
  2263. * @throws BusinessException
  2264. */
  2265. List<TaskMemberBean> findTaskMembersByTaskIdAndRelationTypes(
  2266. Long taskId, Integer key) throws BusinessException;
  2267. List<TaskMemberBean> findTaskMembersByTaskIdAndRelationTypes(Long taskId, List<Integer> key) throws BusinessException;
  2268. /**
  2269. * 查询事项的进度
  2270. * @return
  2271. * @throws BusinessException
  2272. */
  2273. List<Map<String, Object>> findProcessState() throws BusinessException;
  2274. /**
  2275. * 根据事项id和状态查询事项
  2276. * @param ids
  2277. * @param i
  2278. * @return
  2279. */
  2280. List<TaskSummaryBean> findTaskListByIdsAndTstate(
  2281. java.lang.Long[] ids, Integer[] i) throws BusinessException;
  2282. /**
  2283. * 根据部门和承办查询taskMember
  2284. * @param key
  2285. * @param key2
  2286. * @return
  2287. * @throws BusinessException
  2288. */
  2289. List<TaskMemberBean> findByResourceAndRelation(Integer key, Integer key2) throws BusinessException;
  2290. /**
  2291. * 根据事项id查询事项的督办设置
  2292. * @param taskid
  2293. * @return
  2294. * @throws BusinessException
  2295. */
  2296. TaskReportConfigBean findTaskReportConfigByTaskId(Long taskid) throws BusinessException;
  2297. List<TaskReportConfigBean> findAllTaskReportConfigByTaskId(Long taskId) ;
  2298. /**
  2299. *
  2300. * @param taskid
  2301. * @param key
  2302. * @return
  2303. * @throws BusinessException
  2304. */
  2305. List<TaskProcessSummaryBean> findTaskProcessByTaskIdsAndPtype(
  2306. Long taskid, Integer key) throws BusinessException;
  2307. /**
  2308. * 根据id查询汇报详情
  2309. * @param valueOf
  2310. * @return
  2311. */
  2312. TaskReportBean findTaskReportById(Long id) throws BusinessException;
  2313. List<TaskReportBean> findTaskReportByIds(List<Long> ids) throws BusinessException;
  2314. /**
  2315. * 根据领导id查询级别
  2316. * @param id
  2317. * @return
  2318. * @throws BusinessException
  2319. */
  2320. LeaderShowConfigBean findLeaderConfigBeanByPid(Long id) throws BusinessException;
  2321. void addTaskMember(TaskMemberBean memberBean) throws BusinessException;
  2322. void addTaskMember(List<TaskMemberBean> memberBean) throws BusinessException;
  2323. /**
  2324. * 根据事项id和人员id查询
  2325. * @param valueOf
  2326. * @param personId
  2327. * @return
  2328. */
  2329. List<TaskMemberBean> findTaskMembersByTaskIdsAndPid(Long taskId,
  2330. Long personId);
  2331. List<Long> findTaskMembersByTaskIdsAndPid(List<Long> taskIds,
  2332. Long personId);
  2333. /**
  2334. * 查询重点办的项目
  2335. * @param taskTypelist
  2336. * @return
  2337. */
  2338. List<TaskSummaryBean> findAllTaskSummaryBeanByTypes(
  2339. String[] taskTypelist, Integer[] i);
  2340. /**
  2341. * 查询所有项目(按照投资截至月份排序)
  2342. * @param id
  2343. * @return
  2344. */
  2345. List<TaskReportBean> findAllTaskReportBeanOrderByEndMonth(Long id) throws BusinessException;
  2346. /**
  2347. * 按照月份查询当月的最新汇报
  2348. * @param id
  2349. * @param month
  2350. * @return
  2351. */
  2352. TaskReportBean findNewestReportByMonth(Long id, Integer month) throws BusinessException;
  2353. /**
  2354. * 根据进度ID查询被催办的单位
  2355. * created by huzy 2017/9/20 下午3:17
  2356. * @param id
  2357. * @return
  2358. * @throws BusinessException
  2359. */
  2360. List<OrgUnitBean> findTaskRemindDepartmentByProcessId(Long id) throws BusinessException;
  2361. /**
  2362. * 根据进度ID查询被催办的人员
  2363. * created by huzy 2017/9/20 下午3:17
  2364. * @param id
  2365. * @return
  2366. * @throws BusinessException
  2367. */
  2368. List<OrgPersonBean> findTaskRemindPersonByProcessId(Long id) throws BusinessException;
  2369. /**
  2370. * 查询指定事项成员的汇报数据
  2371. * @param id
  2372. * @param memberPhaseId 事项成员阶段ID
  2373. * @param memberId 事项成员ID
  2374. * @param status
  2375. * @return
  2376. * @throws BusinessException
  2377. */
  2378. List<TaskReportBean> findAllTaskReportBeanTaskId(Long id, Long memberPhaseId, Long memberId, List<Integer> status) throws BusinessException;
  2379. void setScreenScope(Long[] plateIds, String[] scope) throws BusinessException;
  2380. void handleWithOutManagerMemberTask() throws BusinessException;
  2381. void handleWithOutTaskPhaseTask() throws BusinessException;
  2382. /**
  2383. * 更新结束时间
  2384. * @param taskIds 事项ID集合
  2385. * @param endTime 结束时间
  2386. * @param curUserId 操作人
  2387. * @param isSys 是否是系统操作,系统操作就不需要记录日志
  2388. */
  2389. void updateTaskEndTime(List<Long> taskIds, Date endTime, Long curUserId, boolean isSys) throws BusinessException;
  2390. /**
  2391. * 根据事项ID查询该事项所有的附件
  2392. * @param taskId
  2393. * @return
  2394. * @throws BusinessException
  2395. */
  2396. List<Map<String,Object>> findAllTaskFileByTaskId(Long taskId) throws BusinessException;
  2397. List<CommonResourceRelationBean> findAllTaskFileRelationsByTaskIds(List<Long> taskIds,Long accountId) throws BusinessException;
  2398. /**
  2399. * 查询汇报的相关附件 即字段名字为reportFile的附件
  2400. * @param cid 单位ID
  2401. * @param id 汇报ID,来自{@link TaskReportBean#id}
  2402. * @return
  2403. */
  2404. List<SpaceFileBean> findReportFileById(Long cid, Long id) throws BusinessException;
  2405. /**
  2406. * 查询任务所有汇报的相关附件
  2407. * @param cid 单位ID
  2408. * @param taskId 事项
  2409. * @return
  2410. */
  2411. List<SpaceFileBean> findReportFileByTaskId(Long cid,Long taskId) throws BusinessException;
  2412. /**
  2413. * 查询汇报的沟通详情附件(人大政协业务) 即字段名字为detailFile的附件
  2414. * @param cid 单位ID
  2415. * @param id 汇报ID,来自{@link TaskReportBean#id}
  2416. * @return
  2417. */
  2418. List<SpaceFileBean> findReportDetailFileById(Long cid, Long id) throws BusinessException;
  2419. /**
  2420. * 根据事项ID查询事项分类
  2421. * create by huzy 2018/2/9 15:00
  2422. * @param taskId
  2423. * @return
  2424. */
  2425. TaskTypeBean findTaskTypeBeanByTaskId(Long taskId) throws BusinessException;
  2426. TaskTypeBean findTaskTypeBeanByTaskId(Map<String,Object> params) throws BusinessException;
  2427. /**
  2428. * 根据iD查询任务类别
  2429. * create by inspired
  2430. * @param
  2431. * @return
  2432. */
  2433. TaskTypeBean findTaskTypeBeanById(Map<String, Object> params) throws BusinessException;
  2434. /**
  2435. * 根据当前登录和事项ID查询最新汇报
  2436. * @param taskId
  2437. * @param pid
  2438. * @return
  2439. * @throws BusinessException
  2440. */
  2441. TaskReportBean findTaskReportByIdAndCreateBy(Long taskId, Long pid) throws BusinessException;
  2442. /**
  2443. * 补充完整事项留言(也可能是其他的内容 进展情况?
  2444. * @param beans
  2445. * @return
  2446. * @throws BusinessException
  2447. */
  2448. List<TaskProcessBO> fillTaskProcessBOs(List<TaskProcessSummaryBean> beans) throws BusinessException;
  2449. /**
  2450. * 根据汇报类型查询事项配置
  2451. * @param reportType
  2452. * @return
  2453. */
  2454. List<TaskReportConfigBean> findTaskReportConfigByReportType(Integer reportType) throws BusinessException;
  2455. /**
  2456. * 根据父ID查询子任务
  2457. * @param id
  2458. * @return
  2459. */
  2460. List<TaskSummaryBean> findTaskSummaryBeansByParentId(Long id) throws BusinessException;
  2461. List<TaskSummaryBean> findTaskSummaryBeansByParentIds(List<Long> ids) throws BusinessException;
  2462. /**
  2463. * 根据父ID查询子任务(包含未交办)
  2464. * @param id
  2465. * @return
  2466. */
  2467. List<TaskSummaryBean> findTaskSummaryBeansByParentIdTemp(Long id) throws BusinessException;
  2468. List<TaskSummaryBean> findTaskSummaryBeansByParentIdsTemp(Long[] ids) throws BusinessException;
  2469. /**
  2470. * 根据父ID和部门id查询子任务
  2471. * @param id
  2472. * @return
  2473. */
  2474. List<Map<String,Object>> findTaskSummaryBeansByParentIdAndDepartmentId(Long id,Long departmentId,Integer type) throws BusinessException;
  2475. /**
  2476. * 查询当前登录所能查看的消息类型
  2477. * @param personId
  2478. * @return
  2479. */
  2480. ListObject<MessageTypeBean> findMessageTypeBeanByAuthorizedPerson(Integer start, Integer pageSize) throws BusinessException;
  2481. /**
  2482. *根据taskTypeId查找 状态不为删除态的TaskSummaryBean,
  2483. *
  2484. **/
  2485. List<TaskSummaryBean> findByTaskTypeAndDontDelete(String taskTypeId) throws BusinessException;
  2486. Integer findMaxSerialNumByTaskTypeAndIsValid(String taskTypeId) throws BusinessException;
  2487. /**
  2488. *根据taskId查找 事项
  2489. *
  2490. **/
  2491. TaskSummaryBean getTaskSummaryById(Long taskId) throws BusinessException;
  2492. /**
  2493. *根据taskTypeId 和 tstate状态查询 TaskSummaryBean,
  2494. *
  2495. **/
  2496. List<TaskSummaryBean> findByTaskTypeAndDontDelete(List<Long> taskTypeId) throws BusinessException;
  2497. /**
  2498. *检查子任务是否由完成时间和责任单位
  2499. *
  2500. **/
  2501. Boolean checkChildrenTask(Long id) throws BusinessException;
  2502. /**
  2503. * 根据消息类型ID查询详情
  2504. * @param aLong
  2505. * @return
  2506. * @throws BusinessException
  2507. */
  2508. MessageTypeBean findMessageTypeById(Long aLong) throws BusinessException;
  2509. /**
  2510. * 根据
  2511. * @param id
  2512. * @param cancount
  2513. * @return
  2514. * @throws BusinessException
  2515. */
  2516. List<TaskTypeBean> findTaskTypesByParentIdAndCanCount(long parentId, int canCount) throws BusinessException;
  2517. /**
  2518. * 更新没有承办部门的信息
  2519. *
  2520. * */
  2521. void updateNotDeptInfos()throws BusinessException;
  2522. /**
  2523. * 根据成员id集合查找出对应的memberBean
  2524. *
  2525. * */
  2526. List<TaskMemberBean> findTaskMemberByIds(List<Long> memberIds) throws BusinessException;
  2527. /**
  2528. * 更新查看标记
  2529. *
  2530. * */
  2531. void updateTaskSummaryByLookOverFlag(TaskSummaryBean summary, String flag)throws BusinessException;
  2532. /**
  2533. * 根据ID获取当前阶段
  2534. * @param phaseId
  2535. * @return
  2536. * @throws BusinessException
  2537. */
  2538. TaskPhase findTaskPhaseById(Long phaseId)throws BusinessException;
  2539. /**
  2540. * 根据一个阶段获取下一个有效的阶段
  2541. * @author inspired
  2542. * @param config
  2543. * @return
  2544. * @throws BusinessException
  2545. */
  2546. TaskPhaseReportConfig findNextTaskPhaseConfigByConfig(TaskPhaseReportConfig config)throws BusinessException;
  2547. /**
  2548. * 获取事项成员分派的人
  2549. * @author inspired
  2550. * @param taskId
  2551. * @param memberId
  2552. * @return
  2553. * @throws BusinessException
  2554. */
  2555. List<TaskMemberBean> findTaskDispatchMember(Long taskId,Long memberId) throws BusinessException;
  2556. /**
  2557. * 根据ID获取当前阶段
  2558. * @param phaseId
  2559. * @return
  2560. * @throws BusinessException
  2561. */
  2562. List<TaskPhase> findTaskPhaseByIds(List<Long> phaseId)throws BusinessException;
  2563. /**
  2564. * 查询所有的TaskPhase
  2565. * @return 返回一个map结构 key:主键id, value:TaskPhase的Map
  2566. * @throws BusinessException
  2567. *
  2568. */
  2569. Map<Long,TaskPhase> findAllTaskPhaseMap() throws BusinessException;
  2570. /**
  2571. * 查询进行中已超期,单位未办结事项
  2572. * @param key
  2573. * @param key1
  2574. * @return
  2575. * @throws BusinessException
  2576. */
  2577. List<Map<String, Object>> findOverdueNotRunTaskSummary(int key, int key1)throws BusinessException;
  2578. /**
  2579. * 保存members
  2580. * @param saveList 需要保存的member集合
  2581. * @param bossIds if not null execute send message
  2582. * @param summarys if not null execute send message
  2583. *
  2584. * */
  2585. void saveMembers(List<TaskMemberBean> saveList, Long[] bossIds, List<TaskSummaryBean> summarys)throws BusinessException;
  2586. /**
  2587. * @param taskIds
  2588. * @param bossIds
  2589. * @param resourceId
  2590. * */
  2591. Map<Long,List<TaskSummaryBean>> findTaskMemberByTaskIdsAndTypeAndResourceId(Long[] taskIds, Long[] bossIds, Integer resourceType)throws BusinessException;
  2592. /**
  2593. * 撤销推送信息
  2594. *
  2595. * */
  2596. void revokePush(Long[] taskIds, Long[] bossIds, Integer resourceType)throws BusinessException;
  2597. /**
  2598. * 撤销前的检查
  2599. *
  2600. * */
  2601. Map<Long,List<TaskSummaryBean>> checkRevokePush(Long[] taskIds, Long[] bossIds, Integer resourceType)throws BusinessException;
  2602. /**
  2603. * 查找领导关注
  2604. *
  2605. * */
  2606. PageInfo<LeaderFollowVo> findLeaderFollowVos(int start, int pageSize, Long taskType, Long taskId, Long resourceId, boolean isLeader)throws BusinessException;
  2607. /**
  2608. * 查找督察处理记录
  2609. *
  2610. * */
  2611. PageInfo<SupervisionTreatmentVo> findSupervisionTreatmentVos(int start, int pageSize)throws BusinessException;
  2612. /**
  2613. * 查询所有的taskPhaseConfigBean
  2614. *
  2615. * */
  2616. List<TaskPhaseReportConfig> findAllPhaseReportConfig()throws BusinessException;
  2617. /**
  2618. * 查找所有的taskSummaryBean 组装成 Map(taskId,tskSummaryBean)形式
  2619. *
  2620. * @return
  2621. * Map<taskId,tskSummaryBean>
  2622. *
  2623. * */
  2624. Map<Long,TaskSummaryBean> findAllTaskSummaryByMap() throws BusinessException;
  2625. /**
  2626. * 分页查询所有报告模板
  2627. * @param start
  2628. * @param pageSize
  2629. * @return
  2630. */
  2631. ListObject<ReportTemplateBean> findReportTemplateByPageAll(Integer start, Integer pageSize)throws BusinessException;
  2632. /**
  2633. * 新增模板
  2634. * @param templateBean
  2635. * @throws BusinessException
  2636. */
  2637. void addReportTemplate(ReportTemplateBean templateBean)throws BusinessException;
  2638. /**
  2639. * 根据ID查询当前模板详情
  2640. * @param id
  2641. * @return
  2642. * @throws BusinessException
  2643. */
  2644. ReportTemplateBean findReportTemplateById(Long id)throws BusinessException;
  2645. /**
  2646. * 查询所有
  2647. * @return
  2648. * @throws BusinessException
  2649. */
  2650. List<ReportTemplateBean> findReportTemplateByAll()throws BusinessException;
  2651. /**
  2652. * 根据taskId和memberId 查询出memberPhases
  2653. * @param taskId
  2654. * @param memberId
  2655. * @return
  2656. * @throws BusinessException
  2657. */
  2658. List<TaskMemberPhase> findTaskMemberPhaseByTaskIdAndMemberId(Long taskId,Long memberId)throws BusinessException;
  2659. /**
  2660. * 删除模板
  2661. * @param templateId
  2662. * @throws BusinessException
  2663. */
  2664. void deleteReportTemplateById(Long[] templateId)throws BusinessException;
  2665. /**
  2666. * 根据taskid[]与 state[]查找出对应的
  2667. * @param taskIds
  2668. * @param tstate
  2669. * @return state 与 taskIds的映射关系
  2670. */
  2671. Map<Integer,List<TaskSummaryBean>> findTaskSummaryByTaskIdAndTstate(Long[] taskIds,Integer[] tstate)throws BusinessException;
  2672. void updateTaskSummarys(List<TaskSummaryBean> summarys)throws BusinessException;
  2673. PageInfo<SuspendedVo> findSuspendedVos(int start, int pageSize, SuspendedVo bean, List<Long> orgIds)throws BusinessException;
  2674. /**
  2675. * 获取事项查看统计
  2676. * @param taskId
  2677. * @return
  2678. */
  2679. List<Map<String,Object>> findViewCount(String taskId)throws BusinessException;
  2680. /**
  2681. * 获取领导批示统计
  2682. * @param taskId
  2683. * @param personId
  2684. * @return
  2685. */
  2686. List<Map<String,Object>> findInstructionsCount(Long taskId)throws BusinessException;
  2687. /**
  2688. * 获取领导批示和留言的数量
  2689. *
  2690. * @param taskId
  2691. * @param excludedIds
  2692. * @return
  2693. * @throws BusinessException
  2694. */
  2695. List<Map<String,Object>> findInstructionsAndLeavingaMessageCount(Long taskId, List<Long> excludedIds)throws BusinessException;
  2696. /**
  2697. * 获取事项查看相关数据
  2698. * @param taskId 事项id
  2699. * @param type 对应 BehaviorEnum.ViewTask.key
  2700. * @return vo 集合
  2701. */
  2702. List<ViewTaskVo> findViewTaskVos(String taskId, Integer type)throws BusinessException;
  2703. /**
  2704. * 根据事项ID查询当前事项阶段信息
  2705. * @param taskId
  2706. * @return
  2707. * @throws BusinessException
  2708. */
  2709. List<TaskPhase> findTaskPhaseByTaskId(Long taskId)throws BusinessException;
  2710. /**
  2711. * 查询当前事项所有汇总计划
  2712. * @param taskId
  2713. * @param i
  2714. * @return
  2715. * @throws BusinessException
  2716. */
  2717. List<TaskMemberPhase> findTaskMemberPhaseByTaskIdAndType(Long taskId, int i)throws BusinessException;
  2718. /**
  2719. * 修改计划
  2720. * @param phases
  2721. * @throws BusinessException
  2722. */
  2723. void updateTaskPhaseList(List<TaskPhase> phases)throws BusinessException;
  2724. /**
  2725. * 通过id修改阶段计划名称
  2726. * @param phases
  2727. * @throws BusinessException
  2728. */
  2729. void updateTaskPhaseById(String id, String name)throws BusinessException;
  2730. /**
  2731. * 根据事项id与状态stats查询出对应的汇报记录
  2732. * @param taskIds 事项id集合
  2733. * @param status 状态集合
  2734. * @return
  2735. */
  2736. List<TaskReportBean> findTaskReportByTaskIdAndStatus(List<Long> taskIds, List<Integer> status)throws BusinessException;
  2737. /**
  2738. * 根据事项id与状态stats查询出对应的汇报记录
  2739. * @param taskIds 事项id集合
  2740. * @param status 状态集合
  2741. * @return
  2742. */
  2743. List<TaskReportBean> findTaskReportByTaskIdAndStatus(List<Long> taskIds, List<Integer> status, List<Long> deptId)throws BusinessException;
  2744. /**
  2745. *批量汇报上报
  2746. * @param taskIds 事项ids
  2747. * @param cid
  2748. * @param pid
  2749. * @param status 需要更新的状态
  2750. * @param findStatus
  2751. * @throws BusinessException
  2752. */
  2753. List<String> batchReportUp(Long[] taskIds,Long cid, Long pid,Integer status, Integer[] findStatus) throws BusinessException;
  2754. /**
  2755. * 得到授权给指定人员的事项类型
  2756. * @param cid
  2757. * @param pid
  2758. * @return
  2759. */
  2760. List<TaskTypeBean> findTaskTypeByPid(Long cid, Long pid) throws BusinessException;
  2761. /**
  2762. * 根据事项的id查询出事项map (key:事项id,value:事项实体)
  2763. * @param taskIds
  2764. * @return
  2765. */
  2766. Map<Long,TaskSummaryBean> findTaskSummaryByIds(Long [] taskIds)throws BusinessException;
  2767. /**
  2768. * 查询已经超出完成时间的事项
  2769. * @param endDate
  2770. * @return
  2771. * @throws BusinessException
  2772. */
  2773. List<TaskSummaryBean> findTaskSummaryBeanByEndDate(Date endDate);
  2774. /**
  2775. * 查询当前类型所有状态事项
  2776. * @param typeId
  2777. * @param startDate
  2778. * @param endDate
  2779. * @param key
  2780. * @param type
  2781. * @return
  2782. * @throws BusinessException
  2783. */
  2784. List<TaskSummaryBean> findTaskSummarByType(String typeId, Date startDate, Date endDate, int key, Integer type)throws BusinessException;
  2785. /**
  2786. * 更新事项状态
  2787. * @param taskIds
  2788. * @param state
  2789. */
  2790. void updateTaskSummaryStateById(Collection<Long> taskIds, Integer state) throws BusinessException;
  2791. /**
  2792. * 根據ID查詢事項
  2793. * @param taskId
  2794. * @return
  2795. * @throws BusinessException
  2796. */
  2797. List<TaskSummaryBean> findTaskSummaryBeanByIds(List<Long> taskId) throws BusinessException;
  2798. /**
  2799. * 根據ID查詢事項(不含其他条件)
  2800. *
  2801. * @param taskId
  2802. * @return
  2803. * @throws BusinessException
  2804. */
  2805. ListObject<TaskSummaryBean> findTaskSummaryByIds(List<Long> taskId, Integer start, Integer pageSize) throws BusinessException;
  2806. /**
  2807. * 查询当前事项所有承办单位
  2808. * @param id
  2809. * @param key
  2810. * @return
  2811. * @throws BusinessException
  2812. */
  2813. List<TaskMemberBean> findTaskMembersByTaskIdAndRelationTypeAndMstate(Long id, int key) throws BusinessException;
  2814. List<TaskMemberBean> findTaskMembersByTaskIdAndRelationTypeAndMstate(Long id, int key,int mstate) throws BusinessException;
  2815. /**
  2816. * 找出指定成员类型对应状态的事项成员信息
  2817. * @param taskIds 要查找的事项id
  2818. * @param relationType 指定成员类型 {@link TaskEnum.TaskMemberRelTypeEnum}
  2819. * @param mstate 成员办结情况 {@link TaskEnum.TaskMemberStateEnum}
  2820. * @return
  2821. */
  2822. List<TaskMemberBean> findTaskMembersByTaskIdsAndRelationTypeAndMstate(List<Long> taskIds, Integer relationType,Integer mstate) ;
  2823. /**
  2824. * 删除领导关注事项成员
  2825. * @param personId
  2826. * @throws BusinessException
  2827. */
  2828. void deleteLeaderAttentionMember(Long personId,Long taskId,boolean isLeader) throws BusinessException;
  2829. /**
  2830. * 根据事项ID和成员类型成员角色查询
  2831. * @param id
  2832. * @param key
  2833. * @param key1
  2834. * @return
  2835. */
  2836. List<TaskMemberBean> findTaskMembersByTaskIdAndRelationTypeAndResourceType(Long id, int key, int key1);
  2837. Map<String,Object>findTaskPhaseTemplateByTaskType(Long taskTypeId) throws BusinessException;
  2838. /**
  2839. * 统计所有事项的留言和批示数量
  2840. * @param id
  2841. * @return
  2842. * @throws BusinessException
  2843. */
  2844. int countTaskProcessSummaryByTaskId(Long id) throws BusinessException;
  2845. /**
  2846. * 统计留言信息
  2847. * @param id
  2848. * @return
  2849. * @throws BusinessException
  2850. */
  2851. List<Map<String,Object>> findLeavingaMessageCount(Long id) throws BusinessException;
  2852. /**
  2853. * 获取下次需要自增的规则相关
  2854. * @param taskTypeId
  2855. * @return
  2856. * @throws BusinessException
  2857. */
  2858. TaskTypeRule findNextTCode(Long taskTypeId)throws BusinessException;
  2859. /**
  2860. * 根据ID获取当前子阶段
  2861. * @param phaseId
  2862. * @return
  2863. * @throws BusinessException
  2864. */
  2865. TaskPhaseReportConfig findTaskPhaseReportConfigById(Long taskPhaseReportConfigId)throws BusinessException;
  2866. /**
  2867. * 根据事项id和当前人的id查询出事项与当前人的关系,目前只会返回两种,督办与承办.
  2868. * @param taskId 事项id
  2869. * @param cid 圈子id
  2870. * @param pid 当前登录人员的id
  2871. * @return TaskMemberRelTypeEnum
  2872. */
  2873. TaskMemberRelTypeEnum findRelationTypeBySummaryId(Long taskId, Long cid, Long pid)throws BusinessException;
  2874. /**
  2875. * 发送短信
  2876. * @param content 短信类容
  2877. * @param numbers 手机号码
  2878. * @return
  2879. */
  2880. void sendSms(String content,List<String> numbers,String currentUserName);
  2881. /**
  2882. * 发送短信
  2883. * @param summary 事项bean
  2884. * @param context 发送内容
  2885. * @throws BusinessException
  2886. */
  2887. void sendSms(TaskSummaryBean summary, String context) throws BusinessException;
  2888. /**
  2889. * 发送短信
  2890. * @param summarys 事项集合
  2891. * @param context 待发送短信前缀内容 如: 督办交办了 督办批示了 督办催办了 督办办结了
  2892. * @throws BusinessException
  2893. */
  2894. void sendSms(List<TaskSummaryBean> summarys, String context) throws BusinessException;
  2895. /**
  2896. * 上报汇报发送短信
  2897. * @param summarys
  2898. * @param context
  2899. * @throws BusinessException
  2900. */
  2901. void sendSmsForReport(List<TaskSummaryBean> summarys, String context) throws BusinessException;
  2902. /**
  2903. * 催办专用
  2904. * @param deptMaps
  2905. * @param content
  2906. * @throws BusinessException
  2907. */
  2908. void sendSmsByUrge(List<Map<String,Object>> deptMaps, String content)throws BusinessException;
  2909. /**
  2910. * 根据部门集合与人员集合查询出person.若是部门id则查询出的人员是部门联系人
  2911. * @param deptids 非必须
  2912. * @param pids 非必须
  2913. * @return List<OrgPersonBean>
  2914. */
  2915. List<OrgPersonBean> findPersonByDeptAndPid(List<Long> deptids, List<Long> pids)throws BusinessException;
  2916. List<TaskTypeBean> findTaskTypesByParentId(Long taskType) throws BusinessException;
  2917. List<TaskMemberBean> findTaskMembersByTaskIdAndRelationTypeAndResourceType(Long taskId, List<Integer> relationType, List<Integer> resourceType) throws BusinessException;
  2918. List<TaskMemberBean> findTaskMembersByTaskIdAndRelationTypeAndResourceType(List<Long> taskIds, List<Integer> relationType, List<Integer> resourceType) throws BusinessException;
  2919. void updateTaskPhaseReportConfig(List<TaskPhaseReportConfig> list) throws BusinessException;
  2920. /**
  2921. * 批量汇报
  2922. * @param phaseId
  2923. * @return
  2924. * @throws BusinessException
  2925. */
  2926. List<TaskPhaseReportConfig> findTaskPhaseReportConfigByIds(String[] phaseId) throws BusinessException;
  2927. List<TaskReportBean> findAllTaskReportBeanTaskId(Long taskId, Long memberPhaseId, Long memberId, Long departmentId, List<Integer> status) throws BusinessException;
  2928. /**
  2929. * 查询即将超出完成时间的事项
  2930. * @param endDate
  2931. * @return
  2932. * @throws BusinessException
  2933. */
  2934. List<TaskSummaryBean> findExpireTaskSummaryBeanByEndDate(Date endDate)throws BusinessException;
  2935. /**
  2936. * 查询所有状态下的事项
  2937. * @return
  2938. * @throws BusinessException
  2939. */
  2940. List<TaskSummaryBean> findTaskSummaryAll(Integer[] status) throws BusinessException;
  2941. /**
  2942. * 根据事项id查询
  2943. * @param id
  2944. * @return
  2945. * @throws BusinessException
  2946. */
  2947. List<TaskMemberPhaseReportConfig> findTaskMemberPhaseReportConfigByTaskId(Long id) throws BusinessException;
  2948. List<TaskMemberPhaseReportConfig> findTaskMemberPhaseReportConfigByTaskIds(List<Long> ids) throws BusinessException;
  2949. /**
  2950. * 根据ID查询详情
  2951. * @param id
  2952. * @return
  2953. * @throws BusinessException
  2954. */
  2955. TaskMemberPhaseReportConfig findTaskMemberPhaseReportConfigById(long id) throws BusinessException;
  2956. /**
  2957. * 查询当前阶段所有小阶段
  2958. * @param phaseId
  2959. * @return
  2960. * @throws BusinessException
  2961. */
  2962. List<TaskPhaseReportConfig> findTaskPhaseReportConfigByPhaseId(Long phaseId) throws BusinessException;
  2963. /**
  2964. * 查询所有阶段信息
  2965. * @return
  2966. * @throws BusinessException
  2967. */
  2968. List<Map<String, Object>> findTaskMemberPhaseReportConfig() throws BusinessException;
  2969. /**
  2970. * 查询当前人员所选择回报事项
  2971. * @param phaseId
  2972. * @return
  2973. * @throws BusinessException
  2974. */
  2975. List<TaskMemberPhaseReportConfig> findTaskMemberPhaseReportConfigByTaskIdAndPhaseId(Long[] phaseId,Long taskId) throws BusinessException;
  2976. TaskMemberPhaseReportConfig findTargetTaskMemberPhaseReportConfig(Long taskId,Long phaseId,Long memberId,Long phaseReportConfigId);
  2977. /**
  2978. * 更新汇报状态
  2979. * @param list
  2980. * @throws BusinessException
  2981. */
  2982. void updateTaskMemberReportConfig(List<TaskMemberPhaseReportConfig> list) throws BusinessException;
  2983. /**
  2984. * 处理未在阶段中存在的事项
  2985. * @return 返回值为事项ID集合
  2986. */
  2987. List<Map<String, Object>> findTaskMemberPhaseReportConfigByAll() throws BusinessException;
  2988. /**
  2989. * 根据事项ID查询所有小阶段信息
  2990. * @return
  2991. * @throws BusinessException
  2992. */
  2993. List<TaskPhaseReportConfig> findTaskPhaseReportConfigByTaskId(Long taskId,Long phaseId) throws BusinessException;
  2994. List<TaskPhaseReportConfig> findTaskPhaseReportConfigByTaskId(Long taskId) throws BusinessException;
  2995. /**
  2996. * 根据事项ID查询阶段信息
  2997. * @param taskId
  2998. * @return
  2999. * @throws BusinessException
  3000. */
  3001. List<TaskMemberPhase> findTaskMemberPhaseByTaskId(Long taskId) throws BusinessException;
  3002. /**
  3003. * 查询某成员阶段是否已汇报
  3004. * @param taskId
  3005. * @param id
  3006. * @return
  3007. * @throws BusinessException
  3008. */
  3009. TaskReportBean findTaskReportByTaskIdAndReportId(Long taskId, Long id, Long memberId) throws BusinessException;
  3010. /**
  3011. * inspired 根据成员阶段获取最新汇报的情况
  3012. */
  3013. TaskReportBean findNewTaskReportByTaskMemberPhaseReportConfig(TaskMemberPhaseReportConfig bean);
  3014. /**
  3015. * 获取除开暂存汇报之外的最近的一次汇报内容
  3016. * @author inspired
  3017. * @param bean
  3018. * @return TaskReportBean
  3019. */
  3020. TaskReportBean findPrevTaskReportByTaskMemberPhaseReportConfig(TaskMemberPhaseReportConfig bean);
  3021. /**
  3022. * 根据事项状态查询
  3023. * @param key
  3024. * @return
  3025. * @throws BusinessException
  3026. */
  3027. List<TaskSummaryBean> findTaskSummaryBeanByTstate(Integer[] key) throws BusinessException;
  3028. /**
  3029. * 根据小阶段和MemberID查询当前人员的该阶段信息
  3030. * @param reportConfigId
  3031. * @param memberId
  3032. * @return
  3033. * @throws BusinessException
  3034. */
  3035. TaskMemberPhaseReportConfig findTaskMemberPhaseReportConfigByReportIdAndMemberId(Long reportConfigId, Long memberId) throws BusinessException;
  3036. /**
  3037. * 根据时间查询当前登录人的事项 -- 日程首页使用
  3038. * @param keyParam
  3039. * @return
  3040. * @throws BusinessException
  3041. */
  3042. List<TaskSummaryBean> findTaskSummaryBeanForschedule(Map<String,Object> keyParam) throws BusinessException;
  3043. /**
  3044. * 查询已经超出完成时间的事项
  3045. * @return
  3046. * @throws BusinessException
  3047. */
  3048. List<TaskSummaryBean> findTaskSummaryBeanByEndDateNew()throws BusinessException;
  3049. /**
  3050. * 查询即将超出完成时间的事项
  3051. * @return
  3052. * @throws BusinessException
  3053. */
  3054. List<TaskSummaryBean> findExpireTaskSummaryBeanByEndDateNew()throws BusinessException;
  3055. /**
  3056. * 根据事项ID和人员ID查询
  3057. * @param id
  3058. * @param departIdList
  3059. * @return
  3060. * @throws BusinessException
  3061. */
  3062. List<TaskMemberBean> findTaskmemberByTaskIdAndResourceId(Long id, List<Long> departIdList)throws BusinessException;
  3063. List<TaskMemberBean> findTaskmemberByTaskIdAndResourceId(Long id, Long departId)throws BusinessException;
  3064. List<TaskMemberBean> findTaskmemberByTaskIdsAndResourceId(List<Long> ids, Long departId)throws BusinessException;
  3065. /**
  3066. * 根据事项ID 和事项成员ID 和 阶段ID 修改事项成员阶段汇报状态(如果所有事项成员都汇报那么则修改事项汇报状态为已汇报)
  3067. *
  3068. * @param report@throws BusinessException
  3069. */
  3070. void updateTaskMemberPhaseReportConfigByTaskIdAndMemberIdAndPhaseId(TaskReportBean report, Integer isReport)throws BusinessException;
  3071. /**
  3072. * 根据阶段ID修改阶段汇总状态
  3073. * @param phaseId
  3074. * @param isReport
  3075. * @throws BusinessException
  3076. */
  3077. void updateTaskPhaseIsGatherById(Long phaseId, Integer IsGather)throws BusinessException;
  3078. void deleteTaskPhaseById(Long phaseId) throws BusinessException;
  3079. /**
  3080. * 查询汇总为进展滞后的事项
  3081. * @param key
  3082. * @param key1
  3083. * @return
  3084. */
  3085. List<TaskSummaryBean> findTasksummaryBeanByReportStateAndTstate(Integer key, Integer key1);
  3086. /**
  3087. * 这个地方是用来在督办立项的时候交办修改了阶段信息做处理的
  3088. * @param taskId
  3089. * @throws BusinessException
  3090. */
  3091. void deleteTaskmemberPhaseReportConfigByTaskId(Long taskId)throws BusinessException;
  3092. /**
  3093. * @author inspired (胡启林)
  3094. * @param
  3095. * @describe 删除指定资源
  3096. * @createTime 2021/5/13 16:33
  3097. */
  3098. void deleteTaskMemberPhaseReportConfig(Long taskId, Long memberId, Long phaseId)throws BusinessException;
  3099. /**
  3100. * 根据事项ID成员ID查询最新的汇报信息
  3101. * 如果查询最新已经通过的汇报,这个接口尽量不要使用,因此已经通过的数据状态只能是通过和历史状态
  3102. * 如果需要查询最新已经通过的汇报请调用接口findTaskReportByMemberIdAndTaskId
  3103. * @param taskId
  3104. * @param id
  3105. * @return
  3106. * @throws BusinessException
  3107. */
  3108. TaskReportBean findTaskReportByTaskIdAndMemmberId(Long taskId, Long id)throws BusinessException;
  3109. /**
  3110. * 根据类型ID查询
  3111. * @param taskType
  3112. * @return
  3113. * @throws BusinessException
  3114. */
  3115. boolean getTaskTypeByIds(Long[] taskType)throws BusinessException;
  3116. /**
  3117. * 根据事项ID查询
  3118. * @param taskIds
  3119. * @return
  3120. * @throws BusinessException
  3121. */
  3122. List<Map<String, Object>> findTaskMemberByTaskIds(String taskIds)throws BusinessException;
  3123. /**
  3124. * 根据ID查询类型
  3125. * @param taskCategory
  3126. * @return
  3127. * @throws BusinessException
  3128. */
  3129. TipEnumBean getTipEnumById(Long taskCategory)throws BusinessException;
  3130. /**
  3131. * 根据事项ID查询所有任务类型并去重复
  3132. * @param taskIds
  3133. * @return
  3134. * @throws BusinessException
  3135. */
  3136. List<Map<String, Object>> findTipEnumByIds(String taskIds)throws BusinessException;
  3137. /**
  3138. * 定时器接口
  3139. * @return
  3140. * @throws BusinessException
  3141. */
  3142. List<Map<String, Object>> findTaskMemberByReprotStaus()throws BusinessException;
  3143. /**
  3144. * 定时器接口
  3145. * @return
  3146. * @throws BusinessException
  3147. */
  3148. void updateTaskMemberBySummaryState(Integer unitState, Integer overdue)throws BusinessException;
  3149. /**
  3150. * 定时器接口
  3151. * @param unitState
  3152. * @param overdue
  3153. * @throws BusinessException
  3154. */
  3155. void updateTaskFromSlowToNormal()throws BusinessException;
  3156. /**
  3157. * 根据事项ID和角色类型查询
  3158. * @param taskId
  3159. * @param key
  3160. * @return
  3161. * @throws BusinessException
  3162. */
  3163. String findTaskMemberByTaskIdAndRelationType(Long taskId, Integer key)throws BusinessException;
  3164. String findMemberIdsByTaskIdAndRelationType(Long taskId, Integer key)throws BusinessException;
  3165. String findTaskMemberByTaskIdAndRelationTypes(Long taskId, Integer[] key)throws BusinessException;
  3166. /**
  3167. *
  3168. * @param taskId
  3169. * @param parseLong
  3170. * @param key
  3171. * @return
  3172. */
  3173. List<TaskMemberBean> findTaskmemberByTaskIdAndResourceIdAndRelationType(Long taskId, Long parseLong, int key)throws BusinessException;
  3174. List<TaskMemberBean> findTaskmemberByTaskIdAndResourceIdAndRelationType(Long taskId, List<Long> parseLong, int key)throws BusinessException;
  3175. List<TaskMemberBean> findTaskmemberByTaskIdAndResourceIdAndRelationTypes(Long taskId, List<Long> parseLong, List<Integer> keys)throws BusinessException;
  3176. TaskMemberBean findTaskMemberBySummaryIdAndResourceIdAndRelationType(Long taskId, Long parseLong, int key)throws BusinessException;
  3177. /**
  3178. * 获取父任务信息
  3179. * @param taskId
  3180. * @return
  3181. * @throws BusinessException
  3182. */
  3183. TaskSummaryBean findTaskSummaryBeanBySonId(Long taskId)throws BusinessException;
  3184. /**
  3185. * 查询事项成员
  3186. * @param taskId
  3187. * @param relationKeys
  3188. * @param pid
  3189. * @return
  3190. */
  3191. List<TaskMemberBean> findTaskMembersByTaskIdWithRelationTypeAndPid(Long taskId, List<Integer> relationKeys, Long pid) throws BusinessException, SQLException;
  3192. Map<Long,List<TaskMemberBean>> findTaskMembersByTaskIdWithRelationTypeAndPid(List<Long> taskId, List<Integer> relationKeys, Long pid) throws BusinessException, SQLException;
  3193. /**
  3194. * 根据事项ID和成员ID查询是否存在阶段信息
  3195. * @param taskId
  3196. * @param id
  3197. * @return
  3198. */
  3199. List<TaskMemberPhaseReportConfig> findTaskMemberPhaseReportConfigByTaskIdAndMemberId(Long taskId, Long id) throws BusinessException;
  3200. /**
  3201. * 查询列表图形统计
  3202. * @param bean
  3203. * @return
  3204. */
  3205. ListStatisticsVo getListStatisticsCount(Integer listType, String taskTypeId, String year) throws BusinessException;
  3206. List<TaskSummaryTemporaryBean> findAllTaskSummaryAndSonTask(Long taskId,Long pid) throws BusinessException;
  3207. /**
  3208. * 主要用于查询列表中具体台账具体状态下的操作配置
  3209. * @param params
  3210. * @return
  3211. * @throws BusinessException
  3212. */
  3213. List<Map<String,Object>> findListStatusSetByParams(Map<String,Object> params)throws BusinessException;
  3214. /**
  3215. * 查询指定人指定任务类型下指定台账的设置,最多两条数据
  3216. * @param pid
  3217. * @param taskTypeId
  3218. * @param listType
  3219. * @return
  3220. * @throws BusinessException
  3221. */
  3222. PersonListSetBean findPersonListSetByPidAndTaskTypeIdAndListTypeAndSetType(Long pid, Long taskTypeId, Integer listType,Integer setType)throws BusinessException;
  3223. /**
  3224. * 删除状态设置
  3225. * @param listStatusSetBeans
  3226. * @throws BusinessException
  3227. */
  3228. void deleteListStatusSet(List<ListStatusSetBean> listStatusSetBeans)throws BusinessException;
  3229. void saveOrUpdatePersonListSet(List<PersonListSetBean> personListSet)throws BusinessException;
  3230. void saveOrUpdateListstatusSet(List<ListStatusSetBean> listStatusSet)throws BusinessException;
  3231. List<ListStatusSetBean> findListStatusSetByListSetIdAndListStatus(Long id, Integer listStatus)throws BusinessException;
  3232. List<TemplateFileBean> findTemplateFileBeansByCriterion(Criterion cr, Integer start, Integer pageSize)throws BusinessException;
  3233. void addTemplateFileBean(TemplateFileBean templateFile)throws BusinessException;
  3234. void saveOrupdateTemplateFileBean(List<TemplateFileBean>templateFiles)throws BusinessException;
  3235. TemplateFileBean findTemplateFileBeanById(Long id)throws BusinessException;
  3236. List<TemplateFileBean> findTemplateFileBeansByTaskTypeIdAndType(Long taskTypeId,Integer type)throws BusinessException;
  3237. String findTaskMemberNameByTaskIdAndRelationType(Long summaryId, int key)throws BusinessException;
  3238. /**
  3239. * 查询某个事项某个成员最新汇报信息
  3240. * @param summaryId
  3241. * @param memberId
  3242. * @return
  3243. * @throws BusinessException
  3244. */
  3245. TaskReportBean findNewTaskReportByTaskIdAndMemberId(Long summaryId, Long memberId)throws BusinessException;
  3246. TaskReportBean findNewTaskReportByTaskIdAndMemberIdAndConfigId(Long summaryId, Long memberId, Long phaseReportConfigId)throws BusinessException;
  3247. TaskPhaseTemplate findTaskPhaseTemplateByCriterion(Criterion c)throws BusinessException;
  3248. List<TaskListTemplateBean> findTaskListTemplateByCriterion(Criterion c)throws BusinessException;
  3249. /**
  3250. *
  3251. *根据任务列表进行分页数据
  3252. */
  3253. ListObject<TaskListTemplateBean> findTaskListTemplate(Criterion c)throws BusinessException;
  3254. List<TaskListTmpColRelBean> findTemplateColsByTemplateId(long id)throws BusinessException;
  3255. /**
  3256. * 获取事项默认阶段(非当前阶段)
  3257. * @author inspired
  3258. * @param referenceId
  3259. * @return
  3260. */
  3261. TaskPhase getDefaultPhaseByTaskId(Long referenceId)throws BusinessException;
  3262. /**
  3263. * 获取事项当前阶段(与当前时间对应)
  3264. * @author inspired
  3265. * @param taskId
  3266. * @return
  3267. */
  3268. TaskPhase getNowTaskPhaseByTaskId(Long taskId);
  3269. void saveOrUpdateAll(List<Object> taskProcessSummaryBeans)throws BusinessException;
  3270. Map<String, Integer> countTaskSummaryByRootDep(Map<String, Object> params) throws BusinessException;
  3271. boolean saveOrUpdateTaskSummary(TaskSummaryBean taskSummaryBean);
  3272. /**
  3273. * 查询该任务相关文件
  3274. * @param id
  3275. * @param params 参数条件
  3276. * @return
  3277. * @throws BusinessException
  3278. */
  3279. List<Map<String, Object>> findSpaceFilesByResourceIdsAndParams(List<Long> ids, Map<String, Object> params)throws BusinessException;
  3280. /**
  3281. * 查询正常的和历史的汇报
  3282. * @param taskId
  3283. * @param id
  3284. * @param configId
  3285. * @return
  3286. * @throws BusinessException
  3287. */
  3288. TaskReportBean findNewTaskReportByTaskIdAndMemmberIdAndConfigId(Long taskId, Long id, Long configId)throws BusinessException;
  3289. /**
  3290. * 查询汇报
  3291. * @param ci
  3292. * @return
  3293. * @throws BusinessException
  3294. */
  3295. List<TaskReportBean> findTaskReportByCriterion(Criterion ci)throws BusinessException;
  3296. /**
  3297. * 查询类型
  3298. * @param ci
  3299. * @return
  3300. * @throws BusinessException
  3301. */
  3302. List<TaskTypeBean> findTaskTypeByCriterion(Criterion ci)throws BusinessException;
  3303. /**
  3304. * 是否未事项承办单位,督办,协办,返回memberId
  3305. * @param pid
  3306. * @param taskId
  3307. * @return
  3308. * @throws BusinessException
  3309. */
  3310. List<Long> isTaskManager(Long pid, Long taskId,List<Integer> type)throws BusinessException;
  3311. TaskMemberBean getTaskRoleMember(Long pid, Long taskId,Integer type)throws BusinessException;
  3312. /**
  3313. * 此人在事项中成员角色,主要用于前端获取,其他地方需要请在map中继续封装数据
  3314. * @param taskId
  3315. * @return
  3316. * @throws BusinessException
  3317. */
  3318. Map<String,Object> hasTaskPower(Long taskId,List<Integer> type)throws BusinessException;
  3319. List<Map<String, Object>> findTaskSummaryVideoListByParams(Map<String, Object> params)throws BusinessException;
  3320. List<Map<String, Object>> findTaskSummaryVideoList(Map<String, Object> params)throws BusinessException;
  3321. /**
  3322. * 获取指定人员督办事项数量
  3323. *@param ids 人员ID集合
  3324. * @return
  3325. * @throws BusinessException
  3326. */
  3327. Map<String,Integer> getTaskCountByPersonId(Long [] ids) throws BusinessException;
  3328. /**
  3329. * 获取指定部门所有督办事项数量
  3330. * @param depId 部门ID
  3331. * @return
  3332. * @throws BusinessException
  3333. */
  3334. Map<String,Integer> getTaskCountByDepId(long depId) throws BusinessException;
  3335. /**
  3336. * 获取指定人员督办事项类型及事项数量
  3337. * @param personId 人员ID
  3338. * @return
  3339. * @throws BusinessException
  3340. */
  3341. List<Map<String,Object>> getTaskTypesByPersonId(long personId) throws BusinessException;
  3342. /**
  3343. * 获取指定部门督办事项类型及事项数量
  3344. * @param depId 部门ID
  3345. * @return
  3346. * @throws BusinessException
  3347. */
  3348. List<Map<String,Object>> getTaskTypesByDepId(long depId) throws BusinessException;
  3349. List<String> findAllTaskTypeByOther(List<Long> resourceIds)throws BusinessException;
  3350. /**
  3351. * 插入事项修改serial_num
  3352. */
  3353. void updateSerialNum(Integer serialNum)throws BusinessException;
  3354. /**
  3355. * 查询某个memberId的最新汇报(已通过的)
  3356. * @param memberId
  3357. * @param taskId
  3358. * @return
  3359. */
  3360. TaskReportBean findTaskReportByMemberIdAndTaskId(Long memberId, Long taskId)throws BusinessException;
  3361. /**
  3362. * 查询某个memberId,某个阶段的最新汇报(已通过的)
  3363. * @param memberId
  3364. * @param taskId
  3365. * @return
  3366. */
  3367. TaskReportBean findTaskReportByMemberIdAndTaskIdAndPhaseId(Long memberId, Long taskId, Long phaseId)throws BusinessException;
  3368. List<TaskReportBean> findTaskReportByMemberIdsAndTaskIdAndPhaseId(List<Long> memberIdList, Long taskId, Long phaseId)throws BusinessException;
  3369. Map<Long, TaskReportBean> findTaskReportByMemberIdAndTaskIdMap(List<Long> memberId, Long taskId)throws BusinessException;
  3370. /**
  3371. * 签收任务自动签收该任务下子任务
  3372. * @param id
  3373. */
  3374. void signatureTaskSon(Long id) throws BusinessException;
  3375. Map<String,Object> findTaskOrgBeanbyId(Map<String,Object> params)throws BusinessException;
  3376. /**
  3377. * 查询该任务下的子任务事项的基本信息和最新汇报信息,传个pid,因为多线程调用无法获取到pid,
  3378. * 如果没有多线程的影响,pid直接传null也是可以的
  3379. *
  3380. */
  3381. List<Map<String, Object>> findSonTaskSummaryByTaskId(Long id,Long pid)throws BusinessException;
  3382. /**
  3383. * 查询当前人员承办事项的所有领导批示
  3384. * @param start
  3385. * @param pageSize
  3386. * @return
  3387. * @throws BusinessException
  3388. */
  3389. PageInfo<Map<String,Object>> findLeaderDraftDataByPid( Integer start, Integer pageSize) throws BusinessException;
  3390. List<TaskSummaryBean> findTaskSummaryBeanByReference(Long reference, Long subReference) throws BusinessException;
  3391. /**
  3392. * @desc 获取指定事项下指定附件类型的所有附件
  3393. * @author mssql
  3394. * @date 2019/10/8
  3395. * @param taskIds 事项id集合
  3396. * @param fileTypes 附件类型集合
  3397. * @return
  3398. */
  3399. List<Map<String,Object>> getEnclosureListByTaskIdsAndFileTypes(List<Long> taskIds,String [] fileTypes) throws BusinessException;
  3400. /**
  3401. * @desc 汇总附件
  3402. * @date 2019/10/9
  3403. */
  3404. Map<String,Object> collectAnnex(List<Long> annexIds) throws BusinessException;
  3405. /**
  3406. * 分页获取指定部门督办事项列表
  3407. * @param taskTypeId 任务类型ID
  3408. * @param isKeyProject 是否查询类型为重大项目的任务类型
  3409. * @return
  3410. * @throws BusinessException
  3411. */
  3412. ListObject<TaskSummaryBean> pagedTaskSummarysByTaskTypeIdAndPids(long taskTypeId,boolean isKeyProject,String type,Long [] pids,int start,int range) throws BusinessException;
  3413. /**
  3414. * 获取指定人员督办事项数量
  3415. * @param pids 人员ID集合
  3416. * @param type finish:已完成 overdue:已超期 leaderAssigned:领导批示 leaderFollow:领导关注 传入null查全部
  3417. * @param isKeyProject 是否查询任务类型为重大项目
  3418. * @return
  3419. * @throws BusinessException
  3420. */
  3421. ListObject<TaskSummaryBean> getTaskCountByPersonIds(Long [] pids,String type,boolean isKeyProject,int start, int range) throws BusinessException;
  3422. /**
  3423. * 获取指定人员督办事项数量
  3424. * @param pids 人员ID集合
  3425. * @param type finish:已完成 overdue:已超期 leaderAssigned:领导批示 leaderFollow:领导关注 传入null查全部
  3426. * @param isKeyProject 是否查询任务类型为重大项目
  3427. * @return
  3428. * @throws BusinessException
  3429. */
  3430. int getTaskCountByPersonIds(Long [] pids,String type,boolean isKeyProject) throws BusinessException;
  3431. /**
  3432. *
  3433. * @param summaryBeans
  3434. * @throws BusinessException
  3435. * @describe 把summary的集合的第一个作为其他的父任务
  3436. */
  3437. void firstAsParentInSummaries(List<TaskSummaryBean> summaryBeans) throws BusinessException;
  3438. /**
  3439. *
  3440. * @param parentTaskId
  3441. * @param childTaskId
  3442. * @throws BusinessException
  3443. * @describe 保存事项父子关系
  3444. */
  3445. void saveTaskFatherSonRel(Long parentTaskId,Long childTaskId)throws BusinessException;
  3446. String findOrgNameByTaskMembrId(Long memberId)throws BusinessException;
  3447. /**
  3448. * 生成任务,公共接口,任何转督办都可以使用
  3449. * @param info
  3450. * @param fileId
  3451. * @param cid
  3452. * @param pid
  3453. */
  3454. void addDraftData(Map<String, Object> info, Long fileId, Long cid, Long pid,Integer num)throws BusinessException;
  3455. /**
  3456. * 湖北目标通知锁定操作
  3457. * @param id
  3458. * @throws BusinessException
  3459. */
  3460. Map<String, Object> editTaskTargetStatus(Long id, Integer status) throws BusinessException;
  3461. /**
  3462. * 处理督办首页统计效率问题独有
  3463. * @param summaryBeans
  3464. * @param expireCounts
  3465. * @param overdueCounts
  3466. * @param unSign
  3467. * @param ycq
  3468. * @param taskIds
  3469. * @param jjcq
  3470. * @param unReport
  3471. * @throws BusinessException
  3472. */
  3473. void dealSearchForPortal(List<TaskSummaryBean> summaryBeans,List<Integer> expireCounts,List<Integer> overdueCounts,Set<Long>unSign,Set<Long> ycq,Set<Long> taskIds,Set<Long> jjcq,Set<Long> unReport) throws BusinessException;
  3474. TaskTypeRelationBean findTaskTypeRelationBeanByTaskId(Long id)throws BusinessException;
  3475. void updateTaskPhaseInfo(List<TaskPhase> taskPhase, List<Long> subTasks,TaskBO bo,Boolean flag)throws BusinessException;
  3476. Map<String, Object> findTaskmemberInfoByTaskIdAndResourceId(Long id, Long personId)throws BusinessException;
  3477. TaskMemberPhase findTaskMemberPhaseByTaskIdAndMemberIdAndPhaseId(Long taskId, Long memberId, Long id)throws BusinessException;
  3478. TaskMemberPhaseReportConfig findTaskMemberPhaseReportConfigByMemberPhaseIdAndConfigId(Long memberPhaseId,Long id)throws BusinessException;
  3479. /**
  3480. * 查询该任务类型所配页签
  3481. * @param taskType
  3482. * @return
  3483. */
  3484. List<Map<String, Object>> findPlugListByTaskType(Long taskType,Long id,Long pid) throws BusinessException;
  3485. /**
  3486. * 办结操作增加验证机制,判断事项是否都汇报,是否都汇报成已完成,如果没有则给出明确的提示
  3487. * 如:A事项存在单位1,单位2未汇报,且单位3汇报状态未选已完成,B事项存在村咋单位4未汇报,
  3488. * C事项存在...等
  3489. * @param id
  3490. * @return
  3491. * @throws BusinessException
  3492. */
  3493. Map<String,Object> checkTaskIsOver(String id)throws BusinessException;
  3494. //是否已办结
  3495. Map<String,Object> checkTaskIsOverByIds(String ids)throws BusinessException;
  3496. /**
  3497. * @author inspired (胡启林)
  3498. * @param
  3499. * @describe 获取当前单位能统计,且挂在树上的指定类型
  3500. * @createTime 2021/5/12 16:29
  3501. */
  3502. List<TaskTypeBean> findCanCountTaskTypeBeanByNeedShowTree(Integer subType,Long accountId)throws BusinessException;
  3503. /**
  3504. * @author inspired (胡启林)
  3505. * @param
  3506. * @describe 批量催办 查询未签收,未汇报,即将超期,已超期的 memberIds
  3507. * @createTime 2021/4/22 13:45
  3508. */
  3509. List<String> findTaskMemberResourceIdsByParams(String flag, Map<String, Object> param)throws BusinessException;
  3510. /**
  3511. * 根据事项ID查询所有汇报ID
  3512. * @param id
  3513. * @return
  3514. * @throws BusinessException
  3515. */
  3516. List<Long> findTaskReportByTaskId(Long id)throws BusinessException;
  3517. List<TaskReportBean> findAllTaskReportByTaskId(Long taskId)throws BusinessException;
  3518. List<TaskSummaryBean> findTaskSummaryByParam(Map<String, Object> param)throws BusinessException;
  3519. /**
  3520. * 查询这些任务涉及到的牵头单位和责任单位,主要用于会议模式主子任务成员同步
  3521. * 返回结果Map<String,Object>:key:managerIds:所有子任务牵头单位集合 managerNames:牵头单位姓名
  3522. * 返回结果Map<String,Object>:key:participantIds:所有子任务责任单位集合 participantNames:责任单位名称
  3523. * @param taskIds
  3524. * @return
  3525. * @throws BusinessException
  3526. */
  3527. Map<String,Object> findTaskMemberList(String taskIds,String remark)throws BusinessException;
  3528. List<TaskTypeBean> findSubFrom(Long from) throws BusinessException;
  3529. List<TaskTypeBean> findSubFromById(Long from) throws BusinessException;
  3530. List<TaskTypeBean> findAllTaskType() throws BusinessException;
  3531. List<TaskTypeBean> findAllTaskTypeByAccountId(@NonNull Long orgAccountId) throws BusinessException;
  3532. List<BehSummaryBean> findByBehTypeAndTaskid(String resId, Integer resType, String ext1) throws BusinessException;
  3533. /**
  3534. * 根据类型查询(目标绩效使用)
  3535. * @param key
  3536. * @return
  3537. * @throws BusinessException
  3538. * @deprecated 使用 {@link #findTaskTypeBeansBySubType(Integer,Long)}
  3539. */
  3540. @Deprecated
  3541. List<Map<String, Object>> findTaskTypeBeanBySubType(int key) throws BusinessException;
  3542. List<Map<String, Object>> findTaskTypeBeanBySubTypeAndEqParentId(int key,TaskTypeBean typebean,Long taskTypeId) throws BusinessException;
  3543. /**
  3544. * 初始化类型树,其实是用的 findTaskTypeBeanBySubTypeAndEqParentId()方法,本方法只做了更方便的查询封装
  3545. * @param params taskType -> 要查找的类型id remark -> 要查找的类型备注(起到的作用大概是模糊查询)
  3546. * 参数二传一即可,一个不传就报错
  3547. * subType -> {@link TaskEnum.TaskTypeSub}
  3548. * @return 适配前端ztree组件的数据结果集
  3549. * @throws BusinessException
  3550. */
  3551. List<Map<String, Object>> findTypeTree(Map<String,Object> params) throws BusinessException;
  3552. List<Map<String, Object>> findTaskTypeBeanBySubTypeAndNeparendtId(int key,Long parentId) throws BusinessException;
  3553. List<TaskListTmpColRelBean> findListColumn(Long key) throws BusinessException;
  3554. /**
  3555. * 查询字段名
  3556. * @param tableName 需要查询的表明
  3557. * @param columnId 查询的iD
  3558. * @return
  3559. * @throws BusinessException
  3560. */
  3561. String findMatrixTableByColumnId(String tableName, Long columnId) throws BusinessException;
  3562. /**
  3563. * 查询当前类型下所有子任务
  3564. * @param typeId
  3565. * @return
  3566. * @throws BusinessException
  3567. */
  3568. List<TaskTypeBean> findTaskTypeBeanByParentId(Long typeId) throws BusinessException;
  3569. List<TaskTypeBean> findTaskTypeBeanByParentAndSuType(Long parentId,Integer subType) throws BusinessException;
  3570. /**
  3571. * 根据类型枚举和状态查询
  3572. * @param subType
  3573. * @param status
  3574. * @return
  3575. * @throws BusinessException
  3576. */
  3577. List<TaskTypeBean> findTaskTypeBeanBySubTypeAndStatus(int subType, int status) throws BusinessException;
  3578. /**
  3579. * @author inspired (胡启林)
  3580. * @param
  3581. * @describe 处理成员汇报预警状态
  3582. * @createTime 2020/9/8 14:27
  3583. */
  3584. void processTaskExpiresData(List<TaskMemberPhaseReportConfig> configs) throws BusinessException;
  3585. /**
  3586. * @author inspired (胡启林)
  3587. * @param summaries
  3588. * @param lampStatus {@link TaskEnum.TaskDynamicLampStatusEnum}
  3589. * @describe 处理动态监控数据, 超期(传 0)和即将超期(传 1)时处理
  3590. * @createTime 2020/9/9 14:27
  3591. */
  3592. void processTaskDynamicMonitoring(List<TaskSummaryBean> summaries, Integer lampStatus);
  3593. List<OrgPersonBean> getReciprocal4Task(Long taskId, Integer taskMemberRelType) throws BusinessException;
  3594. /**
  3595. * 根据父级ID和类型查询
  3596. * @param subType
  3597. * @param parentId
  3598. * @return
  3599. * @throws BusinessException
  3600. */
  3601. TaskTypeBean findTaskTypeBeanBySubTypeAndParentId(int subType, Long parentId) throws BusinessException;
  3602. /**
  3603. * 保存事项模板跟采集表模板的关联关系
  3604. * @param collectionTempId
  3605. * @param taskIds
  3606. * @throws BusinessException
  3607. */
  3608. void saveTaskTempRel(Long collectionTempId,List<Long> taskIds) throws BusinessException;
  3609. /**
  3610. * 通过任务模板id查询关联关系
  3611. * @param taskId
  3612. * @return
  3613. * @throws BusinessException
  3614. */
  3615. TaskRelationship findTaskRelationshipByTaskId(Long taskId) throws BusinessException;
  3616. /**
  3617. * 根据ID查询所有类型数据
  3618. * @param targetTypeId
  3619. * @return
  3620. * @throws BusinessException
  3621. */
  3622. List<TaskTypeBean> findTaskTypebeanByIds(String targetTypeId) throws BusinessException;
  3623. Map<String,Object> batchToDraft(List<Long> taskIds) throws BusinessException;
  3624. /**
  3625. * 通过模板id查询事项
  3626. * @param tempIds 事项的模板的id
  3627. * @return
  3628. * @throws BusinessException
  3629. */
  3630. List<TaskSummaryBean> findTaskSummaryByTempIds(List<Long> tempIds) throws BusinessException;
  3631. /**
  3632. * 领导首页督察督办 - 我的关注 台账
  3633. * @param pageInfo 分页情况
  3634. * @param map 可扩展参数
  3635. * @return
  3636. * @throws BusinessException
  3637. */
  3638. com.minto.tip.common.util.PageInfo findAllTaskMyAttention(com.minto.tip.common.util.PageInfo pageInfo, Map<String, Object> map) throws BusinessException;
  3639. Boolean addTaskAttr(TaskAttrBean attrBean) throws BusinessException;
  3640. void updateTaskAttr(TaskAttrBean oldBean) throws BusinessException;
  3641. List<TaskAttrBean> findTaskAttr(Long[] taskIds) throws BusinessException;
  3642. TaskAttrBean findTaskAttrByTaskId(Long taskId) throws BusinessException;
  3643. /**
  3644. * 添加评论
  3645. * 2017年12月19日 上午9:45:50
  3646. *
  3647. * addTaskComments
  3648. * @param commentBeans
  3649. * @throws BusinessException
  3650. *void
  3651. * @exception
  3652. * @since 2.0
  3653. */
  3654. void addTaskComments(List<TaskCommentBean> commentBeans) throws BusinessException;
  3655. void addTaskComments(String contentJson, Long pid, Long cid) throws BusinessException;
  3656. /**
  3657. * 查询时间范围内的评价
  3658. * @param dateFrom
  3659. * @param dateTo
  3660. * @return
  3661. * @throws BusinessException
  3662. */
  3663. List<TaskCommentBean> findTaskComments(Date dateFrom, Date dateTo) throws BusinessException;
  3664. /**
  3665. * 查询单位在时间范围内的评价
  3666. * @param deptIds
  3667. * @param DateFrom
  3668. * @param DateTo
  3669. * @return
  3670. * @throws BusinessException
  3671. */
  3672. List<TaskCommentBean> findTaskCommentsByDeptId(Long[] deptIds, Date DateFrom, Date DateTo) throws BusinessException;
  3673. /**
  3674. * 根据任务id和汇报id查询汇报的评价记录
  3675. * @param taskId
  3676. * @param reportId
  3677. * @return
  3678. * @throws BusinessException
  3679. */
  3680. List<TaskCommentBean> findTaskCommentsBeanByTaskIdAndReportId(Long taskId, Long reportId) throws BusinessException;
  3681. /**
  3682. * 领导关注发送消息提醒
  3683. * @param creatorId
  3684. * @param cid
  3685. * @param personId
  3686. * @param taskId
  3687. * @param process
  3688. * @param type
  3689. * @throws BusinessException
  3690. */
  3691. void addTaskAttention(Long creatorId, Long cid, Long personId, Long taskId, String process, String type) throws BusinessException;
  3692. /**
  3693. * 查询任务列表
  3694. * @param redFlag
  3695. * @param doType
  3696. * @param keyword
  3697. * @param keywordShow
  3698. * @param dateFrom
  3699. * @param dateTo
  3700. * @param curentPid
  3701. * @param memberRelTypes
  3702. * @param states
  3703. * @param tCategory
  3704. * @param cid
  3705. * @param pid
  3706. * @param findState
  3707. * @param start
  3708. * @param pageSize
  3709. * @param includeIds
  3710. * @param isContain
  3711. * @return
  3712. * @throws BusinessException
  3713. */
  3714. ListObject<TaskBO> findTaskBos(Integer redFlag, String doType, String keyword, String keywordShow, String dateFrom, String dateTo, Long curentPid, Integer[] memberRelTypes,
  3715. Integer[] states, Integer tCategory, Long cid, Long pid, Integer findState, Integer start, Integer pageSize, List<Long> includeIds, boolean isContain) throws BusinessException;
  3716. /**
  3717. * 查询任务列表
  3718. * @param redFlag
  3719. * @param doType
  3720. * @param keyword
  3721. * @param keywordShow
  3722. * @param dateFrom
  3723. * @param dateTo
  3724. * @param curentPid
  3725. * @param memberRelTypes
  3726. * @param states
  3727. * @param tCategory
  3728. * @param cid
  3729. * @param pid
  3730. * @param findState
  3731. * @param start
  3732. * @param pageSize
  3733. * @param includeIds
  3734. * @param isContain
  3735. * @param categoryId
  3736. * @return
  3737. * @throws BusinessException
  3738. */
  3739. ListObject<TaskBO> findTaskBos(Integer redFlag, String doType, String keyword, String keywordShow, String dateFrom, String dateTo, Long curentPid, Integer[] memberRelTypes,
  3740. Integer[] states, Integer tCategory, Long cid, Long pid, Integer findState, Integer start, Integer pageSize, List<Long> includeIds, boolean isContain, Integer categoryId) throws BusinessException;
  3741. /**
  3742. * 查询任务列表
  3743. * @param redFlag
  3744. * @param doType
  3745. * @param keyword
  3746. * @param keywordShow
  3747. * @param dateFrom
  3748. * @param dateTo
  3749. * @param personId
  3750. * @param memberRelTypes
  3751. * @param states
  3752. * @param tCategory
  3753. * @param cid
  3754. * @param pid
  3755. * @param findState
  3756. * @param start
  3757. * @param pageSize
  3758. * @param includeIds
  3759. * @param isContain
  3760. * @param categoryId
  3761. * @param typeId 任务类型:任务类别表
  3762. * @param fromId 任务来源:任务类别表
  3763. * @return
  3764. * @throws BusinessException
  3765. */
  3766. ListObject<TaskBO> findTaskBos(Integer redFlag, String doType, String keyword, String keywordShow, String dateFrom, String dateTo, Long personId, Integer[] memberRelTypes, Integer[] states, Integer tCategory, Long cid, Long pid, Integer findState, Integer start, Integer pageSize, List<Long> includeIds, boolean isContain, Integer categoryId, Long typeId, Long fromId) throws BusinessException;
  3767. ListObject<TaskBO> findTaskBos(Integer redFlag, String doType, String keyword, String keywordShow, String dateFrom, String dateTo, Long personId, Integer[] memberRelTypes, Integer[] states, Integer tCategory, Long cid, Long pid, Integer findState, Integer start, Integer pageSize, List<Long> includeIds, boolean isContain, Integer categoryId, Long typeId, Long fromId, String exmineState) throws BusinessException;
  3768. /**
  3769. * 通过taskId,查询出事项的评价列表,map中包括
  3770. * id->事项的id
  3771. * pjr->评价人bean
  3772. * dbrToTaskStr->督办人对单位的评价
  3773. * dbrToDwList->督办人对单位的评价
  3774. * DwToSelfList->单位对自身的评价
  3775. * @param taskId
  3776. * @return
  3777. * @throws BusinessException
  3778. */
  3779. @SuppressWarnings("rawtypes")
  3780. Map findTaskComments(Long taskId, Long curUserId) throws BusinessException;
  3781. /**
  3782. * 查询count Level
  3783. * zhangzy
  3784. * @param id
  3785. * @param i
  3786. * @return
  3787. */
  3788. Long findTaskComments(Long id, int Level) throws BusinessException;
  3789. void addTaskAttention(TaskAttention dzdbAttention)
  3790. throws BusinessException;
  3791. List<TaskAttention> findTaskAttention(Long id)
  3792. throws BusinessException;
  3793. void updateTaskAttention(TaskAttention dzdbAttention)
  3794. throws BusinessException;
  3795. void delTaskAttr(Long taskId) throws BusinessException;
  3796. /**
  3797. * 根据事项id更改状态
  3798. * @param ids
  3799. * @param state
  3800. * @throws BusinessException
  3801. */
  3802. void updateTaskAttrState(Long[] ids, Integer state) throws BusinessException;
  3803. /**
  3804. * 根据事项状态查询指定人作为督办人的“督办事项”信息
  3805. * @param pid 督办人id
  3806. * @param tstate 不包含在内的事项状态,注意:是取的不包含
  3807. * @param jobType 事项类型 参考{@link TaskEnum.JobType}
  3808. * @return
  3809. */
  3810. List<TaskSummaryBean> findTasksByPidAndOuterStatus(Long pid, Integer[] tstate, Integer jobType) throws BusinessException;
  3811. /**
  3812. * 获取事项进度数据
  3813. * @param taskId 事项ID
  3814. * @param ptype 进度类型
  3815. * @param processResourceId 进度资源
  3816. * @return
  3817. * @throws BusinessException
  3818. */
  3819. List<TaskProcessSummaryBean> findTaskProcessBeans(Long taskId, Integer ptype, Long processResourceId) throws BusinessException;
  3820. /**
  3821. * 根据汇报id查找汇报的最新留言
  3822. * @param taskId 事项ID
  3823. * @param processResourceId 汇报id
  3824. * @return
  3825. * @throws BusinessException
  3826. */
  3827. TaskProcessSummaryBean findLatestTaskProcessBean(Long taskId, Long processResourceId) throws BusinessException;
  3828. /**
  3829. * 分页获取事项进度数据
  3830. * @param pageInfo 分页参数
  3831. * @param params 参数
  3832. * @return
  3833. * @throws BusinessException
  3834. */
  3835. com.minto.tip.common.util.PageInfo findTaskProcessBeans(com.minto.tip.common.util.PageInfo pageInfo,Map<String,Object> params) throws BusinessException;
  3836. /**
  3837. * 根据重大项目ID查询是否存在留言数据
  3838. * @param projectId
  3839. * @return
  3840. * @throws BusinessException
  3841. */
  3842. TaskProcessSummaryBean findTaskProcessSummaryByTaskId(Long projectId) throws BusinessException;
  3843. /**
  3844. * 查询该任务节点下的所有子节点
  3845. * @param taskId
  3846. * @return
  3847. */
  3848. List<Map<String, Object>> displayAllSubTasks(Long taskId) throws BusinessException;
  3849. /**
  3850. * 显示关联任务对应的责任单位
  3851. * @param taskId
  3852. * @param relationShip
  3853. * @return
  3854. */
  3855. StringBuffer displayUnit(Long taskId, Integer relationShip) throws BusinessException;
  3856. void restoreTaskQuartzJob() throws BusinessException;
  3857. /**
  3858. * 根据汇报ID查询事项ID,key为汇报ID,value为事项ID
  3859. * @param reportIds
  3860. * @return
  3861. */
  3862. Map<Long, Long> findTaskIdByReportId(List<Long> reportIds) throws BusinessException;
  3863. /**
  3864. * 查询任务下最新的汇报信息
  3865. * @param taskId
  3866. * @param memberId
  3867. * @return
  3868. * @throws BusinessException
  3869. */
  3870. TaskReportBean findTaskReportByTaskIdAndUpdateTime(Long taskId, Long memberId) throws BusinessException;
  3871. /**
  3872. * 根据id和类型状态查询
  3873. * @param ids id
  3874. * @param subType 所属类型
  3875. * @param status 状态
  3876. * @return
  3877. */
  3878. List<TaskTypeBean> findTaskTypebeanByIdsAndSubTypeAndStatus(List<Long> ids, Integer subType, Integer status) throws BusinessException;
  3879. /**
  3880. * 预置绑定基础页签
  3881. * @param taskId
  3882. * @throws BusinessException
  3883. */
  3884. void saveLabels(Long taskId) throws BusinessException;
  3885. /**
  3886. * 任务类别详情或列表字段配置
  3887. * @param taskId
  3888. * @param name
  3889. * @param type
  3890. * @throws BusinessException
  3891. */
  3892. void saveDetailOrListField(Long taskId, String name, String type) throws BusinessException;
  3893. /**
  3894. * 查询任务模板的数据
  3895. *
  3896. * @param pageInfo
  3897. * @param param
  3898. * @return
  3899. */
  3900. com.minto.tip.common.util.PageInfo findTaskSummaryList(com.minto.tip.common.util.PageInfo pageInfo, Map<String, Object> param) throws BusinessException;
  3901. /**
  3902. * 新增消息通知
  3903. * @param map
  3904. * @return
  3905. */
  3906. Map<String, Object> addMessageConfig(Map<String,Object> map);
  3907. /**
  3908. * 删除消息通知
  3909. * @param id
  3910. * @return
  3911. */
  3912. Map<String,Object> delMessageConfig(Long id);
  3913. /**
  3914. * 根据消息提醒设置来发送消息
  3915. * @param param
  3916. */
  3917. Map<String, Object> findSuperviseTasks(Map<String,Object> param) throws BusinessException;
  3918. /**
  3919. * 获取不同状态任务数量
  3920. * @param state
  3921. * @return
  3922. * @throws BusinessException
  3923. */
  3924. Integer findTaskCountByState(Integer state, Long memberId) throws BusinessException;
  3925. void sendMessage(TaskSummaryBean summaryBean, List<TaskMemberBean> memberBeans, int type, Integer notifyType) throws BusinessException;
  3926. void sendMessage(TaskSummaryBean summaryBean, List<TaskMemberBean> memberBeans, int type, Integer notifyType, String message) throws BusinessException;
  3927. /**
  3928. * 根据状态获取任务
  3929. * @param remark
  3930. * @return
  3931. * @throws BusinessException
  3932. */
  3933. List<Map<String, Object>> findTasksByType(String remark) throws BusinessException;
  3934. List<Map<String, Object>> findNotifyMethod(Map<String, Object> name) throws BusinessException;
  3935. /**
  3936. * 组装消息内容
  3937. * @return
  3938. */
  3939. String buildMessageInfo(Map<String, Object> param,String content) throws BusinessException;
  3940. List<Map<String, Object>> findTaskMemberRelType(Map<String, Object> param) throws BusinessException;
  3941. List<Map<String, Object>> findNotifyType(Map<String, Object> param) throws BusinessException;
  3942. Map<String, Object> getTaskMessageConfig(Long taskTypeId, Integer messageType);
  3943. /**
  3944. * 根据类型状态和是否需要审批查询
  3945. * @param subType
  3946. * @param status
  3947. * @param needApproval
  3948. * @return
  3949. */
  3950. List<TaskTypeBean> findTaskTypeBeanBySubTypeAndStatusAndNeedApproval(Integer subType, Integer status, Integer needApproval) throws BusinessException;
  3951. /**
  3952. * 根据项目Id获取所属项目库
  3953. * @param proId
  3954. * @return
  3955. */
  3956. List<TaskTypeBean> findTaskTypeByProjectId(Long proId);
  3957. /**
  3958. * 根据colId获取目标项目库
  3959. * @return
  3960. */
  3961. List<Map<String, Object>> findTaskTypeByColId(Long colId);
  3962. /**
  3963. * 验证事项是不是未交办
  3964. * @param ids 事项ID
  3965. * @return 返回所有为交办ID
  3966. * @throws BusinessException
  3967. */
  3968. List<Long> verificationTaskState(List<Long> ids) throws BusinessException;
  3969. /**
  3970. * 事项交办,事项延期,事项终止,事项删除,事项办结,事项分派
  3971. * create by Wangcs 2019-08-27
  3972. * * 督办事项定时生成汇报待办,签收待办
  3973. */
  3974. Integer saveTaskWaiteDoBeans(List<TaskSummaryBean> tasks,Long pid) throws BusinessException;
  3975. /**
  3976. * 给成员生成汇报阶段的待办
  3977. * @author inspired
  3978. * @param task
  3979. * @param member
  3980. * @return
  3981. * @throws BusinessException
  3982. */
  3983. TipAffair processMemberAffair(TaskSummaryBean task, TaskMemberBean member) throws BusinessException;
  3984. /**
  3985. * 定时任务调用,生成节点待办
  3986. * @author inspired
  3987. * @param
  3988. * @return
  3989. */
  3990. void addMemberAffair(Long taskId,Long taskTypeId,Long reportConfigId,Long memberId,Integer subType,Long pid) throws BusinessException;
  3991. /** 通过taskIds删除待办
  3992. * @throws BusinessException
  3993. */
  3994. void deleteBytaskId(Long[] taskIds) throws BusinessException;
  3995. void packCommonWaiteDos4Goal(Long personId,TaskSummaryBean task,List<TipAffair> commonWaiteDoBeans);
  3996. void deleteAllCommonWaiteDos() throws BusinessException;
  3997. /**
  3998. * 分页查询所有督办任务
  3999. * @param pageInfo 分页信息
  4000. * @param genericParam 用户信息
  4001. * @return 任务信息
  4002. */
  4003. com.minto.tip.common.util.PageInfo<TaskPanelOutput> findAllSuperviseTask4WebPanel(com.minto.tip.common.util.PageInfo pageInfo, GenericParam genericParam);
  4004. /**
  4005. * 查询当前人员所有督办人任务的熟练
  4006. * @param genericParam
  4007. * @return
  4008. */
  4009. int countAllSuperviseTask4WebPanel(GenericParam genericParam);
  4010. /**
  4011. * 分页查询指定组织为承办单位的任务
  4012. * @param pageInfo
  4013. * @param param
  4014. * @return
  4015. */
  4016. com.minto.tip.common.util.PageInfo<TaskPanelOutput> findAllManagerTask4WebPanel(com.minto.tip.common.util.PageInfo pageInfo, GenericParam param);
  4017. /**
  4018. * 查询指定组织为承办单位的任务数量
  4019. * @param param
  4020. * @return
  4021. */
  4022. int countAllManagerTask4WebPanel(GenericParam param);
  4023. /**
  4024. * 查询当前承办人是否有分派回报
  4025. * @param managerId memberId
  4026. * @param deputeFlag 是否是委托分派 1 否(为空则查询委托分派,1 非委托分派)
  4027. * @return
  4028. */
  4029. List<TaskMemberBean> findTaskMemberByParentIdAndDeputeFlag(Long managerId, Integer deputeFlag);
  4030. /**
  4031. * 根据任务ID查询当前任务下有没有正在进行的延期、办结、中止申请
  4032. * @param taskId 任务ID
  4033. * @return
  4034. */
  4035. Map<String,Object> checkingTaskEmail(List<Long> taskId);
  4036. void saveTaskProcessSummaryBeanList(List<TaskProcessSummaryBean> taskProcessSummaryBeans);
  4037. /**
  4038. * 保存或者更新批示、留言的暂存
  4039. *
  4040. * @param tempBean
  4041. * @return
  4042. */
  4043. Long saveOrUpdateTaskProcessTemp(TaskProcessSummaryTempBean tempBean);
  4044. /**
  4045. * 查询暂存的批示、留言信息
  4046. *
  4047. * @param taskId
  4048. * @param personId
  4049. * @return
  4050. */
  4051. TaskProcessSummaryTempBean findTaskProcessTempByTaskAndPerson(Long taskId, Long personId);
  4052. /**
  4053. * 移除暂存的批示、留言信息
  4054. *
  4055. * @param taskId
  4056. * @param personId
  4057. * @return
  4058. */
  4059. void deleteTaskProcessTempByTaskAndPerson(Long taskId, Long personId);
  4060. /**
  4061. * 撤回批示留言
  4062. * @param itemId
  4063. * @param pid
  4064. */
  4065. void deleteTaskProcess(Long itemId,Long pid) throws Exception;
  4066. /**
  4067. * 传阅任务
  4068. * @param taskId
  4069. * @param resourceIds
  4070. */
  4071. void updateTask4Circulate(Long taskId, String[] resourceIds);
  4072. /**
  4073. * 根据id查找任务动态
  4074. * @param processId
  4075. */
  4076. Map<String,Object> findTaskProcessVisibilityInfo(Long processId);
  4077. /**
  4078. * 根据id更新任务动态
  4079. *
  4080. * @param processId
  4081. * @param visibilityScope
  4082. * @param resourceKeys
  4083. * @param pid
  4084. */
  4085. void updateTaskProcessVisibility(Long processId, String visibilityScope, String[] resourceKeys, Long pid);
  4086. /**
  4087. * 根据人员id,获取当前人员看的批示数据Id
  4088. *
  4089. * @param taskId
  4090. * @param pid
  4091. * @return
  4092. */
  4093. List<Long> findTaskProcessVisibilityRunTime(Long taskId, Long pid);
  4094. }