移动端
25'ten fazla konu seçemezsiniz Konular bir harf veya rakamla başlamalı, kısa çizgiler ('-') içerebilir ve en fazla 35 karakter uzunluğunda olabilir.

list_finance.vue 14 KiB

2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
2 yıl önce
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421
  1. <template>
  2. <div class="home_wrapper">
  3. <div class="header_main">
  4. 财务公开榜
  5. <div class="return_btn" @click="onClickLeft"></div>
  6. <div class="add_btn" v-show="showBtn" @click="goAdd"></div>
  7. </div>
  8. <div class="record_main">
  9. <div class="record_det">
  10. <div class="year_l" @click="tabShow"><i :class="{'icon':true , 'zk':!showTab , 'ss':showTab } "></i>{{queryParams.year == '' ? '全部': queryParams.year}}<span class="unit">{{queryParams.year == '' ? '': '年'}}</span></div>
  11. <div class="total_r">共{{listLength}}条公告</div>
  12. </div>
  13. <div class="record_list" v-if="showTab">
  14. <div :class="{'flex_block':true , 'current':queryParams.year == ''}" @click="tabClick('')">全部</div>
  15. <div :class="{'flex_block':true , 'current':queryParams.year == '2022'}" @click="tabClick('2022')">2022</div>
  16. <div :class="{'flex_block':true , 'current':queryParams.year == '2021'}" @click="tabClick('2021')">2021</div>
  17. <div :class="{'flex_block':true , 'current':queryParams.year == '2020'}" @click="tabClick('2020')">2020</div>
  18. </div>
  19. </div>
  20. <div class="list_main">
  21. <van-list
  22. v-model="loading"
  23. :finished="finished"
  24. finished-text="没有更多了"
  25. @load="getList"
  26. >
  27. <!----1-->
  28. <div class="item" v-for="(item,index) in applicationList" :key="index">
  29. <div class="info" @click="goDetail(item.id)">
  30. <div class="title">
  31. <i class="icon_box"></i>
  32. <p class="news_title">{{item.openName}}</p>
  33. <p class="tips_mark" v-if="index==0">新</p>
  34. </div>
  35. <div class="time">
  36. <div class="icon_time"></div>
  37. {{item.openNy}}
  38. </div>
  39. </div>
  40. <div class="operation">
  41. <!-- delete 删除 edit编辑 view查看 -->
  42. <div class="opera_btn list" @click="goRanking(item.id,item.openNy)">
  43. <i class="icon "></i>
  44. </div>
  45. <div class="opera_btn edit" @click="goEdit(item.id)" v-show="showBtn">
  46. <i class="icon "></i>
  47. </div>
  48. <div class="opera_btn delete" @click="goRemove(item.id)" v-show="showBtn">
  49. <i class="icon"></i>
  50. </div>
  51. <div class="opera_btn view" @click="goDetail(item.id)" v-show="!showBtn">
  52. <i class="icon "></i>
  53. </div>
  54. </div>
  55. </div>
  56. </van-list>
  57. </div>
  58. <!-- <div class="bottom_tips">-->
  59. <!-- <span class="xs">已经到底啦</span>-->
  60. <!-- </div>-->
  61. </div>
  62. </template>
  63. <script>
  64. import { financePublicList,openRemove } from "@/api/sunVillage_info/fixedAssets";
  65. import Cookies from "js-cookie";
  66. import request from '@/utils/request'
  67. export default {
  68. name: "certificateList",
  69. data() {
  70. return {
  71. applicationList:[],
  72. applicationListSecond:[],
  73. assetStatusOptions:[],
  74. auditStatus:[],
  75. loading: false,
  76. finished: false,
  77. show: false,
  78. showTab: false,
  79. fileList:[],
  80. listLength:'0',
  81. searchInput:'',
  82. queryParams:{
  83. pageNum:1,
  84. pageSize:10,
  85. orderByColumn:'createTime',
  86. isAsc:'desc',
  87. year:'',
  88. },
  89. uploadFiles1:[],
  90. projectId:'',
  91. projectIndex:'',
  92. showBtn:true,
  93. };
  94. },
  95. created() {
  96. this.queryParams.bookId = Cookies.get('bookId');
  97. this.queryParams.deptId = Cookies.get('deptId');
  98. if (this.$route.query.type == 'code'){
  99. this.showBtn = false;
  100. }
  101. },
  102. methods: {
  103. getList(){
  104. var _this = this;
  105. setTimeout(() => {
  106. console.log(_this.queryParams)
  107. financePublicList(_this.queryParams).then(response => {
  108. _this.listLength = response.total;
  109. _this.applicationList = response.rows;
  110. if(_this.applicationList.length >= response.total){
  111. _this.finished = true;
  112. return;
  113. }else{
  114. _this.loading = false;
  115. _this.queryParams.pageNum += 1 ;
  116. }
  117. });
  118. }, 1000);
  119. },
  120. tabClick(year){
  121. this.queryParams.year = year ;
  122. this.applicationList = [];
  123. this.getList();
  124. },
  125. tabShow(){
  126. this.showTab = !this.showTab;
  127. },
  128. /** 删除按钮操作 */
  129. handleDelete(row,index) {
  130. let assetStatus = row.assetStatus ? row.assetStatus : data[0].assetStatus;
  131. if (assetStatus === '2' || assetStatus === '3') {
  132. this.$notify({
  133. message: "不允许删除已出售或已报废的资产",
  134. type: "warning",
  135. });
  136. return;
  137. }
  138. let useType = row.useType;
  139. if(useType == 3) {
  140. this.$notify({
  141. message: "出租或出借的资产不允许删除",
  142. type: "warning",
  143. });
  144. return ;
  145. }
  146. const ids = row.id || this.ids;
  147. this.$dialog.alert(
  148. {
  149. message:'是否确认删除固定资产?',
  150. title:"警告",
  151. confirmButtonText: "确定",
  152. cancelButtonText: "取消",
  153. }
  154. )
  155. .then(function () {
  156. return delPermanent(ids);
  157. })
  158. .then(() => {
  159. this.applicationList.splice(index, 1);
  160. this.$notify({ type: 'success', message: '删除成功' });
  161. });
  162. },
  163. goAdd(){
  164. this.$router.push('/sunVillage_info/list_finance_add')
  165. },
  166. goDetail(id){
  167. this.$router.push({path:'/sunVillage_info/list_finance_detail',query: {id:id,type:'finance'}})
  168. },
  169. goRanking(id,time){
  170. this.$router.push({path:'/sunVillage_info/list_finance_ranking',query: {id:id,time:time}})
  171. },
  172. goEdit(id){
  173. this.$router.push({path:'/sunVillage_info/list_finance_edit',query: {id:id,type:'finance'}})
  174. },
  175. goRemove(id){
  176. this.$dialog.alert({
  177. title: '提示',
  178. message: '确认删除?',
  179. showCancelButton:true,
  180. })
  181. .then(() => {
  182. openRemove(id).then(response => {
  183. this.$notify({ type: 'success', message: '删除成功' });
  184. this.getList()
  185. });
  186. })
  187. .catch(() => {
  188. // on cancel
  189. });
  190. }
  191. },
  192. }
  193. </script>
  194. <style scoped lang="scss">
  195. .home_wrapper{
  196. background: #e9e9e9;
  197. min-height: 100vh;
  198. width: 100vw;
  199. .header_main{
  200. height: 116px;
  201. background: url('../../assets/images/sunVillage_info/list_head.png') no-repeat;
  202. background-size: 100% 100%;
  203. position: fixed;
  204. top: 0;
  205. left: 0;
  206. width: 100%;
  207. font-size: 36px;
  208. line-height: 116px;
  209. text-align: center;
  210. color: #fff;
  211. position: relative;
  212. .return_btn{
  213. width: 24px;
  214. height: 43.2px;
  215. background: url('../../assets/images/sunVillage_info/list_icon_5.png') center center no-repeat;
  216. background-size: 20px 36px;
  217. position: absolute;
  218. left: 38px;
  219. top: 36px;
  220. }
  221. .add_btn{
  222. width: 56.4px;
  223. height: 40.8px;
  224. background: url('../../assets/images/sunVillage_info/list_icon_9.png') center center no-repeat;
  225. background-size: 47px 34px;
  226. position: absolute;
  227. right: 38px;
  228. top: 36px;
  229. }
  230. }
  231. .record_main{
  232. padding:30px 22px;
  233. .record_det{
  234. height: 38px;
  235. line-height: 38px;
  236. display: flex;
  237. justify-content:space-between;
  238. .year_l{
  239. font-size: 30px;
  240. display: flex;
  241. align-items: center;
  242. color: #858585;
  243. .unit{
  244. padding-left: 5px;
  245. }
  246. .icon{
  247. width: 23px;
  248. height: 12px;
  249. display: block;
  250. background: url('../../assets/images/sunVillage_info/list_icon_1.png') no-repeat;
  251. background-size: 100% 100%;
  252. margin-bottom: 4px;
  253. margin-right: 8px;
  254. &.zk {
  255. transform: rotate(0deg)
  256. }
  257. &.ss{
  258. transform: rotate(180deg)
  259. }
  260. }
  261. }
  262. .total_r{
  263. font-size: 26px;
  264. letter-spacing: 2px;
  265. }
  266. }
  267. .record_list{
  268. display: flex;
  269. flex-flow: wrap;
  270. margin-top: 12PX;
  271. .flex_block{
  272. font-size: 30px;
  273. color: #878787;
  274. padding-right: 30px;
  275. &.current{
  276. color: #4199fe;
  277. font-weight: bold;
  278. }
  279. }
  280. }
  281. }
  282. .list_main{
  283. padding:0 22px;
  284. .item{
  285. height: 140px;
  286. border-radius: 30px;
  287. background: #fff;
  288. box-shadow: 4px 6px 5px rgba(63, 68, 75, 0.1);
  289. padding:25px 32px;
  290. display: flex;
  291. margin-bottom: 20px;
  292. .info{
  293. flex:0 0 450px;
  294. .title{
  295. display: flex;
  296. font-size: 32px;
  297. align-items: center;
  298. height: 58px;
  299. .icon_box{
  300. width: 34px;
  301. display: block;
  302. height: 30px;
  303. background: url('../../assets/images/sunVillage_info/list_icon_2.png') no-repeat;
  304. background-size: 100% 100%;
  305. margin-right: 10px;
  306. }
  307. .news_title{
  308. max-width:416px;
  309. overflow: hidden;
  310. white-space: nowrap;
  311. text-overflow: ellipsis;
  312. -o-text-overflow: ellipsis;
  313. }
  314. .tips_mark{
  315. width: 34px;
  316. height: 34px;
  317. background: #fa0c0c;
  318. border-radius: 8px;
  319. font-size: 24px;
  320. color: #fff;
  321. text-align: center;
  322. line-height: 34px;
  323. margin-left: 10px;
  324. }
  325. }
  326. .time{
  327. font-size: 24px;
  328. color: #858585;
  329. display: flex;
  330. align-items: center;
  331. height: 30px;
  332. margin-top: 6px;
  333. .icon_time{
  334. width: 25px;
  335. height: 25px;
  336. background: url('../../assets/images/sunVillage_info/list_icon_4.png') no-repeat;
  337. background-size: 100% 100%;
  338. margin-right: 10px;
  339. }
  340. }
  341. }
  342. .operation{
  343. flex: 1;
  344. display: flex;
  345. align-items: center;
  346. justify-content: space-between;
  347. text-align: right;
  348. .opera_btn{
  349. width: 52px;
  350. height: 52px;
  351. border-radius: 50%;
  352. display: flex;
  353. align-items: center;
  354. justify-content:center;
  355. &.delete{
  356. background:#df0707;
  357. .icon{
  358. width: 22px;
  359. height: 29px;
  360. background: url('../../assets/images/sunVillage_info/list_icon_7.png') no-repeat;
  361. background-size: 100% 100%;
  362. display: block;
  363. }
  364. }
  365. &.edit{
  366. background: #79cf13;
  367. .icon {
  368. width: 26px;
  369. height: 25px;
  370. background: url('../../assets/images/sunVillage_info/list_icon_6.png') no-repeat;
  371. background-size: 100% 100%;
  372. display: block;
  373. }
  374. }
  375. &.view{
  376. background: #3494ff;
  377. .icon {
  378. width: 29px;
  379. height: 21px;
  380. background: url('../../assets/images/sunVillage_info/list_icon_3.png') no-repeat;
  381. background-size: 100% 100%;
  382. display: block;
  383. }
  384. }
  385. &.list{
  386. background: #79cf13;
  387. .icon {
  388. width: 29px;
  389. height: 21px;
  390. background: url('../../assets/images/sunVillage_info/list_icon_10.png') no-repeat;
  391. background-size: 100% 100%;
  392. display: block;
  393. }
  394. }
  395. }
  396. }
  397. }
  398. }
  399. .bottom_tips{
  400. font-size: 24px;
  401. color: #a7a6a6;
  402. text-align: center;
  403. margin-top: 32px;
  404. background: url('../../assets/images/sunVillage_info/list_icon_8.png') center center no-repeat;
  405. background-size: 260px 2px;
  406. .xs{
  407. padding:0 8px;
  408. background: #e9e9e9;
  409. }
  410. }
  411. }
  412. </style>