Browse Source

跟帖接口对接

master
lucky 4 years ago
parent
commit
8267986ef3
  1. 2
      src/components/CVideo/VideoDate.vue
  2. 13
      src/components/Community/CommentDate.vue
  3. 1
      src/components/Community/CommentSearch.vue
  4. 8
      src/components/Community/CommunityDate.vue
  5. 30
      src/components/Course/CourseDate.vue
  6. 26
      src/components/Development/DevelopmentDate.vue
  7. 31
      src/components/Institute/InstituteDate.vue
  8. 30
      src/components/Mentor/MentorDate.vue
  9. 54
      src/components/SpinOff/SpinOffDate.vue
  10. 54
      src/components/Transfer/TransferDate.vue
  11. 48
      src/components/innovativeService/innovativeServiceDate.vue
  12. 48
      src/components/innovativeService/innovativeServiceSearch.vue
  13. 3
      src/config/api.js
  14. 2
      src/plugins/ant-design-vue.js

2
src/components/CVideo/VideoDate.vue

@ -190,7 +190,7 @@ export default {
<style lang="stylus" scoped>
.main .img {
width: 100%;
height: 65px;
}
.main .big_img {

13
src/components/Community/CommentDate.vue

@ -19,7 +19,7 @@
<!-- 用户头像 -->
<template slot="avatarUrl" slot-scope="text, record">
<img :src="record.avatarUrl" class="img" />
<a-avatar :size="50" :src="record.avatarUrl" v-if="record.avatarUrl" />
</template>
<!-- 审核状态 -->
@ -64,7 +64,7 @@
</template>
<script>
import { upTopping } from 'config/api';
import { upComment } from 'config/api';
const columns = [
{
@ -149,13 +149,10 @@ export default {
const params = { param: { id: options.id } };
if (options) {
if (options.comStatus !== null) {
params.param.comStatus = options.comStatus;
}
if (options.topping !== null) {
params.param.topping = options.topping;
params.param.comStatus = +options.comStatus;
}
}
const res = await upTopping(params);
const res = await upComment(params);
const { data, msg, code } = res.data;
this.spinning = false;
if (code === 200) {
@ -175,7 +172,7 @@ export default {
<style lang="stylus" scoped>
.main .img {
width: 100%;
height: 65px;
}
.main .big_img {

1
src/components/Community/CommentSearch.vue

@ -4,7 +4,6 @@
<!-- 帖子状态 -->
<a-select
@change="handleChangeSelect('comStatus',$event)"
class="ml-3"
placeholder="跟帖状态"
style="width: 150px"
>

8
src/components/Community/CommunityDate.vue

@ -24,7 +24,7 @@
<!-- 用户头像 -->
<template slot="avatarUrl" slot-scope="text, record">
<img :src="record.avatarUrl" class="img" />
<a-avatar :size="50" :src="record.avatarUrl" v-if="record.avatarUrl" />
</template>
<!-- 审核状态 -->
@ -214,10 +214,10 @@ export default {
const params = { param: { id: options.id } };
if (options) {
if (options.comStatus !== null) {
params.param.comStatus = options.comStatus;
params.param.comStatus = +options.comStatus;
}
if (options.topping !== null) {
params.param.topping = options.topping;
params.param.topping = +options.topping;
}
}
const res = await upTopping(params);
@ -246,7 +246,7 @@ export default {
<style lang="stylus" scoped>
.main .img {
width: 100%;
height: 65px;
}
.main .big_img {

30
src/components/Course/CourseDate.vue

@ -55,7 +55,7 @@
</template>
<script>
import CourseEdit from "components/Course/CourseEdit.vue";
import CourseEdit from 'components/Course/CourseEdit.vue';
const columns = [
{
@ -104,23 +104,23 @@ const columns = [
const lists = [
{
id:'001',
courseName:'传控科技',
courseProfile:'传控科技简介',
introductionPicture:'assets/logo.png',
id: '001',
courseName: '传控科技',
courseProfile: '传控科技简介',
introductionPicture: 'assets/logo.png',
auditStatus: '通过',
},
{
id:'002',
courseName:'中绿环保',
courseProfile:'中绿环保简介',
introductionPicture:'assets/logo.png',
id: '002',
courseName: '中绿环保',
courseProfile: '中绿环保简介',
introductionPicture: 'assets/logo.png',
auditStatus: '未通过',
}
},
];
export default {
name: "CourseDate",
name: 'CourseDate',
components: {
CourseEdit,
},
@ -133,7 +133,7 @@ export default {
height: '',
editVisible: false,
imgVisible: false,
}
};
},
mounted() {
@ -141,11 +141,11 @@ export default {
},
methods: {
showEditModal(){
showEditModal() {
this.editVisible = true;
},
closeModal(){
closeModal() {
this.editVisible = false;
},
@ -173,7 +173,7 @@ export default {
<style lang="stylus" scoped>
.main .img {
width: 100%;
height: 65px;
}
.main .big_img {

26
src/components/Development/DevelopmentDate.vue

@ -37,7 +37,7 @@
</template>
<script>
import DevelopmentEdit from "components/Development/DevelopmentEdit.vue";
import DevelopmentEdit from 'components/Development/DevelopmentEdit.vue';
const columns = [
{
@ -72,19 +72,19 @@ const columns = [
const lists = [
{
id:'001',
directory:'传控科技',
introductionPicture:'assets/logo.png',
id: '001',
directory: '传控科技',
introductionPicture: 'assets/logo.png',
},
{
id:'002',
directory:'中绿环保',
introductionPicture:'assets/logo.png',
}
id: '002',
directory: '中绿环保',
introductionPicture: 'assets/logo.png',
},
];
export default {
name: "DevelopmentDate",
name: 'DevelopmentDate',
components: {
DevelopmentEdit,
},
@ -97,7 +97,7 @@ export default {
height: '',
editVisible: false,
imgVisible: false,
}
};
},
mounted() {
@ -105,11 +105,11 @@ export default {
},
methods: {
showEditModal(){
showEditModal() {
this.editVisible = true;
},
closeModal(){
closeModal() {
this.editVisible = false;
},
@ -137,7 +137,7 @@ export default {
<style lang="stylus" scoped>
.main .img {
width: 100%;
height: 65px;
}
.main .big_img {

31
src/components/Institute/InstituteDate.vue

@ -6,8 +6,8 @@
:data-source="lists"
:loading="loading"
:row-key="record => record.id"
@change="handleTableChange"
:scroll="{ y: height }"
@change="handleTableChange"
bordered
class="white"
>
@ -26,7 +26,7 @@
<!-- 分类管理 -->
<!-- <template slot="categoryManage" slot-scope="text, record">
<a-button @click="openCategoryManage" size="small" type="primary">仪器分类管理</a-button>
</template> -->
</template>-->
<!-- 研究院类型 -->
<template slot="serviceType" slot-scope="text, record">
@ -49,9 +49,7 @@
<div slot="expandedRowRender" slot-scope="record" style="margin: 0">
<div>简介
<span v-dompurify-html="record.description"></span></div>
</div> -->
</div>-->
<div
class="d-flex flex-nowrap justify-space-between"
@ -59,7 +57,10 @@
slot-scope="record"
style="margin: 0"
>
<div class="ml-3">分类<span v-dompurify-html="record.direction"></span></div>
<div class="ml-3">
分类
<span v-dompurify-html="record.direction"></span>
</div>
<div class="ml-3">备注{{ record.description }}</div>
</div>
</a-table>
@ -72,7 +73,7 @@
</template>
<script>
import InstituteEdit from "components/Institute/InstituteEdit.vue";
import InstituteEdit from 'components/Institute/InstituteEdit.vue';
import { deleteInstitute } from 'config/api';
const columns = [
@ -171,7 +172,7 @@ const columns = [
// ];
export default {
name: "InstituteDate",
name: 'InstituteDate',
components: {
InstituteEdit,
},
@ -186,7 +187,7 @@ export default {
height: '',
editVisible: false,
imgVisible: false,
}
};
},
mounted() {
@ -202,23 +203,23 @@ export default {
},
methods: {
showEditModal(){
showEditModal() {
this.editVisible = true;
},
async closeModal(){
async closeModal() {
this.editVisible = false;
await this.$emit('getInstituteSearchBack');
},
//
openTeamMember(){
openTeamMember() {
const { query } = this.$route;
this.$router.push({ path: '/RD-team-member', query });
},
//
openCategoryManage(){
openCategoryManage() {
const { query } = this.$route;
this.$router.push({ path: '/category-manage', query });
},
@ -232,7 +233,7 @@ export default {
//
async onDelete(id) {
try {
const params = { param:{id}};
const params = { param: { id } };
const res = await deleteInstitute(params);
const { data, msg, code } = res.data;
if (code === 200) {
@ -254,7 +255,7 @@ export default {
<style lang="stylus" scoped>
.main .img {
width: 100%;
height: 65px;
}
.main .big_img {

30
src/components/Mentor/MentorDate.vue

@ -55,7 +55,7 @@
</template>
<script>
import MentorEdit from "components/Mentor/MentorEdit.vue";
import MentorEdit from 'components/Mentor/MentorEdit.vue';
const columns = [
{
@ -104,23 +104,23 @@ const columns = [
const lists = [
{
id:'001',
tutorName:'传控科技',
tutorProfile:'传控科技简介',
headPortrait:'assets/logo.png',
id: '001',
tutorName: '传控科技',
tutorProfile: '传控科技简介',
headPortrait: 'assets/logo.png',
auditStatus: '通过',
},
{
id:'002',
tutorName:'中绿环保',
tutorProfile:'中绿环保简介',
headPortrait:'assets/logo.png',
id: '002',
tutorName: '中绿环保',
tutorProfile: '中绿环保简介',
headPortrait: 'assets/logo.png',
auditStatus: '未通过',
}
},
];
export default {
name: "MentorDate",
name: 'MentorDate',
components: {
MentorEdit,
},
@ -133,7 +133,7 @@ export default {
height: '',
editVisible: false,
imgVisible: false,
}
};
},
mounted() {
@ -141,11 +141,11 @@ export default {
},
methods: {
showEditModal(){
showEditModal() {
this.editVisible = true;
},
closeModal(){
closeModal() {
this.editVisible = false;
},
@ -173,7 +173,7 @@ export default {
<style lang="stylus" scoped>
.main .img {
width: 100%;
height: 65px;
}
.main .big_img {

54
src/components/SpinOff/SpinOffDate.vue

@ -14,7 +14,6 @@
</template>
<template slot="position" slot-scope="text, record">
<span v-if=" record.position === 0">功能食品协同创新中心</span>
<span v-if=" record.position === 1">现代医药</span>
<span v-if=" record.position === 2">生物医学工程</span>
@ -25,11 +24,20 @@
<template slot="dealStatus" slot-scope="text, record">
<!-- <a-tag
:color="record.dealStatus === 1 ? 'blue' : 'red'"
>{{ record.dealStatus === 0 ? '未审核' : '不通过' }}</a-tag> -->
>{{ record.dealStatus === 0 ? '未审核' : '不通过' }}</a-tag>-->
<a-tag :color="record.dealStatus === 1 ? 'blue' : 'red'" v-if=" record.dealStatus === 0">未审核</a-tag>
<a-tag :color="record.dealStatus === 1 ? 'blue' : 'red'" v-if=" record.dealStatus === 1">通过</a-tag>
<a-tag :color="record.dealStatus === 1 ? 'blue' : 'red'" v-if=" record.dealStatus === 2">未通过</a-tag>
<a-tag
:color="record.dealStatus === 1 ? 'blue' : 'red'"
v-if=" record.dealStatus === 0"
>未审核</a-tag>
<a-tag
:color="record.dealStatus === 1 ? 'blue' : 'red'"
v-if=" record.dealStatus === 1"
>通过</a-tag>
<a-tag
:color="record.dealStatus === 1 ? 'blue' : 'red'"
v-if=" record.dealStatus === 2"
>未通过</a-tag>
</template>
<!-- 说明图片 -->
@ -56,8 +64,8 @@
</template>
<script>
import SpinOffEdit from "components/SpinOff/SpinOffEdit.vue";
import {getCreatingPlatformDelete} from "config/api"
import SpinOffEdit from 'components/SpinOff/SpinOffEdit.vue';
import { getCreatingPlatformDelete } from 'config/api';
const columns = [
{
@ -122,7 +130,7 @@ const columns = [
align: 'center',
dataIndex: 'dealStatus',
key: 'dealStatus',
scopedSlots: { customRender: 'dealStatus' },
scopedSlots: { customRender: 'dealStatus' },
},
{
title: '编辑',
@ -135,26 +143,26 @@ const columns = [
const lists = [
{
id:'001',
logo:'assets/logo.png',
companyName:'传控科技',
englishName:'ckkj',
id: '001',
logo: 'assets/logo.png',
companyName: '传控科技',
englishName: 'ckkj',
},
{
id:'002',
logo:'assets/logo.png',
companyName:'中绿环保',
englishName:'zlhb',
}
id: '002',
logo: 'assets/logo.png',
companyName: '中绿环保',
englishName: 'zlhb',
},
];
export default {
name: "SpinOffDate",
name: 'SpinOffDate',
components: {
SpinOffEdit,
},
props: { lists: { type: Array, default: () => [] }, pagination: { type: Object, default: () => {} } },
props: { lists: { type: Array, default: () => [] }, pagination: { type: Object, default: () => {} } },
data() {
this.cacheData = lists.map(item => ({ ...item }));
@ -164,7 +172,7 @@ export default {
height: '',
editVisible: false,
imgVisible: false,
}
};
},
mounted() {
@ -172,11 +180,11 @@ export default {
},
methods: {
showEditModal(){
showEditModal() {
this.editVisible = true;
},
closeModal(){
closeModal() {
this.editVisible = false;
},
@ -205,7 +213,7 @@ export default {
<style lang="stylus" scoped>
.main .img {
width: 100%;
height: 65px;
}
.main .big_img {

54
src/components/Transfer/TransferDate.vue

@ -59,7 +59,7 @@
</template>
<script>
import TransferEdit from "components/Transfer/TransferEdit.vue";
import TransferEdit from 'components/Transfer/TransferEdit.vue';
const columns = [
{
@ -113,37 +113,37 @@ const columns = [
const lists = [
{
id:'001',
achievementName:'传控科技',
id: '001',
achievementName: '传控科技',
achievementStage: '初期',
achievementLevel:'中',
achievementLevel: '中',
subjectClassification: '软硬件',
keyWord:'传控',
formOfTransfer:'转让形式',
scopeOfTransfer:'转让范围',
researchForm:'研究形式',
field:'软硬件',
intellectualProperty:'知识产权形式',
keyWord: '传控',
formOfTransfer: '转让形式',
scopeOfTransfer: '转让范围',
researchForm: '研究形式',
field: '软硬件',
intellectualProperty: '知识产权形式',
patentStatus: '专利状况',
},
{
id:'002',
achievementName:'中绿环保',
id: '002',
achievementName: '中绿环保',
achievementStage: '中期',
achievementLevel:'高',
achievementLevel: '高',
subjectClassification: '软硬件',
keyWord:'传控',
formOfTransfer:'转让形式',
scopeOfTransfer:'转让范围',
researchForm:'研究形式',
field:'软硬件',
intellectualProperty:'知识产权形式',
keyWord: '传控',
formOfTransfer: '转让形式',
scopeOfTransfer: '转让范围',
researchForm: '研究形式',
field: '软硬件',
intellectualProperty: '知识产权形式',
patentStatus: '专利状况',
}
},
];
export default {
name: "TransferDate",
name: 'TransferDate',
components: {
TransferEdit,
},
@ -157,7 +157,7 @@ export default {
height: '',
editVisible: false,
imgVisible: false,
}
};
},
mounted() {
@ -165,22 +165,22 @@ export default {
},
methods: {
showEditModal(){
showEditModal() {
this.editVisible = true;
},
closeModal(){
closeModal() {
this.editVisible = false;
},
//
openTeamMember(){
openTeamMember() {
const { query } = this.$route;
this.$router.push({ path: '/RD-team-member', query });
},
//
openCategoryManage(){
openCategoryManage() {
const { query } = this.$route;
this.$router.push({ path: '/category-manage', query });
},
@ -209,7 +209,7 @@ export default {
<style lang="stylus" scoped>
.main .img {
width: 100%;
height: 65px;
}
.main .big_img {

48
src/components/innovativeService/innovativeServiceDate.vue

@ -15,7 +15,7 @@
</template>
<template slot="picUrl" slot-scope="text, record">
<img :src="record.picUrl" width="50" height="50">
<img :src="record.picUrl" height="50" width="50" />
</template>
<template slot="serviceType" slot-scope="text, record">
@ -35,12 +35,12 @@
<a-empty v-else />
<!-- 编辑 -->
<r-d-member-edit :editVisible="editVisible" @closeModal="closeModal" />
<r-d-member-edit :edit-visible="editVisible" @closeModal="closeModal" />
</div>
</template>
<script>
import RDMemberEdit from "components/innovativeService/innovativeServiceEdit.vue";
import RDMemberEdit from 'components/innovativeService/innovativeServiceEdit.vue';
const columns = [
{
@ -68,7 +68,7 @@ const columns = [
align: 'center',
dataIndex: 'picUrl',
key: 'picUrl',
    scopedSlots: { customRender: 'picUrl' },
scopedSlots: { customRender: 'picUrl' },
},
{
title: '服务状态',
@ -83,7 +83,7 @@ const columns = [
key: 'serviceType',
scopedSlots: { customRender: 'serviceType' },
},
// {
// title: '/',
// align: 'center',
@ -107,35 +107,9 @@ const columns = [
},
];
// const columns = [
// {
// id:'001',
// name:'',
// sex: '',
// supportUnit:'',
// birth:'1990-01-01',
// education: '',
// jobTitle: '',
// researchDirection: '',
// },
// {
// id:'002',
// name:'',
// sex: '',
// supportUnit:'绿',
// birth:'1995-01-01',
// education: '',
// jobTitle: '',
// researchDirection: '',
// }
// ];
export default {
name: "innovativeServiceDate",
components: {
RDMemberEdit,
},
// props: { lists: { type: Array, default: () => {} } },
name: 'InnovativeServiceDate',
components: { RDMemberEdit },
props: { lists: { type: Array, default: () => [] }, pagination: { type: Object, default: () => {} } },
data() {
@ -144,8 +118,8 @@ export default {
loading: false,
editingKey: '',
height: '',
editVisible: false
}
editVisible: false,
};
},
mounted() {
@ -161,11 +135,11 @@ export default {
},
methods: {
showEditModal(){
showEditModal() {
this.editVisible = true;
},
closeModal(){
closeModal() {
this.editVisible = false;
},

48
src/components/innovativeService/innovativeServiceSearch.vue

@ -2,19 +2,12 @@
<div class="d-flex flex-wrap pb-3">
<!-- 团队名称 -->
<div>
<a-input
placeholder="服务名称"
style="width: 150px"
v-model="name"
/>
服务类型:
<a-input placeholder="服务名称" style="width: 150px" v-model="name" />服务类型:
<a-select
@change="handleChangeSelect('serviceType',$event)"
allow-clear
class="ml-3"
style="width: 150px"
allow-clear
>
<a-select-option
:key="serviceType.id"
@ -22,7 +15,7 @@
v-for="serviceType in serviceTypes"
>{{ serviceType.value }}</a-select-option>
</a-select>
<a-button @click="handleTableChange" class="mx-2" type="primary">搜索</a-button>
</div>
@ -36,37 +29,35 @@
</template>
<script>
import RDMemberAdd from "components/innovativeService/innovativeServiceAdd.vue";
import RDMemberAdd from 'components/innovativeService/innovativeServiceAdd.vue';
export default {
name: "innovativeServiceSearch",
components: {
RDMemberAdd,
},
name: 'InnovativeServiceSearch',
components: { RDMemberAdd },
data() {
return {
visible: false,
name: '',
serviceTypes: [
{ id:1, value:'创新平台' },
{ id:2, value:'孵化平台' },
{ id:3, value:'产业平台' },
{ id: 1, value: '创新平台' },
{ id: 2, value: '孵化平台' },
{ id: 3, value: '产业平台' },
],
}
};
},
methods: {
showModal(){
showModal() {
this.visible = true;
},
closeModal(){
closeModal() {
this.visible = false;
},
handleChangeSelect(type, value) {
this[type] = value;
},
handleChangeName(value) {
console.log('value: ', value);
this.name = value;
@ -74,13 +65,14 @@ export default {
async handleTableChange() {
console.log('搜索');
const { name,serviceType} = this;
console.log(name,serviceType)
//
const { name, serviceType } = this;
console.log(name, serviceType);
//
const condition = {
name,serviceType
}
await this.$emit('getInnovativeServiceSearch',condition)
name,
serviceType,
};
await this.$emit('getInnovativeServiceSearch', condition);
this.activityType = [];
},
},

3
src/config/api.js

@ -94,6 +94,9 @@ export const upTopping = params => axios.post(`${comment}/upTopping`, params);
// 跟帖查询
export const selCommunityH = params => axios.post(`${comment}/selCommunityH`, params);
// 修改跟贴表中得数据
export const upComment = params => axios.post(`${comment}/upComment`, params);
// 合作意向列表查询
export const getCreatingPlatformSearch = params => axios.post(`${creatingPlatform}/search`, params);

2
src/plugins/ant-design-vue.js

@ -24,6 +24,7 @@ import {
Spin,
Tooltip,
Popover,
Avatar,
} from 'ant-design-vue';
import { ConfigProvider } from 'ant-design-vue';
Vue.component(ConfigProvider.name, ConfigProvider);
@ -49,6 +50,7 @@ Vue.use(Checkbox);
Vue.use(Spin);
Vue.use(Tooltip);
Vue.use(Popover);
Vue.use(Avatar);
Vue.prototype.$message = message;
Vue.prototype.$notification = notification;

Loading…
Cancel
Save