1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586 |
- <template>
- <view class="content">
- <view class="title"> 审核列表 </view>
- <view class="list">
- <view
- class="project"
- v-for="project in projectList"
- :key="project.id"
- @click="onClickProject(project)"
- >
- {{ `${project.project_name}(${project.project_full_code})` }}
- </view>
- <view class="loadmore">{{ loadMoreText }}</view>
- </view>
- </view>
- </template>
- <script>
- import { queryAuth } from "@/services/project";
- import { mapState } from "vuex";
- import mixin from "@/utils/listMixin";
- export default {
- mixins: [mixin],
- computed: {
- ...mapState(["currentProject"]),
- },
- data() {
- return {
- checkself: [],
- projectList: [],
- self: [{ text: "只看自己", value: 0 }],
- };
- },
- onShow() {
- this.initData();
- },
- methods: {
- async getProject(params) {
- let res = {};
- res = await queryAuth(params);
- this.pagination.currentPage == 1
- ? (this.projectList = res.data.list)
- : (this.projectList = this.projectList.concat(res.data.list));
- return res.data;
- },
- async onClickProject(project) {
- await this.$store.commit("setCurrentProject", project);
- uni.navigateTo({
- url: `./detail?id=${project.id}&auth=${true}`,
- });
- },
- },
- };
- </script>
- <style lang="less" scoped>
- .content {
- display: flex;
- justify-content: center;
- flex-wrap: wrap;
- }
- .title {
- width: 100%;
- padding: 0 20px 20px 20px;
- position: fixed;
- background: #f8f8f8;
- font: 24px bold;
- }
- .list {
- width: 90%;
- margin-top: 60px;
- border-top: 2px solid gray;
- }
- .project {
- border-bottom: 2px solid gray;
- padding: 20px 0px;
- font-size: 18px;
- }
- .loadmore {
- padding: 20px 0px;
- font-size: 18px;
- color: gray;
- text-align: center;
- }
- </style>
|