杨豪 3 years ago
parent
commit
a87f7ad161
  1. 2
      .env.development
  2. 2
      .env.production
  3. BIN
      dist.rar
  4. 1
      src/api/ResourcesCagetory.js
  5. 2
      src/router/routers.js
  6. 1
      src/views/shop/demandHall/authentication.vue
  7. 10
      src/views/shop/demandHall/projectList.vue
  8. 1
      src/views/shop/projectManage/cooperationMode.vue
  9. 82
      src/views/shop/projectManage/screenManage.vue
  10. 28
      src/views/shop/user/index.vue

2
.env.development

@ -1,7 +1,7 @@
ENV = 'development' ENV = 'development'
# 接口地址 # 接口地址
VUE_APP_BASE_API = 'http://192.168.0.110:8094' VUE_APP_BASE_API = 'http://192.168.0.114:8094'
VUE_APP_WS_API = 'ws://localhost:8088' VUE_APP_WS_API = 'ws://localhost:8088'
# 是否启用 babel-plugin-dynamic-import-node插件 # 是否启用 babel-plugin-dynamic-import-node插件

2
.env.production

@ -1,6 +1,6 @@
ENV = 'production' ENV = 'production'
# 接口地址 # 接口地址
VUE_APP_BASE_API = 'http://www.cyjyyjy.com:8095' VUE_APP_BASE_API = 'http://www.cyjyyjy.com:8094'
VUE_APP_WS_API = 'ws:///127.0.0.1:8001' VUE_APP_WS_API = 'ws:///127.0.0.1:8001'

BIN
dist.rar

Binary file not shown.

1
src/api/ResourcesCagetory.js

@ -24,4 +24,5 @@ export function edit(data) {
}) })
} }
export default { add, edit, del } export default { add, edit, del }

2
src/router/routers.js

@ -71,7 +71,7 @@ export const constantRouterMap = [
] ]
export default new Router({ export default new Router({
mode: 'history', mode: 'hash',
scrollBehavior: () => ({ y: 0 }), scrollBehavior: () => ({ y: 0 }),
routes: constantRouterMap routes: constantRouterMap
}) })

1
src/views/shop/demandHall/authentication.vue

@ -208,7 +208,6 @@ export default {
}) })
}, },
showDialog(row){ showDialog(row){
console.log(row)
this.authForm.examineId = row.id this.authForm.examineId = row.id
row.authenticationState == 2 ? this.authForm.type = 1 : this.authForm.type = 0 row.authenticationState == 2 ? this.authForm.type = 1 : this.authForm.type = 0
this.authForm.reason = row.reason this.authForm.reason = row.reason

10
src/views/shop/demandHall/projectList.vue

@ -32,16 +32,18 @@
<span v-if="scope.row.examineState == 3">审核不通过</span> <span v-if="scope.row.examineState == 3">审核不通过</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="projectState" label="立项书状态"> <!-- <el-table-column prop="projectState" label="立项书状态">
<template slot-scope="scope"> <template slot-scope="scope">
<span v-if="scope.row.examineState == 0">未开始</span> <span v-if="scope.row.examineState == 0">未开始</span>
<span v-if="scope.row.examineState == 1">进行中</span> <span v-if="scope.row.examineState == 1">进行中</span>
<span v-if="scope.row.examineState == 2">已结束</span> <span v-if="scope.row.examineState == 2">已结束</span>
</template> </template>
</el-table-column> </el-table-column> -->
<el-table-column label="操作" width="150px" align="center"> <el-table-column label="操作" width="150px" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="text" @click="openProject(scope.row)">{{scope.row.projectState == 0 ? '开启项目' : scope.row.projectState == 1 ?'项目进行中' : '项目已结束'}}</el-button></el-button> <el-button type="text" @click="openProject(scope.row)">
{{scope.row.examineState == 1 ? '审核' : ''}}
</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -133,7 +135,7 @@ export default {
}) })
}, },
openProject(row){ openProject(row){
if(row.projectState == 0){ if(row.examineState == 1){
this.$confirm('是否确定开启项目?', '提示', { this.$confirm('是否确定开启项目?', '提示', {
confirmButtonText: '确定', confirmButtonText: '确定',
cancelButtonText: '取消', cancelButtonText: '取消',

1
src/views/shop/projectManage/cooperationMode.vue

@ -41,7 +41,6 @@
<el-table-column v-if="columns.visible('name')" prop="name" label="合作模式名称" /> <el-table-column v-if="columns.visible('name')" prop="name" label="合作模式名称" />
<el-table-column v-if="columns.visible('content')" prop="content" label="合作模式简介" /> <el-table-column v-if="columns.visible('content')" prop="content" label="合作模式简介" />
<el-table-column v-if="columns.visible('stageNums')" prop="stageNums" label="合作模式阶段数" /> <el-table-column v-if="columns.visible('stageNums')" prop="stageNums" label="合作模式阶段数" />
<el-table-column v-if="columns.visible('isDel')" prop="isDel" label="isDel" />
<el-table-column v-permission="['admin','CooperationMode:edit','CooperationMode:del']" label="操作" width="150px" align="center"> <el-table-column v-permission="['admin','CooperationMode:edit','CooperationMode:del']" label="操作" width="150px" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<udOperation <udOperation

82
src/views/shop/projectManage/screenManage.vue

@ -7,24 +7,12 @@
<!--表单组件--> <!--表单组件-->
<el-dialog :close-on-click-modal="false" :before-close="crud.cancelCU" :visible.sync="crud.status.cu > 0" :title="crud.status.title" width="500px"> <el-dialog :close-on-click-modal="false" :before-close="crud.cancelCU" :visible.sync="crud.status.cu > 0" :title="crud.status.title" width="500px">
<el-form ref="form" :model="form" :rules="rules" size="small" label-width="80px"> <el-form ref="form" :model="form" :rules="rules" size="small" label-width="80px">
<el-form-item label="id" prop="id"> <el-form-item style="" label="上级分类" prop="pid">
<el-input v-model="form.id" style="width: 370px;" /> <treeselect v-model="form.parentId" :options="depts" style="width: 370px;" placeholder="选择上级分类" />
</el-form-item> </el-form-item>
<el-form-item label="分类名称"> <el-form-item label="分类名称">
<el-input v-model="form.cagetoryName" style="width: 370px;" /> <el-input v-model="form.cagetoryName" style="width: 370px;" />
</el-form-item> </el-form-item>
<el-form-item label="分类图标">
<el-input v-model="form.cagetoryLogo" style="width: 370px;" />
</el-form-item>
<el-form-item label="createTime">
<el-input v-model="form.createTime" style="width: 370px;" />
</el-form-item>
<el-form-item label="updateTime">
<el-input v-model="form.updateTime" style="width: 370px;" />
</el-form-item>
<el-form-item label="isDel">
<el-input v-model="form.isDel" style="width: 370px;" />
</el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button type="text" @click="crud.cancelCU">取消</el-button> <el-button type="text" @click="crud.cancelCU">取消</el-button>
@ -32,12 +20,17 @@
</div> </div>
</el-dialog> </el-dialog>
<!--表格渲染--> <!--表格渲染-->
<el-table ref="table" v-loading="crud.loading" :data="crud.data" size="small" style="width: 100%;" @selection-change="crud.selectionChangeHandler"> <el-table ref="table"
v-loading="crud.loading"
:data="tableData"
size="small"
style="width: 100%;"
:tree-props="{ children: 'children', hasChildren: 'hasChildren' }"
row-key="id"
@selection-change="crud.selectionChangeHandler">
<el-table-column type="selection" width="55" /> <el-table-column type="selection" width="55" />
<el-table-column v-if="columns.visible('id')" prop="id" label="id" />
<el-table-column v-if="columns.visible('cagetoryName')" prop="cagetoryName" label="分类名称" /> <el-table-column v-if="columns.visible('cagetoryName')" prop="cagetoryName" label="分类名称" />
<el-table-column v-if="columns.visible('cagetoryLogo')" prop="cagetoryLogo" label="分类图标" /> <el-table-column v-if="columns.visible('cagetoryLogo')" prop="cagetoryLogo" label="分类图标" />
<el-table-column v-if="columns.visible('isDel')" prop="isDel" label="isDel" />
<el-table-column v-permission="['admin','ResourcesCagetory:edit','ResourcesCagetory:del']" label="操作" width="150px" align="center"> <el-table-column v-permission="['admin','ResourcesCagetory:edit','ResourcesCagetory:del']" label="操作" width="150px" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<udOperation <udOperation
@ -61,16 +54,20 @@ import crudOperation from '@crud/CRUD.operation'
import udOperation from '@crud/UD.operation' import udOperation from '@crud/UD.operation'
import pagination from '@crud/Pagination' import pagination from '@crud/Pagination'
import MaterialList from "@/components/material"; import MaterialList from "@/components/material";
import Treeselect from '@riophae/vue-treeselect'
import '@riophae/vue-treeselect/dist/vue-treeselect.css'
import { initData } from '@/api/data'
// crudpresenter // crudpresenter
const defaultCrud = CRUD({ title: '资源分类表', url: 'api/ResourcesCagetory', sort: 'id,desc', crudMethod: { ...crudResourcesCagetory }}) const defaultCrud = CRUD({ title: '资源分类表', url: 'api/ResourcesCagetory', sort: 'id,desc', crudMethod: { ...crudResourcesCagetory }})
const defaultForm = { id: null, cagetoryName: null, cagetoryLogo: null, createTime: null, updateTime: null, isDel: null } const defaultForm = { id: null, cagetoryName: null, cagetoryLogo: null, createTime: null, updateTime: null, isDel: null }
export default { export default {
name: 'ResourcesCagetory', name: 'ResourcesCagetory',
components: { pagination, crudOperation, rrOperation, udOperation ,MaterialList}, components: { pagination, crudOperation, rrOperation, udOperation ,MaterialList, Treeselect},
mixins: [presenter(defaultCrud), header(), form(defaultForm), crud()], mixins: [presenter(defaultCrud), header(), form(defaultForm), crud()],
data() { data() {
return { return {
tableData:[],
permission: { permission: {
add: ['admin', 'ResourcesCagetory:add'], add: ['admin', 'ResourcesCagetory:add'],
edit: ['admin', 'ResourcesCagetory:edit'], edit: ['admin', 'ResourcesCagetory:edit'],
@ -80,17 +77,64 @@ export default {
id: [ id: [
{ required: true, message: '不能为空', trigger: 'blur' } { required: true, message: '不能为空', trigger: 'blur' }
] ]
} },
depts:[]
} }
}, },
watch: { watch: {
}, },
mounted(){
initData('/api/ResourcesCagetory',{
page: 1,
size: 100,
sort: ['id,desc'],
}).then((res)=>{
console.log(res)
// this.categoryList = res.content
this.depts = []
const dept = { id: 0, label: '顶级类目', children: [] }
res.content.forEach((item)=>{
item.label = item.cagetoryName
item.children = item.categoryList
item.categoryList.forEach((child)=>{
child.label = child.cagetoryName
child.children = child.categoryList
})
})
this.tableData = res.content
console.log(this.tableData)
dept.children = res.content
this.depts.push(dept)
})
},
methods: { methods: {
// //
[CRUD.HOOK.beforeRefresh]() { [CRUD.HOOK.beforeRefresh]() {
return true return true
}, // }, //
[CRUD.HOOK.afterToCU](crud, form) { [CRUD.HOOK.afterToCU](crud, form) {
initData('/api/ResourcesCagetory',{
page: 1,
size: 100,
sort: ['id,desc'],
}).then((res)=>{
console.log(res)
// this.categoryList = res.content
this.depts = []
const dept = { id: 0, label: '顶级类目', children: [] }
res.content.forEach((item)=>{
item.label = item.cagetoryName
item.children = item.categoryList
item.categoryList.forEach((child)=>{
child.label = child.cagetoryName
child.children = child.categoryList
})
})
this.tableData = res.content
console.log(this.tableData)
dept.children = res.content
this.depts.push(dept)
})
}, },
} }
} }

28
src/views/shop/user/index.vue

@ -33,6 +33,13 @@
@click="toQuery" @click="toQuery"
>刷新</el-button> >刷新</el-button>
<el-button class="filter-item" size="mini" type="warning" @click="moveMember">会员转移</el-button> <el-button class="filter-item" size="mini" type="warning" @click="moveMember">会员转移</el-button>
<el-button
class="filter-item"
size="mini"
type="warning"
icon="el-icon-download"
@click="doExport"
>导出</el-button>
</div> </div>
<!--表单组件--> <!--表单组件-->
<eForm ref="form" :is-add="isAdd" /> <eForm ref="form" :is-add="isAdd" />
@ -127,7 +134,9 @@ import { del, onStatus } from '@/api/yxUser'
import eForm from './form' import eForm from './form'
import pForm from './formp' import pForm from './formp'
import detail from './detail' import detail from './detail'
import { formatTime } from '@/utils/index' import { formatTime, downloadFile } from '@/utils/index'
import request from '@/utils/request'
import qs from 'qs'
export default { export default {
components: { eForm, pForm, detail }, components: { eForm, pForm, detail },
mixins: [initData], mixins: [initData],
@ -160,6 +169,23 @@ export default {
}) })
}, },
methods: { methods: {
doExport(){
let params = {
page: this.page,
size: this.size,
sort: 'id,desc',
isModel: ''}
request({
url: 'api/member/download' + '?' + qs.stringify(params, { indices: false }),
method: 'get',
responseType: 'blob'
}).then(result => {
downloadFile(result, '会员充值数据', 'xlsx')
}).catch(() => {
})
},
selectionChangeHandler(val){ selectionChangeHandler(val){
console.log(val) console.log(val)
}, },

Loading…
Cancel
Save