| | |
| | | # 开发环境配置 |
| | | NODE_ENV = 'development' |
| | | <<<<<<< HEAD |
| | | VUE_APP_API_URL = 'http://192.168.0.7/dianjiang_admin_api/' |
| | | ======= |
| | | |
| | | # 项目上下文路径 |
| | | VUE_APP_API_URL = 'https://test.doumee.cn/dianjiang_admin_api/' |
| | | # VUE_APP_API_URL = 'http://192.168.1.37:11010/' |
| | | VUE_APP_CONTEXT_PATH = '/' |
| | | VUE_APP_API_URL = 'http://localhost:11010' |
| | | >>>>>>> d5810177a4e77ea273971e51dd150bd84906de6f |
| | | |
| | |
| | | # 关闭DEBUG |
| | | VUE_APP_DEBUG = 'off' |
| | | VUE_APP_CONTEXT_PATH = '/dianjiang_admin' |
| | | VUE_APP_API_URL = 'https://jinkuai.832smartfarm.com/jinkuai_admin' |
| | | VUE_APP_API_URL = 'https://test.doumee.cn/' |
| | |
| | | } |
| | | } |
| | | }, |
| | | "dingtalk-h5-remote-debug": { |
| | | "version": "0.1.3", |
| | | "resolved": "https://registry.npmmirror.com/dingtalk-h5-remote-debug/-/dingtalk-h5-remote-debug-0.1.3.tgz", |
| | | "integrity": "sha512-ZEcPflCs5lFFY9vXeCz+M8tbn9kPSCkybYSIbvuSfvGkTb1tMqivr0Vo32CpxcT59nahuRXTfR0tHUIDuxVKfQ==" |
| | | }, |
| | | "dingtalk-jsapi": { |
| | | "version": "3.2.5", |
| | | "resolved": "https://registry.npmmirror.com/dingtalk-jsapi/-/dingtalk-jsapi-3.2.5.tgz", |
| | | "integrity": "sha512-GHtDTmilJQhr07GNarjlzhvgUkPWc0+52zbN2ToW+JzkydaOwmhiJCTO42+BI+onAlhdfLUbtUnGsjQNDTrM1w==", |
| | | "requires": { |
| | | "promise-polyfill": "^7.1.0" |
| | | } |
| | | }, |
| | | "dir-glob": { |
| | | "version": "2.2.2", |
| | | "resolved": "https://registry.npm.taobao.org/dir-glob/download/dir-glob-2.2.2.tgz", |
| | |
| | | "integrity": "sha1-mEcocL8igTL8vdhoEputEsPAKeM=", |
| | | "dev": true |
| | | }, |
| | | "promise-polyfill": { |
| | | "version": "7.1.2", |
| | | "resolved": "https://registry.npmmirror.com/promise-polyfill/-/promise-polyfill-7.1.2.tgz", |
| | | "integrity": "sha512-FuEc12/eKqqoRYIGBrUptCBRhobL19PS2U31vMNTfyck1FxPyMfgsXyW4Mav85y/ZN1hop3hOwRlUDok23oYfQ==" |
| | | }, |
| | | "proxy-addr": { |
| | | "version": "2.0.6", |
| | | "resolved": "https://registry.npm.taobao.org/proxy-addr/download/proxy-addr-2.0.6.tgz", |
| | |
| | | "core-js": "^3.6.5", |
| | | "crypto-js": "^4.1.1", |
| | | "dayjs": "^1.11.0", |
| | | "dingtalk-h5-remote-debug": "^0.1.3", |
| | | "dingtalk-jsapi": "^3.2.5", |
| | | "echarts": "^5.6.0", |
| | | "element-ui": "^2.3.6", |
| | | "js-cookie": "^2.2.1", |
| | |
| | | return request.get(`/business/category/delete/${id}`) |
| | | } |
| | | |
| | | // 战区信息同步 |
| | | export function syncZhanQu () { |
| | | return request.get(`/business/category/syncZhanQu`) |
| | | } |
| | | |
| | | // 批量删除 |
| | | export function deleteByIdInBatch (ids) { |
| | | return request.get('/business/category/delete/batch', { |
| | |
| | | export function upload (data) { |
| | | return request.post('/public/upload', data) |
| | | } |
| | | |
| | | // 钉钉授权登录 |
| | | export function loginByDingTalk (data) { |
| | | return request.post('/system/loginByDingTalk', data) |
| | | } |
| | | |
| | |
| | | containDeleted: 1, |
| | | name: '', |
| | | importId: '', |
| | | status: null |
| | | status: null, |
| | | memberId: null |
| | | }, |
| | | memberList: [] |
| | | } |
| | |
| | | this.title = title |
| | | this.visible = true |
| | | this.getTableHeight() |
| | | this.searchForm.memberId = memberId |
| | | this.tableData = { |
| | | // 已选中的数据 |
| | | selectedRows: [], |
| | |
| | | @confirm="confirm" |
| | | > |
| | | <el-form :model="form" ref="form" :rules="rules"> |
| | | <el-form-item label="名称" prop="name"> |
| | | <el-form-item label="标题" prop="name"> |
| | | <el-input v-model="form.name" placeholder="请输入名称" v-trim/> |
| | | </el-form-item> |
| | | <el-form-item label="老师" prop="memberId" > |
| | |
| | | <UploadImage |
| | | :fileList="tempfileList" |
| | | :uploadData="uploadData" |
| | | :size="5" |
| | | @beginUpload="isUploading=true" |
| | | @endUpload="isUploading=false"/> |
| | | <p class="tip-warn"> |
| | | 建议尺寸:750px X 750px |
| | | 支持png、jpg、jpeg格式,大小不超过2M,上传图片不允许涉及政治敏感与色情, |
| | | 支持png、jpg、jpeg格式,大小不超过5M,上传图片不允许涉及政治敏感与色情, |
| | | </p> |
| | | </el-form-item> |
| | | <el-form-item label="开始时间" prop="startDate" > |
| | |
| | | placeholder="开始时间" |
| | | ></el-date-picker> |
| | | </el-form-item> |
| | | <el-form-item label="导入时间" prop="endDate" > |
| | | <el-form-item label="结束时间" prop="endDate" > |
| | | <el-date-picker |
| | | clearable |
| | | v-model="form.endDate" |
| | |
| | | this.memberList = res |
| | | }) |
| | | }, |
| | | |
| | | confirm () { |
| | | this.form.fileList = this.tempfileList |
| | | if (this.form[this.configData['field.id']] == null || this.form[this.configData['field.id']] === '') { |
| | |
| | | <UploadImage |
| | | :fileList="tempfileList" |
| | | :uploadData="uploadData" |
| | | :size="5" |
| | | @beginUpload="isUploading=true" |
| | | @endUpload="isUploading=false"/> |
| | | <p class="tip-warn"> |
| | | 建议尺寸:750px X 750px,上限6张 |
| | | 支持png、jpg、jpeg格式,大小不超过2M,上传图片不允许涉及政治敏感与色情, |
| | | 支持png、jpg、jpeg格式,大小不超过5M,上传图片不允许涉及政治敏感与色情, |
| | | </p> |
| | | </el-form-item> |
| | | <el-form-item label="排序码" prop="sortnum"> |
| | | <el-form-item label="等级顺序" prop="sortnum" v-if="form.type == 3"> |
| | | <el-input v-model="form.sortnum" type="" placeholder="请输入排序码" v-trim/> |
| | | </el-form-item> |
| | | <el-form-item label="排序码" prop="sortnum" v-else> |
| | | <el-input v-model="form.sortnum" type="" placeholder="请输入排序码" v-trim/> |
| | | </el-form-item> |
| | | <el-form-item label="描述" prop="remark"> |
| | |
| | | tempfileList: [], |
| | | // 验证规则 |
| | | rules: { |
| | | name: [{ required: true, message: '请输入名称' }] |
| | | name: [{ required: true, message: '请输入名称' }], |
| | | detail: [{ required: true, message: '请输入战区编码' }] |
| | | } |
| | | } |
| | | }, |
| | |
| | | name: [{ required: true, message: '请输入姓名' }], |
| | | code: [{ required: true, message: '请输入工号' }], |
| | | imgurl: [{ required: true, message: '请上传职业照' }], |
| | | sex: [{ required: true, message: '请选择性别' }], |
| | | jobYear: [{ required: true, message: '请选择从业年份' }], |
| | | zhanquIdList: [{ required: true, message: '请选择服务战区' }], |
| | | bustypeIdList: [{ required: true, message: '请选择商业化类型' }], |
| | | levelId: [{ required: true, message: '请选择老师等级' }], |
| | | fieldIdList: [{ required: true, message: '请选择擅长领域' }], |
| | | content: [{ required: true, message: '请输入老师简介' }] |
| | | content: [{ required: true, message: '请输入老师简介' }], |
| | | fee: [{ required: true, message: '请输入费用标准' }] |
| | | } |
| | | } |
| | | }, |
| | |
| | | :style="customStyle" |
| | | action="" |
| | | :auto-upload="false" |
| | | :before-upload="beforeUpload" |
| | | :show-file-list="false" |
| | | :on-change='openUpdateIcon'> |
| | | <img v-if=" file.imgurlfull" style="width: 100%;" :src="file.imgurlfull" :style="customStyle" class="avatar"> |
| | |
| | | type: String, |
| | | default: 'width: 90px; height: 90px;' |
| | | }, |
| | | size: { |
| | | type: Number, |
| | | default: () => 5 |
| | | }, |
| | | uploadData: Object |
| | | }, |
| | | data () { |
| | |
| | | }, |
| | | |
| | | methods: { |
| | | beforeUpload (file) { |
| | | const isLt2M = file.size / 1024 / 1024 < this.size; |
| | | if (!isLt2M) { |
| | | this.$message.error(`上传图片大小不能超过${this.size}mb!`); |
| | | return false |
| | | } |
| | | return true |
| | | }, |
| | | uploadIcon () { |
| | | // 获取裁剪后的图片 |
| | | this.$refs.iconShot.getImagecropper().getCropBlob((fileData) => { // 获取当前裁剪好的数据 |
| | |
| | | type: Number, |
| | | default: () => null |
| | | }, |
| | | size: { |
| | | type: Number, |
| | | default: () => 1 |
| | | }, |
| | | uploadData: Object |
| | | }, |
| | | data () { |
| | |
| | | beforeUpload (file) { |
| | | this.$emit('beginUpload') |
| | | const isJPGOrPNG = file.type === 'image/jpeg' || file.type === 'image/png' |
| | | const isLt2M = file.size / 1024 / 1024 < 1; // 500kb |
| | | const isLt2M = file.size / 1024 / 1024 < this.size; |
| | | if (!isJPGOrPNG) { |
| | | this.$message.error('上传头像图片只能是 JPG/PNG 格式!'); |
| | | return false |
| | | } |
| | | if (!isLt2M) { |
| | | this.$message.error('上传头像图片大小不能超过 500KB!'); |
| | | this.$message.error(`上传图片大小不能超过${this.size}mb!`); |
| | | return false |
| | | } |
| | | return true |
| | |
| | | import { fetchMenuTree } from './api/system/menu' |
| | | import Treeselect from '@riophae/vue-treeselect' |
| | | import '@riophae/vue-treeselect/dist/vue-treeselect.css' |
| | | import { initDingH5RemoteDebug } from "dingtalk-h5-remote-debug"; |
| | | Vue.component('treeselect', Treeselect) |
| | | Vue.config.productionTip = false |
| | | initDingH5RemoteDebug(); |
| | | Vue.use(ElementUI, { |
| | | size: 'small' |
| | | }) |
| | |
| | | Vue.use(directives) |
| | | Vue.use(filters) |
| | | Vue.use(plugins) |
| | | |
| | | new Vue({ |
| | | data: { |
| | | loading: false |
| | |
| | | { |
| | | name: 'login', |
| | | path: '/login', |
| | | meta: { |
| | | refresh: true |
| | | }, |
| | | component: Login |
| | | }, |
| | | // 无权限 |
| | |
| | | }) |
| | | }, |
| | | methods: { |
| | | deleteById (row, childConfirm = true, call) { |
| | | this.__checkApi() |
| | | let message = `确认删除案例数据吗?` |
| | | if (childConfirm && row.children != null && row.children.length > 0) { |
| | | message = `确认删除案例数据吗?` |
| | | } |
| | | this.$dialog.deleteConfirm(message) |
| | | .then(() => { |
| | | this.isWorking.delete = true |
| | | this.api.deleteById(row[this.configData['field.id']]) |
| | | .then(() => { |
| | | this.__afterDelete() |
| | | if (call) { |
| | | call() |
| | | } |
| | | }) |
| | | .catch(e => { |
| | | this.$tip.apiFailed(e) |
| | | }) |
| | | .finally(() => { |
| | | this.isWorking.delete = false |
| | | }) |
| | | }) |
| | | .catch(() => {}) |
| | | }, |
| | | deleteByIdInBatch (childConfirm = true, call) { |
| | | this.__checkApi() |
| | | if (this.tableData.selectedRows.length === 0) { |
| | | this.$tip.warning('请至少选择一条数据') |
| | | return |
| | | } |
| | | let message = `确认删除案例数据吗?` |
| | | if (childConfirm) { |
| | | const containChildrenRows = [] |
| | | for (const row of this.tableData.selectedRows) { |
| | | if (row.children != null && row.children.length > 0) { |
| | | containChildrenRows.push(row[this.configData['field.main']]) |
| | | } |
| | | } |
| | | if (containChildrenRows.length > 0) { |
| | | message = `确认删除案例数据吗?` |
| | | } |
| | | } |
| | | this.$dialog.deleteConfirm(message) |
| | | .then(() => { |
| | | this.isWorking.delete = true |
| | | this.api.deleteByIdInBatch(this.tableData.selectedRows.map(row => row[this.configData['field.id']]).join(',')) |
| | | .then(() => { |
| | | this.__afterDelete(this.tableData.selectedRows.length) |
| | | if (call) { |
| | | call() |
| | | } |
| | | }) |
| | | .catch(e => { |
| | | this.$tip.apiFailed(e) |
| | | }) |
| | | .finally(() => { |
| | | this.isWorking.delete = false |
| | | }) |
| | | }) |
| | | .catch(() => {}) |
| | | }, |
| | | changeStatus (e, row) { |
| | | this.working = true |
| | | this.api.updateStatus({ id: row.id, status: e }) |
| | |
| | | <template v-slot:table-wrap> |
| | | <ul class="toolbar" v-permissions="['business:category:create', 'business:category:delete']"> |
| | | <li><el-button type="primary" @click="$refs.operaCategoryWindow.open('新建战区',null,searchForm.type)" icon="el-icon-plus" v-permissions="['business:category:create']">新建</el-button></li> |
| | | <li><el-button type="primary" icon="el-icon-refresh" v-permissions="['business:category:create']">同步</el-button></li> |
| | | <li><el-button type="primary" icon="el-icon-refresh" v-permissions="['business:category:create']" @click="synchronization">同步</el-button></li> |
| | | <li><el-button type="danger" @click="deleteByIdInBatch" icon="el-icon-delete" v-permissions="['business:category:delete']">删除</el-button></li> |
| | | </ul> |
| | | <el-table |
| | |
| | | import TableLayout from '@/layouts/TableLayout' |
| | | import Pagination from '@/components/common/Pagination' |
| | | import OperaCategoryWindow from '@/components/business/OperaCategoryWindow' |
| | | import { syncZhanQu } from '@/api/business/category' |
| | | export default { |
| | | name: 'Category', |
| | | extends: BaseTable, |
| | |
| | | this.search() |
| | | }, |
| | | methods: { |
| | | synchronization() { |
| | | this.$dialog.deleteConfirm('确认同步战区信息吗?') |
| | | .then(() => { |
| | | syncZhanQu() |
| | | .then(res=>{ |
| | | if (res.code === 200) { |
| | | this.$message.success('同步成功!') |
| | | } |
| | | }) |
| | | }) |
| | | .catch(() => {}) |
| | | }, |
| | | deleteById (row, childConfirm = true, call) { |
| | | this.__checkApi() |
| | | let message = `确认删除战区数据吗?` |
| | | if (childConfirm && row.children != null && row.children.length > 0) { |
| | | message = `确认删除战区数据吗?` |
| | | } |
| | | this.$dialog.deleteConfirm(message) |
| | | .then(() => { |
| | | this.isWorking.delete = true |
| | | this.api.deleteById(row[this.configData['field.id']]) |
| | | .then(() => { |
| | | this.__afterDelete() |
| | | if (call) { |
| | | call() |
| | | } |
| | | }) |
| | | .catch(e => { |
| | | this.$tip.apiFailed(e) |
| | | }) |
| | | .finally(() => { |
| | | this.isWorking.delete = false |
| | | }) |
| | | }) |
| | | .catch(() => {}) |
| | | }, |
| | | deleteByIdInBatch (childConfirm = true, call) { |
| | | this.__checkApi() |
| | | if (this.tableData.selectedRows.length === 0) { |
| | | this.$tip.warning('请至少选择一条数据') |
| | | return |
| | | } |
| | | let message = `确认删除战区数据吗?` |
| | | if (childConfirm) { |
| | | const containChildrenRows = [] |
| | | for (const row of this.tableData.selectedRows) { |
| | | if (row.children != null && row.children.length > 0) { |
| | | containChildrenRows.push(row[this.configData['field.main']]) |
| | | } |
| | | } |
| | | if (containChildrenRows.length > 0) { |
| | | message = `确认删除战区数据吗?` |
| | | } |
| | | } |
| | | this.$dialog.deleteConfirm(message) |
| | | .then(() => { |
| | | this.isWorking.delete = true |
| | | this.api.deleteByIdInBatch(this.tableData.selectedRows.map(row => row[this.configData['field.id']]).join(',')) |
| | | .then(() => { |
| | | this.__afterDelete(this.tableData.selectedRows.length) |
| | | if (call) { |
| | | call() |
| | | } |
| | | }) |
| | | .catch(e => { |
| | | this.$tip.apiFailed(e) |
| | | }) |
| | | .finally(() => { |
| | | this.isWorking.delete = false |
| | | }) |
| | | }) |
| | | .catch(() => {}) |
| | | }, |
| | | changeStatus (e, row) { |
| | | this.working = true |
| | | this.api.updateStatus({ id: row.id, status: e }) |
| | |
| | | <TableLayout :permissions="['business:category:query']"> |
| | | <!-- 搜索表单 --> |
| | | <el-form ref="searchForm" slot="search-form" :model="searchForm" label-width="100px" inline> |
| | | <el-form-item label="名称" prop="name"> |
| | | <el-input v-model="searchForm.name" placeholder="请输入名称" @keypress.enter.native="search"></el-input> |
| | | <el-form-item label="商业化类型" prop="name"> |
| | | <el-input v-model="searchForm.name" placeholder="请输入商业化类型" @keypress.enter.native="search"></el-input> |
| | | </el-form-item> |
| | | <section> |
| | | <el-button type="primary" @click="search">搜索</el-button> |
| | |
| | | <template v-slot:table-wrap> |
| | | <ul class="toolbar" v-permissions="['business:category:create', 'business:category:delete']"> |
| | | <li><el-button type="primary" @click="$refs.operaCategoryWindow.open('新建商业化类型',null,searchForm.type)" icon="el-icon-plus" v-permissions="['business:category:create']">新建</el-button></li> |
| | | <li><el-button @click="deleteByIdInBatch" icon="el-icon-delete" v-permissions="['business:category:delete']">删除</el-button></li> |
| | | <li><el-button type="danger" @click="deleteByIdInBatch" icon="el-icon-delete" v-permissions="['business:category:delete']">删除</el-button></li> |
| | | </ul> |
| | | <el-table |
| | | :height="tableHeightNew" |
| | |
| | | > |
| | | <template slot-scope="{row}"> |
| | | <el-button type="text" @click="$refs.operaCategoryWindow.open('编辑商业化类型', row,searchForm.type)" icon="el-icon-edit" v-permissions="['business:category:update']">编辑</el-button> |
| | | <el-button type="text" @click="deleteById(row)" icon="el-icon-delete" v-permissions="['business:category:delete']">删除</el-button> |
| | | <el-button type="text" style="color: red" @click="deleteById(row)" icon="el-icon-delete" v-permissions="['business:category:delete']">删除</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | |
| | | this.search() |
| | | }, |
| | | methods: { |
| | | deleteById (row, childConfirm = true, call) { |
| | | this.__checkApi() |
| | | let message = `确认删除商业化类型数据吗?` |
| | | if (childConfirm && row.children != null && row.children.length > 0) { |
| | | message = `确认删除商业化类型数据吗?` |
| | | } |
| | | this.$dialog.deleteConfirm(message) |
| | | .then(() => { |
| | | this.isWorking.delete = true |
| | | this.api.deleteById(row[this.configData['field.id']]) |
| | | .then(() => { |
| | | this.__afterDelete() |
| | | if (call) { |
| | | call() |
| | | } |
| | | }) |
| | | .catch(e => { |
| | | this.$tip.apiFailed(e) |
| | | }) |
| | | .finally(() => { |
| | | this.isWorking.delete = false |
| | | }) |
| | | }) |
| | | .catch(() => {}) |
| | | }, |
| | | deleteByIdInBatch (childConfirm = true, call) { |
| | | this.__checkApi() |
| | | if (this.tableData.selectedRows.length === 0) { |
| | | this.$tip.warning('请至少选择一条数据') |
| | | return |
| | | } |
| | | let message = `确认删除商业化类型数据吗?` |
| | | if (childConfirm) { |
| | | const containChildrenRows = [] |
| | | for (const row of this.tableData.selectedRows) { |
| | | if (row.children != null && row.children.length > 0) { |
| | | containChildrenRows.push(row[this.configData['field.main']]) |
| | | } |
| | | } |
| | | if (containChildrenRows.length > 0) { |
| | | message = `确认删除商业化类型数据吗?` |
| | | } |
| | | } |
| | | this.$dialog.deleteConfirm(message) |
| | | .then(() => { |
| | | this.isWorking.delete = true |
| | | this.api.deleteByIdInBatch(this.tableData.selectedRows.map(row => row[this.configData['field.id']]).join(',')) |
| | | .then(() => { |
| | | this.__afterDelete(this.tableData.selectedRows.length) |
| | | if (call) { |
| | | call() |
| | | } |
| | | }) |
| | | .catch(e => { |
| | | this.$tip.apiFailed(e) |
| | | }) |
| | | .finally(() => { |
| | | this.isWorking.delete = false |
| | | }) |
| | | }) |
| | | .catch(() => {}) |
| | | }, |
| | | isChangeSelected(row,index){ |
| | | // if(row.isFixed ==1) { |
| | | // return false |
| | |
| | | <template v-slot:table-wrap> |
| | | <ul class="toolbar" v-permissions="['business:category:create', 'business:category:delete']"> |
| | | <li><el-button type="primary" @click="$refs.operaCategoryWindow.open('新建擅长领域',null,searchForm.type)" icon="el-icon-plus" v-permissions="['business:category:create']">新建</el-button></li> |
| | | <li><el-button @click="deleteByIdInBatch" icon="el-icon-delete" v-permissions="['business:category:delete']">删除</el-button></li> |
| | | <li><el-button type="danger" @click="deleteByIdInBatch" icon="el-icon-delete" v-permissions="['business:category:delete']">删除</el-button></li> |
| | | </ul> |
| | | <el-table |
| | | :height="tableHeightNew" |
| | |
| | | this.search() |
| | | }, |
| | | methods: { |
| | | deleteById (row, childConfirm = true, call) { |
| | | this.__checkApi() |
| | | let message = `确认删除擅长领域数据吗?` |
| | | if (childConfirm && row.children != null && row.children.length > 0) { |
| | | message = `确认删除擅长领域数据吗?` |
| | | } |
| | | this.$dialog.deleteConfirm(message) |
| | | .then(() => { |
| | | this.isWorking.delete = true |
| | | this.api.deleteById(row[this.configData['field.id']]) |
| | | .then(() => { |
| | | this.__afterDelete() |
| | | if (call) { |
| | | call() |
| | | } |
| | | }) |
| | | .catch(e => { |
| | | this.$tip.apiFailed(e) |
| | | }) |
| | | .finally(() => { |
| | | this.isWorking.delete = false |
| | | }) |
| | | }) |
| | | .catch(() => {}) |
| | | }, |
| | | deleteByIdInBatch (childConfirm = true, call) { |
| | | this.__checkApi() |
| | | if (this.tableData.selectedRows.length === 0) { |
| | | this.$tip.warning('请至少选择一条数据') |
| | | return |
| | | } |
| | | let message = `确认删除擅长领域数据吗?` |
| | | if (childConfirm) { |
| | | const containChildrenRows = [] |
| | | for (const row of this.tableData.selectedRows) { |
| | | if (row.children != null && row.children.length > 0) { |
| | | containChildrenRows.push(row[this.configData['field.main']]) |
| | | } |
| | | } |
| | | if (containChildrenRows.length > 0) { |
| | | message = `确认删除擅长领域数据吗?` |
| | | } |
| | | } |
| | | this.$dialog.deleteConfirm(message) |
| | | .then(() => { |
| | | this.isWorking.delete = true |
| | | this.api.deleteByIdInBatch(this.tableData.selectedRows.map(row => row[this.configData['field.id']]).join(',')) |
| | | .then(() => { |
| | | this.__afterDelete(this.tableData.selectedRows.length) |
| | | if (call) { |
| | | call() |
| | | } |
| | | }) |
| | | .catch(e => { |
| | | this.$tip.apiFailed(e) |
| | | }) |
| | | .finally(() => { |
| | | this.isWorking.delete = false |
| | | }) |
| | | }) |
| | | .catch(() => {}) |
| | | }, |
| | | isChangeSelected(row,index){ |
| | | // if(row.isFixed ==1) { |
| | | // return false |
| | |
| | | <template v-slot:table-wrap> |
| | | <ul class="toolbar" v-permissions="['business:category:create', 'business:category:delete']"> |
| | | <li><el-button type="primary" @click="$refs.operaCategoryWindow.open('新建老师等级',null,searchForm.type)" icon="el-icon-plus" v-permissions="['business:category:create']">新建</el-button></li> |
| | | <li><el-button @click="deleteByIdInBatch" icon="el-icon-delete" v-permissions="['business:category:delete']">删除</el-button></li> |
| | | <li><el-button type="danger" @click="deleteByIdInBatch" icon="el-icon-delete" v-permissions="['business:category:delete']">删除</el-button></li> |
| | | </ul> |
| | | <el-table |
| | | :height="tableHeightNew" |
| | |
| | | this.search() |
| | | }, |
| | | methods: { |
| | | deleteById (row, childConfirm = true, call) { |
| | | this.__checkApi() |
| | | let message = `确认删除老师等级数据吗?` |
| | | if (childConfirm && row.children != null && row.children.length > 0) { |
| | | message = `确认删除老师等级数据吗?` |
| | | } |
| | | this.$dialog.deleteConfirm(message) |
| | | .then(() => { |
| | | this.isWorking.delete = true |
| | | this.api.deleteById(row[this.configData['field.id']]) |
| | | .then(() => { |
| | | this.__afterDelete() |
| | | if (call) { |
| | | call() |
| | | } |
| | | }) |
| | | .catch(e => { |
| | | this.$tip.apiFailed(e) |
| | | }) |
| | | .finally(() => { |
| | | this.isWorking.delete = false |
| | | }) |
| | | }) |
| | | .catch(() => {}) |
| | | }, |
| | | deleteByIdInBatch (childConfirm = true, call) { |
| | | this.__checkApi() |
| | | if (this.tableData.selectedRows.length === 0) { |
| | | this.$tip.warning('请至少选择一条数据') |
| | | return |
| | | } |
| | | let message = `确认删除老师等级数据吗?` |
| | | if (childConfirm) { |
| | | const containChildrenRows = [] |
| | | for (const row of this.tableData.selectedRows) { |
| | | if (row.children != null && row.children.length > 0) { |
| | | containChildrenRows.push(row[this.configData['field.main']]) |
| | | } |
| | | } |
| | | if (containChildrenRows.length > 0) { |
| | | message = `确认删除老师等级数据吗?` |
| | | } |
| | | } |
| | | this.$dialog.deleteConfirm(message) |
| | | .then(() => { |
| | | this.isWorking.delete = true |
| | | this.api.deleteByIdInBatch(this.tableData.selectedRows.map(row => row[this.configData['field.id']]).join(',')) |
| | | .then(() => { |
| | | this.__afterDelete(this.tableData.selectedRows.length) |
| | | if (call) { |
| | | call() |
| | | } |
| | | }) |
| | | .catch(e => { |
| | | this.$tip.apiFailed(e) |
| | | }) |
| | | .finally(() => { |
| | | this.isWorking.delete = false |
| | | }) |
| | | }) |
| | | .catch(() => {}) |
| | | }, |
| | | isChangeSelected(row,index){ |
| | | // if(row.isFixed ==1) { |
| | | // return false |
| | |
| | | <TableLayout :permissions="['business:member:query']"> |
| | | <!-- 搜索表单 --> |
| | | <el-form ref="searchForm" slot="search-form" :model="searchForm" label-width="100px" inline> |
| | | <el-form-item label="名称" prop="name"> |
| | | <el-input v-model="searchForm.name" style="width: 150px" placeholder="请输入名称" @keypress.enter.native="search"></el-input> |
| | | <el-form-item label="姓名" prop="name"> |
| | | <el-input v-model="searchForm.name" style="width: 150px" placeholder="请输入姓名" @keypress.enter.native="search"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="工号" prop="code"> |
| | | <el-input v-model="searchForm.code" style="width: 150px" placeholder="请输入工号" @keypress.enter.native="search"></el-input> |
| | |
| | | ></el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="商业化类型" prop="bustypeIds"> |
| | | <el-form-item label="商业化类型" prop="bustypeIdList"> |
| | | <el-select |
| | | v-model="searchForm.bustypeIds" |
| | | v-model="searchForm.bustypeIdList" |
| | | style="width: 150px" |
| | | placeholder="商业化类型" |
| | | clearable |
| | | multiple |
| | | @change="search" |
| | | > |
| | | <el-option |
| | |
| | | </el-table-column> |
| | | <el-table-column prop="positon" label="岗位" min-width="120px"></el-table-column> |
| | | <el-table-column prop="levelName" label="等级" min-width="100px"></el-table-column> |
| | | <el-table-column prop="jobYear" label="从业年份" min-width="100px"></el-table-column> |
| | | <el-table-column prop="workYears" label="从业年份" min-width="100px"> |
| | | <template slot-scope="{row}"> |
| | | {{row.workYears}}年 |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="serveNum" label="服务商场" min-width="100px"> |
| | | <template slot-scope="{row}"> |
| | | <span v-if="row.serveNum">{{row.serveNum}}个</span> |
| | |
| | | levelId:null, |
| | | fieldIdList: [], |
| | | zhanquIds:null, |
| | | bustypeIds:null, |
| | | bustypeIdList:[], |
| | | type: 0 |
| | | }, |
| | | cateList:[] |
| | |
| | | |
| | | }, |
| | | methods: { |
| | | deleteById (row, childConfirm = true, call) { |
| | | this.__checkApi() |
| | | let message = `确认删除老师数据吗?` |
| | | if (childConfirm && row.children != null && row.children.length > 0) { |
| | | message = `确认删除老师数据吗?` |
| | | } |
| | | this.$dialog.deleteConfirm(message) |
| | | .then(() => { |
| | | this.isWorking.delete = true |
| | | this.api.deleteById(row[this.configData['field.id']]) |
| | | .then(() => { |
| | | this.__afterDelete() |
| | | if (call) { |
| | | call() |
| | | } |
| | | }) |
| | | .catch(e => { |
| | | this.$tip.apiFailed(e) |
| | | }) |
| | | .finally(() => { |
| | | this.isWorking.delete = false |
| | | }) |
| | | }) |
| | | .catch(() => {}) |
| | | }, |
| | | deleteByIdInBatch (childConfirm = true, call) { |
| | | this.__checkApi() |
| | | if (this.tableData.selectedRows.length === 0) { |
| | | this.$tip.warning('请至少选择一条数据') |
| | | return |
| | | } |
| | | let message = `确认删除老师数据吗?` |
| | | if (childConfirm) { |
| | | const containChildrenRows = [] |
| | | for (const row of this.tableData.selectedRows) { |
| | | if (row.children != null && row.children.length > 0) { |
| | | containChildrenRows.push(row[this.configData['field.main']]) |
| | | } |
| | | } |
| | | if (containChildrenRows.length > 0) { |
| | | message = `确认删除老师数据吗?` |
| | | } |
| | | } |
| | | this.$dialog.deleteConfirm(message) |
| | | .then(() => { |
| | | this.isWorking.delete = true |
| | | this.api.deleteByIdInBatch(this.tableData.selectedRows.map(row => row[this.configData['field.id']]).join(',')) |
| | | .then(() => { |
| | | this.__afterDelete(this.tableData.selectedRows.length) |
| | | if (call) { |
| | | call() |
| | | } |
| | | }) |
| | | .catch(e => { |
| | | this.$tip.apiFailed(e) |
| | | }) |
| | | .finally(() => { |
| | | this.isWorking.delete = false |
| | | }) |
| | | }) |
| | | .catch(() => {}) |
| | | }, |
| | | changeStatus (e, row) { |
| | | this.working = true |
| | | this.api.updateStatus({ id: row.id, status: e }) |
| | |
| | | |
| | | <script> |
| | | import { mapMutations } from 'vuex' |
| | | import { getCaptcha, loginByPassword } from '@/api/system/common' |
| | | |
| | | import { getCaptcha, loginByPassword, loginByDingTalk } from '@/api/system/common' |
| | | import * as dd from 'dingtalk-jsapi'; |
| | | export default { |
| | | name: 'Login', |
| | | data () { |
| | |
| | | loading: false, |
| | | username: '', |
| | | password: '', |
| | | unionId: '', |
| | | // 验证码 |
| | | captcha: { |
| | | loading: false, |
| | |
| | | username: this.username.trim(), |
| | | password: this.password, |
| | | code: this.captcha.value.trim(), |
| | | uuid: this.captcha.uuid |
| | | uuid: this.captcha.uuid, |
| | | unionId: this.unionId |
| | | },true) |
| | | .then(() => { |
| | | window.location.href = process.env.VUE_APP_CONTEXT_PATH |
| | |
| | | }, |
| | | created () { |
| | | this.refreshCaptcha() |
| | | var that = this |
| | | let href = window.location.href; |
| | | let corpId = '' |
| | | if (dd.env.platform !== 'notInDingTalk') { |
| | | // 先判断地址上有没有corpId |
| | | if (href.indexOf('?corpid=') !== -1) { |
| | | alert('从地址拿corpid') |
| | | corpId = href.substring(href.lastIndexOf('?corpid=') + 8, href.lastIndexOf('#')) |
| | | window.localStorage.setItem('corpId', corpId) |
| | | // 判断浏览器缓存是否有corpId |
| | | } else if (window.localStorage.getItem('corpId')) { |
| | | corpId = window.localStorage.getItem('corpId') |
| | | alert('从缓存拿corpid') |
| | | } |
| | | dd.requestAuthCode({ |
| | | corpId: corpId, |
| | | clientId: 'dingulzemj5bynjciapg', |
| | | onSuccess: function(result) { |
| | | loginByDingTalk({ |
| | | code: result.code, |
| | | corpId: corpId |
| | | }).then(res => { |
| | | if (res.loginStatus) { |
| | | window.location.href = process.env.VUE_APP_CONTEXT_PATH |
| | | return |
| | | } |
| | | that.unionId = res.unionId |
| | | }) |
| | | } |
| | | }); |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | |
| | | } |
| | | }); |
| | | } else if (href.indexOf('?token') !== -1) { |
| | | let token = href.substring(href.lastIndexOf('?token=') + 7, href.length) |
| | | let token = href.substring(href.lastIndexOf('?token=') + 7, href.lastIndexOf('#')) |
| | | that.$store.commit('setToken', token) |
| | | that.$isResolve() |
| | | } else { |
| | |
| | | }) |
| | | Vue.prototype.$dd = dd |
| | | Vue.prototype.$baseUrl = 'https://test.doumee.cn/dianjiang_web_api/' |
| | | // Vue.prototype.$baseUrl = 'http://192.168.0.7/dianjiang_web_api/' |
| | | Vue.prototype.vconsole = new vconsole(); |
| | | |
| | | initDingH5RemoteDebug(); |
| | |
| | | </view> |
| | | </view> |
| | | </view> |
| | | <view class="card"> |
| | | <view class="card" v-if="item.casesList"> |
| | | <view class="card-title"> |
| | | <view class="card-title-xian"></view> |
| | | <text>优秀项目案例 (40)</text> |
| | | <text>优秀项目案例 ({{item.casesList.length}})</text> |
| | | </view> |
| | | <view class="work"> |
| | | <view class="work-item" v-for="(child, index) in item.casesList" :key="index"> |
| | |
| | | </view> |
| | | <view class="left-info">{{child.detail}}</view> |
| | | </view> |
| | | <view class="right" v-if="child.fileList && child.fileList.length > 0" @click="yulan"> |
| | | <view class="right" v-if="child.fileList && child.fileList.length > 0" @click="yulan(index, child.fileList[0].url)"> |
| | | <image :src="child.fileList[0].url" mode="widthFix"></image> |
| | | <view class="right-num">共{{child.fileList.length}}张</view> |
| | | </view> |
| | |
| | | this.getDetails() |
| | | }, |
| | | methods: { |
| | | yulan(index, url) { |
| | | uni.previewImage({ |
| | | current: url, |
| | | urls: this.item.casesList[index].fileList.map(item => item.url) |
| | | }) |
| | | }, |
| | | zhankai() { |
| | | this.item.zhankai = !this.item.zhankai |
| | | }, |
| | |
| | | res.data.zhankai = false |
| | | res.data.contentCopy = res.data.content.substring(0, 30) + '...' |
| | | } |
| | | let arr = [] |
| | | res.data.fieldList.forEach(item => { |
| | | if (item.remark) { |
| | | arr.push(item) |
| | | } |
| | | }) |
| | | res.data.fieldList = arr; |
| | | this.item = res.data |
| | | } |
| | | }) |
| | |
| | | } |
| | | .item-info-a { |
| | | display: flex; |
| | | align-items: center; |
| | | align-items: flex-start; |
| | | text { |
| | | &:nth-child(1) { |
| | | flex-shrink: 0; |
| | | font-weight: 600; |
| | | font-size: 30rpx; |
| | | color: #222222; |
| | | } |
| | | &:nth-child(2) { |
| | | width: 300rpx; |
| | | font-weight: 400; |
| | | font-size: 24rpx; |
| | | color: #777777; |
| | | margin-left: 10rpx; |
| | | margin-top: 7rpx; |
| | | } |
| | | } |
| | | } |
| | |
| | | display: flex; |
| | | flex-wrap: wrap; |
| | | align-items: center; |
| | | margin-top: 8rpx; |
| | | margin-top: 16rpx; |
| | | .item-info-b-row { |
| | | padding: 0 8rpx; |
| | | box-sizing: border-box; |
| | |
| | | font-size: 22rpx; |
| | | color: #2E68C4; |
| | | margin-right: 8rpx; |
| | | margin-bottom: 8rpx; |
| | | &:last-child { |
| | | margin: 0; |
| | | margin-right: 0; |
| | | } |
| | | } |
| | | } |
| | |
| | | } |
| | | .item-info-d { |
| | | width: 100%; |
| | | line-height: 40rpx; |
| | | font-weight: 400; |
| | | font-size: 24rpx; |
| | | color: #333333; |
| | |
| | | .card-list-item { |
| | | display: flex; |
| | | flex-direction: column; |
| | | margin-bottom: 20rpx; |
| | | margin-bottom: 30rpx; |
| | | &:last-child { |
| | | margin: 0 !important; |
| | | } |
| | |
| | | font-weight: 500; |
| | | font-size: 28rpx; |
| | | color: #333333; |
| | | margin-bottom: 15rpx; |
| | | } |
| | | .card-list-item-text { |
| | | font-weight: 500; |
| | | font-weight: 400; |
| | | font-size: 26rpx; |
| | | color: #666666; |
| | | } |
| | |
| | | <view class="index"> |
| | | <view class="zhezhao" v-show="view" @click="view = null"></view> |
| | | <view class="head"> |
| | | <view class="head-title"> |
| | | <view class="head-title-left" @click="jumpList"> |
| | | <image src="/static/ic_paihang@2x.png" mode="widthFix"></image> |
| | | <text>排行榜</text> |
| | | </view> |
| | | <view class="head-title-name">选择点将老师</view> |
| | | <view class="head-title-left" style="opacity: 0;"> |
| | | <image src="/static/ic_paihang@2x.png" mode="widthFix"></image> |
| | | <text>排行榜</text> |
| | | </view> |
| | | </view> |
| | | <view class="head-search"> |
| | | <view class="head-search-input"> |
| | | <u-search placeholder="请输入老师姓名" height="36" v-model="form.name" :showAction="false" @search="search"></u-search> |
| | | <view class="head-title-left" @click="jumpList"> |
| | | <image src="/static/ic_paihang@2x.png" mode="widthFix"></image> |
| | | <text>排行榜</text> |
| | | </view> |
| | | <view class="head-search-input-right"> |
| | | <u-search placeholder="请输入老师姓名" height="36" v-model="form.name" :showAction="false" @search="search" @clear="search"></u-search> |
| | | </view> |
| | | </view> |
| | | <view class="cate"> |
| | | <view class="cate-item" @click="clickRow(1)"> |
| | | <text :style="{ fontWeight: (view === 1 || form.bustypeIds) ? 'bold' : '', color: (view === 1 || form.bustypeIds) ? '#222222' : '' }">{{form.bustypeIds ? form.bustypeName : '商业化类型'}}</text> |
| | | <image src="/static/ar_open_sel8@2x.png" mode="widthFix" v-if="view === 1"></image> |
| | | <image src="/static/ar_open_sel@2x.png" mode="widthFix" v-else-if="view !== 1 && form.bustypeIds"></image> |
| | | <image src="/static/ar_open7@2x.png" mode="widthFix" v-else></image> |
| | | </view> |
| | | <view class="cate-item" @click="clickRow(2)"> |
| | | <text :style="{ fontWeight: (view === 2 || form.fieldIds) ? 'bold' : '', color: (view === 2 || form.fieldIds) ? '#222222' : '' }">擅长领域</text> |
| | | <text :style="{ fontWeight: (view === 2 || form.fieldIdList.length > 0) ? 'bold' : '', color: (view === 2 || form.fieldIdList.length > 0) ? '#222222' : '' }">擅长领域</text> |
| | | <image src="/static/ar_open_sel8@2x.png" mode="widthFix" v-if="view === 2"></image> |
| | | <image src="/static/ar_open_sel@2x.png" mode="widthFix" v-else-if="view !== 2 && form.fieldIdList.length > 0"></image> |
| | | <image src="/static/ar_open7@2x.png" mode="widthFix" v-else></image> |
| | | </view> |
| | | <view class="cate-item" @click="clickRow(3)"> |
| | | <text :style="{ fontWeight: (view === 3 || form.orderByType) ? 'bold' : '', color: (view === 3 || form.orderByType) ? '#222222' : '' }">{{form.orderByType ? form.orderByName : '默认排序'}}</text> |
| | | <image src="/static/ar_open_sel8@2x.png" mode="widthFix" v-if="view === 3"></image> |
| | | <image src="/static/ar_open_sel@2x.png" mode="widthFix" v-else-if="view !== 3 && form.orderByType"></image> |
| | | <image src="/static/ar_open7@2x.png" mode="widthFix" v-else></image> |
| | | </view> |
| | | </view> |
| | |
| | | form: { |
| | | orderByType: '', |
| | | orderByName: '', |
| | | fieldIds: '', |
| | | fieldIdList: [], |
| | | bustypeIds: '', |
| | | bustypeName: '', |
| | | name: '' |
| | |
| | | list1: [], |
| | | list2: [], |
| | | list3: [ |
| | | { name: '默认排序', id: '', active: true }, |
| | | { name: '收费从高到低', id: '0', active: false }, |
| | | { name: '收费从低到高', id: '1', active: false }, |
| | | { name: '等级从高到低', id: '2', active: false }, |
| | |
| | | this.$u.api.memberPage({ |
| | | capacity: 10, |
| | | page: this.page, |
| | | model: this.form |
| | | model: { |
| | | orderByType: this.form.orderByType ? this.form.orderByType : 3, |
| | | orderByName: this.form.orderByName, |
| | | fieldIdList: this.form.fieldIdList, |
| | | bustypeIds: this.form.bustypeIds, |
| | | bustypeName: this.form.bustypeName, |
| | | name: this.form.name |
| | | } |
| | | }).then(res => { |
| | | if (res.code === 200) { |
| | | res.data.records.forEach(item => { |
| | |
| | | this.view = null |
| | | } else if (type === 2) { |
| | | this.list2[i].active = !this.list2[i].active |
| | | this.form.fieldIds = this.list2.filter(item => item.active).map(item => item.id).join(',') |
| | | this.form.fieldIdList = this.list2.filter(item => item.active).map(item => item.id) |
| | | this.$forceUpdate() |
| | | } else { |
| | | this.form.orderByType = this.list3[i].id |
| | |
| | | if (res.code === 200) { |
| | | res.data.active = false |
| | | this.list1 = res.data |
| | | this.list1.unshift({ name: '全部', id: null, active: true }) |
| | | } |
| | | }) |
| | | this.$u.api.categoryList({ type: 2 }) |
| | |
| | | width: 100%; |
| | | background: #FFFFFF; |
| | | border-radius: 8rpx; |
| | | padding: 24rpx; |
| | | padding: 30rpx; |
| | | box-sizing: border-box; |
| | | display: flex; |
| | | align-items: flex-start; |
| | |
| | | } |
| | | .item-info-a { |
| | | display: flex; |
| | | align-items: center; |
| | | align-items: flex-start; |
| | | text { |
| | | &:nth-child(1) { |
| | | flex-shrink: 0; |
| | | font-weight: 600; |
| | | font-size: 30rpx; |
| | | color: #222222; |
| | | } |
| | | &:nth-child(2) { |
| | | width: 280rpx; |
| | | font-weight: 400; |
| | | font-size: 24rpx; |
| | | color: #777777; |
| | | margin-left: 10rpx; |
| | | margin-top: 7rpx; |
| | | } |
| | | } |
| | | } |
| | |
| | | display: flex; |
| | | flex-wrap: wrap; |
| | | align-items: center; |
| | | margin-top: 8rpx; |
| | | margin-top: 16rpx; |
| | | .item-info-b-row { |
| | | padding: 0 8rpx; |
| | | box-sizing: border-box; |
| | |
| | | font-size: 22rpx; |
| | | color: #2E68C4; |
| | | margin-right: 8rpx; |
| | | margin-bottom: 8rpx; |
| | | &:last-child { |
| | | margin: 0; |
| | | margin-right: 0; |
| | | } |
| | | } |
| | | } |
| | |
| | | } |
| | | .item-info-d { |
| | | width: 100%; |
| | | line-height: 40rpx; |
| | | font-weight: 400; |
| | | font-size: 24rpx; |
| | | color: #333333; |
| | |
| | | } |
| | | .head { |
| | | width: 100%; |
| | | height: 260rpx; |
| | | height: 172rpx; |
| | | padding-top: 12rpx; |
| | | box-sizing: border-box; |
| | | position: sticky; |
| | | top: 0; |
| | | left: 0; |
| | | z-index: 9; |
| | | background-color: #ffffff; |
| | | .head-title { |
| | | width: 100%; |
| | | height: 88rpx; |
| | | padding: 0 30rpx; |
| | | box-sizing: border-box; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: space-between; |
| | | .head-title-left { |
| | | display: flex; |
| | | align-items: center; |
| | | image { |
| | | width: 40rpx; |
| | | height: 40rpx; |
| | | } |
| | | text { |
| | | font-weight: 400; |
| | | font-size: 26rpx; |
| | | color: #2E68C4; |
| | | margin-left: 8rpx; |
| | | } |
| | | } |
| | | .head-title-name { |
| | | font-weight: 500; |
| | | font-size: 32rpx; |
| | | color: #111111; |
| | | } |
| | | } |
| | | .head-search { |
| | | width: 100%; |
| | | height: 172rpx; |
| | | .head-search-input { |
| | | width: 100%; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: space-between; |
| | | padding: 0 30rpx; |
| | | box-sizing: border-box; |
| | | height: 72rpx; |
| | | margin-top: 12rpx; |
| | | .head-title-left { |
| | | flex-shrink: 0; |
| | | display: flex; |
| | | align-items: center; |
| | | margin-right: 30rpx; |
| | | image { |
| | | width: 40rpx; |
| | | height: 40rpx; |
| | | } |
| | | text { |
| | | font-weight: 400; |
| | | font-size: 26rpx; |
| | | color: #2E68C4; |
| | | margin-left: 8rpx; |
| | | } |
| | | } |
| | | .head-search-input-right { |
| | | flex: 1; |
| | | } |
| | | } |
| | | .sou { |
| | | width: 100%; |
| | |
| | | }, |
| | | methods: { |
| | | getAll() { |
| | | this.$u.api.categoryList({ type: 1 }) |
| | | this.$u.api.categoryList({ type: 1, rank: 1 }) |
| | | .then(res => { |
| | | if (res.code === 200) { |
| | | res.data.active = false |
| | |
| | | const install = (Vue, vm) => { |
| | | // 请求拦截器 |
| | | uni.$u.http.interceptors.request.use((config) => { |
| | | const Headtoken = vm.$store.state.token |
| | | if (Headtoken) { |
| | | config.header['token'] = Headtoken; |
| | | } |
| | | // const Headtoken = vm.$store.state.token |
| | | // if (Headtoken) { |
| | | config.header['token'] = 'eyJhbGciOiJIUzUxMiJ9.eyJpZCI6IjE4MDU1MTU5NDUzIiwiZXhwIjoxNzcwMTg3MDgxfQ.xoNzXq98cZQEAlCO3UeJU6zn5obIdoCWxWLRJumlj4AAzVeBNQosrVfxZMBfYOAZKB7qBcM_4JiWlDCEyL8hrg'; |
| | | // } |
| | | return config |
| | | }, config => { |
| | | return Promise.reject(config) |