移动端
Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.

387 lignes
13 KiB

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