Merge branch 'master' of http://139.186.142.91:10010/r/productDev/dmvisit
| | |
| | | export const createVisit = (data) => { |
| | | return request.post('/visitsAdmin/cloudService/business/visits/createVisit', data) |
| | | } |
| | | export function visitResend (visitId) { |
| | | return request.get(`/visitsAdmin/cloudService/business/visits/visitResend?visitId=${visitId}`) |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | import request from '../../utils/request' |
| | | |
| | | // æ¥è¯¢ |
| | | export function fetchList (data) { |
| | | return request.post('/visitsAdmin/cloudService/business/platformWaterGas/page', data, { |
| | | trim: true |
| | | }) |
| | | } |
| | | export function allList (data) { |
| | | return request.post('/visitsAdmin/cloudService/business/platformWaterGas/list', data, { |
| | | trim: true |
| | | }) |
| | | } |
| | | |
| | | // 导åºExcel |
| | | export function exportExcel (data) { |
| | | return request.post('/visitsAdmin/cloudService/business/platformWaterGas/exportExcel', data, { |
| | | trim: true, |
| | | download: true |
| | | }) |
| | | } |
| | | |
| | | // å建 |
| | | export function create (data) { |
| | | return request.post('/visitsAdmin/cloudService/business/platformWaterGas/create', data) |
| | | } |
| | | |
| | | // ä¿®æ¹ |
| | | export function updateById (data) { |
| | | return request.post('/visitsAdmin/cloudService/business/platformWaterGas/updateById', data) |
| | | } |
| | | export function updateStatusById (data) { |
| | | return request.post('/visitsAdmin/cloudService/business/platformWaterGas/updateStatusById', data) |
| | | } |
| | | |
| | | // å é¤ |
| | | export function deleteById (id) { |
| | | return request.get(`/visitsAdmin/cloudService/business/platformWaterGas/delete/${id}`) |
| | | } |
| | | |
| | | // æ¹éå é¤ |
| | | export function deleteByIdInBatch (ids) { |
| | | return request.get('/visitsAdmin/cloudService/business/platformWaterGas/delete/batch', { |
| | | params: { |
| | | ids |
| | | } |
| | | }) |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <GlobalWindow |
| | | :title="title" |
| | | width="50%" |
| | | :visible.sync="visible" |
| | | :confirm-working="isWorking" |
| | | @confirm="confirm" |
| | | > |
| | | <el-form :model="form" ref="form" :rules="rules"> |
| | | <el-form-item label="æä»½" prop="timeInfo"> |
| | | <el-date-picker |
| | | v-model="form.timeInfo" |
| | | format="yyyy-MM" |
| | | value-format="yyyy-MM-dd HH:mm:ss" |
| | | type="month" |
| | | /> |
| | | </el-form-item> |
| | | <el-form-item label="ç¨æ°éï¼ç«æ¹ç±³ï¼ï¼" prop="num" > |
| | | <el-input type="number" v-model="form.num" placeholder="请è¾å
¥ç¨æ°éï¼ç«æ¹ç±³ï¼" v-trim/> |
| | | </el-form-item> |
| | | <el-form-item label="说æï¼" prop="content"> |
| | | <el-input type="textarea" v-model="form.content" placeholder="请è¾å
¥è¯´æ" v-trim/> |
| | | </el-form-item> |
| | | </el-form> |
| | | </GlobalWindow> |
| | | </template> |
| | | |
| | | <script> |
| | | import BaseOpera from '@/components/base/BaseOpera' |
| | | import GlobalWindow from '@/components/common/GlobalWindow' |
| | | import { allList } from '@/api/platform/platformGroup' |
| | | export default { |
| | | name: 'OperaPlatformReasonWindow', |
| | | extends: BaseOpera, |
| | | components: { GlobalWindow }, |
| | | data () { |
| | | return { |
| | | // è¡¨åæ°æ® |
| | | groupList: [], |
| | | form: { |
| | | id: null, |
| | | content: null, |
| | | num: null, |
| | | timeInfo: '', |
| | | type: 1 |
| | | }, |
| | | // éªè¯è§å |
| | | rules: { |
| | | timeInfo: [{ required: true, message: '请è¾éæ©æä»½ ', trigger: 'blur' }], |
| | | num: [{ required: true, message: '请è¾å
¥ç¨æ°éï¼å¨ï¼ ', trigger: 'blur' }] |
| | | } |
| | | } |
| | | }, |
| | | created () { |
| | | this.config({ |
| | | api: '/platform/platformWaterGas', |
| | | 'field.id': 'id' |
| | | }) |
| | | }, |
| | | methods: { |
| | | /** |
| | | * æå¼çªå£ |
| | | * @title çªå£æ é¢ |
| | | * @target ç¼è¾ç对象 |
| | | */ |
| | | open (title, target) { |
| | | this.title = title |
| | | this.visible = true |
| | | // æ°å»º |
| | | if (target == null) { |
| | | this.$nextTick(() => { |
| | | this.$refs.form.resetFields() |
| | | this.form[this.configData['field.id']] = null |
| | | }) |
| | | return |
| | | } |
| | | // ç¼è¾ |
| | | this.$nextTick(() => { |
| | | for (const key in this.form) { |
| | | this.form[key] = target[key] |
| | | } |
| | | }) |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | | <style scoped> |
| | | .labelTip{ |
| | | font-size: 12px; |
| | | color: #666666; |
| | | } |
| | | </style> |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <GlobalWindow |
| | | :title="title" |
| | | width="50%" |
| | | :visible.sync="visible" |
| | | :confirm-working="isWorking" |
| | | @confirm="confirm" |
| | | > |
| | | <el-form :model="form" ref="form" :rules="rules"> |
| | | <el-form-item label="车çå·ï¼" prop="carCode" > |
| | | <el-input type="text" v-model="form.carCode" placeholder="请è¾å
¥è½¦çå·" v-trim/> |
| | | </el-form-item> |
| | | <el-form-item label="æä»½" prop="timeInfo"> |
| | | <el-date-picker |
| | | v-model="form.timeInfo" |
| | | format="yyyy-MM" |
| | | placeholder="è¯·éæ©å¹´æ" |
| | | value-format="yyyy-MM-dd HH:mm:ss" |
| | | type="month" |
| | | /> |
| | | </el-form-item> |
| | | <el-form-item label="æ²¹èï¼åï¼ï¼" prop="num" > |
| | | <el-input type="number" v-model="form.num" placeholder="请è¾å
¥æ²¹èï¼åï¼" v-trim/> |
| | | </el-form-item> |
| | | <el-form-item label="说æï¼" prop="content"> |
| | | <el-input type="textarea" v-model="form.content" placeholder="请è¾å
¥è¯´æ" v-trim/> |
| | | </el-form-item> |
| | | </el-form> |
| | | </GlobalWindow> |
| | | </template> |
| | | |
| | | <script> |
| | | import BaseOpera from '@/components/base/BaseOpera' |
| | | import GlobalWindow from '@/components/common/GlobalWindow' |
| | | import { allList } from '@/api/platform/platformGroup' |
| | | export default { |
| | | name: 'OperaPlatformReasonWindow', |
| | | extends: BaseOpera, |
| | | components: { GlobalWindow }, |
| | | data () { |
| | | return { |
| | | // è¡¨åæ°æ® |
| | | groupList: [], |
| | | form: { |
| | | id: null, |
| | | carCode:null, |
| | | content: null, |
| | | num: null, |
| | | timeInfo: '', |
| | | type: 2 |
| | | }, |
| | | // éªè¯è§å |
| | | rules: { |
| | | carCode: [{ required: true, message: '请è¾å
¥è½¦çå· ', trigger: 'blur' }], |
| | | timeInfo: [{ required: true, message: '请è¾éæ©æä»½ ', trigger: 'blur' }], |
| | | num: [{ required: true, message: '请è¾å
¥æ²¹èï¼åï¼ ', trigger: 'blur' }] |
| | | } |
| | | } |
| | | }, |
| | | created () { |
| | | this.config({ |
| | | api: '/platform/platformWaterGas', |
| | | 'field.id': 'id' |
| | | }) |
| | | }, |
| | | methods: { |
| | | /** |
| | | * æå¼çªå£ |
| | | * @title çªå£æ é¢ |
| | | * @target ç¼è¾ç对象 |
| | | */ |
| | | open (title, target) { |
| | | this.title = title |
| | | this.visible = true |
| | | // æ°å»º |
| | | if (target == null) { |
| | | this.$nextTick(() => { |
| | | this.$refs.form.resetFields() |
| | | this.form[this.configData['field.id']] = null |
| | | }) |
| | | return |
| | | } |
| | | // ç¼è¾ |
| | | this.$nextTick(() => { |
| | | for (const key in this.form) { |
| | | this.form[key] = target[key] |
| | | } |
| | | }) |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | | <style scoped> |
| | | .labelTip{ |
| | | font-size: 12px; |
| | | color: #666666; |
| | | } |
| | | </style> |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <GlobalWindow |
| | | :title="title" |
| | | width="50%" |
| | | :visible.sync="visible" |
| | | :confirm-working="isWorking" |
| | | @confirm="confirm" |
| | | > |
| | | <el-form :model="form" ref="form" :rules="rules"> |
| | | <el-form-item label="æä»½" prop="timeInfo"> |
| | | <el-date-picker |
| | | v-model="form.timeInfo" |
| | | format="yyyy-MM" |
| | | value-format="yyyy-MM-dd HH:mm:ss" |
| | | type="month" |
| | | /> |
| | | </el-form-item> |
| | | <el-form-item label="ç¨æ°´éï¼å¨ï¼ï¼" prop="num" > |
| | | <el-input type="number" v-model="form.num" placeholder="请è¾å
¥ç¨æ°´éï¼å¨ï¼" v-trim/> |
| | | </el-form-item> |
| | | <el-form-item label="说æï¼" prop="content"> |
| | | <el-input type="textarea" v-model="form.content" placeholder="请è¾å
¥è¯´æ" v-trim/> |
| | | </el-form-item> |
| | | </el-form> |
| | | </GlobalWindow> |
| | | </template> |
| | | |
| | | <script> |
| | | import BaseOpera from '@/components/base/BaseOpera' |
| | | import GlobalWindow from '@/components/common/GlobalWindow' |
| | | import { allList } from '@/api/platform/platformGroup' |
| | | export default { |
| | | name: 'OperaPlatformReasonWindow', |
| | | extends: BaseOpera, |
| | | components: { GlobalWindow }, |
| | | data () { |
| | | return { |
| | | // è¡¨åæ°æ® |
| | | groupList: [], |
| | | form: { |
| | | id: null, |
| | | content: null, |
| | | num: null, |
| | | timeInfo: '', |
| | | type:0 |
| | | }, |
| | | // éªè¯è§å |
| | | rules: { |
| | | timeInfo: [{ required: true, message: '请è¾éæ©æä»½ ', trigger: 'blur' }], |
| | | num: [{ required: true, message: '请è¾å
¥ç¨æ·éï¼å¨ï¼ ', trigger: 'blur' }] |
| | | } |
| | | } |
| | | }, |
| | | created () { |
| | | this.config({ |
| | | api: '/platform/platformWaterGas', |
| | | 'field.id': 'id' |
| | | }) |
| | | }, |
| | | methods: { |
| | | /** |
| | | * æå¼çªå£ |
| | | * @title çªå£æ é¢ |
| | | * @target ç¼è¾ç对象 |
| | | */ |
| | | open (title, target) { |
| | | this.title = title |
| | | this.visible = true |
| | | // æ°å»º |
| | | if (target == null) { |
| | | this.$nextTick(() => { |
| | | this.$refs.form.resetFields() |
| | | this.form[this.configData['field.id']] = null |
| | | }) |
| | | return |
| | | } |
| | | // ç¼è¾ |
| | | this.$nextTick(() => { |
| | | for (const key in this.form) { |
| | | this.form[key] = target[key] |
| | | } |
| | | }) |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | | <style scoped> |
| | | .labelTip{ |
| | | font-size: 12px; |
| | | color: #666666; |
| | | } |
| | | </style> |
| | |
| | | <el-table-column |
| | | v-if="containPermissions(['business:visits:update', 'business:visits:delete'])" |
| | | label="æä½" |
| | | min-width="100" |
| | | min-width="200" |
| | | fixed="right" |
| | | > |
| | | <template slot-scope="{row}"> |
| | | <el-button type="text" @click="departure(row.id)" v-permissions="['business:visits:level']" icon="el-icon-delete" style="color: red" v-if="row.status == 7">离å</el-button> |
| | | <el-button type="text" @click="cancel(row.id)" v-permissions="['business:visits:cancel']" icon="el-icon-delete" style="color: red" v-if="row.status == 5">åæ¶é¢çº¦</el-button> |
| | | <el-button type="text" @click="resend(row.id)" v-permissions="['business:visits:update']" icon="el-icon-edit" v-if="row.status == 6">éæ°ä¸å</el-button> |
| | | <!-- <el-button type="text" @click="$refs.OperaVisitsDesWindow.open('详æ
', row.id)" icon="el-icon-view">详æ
</el-button> --> |
| | | <el-button type="text" @click="handleDetail(row)" icon="el-icon-view">详æ
</el-button> |
| | | <!-- <el-button type="text" @click="deleteById(row)" icon="el-icon-delete" v-permissions="['business:visits:delete']">æ¥è¯¢å®¡æ¹ç»æ</el-button>--> |
| | |
| | | cancelButtonText: 'åæ¶', |
| | | type: 'warning' |
| | | }).then(() => { |
| | | level(id) |
| | | level(id) |
| | | .then(res => { |
| | | this.page = 1 |
| | | this.getData() |
| | |
| | | cancelButtonText: 'åæ¶', |
| | | type: 'warning' |
| | | }).then(() => { |
| | | visitCancel(id) |
| | | visitCancel(id) |
| | | .then(res => { |
| | | this.page = 1 |
| | | this.getData() |
| | | }) |
| | | }).catch(() => { |
| | | |
| | | }) |
| | | }, |
| | | resend (id) { |
| | | this.$confirm('ç¡®å®å°è¯éæ°æ´åé¢çº¦å, æ¯å¦ç»§ç»?', 'æç¤º', { |
| | | confirmButtonText: 'ç¡®å®', |
| | | cancelButtonText: 'åæ¶', |
| | | type: 'warning' |
| | | }).then(() => { |
| | | this.api.visitResend(id) |
| | | .then(res => { |
| | | this.page = 1 |
| | | this.getData() |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <TableLayout :permissions="['business:platformwatergas:query']"> |
| | | <SearchFormCollapse slot="search-form" :need-more="false"> |
| | | <el-form ref="searchForm" :model="searchForm" label-width="100px" inline > |
| | | <el-form-item title="è¯·éæ©å¹´ææ¶é´" label="" prop="timeInfo" > |
| | | <el-date-picker |
| | | @change="search" |
| | | v-model="searchForm.timeInfo" |
| | | format="yyyy-MM" |
| | | placeholder="è¯·éæ©å¹´ææ¶é´" |
| | | value-format="yyyy-MM-dd HH:mm:ss" |
| | | type="month" |
| | | /> |
| | | </el-form-item> |
| | | <section> |
| | | <el-button type="primary" @click="search">æç´¢</el-button> |
| | | <el-button @click="reset">éç½®</el-button> |
| | | </section> |
| | | </el-form> |
| | | </SearchFormCollapse> |
| | | <!-- è¡¨æ ¼åå页 --> |
| | | <template v-slot:table-wrap> |
| | | <ul class="toolbar" v-permissions="['business:platformwatergas:create','business:platformwatergas:delete','business:notice:exportExcel']"> |
| | | <li><el-button type="primary" @click="$refs.OperaPlatformGasWindow.open('æ°å»ºç¨æ°')" icon="el-icon-plus" v-permissions="['business:platformwatergas:create']">æ°å»º</el-button></li> |
| | | <li><el-button @click="deleteByIdInBatch" icon="el-icon-delete" v-permissions="['business:platformwatergas:delete']">å é¤</el-button></li> |
| | | <el-button type="primary" :loading="isWorking.export" v-permissions="['business:notice:exportExcel']" @click="exportExcel">导åº</el-button> |
| | | </ul> |
| | | <el-table |
| | | v-loading="isWorking.search" |
| | | :data="tableData.list" |
| | | stripe |
| | | @selection-change="handleSelectionChange" |
| | | > |
| | | <el-table-column type="selection" width="55"></el-table-column> |
| | | <el-table-column prop="timeInfo" label="ä½¿ç¨æä»½" fixed min-width="100px"> |
| | | <template slot-scope="{row}"> |
| | | {{(row.timeInfo || row.timeInfo.length >7 )?row.timeInfo.substr(0,7):'-'}} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="num" label="ç¨æ°éï¼ç«æ¹ç±³ï¼" fixed min-width="150px"></el-table-column> |
| | | <el-table-column prop="content" label="说æ" min-width="120px"></el-table-column> |
| | | <el-table-column prop="editDate" label="æè¿æä½æ¶é´" min-width="140px"></el-table-column> |
| | | <el-table-column |
| | | v-if="containPermissions(['business:platformwatergas:update', 'business:platformwatergas:delete'])" |
| | | label="æä½" |
| | | align="center" |
| | | min-width="150" |
| | | fixed="right" |
| | | > |
| | | <template slot-scope="{row}"> |
| | | <el-button type="text" @click="$refs.OperaPlatformGasWindow.open('ç¼è¾ç¨æ°', row)" icon="el-icon-edit" v-permissions="['business:platformwatergas:update']">ç¼è¾</el-button> |
| | | <el-button type="text" @click="deleteById(row)" icon="el-icon-delete" v-permissions="['business:platformwatergas:delete']">å é¤</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | <pagination |
| | | @size-change="handleSizeChange" |
| | | @current-change="handlePageChange" |
| | | :pagination="tableData.pagination" |
| | | > |
| | | </pagination> |
| | | </template> |
| | | <!-- æ°å»º/ä¿®æ¹ --> |
| | | <OperaPlatformGasWindow ref="OperaPlatformGasWindow" @success="handlePageChange"/> |
| | | </TableLayout> |
| | | </template> |
| | | |
| | | <script> |
| | | import BaseTable from '@/components/base/BaseTable' |
| | | import TableLayout from '@/layouts/TableLayout' |
| | | import SearchFormCollapse from '@/components/common/SearchFormCollapse' |
| | | import Pagination from '@/components/common/Pagination' |
| | | import OperaPlatformGasWindow from '@/components/business/OperaPlatformGasWindow' |
| | | import { allList } from '@/api/platform/platformGroup' |
| | | export default { |
| | | name: 'Platform', |
| | | extends: BaseTable, |
| | | components: { SearchFormCollapse, TableLayout, Pagination, OperaPlatformGasWindow }, |
| | | data () { |
| | | return { |
| | | groupList: [], |
| | | // æç´¢ |
| | | working: false, |
| | | working1: false, |
| | | searchForm: { |
| | | timeInfo: '', |
| | | type: 1 |
| | | } |
| | | } |
| | | }, |
| | | created () { |
| | | this.config({ |
| | | module: 'ç¨æ°ä¿¡æ¯è¡¨', |
| | | api: '/platform/platformWaterGas', |
| | | 'field.id': 'id', |
| | | 'field.main': 'id' |
| | | }) |
| | | this.search() |
| | | this.loadGroupList() |
| | | }, |
| | | methods: { |
| | | loadGroupList () { |
| | | allList({}) |
| | | .then(res => { |
| | | this.groupList = res || [] |
| | | }) |
| | | }, |
| | | changeStatus (e, row) { |
| | | this.api.updateStatusById({ |
| | | id: row.id, |
| | | status: e |
| | | }) |
| | | } |
| | | } |
| | | } |
| | | </script> |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <TableLayout :permissions="['business:platformwatergas:query']"> |
| | | <SearchFormCollapse slot="search-form" :need-more="false"> |
| | | <el-form ref="searchForm" :model="searchForm" label-width="100px" inline > |
| | | <el-form-item title="请è¾å
¥è½¦çå·" > |
| | | <el-input v-model="searchForm.carCode" clearable placeholder="请è¾å
¥è½¦çå·" @keypress.enter.native="search"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="ä½¿ç¨æ¶é´ï¼" > |
| | | <el-date-picker |
| | | @change="search" |
| | | v-model="searchForm.startTime" |
| | | format="yyyy-MM" |
| | | style="width: 140px" |
| | | placeholder="å¼å§æ¶é´" |
| | | value-format="yyyy-MM-dd HH:mm:ss" |
| | | type="month" |
| | | />~ |
| | | <el-date-picker |
| | | @change="search" |
| | | v-model="searchForm.endTime" |
| | | format="yyyy-MM" |
| | | style="width: 140px" |
| | | placeholder="ç»ææ¶é´" |
| | | value-format="yyyy-MM-dd HH:mm:ss" |
| | | type="month" |
| | | /> |
| | | </el-form-item> |
| | | <section> |
| | | <el-button type="primary" @click="search">æç´¢</el-button> |
| | | <el-button @click="reset">éç½®</el-button> |
| | | </section> |
| | | </el-form> |
| | | </SearchFormCollapse> |
| | | <!-- è¡¨æ ¼åå页 --> |
| | | <template v-slot:table-wrap> |
| | | <ul class="toolbar" v-permissions="['business:platformwatergas:create','business:platformwatergas:delete','business:notice:exportExcel']"> |
| | | <li><el-button type="primary" @click="$refs.OperaPlatformOilWindow.open('æ°å»ºæ²¹è')" icon="el-icon-plus" v-permissions="['business:platformwatergas:create']">æ°å»º</el-button></li> |
| | | <li><el-button @click="deleteByIdInBatch" icon="el-icon-delete" v-permissions="['business:platformwatergas:delete']">å é¤</el-button></li> |
| | | <el-button type="primary" :loading="isWorking.export" v-permissions="['business:notice:exportExcel']" @click="exportExcel">导åº</el-button> |
| | | </ul> |
| | | <el-table |
| | | v-loading="isWorking.search" |
| | | :data="tableData.list" |
| | | stripe |
| | | @selection-change="handleSelectionChange" |
| | | > |
| | | <el-table-column type="selection" width="55"></el-table-column> |
| | | <el-table-column prop="carCode" label="车çå·" fixed min-width="150px"></el-table-column> |
| | | <el-table-column prop="timeInfo" label="ä½¿ç¨æä»½" fixed min-width="100px"> |
| | | <template slot-scope="{row}"> |
| | | {{(row.timeInfo || row.timeInfo.length >7 )?row.timeInfo.substr(0,7):'-'}} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="num" label="æ²¹èï¼åï¼" fixed min-width="150px"></el-table-column> |
| | | <el-table-column prop="content" label="说æ" min-width="120px"></el-table-column> |
| | | <el-table-column prop="editDate" label="æè¿æä½æ¶é´" min-width="140px"></el-table-column> |
| | | <el-table-column |
| | | v-if="containPermissions(['business:platformwatergas:update', 'business:platformwatergas:delete'])" |
| | | label="æä½" |
| | | align="center" |
| | | min-width="150" |
| | | fixed="right" |
| | | > |
| | | <template slot-scope="{row}"> |
| | | <el-button type="text" @click="$refs.OperaPlatformOilWindow.open('ç¼è¾æ²¹è', row)" icon="el-icon-edit" v-permissions="['business:platformwatergas:update']">ç¼è¾</el-button> |
| | | <el-button type="text" @click="deleteById(row)" icon="el-icon-delete" v-permissions="['business:platformwatergas:delete']">å é¤</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | <pagination |
| | | @size-change="handleSizeChange" |
| | | @current-change="handlePageChange" |
| | | :pagination="tableData.pagination" |
| | | > |
| | | </pagination> |
| | | </template> |
| | | <!-- æ°å»º/ä¿®æ¹ --> |
| | | <OperaPlatformOilWindow ref="OperaPlatformOilWindow" @success="handlePageChange"/> |
| | | </TableLayout> |
| | | </template> |
| | | |
| | | <script> |
| | | import BaseTable from '@/components/base/BaseTable' |
| | | import TableLayout from '@/layouts/TableLayout' |
| | | import SearchFormCollapse from '@/components/common/SearchFormCollapse' |
| | | import Pagination from '@/components/common/Pagination' |
| | | import OperaPlatformOilWindow from '@/components/business/OperaPlatformOilWindow' |
| | | import { allList } from '@/api/platform/platformGroup' |
| | | export default { |
| | | name: 'Platform', |
| | | extends: BaseTable, |
| | | components: { SearchFormCollapse, TableLayout, Pagination, OperaPlatformOilWindow }, |
| | | data () { |
| | | return { |
| | | groupList: [], |
| | | // æç´¢ |
| | | working: false, |
| | | working1: false, |
| | | searchForm: { |
| | | carCode:'', |
| | | startTime: '', |
| | | endTime: '', |
| | | type: 2 |
| | | } |
| | | } |
| | | }, |
| | | created () { |
| | | this.config({ |
| | | module: 'æ²¹èä¿¡æ¯è¡¨', |
| | | api: '/platform/platformWaterGas', |
| | | 'field.id': 'id', |
| | | 'field.main': 'id' |
| | | }) |
| | | this.search() |
| | | this.loadGroupList() |
| | | }, |
| | | methods: { |
| | | loadGroupList () { |
| | | allList({}) |
| | | .then(res => { |
| | | this.groupList = res || [] |
| | | }) |
| | | }, |
| | | changeStatus (e, row) { |
| | | this.api.updateStatusById({ |
| | | id: row.id, |
| | | status: e |
| | | }) |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | |
| | | <span v-if="row.platformStatus == 3">é误åé </span> |
| | | </template> |
| | | </el-table-column> |
| | | |
| | | <el-table-column prop="broadcastNames" label="å
³è广æ" min-width="100px"></el-table-column> |
| | | <el-table-column prop="ledNames" label="å
³èLED" min-width="100px"></el-table-column> |
| | | <el-table-column prop="hkDate" label="忥æ¶é´" min-width="140px"></el-table-column> |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <TableLayout :permissions="['business:platformwatergas:query']"> |
| | | <SearchFormCollapse slot="search-form" :need-more="false"> |
| | | <el-form ref="searchForm" :model="searchForm" label-width="100px" inline> |
| | | <el-form-item title="è¯·éæ©å¹´ææ¶é´" label="" > |
| | | <el-date-picker |
| | | @change="search" |
| | | clearable |
| | | v-model="searchForm.timeInfo" |
| | | format="yyyy-MM" |
| | | placeholder="è¯·éæ©å¹´ææ¶é´" |
| | | value-format="yyyy-MM-dd HH:mm:ss" |
| | | type="month" |
| | | /> |
| | | </el-form-item> |
| | | <section> |
| | | <el-button type="primary" @click="search">æç´¢</el-button> |
| | | <el-button @click="reset">éç½®</el-button> |
| | | </section> |
| | | </el-form> |
| | | </SearchFormCollapse> |
| | | <!-- è¡¨æ ¼åå页 --> |
| | | <template v-slot:table-wrap> |
| | | <ul class="toolbar" v-permissions="['business:platformwatergas:create','business:platformwatergas:delete','business:notice:exportExcel']"> |
| | | <li><el-button type="primary" @click="$refs.OperaPlatformWaterWindow.open('æ°å»ºç¨æ°´')" icon="el-icon-plus" v-permissions="['business:platformwatergas:create']">æ°å»º</el-button></li> |
| | | <li><el-button @click="deleteByIdInBatch" icon="el-icon-delete" v-permissions="['business:platformwatergas:delete']">å é¤</el-button></li> |
| | | <el-button type="primary" :loading="isWorking.export" v-permissions="['business:notice:exportExcel']" @click="exportExcel">导åº</el-button> |
| | | </ul> |
| | | <el-table |
| | | v-loading="isWorking.search" |
| | | :data="tableData.list" |
| | | stripe |
| | | @selection-change="handleSelectionChange" |
| | | > |
| | | <el-table-column type="selection" width="55"></el-table-column> |
| | | <el-table-column prop="timeInfo" label="ä½¿ç¨æä»½" fixed min-width="100px"> |
| | | <template slot-scope="{row}"> |
| | | {{(row.timeInfo || row.timeInfo.length >7 )?row.timeInfo.substr(0,7):'-'}} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="num" label="ç¨æ°´éï¼å¨ï¼" fixed min-width="150px"></el-table-column> |
| | | <el-table-column prop="content" label="说æ" min-width="120px"></el-table-column> |
| | | <el-table-column prop="editDate" label="æè¿æä½æ¶é´" min-width="140px"></el-table-column> |
| | | <el-table-column |
| | | v-if="containPermissions(['business:platformwatergas:update', 'business:platformwatergas:delete'])" |
| | | label="æä½" |
| | | align="center" |
| | | min-width="150" |
| | | fixed="right" |
| | | > |
| | | <template slot-scope="{row}"> |
| | | <el-button type="text" @click="$refs.OperaPlatformWaterWindow.open('ç¼è¾ç¨æ°´', row)" icon="el-icon-edit" v-permissions="['business:platformwatergas:update']">ç¼è¾</el-button> |
| | | <el-button type="text" @click="deleteById(row)" icon="el-icon-delete" v-permissions="['business:platformwatergas:delete']">å é¤</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | <pagination |
| | | @size-change="handleSizeChange" |
| | | @current-change="handlePageChange" |
| | | :pagination="tableData.pagination" |
| | | > |
| | | </pagination> |
| | | </template> |
| | | <!-- æ°å»º/ä¿®æ¹ --> |
| | | <OperaPlatformWaterWindow ref="OperaPlatformWaterWindow" @success="handlePageChange"/> |
| | | </TableLayout> |
| | | </template> |
| | | |
| | | <script> |
| | | import BaseTable from '@/components/base/BaseTable' |
| | | import TableLayout from '@/layouts/TableLayout' |
| | | import SearchFormCollapse from '@/components/common/SearchFormCollapse' |
| | | import Pagination from '@/components/common/Pagination' |
| | | import OperaPlatformWaterWindow from '@/components/business/OperaPlatformWaterWindow' |
| | | import { allList } from '@/api/platform/platformGroup' |
| | | export default { |
| | | name: 'Platform', |
| | | extends: BaseTable, |
| | | components: { SearchFormCollapse, TableLayout, Pagination, OperaPlatformWaterWindow }, |
| | | data () { |
| | | return { |
| | | groupList: [], |
| | | // æç´¢ |
| | | working: false, |
| | | working1: false, |
| | | searchForm: { |
| | | timeInfo: '', |
| | | type: 0 |
| | | } |
| | | } |
| | | }, |
| | | created () { |
| | | this.config({ |
| | | module: 'ç¨æ°´ä¿¡æ¯è¡¨', |
| | | api: '/platform/platformWaterGas', |
| | | 'field.id': 'id', |
| | | 'field.main': 'id' |
| | | }) |
| | | this.search() |
| | | this.loadGroupList() |
| | | }, |
| | | methods: { |
| | | loadGroupList () { |
| | | allList({}) |
| | | .then(res => { |
| | | this.groupList = res || [] |
| | | }) |
| | | }, |
| | | changeStatus (e, row) { |
| | | this.api.updateStatusById({ |
| | | id: row.id, |
| | | status: e |
| | | }) |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | |
| | | <el-table-column prop="memberName" label="车主å§å" min-width="100px"></el-table-column> |
| | | <el-table-column prop="memberPhone" label="è½¦ä¸»ææºå·" min-width="100px"></el-table-column> |
| | | <el-table-column prop="companyName" label="车主ç»ç»" min-width="200px"></el-table-column> |
| | | <el-table-column label="æ¯å¦ææ" align="center" min-width="100px"> |
| | | <template slot-scope="{row}"> |
| | | <span v-if="row.authStatus == 1" style="color: green">æ¯</span> |
| | | <span v-else style="color: red">å¦</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="parksName" align="center" label="å·²ææå车åº" min-width="200px"> |
| | | <template slot-scope="{row}"> |
| | | <div v-if="row.parkBookList && row.parkBookList.length" > |
| | | <span v-for="item in row.parkBookList" :key="item.id" style="display: block"> |
| | | <span :style="(item.hkStatus== 0?'color:#2080f7':(item.hkStatus== 1?'color:green':(item.hkStatus== 2?'color:red':'')))">ã{{item.hkStatus== 0?'çå¾
ä¸å':(item.hkStatus== 1?'ä¸åæå':(item.hkStatus== 2?'ä¸å失败':''))}}ã </span>{{item.parksName}} |
| | | </span> |
| | | </div> |
| | | <span v-if="row.parkBookList ==null ||row.parkBookList.length ==0">-</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="æ¯å¦ææ" align="center" min-width="100px"> |
| | | <template slot-scope="{row}"> |
| | | <span v-if="row.authStatus == 1" style="color: green">æ¯</span> |
| | | <span v-else style="color: red">å¦</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="parksName" align="center" label="å·²ææå车åº" min-width="200px"> |
| | | <template slot-scope="{row}"> |
| | | <div v-if="row.parkBookList && row.parkBookList.length" > |
| | | <span v-for="item in row.parkBookList" :key="item.id" style="display: block"> |
| | | <span :style="(item.hkStatus== 0?'color:#2080f7':(item.hkStatus== 1?'color:green':(item.hkStatus== 2?'color:red':'')))">ã{{item.hkStatus== 0?'çå¾
ä¸å':(item.hkStatus== 1?'ä¸åæå':(item.hkStatus== 2?'ä¸å失败':''))}}ã </span>{{item.parksName}} |
| | | </span> |
| | | </div> |
| | | <span v-if="row.parkBookList ==null ||row.parkBookList.length ==0">-</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="ä¸åæææ" align="center" min-width="170px"> |
| | | <template slot-scope="{row}"> |
| | | <div v-if="row.authStatus !=null && row.authStatus == 1 && row.parkBookList!=null && row.parkBookList.length>0"> |
| | |
| | | import Pagination from '@/components/common/Pagination' |
| | | import OperaCarsWindow from '@/components/business/OperaCarsWindow' |
| | | import OperaCarAuthWindow from '@/components/business/OperaCarAuthWindow' |
| | | import { sync } from '@/api/business/cars' |
| | | export default { |
| | | name: 'Cars', |
| | | extends: BaseTable, |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | INSERT INTO `SYSTEM_PERMISSION`(`CODE`, `NAME`, `REMARK`, `FIXED`, `CREATE_USER`, `CREATE_TIME`, `UPDATE_USER`, `UPDATE_TIME`, `DELETED`) VALUES ('business:platformwatergas:create', 'æ°å»ºæå°_ç¨æ°´ç¨æ°ä¿¡æ¯è®°å½è¡¨', '', 0, 1, CURRENT_TIMESTAMP, NULL, NULL, 0); |
| | | INSERT INTO `SYSTEM_PERMISSION`(`CODE`, `NAME`, `REMARK`, `FIXED`, `CREATE_USER`, `CREATE_TIME`, `UPDATE_USER`, `UPDATE_TIME`, `DELETED`) VALUES ('business:platformwatergas:delete', 'å 餿å°_ç¨æ°´ç¨æ°ä¿¡æ¯è®°å½è¡¨', '', 0, 1, CURRENT_TIMESTAMP, NULL, NULL, 0); |
| | | INSERT INTO `SYSTEM_PERMISSION`(`CODE`, `NAME`, `REMARK`, `FIXED`, `CREATE_USER`, `CREATE_TIME`, `UPDATE_USER`, `UPDATE_TIME`, `DELETED`) VALUES ('business:platformwatergas:update', 'ä¿®æ¹æå°_ç¨æ°´ç¨æ°ä¿¡æ¯è®°å½è¡¨', '', 0, 1, CURRENT_TIMESTAMP, NULL, NULL, 0); |
| | | INSERT INTO `SYSTEM_PERMISSION`(`CODE`, `NAME`, `REMARK`, `FIXED`, `CREATE_USER`, `CREATE_TIME`, `UPDATE_USER`, `UPDATE_TIME`, `DELETED`) VALUES ('business:platformwatergas:query', 'æ¥è¯¢æå°_ç¨æ°´ç¨æ°ä¿¡æ¯è®°å½è¡¨', '', 0, 1, CURRENT_TIMESTAMP, NULL, NULL, 0); |
| | | INSERT INTO `SYSTEM_PERMISSION`(`CODE`, `NAME`, `REMARK`, `FIXED`, `CREATE_USER`, `CREATE_TIME`, `UPDATE_USER`, `UPDATE_TIME`, `DELETED`) VALUES ('business:platformwatergas:exportExcel', 'å¯¼åºæå°_ç¨æ°´ç¨æ°ä¿¡æ¯è®°å½è¡¨(Excel)', '', 0, 1, CURRENT_TIMESTAMP, NULL, NULL, 0); |
| | | |
| | |
| | | public ApiResponse<String> login (@Validated @RequestBody LoginDTO dto, ServerWebExchange serverWebExchange) { |
| | | try { |
| | | ServerHttpRequest request = serverWebExchange.getRequest(); |
| | | dto.setCheckCode(true); |
| | | LoginUserInfo user = systemLoginService.loginByPasswordNew(dto,request); |
| | | String token = jwtTokenUtil.generateToken(user); |
| | | return ApiResponse.success(token); |
| | |
| | | } |
| | | } |
| | | |
| | | @PreventRepeat(limit = 10, lockTime = 10000) |
| | | @ApiOperation("叿ºç»å½") |
| | | @PostMapping("/loginDriver") |
| | | @LoginNoRequired |
| | | public ApiResponse<String> loginDriver (@Validated @RequestBody LoginDTO dto, ServerWebExchange serverWebExchange) { |
| | | try { |
| | | ServerHttpRequest request = serverWebExchange.getRequest(); |
| | | dto.setCheckCode(false); |
| | | LoginUserInfo user = systemLoginService.driverLogin(dto,request); |
| | | String token = jwtTokenUtil.generateToken(user); |
| | | return ApiResponse.success(token); |
| | | }catch (BusinessException e){ |
| | | return ApiResponse.failed(e.getCode(),e.getMessage()); |
| | | }catch (Exception e){ |
| | | e.printStackTrace(); |
| | | return ApiResponse.failed(ResponseStatus.SERVER_ERROR); |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * å·æ°JWT令ç,ç¨æ§çä»¤çæ¢æ°ç令ç |
| | |
| | | * @author Eva.Caesar Liu |
| | | * @date 2023/03/21 14:49 |
| | | */ |
| | | protected LoginUserInfo getLoginUser (String token) { |
| | | public LoginUserInfo getLoginUser (String token) { |
| | | if (token == null || token.isEmpty()) { |
| | | return (LoginUserInfo)SecurityUtils.getSubject().getPrincipal(); |
| | | // throw new BusinessException(ResponseStatus.NO_LOGIN.getCode(),"æªç»å½"); |
| | |
| | | import com.doumee.dao.system.model.SystemPermission; |
| | | import com.doumee.dao.system.model.SystemRole; |
| | | import com.doumee.dao.system.model.SystemUser; |
| | | import com.github.xiaoymin.knife4j.core.util.CollectionUtils; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | import org.springframework.beans.BeanUtils; |
| | |
| | | loginUserInfo.setCompany(company); |
| | | // 设置è§è²ä¿¡æ¯ |
| | | List<String> rs = new ArrayList<>(); |
| | | for (SystemRole role : roles) { |
| | | rs.add(role.getCode()); |
| | | if(CollectionUtils.isNotEmpty(roles)){ |
| | | for (SystemRole role : roles) { |
| | | rs.add(role.getCode()); |
| | | } |
| | | } |
| | | loginUserInfo.setSessionId(sessionId); |
| | | loginUserInfo.setRoles(rs); |
| | | // 设置æéä¿¡æ¯ |
| | | List<String> pms = new ArrayList<>(); |
| | | for (SystemPermission permission : permissions) { |
| | | pms.add(permission.getCode()); |
| | | if(CollectionUtils.isNotEmpty(permissions)){ |
| | | for (SystemPermission permission : permissions) { |
| | | pms.add(permission.getCode()); |
| | | } |
| | | } |
| | | loginUserInfo.setPermissions(pms); |
| | | return loginUserInfo; |
| | |
| | | package com.doumee.core.utils; |
| | | |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.doumee.core.model.LoginUserInfo; |
| | | import com.fasterxml.jackson.annotation.JsonInclude; |
| | | import com.fasterxml.jackson.core.JsonProcessingException; |
| | | import com.fasterxml.jackson.databind.ObjectMapper; |
| | | import com.fasterxml.jackson.databind.PropertyNamingStrategy; |
| | | import io.swagger.models.auth.In; |
| | | import org.apache.batik.util.Platform; |
| | | import org.apache.commons.collections4.CollectionUtils; |
| | | import org.apache.commons.lang3.StringUtils; |
| | | import org.springframework.util.CollectionUtils; |
| | | |
| | | import java.io.IOException; |
| | | import java.math.BigDecimal; |
| | |
| | | // è¶
æ¶é¢è¦é
ç½® |
| | | public static final String TIMEOUT_WARNING = "TIMEOUT_WARNING"; |
| | | // FTPæä»¶æå¡å¨èµæºè®¿é®å°å |
| | | //æå°é¢çº¦æå |
| | | public static final String PLATFORM_BOOKING_TIPS = "PLATFORM_BOOKING_TIPS"; |
| | | //æå°å¯¼è§å¾ |
| | | public static final String PLATFORM_GUIDEMAP = "PLATFORM_GUIDEMAP"; |
| | | |
| | | |
| | | public static String getRandom6Num( ) { |
| | | Random random = new Random(); |
| | |
| | | int cityUseCar = 3;//å¸å
ç¨è½¦ |
| | | int unCityUseCar = 4;//å¸å¤ç¨è½¦ |
| | | int logisticsCarUse = 5;//ç©æµè½¦é¢çº¦ |
| | | int reason = 6;//å
¥ååå |
| | | } |
| | | |
| | | |
| | |
| | | }else if(Constants.equalsInteger(approveType,Constants.approveObjectType.cityUseCar) |
| | | ||Constants.equalsInteger(approveType,Constants.approveObjectType.unCityUseCar)){ |
| | | return Constants.noticesObjectType.useCar; |
| | | }else if(Constants.equalsInteger(approveType,Constants.approveObjectType.logisticsCarUse)){ |
| | | return Constants.noticesObjectType.logisticsCarUse; |
| | | }else if(Constants.equalsInteger(approveType, approveObjectType.reason)){ |
| | | return noticesObjectType.reason; |
| | | }else { |
| | | return Constants.noticesObjectType.system; |
| | | } |
| | |
| | | int dangerDeal = 3;//鿣å¤ç |
| | | int logisticsCarUse = 4;//ç©æµè½¦å®¡æ¹ |
| | | int system = 5;//ç³»ç»æ¶æ¯ |
| | | int reason = 6;//å
¥ååå |
| | | } |
| | | |
| | | |
| | |
| | | // StringUtil.getNotNullStr(request.getParameter(strParamName)); |
| | | // return getDateByString(strStr); |
| | | // } |
| | | /** |
| | | * å¾å°å½åæ¥æï¼æ ¼å¼yyyy-MM-ddã |
| | | * |
| | | * @return String æ ¼å¼åçæ¥æå符串 |
| | | */ |
| | | public static String getCurrDate() { |
| | | return getFormattedDate(getDateByString("")); |
| | | } |
| | | |
| | | /** |
| | | * å¾å°å½åæ¥æï¼æ ¼å¼yyyy-MM-ddã |
| | |
| | | } |
| | | |
| | | /** |
| | | * å¾å°å½åæ¥ææ¶é´,æ ¼å¼ä¸ºyyyy-MM-dd. |
| | | * |
| | | * @return String |
| | | */ |
| | | public static String getCurrDate() { |
| | | Timestamp date = new Timestamp(System.currentTimeMillis()); |
| | | SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM-dd"); |
| | | return formatter.format(date); |
| | | } |
| | | |
| | | /** |
| | | * å¾å°æå®çæ¥æï¼å¦ä¸å¹´ä¸ä¸ªæé¶ä¹å¤©å(以yyyy/MM/ddæ ¼å¼æ¾ç¤º)åæ°ä¸º("yyyy/MM/dd",1,3,9) |
| | | * |
| | | * @param strFormat |
| | |
| | | |
| | | LoginUserInfo loginByPasswordNew (LoginDTO dto, ServerHttpRequest request); |
| | | |
| | | LoginUserInfo driverLogin(LoginDTO dto, ServerHttpRequest request); |
| | | /** |
| | | * æ ¹æ® openIdç»å½ |
| | | * @param userId |
| | |
| | | loginLog.setOsInfo(Utils.User_Client.getOS(request)); |
| | | } |
| | | loginLog.setServerIp(Utils.Server.getIP()); |
| | | if(isDebug == null || !isDebug){ |
| | | if(isDebug == null || !isDebug && dto.getCheckCode()){ |
| | | // æ ¡éªéªè¯ç |
| | | try { |
| | | captchaService.check(dto.getUuid(), dto.getCode()); |
| | |
| | | } |
| | | |
| | | |
| | | |
| | | @Override |
| | | public LoginUserInfo driverLogin(LoginDTO dto, ServerHttpRequest request) { |
| | | SystemLoginLog loginLog = new SystemLoginLog(); |
| | | loginLog.setLoginUsername(dto.getUsername()); |
| | | loginLog.setLoginTime(new Date()); |
| | | loginLog.setSystemVersion(systemVersion); |
| | | loginLog.setLocation(Utils.Location.getLocationString(loginLog.getIp())); |
| | | if(request!=null&&request.getHeaders()!=null && request.getHeaders().size()>0){ |
| | | loginLog.setIp(Utils.User_Client.getIP(request)); |
| | | loginLog.setPlatform(Utils.User_Client.getPlatform(request)); |
| | | loginLog.setClientInfo(Utils.User_Client.getBrowser(request)); |
| | | loginLog.setOsInfo(Utils.User_Client.getOS(request)); |
| | | } |
| | | loginLog.setServerIp(Utils.Server.getIP()); |
| | | // æ ¹æ®ç¨æ·åæ¥è¯¢ç¨æ·å¯¹è±¡ |
| | | SystemUser queryDto = new SystemUser(); |
| | | queryDto.setUsername(dto.getUsername()); |
| | | queryDto.setDeleted(Boolean.FALSE); |
| | | SystemUser user = systemUserService.findOne(queryDto); |
| | | if (user == null) { |
| | | throw new BusinessException(ResponseStatus.ACCOUNT_INCORRECT); |
| | | } |
| | | String pwd = Utils.Secure.encryptPassword(new String(dto.getPassword()), user.getSalt()); |
| | | // æ¯è¾å¯ç |
| | | if( !StringUtils.equals(pwd, user.getPassword())){ |
| | | throw new BusinessException(ResponseStatus.ACCOUNT_INCORRECT); |
| | | } |
| | | Company company = new Company(); |
| | | if(Objects.nonNull(user.getCompanyId())){ |
| | | company = companyMapper.selectById(user.getCompanyId()); |
| | | } |
| | | LoginUserInfo userInfo = LoginUserInfo.from(user, null, null,company,null); |
| | | return userInfo; |
| | | } |
| | | |
| | | |
| | | /** |
| | | * å
é¨äººå ä¸ å¸æº æ ¹æ®codeæ¥è¯¢openIdåè¿è¡ç»å½æ¥å£ |
| | | * @return |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.doumee.api.business; |
| | | |
| | | import com.doumee.api.BaseController; |
| | | import com.doumee.core.annotation.excel.ExcelExporter; |
| | | import com.doumee.core.annotation.pr.PreventRepeat; |
| | | import com.doumee.core.model.ApiResponse; |
| | | import com.doumee.core.model.PageWrap; |
| | | import com.doumee.core.model.PageData; |
| | | import com.doumee.dao.business.model.PlatformWaterGas; |
| | | import com.doumee.service.business.PlatformWaterGasService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.apache.shiro.authz.annotation.RequiresPermissions; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * @author æ±è¹è¹ |
| | | * @date 2024/08/26 16:22 |
| | | */ |
| | | @Api(tags = "æå°_ç¨æ°´ç¨æ°ä¿¡æ¯è®°å½è¡¨") |
| | | @RestController |
| | | @RequestMapping("/business/platformWaterGas") |
| | | public class PlatformWaterGasController extends BaseController { |
| | | |
| | | @Autowired |
| | | private PlatformWaterGasService platformWaterGasService; |
| | | |
| | | @PreventRepeat |
| | | @ApiOperation("æ°å»º") |
| | | @PostMapping("/create") |
| | | @RequiresPermissions("business:platformwatergas:create") |
| | | public ApiResponse create(@RequestBody PlatformWaterGas platformWaterGas) { |
| | | return ApiResponse.success(platformWaterGasService.create(platformWaterGas)); |
| | | } |
| | | |
| | | @ApiOperation("æ ¹æ®IDå é¤") |
| | | @GetMapping("/delete/{id}") |
| | | @RequiresPermissions("business:platformwatergas:delete") |
| | | public ApiResponse deleteById(@PathVariable Integer id) { |
| | | platformWaterGasService.deleteById(id); |
| | | return ApiResponse.success(null); |
| | | } |
| | | |
| | | @ApiOperation("æ¹éå é¤") |
| | | @GetMapping("/delete/batch") |
| | | @RequiresPermissions("business:platformwatergas:delete") |
| | | public ApiResponse deleteByIdInBatch(@RequestParam String ids) { |
| | | String [] idArray = ids.split(","); |
| | | List<Integer> idList = new ArrayList<>(); |
| | | for (String id : idArray) { |
| | | idList.add(Integer.valueOf(id)); |
| | | } |
| | | platformWaterGasService.deleteByIdInBatch(idList); |
| | | return ApiResponse.success(null); |
| | | } |
| | | |
| | | @ApiOperation("æ ¹æ®IDä¿®æ¹") |
| | | @PostMapping("/updateById") |
| | | @RequiresPermissions("business:platformwatergas:update") |
| | | public ApiResponse updateById(@RequestBody PlatformWaterGas platformWaterGas) { |
| | | platformWaterGasService.updateById(platformWaterGas); |
| | | return ApiResponse.success(null); |
| | | } |
| | | |
| | | @ApiOperation("å页æ¥è¯¢") |
| | | @PostMapping("/page") |
| | | @RequiresPermissions("business:platformwatergas:query") |
| | | public ApiResponse<PageData<PlatformWaterGas>> findPage (@RequestBody PageWrap<PlatformWaterGas> pageWrap) { |
| | | return ApiResponse.success(platformWaterGasService.findPage(pageWrap)); |
| | | } |
| | | |
| | | @ApiOperation("导åºExcel") |
| | | @PostMapping("/exportExcel") |
| | | @RequiresPermissions("business:platformwatergas:exportExcel") |
| | | public void exportExcel (@RequestBody PageWrap<PlatformWaterGas> pageWrap, HttpServletResponse response) { |
| | | ExcelExporter.build(PlatformWaterGas.class).export(platformWaterGasService.findPage(pageWrap).getRecords(), "æå°_ç¨æ°´ç¨æ°ä¿¡æ¯è®°å½è¡¨", response); |
| | | } |
| | | |
| | | @ApiOperation("æ ¹æ®IDæ¥è¯¢") |
| | | @GetMapping("/{id}") |
| | | @RequiresPermissions("business:platformwatergas:query") |
| | | public ApiResponse findById(@PathVariable Integer id) { |
| | | return ApiResponse.success(platformWaterGasService.findById(id)); |
| | | } |
| | | } |
| | |
| | | visitsService.visitCancel(visitId); |
| | | return ApiResponse.success(null); |
| | | } |
| | | @ApiOperation("éæ°ä¸å失败çé¢çº¦") |
| | | @GetMapping("/visitResend") |
| | | @RequiresPermissions("business:visits:update") |
| | | public ApiResponse visitResend(@RequestParam Integer visitId) { |
| | | visitsService.visitResend(visitId); |
| | | return ApiResponse.success(null); |
| | | } |
| | | |
| | | @ApiOperation("æ ¹æ®æ¥æ(starttime)åæ¥è®¿å®¢æ°æ®") |
| | | @PostMapping("/syncByDate") |
| | |
| | | import com.doumee.core.model.PageWrap; |
| | | import com.doumee.core.utils.Constants; |
| | | import com.doumee.dao.business.model.Platform; |
| | | import com.doumee.service.business.PlatformJobService; |
| | | import com.doumee.service.business.PlatformService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * @author æ±è¹è¹ |
| | |
| | | |
| | | @Autowired |
| | | private PlatformService platformService; |
| | | |
| | | @Autowired |
| | | private PlatformJobService platformJobService; |
| | | |
| | | @PreventRepeat |
| | | @ApiOperation("æ°å»º") |
| | |
| | | return ApiResponse.success(platformService.findPage(pageWrap)); |
| | | } |
| | | |
| | | |
| | | @ApiOperation("æ ¹æ®æå°ç»è·åæå°å表信æ¯") |
| | | @GetMapping("/listByGroupId") |
| | | @CloudRequiredPermission("business:platform:query") |
| | | public ApiResponse<List<Platform>> listByGroupId (@RequestParam Integer groupId, @RequestHeader(Constants.HEADER_USER_TOKEN) String token){ |
| | | return ApiResponse.success(platformJobService.getPlatformList(groupId,this.getLoginUser(token))); |
| | | } |
| | | |
| | | @ApiOperation("导åºExcel") |
| | | @PostMapping("/exportExcel") |
| | | @CloudRequiredPermission("business:platform:exportExcel") |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.doumee.cloud.admin; |
| | | |
| | | import com.doumee.api.BaseController; |
| | | import com.doumee.config.annotation.CloudRequiredPermission; |
| | | import com.doumee.core.annotation.excel.ExcelExporter; |
| | | import com.doumee.core.annotation.pr.PreventRepeat; |
| | | import com.doumee.core.model.ApiResponse; |
| | | import com.doumee.core.model.PageData; |
| | | import com.doumee.core.model.PageWrap; |
| | | import com.doumee.core.utils.Constants; |
| | | import com.doumee.dao.business.model.PlatformWaterGas; |
| | | import com.doumee.service.business.PlatformWaterGasService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * @author æ±è¹è¹ |
| | | * @date 2024/08/26 16:22 |
| | | */ |
| | | @Api(tags = "æå°_ç¨æ°´ç¨æ°ä¿¡æ¯è®°å½è¡¨") |
| | | @RestController |
| | | @RequestMapping(Constants.CLOUD_SERVICE_URL_INDEX+"/business/platformWaterGas") |
| | | public class PlatformWaterGasCloudController extends BaseController { |
| | | |
| | | @Autowired |
| | | private PlatformWaterGasService platformWaterGasService; |
| | | |
| | | @PreventRepeat |
| | | @ApiOperation("æ°å»º") |
| | | @PostMapping("/create") |
| | | @CloudRequiredPermission("business:platformwatergas:create") |
| | | public ApiResponse create(@RequestBody PlatformWaterGas platformWaterGas,@RequestHeader(Constants.HEADER_USER_TOKEN) String token) { |
| | | platformWaterGas.setLoginUserInfo(getLoginUser(token)); |
| | | return ApiResponse.success(platformWaterGasService.create(platformWaterGas)); |
| | | } |
| | | |
| | | @ApiOperation("æ ¹æ®IDå é¤") |
| | | @GetMapping("/delete/{id}") |
| | | @CloudRequiredPermission("business:platformwatergas:delete") |
| | | public ApiResponse deleteById(@PathVariable Integer id,@RequestHeader(Constants.HEADER_USER_TOKEN) String token) { |
| | | platformWaterGasService.deleteById(id,getLoginUser(token)); |
| | | return ApiResponse.success(null); |
| | | } |
| | | |
| | | @ApiOperation("æ¹éå é¤") |
| | | @GetMapping("/delete/batch") |
| | | @CloudRequiredPermission("business:platformwatergas:delete") |
| | | public ApiResponse deleteByIdInBatch(@RequestParam String ids,@RequestHeader(Constants.HEADER_USER_TOKEN) String token) { |
| | | String [] idArray = ids.split(","); |
| | | List<Integer> idList = new ArrayList<>(); |
| | | for (String id : idArray) { |
| | | idList.add(Integer.valueOf(id)); |
| | | } |
| | | platformWaterGasService.deleteByIdInBatch(idList,getLoginUser(token)); |
| | | return ApiResponse.success(null); |
| | | } |
| | | |
| | | @ApiOperation("æ ¹æ®IDä¿®æ¹") |
| | | @PostMapping("/updateById") |
| | | @CloudRequiredPermission("business:platformwatergas:update") |
| | | public ApiResponse updateById(@RequestBody PlatformWaterGas platformWaterGas,@RequestHeader(Constants.HEADER_USER_TOKEN) String token) { |
| | | platformWaterGas.setLoginUserInfo(getLoginUser(token)); |
| | | platformWaterGasService.updateById(platformWaterGas); |
| | | return ApiResponse.success(null); |
| | | } |
| | | |
| | | @ApiOperation("å页æ¥è¯¢") |
| | | @PostMapping("/page") |
| | | @CloudRequiredPermission("business:platformwatergas:query") |
| | | public ApiResponse<PageData<PlatformWaterGas>> findPage (@RequestBody PageWrap<PlatformWaterGas> pageWrap,@RequestHeader(Constants.HEADER_USER_TOKEN) String token) { |
| | | return ApiResponse.success(platformWaterGasService.findPage(pageWrap)); |
| | | } |
| | | |
| | | @ApiOperation("导åºExcel") |
| | | @PostMapping("/exportExcel") |
| | | @CloudRequiredPermission("business:platformwatergas:exportExcel") |
| | | public void exportExcel (@RequestBody PageWrap<PlatformWaterGas> pageWrap, HttpServletResponse response,@RequestHeader(Constants.HEADER_USER_TOKEN) String token) { |
| | | ExcelExporter.build(PlatformWaterGas.class).export(platformWaterGasService.findPage(pageWrap).getRecords(), "æå°_ç¨æ°´ç¨æ°ä¿¡æ¯è®°å½è¡¨", response); |
| | | } |
| | | |
| | | @ApiOperation("æ ¹æ®IDæ¥è¯¢") |
| | | @GetMapping("/{id}") |
| | | @CloudRequiredPermission("business:platformwatergas:query") |
| | | public ApiResponse findById(@PathVariable Integer id,@RequestHeader(Constants.HEADER_USER_TOKEN) String token) { |
| | | return ApiResponse.success(platformWaterGasService.findById(id)); |
| | | } |
| | | } |
| | |
| | | import io.swagger.annotations.ApiImplicitParam; |
| | | import io.swagger.annotations.ApiImplicitParams; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.apache.shiro.authz.annotation.RequiresPermissions; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | |
| | | visitsService.resetPassword(resetPasswordDTO); |
| | | return ApiResponse.success("éç½®æå"); |
| | | } |
| | | |
| | | @ApiOperation("éæ°ä¸å失败çé¢çº¦") |
| | | @GetMapping("/visitResend") |
| | | @CloudRequiredPermission("business:visits:update") |
| | | public ApiResponse visitResend(@RequestParam Integer visitId) { |
| | | visitsService.visitResend(visitId); |
| | | return ApiResponse.success(null); |
| | | } |
| | | |
| | | } |
| | |
| | | package com.doumee.cloud.web; |
| | | |
| | | import cn.hutool.http.useragent.Platform; |
| | | import com.doumee.api.BaseController; |
| | | import com.doumee.config.annotation.LoginNoRequired; |
| | | import com.doumee.config.annotation.LoginRequired; |
| | | import com.doumee.core.annotation.trace.Trace; |
| | | import com.doumee.core.model.ApiResponse; |
| | | import com.doumee.core.model.LoginUserInfo; |
| | | import com.doumee.core.model.PageData; |
| | | import com.doumee.core.model.PageWrap; |
| | | import com.doumee.core.utils.Constants; |
| | | import com.doumee.core.utils.DateUtil; |
| | | import com.doumee.dao.business.model.PlatformBooks; |
| | | import com.doumee.dao.business.model.PlatformJob; |
| | | import com.doumee.dao.business.model.Visits; |
| | | import com.doumee.dao.business.model.*; |
| | | import com.doumee.dao.web.reqeust.*; |
| | | import com.doumee.dao.web.response.DriverHomeVO; |
| | | import com.doumee.dao.web.response.LineUpVO; |
| | |
| | | |
| | | import java.math.BigDecimal; |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * Created by IntelliJ IDEA. |
| | |
| | | @Autowired |
| | | private PlatformBooksService platformBooksService; |
| | | |
| | | @Autowired |
| | | private PlatformReasonService platformReasonService; |
| | | |
| | | |
| | | |
| | | @ApiOperation("å
¥ååå ") |
| | | @GetMapping("/platformReasonList") |
| | | public ApiResponse<List<PlatformReason>> platformReasonList (@RequestHeader(Constants.HEADER_USER_TOKEN) String token) { |
| | | List<PlatformReason> platformReasons = platformReasonService.findList(null); |
| | | return ApiResponse.success(platformReasons); |
| | | } |
| | | |
| | | @ApiOperation("叿ºé¦é¡µä¿¡æ¯") |
| | | @GetMapping("/driverHome") |
| | | public ApiResponse<DriverHomeVO> driverHome (@RequestHeader(Constants.HEADER_USER_TOKEN) String token) { |
| | | DriverHomeVO driverHomeVO = platformJobService.getDriverHome(getLoginUser(token).getMemberId()); |
| | | DriverHomeVO driverHomeVO = platformJobService.getDriverHome(getLoginUser(token)); |
| | | return ApiResponse.success(driverHomeVO); |
| | | } |
| | | |
| | | |
| | | @ApiOperation("æ¥è¯¢å¯é¢çº¦é") |
| | | @PostMapping("/checkSurplusNum") |
| | |
| | | @ApiOperation("ç©æµè½¦é¢çº¦") |
| | | @PostMapping("/apply") |
| | | public ApiResponse<Integer> apply (@RequestBody PlatformBooksApplyDTO platformBooksApplyDTO , @RequestHeader(Constants.HEADER_USER_TOKEN) String token) { |
| | | platformBooksApplyDTO.setUserId(getLoginUser(token).getMemberId()); |
| | | LoginUserInfo loginUserInfo = getLoginUser(token); |
| | | platformBooksApplyDTO.setUserId(loginUserInfo.getMemberId()); |
| | | platformBooksApplyDTO.setDriverId(loginUserInfo.getMemberId()); |
| | | return ApiResponse.success(platformBooksService.apply(platformBooksApplyDTO)); |
| | | } |
| | | |
| | | @ApiOperation("ç©æµè½¦é¢çº¦è®°å½") |
| | | @PostMapping("/page") |
| | | public ApiResponse<PageData<PlatformBooks>> findPage (@RequestBody PageWrap<PlatformBooks> pageWrap, @RequestHeader(Constants.HEADER_USER_TOKEN) String token) { |
| | | LoginUserInfo loginUserInfo = this.getLoginUser(token); |
| | | pageWrap.getModel().setQueryDate(DateUtil.getBeforDay(new Date(),30)); |
| | | pageWrap.getModel().setDriverPhone(loginUserInfo.getMobile()); |
| | | return ApiResponse.success(platformBooksService.findPage(pageWrap)); |
| | | } |
| | | |
| | |
| | | import com.doumee.core.model.PageWrap; |
| | | import com.doumee.core.utils.Constants; |
| | | import com.doumee.core.utils.DateUtil; |
| | | import com.doumee.dao.business.model.PlatformBooks; |
| | | import com.doumee.dao.business.model.PlatformGroup; |
| | | import com.doumee.dao.business.model.PlatformJob; |
| | | import com.doumee.dao.business.model.PlatformShowParam; |
| | | import com.doumee.dao.business.model.*; |
| | | import com.doumee.dao.web.reqeust.*; |
| | | import com.doumee.dao.web.response.DriverHomeVO; |
| | | import com.doumee.dao.web.response.LineUpVO; |
| | |
| | | @Autowired |
| | | private PlatformShowParamService platformShowParamService; |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | @Autowired |
| | | private PlatformService platformService; |
| | | |
| | | @ApiOperation("è·åæå°ç»ä¿¡æ¯") |
| | | @ApiImplicitParams({ |
| | |
| | | } |
| | | |
| | | @ApiOperation("æ´æ°æå°é
置信æ¯") |
| | | @GetMapping("/updUserPlatformConfig") |
| | | @PostMapping("/updUserPlatformConfig") |
| | | public ApiResponse updUserPlatformConfig (@RequestBody List<Integer> ids, @RequestHeader(Constants.HEADER_USER_TOKEN) String token){ |
| | | platformShowParamService.updUserConfig(ids,getLoginUser(token)); |
| | | return ApiResponse.success("æä½æå"); |
| | | } |
| | | |
| | | @ApiOperation("ä¿®æ¹ç¦å¯ç¨ç¶æ") |
| | | @PostMapping("/updPlatformStatus") |
| | | public ApiResponse updPlatformStatus (@RequestBody Platform platform, @RequestHeader(Constants.HEADER_USER_TOKEN) String token){ |
| | | platformService.updateStatusById(platform); |
| | | return ApiResponse.success("æä½æå"); |
| | | } |
| | | |
| | |
| | | platformJobService.platformInPark(jobOperateDTO); |
| | | return ApiResponse.success("æä½æå"); |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | } |
| | |
| | | * æ¥å£å°åéå |
| | | */ |
| | | public interface InterfacePath{ |
| | | // String doorEvents = "/api/acs/v2/door/events";//é¨ç¦äºä»¶æ¥è¯¢ |
| | | // String visitEvents = "/api/visitor/v1/event/turnover/search";//访客äºä»¶æ¥è¯¢ |
| | | String parkCrossRecords = "/api/pms/v1/crossRecords/page";//å车åºè¿ç¨è®°å½ |
| | | String rootOrg = "/api/resource/v1/org/rootOrg";//è·åè·ç»ç» |
| | | String orgAllList = "/api/resource/v1/org/orgList";//è·åå
¨éç»ç»ä¿¡æ¯ |
| | | String userAllList = "/api/resource/v2/person/personList";//è·åå
¨éç¨æ·å表 |
| | | String personList = "/api/resource/v2/person/advance/personList";//æ¥è¯¢äººåå表v2 |
| | | String orgTimeRangeList = "/api/resource/v1/org/timeRange";//å¢éè·åç»ç»ä¿¡æ¯ |
| | | String userTimeRangeList = "/api/resource/v1/person/personList/timeRange";//å¢éè·åç¨æ·å表 |
| | | String addBatchOrg = "/api/resource/v1/org/batch/add";//æ¹éæ°å¢ç»ç» |
| | | String delBatchOrg = "/api/resource/v1/org/batch/delete";//æ¹éå é¤ç»ç» |
| | | String editOrg = "/api/resource/v1/org/single/update";//ä¿®æ¹ç»ç» |
| | | String addUser = "/api/resource/v2/person/single/add";//æ·»å 人å |
| | | String addBatchUser = "/api/resource/v1/person/batch/add";//æ¹éæ·»å 人å |
| | | String editUser = "/api/resource/v1/person/single/update";//ä¿®æ¹äººå |
| | | String delBatchUser = "/api/resource/v1/person/batch/delete";//æ¹éå é¤äººå |
| | | String addFace = "/api/resource/v1/face/single/add";//æ·»å äººè¸ |
| | | String editFace = "/api/resource/v1/face/single/update";//ä¿®æ¹äººè¸ |
| | | String delFace = "/api/resource/v1/face/single/delete";//å é¤äººè¸ |
| | | String acsDeviceList = "/api/resource/v2/acsDevice/search";//æ¥è¯¢é¨ç¦è®¾å¤å表v2 |
| | | String acsDeviceTimeRangeList = "/api/resource/v1/acsDevice/timeRange";//å¢éè·åé¨ç¦è®¾å¤æ°æ® |
| | | String parkAddition = "/api/pms/v2/parkingSpace/reservations/addition";//车ä½é¢çº¦v2 |
| | | String parkDeletion= "/api/pms/v1/parkingSpace/reservations/deletion";//车ä½åæ¶é¢çº¦v2 |
| | | String carChargeAddtion= "/api/pms/v1/car/charge";//åºå®è½¦å
å¼å
æ |
| | | String carChargeDeletion= "/api/pms/v1/car/charge/deletion";//åºå®è½¦åæ¶å
æ |
| | | String getParkList= "/api/resource/v1/park/parkList";//è·åå车åºå表 |
| | | String getEntranceList= "/api/resource/v1/entrance/entranceList";//è·ååºå
¥å£å表 |
| | | String visitAppiontment= "/api/visitor/v2/appointment";//访客é¢çº¦v2 |
| | | String visitAppiontmentMDJ= "/api/visitor/v1/appointment/registration";//访客é¢çº¦å
ç»è®°v2 |
| | | String visitCancel= "/api/visitor/v1/appointment/cancel";//åæ¶è®¿å®¢é¢çº¦ |
| | | String visitOut= "/api/visitor/v1/visitor/out";//ç¾ç¦»è®¿å®¢é¢çº¦ |
| | | String facePicture= "/api/resource/v1/person/picture";//æåç¨æ·äººè¸ç
§ç |
| | | String privilegeGroup= "/api/visitor/v1/privilege/group";//æ¥è¯¢è®¿å®¢æéç» |
| | | String eventSub= "/api/eventService/v1/eventSubscriptionByEventTypes";//äºä»¶è®¢é
|
| | | String doorSearch= "/api/resource/v2/door/search";//æ¥è¯¢é¨ç¦ç¹å表v2 |
| | | String cancelEventSub= "/api/eventService/v1/eventUnSubscriptionByEventTypes";//åæ¶äºä»¶è®¢é
|
| | | String visitPicture= "/api/visitor/v1/record/pictures";//è·å访客记å½ä¸çå¾ç |
| | | String devicePicture= "/api/acs/v1/event/pictures";//è·åé¨ç¦äºä»¶çå¾ç |
| | | String carPicture= "/api/pms/v1/image";//æ¥è¯¢è½¦è¾ææå¾ç |
| | | String taskAddition= "/api/acps/v1/authDownload/task/addition";//å建ä¸è½½ä»»å¡_æ ¹æ®äººåä¸è®¾å¤ééæå®ä¸è½½ |
| | | String taskDataAddition= "/api/acps/v1/authDownload/data/addition";//ä¸è½½ä»»å¡ä¸æ·»å æ°æ®_æ ¹æ®äººåä¸è®¾å¤ééæå®ä¸è½½ |
| | | String taskStart= "/api/acps/v1/authDownload/task/start";//å¼å§ä¸è½½ä»»å¡ |
| | | String taskProgressNum= "/api/acps/v1/authDownload/task/progress";//æ¥è©¢ä¸è½½ä»»å¡è¿åº¦ |
| | | String taskProgress= "/api/acps/v2/download_record/person/detail/search";//æ¥è¯¢è®¾å¤ééç人åæéä¸è½½è¯¦æ
æ»æ°v2 |
| | | String authItemList= "/api/acps/v1/auth_item/list/search";//æ¥è¯¢æéæ¡ç®å表 |
| | | String cardBingding= "/api/cis/v1/card/bindings";//æ¹éå¼å¡ |
| | | String cardDeletion= "/api/cis/v1/card/deletion";//å¡çéå¡ |
| | | String cardLoss= "/api/cis/v1/card/batch/loss";//æ¹éæå¤± |
| | | String cardUnloss= "/api/cis/v1/card/batch/unLoss";//æ¹éè§£æ |
| | | String taskPersoDetail= "/api/acps/v1/download_record/person/detail/search";//æ¥è¯¢è®¾å¤ééç人åæéä¸è½½è¯¦æ
|
| | | String appointmentRecords= "/api/visitor/v2/appointment/records";//æ¥è¯¢è®¿å®¢é¢çº¦è®°å½v2 |
| | | String visitingRecords= "/api/visitor/v2/visiting/records";//æ¥è¯¢è®¿å®¢æ¥è®¿è®°å½v2 |
| | | String vehicleList= "/api/resource/v2/vehicle/advance/vehicleList";//æ¥è¯¢è½¦è¾å表v2 |
| | | String vehicleTimeRangeList= "/api/resource/v1/vehicle/timeRange";//å¢éè·åè½¦è¾æ°æ® |
| | | String facePictureCheck= "/api/frs/v1/face/picture/check";//人è¸è¯å |
| | | String acsDeviceStatus= "/api/nms/v1/online/acs_device/get";//è·åé¨ç¦è®¾å¤å¨çº¿ç¶æ |
| | | String tempCarInRecords= "/api/pms/v1/tempCarInRecords/page";//æ¥è¯¢åºå
车åè½¦ä¿¡æ¯ |
| | | String applyCTGT= "/api/lsm/ssoService/v1/applyCTGT";//æ ¹æ®ç¨æ·æ è¯è·å客æ·ç«¯TGCæ¥å£ |
| | | String applyST= "/api/lsm/ssoService/v1/applyST";//æ ¹æ®ç»å½æ è¯TGCç³è¯·ç»å½åè¯STæ¥å£ |
| | | String tokenLoginUrl= "/lsm/ssoService/v1/tokenLogin?token=${st}&service=${service}";//ç»ä»¶ææç»å½æ¼æ¥å°å |
| | | String fetchAudioChannel= "/api/ibas/resource/v1/fetchAudioChannel";//1.1.4.1å页è·å广æç¹ |
| | | String fetchAudioDevice= "/api/ibas/resource/v1/fetchAudioDevice";//1.1.4.2å页è·å广æè®¾å¤å表 |
| | | String fetchAudioChannelByDevice= "/api/ibas/resource/v1/fetchAudioChannelByDevice";//1.1.4.3æ ¹æ®è®¾å¤ä¿¡æ¯è·å广æç¹ |
| | | String ledRecords= "/api/v1/model/tb_led_info/records";//è·åæå°ç»ä»¶é
ç½®çLEDè®¾å¤æ¸
å |
| | | String transparentchannel= "/api/v1/transparentchannel";//åéæ¶æ¯ç»LED |
| | | String platformsList= "/api/platformService/v1/platforms";//è·åå
¨é¨æå°ä¿¡æ¯ |
| | | String platformStatus= "/api/platformService/v1/platform/status";//è·åæå°ç¶æ |
| | | String customBroadcast= "/api/ibas/v1/customBroadcast";//ç¨äºè®¾ç½®å¹¿æçèªå®ææ¾å忢 |
| | | String iccmAppointment= "/api/iccm/v2/appointment";//iccm访客ç»è®°æ·»å |
| | | String iccmUpdateAppointment= "/api/iccm/v2/appointment/update";//iccm访客ç»è®°ä¿®æ¹ |
| | | String iccmCancelAppointment= "/api/iccm/v1/appointment/cancel";//iccm访客ç»è®°ä¿®æ¹ |
| | | String iccmAppointmentMDJ= "/api/iccm/v1/appointment/free/registration";//iccm访客é¢çº¦å
ç»è®° |
| | | // String doorEvents = new String[]{"/api/acs/v2/door/events",""};//é¨ç¦äºä»¶æ¥è¯¢ |
| | | // String visitEvents = new String[]{"/api/visitor/v1/event/turnover/search",""};//访客äºä»¶æ¥è¯¢ |
| | | String[] parkCrossRecords =new String[]{"/api/pms/v1/crossRecords/page","å车åºè¿ç¨è®°å½"};//å车åºè¿ç¨è®°å½ |
| | | String[] rootOrg = new String[]{"/api/resource/v1/org/rootOrg","è·åè·ç»ç»"};//è·åè·ç»ç» |
| | | String[] orgAllList = new String[]{"/api/resource/v1/org/orgList","è·åå
¨éç»ç»ä¿¡æ¯"};//è·åå
¨éç»ç»ä¿¡æ¯ |
| | | String[] userAllList = new String[]{"/api/resource/v2/person/personList","è·åå
¨éç¨æ·å表"};//è·åå
¨éç¨æ·å表 |
| | | String[] personList = new String[]{"/api/resource/v2/person/advance/personList","æ¥è¯¢äººåå表v2"};//æ¥è¯¢äººåå表v2 |
| | | String[] orgTimeRangeList = new String[]{"/api/resource/v1/org/timeRange","å¢éè·åç»ç»ä¿¡æ¯"};//å¢éè·åç»ç»ä¿¡æ¯ |
| | | String[] userTimeRangeList = new String[]{"/api/resource/v1/person/personList/timeRange","å¢éè·åç¨æ·å表"};//å¢éè·åç¨æ·å表 |
| | | String[] addBatchOrg = new String[]{"/api/resource/v1/org/batch/add","æ¹éæ°å¢ç»ç»"};//æ¹éæ°å¢ç»ç» |
| | | String[] delBatchOrg = new String[]{"/api/resource/v1/org/batch/delete","æ¹éå é¤ç»ç»"};//æ¹éå é¤ç»ç» |
| | | String[] editOrg = new String[]{"/api/resource/v1/org/single/update","ä¿®æ¹ç»ç»"};//ä¿®æ¹ç»ç» |
| | | String[] addUser = new String[]{"/api/resource/v2/person/single/add","æ·»å 人å"};//æ·»å 人å |
| | | String[] addBatchUser = new String[]{"/api/resource/v1/person/batch/add","æ¹éæ·»å 人å"};//æ¹éæ·»å 人å |
| | | String[] editUser = new String[]{"/api/resource/v1/person/single/update","ä¿®æ¹äººå"};//ä¿®æ¹äººå |
| | | String[] delBatchUser = new String[]{"/api/resource/v1/person/batch/delete","æ¹éå é¤äººå"};//æ¹éå é¤äººå |
| | | String[] addFace = new String[]{"/api/resource/v1/face/single/add","æ·»å 人è¸"};//æ·»å äººè¸ |
| | | String[] editFace = new String[]{"/api/resource/v1/face/single/update","ä¿®æ¹äººè¸"};//ä¿®æ¹äººè¸ |
| | | String[] delFace = new String[]{"/api/resource/v1/face/single/delete","å é¤äººè¸"};//å é¤äººè¸ |
| | | String[] acsDeviceList = new String[]{"/api/resource/v2/acsDevice/search","æ¥è¯¢é¨ç¦è®¾å¤å表v2"};//æ¥è¯¢é¨ç¦è®¾å¤å表v2 |
| | | String[] acsDeviceTimeRangeList = new String[]{"/api/resource/v1/acsDevice/timeRange","å¢éè·åé¨ç¦è®¾å¤æ°æ®"};//å¢éè·åé¨ç¦è®¾å¤æ°æ® |
| | | String[] parkAddition = new String[]{"/api/pms/v2/parkingSpace/reservations/addition","车ä½é¢çº¦v2"};//车ä½é¢çº¦v2 |
| | | String[] parkDeletion= new String[]{"/api/pms/v1/parkingSpace/reservations/deletion","车ä½åæ¶é¢çº¦v2"};//车ä½åæ¶é¢çº¦v2 |
| | | String[] carChargeAddtion= new String[]{"/api/pms/v1/car/charge","åºå®è½¦å
å¼å
æ"};//åºå®è½¦å
å¼å
æ |
| | | String[] carChargeDeletion= new String[]{"/api/pms/v1/car/charge/deletion","åºå®è½¦åæ¶å
æ"};//åºå®è½¦åæ¶å
æ |
| | | String[] getParkList= new String[]{"/api/resource/v1/park/parkList","è·åå车åºå表"};//è·åå车åºå表 |
| | | String[] getEntranceList= new String[]{"/api/resource/v1/entrance/entranceList","è·ååºå
¥å£å表"};//è·ååºå
¥å£å表 |
| | | String[] visitAppiontment= new String[]{"/api/visitor/v2/appointment","访客é¢çº¦v2"};//访客é¢çº¦v2 |
| | | String[] visitAppiontmentMDJ= new String[]{"/api/visitor/v1/appointment/registration","访客é¢çº¦å
ç»è®°v2"};//访客é¢çº¦å
ç»è®°v2 |
| | | String[] visitCancel= new String[]{"/api/visitor/v1/appointment/cancel","åæ¶è®¿å®¢é¢çº¦"};//åæ¶è®¿å®¢é¢çº¦ |
| | | String[] visitOut= new String[]{"/api/visitor/v1/visitor/out","ç¾ç¦»è®¿å®¢é¢çº¦"};//ç¾ç¦»è®¿å®¢é¢çº¦ |
| | | String[] facePicture= new String[]{"/api/resource/v1/person/picture","æåç¨æ·äººè¸ç
§ç"};//æåç¨æ·äººè¸ç
§ç |
| | | String[] privilegeGroup= new String[]{"/api/visitor/v1/privilege/group","æ¥è¯¢è®¿å®¢æéç»"};//æ¥è¯¢è®¿å®¢æéç» |
| | | String[] eventSub= new String[]{"/api/eventService/v1/eventSubscriptionByEventTypes","äºä»¶è®¢é
"};//äºä»¶è®¢é
|
| | | String[] doorSearch= new String[]{"/api/resource/v2/door/search","æ¥è¯¢é¨ç¦ç¹å表v2"};//æ¥è¯¢é¨ç¦ç¹å表v2 |
| | | String[] cancelEventSub= new String[]{"/api/eventService/v1/eventUnSubscriptionByEventTypes","åæ¶äºä»¶è®¢é
"};//åæ¶äºä»¶è®¢é
|
| | | String[] visitPicture= new String[]{"/api/visitor/v1/record/pictures","è·å访客记å½ä¸çå¾ç"};//è·å访客记å½ä¸çå¾ç |
| | | String[] devicePicture= new String[]{"/api/acs/v1/event/pictures","è·åé¨ç¦äºä»¶çå¾ç"};//è·åé¨ç¦äºä»¶çå¾ç |
| | | String[] carPicture= new String[]{"/api/pms/v1/image","æ¥è¯¢è½¦è¾ææå¾ç"};//æ¥è¯¢è½¦è¾ææå¾ç |
| | | String[] taskAddition= new String[]{"/api/acps/v1/authDownload/task/addition","å建ä¸è½½ä»»å¡_æ ¹æ®äººåä¸è®¾å¤ééæå®ä¸è½½"};//å建ä¸è½½ä»»å¡_æ ¹æ®äººåä¸è®¾å¤ééæå®ä¸è½½ |
| | | String[] taskDataAddition= new String[]{"/api/acps/v1/authDownload/data/addition","ä¸è½½ä»»å¡ä¸æ·»å æ°æ®_æ ¹æ®äººåä¸è®¾å¤ééæå®ä¸è½½"};//ä¸è½½ä»»å¡ä¸æ·»å æ°æ®_æ ¹æ®äººåä¸è®¾å¤ééæå®ä¸è½½ |
| | | String[] taskStart= new String[]{"/api/acps/v1/authDownload/task/start","å¼å§ä¸è½½ä»»å¡"};//å¼å§ä¸è½½ä»»å¡ |
| | | String[] taskProgressNum= new String[]{"/api/acps/v1/authDownload/task/progress","æ¥è©¢ä¸è½½ä»»å¡è¿åº¦"};//æ¥è©¢ä¸è½½ä»»å¡è¿åº¦ |
| | | String[] taskProgress= new String[]{"/api/acps/v2/download_record/person/detail/search","æ¥è¯¢è®¾å¤ééç人åæéä¸è½½è¯¦æ
æ»æ°v2"};//æ¥è¯¢è®¾å¤ééç人åæéä¸è½½è¯¦æ
æ»æ°v2 |
| | | String[] authItemList= new String[]{"/api/acps/v1/auth_item/list/search","æ¥è¯¢æéæ¡ç®å表"};//æ¥è¯¢æéæ¡ç®å表 |
| | | String[] cardBingding= new String[]{"/api/cis/v1/card/bindings","æ¹éå¼å¡"};//æ¹éå¼å¡ |
| | | String[] cardDeletion= new String[]{"/api/cis/v1/card/deletion","å¡çéå¡"};//å¡çéå¡ |
| | | String[] cardLoss= new String[]{"/api/cis/v1/card/batch/loss","æ¹éæå¤±"};//æ¹éæå¤± |
| | | String[] cardUnloss= new String[]{"/api/cis/v1/card/batch/unLoss","æ¹éè§£æ"};//æ¹éè§£æ |
| | | String[] taskPersoDetail= new String[]{"/api/acps/v1/download_record/person/detail/search","æ¥è¯¢è®¾å¤ééç人åæéä¸è½½è¯¦æ
"};//æ¥è¯¢è®¾å¤ééç人åæéä¸è½½è¯¦æ
|
| | | String[] appointmentRecords= new String[]{"/api/visitor/v2/appointment/records","æ¥è¯¢è®¿å®¢é¢çº¦è®°å½v2"};//æ¥è¯¢è®¿å®¢é¢çº¦è®°å½v2 |
| | | String[] visitingRecords= new String[]{"/api/visitor/v2/visiting/records","æ¥è¯¢è®¿å®¢æ¥è®¿è®°å½v2"};//æ¥è¯¢è®¿å®¢æ¥è®¿è®°å½v2 |
| | | String[] vehicleList= new String[]{"/api/resource/v2/vehicle/advance/vehicleList","æ¥è¯¢è½¦è¾å表v2"};//æ¥è¯¢è½¦è¾å表v2 |
| | | String[] vehicleTimeRangeList= new String[]{"/api/resource/v1/vehicle/timeRange","å¢éè·åè½¦è¾æ°æ®"};//å¢éè·åè½¦è¾æ°æ® |
| | | String[] facePictureCheck= new String[]{"/api/frs/v1/face/picture/check","人è¸è¯å"};//人è¸è¯å |
| | | String[] acsDeviceStatus= new String[]{"/api/nms/v1/online/acs_device/get","è·åé¨ç¦è®¾å¤å¨çº¿ç¶æ"};//è·åé¨ç¦è®¾å¤å¨çº¿ç¶æ |
| | | String[] tempCarInRecords= new String[]{"/api/pms/v1/tempCarInRecords/page","æ¥è¯¢åºå
车å车信æ¯"};//æ¥è¯¢åºå
车åè½¦ä¿¡æ¯ |
| | | String[] applyCTGT= new String[]{"/api/lsm/ssoService/v1/applyCTGT","æ ¹æ®ç¨æ·æ è¯è·å客æ·ç«¯TGCæ¥å£"};//æ ¹æ®ç¨æ·æ è¯è·å客æ·ç«¯TGCæ¥å£ |
| | | String[] applyST= new String[]{"/api/lsm/ssoService/v1/applyST","æ ¹æ®ç»å½æ è¯TGCç³è¯·ç»å½åè¯STæ¥å£"};//æ ¹æ®ç»å½æ è¯TGCç³è¯·ç»å½åè¯STæ¥å£ |
| | | String[] tokenLoginUrl= new String[]{"/lsm/ssoService/v1/tokenLogin?token=${st}&service=${service}","ç»ä»¶ææç»å½æ¼æ¥å°å"};//ç»ä»¶ææç»å½æ¼æ¥å°å |
| | | String[] fetchAudioChannel= new String[]{"/api/ibas/resource/v1/fetchAudioChannel","å页è·å广æç¹"};//1.1.4.1å页è·å广æç¹ |
| | | String[] fetchAudioDevice= new String[]{"/api/ibas/resource/v1/fetchAudioDevice","2å页è·å广æè®¾å¤å表"};//1.1.4.2å页è·å广æè®¾å¤å表 |
| | | String[] fetchAudioChannelByDevice= new String[]{"/api/ibas/resource/v1/fetchAudioChannelByDevice","3æ ¹æ®è®¾å¤ä¿¡æ¯è·å广æç¹"};//1.1.4.3æ ¹æ®è®¾å¤ä¿¡æ¯è·å广æç¹ |
| | | String[] ledRecords= new String[]{"/api/v1/model/tb_led_info/records","è·åæå°ç»ä»¶é
ç½®çLEDè®¾å¤æ¸
å"};//è·åæå°ç»ä»¶é
ç½®çLEDè®¾å¤æ¸
å |
| | | String[] transparentchannel= new String[]{"/api/v1/transparentchannel","åéæ¶æ¯ç»LED"};//åéæ¶æ¯ç»LED |
| | | String[] platformsList= new String[]{"/api/platformService/v1/platforms","è·åå
¨é¨æå°ä¿¡æ¯"};//è·åå
¨é¨æå°ä¿¡æ¯ |
| | | String[] platformStatus= new String[]{"/api/platformService/v1/platform/status","è·åæå°ç¶æ"};//è·åæå°ç¶æ |
| | | String[] customBroadcast= new String[]{"/api/ibas/v1/customBroadcast","ç¨äºè®¾ç½®å¹¿æçèªå®ææ¾å忢"};//ç¨äºè®¾ç½®å¹¿æçèªå®ææ¾å忢 |
| | | String[] iccmAppointment= new String[]{"/api/iccm/v2/appointment/","iccm访客ç»è®°æ·»å "};//iccm访客ç»è®°æ·»å |
| | | String[] iccmUpdateAppointment= new String[]{"/api/iccm/v2/appointment/update","iccm访客ç»è®°ä¿®æ¹"};//iccm访客ç»è®°ä¿®æ¹ |
| | | String[] iccmCancelAppointment= new String[]{"/api/iccm/v1/appointment/cancel","iccm访客ç»è®°ä¿®æ¹"};//iccm访客ç»è®°ä¿®æ¹ |
| | | String[] iccmAppointmentMDJ= new String[]{"/api/iccm/v1/appointment/free/registration","iccm访客é¢çº¦å
ç»è®°"};//iccm访客é¢çº¦å
ç»è®° |
| | | |
| | | String privilegIccmeGroup= "/api/iccm/v1/privilege/groups";//æ¥è¯¢è®¿å®¢æéç» |
| | | String iccmAppointmentRecords= "/api/iccm/v2/appointment/records";//iccmæ¥è¯¢å·²é¢çº¦ç»è®° |
| | | String[] privilegIccmeGroup= new String[]{"/api/iccm/v1/privilege/groups","æ¥è¯¢è®¿å®¢æéç»"};//æ¥è¯¢è®¿å®¢æéç» |
| | | String[] iccmAppointmentRecords= new String[]{"/api/iccm/v2/appointment/records","iccmæ¥è¯¢å·²é¢çº¦ç»è®°"};//iccmæ¥è¯¢å·²é¢çº¦ç»è®° |
| | | } |
| | | |
| | | /** |
| | |
| | | |
| | | } |
| | | public static InterfaceLogService interfaceLogService = null; |
| | | private static void saveInterfaceLog(String s, String result,Map<String, String> path) { |
| | | private static void saveInterfaceLog(String s, String result,Map<String, String> path,String name) { |
| | | // InterfaceLogService bean = SpringContextUtil.getBean(InterfaceLogService.class); |
| | | if(interfaceLogService !=null){ |
| | | InterfaceLog hkMonitoryLogDO=new InterfaceLog(); |
| | |
| | | hkMonitoryLogDO.setIsdeleted(0); |
| | | hkMonitoryLogDO.setRequest(s); |
| | | hkMonitoryLogDO.setRepose(result); |
| | | hkMonitoryLogDO.setName(path.get(HKConstants.https)); |
| | | hkMonitoryLogDO.setName("ãå®é²å¹³å°ã"+name); |
| | | hkMonitoryLogDO.setUrl(HKConstants.https + ArtemisConfig.host+path.get(HKConstants.https)); |
| | | interfaceLogService.create(hkMonitoryLogDO); |
| | | } |
| | |
| | | */ |
| | | public static InputStream getFaceInputStream(String body) throws Exception{ |
| | | |
| | | Map<String, String> path = getPath(HKConstants.InterfacePath.facePicture); |
| | | Map<String, String> path = getPath(HKConstants.InterfacePath.facePicture[0]); |
| | | //åæ°æ ¹æ®æ¥å£å®é
æ
åµè®¾ç½® |
| | | HttpResponse resp = ArtemisHttpUtil.doPostStringImgArtemis( path, body, null, null,"application/json",null); |
| | | if (200==resp.getStatusLine().getStatusCode()) { |
| | |
| | | * @return |
| | | */ |
| | | public static InputStream getVisitPicture(String body) throws Exception{ |
| | | Map<String, String> path = getPath(HKConstants.InterfacePath.visitPicture); |
| | | Map<String, String> path = getPath(HKConstants.InterfacePath.visitPicture[0]); |
| | | //åæ°æ ¹æ®æ¥å£å®é
æ
åµè®¾ç½® |
| | | HttpResponse resp = ArtemisHttpUtil.doPostStringImgArtemis( path, body, null, null,"application/json",null); |
| | | if (200==resp.getStatusLine().getStatusCode()) { |
| | |
| | | */ |
| | | public static InputStream getDevicePicture(String body) throws Exception{ |
| | | |
| | | Map<String, String> path = getPath(HKConstants.InterfacePath.devicePicture); |
| | | Map<String, String> path = getPath(HKConstants.InterfacePath.devicePicture[0]); |
| | | //åæ°æ ¹æ®æ¥å£å®é
æ
åµè®¾ç½® |
| | | HttpResponse resp = ArtemisHttpUtil.doPostStringImgArtemis( path, body, null, null,"application/json",null); |
| | | if (200==resp.getStatusLine().getStatusCode()) { |
| | |
| | | */ |
| | | public static InputStream getCarPicture(String body) throws Exception{ |
| | | |
| | | Map<String, String> path = getPath(HKConstants.InterfacePath.carPicture); |
| | | Map<String, String> path = getPath(HKConstants.InterfacePath.carPicture[0]); |
| | | //åæ°æ ¹æ®æ¥å£å®é
æ
åµè®¾ç½® |
| | | HttpResponse resp = ArtemisHttpUtil.doPostStringImgArtemis( path, body, null, null,"application/json",null); |
| | | if (200==resp.getStatusLine().getStatusCode()) { |
| | |
| | | return startDoPostStringArtemis(HKConstants.InterfacePath.visitCancel,body); |
| | | } |
| | | |
| | | public static String startDoPostStringArtemis(String pathStr,String body){ |
| | | Map<String, String> path = getPath(pathStr); |
| | | public static String startDoPostStringArtemis(String[] pathStr,String body ){ |
| | | Map<String, String> path = getPath(pathStr[0]); |
| | | Map<String, String> header = new HashMap<>(); |
| | | header.put("tagId", UUID.randomUUID().toString().replace("-", "")); |
| | | String result = ArtemisHttpUtil.doPostStringArtemis(path, body, null, null, "application/json", header);// post请æ±application/jsonç±»ååæ° |
| | | saveInterfaceLog(body,result,path); |
| | | saveInterfaceLog(body,result,path,pathStr[1]); |
| | | return result; |
| | | |
| | | } |
| | | public static String startDoPostStringArtemis(String pathStr,Map<String, String> querys,Map<String, String> header,String body){ |
| | | Map<String, String> path = getPath(pathStr); |
| | | public static String startDoPostStringArtemis(String[] pathStr,String param,String body ){ |
| | | Map<String, String> path = getPath(pathStr[0]+StringUtils.defaultString(param,"")); |
| | | Map<String, String> header = new HashMap<>(); |
| | | header.put("tagId", UUID.randomUUID().toString().replace("-", "")); |
| | | String result = ArtemisHttpUtil.doPostStringArtemis(path, body, null, null, "application/json", header);// post请æ±application/jsonç±»ååæ° |
| | | saveInterfaceLog(body,result,path,pathStr[1]); |
| | | return result; |
| | | |
| | | } |
| | | public static String startDoPostStringArtemis(String[] pathStr,Map<String, String> querys,Map<String, String> header,String body){ |
| | | Map<String, String> path = getPath(pathStr[0]); |
| | | header.put("tagId", UUID.randomUUID().toString().replace("-", "")); |
| | | String result = ArtemisHttpUtil.doPostStringArtemis(path, body, querys, null, "application/json", header);// post请æ±application/jsonç±»ååæ° |
| | | saveInterfaceLog(body,result,path); |
| | | saveInterfaceLog(body,result,path,pathStr[1]); |
| | | return result; |
| | | |
| | | } |
| | |
| | | */ |
| | | public static String platformStatus(String param) { |
| | | if(StringUtils.isNotBlank(param)){ |
| | | return startDoPostStringArtemis(HKConstants.InterfacePath.platformStatus+"?platformIds="+param,null); |
| | | return startDoPostStringArtemis(HKConstants.InterfacePath.platformStatus,"?platformIds="+param,null); |
| | | }else{ |
| | | return startDoPostStringArtemis(HKConstants.InterfacePath.platformStatus,null); |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.doumee.dao.business; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.doumee.dao.business.model.PlatformWaterGas; |
| | | |
| | | /** |
| | | * @author æ±è¹è¹ |
| | | * @date 2024/08/26 16:22 |
| | | */ |
| | | public interface PlatformWaterGasMapper extends BaseMapper<PlatformWaterGas> { |
| | | |
| | | } |
| | |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.doumee.dao.business.model.Visits; |
| | | import com.github.yulichang.base.MPJBaseMapper; |
| | | |
| | | import java.util.List; |
| | | |
| | |
| | | * @author æ±è¹è¹ |
| | | * @date 2023/11/30 15:33 |
| | | */ |
| | | public interface VisitsMapper extends BaseMapper<Visits> { |
| | | public interface VisitsMapper extends MPJBaseMapper<Visits> { |
| | | |
| | | } |
| | |
| | | @ApiModelProperty(value = "å
³èä¸å¡ä¸»é®") |
| | | private Integer objId; |
| | | |
| | | @ApiModelProperty(value = "å
³èä¸å¡ç±»åï¼0éæ½å·¥äººå访客ç³è¯· 1éæ½å·¥äººå访客ç³è¯· 2访客æ¥å¤ 3å
¬è½¦å¸å
ç¨è½¦ 4å
¬è½¦å®¤å¤ç¨è½¦ 5å¸å
¬å¸ç©æµè½¦é¢çº¦") |
| | | @ApiModelProperty(value = "å
³èä¸å¡ç±»åï¼0éæ½å·¥äººå访客ç³è¯· 1éæ½å·¥äººå访客ç³è¯· 2访客æ¥å¤ 3å
¬è½¦å¸å
ç¨è½¦ 4å
¬è½¦å®¤å¤ç¨è½¦ 5å¸å
¬å¸ç©æµè½¦é¢çº¦ 6å
¥åé¢çº¦") |
| | | private Integer objType; |
| | | |
| | | @ApiModelProperty(value = "2审æ¹éè¿ 3å®¡æ¹æªéè¿") |
| | |
| | | @ExcelColumn(name="æ¯å¦ä¿®æ¹ç®çå° 0å¦ 1æ¯") |
| | | private Integer addrParam; |
| | | |
| | | @ApiModelProperty(value = "å
³èä¸å¡ç±»åï¼0éæ½å·¥äººå访客ç³è¯· 1éæ½å·¥äººå访客ç³è¯· 2访客æ¥å¤ 3å
¬è½¦å¸å
ç¨è½¦ 4å
¬è½¦å®¤å¤ç¨è½¦ 5å¸å
¬å¸ç©æµè½¦é¢çº¦", example = "1") |
| | | @ExcelColumn(name="å
³èä¸å¡ç±»åï¼0éæ½å·¥äººå访客ç³è¯· 1éæ½å·¥äººå访客ç³è¯· 2访客æ¥å¤ 3å
¬è½¦å¸å
ç¨è½¦ 4å
¬è½¦å®¤å¤ç¨è½¦ 5å¸å
¬å¸ç©æµè½¦é¢çº¦") |
| | | @ApiModelProperty(value = "å
³èä¸å¡ç±»åï¼0éæ½å·¥äººå访客ç³è¯· 1éæ½å·¥äººå访客ç³è¯· 2访客æ¥å¤ 3å
¬è½¦å¸å
ç¨è½¦ 4å
¬è½¦å®¤å¤ç¨è½¦ 5å¸å
¬å¸ç©æµè½¦é¢çº¦ 6å
¥ååå ", example = "1") |
| | | @ExcelColumn(name="å
³èä¸å¡ç±»åï¼0éæ½å·¥äººå访客ç³è¯· 1éæ½å·¥äººå访客ç³è¯· 2访客æ¥å¤ 3å
¬è½¦å¸å
ç¨è½¦ 4å
¬è½¦å®¤å¤ç¨è½¦ 5å¸å
¬å¸ç©æµè½¦é¢çº¦ 6å
¥ååå ") |
| | | private Integer objType; |
| | | |
| | | @ApiModelProperty(value = "ç±»å 0å®¡æ¹ 1æé", example = "1") |
| | |
| | | @ExcelColumn(name="夿³¨") |
| | | private String remark; |
| | | |
| | | @ApiModelProperty(value = "åç§° 0éæ½å·¥äººå访客ç³è¯· 1æ½å·¥äººå访客ç³è¯· 2访客æ¥å¤ 3å
¬è½¦å¸å
ç¨è½¦ 4å
¬è½¦å®¤å¤ç¨è½¦ 5å¸å
¬å¸ç©æµè½¦é¢çº¦", example = "1") |
| | | @ExcelColumn(name="åç§° 0éæ½å·¥äººå访客ç³è¯· 1æ½å·¥äººå访客ç³è¯· 2访客æ¥å¤ 3å
¬è½¦å¸å
ç¨è½¦ 4å
¬è½¦å®¤å¤ç¨è½¦ 5å¸å
¬å¸ç©æµè½¦é¢çº¦") |
| | | @ApiModelProperty(value = "åç§° 0éæ½å·¥äººå访客ç³è¯· 1æ½å·¥äººå访客ç³è¯· 2访客æ¥å¤ 3å
¬è½¦å¸å
ç¨è½¦ 4å
¬è½¦å®¤å¤ç¨è½¦ 5å¸å
¬å¸ç©æµè½¦é¢çº¦ 6å
¥ååå ", example = "1") |
| | | @ExcelColumn(name="åç§° 0éæ½å·¥äººå访客ç³è¯· 1æ½å·¥äººå访客ç³è¯· 2访客æ¥å¤ 3å
¬è½¦å¸å
ç¨è½¦ 4å
¬è½¦å®¤å¤ç¨è½¦ 5å¸å
¬å¸ç©æµè½¦é¢çº¦ 6å
¥ååå ") |
| | | private Integer type; |
| | | |
| | | @ApiModelProperty(value = "åç§°") |
| | |
| | | @TableField(exist = false) |
| | | private String queryDate; |
| | | |
| | | @ApiModelProperty(value = "å¾çåç¼") |
| | | @TableField(exist = false) |
| | | private String prefixUrl; |
| | | |
| | | @ApiModelProperty(value = "审æ¹ä¿¡æ¯æ°æ®") |
| | | @TableField(exist = false) |
| | | private ApproveDataVO approveDateVO; |
| | |
| | | |
| | | @ApiModelProperty(value = "åæ¹æéæ°é", example = "1") |
| | | @TableField(exist = false) |
| | | private Long lineUpNum; |
| | | private Integer lineUpNum; |
| | | |
| | | @ApiModelProperty(value = "é¢è®¡çå¾
æ¶é´", example = "1") |
| | | @TableField(exist = false) |
| | | private String waitTime; |
| | | |
| | | @ApiModelProperty(value = "é¢è®¡å®ææ¶é´", example = "1") |
| | | @TableField(exist = false) |
| | | private String finishTimeStr; |
| | | |
| | | @ApiModelProperty(value = "å
³èæå°ç»ç¼ç ï¼å
³èplatform_group表ï¼", example = "1") |
| | | @TableField(exist = false) |
| | |
| | | @TableField(exist = false) |
| | | private BigDecimal getDistance; |
| | | |
| | | @ApiModelProperty(value = "æå°ä½ä¸æçï¼ä¸æ¯/å°æ¶ï¼", hidden = true) |
| | | @TableField(exist = false) |
| | | private BigDecimal workRate; |
| | | |
| | | @ApiModelProperty(value = "ä¸å¡è§¦åæ¶é´ æ¶é´") |
| | | @TableField(exist = false) |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.doumee.dao.business.model; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.doumee.core.annotation.excel.ExcelColumn; |
| | | import com.doumee.core.model.LoginUserModel; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import lombok.Data; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import java.util.Date; |
| | | import java.math.BigDecimal; |
| | | |
| | | /** |
| | | * æå°_ç¨æ°´ç¨æ°ä¿¡æ¯è®°å½è¡¨ |
| | | * @author æ±è¹è¹ |
| | | * @date 2024/08/26 16:22 |
| | | */ |
| | | @Data |
| | | @ApiModel("æå°_ç¨æ°´ç¨æ°ä¿¡æ¯è®°å½è¡¨") |
| | | @TableName("`platform_water_gas`") |
| | | public class PlatformWaterGas extends LoginUserModel { |
| | | |
| | | @TableId(type = IdType.AUTO) |
| | | @ApiModelProperty(value = "主é®", example = "1") |
| | | @ExcelColumn(name="主é®") |
| | | private Integer id; |
| | | |
| | | @ApiModelProperty(value = "å建人ç¼ç ", example = "1") |
| | | @ExcelColumn(name="å建人ç¼ç ") |
| | | private Integer creator; |
| | | |
| | | @ApiModelProperty(value = "å建æ¶é´") |
| | | @ExcelColumn(name="å建æ¶é´") |
| | | private Date createDate; |
| | | |
| | | @ApiModelProperty(value = "æ´æ°äººç¼ç ", example = "1") |
| | | @ExcelColumn(name="æ´æ°äººç¼ç ") |
| | | private Integer editor; |
| | | |
| | | @ApiModelProperty(value = "æ´æ°æ¶é´") |
| | | @ExcelColumn(name="æ´æ°æ¶é´") |
| | | private Date editDate; |
| | | |
| | | @ApiModelProperty(value = "æ¯å¦å é¤0å¦ 1æ¯", example = "1") |
| | | @ExcelColumn(name="æ¯å¦å é¤0å¦ 1æ¯") |
| | | private Integer isdeleted; |
| | | |
| | | @ApiModelProperty(value = "夿³¨") |
| | | @ExcelColumn(name="夿³¨") |
| | | private String remark; |
| | | |
| | | @ApiModelProperty(value = "æ¶é´ï¼å¹´æï¼") |
| | | @ExcelColumn(name="æ¶é´ï¼å¹´æï¼") |
| | | private Date timeInfo; |
| | | |
| | | @ApiModelProperty(value = "æåºç ", example = "1") |
| | | @ExcelColumn(name="æåºç ") |
| | | private Integer sortnum; |
| | | |
| | | @ApiModelProperty(value = "ç±»å 0ç¨çµ 1ç¨çµ 2æ²¹è", example = "1") |
| | | @ExcelColumn(name="ç±»å 0ç¨çµ 1ç¨çµ 2æ²¹è") |
| | | private Integer type; |
| | | |
| | | @ApiModelProperty(value = "æ°é (ç¨çµé¡¿ï¼ç¨çµåº¦ï¼ æ²¹èLï¼", example = "1") |
| | | @ExcelColumn(name="æ°é (ç¨çµé¡¿ï¼ç¨çµåº¦ï¼ æ²¹èLï¼") |
| | | private BigDecimal num; |
| | | |
| | | @ApiModelProperty(value = "说æ") |
| | | @ExcelColumn(name="说æ") |
| | | private String content; |
| | | |
| | | @ApiModelProperty(value = "车çå·") |
| | | @ExcelColumn(name="车çå·") |
| | | private String carCode; |
| | | |
| | | @ApiModelProperty(value = "å¼å§æ¶é´") |
| | | @TableField(exist = false) |
| | | private Date startTime; |
| | | @ApiModelProperty(value = "å¼å§æ¶é´") |
| | | @TableField(exist = false) |
| | | private Date endTime; |
| | | } |
| | |
| | | @Api(tags = "å
¥åé¢çº¦ç³è¯·ä¿¡æ¯" ) |
| | | public class PlatformBooksApplyDTO { |
| | | |
| | | @ApiModelProperty(value = "ä¸»é® - ä¿®æ¹ä½¿ç¨") |
| | | private Integer id; |
| | | @ApiModelProperty(value = "ååå·") |
| | | private String contractNum; |
| | | |
| | |
| | | @ApiModelProperty(value = "æå°ä»»å¡å表") |
| | | private List<PlatformJob> platformJobList; |
| | | |
| | | @ApiModelProperty(value = "é¢çº¦æå") |
| | | private String bookingTips; |
| | | |
| | | @ApiModelProperty(value = "ååºå¯¼è§å¾") |
| | | private String reservationMap; |
| | | |
| | | |
| | | } |
| | |
| | | |
| | | void createApproveFlow(Integer tempType,Integer businessId,Integer createMemberId); |
| | | |
| | | void createApproveForPlatfrom(Integer tempId,Integer businessId,Integer createMemberId); |
| | | |
| | | ApproveDataVO arrangeApprovedData(Integer businessId, Integer businessType, Integer memberId); |
| | | |
| | | void approved(ApproveDTO approveDTO); |
| | |
| | | package com.doumee.service.business; |
| | | |
| | | import com.doumee.core.model.LoginUserInfo; |
| | | import com.doumee.core.model.PageData; |
| | | import com.doumee.core.model.PageWrap; |
| | | import com.doumee.dao.business.model.Platform; |
| | | import com.doumee.dao.business.model.PlatformJob; |
| | | import com.doumee.dao.web.reqeust.JobDetailDTO; |
| | | import com.doumee.dao.web.reqeust.JobOperateDTO; |
| | |
| | | */ |
| | | long count(PlatformJob platformJob); |
| | | |
| | | DriverHomeVO getDriverHome(Integer memberId); |
| | | DriverHomeVO getDriverHome(LoginUserInfo loginUserInfo); |
| | | |
| | | /** |
| | | * è·ç¦»ç¾å° |
| | |
| | | */ |
| | | void finishWork(JobOperateDTO jobOperateDTO); |
| | | |
| | | /** |
| | | * è·åæå°ä¸çä»»å¡ä¿¡æ¯ |
| | | * @param groupId |
| | | * @param loginUserInfo |
| | | * @return |
| | | */ |
| | | List<Platform> getPlatformList(Integer groupId, LoginUserInfo loginUserInfo); |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.doumee.service.business; |
| | | |
| | | import com.doumee.core.model.LoginUserInfo; |
| | | import com.doumee.core.model.LoginUserModel; |
| | | import com.doumee.core.model.PageData; |
| | | import com.doumee.core.model.PageWrap; |
| | | import com.doumee.dao.business.model.PlatformWaterGas; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * æå°_ç¨æ°´ç¨æ°ä¿¡æ¯è®°å½è¡¨Serviceå®ä¹ |
| | | * @author æ±è¹è¹ |
| | | * @date 2024/08/26 16:22 |
| | | */ |
| | | public interface PlatformWaterGasService { |
| | | |
| | | /** |
| | | * å建 |
| | | * |
| | | * @param platformWaterGas å®ä½å¯¹è±¡ |
| | | * @return Integer |
| | | */ |
| | | Integer create(PlatformWaterGas platformWaterGas); |
| | | |
| | | /** |
| | | * 主é®å é¤ |
| | | * |
| | | * @param id ä¸»é® |
| | | */ |
| | | void deleteById(Integer id); |
| | | |
| | | /** |
| | | * å é¤ |
| | | * |
| | | * @param platformWaterGas å®ä½å¯¹è±¡ |
| | | */ |
| | | void delete(PlatformWaterGas platformWaterGas); |
| | | void deleteById(Integer id, LoginUserInfo user); |
| | | |
| | | /** |
| | | * æ¹é主é®å é¤ |
| | | * |
| | | * @param ids 主é®é |
| | | */ |
| | | void deleteByIdInBatch(List<Integer> ids); |
| | | void deleteByIdInBatch(List<Integer> ids, LoginUserInfo user); |
| | | |
| | | /** |
| | | * 䏻鮿´æ° |
| | | * |
| | | * @param platformWaterGas å®ä½å¯¹è±¡ |
| | | */ |
| | | void updateById(PlatformWaterGas platformWaterGas); |
| | | |
| | | /** |
| | | * æ¹é䏻鮿´æ° |
| | | * |
| | | * @param platformWaterGass å®ä½é |
| | | */ |
| | | void updateByIdInBatch(List<PlatformWaterGas> platformWaterGass); |
| | | |
| | | /** |
| | | * 䏻鮿¥è¯¢ |
| | | * |
| | | * @param id ä¸»é® |
| | | * @return PlatformWaterGas |
| | | */ |
| | | PlatformWaterGas findById(Integer id); |
| | | |
| | | /** |
| | | * æ¡ä»¶æ¥è¯¢åæ¡è®°å½ |
| | | * |
| | | * @param platformWaterGas å®ä½å¯¹è±¡ |
| | | * @return PlatformWaterGas |
| | | */ |
| | | PlatformWaterGas findOne(PlatformWaterGas platformWaterGas); |
| | | |
| | | /** |
| | | * æ¡ä»¶æ¥è¯¢ |
| | | * |
| | | * @param platformWaterGas å®ä½å¯¹è±¡ |
| | | * @return List<PlatformWaterGas> |
| | | */ |
| | | List<PlatformWaterGas> findList(PlatformWaterGas platformWaterGas); |
| | | |
| | | /** |
| | | * å页æ¥è¯¢ |
| | | * |
| | | * @param pageWrap å页对象 |
| | | * @return PageData<PlatformWaterGas> |
| | | */ |
| | | PageData<PlatformWaterGas> findPage(PageWrap<PlatformWaterGas> pageWrap); |
| | | |
| | | /** |
| | | * æ¡ä»¶ç»è®¡ |
| | | * |
| | | * @param platformWaterGas å®ä½å¯¹è±¡ |
| | | * @return long |
| | | */ |
| | | long count(PlatformWaterGas platformWaterGas); |
| | | } |
| | |
| | | void visitCancel(Integer visitId); |
| | | |
| | | void resetPassword(ResetPasswordDTO resetPasswordDTO); |
| | | |
| | | void visitResend(Integer visitId); |
| | | } |
| | |
| | | import com.github.xiaoymin.knife4j.core.util.CollectionUtils; |
| | | import com.github.yulichang.wrapper.MPJLambdaWrapper; |
| | | import io.swagger.models.auth.In; |
| | | import javafx.application.Platform; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.apache.commons.lang3.StringUtils; |
| | | import org.apache.xpath.operations.Bool; |
| | |
| | | } |
| | | |
| | | |
| | | @Override |
| | | @Transactional(rollbackFor = {Exception.class,BusinessException.class}) |
| | | public void createApproveForPlatfrom(Integer tempId,Integer businessId,Integer createMemberId){ |
| | | //æ¥è¯¢å¤çæ¨¡æ¿ |
| | | ApproveTempl approveTempl = approveTemplMapper.selectById(tempId); |
| | | if(Objects.isNull(approveTempl)){ |
| | | throw new BusinessException(ResponseStatus.DATA_EMPTY.getCode(),"æªæ¥è¯¢å°å®¡æ¹æµé
置模æ¿"); |
| | | } |
| | | //æ¥è¯¢é
ç½®æµç¨ |
| | | List<ApproveParam> approveParamAllList = approveParamMapper.selectList(new QueryWrapper<ApproveParam>() |
| | | .lambda().eq(ApproveParam::getIsdeleted,Constants.ZERO) |
| | | .eq(ApproveParam::getTemplId,approveTempl.getId()) |
| | | .orderByAsc(ApproveParam::getType) |
| | | .orderByAsc(ApproveParam::getLevel) |
| | | ); |
| | | if(Objects.isNull(approveParamAllList)){ |
| | | throw new BusinessException(ResponseStatus.DATA_EMPTY.getCode(),"æªé
ç½®å®¡æ¹æµç¨"); |
| | | } |
| | | //审æ¹é
ç½® |
| | | List<ApproveParam> approveParamList = approveParamAllList.stream().filter(i->i.getType().equals(Constants.ZERO)).collect(Collectors.toList()); |
| | | if(Objects.isNull(approveParamList)){ |
| | | throw new BusinessException(ResponseStatus.DATA_EMPTY.getCode(),"æªé
ç½®å®¡æ¹æµç¨"); |
| | | } |
| | | List<ApproveParam> approveCopyList = approveParamAllList.stream().filter(i->i.getType().equals(Constants.ONE)).collect(Collectors.toList()); |
| | | |
| | | Member createMember = memberMapper.selectById(createMemberId); |
| | | if(Objects.isNull(createMember)){ |
| | | throw new BusinessException(ResponseStatus.DATA_EMPTY.getCode(),"ç³è¯·äººç»ç»ä¿¡æ¯å¼å¸¸"); |
| | | } |
| | | List<Approve> approveList = new ArrayList<>(); |
| | | |
| | | this.organizeApproveData(approveTempl,approveParamList,createMember,businessId,approveList); |
| | | |
| | | if(CollectionUtils.isEmpty(approveList)){ |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"å®¡æ¹æµé
ç½®é误"); |
| | | } |
| | | |
| | | //å¤çæéæ°æ® |
| | | if(CollectionUtils.isNotEmpty(approveCopyList)){ |
| | | this.organizeApproveCopyData(approveTempl,approveCopyList,businessId,approveList); |
| | | } |
| | | approveJoinMapper.insert(approveList); |
| | | |
| | | } |
| | | |
| | | |
| | | /** |
| | | * ç»ç»å®¡æ¹æµæ°æ® |
| | | * @param approveTempl |
| | |
| | | jsonMap.put("eTime", "ç»ææ¶é´:" + DateUtil.DateToStr(carUseBook.getEndTime() , "yyyy-MM-dd HH:mm")); |
| | | jsonMap.put("usrNum", StringUtils.isBlank(carUseBook.getMemberIds())?"ä¹è½¦äººæ°: 0人": "ä¹è½¦äººæ°: " +carUseBook.getMemberIds().split(",").length +"人"); |
| | | jsonMap.put("mdd", StringUtils.isBlank(carUseBook.getAddr())?"ç®çå°: - ": "ç®çå°:" +carUseBook.getAddr()); |
| | | }else { |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED); |
| | | }else if(Constants.equalsInteger(noticeType,Constants.noticesObjectType.reason)){ |
| | | //ç©æµè½¦é¢çº¦ |
| | | PlatformBooks platformBooks = platformBooksMapper.selectById(businessId); |
| | | if(Objects.isNull(platformBooks)){ |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"æªæ¥è¯¢å°ä¸å¡æ°æ®ä¿¡æ¯"); |
| | | } |
| | | title = "ãç©æµè½¦å
¥åé¢çº¦ãç³è¯·äºº - " + platformBooks.getDriverName(); |
| | | jsonMap.put("inType", "å
¥åºç±»åï¼"+(Constants.equalsInteger(platformBooks.getInType(),Constants.ZERO)?"æ´æç":"ä»¶ç")); |
| | | jsonMap.put("totalNum", "æ»è¿è¾éï¼"+platformBooks.getTotalNum()+"䏿¯"); |
| | | jsonMap.put("arriveDate", "å°åºæ¶é´ï¼" + DateUtil.DateToStr(platformBooks.getArriveDate() , "yyyy-MM-dd HH:mm")); |
| | | jsonMap.put("carNum", "车çç
§ï¼"+platformBooks.getCarCodeFront()); |
| | | } |
| | | return title; |
| | | } |
| | |
| | | }else if(approveDTO.getObjType().equals(Constants.approveObjectType.cityUseCar)||approveDTO.getObjType().equals( |
| | | Constants.approveObjectType.unCityUseCar)){ |
| | | this.updDriver(approveDTO,approve,true); |
| | | }else if(approveDTO.getObjType().equals(Constants.approveObjectType.logisticsCarUse)){ |
| | | }else if(approveDTO.getObjType().equals(Constants.approveObjectType.reason)){ |
| | | //ç©æµè½¦é¢çº¦ |
| | | PlatformBooks platformBooks = platformBooksMapper.selectById(approveDTO.getObjId()); |
| | | if(Objects.isNull(platformBooks)){ |
| | |
| | | days = Integer.parseInt(systemDictDataBiz.queryByCode(Constants.SYSTEM,Constants.HK_LOG_DEL_DAYS_LIMIT).getCode()); |
| | | }catch (Exception e){} |
| | | interfaceLogMapper.delete(new UpdateWrapper<InterfaceLog>().lambda() |
| | | .apply("to_days(create_date)+"+days+" < to_days(now())") ); |
| | | .apply("to_days(create_dat e)+"+days+" < to_days(now())") ); |
| | | } |
| | | } |
| | |
| | | systemUser.setUsername(registerDriverDTO.getPhone()); |
| | | systemUser.setRealname(registerDriverDTO.getName()); |
| | | systemUser.setMemberId(member.getId()); |
| | | systemUser.setMobile(registerDriverDTO.getPhone()); |
| | | systemUser.setSalt(salt); |
| | | systemUser.setPassword(member.getPassward()); |
| | | systemUser.setStatus(Constants.ZERO); |
| | |
| | | } |
| | | //æ¥è¯¢æ¯æ¥é
ç½®çæ»é¢çº¦é |
| | | PlatformReason platformReason = platformReasonMapper.selectById(platformBooksCheckNumDTO.getReasonId()); |
| | | if(Objects.isNull(platformReason)|| Constants.equalsInteger(platformReason.getIsdeleted(),Constants.ZERO)){ |
| | | if(Objects.isNull(platformReason)|| !Constants.equalsInteger(platformReason.getIsdeleted(),Constants.ZERO)){ |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"å
¥ååå ä¿¡æ¯å¼å¸¸,è¯·å·æ°éè¯"); |
| | | } |
| | | List<PlatformBooks> platformBooksList = platformBooksMapper.selectList(new QueryWrapper<PlatformBooks>().lambda() |
| | |
| | | throw new BusinessException(ResponseStatus.BAD_REQUEST); |
| | | } |
| | | PlatformReason platformReason = platformReasonMapper.selectById(platformBooksApplyDTO.getReasonId()); |
| | | if(Objects.isNull(platformReason)|| Constants.equalsInteger(platformReason.getIsdeleted(),Constants.ZERO)){ |
| | | if(Objects.isNull(platformReason)|| !Constants.equalsInteger(platformReason.getIsdeleted(),Constants.ZERO)){ |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"å
¥ååå ä¿¡æ¯å¼å¸¸,è¯·å·æ°éè¯"); |
| | | } |
| | | ApproveTempl approveTempl = approveTemplMapper.selectOne(new QueryWrapper<ApproveTempl>().lambda() |
| | | .eq(ApproveTempl::getIsdeleted,Constants.ZERO) |
| | | .eq(ApproveTempl::getObjId,platformReason.getId()) |
| | | .last(" limit 1") |
| | | ); |
| | | ApproveTempl approveTempl = approveTemplMapper.selectById(platformReason.getId()); |
| | | if(Objects.isNull(approveTempl)){ |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"æªé
ç½®å®¡æ¹æµ,请è系管çå"); |
| | | } |
| | | |
| | | if(Constants.equalsInteger(platformBooksApplyDTO.getUserId(),platformBooksApplyDTO.getDriverId())){ |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"人åä¿¡æ¯å¹é
é误"); |
| | | } |
| | | if(Objects.nonNull(platformReason.getLimitNum())&&platformReason.getLimitNum().compareTo(platformBooksApplyDTO.getTotalNum())>0){ |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"è¶
åºå
¥åç³è¯·çº¿è´¨é"); |
| | | if(!Constants.equalsInteger(approveTempl.getIsdeleted(),Constants.ZERO)){ |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"å®¡æ¹æµå·²åç¨,请è系管çå"); |
| | | } |
| | | PlatformBooks platformBooks = new PlatformBooks(); |
| | | BeanUtils.copyProperties(platformBooksApplyDTO,platformBooks); |
| | |
| | | platformBooksMapper.insert(platformBooks); |
| | | |
| | | //åå»ºå®¡æ¹æµä¿¡æ¯ |
| | | approveService.createApproveFlow(5,platformBooks.getId(),platformBooks.getDriverId()); |
| | | approveService.createApproveForPlatfrom(platformReason.getApproveTemplId(),platformBooks.getId(),platformBooks.getDriverId()); |
| | | return platformBooks.getId(); |
| | | } |
| | | |
| | | |
| | | |
| | | // @Override |
| | | @Transactional(rollbackFor = {BusinessException.class,Exception.class}) |
| | | public Integer edit(PlatformBooksApplyDTO platformBooksApplyDTO){ |
| | | if(Objects.isNull(platformBooksApplyDTO) |
| | | || Objects.isNull(platformBooksApplyDTO.getId()) |
| | | || StringUtils.isBlank(platformBooksApplyDTO.getContractNum()) |
| | | || Objects.isNull(platformBooksApplyDTO.getArriveDate()) |
| | | || Objects.isNull(platformBooksApplyDTO.getInType()) |
| | | || Objects.isNull(platformBooksApplyDTO.getTotalNum()) |
| | | || StringUtils.isBlank(platformBooksApplyDTO.getCarCodeFront()) |
| | | || StringUtils.isBlank(platformBooksApplyDTO.getCarCodeBack()) |
| | | || Objects.isNull(platformBooksApplyDTO.getDriverId()) |
| | | || StringUtils.isBlank(platformBooksApplyDTO.getDriverPhone()) |
| | | || StringUtils.isBlank(platformBooksApplyDTO.getDriverName()) |
| | | || StringUtils.isBlank(platformBooksApplyDTO.getTransportImg()) |
| | | || Objects.isNull(platformBooksApplyDTO.getReasonId()) |
| | | || StringUtils.isBlank(platformBooksApplyDTO.getInReason()) |
| | | ){ |
| | | throw new BusinessException(ResponseStatus.BAD_REQUEST); |
| | | } |
| | | PlatformBooks platformBooks = platformBooksMapper.selectById(platformBooksApplyDTO.getId()); |
| | | if(Objects.isNull(platformBooks)){ |
| | | throw new BusinessException(ResponseStatus.DATA_EMPTY); |
| | | } |
| | | if(!Constants.equalsInteger(platformBooks.getStatus(),Constants.ZERO)){ |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"ä¸å¡ç¶æå·²æµè½¬"); |
| | | } |
| | | BeanUtils.copyProperties(platformBooksApplyDTO,platformBooks); |
| | | platformBooks.setEditDate(new Date()); |
| | | platformBooksMapper.insert(platformBooks); |
| | | return platformBooks.getId(); |
| | | } |
| | | |
| | | |
| | | |
| | | @Override |
| | |
| | | if(Objects.isNull(model)){ |
| | | throw new BusinessException(ResponseStatus.DATA_EMPTY.getCode(),"æªæ¥è¯¢å°é¢çº¦è®°å½"); |
| | | } |
| | | String prefixUrl = systemDictDataBiz.queryByCode(Constants.FTP,Constants.FTP_RESOURCE_PATH).getCode() + |
| | | systemDictDataBiz.queryByCode(Constants.FTP,Constants.PLATFORM).getCode(); |
| | | model.setPrefixUrl(prefixUrl); |
| | | |
| | | ApproveDataVO approveDataVO = approveService.arrangeApprovedData(id, |
| | | 5, |
| | | 6, |
| | | memberId); |
| | | model.setApproveDateVO(approveDataVO); |
| | | List<Approve> approveList = approveDataVO.getApproveList(); |
| | |
| | | import com.doumee.core.model.PageData; |
| | | import com.doumee.core.model.PageWrap; |
| | | import com.doumee.core.utils.Constants; |
| | | import com.doumee.core.utils.DateUtil; |
| | | import com.doumee.core.utils.Utils; |
| | | import com.doumee.dao.business.PlatformGroupMapper; |
| | | import com.doumee.dao.business.PlatformShowParamMapper; |
| | | import com.doumee.dao.business.join.PlatformJobJoinMapper; |
| | | import com.doumee.dao.business.join.PlatformJoinMapper; |
| | | import com.doumee.dao.business.model.Platform; |
| | | import com.doumee.dao.business.model.PlatformGroup; |
| | | import com.doumee.dao.business.model.PlatformJob; |
| | | import com.doumee.dao.business.model.PlatformShowParam; |
| | | import com.doumee.service.business.PlatformGroupService; |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.doumee.service.business.PlatformJobService; |
| | | import com.github.yulichang.wrapper.MPJLambdaWrapper; |
| | | import lombok.extern.java.Log; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.util.CollectionUtils; |
| | |
| | | |
| | | @Autowired |
| | | private PlatformShowParamMapper platformShowParamMapper; |
| | | |
| | | @Autowired |
| | | private PlatformJobJoinMapper platformJobJoinMapper; |
| | | |
| | | @Override |
| | | public Integer create(PlatformGroup platformGroup) { |
| | |
| | | .selectAll(Platform.class) |
| | | .select(" ( select count(1) from platform_job pj where t.id = pj.PLATFORM_ID and pj.STATUS = "+Constants.PlatformJobStatus.WORKING.getKey()+" ) as workStatus ") |
| | | .eq(Platform::getIsdeleted, Constants.ZERO) |
| | | .eq(Platform::getStatus, Constants.ZERO) |
| | | .eq(Objects.nonNull(queryType)&&!Constants.equalsInteger(queryType,Constants.ZERO),Platform::getStatus,Constants.ZERO) |
| | | ); |
| | | //å¤çæçæå°ä¿¡æ¯ æ¯å¦é
ç½®éè |
| | |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | } |
| | |
| | | import com.doumee.biz.system.SystemDictDataBiz; |
| | | import com.doumee.core.constants.ResponseStatus; |
| | | import com.doumee.core.exception.BusinessException; |
| | | import com.doumee.core.model.LoginUserInfo; |
| | | import com.doumee.core.model.PageData; |
| | | import com.doumee.core.model.PageWrap; |
| | | import com.doumee.core.utils.Constants; |
| | |
| | | import com.doumee.core.utils.Utils; |
| | | import com.doumee.dao.business.*; |
| | | import com.doumee.dao.business.join.PlatformJobJoinMapper; |
| | | import com.doumee.dao.business.join.PlatformJoinMapper; |
| | | import com.doumee.dao.business.model.*; |
| | | import com.doumee.dao.web.reqeust.JobDetailDTO; |
| | | import com.doumee.dao.web.reqeust.JobOperateDTO; |
| | |
| | | import org.springframework.util.CollectionUtils; |
| | | |
| | | import java.math.BigDecimal; |
| | | import java.math.RoundingMode; |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | import java.util.Objects; |
| | |
| | | @Autowired |
| | | private SystemDictDataBiz systemDictDataBiz; |
| | | |
| | | |
| | | @Autowired |
| | | private PlatformMapper platformMapper; |
| | | private PlatformJoinMapper platformJoinMapper; |
| | | |
| | | @Autowired |
| | | private PlatformLogMapper platformLogMapper; |
| | |
| | | |
| | | @Autowired |
| | | private PlatformWmsDetailMapper platformWmsDetailMapper; |
| | | |
| | | @Autowired |
| | | private PlatformGroupMapper platformGroupMapper; |
| | | |
| | | @Autowired |
| | | private PlatformShowParamMapper platformShowParamMapper; |
| | | |
| | | |
| | | @Override |
| | |
| | | @Override |
| | | public PageData<PlatformJob> findPage(PageWrap<PlatformJob> pageWrap) { |
| | | IPage<PlatformJob> page = new Page<>(pageWrap.getPage(), pageWrap.getCapacity()); |
| | | QueryWrapper<PlatformJob> queryWrapper = new QueryWrapper<>(); |
| | | MPJLambdaWrapper<PlatformJob> queryWrapper = new MPJLambdaWrapper<>(); |
| | | Utils.MP.blankToNull(pageWrap.getModel()); |
| | | queryWrapper.lambda() |
| | | queryWrapper |
| | | .selectAll(PlatformJob.class) |
| | | .selectAs(Platform::getName,PlatformJob::getPlatformName) |
| | | .selectAs(Platform::getWorkRate,PlatformJob::getWorkRate) |
| | | .leftJoin(Platform.class,Platform::getId,PlatformJob::getPlatformId) |
| | | .eq(pageWrap.getModel().getId() != null, PlatformJob::getId, pageWrap.getModel().getId()) |
| | | .eq(pageWrap.getModel().getCreator() != null, PlatformJob::getCreator, pageWrap.getModel().getCreator()) |
| | | .ge(pageWrap.getModel().getCreateDate() != null, PlatformJob::getCreateDate, Utils.Date.getStart(pageWrap.getModel().getCreateDate())) |
| | |
| | | queryWrapper.orderByAsc(sortData.getProperty()); |
| | | } |
| | | } |
| | | |
| | | PageData<PlatformJob> pageData = PageData.from(platformJobMapper.selectPage(page, queryWrapper)); |
| | | pageData.getRecords().forEach(i->{ |
| | | IPage<PlatformJob> platformJobIPage = platformJobJoinMapper.selectJoinPage(page,PlatformJob.class,queryWrapper); |
| | | platformJobIPage.getRecords().forEach(i->{ |
| | | i.dealTime(); |
| | | this.getWmsJobData(i); |
| | | }); |
| | | return pageData; |
| | | return PageData.from(platformJobIPage); |
| | | // PageData<PlatformJob> pageData = PageData.from(platformJobMapper.selectPage(page, queryWrapper)); |
| | | // pageData.getRecords().forEach(i->{ |
| | | // i.dealTime(); |
| | | // this.getWmsJobData(i); |
| | | // }); |
| | | // return pageData; |
| | | } |
| | | |
| | | |
| | |
| | | platformWmsJob.setPlatformWmsDetailList(platformWmsDetailList); |
| | | platformJob.setPlatformWmsJob(platformWmsJob); |
| | | } |
| | | } |
| | | |
| | | |
| | | } |
| | | } |
| | | |
| | | |
| | | public void queryWaitNum(PlatformJob platformJob){ |
| | | if(Constants.equalsInteger(platformJob.getStatus(),Constants.PlatformJobStatus.WAIT_CALL.getKey())){ |
| | | //æ¥è¯¢åæ¹æéæ°é |
| | | List<PlatformJob> lineUpNum = platformJobMapper.selectList(new QueryWrapper<PlatformJob>().lambda() |
| | | .eq(PlatformJob::getIsdeleted,Constants.ZERO) |
| | | .in(PlatformJob::getStatus,Constants.PlatformJobStatus.WAIT_CALL.getKey() |
| | | ,Constants.PlatformJobStatus.IN_WAIT.getKey() |
| | | ,Constants.PlatformJobStatus.TRANSFERING.getKey()) |
| | | .gt(PlatformJob::getSignDate,platformJob.getSignDate()) |
| | | .eq(PlatformJob::getPlatformGroupId,platformJob.getPlatformGroupId()) |
| | | .like(PlatformJob::getArriveDate,DateUtil.getDate(platformJob.getArriveDate(),"yyyy-MM-dd"))); |
| | | platformJob.setLineUpNum(lineUpNum.size()); |
| | | BigDecimal sumWorkRate = platformJob.getTotalNum(); |
| | | for (PlatformJob linePlatformJob:lineUpNum) { |
| | | this.getWmsJobData(linePlatformJob); |
| | | sumWorkRate = sumWorkRate.add(linePlatformJob.getTotalNum()); |
| | | } |
| | | //计ç®é¢è®¡çå¾
æ¶é´ |
| | | List<Platform> platformList = platformJoinMapper.selectList(new QueryWrapper<Platform>().lambda().eq(Platform::getIsdeleted,Constants.ZERO).eq(Platform::getGroupId,platformJob.getPlatformGroupId())); |
| | | BigDecimal workRate = platformList.stream().map(m->m.getWorkRate()).reduce(BigDecimal.ZERO,BigDecimal::add); |
| | | if(sumWorkRate.compareTo(BigDecimal.ZERO) == Constants.ZERO|| workRate.compareTo(BigDecimal.ZERO) == Constants.ZERO ){ |
| | | BigDecimal sumMinute = sumWorkRate.divide(workRate,1, RoundingMode.HALF_DOWN).multiply(BigDecimal.valueOf(60L)); |
| | | Integer sumMinuteInteger = sumMinute.intValue(); |
| | | Integer hours = sumMinuteInteger/60; |
| | | Integer minus = sumMinuteInteger%60; |
| | | String waitTime = "é¢è®¡çå¾
ï¼"; |
| | | if(!Constants.equalsInteger(hours,Constants.ZERO)){ |
| | | waitTime = waitTime + hours + "å°æ¶"; |
| | | } |
| | | if(!Constants.equalsInteger(hours,Constants.ZERO)){ |
| | | waitTime = waitTime + minus + "åé"; |
| | | } |
| | | platformJob.setWaitTime(waitTime); |
| | | } |
| | | }else if(Constants.equalsInteger(platformJob.getStatus(),Constants.PlatformJobStatus.WORKING.getKey())){ |
| | | //æ¥è¯¢æåå¼å§ä»»å¡çæå°è®°å½ æ¥å¿è¡¨ å 为åå¨å¼å¸¸æèµ· 转移 çé®é¢ |
| | | PlatformLog platformLog = platformLogMapper.selectOne(new QueryWrapper<PlatformLog>().lambda() |
| | | .eq(PlatformLog::getJobId,platformJob.getId()) |
| | | .eq(PlatformLog::getObjType,Constants.PlatformJobStatus.WORKING.getKey()) |
| | | .orderByDesc(PlatformLog::getCreateDate) |
| | | .last(" limit 1") |
| | | ); |
| | | if(Objects.nonNull(platformLog)){ |
| | | BigDecimal sumMinute = platformJob.getTotalNum().divide(platformJob.getWorkRate(),1, RoundingMode.HALF_DOWN).multiply(BigDecimal.valueOf(60L)); |
| | | platformJob.setFinishTimeStr(DateUtil.DateToStr(DateUtil.afterMinutesDate(platformLog.getCreateDate(),sumMinute.intValue()),"HH:mm")); |
| | | } |
| | | } |
| | | } |
| | | |
| | | |
| | | @Override |
| | | public long count(PlatformJob platformJob) { |
| | | QueryWrapper<PlatformJob> wrapper = new QueryWrapper<>(platformJob); |
| | |
| | | |
| | | //TODO |
| | | @Override |
| | | public DriverHomeVO getDriverHome(Integer memberId){ |
| | | public DriverHomeVO getDriverHome(LoginUserInfo loginUserInfo){ |
| | | DriverHomeVO driverHomeVO = new DriverHomeVO(); |
| | | //TODO è½®æå¾ |
| | | |
| | | List<PlatformJob> platformJobList = platformJobMapper.selectList(new QueryWrapper<PlatformJob>() |
| | | .lambda() |
| | | .eq(PlatformJob::getDriverId,memberId) |
| | | // .like(PlatformJob::get) |
| | | .orderByDesc(PlatformJob::getId)); |
| | | List<PlatformJob> platformJobList = platformJobJoinMapper.selectJoinList(PlatformJob.class,new MPJLambdaWrapper<PlatformJob>() |
| | | .selectAll(PlatformJob.class) |
| | | .selectAs(Platform::getName,PlatformJob::getPlatformName) |
| | | .selectAs(Platform::getWorkRate,PlatformJob::getWorkRate) |
| | | .leftJoin(Platform.class,Platform::getId,PlatformJob::getPlatformId) |
| | | .eq(PlatformJob::getIsdeleted,Constants.ZERO) |
| | | .eq(PlatformJob::getDrivierPhone,loginUserInfo.getMobile()) |
| | | .like(PlatformJob::getArriveDate,DateUtil.getCurrDate()) |
| | | .orderByDesc(PlatformJob::getId) |
| | | ); |
| | | for (PlatformJob platformJob:platformJobList) { |
| | | //å¤çWSMæ°é |
| | | this.getWmsJobData(platformJob); |
| | | //æ¥è¯¢åæ¹æéæ°é |
| | | this.queryWaitNum(platformJob); |
| | | } |
| | | |
| | | |
| | | driverHomeVO.setPlatformJobList(platformJobList); |
| | | |
| | | // ååºå¯¼è§å¾ å¾ç |
| | | driverHomeVO.setReservationMap(systemDictDataBiz.queryByCode(Constants.PLATFORM,Constants.PLATFORM_GUIDEMAP).getCode()); |
| | | // é¢çº¦æå ææ¬ |
| | | driverHomeVO.setBookingTips(systemDictDataBiz.queryByCode(Constants.PLATFORM,Constants.PLATFORM_BOOKING_TIPS).getCode()); |
| | | |
| | | return driverHomeVO; |
| | | } |
| | |
| | | } |
| | | }else if( Constants.equalsInteger(platformJob.getStatus(),Constants.PlatformJobStatus.WAIT_CALL.getKey()) |
| | | || Constants.equalsInteger(platformJob.getStatus(),Constants.PlatformJobStatus.IN_WAIT.getKey()) |
| | | ){//æ¥è¯¢æéæ
åµ |
| | | Long lineUpNum = platformJobMapper.selectCount(new QueryWrapper<PlatformJob>().lambda() |
| | | .eq(PlatformJob::getIsdeleted,Constants.ZERO) |
| | | .in(PlatformJob::getStatus,Constants.PlatformJobStatus.WAIT_CALL.getKey() |
| | | ,Constants.PlatformJobStatus.IN_WAIT.getKey() |
| | | ,Constants.PlatformJobStatus.TRANSFERING.getKey()) |
| | | .gt(PlatformJob::getSignDate,platformJob.getSignDate()) |
| | | .like(PlatformJob::getArriveDate,DateUtil.getDate(platformJob.getArriveDate(),"yyyy-MM-dd"))); |
| | | platformJob.setLineUpNum(lineUpNum); |
| | | ){ |
| | | //æ¥è¯¢åæ¹æéæ°é |
| | | this.queryWaitNum(platformJob); |
| | | }else if(Constants.equalsInteger(platformJob.getStatus(),Constants.PlatformJobStatus.WORKING.getKey())){ |
| | | //ä½ä¸æå°ä¿¡æ¯ |
| | | Platform platform = platformMapper.selectById(platformJob.getPlatformId()); |
| | | Platform platform = platformJoinMapper.selectById(platformJob.getPlatformId()); |
| | | if(Objects.nonNull(platform)){ |
| | | platformJob.setPlatformName(platform.getName()); |
| | | } |
| | |
| | | ); |
| | | //è·åæææå°ç» |
| | | List<Integer> platformIdList = platformJobList.stream().map(m->m.getPlatformGroupId()).collect(Collectors.toList()); |
| | | List<Platform> platformList = platformMapper.selectList(new QueryWrapper<Platform>().lambda() |
| | | List<Platform> platformList = platformJoinMapper.selectList(new QueryWrapper<Platform>().lambda() |
| | | .eq(Platform::getIsdeleted,Constants.ZERO) |
| | | .in(Platform::getId,platformIdList)); |
| | | |
| | |
| | | } |
| | | |
| | | |
| | | @Override |
| | | public List<Platform> getPlatformList(Integer groupId, LoginUserInfo loginUserInfo){ |
| | | //æ¥è¯¢æå°ç»ä¸æææå° |
| | | List<Platform> allPlatformList = platformJoinMapper.selectJoinList(Platform.class, |
| | | new MPJLambdaWrapper<Platform>() |
| | | .selectAll(Platform.class) |
| | | .select(" ( select count(1) from platform_job pj where t.id = pj.PLATFORM_ID and pj.STATUS = "+Constants.PlatformJobStatus.WORKING.getKey()+" ) as workStatus ") |
| | | .eq(Platform::getIsdeleted, Constants.ZERO) |
| | | .eq(Platform::getStatus,Constants.ZERO) |
| | | .eq(Platform::getGroupId,groupId) |
| | | ); |
| | | this.getPlatformShow(allPlatformList,loginUserInfo); |
| | | for (Platform platform:allPlatformList) { |
| | | this.getJobByPlatform(platform,loginUserInfo); |
| | | } |
| | | return allPlatformList; |
| | | } |
| | | |
| | | /** |
| | | * æ¥è¯¢æå°çå¼å¯æ
åµ |
| | | * @param allPlatformList |
| | | * @param loginUserInfo |
| | | */ |
| | | public void getPlatformShow(List<Platform> allPlatformList , LoginUserInfo loginUserInfo){ |
| | | //å¤çæçæå°ä¿¡æ¯ æ¯å¦é
ç½®éè |
| | | List<PlatformShowParam> platformShowParamList = platformShowParamMapper.selectList(new QueryWrapper<PlatformShowParam>() |
| | | .lambda() |
| | | .eq(PlatformShowParam::getIsdeleted, Constants.ZERO) |
| | | .eq(PlatformShowParam::getMemberId,loginUserInfo.getMemberId()) |
| | | ); |
| | | //妿æªé
ç½®è¯¥æ°æ® åå
¨é¨æ¾ç¤º |
| | | if(CollectionUtils.isEmpty(platformShowParamList)){ |
| | | for (Platform platform:allPlatformList) { |
| | | platform.setShowConfig(true); |
| | | } |
| | | }else{ |
| | | //æ ¹æ®é
ç½®æ¾ç¤ºæ°æ® |
| | | for (PlatformShowParam platformShowParam:platformShowParamList) { |
| | | for (Platform platform:allPlatformList) { |
| | | if(Constants.equalsInteger(platform.getId(),platformShowParam.getPlatformId())){ |
| | | platform.setShowConfig(true); |
| | | break; |
| | | } |
| | | } |
| | | } |
| | | } |
| | | } |
| | | |
| | | |
| | | |
| | | /** |
| | | * è·åæå°ä¸çä»»å¡å表 |
| | | * @param platform |
| | | * @param loginUserInfo |
| | | */ |
| | | public void getJobByPlatform(Platform platform,LoginUserInfo loginUserInfo){ |
| | | List<PlatformJob> platformJobList = platformJobJoinMapper.selectJoinList(PlatformJob.class,new MPJLambdaWrapper<PlatformJob>() |
| | | .selectAll(PlatformJob.class) |
| | | .selectAs(Platform::getName,PlatformJob::getPlatformName) |
| | | .selectAs(Platform::getWorkRate,PlatformJob::getWorkRate) |
| | | .leftJoin(Platform.class,Platform::getId,PlatformJob::getPlatformId) |
| | | .eq(PlatformJob::getPlatformId,platform.getId()) |
| | | .eq(PlatformJob::getIsdeleted,Constants.ZERO) |
| | | .eq(PlatformJob::getDrivierPhone,loginUserInfo.getMobile()) |
| | | .like(PlatformJob::getArriveDate, DateUtil.getCurrDate()) |
| | | .orderByDesc(PlatformJob::getId) |
| | | ); |
| | | for (PlatformJob platformJob:platformJobList) { |
| | | //å¤çWSMæ°é |
| | | this.getWmsJobData(platformJob); |
| | | //æ¥è¯¢åæ¹æéæ°é |
| | | this.queryWaitNum(platformJob); |
| | | } |
| | | platform.setWorkJobList(platformJobList); |
| | | } |
| | | |
| | | } |
| | |
| | | @Override |
| | | public List<PlatformReason> findList(PlatformReason platformReason) { |
| | | QueryWrapper<PlatformReason> wrapper = new QueryWrapper<>(platformReason); |
| | | wrapper.eq("isdeleted",Constants.ZERO); |
| | | return platformReasonMapper.selectList(wrapper); |
| | | } |
| | | |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.doumee.service.business.impl; |
| | | |
| | | import com.doumee.core.constants.ResponseStatus; |
| | | import com.doumee.core.exception.BusinessException; |
| | | import com.doumee.core.model.LoginUserInfo; |
| | | import com.doumee.core.model.LoginUserModel; |
| | | import com.doumee.core.model.PageData; |
| | | import com.doumee.core.model.PageWrap; |
| | | import com.doumee.core.utils.Constants; |
| | | import com.doumee.core.utils.DateUtil; |
| | | import com.doumee.core.utils.Utils; |
| | | import com.doumee.dao.business.PlatformWaterGasMapper; |
| | | import com.doumee.dao.business.model.PlatformReason; |
| | | import com.doumee.dao.business.model.PlatformWaterGas; |
| | | import com.doumee.service.business.PlatformWaterGasService; |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import org.apache.commons.lang3.StringUtils; |
| | | import org.checkerframework.checker.units.qual.C; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.util.CollectionUtils; |
| | | |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * æå°_ç¨æ°´ç¨æ°ä¿¡æ¯è®°å½è¡¨Serviceå®ç° |
| | | * @author æ±è¹è¹ |
| | | * @date 2024/08/26 16:22 |
| | | */ |
| | | @Service |
| | | public class PlatformWaterGasServiceImpl implements PlatformWaterGasService { |
| | | |
| | | @Autowired |
| | | private PlatformWaterGasMapper platformWaterGasMapper; |
| | | |
| | | @Override |
| | | public Integer create(PlatformWaterGas platformWaterGas) { |
| | | if(platformWaterGas.getTimeInfo() ==null || platformWaterGas.getNum()==null |
| | | ||(Constants.equalsInteger(platformWaterGas.getType(),Constants.TWO) && StringUtils.isBlank(platformWaterGas.getCarCode()))){ |
| | | throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"对ä¸èµ·ï¼è¯¥å¹´ææ°æ®å·²åå¨ï¼è¯·å¿éæ°å½å
¥ï¼å¯ä»¥å°è¯æç´¢åè¿è¡æ°æ®ä¿®æ¹ï¼"); |
| | | } |
| | | if( platformWaterGasMapper.selectCount(new QueryWrapper<PlatformWaterGas>().lambda() |
| | | .eq(PlatformWaterGas::getIsdeleted, Constants.ZERO) |
| | | .apply("to_days(time_info) = to_days('"+ DateUtil.getPlusTime2(platformWaterGas.getTimeInfo()) +"')") |
| | | .eq(Constants.equalsInteger(platformWaterGas.getType(),Constants.TWO),PlatformWaterGas::getCarCode,platformWaterGas.getCarCode()))>0){ |
| | | throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"对ä¸èµ·ï¼è¯¥å¹´ææ°æ®å·²åå¨ï¼è¯·å¿éæ°å½å
¥ï¼å¯ä»¥å°è¯æç´¢åè¿è¡æ°æ®ä¿®æ¹ï¼"); |
| | | } |
| | | platformWaterGas.setIsdeleted(Constants.ZERO); |
| | | platformWaterGas.setType(Constants.formatIntegerNum(platformWaterGas.getType())); |
| | | platformWaterGas.setCreator(platformWaterGas.getLoginUserInfo().getId()); |
| | | platformWaterGas.setCreateDate(new Date()); |
| | | platformWaterGas.setEditDate(platformWaterGas.getCreateDate()); |
| | | platformWaterGas.setEditor(platformWaterGas.getCreator()); |
| | | platformWaterGasMapper.insert(platformWaterGas); |
| | | return platformWaterGas.getId(); |
| | | } |
| | | |
| | | @Override |
| | | public void deleteById(Integer id) { |
| | | |
| | | platformWaterGasMapper.deleteById(id); |
| | | } |
| | | @Override |
| | | public void deleteById(Integer id, LoginUserInfo model) { |
| | | PlatformWaterGas param = new PlatformWaterGas(); |
| | | param.setId(id); |
| | | param.setIsdeleted(Constants.ONE); |
| | | param.setEditor(model.getId()); |
| | | param.setEditDate(new Date()); |
| | | platformWaterGasMapper.updateById(param); |
| | | } |
| | | |
| | | @Override |
| | | public void delete(PlatformWaterGas platformWaterGas) { |
| | | UpdateWrapper<PlatformWaterGas> deleteWrapper = new UpdateWrapper<>(platformWaterGas); |
| | | platformWaterGasMapper.delete(deleteWrapper); |
| | | } |
| | | |
| | | @Override |
| | | public void deleteByIdInBatch(List<Integer> ids) { |
| | | if (CollectionUtils.isEmpty(ids)) { |
| | | return; |
| | | } |
| | | platformWaterGasMapper.deleteBatchIds(ids); |
| | | } |
| | | @Override |
| | | public void deleteByIdInBatch(List<Integer> ids, LoginUserInfo model) { |
| | | if (CollectionUtils.isEmpty(ids)) { |
| | | return; |
| | | } |
| | | for(Integer id : ids){ |
| | | deleteById(id,model); |
| | | } |
| | | } |
| | | |
| | | @Override |
| | | public void updateById(PlatformWaterGas platformWaterGas) { |
| | | if(platformWaterGas.getTimeInfo() ==null |
| | | || platformWaterGas.getId()==null |
| | | || platformWaterGas.getNum()==null |
| | | ||(Constants.equalsInteger(platformWaterGas.getType(),Constants.TWO) && StringUtils.isBlank(platformWaterGas.getCarCode()))){ |
| | | throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"对ä¸èµ·ï¼è¯¥å¹´ææ°æ®å·²åå¨ï¼è¯·å¿éæ°å½å
¥ï¼å¯ä»¥å°è¯æç´¢åè¿è¡æ°æ®ä¿®æ¹ï¼"); |
| | | } |
| | | if( platformWaterGasMapper.selectCount(new QueryWrapper<PlatformWaterGas>().lambda() |
| | | .eq(PlatformWaterGas::getIsdeleted, Constants.ZERO) |
| | | .ne(PlatformWaterGas::getId,platformWaterGas.getId()) |
| | | .apply("to_days(time_info) = to_days('"+ DateUtil.getPlusTime2(platformWaterGas.getTimeInfo()) +"')") |
| | | .eq(Constants.equalsInteger(platformWaterGas.getType(),Constants.TWO),PlatformWaterGas::getCarCode,platformWaterGas.getCarCode()))>0){ |
| | | throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"对ä¸èµ·ï¼è¯¥å¹´ææ°æ®å·²åå¨ï¼è¯·å¿éæ°å½å
¥ï¼å¯ä»¥å°è¯æç´¢åè¿è¡æ°æ®ä¿®æ¹ï¼"); |
| | | } |
| | | |
| | | platformWaterGas.setEditDate(new Date()); |
| | | platformWaterGas.setEditor(platformWaterGas.getLoginUserInfo().getId()); |
| | | platformWaterGasMapper.updateById(platformWaterGas); |
| | | } |
| | | |
| | | @Override |
| | | public void updateByIdInBatch(List<PlatformWaterGas> platformWaterGass) { |
| | | if (CollectionUtils.isEmpty(platformWaterGass)) { |
| | | return; |
| | | } |
| | | for (PlatformWaterGas platformWaterGas: platformWaterGass) { |
| | | this.updateById(platformWaterGas); |
| | | } |
| | | } |
| | | |
| | | @Override |
| | | public PlatformWaterGas findById(Integer id) { |
| | | return platformWaterGasMapper.selectById(id); |
| | | } |
| | | |
| | | @Override |
| | | public PlatformWaterGas findOne(PlatformWaterGas platformWaterGas) { |
| | | QueryWrapper<PlatformWaterGas> wrapper = new QueryWrapper<>(platformWaterGas); |
| | | return platformWaterGasMapper.selectOne(wrapper); |
| | | } |
| | | |
| | | @Override |
| | | public List<PlatformWaterGas> findList(PlatformWaterGas platformWaterGas) { |
| | | QueryWrapper<PlatformWaterGas> wrapper = new QueryWrapper<>(platformWaterGas); |
| | | return platformWaterGasMapper.selectList(wrapper); |
| | | } |
| | | |
| | | @Override |
| | | public PageData<PlatformWaterGas> findPage(PageWrap<PlatformWaterGas> pageWrap) { |
| | | IPage<PlatformWaterGas> page = new Page<>(pageWrap.getPage(), pageWrap.getCapacity()); |
| | | QueryWrapper<PlatformWaterGas> queryWrapper = new QueryWrapper<>(); |
| | | Utils.MP.blankToNull(pageWrap.getModel()); |
| | | if (pageWrap.getModel().getId() != null) { |
| | | queryWrapper.lambda().eq(PlatformWaterGas::getId, pageWrap.getModel().getId()); |
| | | } |
| | | if (pageWrap.getModel().getCreator() != null) { |
| | | queryWrapper.lambda().eq(PlatformWaterGas::getCreator, pageWrap.getModel().getCreator()); |
| | | } |
| | | if (pageWrap.getModel().getCreateDate() != null) { |
| | | queryWrapper.lambda().ge(PlatformWaterGas::getCreateDate, Utils.Date.getStart(pageWrap.getModel().getCreateDate())); |
| | | queryWrapper.lambda().le(PlatformWaterGas::getCreateDate, Utils.Date.getEnd(pageWrap.getModel().getCreateDate())); |
| | | } |
| | | if (pageWrap.getModel().getEditor() != null) { |
| | | queryWrapper.lambda().eq(PlatformWaterGas::getEditor, pageWrap.getModel().getEditor()); |
| | | } |
| | | if (pageWrap.getModel().getEditDate() != null) { |
| | | queryWrapper.lambda().ge(PlatformWaterGas::getEditDate, Utils.Date.getStart(pageWrap.getModel().getEditDate())); |
| | | queryWrapper.lambda().le(PlatformWaterGas::getEditDate, Utils.Date.getEnd(pageWrap.getModel().getEditDate())); |
| | | } |
| | | if (pageWrap.getModel().getIsdeleted() != null) { |
| | | queryWrapper.lambda().eq(PlatformWaterGas::getIsdeleted, pageWrap.getModel().getIsdeleted()); |
| | | } |
| | | if (pageWrap.getModel().getRemark() != null) { |
| | | queryWrapper.lambda().eq(PlatformWaterGas::getRemark, pageWrap.getModel().getRemark()); |
| | | } |
| | | if (pageWrap.getModel().getTimeInfo() != null) { |
| | | queryWrapper.lambda().ge(PlatformWaterGas::getTimeInfo, Utils.Date.getStart(pageWrap.getModel().getTimeInfo())); |
| | | queryWrapper.lambda().le(PlatformWaterGas::getTimeInfo, Utils.Date.getEnd(pageWrap.getModel().getTimeInfo())); |
| | | } |
| | | if (pageWrap.getModel().getSortnum() != null) { |
| | | queryWrapper.lambda().eq(PlatformWaterGas::getSortnum, pageWrap.getModel().getSortnum()); |
| | | } |
| | | if (pageWrap.getModel().getType() != null) { |
| | | queryWrapper.lambda().eq(PlatformWaterGas::getType, pageWrap.getModel().getType()); |
| | | } |
| | | if (pageWrap.getModel().getNum() != null) { |
| | | queryWrapper.lambda().eq(PlatformWaterGas::getNum, pageWrap.getModel().getNum()); |
| | | } |
| | | if (pageWrap.getModel().getContent() != null) { |
| | | queryWrapper.lambda().eq(PlatformWaterGas::getContent, pageWrap.getModel().getContent()); |
| | | } |
| | | if (pageWrap.getModel().getCarCode() != null) { |
| | | queryWrapper.lambda().like(PlatformWaterGas::getCarCode, pageWrap.getModel().getCarCode()); |
| | | } |
| | | if (pageWrap.getModel().getStartTime() != null) { |
| | | queryWrapper.lambda().ge(PlatformWaterGas::getTimeInfo, pageWrap.getModel().getStartTime()); |
| | | } |
| | | if (pageWrap.getModel().getEndTime() != null) { |
| | | queryWrapper.lambda().le(PlatformWaterGas::getTimeInfo, pageWrap.getModel().getEndTime()); |
| | | } |
| | | queryWrapper.lambda().orderByDesc(PlatformWaterGas::getTimeInfo ,PlatformWaterGas::getCarCode); |
| | | return PageData.from(platformWaterGasMapper.selectPage(page, queryWrapper)); |
| | | } |
| | | |
| | | @Override |
| | | public long count(PlatformWaterGas platformWaterGas) { |
| | | QueryWrapper<PlatformWaterGas> wrapper = new QueryWrapper<>(platformWaterGas); |
| | | return platformWaterGasMapper.selectCount(wrapper); |
| | | } |
| | | } |
| | |
| | | QueryWrapper<VisitReason> wrapper = new QueryWrapper<>(visitReason); |
| | | return visitReasonMapper.selectCount(wrapper); |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | } |
| | |
| | | import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.doumee.service.business.impl.hksync.HkSyncVisitServiceImpl; |
| | | import com.github.xiaoymin.knife4j.core.util.CollectionUtils; |
| | | import com.github.yulichang.wrapper.MPJLambdaWrapper; |
| | | import org.apache.commons.lang3.StringUtils; |
| | |
| | | .eq(Retention::getType,Constants.memberType.visitor) |
| | | .eq(Retention::getMemberId,visits.getMemberId())); |
| | | } |
| | | @Override |
| | | public void visitResend(Integer visitId) { |
| | | MPJLambdaWrapper<Visits> queryWrapper = new MPJLambdaWrapper<>(); |
| | | queryWrapper.selectAll(Visits.class); |
| | | queryWrapper.selectAs(Member::getName,Visits::getReceptMemberName) |
| | | .selectAs(Member::getHkId,Visits::getReceptMemberHkId) |
| | | .leftJoin(Member.class,Member::getId,Visits::getReceptMemberId) |
| | | .eq(Visits::getId,visitId)//æªåæ¥å°æµ·åº· |
| | | .last("limit 1"); |
| | | Visits visits = visitsMapper.selectJoinOne(Visits.class,queryWrapper); |
| | | if(Objects.isNull(visits)){ |
| | | throw new BusinessException(ResponseStatus.DATA_EMPTY); |
| | | } |
| | | if(!visits.getStatus().equals(Constants.VisitStatus.xfFail)){ |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"访客记å½ç¶æé误ï¼è¯·å·æ°éè¯"); |
| | | } |
| | | List<DeviceRole> roleList = deviceRoleMapper.selectList(new QueryWrapper<DeviceRole>().lambda() |
| | | .eq(DeviceRole::getType, Constants.ONE)); |
| | | String path = systemDictDataBiz.queryByCode(Constants.FTP,Constants.FTP_RESOURCE_PATH).getCode() |
| | | +systemDictDataBiz.queryByCode(Constants.FTP,Constants.MEMBER_IMG).getCode(); |
| | | |
| | | HkSyncVisitServiceImpl.getUpdateModelByResponseIccm(visits,new Date(),roleList,path); |
| | | if(Constants.equalsInteger(visits.getStatus(),Constants.VisitStatus.xfSuccess)){ |
| | | //妿ä¸åæåï¼ |
| | | visitsMapper.updateById(visits); |
| | | if(Objects.isNull(visits.getParentId())){ |
| | | wxPlatNotice.sendVisitAuditTemplateNotice(visits, |
| | | systemDictDataBiz.queryByCode(Constants.WX_PLATFORM,Constants.WX_PLATFORM_PREFIX).getCode(), |
| | | systemDictDataBiz.queryByCode(Constants.WX_PLATFORM,Constants.WX_PLATFORM_AUDIT_VISIT).getCode()); |
| | | } |
| | | }else{ |
| | | throw new BusinessException(ResponseStatus.SERVER_ERROR.getCode(),"éæ°ä¸åä¼å¤±è´¥ï¼"); |
| | | } |
| | | } |
| | | |
| | | |
| | | @Override |
| | |
| | | String st = result.getData().getST(); |
| | | try { |
| | | String serviceUrl = systemDictDataBiz.queryByCode(Constants.HK_PARAM,Constants.HK_NGINX_URL).getCode() |
| | | +(HKConstants.InterfacePath.tokenLoginUrl.replace("${st}", st).replace("${service}", URLEncoder.encode(url, "UTF-8"))); |
| | | +(HKConstants.InterfacePath.tokenLoginUrl[0].replace("${st}", st).replace("${service}", URLEncoder.encode(url, "UTF-8"))); |
| | | // redisTemplate.opsForValue().set(Constants.REDIS_HK_TOKEN_KEY+param.getUsername()+param.getLabel(),serviceUrl,1, TimeUnit.HOURS); |
| | | return serviceUrl; |
| | | }catch (Exception e){ |
| | |
| | | c.setHkStatus(Constants.ONE); |
| | | c.setHkDate(date); |
| | | } |
| | | private void getUpdateModelByResponseIccm( Visits c,Date date, List<DeviceRole> roleList,String path ) { |
| | | public static void getUpdateModelByResponseIccm( Visits c,Date date, List<DeviceRole> roleList,String path ) { |
| | | String code = null; |
| | | String id = null; |
| | | String qrcode = null; |
| | |
| | | request.setVisitorPermissionSet(getVisitPermissonRequest(roleList,c)); |
| | | return request; |
| | | } |
| | | private IccmAppointmentMDJRequest getHkMDJRequestParamIccm(Visits c,List<DeviceRole> roleList,String path) { |
| | | public static IccmAppointmentMDJRequest getHkMDJRequestParamIccm(Visits c,List<DeviceRole> roleList,String path) { |
| | | IccmAppointmentMDJRequest request = new IccmAppointmentMDJRequest(); |
| | | IccmAppointmentVistorRequest info =getRequestInfoByVisitIccm(c,path); |
| | | if(info == null ){ |
| | |
| | | request.setVisitStartTime(DateUtil.getISO8601Timestamp2(c.getStarttime())); |
| | | request.setVisitEndTime(DateUtil.getISO8601Timestamp2(c.getEndtime())); |
| | | request.setReceptionistId(c.getReceptMemberHkId());//被访人海康ç¼ç |
| | | if(StringUtils.isNotBlank(c.getReason())){ |
| | | /* if(StringUtils.isNotBlank(c.getReason())){ |
| | | char[] charArray = c.getReason().toCharArray(); |
| | | int length = charArray.length; |
| | | if(length>32){ |
| | |
| | | }else{ |
| | | request.setVisitPurpose(c.getReason()); |
| | | } |
| | | } |
| | | }*/ |
| | | request.setVisitorInfo(info); |
| | | request.setVisitorPermissionSet(getVisitPermissonRequestIccm(roleList,c)); |
| | | return request; |
| | |
| | | } |
| | | return p; |
| | | } |
| | | private IccmPermissionSetRequest getVisitPermissonRequestIccm(List<DeviceRole> roleList, Visits c) { |
| | | public static IccmPermissionSetRequest getVisitPermissonRequestIccm(List<DeviceRole> roleList, Visits c) { |
| | | IccmPermissionSetRequest p = new IccmPermissionSetRequest(); |
| | | //è·åæéç»éå |
| | | String[] roles = getHkRoles(c.getDoors(),roleList); |
| | |
| | | request.setVisitorInfoList(infolist); |
| | | return request; |
| | | } |
| | | private IccmAppointmentRequest getHkRequestParaIccm(Visits c,List<DeviceRole> roleList,String path ) { |
| | | public static IccmAppointmentRequest getHkRequestParaIccm(Visits c,List<DeviceRole> roleList,String path ) { |
| | | IccmAppointmentRequest request = new IccmAppointmentRequest(); |
| | | //ç³è¯·äººä¿¡æ¯ |
| | | IccmAppointmentVistorRequest info =getRequestInfoByVisitIccm(c,path); |
| | |
| | | //人è¸ä¸ºç©ºï¼ä¸è½è¿è¡æ¨é |
| | | return null; |
| | | } |
| | | request.setVisitStartTime(DateUtil.getISO8601Timestamp(c.getStarttime())); |
| | | request.setVisitEndTime(DateUtil.getISO8601Timestamp(c.getEndtime())); |
| | | request.setVisitStartTime(DateUtil.getISO8601Timestamp2(c.getStarttime())); |
| | | request.setVisitEndTime(DateUtil.getISO8601Timestamp2(c.getEndtime())); |
| | | request.setReceptionistId(c.getReceptMemberHkId());//被访人海康ç¼ç |
| | | |
| | | if(StringUtils.isNotBlank(c.getReason())){ |
| | | /* if(StringUtils.isNotBlank(c.getReason())){ |
| | | char[] charArray = c.getReason().toCharArray(); |
| | | int length = charArray.length; |
| | | if(length>32){ |
| | |
| | | }else{ |
| | | request.setVisitPurpose(c.getReason()); |
| | | } |
| | | } |
| | | }*/ |
| | | //è·åæéç»éå |
| | | request.setVisitorPermissionSet(getVisitPermissonRequestIccm(roleList,c)); |
| | | List<IccmAppointmentVistorRequest> infolist = new ArrayList<>(); |
| | |
| | | |
| | | return info; |
| | | } |
| | | private IccmAppointmentVistorRequest getRequestInfoByVisitIccm(Visits c,String path) { |
| | | public static IccmAppointmentVistorRequest getRequestInfoByVisitIccm(Visits c,String path) { |
| | | IccmAppointmentVistorRequest info = new IccmAppointmentVistorRequest(); |
| | | //äººè¸æ°æ® |
| | | if(StringUtils.isBlank(c.getName()) |
| | |
| | | return info; |
| | | } |
| | | |
| | | private String[] getHkRoles(String doors, List<DeviceRole> roleList) { |
| | | public static String[] getHkRoles(String doors, List<DeviceRole> roleList) { |
| | | if(StringUtils.isBlank(doors) || roleList.size()==0|| roleList.size()==0){ |
| | | return null; |
| | | } |