dailyWork.vue 28 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928
  1. <template>
  2. <view style="width: 100vw;height:100vh;">
  3. <view style="height: calc(100% - 104rpx);">
  4. <swiper style="height: 100%;background-color:#F3F4F6 ;" :current="current" disable-touch
  5. @animationfinish="animationfinish">
  6. <swiper-item>
  7. <scroll-view scroll-y style="width: 100%;height: 100%;overflow: auto;box-sizing: border-box;"
  8. lower-threshold="10" :refresher-enabled="xlList1[0]" :refresher-triggered="xlList2[0]"
  9. @scrolltolower="lower(0)" @refresherrefresh="refresherrefresh(0)"
  10. @refresherrestore="refresherrestore(0)">
  11. <view v-if="title!='督办事项'" class="">
  12. <view style="padding: 20rpx;background-color: #fff;">
  13. <u-search v-model="db.title" placeholder="请输入标题" :showAction="true" actionText="搜索"
  14. :animation="true" @custom="dbsearch" @clear="dbsearch">
  15. </u-search>
  16. </view>
  17. <view v-for="item in dbList" :key="item.WorkID"
  18. style="padding: 20rpx 40rpx;border-bottom: 1px solid #dadada;background-color: #fff;"
  19. @click="getinfo(item)">
  20. <view>
  21. <u--text :lines="1" size="32rpx" :text="item.Title"></u--text>
  22. </view>
  23. <view
  24. style="display: flex;justify-content: space-between;margin-top: 20rpx;color:#909399;font-size: 28rpx;">
  25. <view>{{item.NodeName}}</view>
  26. <view>{{showtime(item.ADT)}}</view>
  27. </view>
  28. </view>
  29. <div style="padding: 10rpx 0;" v-if="dbList.length > 0">
  30. <u-loadmore :status="statusList[0]" />
  31. </div>
  32. <div v-if="dbList.length == 0">
  33. <u-empty mode="list" icon="/static/list.png" text="暂无内容" textSize="30rpx"></u-empty>
  34. </div>
  35. </view>
  36. <view v-else class="">
  37. <u-checkbox-group placement="column" @change="changeCheckBox">
  38. <view style="padding: 20rpx;background-color: #fff;">
  39. <u-search v-model="db.title" placeholder="请输入标题" :showAction="true" actionText="搜索"
  40. :animation="true" @custom="dbsearch" @clear="dbsearch">
  41. </u-search>
  42. </view>
  43. <view v-for="item in dbList" :key="item.id"
  44. style="padding: 20rpx 40rpx;border-bottom: 1px solid #ceccca;background-color: #fff;">
  45. <uni-card>
  46. <view class="" style="display: flex;">
  47. <!-- <u-checkbox :disabled="item.submitState!=null" :name="item.id"></u-checkbox> -->
  48. <span
  49. style="font-weight: 700;font-size: 30rpx;margin-left: 40rpx;">{{item.title}}</span>
  50. </view>
  51. <view style='margin:20rpx 40rpx' class="">
  52. <text> 处室及负责人: {{item.departmentHead}}</text>
  53. <br />
  54. <text> 创建时间: {{item.createTime}}</text>
  55. <br />
  56. <text>
  57. 责任处室:{{item.prersonLiable}}</text>
  58. </view>
  59. <view style="display: flex;" class="">
  60. <!-- <u-button v-if="item.submitState==1" @click="handleView(item)"
  61. style="width: 150rpx;" size="small" type="warning">查看</u-button> -->
  62. <u-button @click="handleChuli(item)" style="width: 150rpx;" size="small"
  63. type="primary">处理</u-button>
  64. </view>
  65. </uni-card>
  66. </view>
  67. </u-checkbox-group>
  68. <div style="padding: 10rpx 0;" v-if="dbList.length > 0">
  69. <u-loadmore :status="statusList[0]" />
  70. </div>
  71. <div v-if="dbList.length == 0">
  72. <u-empty mode="list" icon="/static/list.png" text="暂无内容" textSize="30rpx"></u-empty>
  73. </div>
  74. </view>
  75. </scroll-view>
  76. </swiper-item>
  77. <swiper-item>
  78. <scroll-view scroll-y style="width: 100%;height: 100%;overflow: auto;box-sizing: border-box;"
  79. lower-threshold="0" :refresher-enabled="xlList1[1]" :refresher-triggered="xlList2[1]"
  80. @scrolltolower="lower(1)" @refresherrefresh="refresherrefresh(1)"
  81. @refresherrestore="refresherrestore(1)">
  82. <view v-if="this.title!='督办事项'" class="">
  83. <view style="padding: 20rpx;background-color: #fff;">
  84. <u-search v-model="sq.title" placeholder="请输入标题" :showAction="true" actionText="搜索"
  85. :animation="true" @custom="sqsearch" @clear="sqsearch">
  86. </u-search>
  87. </view>
  88. <view v-for="item in sqList" :key="item.WorkID"
  89. style="padding: 20rpx 40rpx;border-bottom: 1px solid #ceccca;background-color: #fff;"
  90. @click="getinfo(item)">
  91. <view>
  92. <u--text :lines="1" size="32rpx" :text="item.Title"></u--text>
  93. </view>
  94. <view
  95. style="display: flex;justify-content: space-between;margin-top: 20rpx;color:#909399;font-size: 28rpx;">
  96. <view>{{item.NodeName}}</view>
  97. <view>{{showtime(item.RDT)}}</view>
  98. </view>
  99. </view>
  100. <div style="padding: 10rpx 0;" v-if="sqList.length > 0">
  101. <u-loadmore :status="statusList[1]" />
  102. </div>
  103. <div v-if="sqList.length == 0">
  104. <u-empty mode="list" icon="/static/list.png" text="暂无内容" textSize="30rpx"></u-empty>
  105. </div>
  106. </view>
  107. <view v-else class="">
  108. <view style="padding: 20rpx;background-color: #fff;">
  109. <u-search v-model="sq.title" placeholder="请输入标题" :showAction="true" actionText="搜索"
  110. :animation="true" @custom="sqsearch" @clear="sqsearch">
  111. </u-search>
  112. </view>
  113. <view style="background-color: #fff;" class="">
  114. <u-button v-if="sqList.length != 0" @click="submitDB"
  115. style="width: 150rpx;margin-left:50rpx;" size="small" type="primary">提
  116. 交</u-button>
  117. <u-checkbox-group placement="column" @change="changeCheckBox">
  118. <view v-for="(item,index) in sqList" :key="index"
  119. style="padding: 20rpx 40rpx;border-bottom: 1px solid #ceccca;background-color: #fff;">
  120. <uni-card>
  121. <view class="" style="display: flex;">
  122. <u-checkbox :disabled="item.submitState!=0"
  123. :name="item.id"></u-checkbox>
  124. <span style="font-weight: 700;font-size: 30rpx;">{{item.title}}</span>
  125. </view>
  126. <view style='margin:20rpx 40rpx' class="">
  127. <text> 处室及负责人: {{item.departmentHead}}</text>
  128. <br />
  129. <text> 创建时间: {{item.createTime}}</text>
  130. <br />
  131. <text>
  132. 责任处室:{{item.prersonLiable}}</text>
  133. </view>
  134. <view style="display: flex;" class="">
  135. <u-button v-if="item.submitState==1||item.submitState==3"
  136. @click="handleView(item)" style="width: 150rpx;" size="small"
  137. type="warning">查看</u-button>
  138. <u-button v-if="item.submitState == '2'" @click="handleAgain(item)"
  139. style="width: 150rpx;" size="small" type="primary">再次发起</u-button>
  140. <u-button v-if="item.submitState == '2'" @click="handleGuidang(item)"
  141. style="width: 150rpx;" size="small" type="success">归档</u-button>
  142. </view>
  143. </uni-card>
  144. </view>
  145. </u-checkbox-group>
  146. </view>
  147. <!-- <view v-for="item in sqList" :key="item.WorkID"
  148. style="padding: 20rpx 40rpx;border-bottom: 1px solid #ceccca;background-color: #fff;"
  149. @click="getinfo(item)">
  150. <view>
  151. <u--text :lines="1" size="32rpx" :text="item.Title"></u--text>
  152. </view>
  153. <view
  154. style="display: flex;justify-content: space-between;margin-top: 20rpx;color:#909399;font-size: 28rpx;">
  155. <view>{{item.NodeName}}</view>
  156. <view>{{showtime(item.RDT)}}</view>
  157. </view>
  158. </view> -->
  159. <div style="padding: 10rpx 0;" v-if="sqList.length > 0">
  160. <u-loadmore :status="statusList[1]" />
  161. </div>
  162. <div v-if="sqList.length == 0">
  163. <u-empty mode="list" icon="/static/list.png" text="暂无内容" textSize="30rpx"></u-empty>
  164. </div>
  165. <u-modal :show="showGuidang" :showCancelButton='true' @cancel="showGuidang=false"
  166. @confirm="handleGD" title="提示" content='是否确认归档?'></u-modal>
  167. </view>
  168. </scroll-view>
  169. </swiper-item>
  170. <swiper-item>
  171. <scroll-view scroll-y style="width: 100%;height: 100%;overflow: auto;box-sizing: border-box;"
  172. lower-threshold="0" :refresher-enabled="xlList1[2]" :refresher-triggered="xlList2[2]"
  173. @scrolltolower="lower(2)" @refresherrefresh="refresherrefresh(2)"
  174. @refresherrestore="refresherrestore(2)">
  175. <view style="padding: 20rpx;background-color: #fff;">
  176. <u-search v-model="yb.title" placeholder="请输入标题" :showAction="true" actionText="搜索"
  177. :animation="true" @custom="ybsearch" @clear="ybsearch">
  178. </u-search>
  179. </view>
  180. <view v-for="item in ybList" :key="item.WorkID"
  181. style="padding: 20rpx 40rpx;border-bottom: 1px solid #ceccca;background-color: #fff;"
  182. @click="getinfo(item)">
  183. <view>
  184. <u--text :lines="1" size="32rpx" :text="item.Title"></u--text>
  185. </view>
  186. <view
  187. style="display: flex;justify-content: space-between;margin-top: 20rpx;color:#909399;font-size: 28rpx;">
  188. <view>{{item.NodeName}}</view>
  189. <view>{{showtime(item.RDT)}}</view>
  190. </view>
  191. </view>
  192. <div style="padding: 10rpx 0;" v-if="ybList.length > 0">
  193. <u-loadmore :status="statusList[2]" />
  194. </div>
  195. <div v-if="ybList.length == 0">
  196. <u-empty mode="list" icon="/static/list.png" text="暂无内容" textSize="30rpx"></u-empty>
  197. </div>
  198. </scroll-view>
  199. </swiper-item>
  200. <swiper-item>
  201. <scroll-view scroll-y style="width: 100%;height: 100%;overflow: auto;box-sizing: border-box;"
  202. lower-threshold="0" :refresher-enabled="xlList1[3]" :refresher-triggered="xlList2[3]"
  203. @scrolltolower="lower(3)" @refresherrefresh="refresherrefresh(3)"
  204. @refresherrestore="refresherrestore(3)">
  205. <view style="padding: 20rpx;background-color: #fff;">
  206. <u-search v-model="tj.title" placeholder="请输入督办事项" :showAction="true" actionText="搜索"
  207. :animation="true" @custom="tjsearch" @clear="tjsearch">
  208. </u-search>
  209. </view>
  210. <view style="background-color: #fff;" class="">
  211. <u-button v-if="tjList.length != 0" @click="cuibanDB"
  212. style="width: 150rpx;margin-left:50rpx;" size="small" type="success">催办</u-button>
  213. <u-checkbox-group placement="column" @change="changeCheckBox">
  214. <view v-for="(item,index) in tjList" :key="index"
  215. style="padding: 20rpx 40rpx;border-bottom: 1px solid #ceccca;background-color: #fff;">
  216. <uni-card>
  217. <view class="" style="display: flex;">
  218. <u-checkbox :name="item.id"></u-checkbox>
  219. <span style="font-weight: 700;font-size: 30rpx;">{{item.title}}</span>
  220. </view>
  221. <view style='margin:20rpx 40rpx' class="">
  222. <text> 处室及负责人: {{item.departmentHead}}</text>
  223. <br />
  224. <text> 创建时间: {{item.createTime}}</text>
  225. <br />
  226. <text>
  227. 责任处室:{{item.prersonLiable}}</text>
  228. </view>
  229. <view style="display: flex;" class="">
  230. <u-button @click="handleView(item)" style="width: 150rpx;" size="small"
  231. type="warning">查看</u-button>
  232. <!-- <u-button @click="handleEdit(item)" v-if="
  233. item.submitState != null &&
  234. item.isCb != 'Y' &&
  235. item.progressEva != 1
  236. " style="width: 150rpx;" size="small" type="primary">催办</u-button> -->
  237. </view>
  238. </uni-card>
  239. </view>
  240. </u-checkbox-group>
  241. </view>
  242. <div style="padding: 10rpx 0;" v-if="tjList.length > 0">
  243. <u-loadmore :status="statusList[3]" />
  244. </div>
  245. <div v-if="tjList.length == 0">
  246. <u-empty mode="list" icon="/static/list.png" text="暂无内容" textSize="30rpx"></u-empty>
  247. </div>
  248. </scroll-view>
  249. </swiper-item>
  250. </swiper>
  251. </view>
  252. <view v-if="title=='督办事项'" style="height: 100rpx;border-top: 2px solid #dadbde;box-sizing: border-box;">
  253. <u-grid :border="true" :col="showDB==true?3:2">
  254. <u-grid-item @click="click(0)">
  255. <text class="grid-text" :class="current==0?'choose':''">待办</text>
  256. </u-grid-item>
  257. <u-grid-item @click="click(1)">
  258. <text class="grid-text" :class="current==1?'choose':''">{{this.title=='督办事项'?'我发起的':'我申请的'}}</text>
  259. </u-grid-item>
  260. <u-grid-item v-if="title!='督办事项'" @click="click(2)">
  261. <text class="grid-text" :class="current==2?'choose':''">已办</text>
  262. </u-grid-item>
  263. <u-grid-item v-if="title=='督办事项'&&showDB==true" @click="click(3)">
  264. <text class="grid-text" :class="current==3?'choose':''">所有督办</text>
  265. </u-grid-item>
  266. </u-grid>
  267. </view>
  268. <view v-else style="height: 100rpx;border-top: 2px solid #dadbde;box-sizing: border-box;">
  269. <u-grid :border="true" :col="3">
  270. <u-grid-item @click="click(0)">
  271. <text class="grid-text" :class="current==0?'choose':''">待办</text>
  272. </u-grid-item>
  273. <u-grid-item @click="click(1)">
  274. <text class="grid-text" :class="current==1?'choose':''">{{this.title=='督办事项'?'我发起的':'我申请的'}}</text>
  275. </u-grid-item>
  276. <u-grid-item v-if="title!='督办事项'" @click="click(2)">
  277. <text class="grid-text" :class="current==2?'choose':''">已办</text>
  278. </u-grid-item>
  279. <u-grid-item v-if="title=='督办事项'&&showDB==true" @click="click(3)">
  280. <text class="grid-text" :class="current==3?'choose':''">所有督办</text>
  281. </u-grid-item>
  282. </u-grid>
  283. </view>
  284. <u-action-sheet :actions="morelist" :closeOnClickOverlay="true" :closeOnClickAction="true" cancelText="取消"
  285. title="发起" :show="show" @select="selectClick" @close="show = false"></u-action-sheet>
  286. </view>
  287. </template>
  288. <script>
  289. import {
  290. showtime
  291. } from "@/utils/wjw.js"
  292. export default {
  293. data() {
  294. return {
  295. fkFlow: '',
  296. CheckBoxList: [],
  297. //当前待办还是已办
  298. current: 0,
  299. //待办相关
  300. db: {
  301. pageNum: 1,
  302. pageSize: 20,
  303. fkFlow: null,
  304. title: null,
  305. token: uni.getStorageSync('jtoken')
  306. },
  307. dbList: [],
  308. showGuidang: false,
  309. dbSearch: null,
  310. dbTotal: 0,
  311. //已办相关
  312. yb: {
  313. pageNum: 1,
  314. pageSize: 20,
  315. fkFlow: null,
  316. title: null,
  317. token: uni.getStorageSync('jtoken')
  318. },
  319. ybList: [],
  320. ybSearch: null,
  321. ybTotal: 0,
  322. //下拉刷新相关
  323. xlList1: [true, false, false, false],
  324. xlList2: [true, true, true, true],
  325. statusList: ['loadmore', 'loadmore', 'loadmore', 'loadmore'],
  326. //查看事件
  327. showtime: showtime,
  328. //收发文状态
  329. type: null,
  330. //我申请的相关
  331. sq: {
  332. pageNum: 1,
  333. pageSize: 20,
  334. fkFlow: null,
  335. title: null,
  336. token: uni.getStorageSync('jtoken')
  337. },
  338. tj: {
  339. pageNum: 1,
  340. pageSize: 20,
  341. fkFlow: null,
  342. title: null,
  343. orderByColumn: 'createTime',
  344. isAsc: 'Desc',
  345. token: uni.getStorageSync('jtoken')
  346. },
  347. sqList: [],
  348. sqSearch: null,
  349. sqTotal: 0,
  350. //更多展示
  351. show: false,
  352. morelist: [
  353. ],
  354. tjList: [],
  355. checkBoxAll: '',
  356. checkBoxAllList: [],
  357. selectedItems: '',
  358. title: '',
  359. rowItem: null,
  360. showDB: false
  361. }
  362. },
  363. onLoad(options) {
  364. uni.$u.http.get('/getInfo').then(res => {
  365. console.log('res66', res)
  366. res.roles.filter((item) => {
  367. if (item == 'zhoubaoGly') {
  368. this.showDB = true
  369. }
  370. })
  371. })
  372. getApp().globalData.zerenList = null
  373. getApp().globalData.ywListZR = null
  374. this.fkFlow = options.fkFlow
  375. this.db.fkFlow = options.fkFlow
  376. this.yb.fkFlow = options.fkFlow
  377. this.sq.fkFlow = options.fkFlow
  378. this.tj.fkFlow = options.fkFlow
  379. this.type = options.type
  380. this.title = options.title
  381. uni.setNavigationBarTitle({
  382. title: options.title
  383. })
  384. this.getDbList()
  385. if (options.fkFlow == '006') {
  386. this.morelist.push({
  387. name: '中层出差申请'
  388. })
  389. } else if (options.fkFlow == '007') {
  390. this.morelist.push({
  391. name: '外出授课申请'
  392. })
  393. } else if (options.fkFlow == '009') {
  394. this.morelist.push({
  395. name: '请(休)假申请'
  396. })
  397. } else if (options.fkFlow == '015') {
  398. this.morelist.push({
  399. name: '用车申请'
  400. })
  401. } else if (options.fkFlow == '020') {
  402. this.morelist.push({
  403. name: '调班申请'
  404. })
  405. } else if (options.fkFlow == '017') {
  406. this.morelist.push({
  407. name: '用章申请'
  408. })
  409. } else if (options.fkFlow == '018') {
  410. this.morelist.push({
  411. name: '合同用章申请'
  412. })
  413. } else if (options.fkFlow == '016') {
  414. this.morelist.push({
  415. name: '督办事项发起'
  416. })
  417. }
  418. },
  419. onNavigationBarButtonTap(e) {
  420. this.show = true
  421. },
  422. onShow() {
  423. getApp().globalData.peoIdList = []
  424. getApp().globalData.peoList = []
  425. getApp().globalData.peoDeptList = []
  426. uni.$off()
  427. uni.$on('query', (query) => {
  428. if (query.a == 'back') {
  429. setTimeout(() => {
  430. this.db.pageNum = 1
  431. this.dbList = []
  432. this.getDbList()
  433. this.xlList2[this.current] = true
  434. this.yb.pageNum = 1
  435. this.ybList = []
  436. this.getYbList()
  437. this.tj.pageNum = 1
  438. this.tjList = []
  439. this.getTjList()
  440. this.sq.pageNum = 1
  441. this.sqList = []
  442. this.getSqList()
  443. this.selectedItems = null
  444. }, 2000)
  445. }
  446. })
  447. },
  448. methods: {
  449. handleGD() {
  450. let data = {
  451. id: this.rowItem.id,
  452. submitState: '3'
  453. }
  454. let dataGuidang = {
  455. workId: this.rowItem.id,
  456. archiveFormNo: '016'
  457. }
  458. uni.$u.http.put('/offcial/supervision', data).then(res => {
  459. uni.$u.http.post('/offcial/archive/save', dataGuidang).then(res => {
  460. uni.showToast({
  461. title: '归档成功',
  462. icon: 'none'
  463. })
  464. this.showGuidang = false
  465. this.sq.pageNum = 1
  466. this.sqList = []
  467. this.getSqList()
  468. })
  469. })
  470. },
  471. handleGuidang(row) {
  472. console.log('frer', row)
  473. this.showGuidang = true
  474. this.rowItem = row
  475. },
  476. handleAgain(row) {
  477. uni.navigateTo({
  478. url: '/pages/dbZaici/dbZaiCi?id=' + row.id
  479. })
  480. },
  481. handleChuli(row) {
  482. uni.navigateTo({
  483. url: '/pages/dbChuli/dbChuli?fkFlow=' + this.fkFlow + '&id=' + row.id +
  484. '&title=' + '督办事项处理'
  485. })
  486. },
  487. handleEdit(row) {
  488. uni.navigateTo({
  489. url: '/pages/dbDetail/dbDetail?fkFlow=' + this.fkFlow + '&id=' + row.id +
  490. '&title=' + '督办编辑'
  491. })
  492. },
  493. handleView(row) {
  494. console.log('row', row)
  495. uni.navigateTo({
  496. url: '/pages/dbDetail/dbDetail?fkFlow=' + this.fkFlow + '&id=' + row.id +
  497. '&title=' + '督办查看'
  498. })
  499. },
  500. submitDB() {
  501. uni.showLoading({
  502. title: "提交中..."
  503. })
  504. console.log('selectedItems', this.selectedItems)
  505. if (this.selectedItems != '' && this.selectedItems != null) {
  506. uni.$u.http.post('/offcial/supervision/patchStartSupervision/' + this.selectedItems).then(
  507. res => {
  508. console.log('res', res)
  509. uni.showToast({
  510. title: '提交成功',
  511. icon: "none",
  512. mask: true,
  513. duration: 3000
  514. })
  515. uni.hideLoading()
  516. this.selectedItems = null
  517. this.tj.pageNum = 1
  518. this.tjList = []
  519. this.getTjList()
  520. this.sq.pageNum = 1
  521. this.sqList = []
  522. this.getSqList()
  523. }).catch(() => {
  524. uni.hideLoading()
  525. })
  526. } else {
  527. uni.showToast({
  528. title: '请先勾选要提交的督办事项',
  529. icon: "none",
  530. mask: true,
  531. duration: 3000
  532. })
  533. }
  534. },
  535. cuibanDB() {
  536. uni.showLoading({
  537. title: "催办中..."
  538. })
  539. console.log('selectedItems', this.selectedItems)
  540. if (this.selectedItems != '' && this.selectedItems != null) {
  541. uni.$u.http.get('/offcial/supervision/sel/myselfDetail/' + this.selectedItems).then(
  542. res => {
  543. console.log('res', res)
  544. uni.showToast({
  545. title: '催办成功',
  546. icon: "none",
  547. mask: true,
  548. duration: 3000
  549. })
  550. uni.hideLoading()
  551. this.selectedItems = null
  552. this.tj.pageNum = 1
  553. this.tjList = []
  554. this.getTjList()
  555. this.sq.pageNum = 1
  556. this.sqList = []
  557. this.getSqList()
  558. }).catch(() => {
  559. uni.hideLoading()
  560. })
  561. } else {
  562. uni.showToast({
  563. title: '请先勾选要催办的督办事项',
  564. icon: "none",
  565. mask: true,
  566. duration: 3000
  567. })
  568. }
  569. },
  570. changeCheckBox(val) {
  571. console.log('val', val)
  572. // console.log(this.CheckBoxList)
  573. this.selectedItems = val.join(',');
  574. console.log('selectedItems', this.selectedItems)
  575. },
  576. //点击已办待办
  577. click(i) {
  578. if (i == 0) {
  579. this.xlList1[i] = true
  580. this.xlList1[this.current] = false
  581. this.current = i
  582. if (this.dbList.length == 0) {
  583. this.getDbList()
  584. }
  585. } else if (i == 1) {
  586. this.xlList1[i] = true
  587. this.xlList1[this.current] = false
  588. this.current = i
  589. if (this.sqList.length == 0) {
  590. this.getSqList()
  591. }
  592. this.selectedItems = null
  593. } else if (i == 2) {
  594. this.xlList1[i] = true
  595. this.xlList1[this.current] = false
  596. this.current = i
  597. if (this.ybList.length == 0) {
  598. this.getYbList()
  599. }
  600. } else if (i == 3) {
  601. this.xlList1[i] = true
  602. this.xlList1[this.current] = false
  603. this.current = i
  604. if (this.tjList.length == 0) {
  605. this.getTjList()
  606. }
  607. this.selectedItems = null
  608. }
  609. },
  610. getTjList() {
  611. uni.$u.http.get('/offcial/supervision/list', {
  612. params: this.tj
  613. }).then(res => {
  614. uni.hideLoading()
  615. this.tjList = [...this.tjList, ...res.rows]
  616. console.log('tjList', this.tjList)
  617. if (res.total <= this.tj.pageSize) {
  618. this.statusList[0] = "nomore"
  619. } else {
  620. this.statusList[0] = "loadmore"
  621. }
  622. console.log('863',
  623. this.tjList)
  624. this.$forceUpdate()
  625. this.tjTotal = Math.ceil(res.total / this.tj.pageSize)
  626. })
  627. },
  628. //swiper切换
  629. animationfinish(e) {
  630. this.current = e.detail.current;
  631. },
  632. //查询待办列表
  633. getDbList() {
  634. if (this.title == '督办事项') {
  635. uni.$u.http.get('/offcial/supervision/dblist', {
  636. params: this.db
  637. }).then(res => {
  638. uni.hideLoading()
  639. this.dbList = [...this.dbList, ...res.rows]
  640. if (res.total <= this.db.pageSize) {
  641. this.statusList[0] = "nomore"
  642. } else {
  643. this.statusList[0] = "loadmore"
  644. }
  645. this.$forceUpdate()
  646. this.dbTotal = Math.ceil(res.total / this.db.pageSize)
  647. })
  648. } else {
  649. uni.$u.http.get('/jflow/restful/DB_Todolist_FlowNo', {
  650. params: this.db
  651. }).then(res => {
  652. uni.hideLoading()
  653. this.dbList = [...this.dbList, ...res.list]
  654. if (res.total <= this.db.pageSize) {
  655. this.statusList[0] = "nomore"
  656. } else {
  657. this.statusList[0] = "loadmore"
  658. }
  659. this.$forceUpdate()
  660. this.dbTotal = Math.ceil(res.total / this.db.pageSize)
  661. })
  662. }
  663. },
  664. //查询已办列表
  665. getYbList() {
  666. uni.$u.http.get('/jflow/restful/MyJoinOneFlows', {
  667. params: this.yb
  668. }).then(res => {
  669. uni.hideLoading()
  670. this.ybList = [...this.ybList, ...res.list]
  671. if (res.total <= this.yb.pageSize) {
  672. this.statusList[2] = "nomore"
  673. } else {
  674. this.statusList[2] = "loadmore"
  675. }
  676. this.$forceUpdate()
  677. this.ybTotal = Math.ceil(res.total / this.yb.pageSize)
  678. })
  679. },
  680. //查询我申请的列表
  681. getSqList() {
  682. if (this.title == '督办事项') {
  683. uni.$u.http.get('/offcial/supervision/dbfqlist', {
  684. params: {
  685. ...this.sq
  686. },
  687. header: {
  688. 'content-Type': 'application/x-www-form-urlencoded'
  689. },
  690. }).then(res => {
  691. // console.log(res)
  692. uni.hideLoading()
  693. this.sqList = [...this.sqList, ...res.rows]
  694. if (res.total <= this.sq.pageSize) {
  695. this.statusList[1] = "nomore"
  696. } else {
  697. this.statusList[1] = "loadmore"
  698. }
  699. this.$forceUpdate()
  700. this.sqTotal = Math.ceil(res.total / this.sq.pageSize)
  701. })
  702. } else {
  703. uni.$u.http.get('/jflow/restful/DB_MyStartFlowInstanceByFlow', {
  704. params: {
  705. ...this.sq
  706. },
  707. header: {
  708. 'content-Type': 'application/x-www-form-urlencoded'
  709. },
  710. }).then(res => {
  711. // console.log(res)
  712. uni.hideLoading()
  713. this.sqList = [...this.sqList, ...res.list]
  714. if (res.total <= this.sq.pageSize) {
  715. this.statusList[1] = "nomore"
  716. } else {
  717. this.statusList[1] = "loadmore"
  718. }
  719. this.$forceUpdate()
  720. this.sqTotal = Math.ceil(res.total / this.sq.pageSize)
  721. })
  722. }
  723. },
  724. //触底加载
  725. lower(e) {
  726. uni.showLoading({
  727. title: "加载中..."
  728. })
  729. if (e == 0) {
  730. if (this.db.pageNum != this.dbTotal) {
  731. this.db.pageNum++
  732. this.getDbList()
  733. } else {
  734. uni.hideLoading()
  735. this.statusList[e] = "nomore"
  736. this.$forceUpdate()
  737. }
  738. } else if (e == 1) {
  739. if (this.sq.pageNum != this.sqTotal) {
  740. this.sq.pageNum++
  741. this.getSqList()
  742. } else {
  743. uni.hideLoading()
  744. this.statusList[e] = "nomore"
  745. this.$forceUpdate()
  746. }
  747. } else if (e == 2) {
  748. if (this.yb.pageNum != this.ybTotal) {
  749. this.yb.pageNum++
  750. this.getYbList()
  751. } else {
  752. uni.hideLoading()
  753. this.statusList[e] = "nomore"
  754. this.$forceUpdate()
  755. }
  756. } else if (e == 3) {
  757. if (this.tj.pageNum != this.tjTotal) {
  758. this.tj.pageNum++
  759. this.getTjList()
  760. } else {
  761. uni.hideLoading()
  762. this.statusList[e] = "nomore"
  763. this.$forceUpdate()
  764. }
  765. }
  766. },
  767. //下拉刷新
  768. refresherrefresh(e) {
  769. if (e == 0) {
  770. this.xlList2[e] = true
  771. this.db.pageNum = 1
  772. this.dbList = []
  773. this.getDbList()
  774. setTimeout(() => {
  775. this.xlList2[e] = false
  776. this.$forceUpdate()
  777. }, 2000)
  778. } else if (e == 1) {
  779. this.xlList2[e] = true
  780. this.sq.pageNum = 1
  781. this.sqList = []
  782. this.getSqList()
  783. setTimeout(() => {
  784. this.xlList2[e] = false
  785. this.$forceUpdate()
  786. }, 2000)
  787. } else if (e == 2) {
  788. this.xlList2[e] = true
  789. this.yb.pageNum = 1
  790. this.ybList = []
  791. this.getYbList()
  792. setTimeout(() => {
  793. this.xlList2[e] = false
  794. this.$forceUpdate()
  795. }, 2000)
  796. } else if (e == 3) {
  797. this.xlList2[e] = true
  798. this.tj.pageNum = 1
  799. this.tjList = []
  800. this.getTjList()
  801. setTimeout(() => {
  802. this.xlList2[e] = false
  803. this.$forceUpdate()
  804. }, 2000)
  805. }
  806. },
  807. refresherrestore(e) {
  808. },
  809. //待办搜索
  810. dbsearch() {
  811. this.db.pageNum = 1
  812. this.dbList = []
  813. this.getDbList()
  814. },
  815. //已办搜索
  816. ybsearch() {
  817. this.yb.pageNum = 1
  818. this.ybList = []
  819. this.getYbList()
  820. },
  821. //申请搜索
  822. sqsearch() {
  823. this.sq.pageNum = 1
  824. this.sqList = []
  825. this.getSqList()
  826. },
  827. //提交搜索
  828. tjsearch() {
  829. this.tj.pageNum = 1
  830. this.tjList = []
  831. this.getTjList()
  832. },
  833. //查看收文发文详情
  834. getinfo(item) {
  835. console.log('title', item)
  836. uni.navigateTo({
  837. url: "/pages/workInfo/workInfo?workid=" + item.WorkID + '&type=' + this.current +
  838. '&flowNo=' +
  839. this.db.fkFlow + "&title=" + item.Title + "&nodeName=" + item.NodeName +
  840. "&nodeId=" + item
  841. .FK_Node + "&fkFlow=" + this.db.fkFlow
  842. })
  843. },
  844. //点击申请
  845. selectClick() {
  846. if (this.db.fkFlow == '006') {
  847. uni.navigateTo({
  848. url: "/pages/shenqing/shenqing?title=中层出差申请&fkFlow=" + this.db.fkFlow
  849. })
  850. } else if (this.db.fkFlow == '007') {
  851. uni.navigateTo({
  852. url: "/pages/shenqing/shenqing?title=外出授课申请&fkFlow=" + this.db.fkFlow
  853. })
  854. } else if (this.db.fkFlow == '009') {
  855. uni.navigateTo({
  856. url: "/pages/shenqing/shenqing?title=请(休)假申请&fkFlow=" + this.db.fkFlow
  857. })
  858. } else if (this.db.fkFlow == '015') {
  859. uni.navigateTo({
  860. url: "/pages/shenqing/shenqing?title=用车申请&fkFlow=" + this.db.fkFlow
  861. })
  862. } else if (this.db.fkFlow == '020') {
  863. uni.navigateTo({
  864. url: "/pages/shenqing/shenqing?title=调班申请&fkFlow=" + this.db.fkFlow
  865. })
  866. } else if (this.db.fkFlow == '017') {
  867. uni.navigateTo({
  868. url: "/pages/shenqing/shenqing?title=用章申请&fkFlow=" + this.db.fkFlow
  869. })
  870. } else if (this.db.fkFlow == '018') {
  871. uni.navigateTo({
  872. url: "/pages/shenqing/shenqing?title=合同用章申请&fkFlow=" + this.db.fkFlow
  873. })
  874. } else if (this.db.fkFlow == '016') {
  875. uni.navigateTo({
  876. url: "/pages/shenqing/shenqing?title=督办事项发起&fkFlow=" + this.db.fkFlow
  877. })
  878. }
  879. }
  880. }
  881. }
  882. </script>
  883. <style lang="scss" scoped>
  884. .grid-text {
  885. height: 100rpx;
  886. line-height: 100rpx;
  887. font-size: 36rpx;
  888. color: #606266;
  889. /* #ifndef APP-PLUS */
  890. box-sizing: border-box;
  891. /* #endif */
  892. }
  893. .choose {
  894. color: #409EFF
  895. }
  896. .uni-card {
  897. margin: 0 !important;
  898. }
  899. </style>