Commit e0fb6fa7 authored by xiaosl's avatar xiaosl

Merge branch 'base-modify' of http://113.105.137.151:22280/youjj/cloud-platform-ui into base-modify

Conflicts:
	config/dev.env.js
	src/views/vehicle/vehicleInfo/index.vue
parents 4a7325f2 4ae432b1
module.exports = { module.exports = {
NODE_ENV: '"development"', NODE_ENV: '"development"',
<<<<<<< HEAD
<<<<<<< HEAD <<<<<<< HEAD
BASE_API:'"https://xxtest.upyuns.com"',//'"https://dev.dfangche.com"',//'"https://xxfcmgmt.upyuns.com"(正)',//http://10.1.37.192:9527(何), //https://xxtest.upyuns.com(测),10.1.37.246:9527(韩), 10.1.37.244(李斌)10.1.37.248:8765(小威) BASE_API:'"https://xxtest.upyuns.com"',//'"https://dev.dfangche.com"',//'"https://xxfcmgmt.upyuns.com"(正)',//http://10.1.37.192:9527(何), //https://xxtest.upyuns.com(测),10.1.37.246:9527(韩), 10.1.37.244(李斌)10.1.37.248:8765(小威)
======= =======
BASE_API:'"https://xxtest.upyuns.com"',//'"https://xxtest.upyuns.com"',//'"https://dev.dfangche.com"',//'"https://xxfcmgmt.upyuns.com"(正)',//http://10.1.37.192:9527(何), //https://xxtest.upyuns.com(测),10.1.37.246:9527(韩), 10.1.37.244(李斌)10.1.37.248:8765(小威) BASE_API:'"https://xxtest.upyuns.com"',//'"https://xxtest.upyuns.com"',//'"https://dev.dfangche.com"',//'"https://xxfcmgmt.upyuns.com"(正)',//http://10.1.37.192:9527(何), //https://xxtest.upyuns.com(测),10.1.37.246:9527(韩), 10.1.37.244(李斌)10.1.37.248:8765(小威)
>>>>>>> ed66af1f93f55e2551b0b09c15e1697c72ecb84b >>>>>>> ed66af1f93f55e2551b0b09c15e1697c72ecb84b
=======
BASE_API:'"https://xxtest.upyuns.com"',//'"https://xxtest.upyuns.com"',//'"https://xxtest.upyuns.com"',//'"https://dev.dfangche.com"',//'"https://xxfcmgmt.upyuns.com"(正)',//http://10.1.37.192:9527(何), //https://xxtest.upyuns.com(测),10.1.37.246:9527(韩), 10.1.37.244(李斌)10.1.37.248:8765(小威)
>>>>>>> 4ae432b1473866a6dc59f10c1ec4b5c66a9ad5cc
APP_ORIGIN: '"https://wallstreetcn.com"' APP_ORIGIN: '"https://wallstreetcn.com"'
} }
...@@ -11264,6 +11264,22 @@ ...@@ -11264,6 +11264,22 @@
"resolved": "https://registry.npm.taobao.org/uuid/download/uuid-3.3.2.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fuuid%2Fdownload%2Fuuid-3.3.2.tgz", "resolved": "https://registry.npm.taobao.org/uuid/download/uuid-3.3.2.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fuuid%2Fdownload%2Fuuid-3.3.2.tgz",
"integrity": "sha1-G0r0lV6zB3xQHCOHL8ZROBFYcTE=" "integrity": "sha1-G0r0lV6zB3xQHCOHL8ZROBFYcTE="
}, },
"v-viewer": {
"version": "1.4.2",
"resolved": "https://registry.npmjs.org/v-viewer/-/v-viewer-1.4.2.tgz",
"integrity": "sha512-WEslW+dKPHg10f9jl1v0ilH0uk4ZFOz4vUp4wJjomwl+VQEnsWLjSzHCeFoayxjE9KyZspVu9lYLNxk+o3xzkw==",
"requires": {
"throttle-debounce": "^2.0.1",
"viewerjs": "^1.3.2"
},
"dependencies": {
"throttle-debounce": {
"version": "2.1.0",
"resolved": "https://registry.npmjs.org/throttle-debounce/-/throttle-debounce-2.1.0.tgz",
"integrity": "sha512-AOvyNahXQuU7NN+VVvOOX+uW6FPaWdAOdRP5HfwYxAfCzXTFKRMoIMk+n+po318+ktcChx+F1Dd91G3YHeMKyg=="
}
}
},
"validate-npm-package-license": { "validate-npm-package-license": {
"version": "3.0.1", "version": "3.0.1",
"resolved": "https://registry.npmjs.org/validate-npm-package-license/-/validate-npm-package-license-3.0.1.tgz", "resolved": "https://registry.npmjs.org/validate-npm-package-license/-/validate-npm-package-license-3.0.1.tgz",
...@@ -11295,6 +11311,11 @@ ...@@ -11295,6 +11311,11 @@
"extsprintf": "^1.2.0" "extsprintf": "^1.2.0"
} }
}, },
"viewerjs": {
"version": "1.4.0",
"resolved": "https://registry.npmjs.org/viewerjs/-/viewerjs-1.4.0.tgz",
"integrity": "sha512-HTtR44rzdX76VrDfZGaYNciUL3EEexGX4HkvdJHP0VFSR+d2I/ZXFqdx6Q4Cc+X5VwhEf0Fx1Hi3wQy7msmKOA=="
},
"vm-browserify": { "vm-browserify": {
"version": "0.0.4", "version": "0.0.4",
"resolved": "https://registry.npmjs.org/vm-browserify/-/vm-browserify-0.0.4.tgz", "resolved": "https://registry.npmjs.org/vm-browserify/-/vm-browserify-0.0.4.tgz",
......
...@@ -31,6 +31,7 @@ ...@@ -31,6 +31,7 @@
"showdown": "1.7.1", "showdown": "1.7.1",
"simplemde": "1.11.2", "simplemde": "1.11.2",
"sortablejs": "1.5.1", "sortablejs": "1.5.1",
"v-viewer": "^1.4.2",
"vue": "2.4.2", "vue": "2.4.2",
"vue-baidu-map": "^0.21.19", "vue-baidu-map": "^0.21.19",
"vue-count-to": "1.0.5", "vue-count-to": "1.0.5",
......
...@@ -98,6 +98,17 @@ export function calculate(no, params) { ...@@ -98,6 +98,17 @@ export function calculate(no, params) {
}); });
} }
/**
* @param {Object} no
* @param {Object} params计算违约价格
*/
export function getViolatePrice(no) {
return fetch({
url: '/api/order/orderRefund/bg-stage/getViolatePrice/'+ no,
method: 'get',
});
}
//创建订单 //创建订单
export function orderStatistics(params) { export function orderStatistics(params) {
return fetch({ return fetch({
...@@ -112,7 +123,34 @@ export function downloadExcel(params) { ...@@ -112,7 +123,34 @@ export function downloadExcel(params) {
return fetch({ return fetch({
url: '/api/order/orderStatistics/excel', url: '/api/order/orderStatistics/excel',
method: 'post', method: 'post',
data:params, data: params,
responseType: 'blob'
});
}
//会员订单管理列表
export function pageList(params) {
return fetch({
url: '/api/order/orderMember/page',
method: 'post',
data: params
});
}
//会员订单管理导出
export function orderMemberExcel(params) {
return fetch({
url: '/api/order/orderMember/export',
method: 'post',
data: params,
responseType: 'blob' responseType: 'blob'
}); });
} }
//用户信息
export function user_info(id) {
return fetch({
url: '/api/admin/appUsersManage/user_info/' + id,
method: 'get'
});
}
\ No newline at end of file
...@@ -71,3 +71,21 @@ export function editObj(obj) { ...@@ -71,3 +71,21 @@ export function editObj(obj) {
params: obj params: obj
}); });
} }
// 禁止||允许提现
export function forbidden(query) {
return fetch({
url: '/api/admin/wallet/admin/forbidden',
method: 'put',
params: query
});
}
// 佣金记录
export function recordList(params) {
return fetch({
url: 'api/admin/sellingwater/admin/page',
method: 'post',
data: params
});
}
...@@ -114,3 +114,12 @@ export function checkEngineNum(engineNum, id) { ...@@ -114,3 +114,12 @@ export function checkEngineNum(engineNum, id) {
method: 'get' method: 'get'
}); });
} }
export function downloadExcel(query) {
return fetch({
url: '/vehicle/VehicleInformationDownload/excel',
method: 'get',
params: {vehiclePageQueryVoJson: query},
responseType: 'blob'
});
}
...@@ -162,3 +162,71 @@ export function upStatusChange(query) { ...@@ -162,3 +162,71 @@ export function upStatusChange(query) {
method: 'put' method: 'put'
}); });
} }
// 日历价格月份查询
export function priceList(month) {
return fetch({
url: '/vehicle/admin/vehicle_model/calendar_price/month?date=' + month,
method: 'get'
});
}
// 日历价格具体日期查询
export function dayList(day) {
return fetch({
url: '/vehicle/admin/vehicle_model/calendar_price/day?date=' + day,
method: 'get'
});
}
// 日历价格设置
export function add_edit(params) {
return fetch({
url: '/vehicle/admin/vehicle_model/calendar_price/add_edit',
method: 'post',
data: params
});
}
// 会员等级
export function levels() {
return fetch({
url: 'api/admin/member/app/unauth/levels',
method: 'get'
});
}
// 节假日设置
export function add_edit_set(params) {
return fetch({
url: '/vehicle/admin/vehicle_model/holiday_price/add_edit',
method: 'post',
data: params
});
}
// 节假日列表
export function pageList(params) {
return fetch({
url: '/vehicle/admin/vehicle_model/holiday_price/page',
method: 'post',
data: params
});
}
// 节假日删除
export function deleteList(id) {
return fetch({
url: '/vehicle/admin/vehicle_model/holiday_price/'+id,
method: 'delete'
});
}
// 通用规则设置
export function rule(query) {
return fetch({
url: 'vehicle/admin/vehicle_model/holiday_price/update',
method: 'put',
params: query
});
}
\ No newline at end of file
...@@ -64,7 +64,13 @@ import '../static/utf8-jsp/ueditor.config.js' ...@@ -64,7 +64,13 @@ import '../static/utf8-jsp/ueditor.config.js'
import '../static/utf8-jsp/ueditor.all.min.js' import '../static/utf8-jsp/ueditor.all.min.js'
import '../static/utf8-jsp/lang/zh-cn/zh-cn.js' import '../static/utf8-jsp/lang/zh-cn/zh-cn.js'
import '../static/utf8-jsp/ueditor.parse.min.js' import '../static/utf8-jsp/ueditor.parse.min.js'
import Viewer from 'v-viewer'
import 'viewerjs/dist/viewer.css'
Vue.use(Viewer, {
defaultOptions: {
zIndex: 9999
}
})
// register globally // register globally
Vue.component('multiselect', Multiselect); Vue.component('multiselect', Multiselect);
Vue.component('Sticky', Sticky); Vue.component('Sticky', Sticky);
......
...@@ -300,6 +300,12 @@ export const asyncRouterMap = [{ ...@@ -300,6 +300,12 @@ export const asyncRouterMap = [{
component: _import('vehicleType/priceList'), component: _import('vehicleType/priceList'),
name: '租车价格表', name: '租车价格表',
authority: 'priceList' authority: 'priceList'
},
{
path: 'mockSun',
component: _import('vehicleType/mockSun'),
name: '节日价格',
authority: 'mockSun'
} }
] ]
}, },
...@@ -384,7 +390,7 @@ export const asyncRouterMap = [{ ...@@ -384,7 +390,7 @@ export const asyncRouterMap = [{
component: _import('vehicle/vehicleCount/index'), component: _import('vehicle/vehicleCount/index'),
name: '车辆出行统计', name: '车辆出行统计',
authority: 'vehicleCount' authority: 'vehicleCount'
}, }
// { // {
// path: 'dispatchApply', // path: 'dispatchApply',
// component: _import('vehicle/dispatchApply/index'), // component: _import('vehicle/dispatchApply/index'),
...@@ -483,6 +489,12 @@ export const asyncRouterMap = [{ ...@@ -483,6 +489,12 @@ export const asyncRouterMap = [{
component: _import('purseManage/discountRecord'), component: _import('purseManage/discountRecord'),
name: '提现记录', name: '提现记录',
authority: 'discountRecord' authority: 'discountRecord'
},
{
path: 'commissionRecord',
component: _import('purseManage/commissionRecord'),
name: '佣金记录',
authority: 'commissionRecord'
} }
] ]
}, },
......
...@@ -85,6 +85,14 @@ const baseInfo = { ...@@ -85,6 +85,14 @@ const baseInfo = {
5: { 5: {
code: 5, code: 5,
val: '保养' val: '保养'
},
6: {
code: 6,
val: '维修中'
},
7: {
code: 7,
val: '保养中'
} }
}, },
codeAndBranchCompany: {}, codeAndBranchCompany: {},
......
This diff is collapsed.
...@@ -39,6 +39,7 @@ ...@@ -39,6 +39,7 @@
<span v-if="scope.row.channel==1">租车</span> <span v-if="scope.row.channel==1">租车</span>
<span v-if="scope.row.channel==2">旅游</span> <span v-if="scope.row.channel==2">旅游</span>
<span v-if="scope.row.channel==3">营地</span> <span v-if="scope.row.channel==3">营地</span>
<span v-if="scope.row.channel==4">会员</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="金额"> <el-table-column align="center" label="金额">
...@@ -119,6 +120,7 @@ ...@@ -119,6 +120,7 @@
<el-radio-group v-model="formdata.valid_type_name" size="medium"> <el-radio-group v-model="formdata.valid_type_name" size="medium">
<el-radio-button label="绝对时效" :disabled="formdata.valid_type_name=='相对时效'&&isUpdate"></el-radio-button> <el-radio-button label="绝对时效" :disabled="formdata.valid_type_name=='相对时效'&&isUpdate"></el-radio-button>
<el-radio-button label="相对时效" :disabled="formdata.valid_type_name=='绝对时效'&&isUpdate"></el-radio-button> <el-radio-button label="相对时效" :disabled="formdata.valid_type_name=='绝对时效'&&isUpdate"></el-radio-button>
<el-radio-button label="永久时效" :disabled="formdata.valid_type_name=='永久时效'&&isUpdate"></el-radio-button>
</el-radio-group> </el-radio-group>
<div style="display:inline-block" v-show="formdata.valid_type_name=='绝对时效'"> <div style="display:inline-block" v-show="formdata.valid_type_name=='绝对时效'">
<el-date-picker v-model="formdata.validStartTimeStr" type = "date" placeholder = "开始时间" :disabled="isUpdate" :picker-options="pickerOptionsStart"></el-date-picker> <el-date-picker v-model="formdata.validStartTimeStr" type = "date" placeholder = "开始时间" :disabled="isUpdate" :picker-options="pickerOptionsStart"></el-date-picker>
...@@ -328,6 +330,10 @@ ...@@ -328,6 +330,10 @@
{ {
id:3, id:3,
val:'营地' val:'营地'
},
{
id:4,
val:'会员'
} }
], ],
BASE_API: process.env.BASE_API, BASE_API: process.env.BASE_API,
...@@ -448,7 +454,7 @@ ...@@ -448,7 +454,7 @@
console.log(response) console.log(response)
var item = response.data; var item = response.data;
item.user_type_name = item.userType==0?'普通用户':'会员用户'; item.user_type_name = item.userType==0?'普通用户':'会员用户';
item.valid_type_name = item.validType==1?'绝对时效':'相对时效'; item.valid_type_name = item.validType==1?'绝对时效':item.validType==2?'相对时效':'永久时效';
//相对时效的时间 //相对时效的时间
if(item.validStartTime>0){ if(item.validStartTime>0){
item.validStartTimeStr = getYMD(item.validStartTime); item.validStartTimeStr = getYMD(item.validStartTime);
...@@ -517,7 +523,7 @@ ...@@ -517,7 +523,7 @@
set[formName].validate(valid => { set[formName].validate(valid => {
if (valid) { if (valid) {
that.formdata.userType = that.formdata.user_type_name=='普通用户'?0:1; that.formdata.userType = that.formdata.user_type_name=='普通用户'?0:1;
that.formdata.validType = that.formdata.valid_type_name=='绝对时效'?1:2; that.formdata.validType = that.formdata.valid_type_name=='绝对时效'?1:that.formdata.valid_type_name=='相对时效'?2:3;
if(that.formdata.valid_type_name=='绝对时效'){ if(that.formdata.valid_type_name=='绝对时效'){
that.formdata.validStartTime = new Date(this.formdata.validStartTimeStr).getTime(); that.formdata.validStartTime = new Date(this.formdata.validStartTimeStr).getTime();
that.formdata.validEndTime = new Date(this.formdata.validEndTimeStr).getTime(); that.formdata.validEndTime = new Date(this.formdata.validEndTimeStr).getTime();
...@@ -582,7 +588,7 @@ ...@@ -582,7 +588,7 @@
set[formName].validate(valid => { set[formName].validate(valid => {
if (valid) { if (valid) {
that.formdata.userType = that.formdata.user_type_name=='普通用户'?0:1; that.formdata.userType = that.formdata.user_type_name=='普通用户'?0:1;
that.formdata.validType = that.formdata.valid_type_name=='绝对时效'?1:2; that.formdata.validType = that.formdata.valid_type_name=='绝对时效'?1:that.formdata.valid_type_name=='相对时效'?2:3;
if(that.formdata.valid_type_name=='绝对时效'){ if(that.formdata.valid_type_name=='绝对时效'){
that.formdata.validStartTime = new Date(that.formdata.validStartTimeStr).getTime(); that.formdata.validStartTime = new Date(that.formdata.validStartTimeStr).getTime();
......
...@@ -65,6 +65,9 @@ ...@@ -65,6 +65,9 @@
<el-col :span="5"> <el-col :span="5">
<el-form-item label="手机号:" :prop="isHave === true ? domains.tel : ''"> <el-form-item label="手机号:" :prop="isHave === true ? domains.tel : ''">
<el-input v-model="listQuery.tel" placeholder="请输入手机号" @blur="lose"></el-input> <el-input v-model="listQuery.tel" placeholder="请输入手机号" @blur="lose"></el-input>
</el-form-item>
<el-form-item label="促成人手机号:" :prop="isHave === true ? domains.facilitatePhone : ''">
<el-input v-model="listQuery.facilitatePhone" placeholder="请输入促成人手机号"></el-input>
</el-form-item> </el-form-item>
<el-form-item label="车损免赔:" :prop="isHave === true ? domains.damageSafe : ''"> <el-form-item label="车损免赔:" :prop="isHave === true ? domains.damageSafe : ''">
<el-radio-group v-model="listQuery.damageSafe"> <el-radio-group v-model="listQuery.damageSafe">
...@@ -136,7 +139,8 @@ export default { ...@@ -136,7 +139,8 @@ export default {
modelId: "modelId", modelId: "modelId",
tel: "tel", tel: "tel",
damageSafe: "damageSafe", damageSafe: "damageSafe",
rentFreeDay: "rentFreeDay" rentFreeDay: "rentFreeDay",
facilitatePhone:'facilitatePhone'
}, },
rules: { rules: {
startCompanyId: [ startCompanyId: [
...@@ -250,7 +254,7 @@ export default { ...@@ -250,7 +254,7 @@ export default {
endCityName: this.listQuery.startCityName, //还车城市名称 endCityName: this.listQuery.startCityName, //还车城市名称
endCompanyId: this.listQuery.endCompanyIds, //还车公司id endCompanyId: this.listQuery.endCompanyIds, //还车公司id
endTime: this.listQuery.time[1].getTime(), //结束时间 endTime: this.listQuery.time[1].getTime(), //结束时间
facilitatePhone:this.listQuery.facilitatePhone,//促成人手机号
modelId: this.listQuery.modelId, //车型 modelId: this.listQuery.modelId, //车型
startAddr: this.listQuery.endEndAddr, //取车地点 startAddr: this.listQuery.endEndAddr, //取车地点
startCity: this.listQuery.endAddrCity, //取车城市编号 startCity: this.listQuery.endAddrCity, //取车城市编号
......
This diff is collapsed.
...@@ -136,12 +136,14 @@ export default { ...@@ -136,12 +136,14 @@ export default {
!!this.listQuery.time[1] !!this.listQuery.time[1]
? (this.listQuery.endTime = this.listQuery.time[1].getTime()) ? (this.listQuery.endTime = this.listQuery.time[1].getTime())
: (this.listQuery.endTime = null) : (this.listQuery.endTime = null)
this.listQuery.page = 1
this.getList() this.getList()
}, },
//统计方式筛选 //统计方式筛选
changeWay(val) { changeWay(val) {
this.isactive = val.label this.isactive = val.label
this.listQuery.type = val.id this.listQuery.type = val.id
this.listQuery.page = 1
this.getList() this.getList()
}, },
//导出 //导出
...@@ -203,7 +205,7 @@ export default { ...@@ -203,7 +205,7 @@ export default {
} }
} }
}) })
this.total = data.data.total; this.total = data.data.total
this.list = data.data.list this.list = data.data.list
} }
setTimeout(() => { setTimeout(() => {
......
...@@ -28,7 +28,8 @@ ...@@ -28,7 +28,8 @@
<el-row> <el-row>
<el-col :span="24"> <el-col :span="24">
<el-form-item label="用户ID/实名"> <el-form-item label="用户ID/实名">
<span>{{row.userId}}</span>/<span>{{row.username}}</span> <span>{{row.userId}}</span>/
<span>{{row.username}}</span>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
...@@ -88,27 +89,18 @@ ...@@ -88,27 +89,18 @@
</el-dialog> </el-dialog>
</template> </template>
<script> <script>
import { import { page, saveOrderViolation } from 'api/order/rentVehicle'
page, import { mapGetters } from 'vuex'
saveOrderViolation import { formatDate } from '../../../utils/dateFormattor'
} from 'api/order/rentVehicle'; import { getToken } from '../../../utils/auth'
import {mapGetters} from 'vuex'; import { getOneIllegalRow } from 'api/order/rentVehicle'
import { import ElRow from 'element-ui/packages/row/src/row'
formatDate import ElInput from '../../../../node_modules/element-ui/packages/input/src/input.vue'
} from '../../../utils/dateFormattor'; import ElCol from 'element-ui/packages/col/src/col'
import { import ElFormItem from '../../../../node_modules/element-ui/packages/form/src/form-item.vue'
getToken import ElForm from '../../../../node_modules/element-ui/packages/form/src/form.vue'
} from '../../../utils/auth'; export default {
import { props: ['row'],
getOneIllegalRow
} from 'api/order/rentVehicle';
import ElRow from "element-ui/packages/row/src/row";
import ElInput from "../../../../node_modules/element-ui/packages/input/src/input.vue";
import ElCol from "element-ui/packages/col/src/col";
import ElFormItem from "../../../../node_modules/element-ui/packages/form/src/form-item.vue";
import ElForm from "../../../../node_modules/element-ui/packages/form/src/form.vue";
export default {
props: ["row"],
name: 'illegalDialog', name: 'illegalDialog',
components: { components: {
ElForm, ElForm,
...@@ -120,30 +112,27 @@ ...@@ -120,30 +112,27 @@
data() { data() {
return { return {
isVisible: false, isVisible: false,
tableData:[], tableData: []
} }
}, },
created() { created() {
console.log(JSON.stringify(this.row)) console.log(JSON.stringify(this.row))
}, },
watch: { watch: {
isVisible(newValue, oldValue){ isVisible(newValue, oldValue) {
if(!newValue){ if (!newValue) {
this.$emit('detailEvent', false); this.$emit('detailEvent', false)
}
} }
},
}, },
mounted() { mounted() {
let that = this; let that = this
this.isVisible = true; this.isVisible = true
}, },
computed: { computed: {
...mapGetters([ ...mapGetters(['elements']),
'elements',
]),
getHeaderWithToken() { getHeaderWithToken() {
return {Authorization: getToken()}; return { Authorization: getToken() }
} }
}, },
methods: { methods: {
...@@ -151,10 +140,10 @@ ...@@ -151,10 +140,10 @@
* 弹框-取消 * 弹框-取消
* */ * */
cancel() { cancel() {
this.$emit('detailEvent', false); this.$emit('detailEvent', false)
}, },
sure:function(){ sure: function() {
this.$emit('detailEvent', false); this.$emit('detailEvent', false)
}, },
/** /**
* 格式化时间 * 格式化时间
...@@ -162,14 +151,14 @@ ...@@ -162,14 +151,14 @@
* @returns {*} * @returns {*}
*/ */
dateFormat(timestamp) { dateFormat(timestamp) {
let date = new Date(timestamp);//时间戳为10位需*1000,时间戳为13位的话不需乘1000 let date = new Date(timestamp) //时间戳为10位需*1000,时间戳为13位的话不需乘1000
return formatDate(date, 'yyyy-MM-dd hh:mm'); return formatDate(date, 'yyyy-MM-dd hh:mm')
},
} }
} }
}
</script> </script>
<style> <style>
.el-form-item__content{ .el-form-item__content {
display: inline-block; display: inline-block;
} }
</style> </style>
This diff is collapsed.
...@@ -108,9 +108,15 @@ ...@@ -108,9 +108,15 @@
<span v-if="scope.row.status == '6'">已完成</span> <span v-if="scope.row.status == '6'">已完成</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column width="110" align="center" label="订单详情" fixed="right"> <el-table-column width="200" align="center" label="订单详情" fixed="right">
<template scope="scope"> <template scope="scope">
<span style="color: #13CE66;cursor: pointer;" @click="handleBuy(scope.row)">订单详情</span> <span style="color: #13CE66;cursor: pointer;" @click="handleBuy(scope.row)">订单详情</span>
<el-button
size="small"
v-if="scope.row.status == 3 || scope.row.status == 4"
class="el-button el-button--text el-button--small"
@click="handleViolatePrice(scope.row)"
>取消订单</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
...@@ -124,7 +130,25 @@ ...@@ -124,7 +130,25 @@
<tourOrderDetailModal :tourRow="tourRow" :insureDetail="insureDetail" v-if="tourDialogVisible" <tourOrderDetailModal :tourRow="tourRow" :insureDetail="insureDetail" v-if="tourDialogVisible"
:tourCostDetail="tourCostDetail" :tourCostDetail="tourCostDetail"
v-on:tourOrderDetailDialogEvent="tourOrderDetailDialogEvent"></tourOrderDetailModal> v-on:tourOrderDetailDialogEvent="tourOrderDetailDialogEvent"></tourOrderDetailModal>
<el-dialog title="取消订单" :visible.sync="showDialog">
<el-form>
<el-form-item label="违约金金额:" >
<el-input v-model="violateAmount" type="number" @blur="checkViolateAmount()" auto-complete="off"></el-input>
</el-form-item>
<el-form-item>
<span class="label-text">实际违约金是{{changeViolateAmount}}元</span>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click = "handleCancelDialog()">取 消</el-button>
<el-button type="primary" @click = "handleConfirm()">确 定</el-button>
</div>
</el-dialog>
</div> </div>
</template> </template>
<script> <script>
...@@ -133,7 +157,9 @@ ...@@ -133,7 +157,9 @@
import { import {
page, page,
getAllBranchCompany, getAllBranchCompany,
getAllBranchCompanyByZoneId getAllBranchCompanyByZoneId,
calculate,
getViolatePrice
} from 'api/order/rentVehicle'; } from 'api/order/rentVehicle';
import {mapGetters} from 'vuex'; import {mapGetters} from 'vuex';
import rsCode from '../../../utils/rsCode'; import rsCode from '../../../utils/rsCode';
...@@ -155,6 +181,11 @@ ...@@ -155,6 +181,11 @@
}, },
data() { data() {
return { return {
showDialog:false,
changeViolateAmount:null,
violateAmount: null,
row:null,
topAmount: null,
form: { form: {
couponAmount: undefined, couponAmount: undefined,
crtHost: undefined, crtHost: undefined,
...@@ -286,6 +317,36 @@ ...@@ -286,6 +317,36 @@
} }
}, },
created() { created() {
let t = this;
let query = localStorage.getItem("tourOrderInfo");
this.listQuery.no = this.$route.query.id || null
if(query !="null" && query){
let queryJson = JSON.parse(query);
if(queryJson.page){
t.listQuery.page = queryJson.page;
}
if(queryJson.limit){
t.listQuery.limit = queryJson.limit;
}
if(queryJson.no){
t.listQuery.no = queryJson.no;
}
if(queryJson.type){
t.listQuery.type = queryJson.type;
}
if(queryJson.startTime){
t.listQuery.startTime = queryJson.startTime;
}
if(queryJson.endTime){
t.listQuery.endTime = queryJson.endTime;
}
if(queryJson.status){
t.listQuery.status = queryJson.status;
}
if(queryJson.phone){
t.listQuery.phone = queryJson.phone;
}
}
this.getList(); this.getList();
this.btn_del = this.elements['branchCompany/stockApply:btn_delete']; this.btn_del = this.elements['branchCompany/stockApply:btn_delete'];
}, },
...@@ -338,6 +399,128 @@ ...@@ -338,6 +399,128 @@
this.tourRow = row; this.tourRow = row;
this.tourDialogVisible = true; this.tourDialogVisible = true;
}, },
/**
* 取消订单
*/
//取消订单
cancel(row, changeViolateAmount) {
let that = this;
if (changeViolateAmount == null || changeViolateAmount == 0) {
this.$confirm('此操作将取消该订单, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
let params = {
cancelReason: '后台取消',
appUserId: row.userId,
changeViolateAmount: null
}
calculate(row.no, params).then(data => {
if (data.status == 200) {
this.$notify({
title: '成功',
message: '取消订单成功',
type: 'success',
duration: 2000
})
this.getList()
} else {
this.$notify({
title: '失败',
message: '取消订单失败',
type: 'fail',
duration: 2000
})
}
})
})
} else {
// this.$prompt('请输入违约金', '提示', {
// confirmButtonText: '确定',
// cancelButtonText: '取消',
// inputPattern: /^[0-9]*$/,
// inputErrorMessage: '只能输入数字'
// }).then(({ value }) => {
// this.$message({
// type: 'success',
// message: '你的邮箱是: ' + value
// });
// }).catch(() => {
// this.$message({
// type: 'info',
// message: '取消输入'
// });
// });
that.showDialog = true
that.changeViolateAmount = changeViolateAmount
that.violateAmount = changeViolateAmount
that.row = row
}
},
checkViolateAmount() {
console.log(this.topAmount)
console.log(this.violateAmount)
if(this.topAmount < this.violateAmount) {
this.$notify({
title: '失败',
message: '违约金额不能大于最高限制金额' + this.topAmount,
type: 'fail',
duration: 2000
})
}
},
handleConfirm() {
let params = {
cancelReason: '后台取消',
appUserId: this.row.userId,
changeViolateAmount: this.violateAmount
}
calculate(this.row.no, params).then(data => {
if (data.status == 200) {
this.$notify({
title: '成功',
message: '取消订单成功',
type: 'success',
duration: 2000
})
this.showDialog = false
this.getList()
} else {
this.$notify({
title: '失败',
message: '取消订单失败',
type: 'fail',
duration: 2000
})
}
})
},
handleCancelDialog() {
this.showDialog = false
},
handleViolatePrice(row) {
let that = this;
let params = {
cancelReason: '后台取消',
appUserId: row.userId
}
getViolatePrice(row.no).then(data => {
if (data.status == 200) {
that.topAmount = data.data.topAmount;
that.cancel(row, data.data.cutAmount);
} else {
this.$notify({
title: '失败',
message: '获取违约金失败',
type: 'success',
duration: 2000
})
}
})
},
getProvinceRegions(item) { getProvinceRegions(item) {
this.listQuery.zoneId = item this.listQuery.zoneId = item
this.baranchQuery.zoneId = item this.baranchQuery.zoneId = item
...@@ -424,6 +607,9 @@ ...@@ -424,6 +607,9 @@
// if(this.listQuery.endTime){ // if(this.listQuery.endTime){
// this.listQuery.endTime = this.listQuery.endTime.getTime(); // this.listQuery.endTime = this.listQuery.endTime.getTime();
// } // }
if(this.listQuery){
localStorage.setItem("tourOrderInfo", JSON.stringify(this.listQuery));
}
page(this.listQuery) page(this.listQuery)
.then(response => { .then(response => {
this.list = response.data.data; this.list = response.data.data;
......
<template>
<div class="app-container calendar-list-container">
<div class="filter-container">
<el-row :gutter="20">
<el-col :span="4">
<el-input v-model="search.userName" placeholder="请输入用户姓名"></el-input>
</el-col>
<el-col :span="4">
<el-input v-model="search.phone" placeholder="请输入手机号"></el-input>
</el-col>
<el-col :span="6">
<el-date-picker v-model="time" type="datetimerange" placeholder="选择时间范围"></el-date-picker>
</el-col>
<el-col :span="4">
<el-button type="primary" @click="searchBtn">搜索</el-button>
</el-col>
</el-row>
<el-table
:data="list"
border
fit
highlight-current-row
style="width: 100%;margin-top:10px"
v-loading="loading"
>
<el-table-column align="center" label="姓名">
<template scope="scope">
<span>{{scope.row.userName}}</span>
</template>
</el-table-column>
<el-table-column align="center" label="手机号">
<template scope="scope">
<span>{{scope.row.phone}}</span>
</template>
</el-table-column>
<el-table-column align="center" label="来源">
<template scope="scope">
<span>{{scope.row.sourceName}}</span>
</template>
</el-table-column>
<el-table-column align="center" label="订单金额">
<template scope="scope">
<span>{{scope.row.price}}</span>
</template>
</el-table-column>
<el-table-column align="center" label="提成比例">
<template scope="scope">
<span>{{scope.row.extract}}</span>
</template>
</el-table-column>
<el-table-column align="center" label="金额变动">
<template scope="scope">
<span>{{scope.row.commission}}</span>
</template>
</el-table-column>
<el-table-column align="center" label="状态">
<template scope="scope">
<span>{{scope.row.waiting == 1 ? '入账' : '未入账'}}</span>
</template>
</el-table-column>
<el-table-column align="center" label="时间">
<template scope="scope">
<span>{{getLocalTime(scope.row.crtTime)}}</span>
</template>
</el-table-column>
<el-table-column align="center" label="操作" fixed="right">
<template scope="scope">
<el-button
size="small"
class="el-button el-button--text el-button--small"
@click="deposit(scope.row)"
>详情</el-button>
</template>
</el-table-column>
</el-table>
<el-pagination
@size-change="handleSizeChange"
@current-change="handleCurrentChange"
:current-page.sync="search.page"
:page-sizes="[10,20,30, 50]"
:page-size="search.limit"
layout="total, sizes, prev, pager, next, jumper"
:total="total"
style="margin-top:20px"
></el-pagination>
</div>
</div>
</template>
<script>
import { recordList } from 'api/purseManage'
export default {
created() {
this.getList()
},
data() {
return {
loading: false,
time: [],
list: [],
total: null,
search: {
page: 1,
limit: 10,
userName: null,
phone: null,
startTime: null,
endTime: null
}
}
},
methods: {
deposit(row) {
switch (row.orderType) {
case 1:
this.$router.push({
path: '/order/rentVehicleInfo',
query: {
id: row.orderNo
}
})
break
case 2:
this.$router.push({
path: '/order/tourOrderInfo',
query: {
id: row.orderNo
}
})
break
case 3:
this.$router.push({
path: '/order/memberOrderInfo',
query: {
id: row.orderNo
}
})
break
default:
break
}
},
handleSizeChange(val) {
this.search.limit = val
this.getList()
},
handleCurrentChange(val) {
this.search.page = val
this.getList()
},
getList() {
this.loading = true
this.search.startTime = new Date(this.time[0]).getTime() || null
this.search.endTime = new Date(this.time[1]).getTime() || null
recordList(this.search).then(data => {
if (data.status == 200) {
this.list = data.data.data
this.total = data.data.totalCount
}
setTimeout(() => {
this.loading = false
}, 300)
})
},
searchBtn() {
this.search.page = 1
this.getList()
},
getLocalTime(nS) {
//将时间戳(十三位时间搓,也就是带毫秒的时间搓)转换成时间格式
// d.cTime = 1539083829787
let date = new Date(nS)
let year = date.getFullYear()
let month = date.getMonth() + 1
let day = date.getDate()
let hours = date.getHours()
let minutes = date.getMinutes()
let secibds = date.getSeconds()
month = month < 10 ? '0' + month : month
day = day < 10 ? '0' + day : day
hours = hours < 10 ? '0' + hours : hours
minutes = minutes < 10 ? '0' + minutes : minutes
secibds = secibds < 10 ? '0' + secibds : secibds
date =
year +
'-' +
month +
'-' +
day +
' ' +
hours +
':' +
minutes +
':' +
secibds
return date
}
}
}
</script>
<style>
</style>
\ No newline at end of file
...@@ -3,43 +3,70 @@ ...@@ -3,43 +3,70 @@
<el-form ref="form" label-width="140px" style="margin-top: 20px;"> <el-form ref="form" label-width="140px" style="margin-top: 20px;">
<el-row v-for="(item,index) in settingList" :key="index"> <el-row v-for="(item,index) in settingList" :key="index">
<el-col :span="24" v-if="item.level==1"> <el-col :span="24" v-if="item.level==1">
<el-form-item label="总部股东分销提成"> <el-form-item label="股东分销提成">
<el-input v-model="item.extract" placeholder="请输入总部股东分销提成" type="number" v-enterNumber></el-input> <el-input
v-model="item.extract"
placeholder="请输入股东分销提成"
type="number"
v-enterNumber
style="width:200px"
></el-input>
<span style="color:#bfcbd9;">用户消费,其上线所得提成。提成为百分比,取值0到100之间,超出取值范围按0计算,无上线时无提成</span> <span style="color:#bfcbd9;">用户消费,其上线所得提成。提成为百分比,取值0到100之间,超出取值范围按0计算,无上线时无提成</span>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="24" v-if="item.level==2"> <el-col :span="24" v-if="item.level==2">
<el-form-item label="分公司股东分销提成"> <el-form-item label="合伙人分销提成">
<el-input v-model="item.extract" placeholder="请输入分公司股东分销提成" type="number" v-enterNumber></el-input> <el-input
v-model="item.extract"
placeholder="请输入合伙人分销提成"
type="number"
v-enterNumber
style="width:200px"
></el-input>
<span style="color:#bfcbd9;">用户消费,其上线所得提成。提成为百分比,取值0到100之间,超出取值范围按0计算,无上线时无提成</span> <span style="color:#bfcbd9;">用户消费,其上线所得提成。提成为百分比,取值0到100之间,超出取值范围按0计算,无上线时无提成</span>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="24" v-if="item.level==3"> <el-col :span="24" v-if="item.level==3">
<el-form-item label="合伙人分销提成"> <el-form-item label="代理人分销提成">
<el-input v-model="item.extract" placeholder="请输入合伙人分销提成" type="number" v-enterNumber></el-input> <el-input
v-model="item.extract"
placeholder="请输入代理人分销提成"
type="number"
v-enterNumber
style="width:200px"
></el-input>
<span style="color:#bfcbd9;">用户消费,其上线所得提成。提成为百分比,取值0到100之间,超出取值范围按0计算,无上线时无提成</span> <span style="color:#bfcbd9;">用户消费,其上线所得提成。提成为百分比,取值0到100之间,超出取值范围按0计算,无上线时无提成</span>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="24" v-if="item.level==4"> <el-col :span="24" v-if="item.level==4">
<el-form-item label="员工分销提成"> <el-form-item label="员工分销提成">
<el-input v-model="item.extract" placeholder="请输入员工分销提成" type="number" v-enterNumber></el-input> <el-input
<span style="color:#bfcbd9;">用户消费,其上线所得提成。提成为百分比,取值0到100之间,超出取值范围按0计算,无上线时无提成</span> v-model="item.extract"
</el-form-item> placeholder="请输入员工分销提成"
</el-col> type="number"
<el-col :span="24" v-if="item.level==5"> v-enterNumber
<el-form-item label="代理人分销提成"> style="width:200px"
<el-input v-model="item.extract" placeholder="请输入代理人分销提成" type="number" v-enterNumber></el-input> ></el-input>
<span style="color:#bfcbd9;">用户消费,其上线所得提成。提成为百分比,取值0到100之间,超出取值范围按0计算,无上线时无提成</span> <span style="color:#bfcbd9;">用户消费,其上线所得提成。提成为百分比,取值0到100之间,超出取值范围按0计算,无上线时无提成</span>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="24" v-if="item.level==0"> <el-col :span="24" v-if="item.level==0">
<el-form-item label="普通用户分销提成"> <el-form-item label="普通用户分销提成">
<el-input v-model="item.extract" placeholder="请输入普通用户分销提成" type="number" v-enterNumber></el-input> <el-input
v-model="item.extract"
placeholder="请输入普通用户分销提成"
type="number"
v-enterNumber
style="width:200px"
></el-input>
<span style="color:#bfcbd9;">用户消费,其上线所得提成。提成为百分比,取值0到100之间,超出取值范围按0计算,无上线时无提成</span> <span style="color:#bfcbd9;">用户消费,其上线所得提成。提成为百分比,取值0到100之间,超出取值范围按0计算,无上线时无提成</span>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button type="primary" @click="create()">立即提交</el-button> <el-button type="primary" @click="create()">立即提交</el-button>
...@@ -49,79 +76,69 @@ ...@@ -49,79 +76,69 @@
</template> </template>
<script> <script>
import { import { formatDate } from 'utils/dateFormattor'
formatDate
} from 'utils/dateFormattor';
import { import {
toEast8Date, toEast8Date,
deepCopyDate, deepCopyDate,
newEast8Date, newEast8Date,
convertDate2Str, convertDate2Str,
timestamp2Date timestamp2Date
} from 'utils/dateUtils'; } from 'utils/dateUtils'
import {mapGetters} from 'vuex'; import { mapGetters } from 'vuex'
import { import { getToken } from 'utils/auth'
getToken import { getrewardSetting, rewardSetting } from 'api/purseManage'
} from 'utils/auth'; import Element1 from '../admin/menu/components/element'
import { import ElRow from 'element-ui/packages/row/src/row'
getrewardSetting,rewardSetting import ElCol from 'element-ui/packages/col/src/col'
} from 'api/purseManage';
import Element1 from "../admin/menu/components/element";
import ElRow from "element-ui/packages/row/src/row";
import ElCol from "element-ui/packages/col/src/col";
export default { export default {
name: 'tourManage', name: 'tourManage',
components: { components: {
ElCol, ElCol,
ElRow, ElRow,
Element1, Element1
}, },
data() { data() {
return { return {
BASE_API: process.env.BASE_API, BASE_API: process.env.BASE_API,
showLoadingBody: false, showLoadingBody: false,
listLoading: true, listLoading: true,
form: { form: {},
},
inline: true, inline: true,
tableKey: 0, tableKey: 0,
settingList:[] settingList: []
} }
}, },
created() { created() {
this.getSetting(); this.getSetting()
}, },
computed: { computed: {
...mapGetters([ ...mapGetters(['elements'])
'elements'
])
}, },
methods: { methods: {
getSetting:function(){ getSetting: function() {
this.listLoading = true; this.listLoading = true
getrewardSetting().then(response => { getrewardSetting().then(response => {
this.settingList = response.data; this.settingList = response.data
this.listLoading = false; this.listLoading = false
}) })
}, },
create(formName) { create(formName) {
var that = this; var that = this
var arr = []; var arr = []
that.settingList.forEach(function(item){ that.settingList.forEach(function(item) {
if(item.extract==''){ if (item.extract == '') {
this.$notify({ this.$notify({
title: '警告', title: '警告',
message: '请输入'+item.name+'提成', message: '请输入' + item.name + '提成',
type: 'warning' type: 'warning'
}); })
return false; return false
} }
var obj = {} var obj = {}
obj.id = item.id; obj.id = item.id
obj.extract = item.extract obj.extract = item.extract
arr.push(obj) arr.push(obj)
}) })
...@@ -132,16 +149,16 @@ ...@@ -132,16 +149,16 @@
title: '修改成功', title: '修改成功',
message: '修改成功', message: '修改成功',
type: 'success' type: 'success'
}); })
this.getSetting(); this.getSetting()
}) })
}, },
cancel:function(formName){ cancel: function(formName) {
var that = this; var that = this
that.settingList.forEach(function(item){ that.settingList.forEach(function(item) {
item.extract = '' item.extract = ''
}) })
} }
} }
} }
</script> </script>
This diff is collapsed.
This diff is collapsed.
...@@ -4,22 +4,22 @@ ...@@ -4,22 +4,22 @@
<div class="filter-container" ref="filter-container"> <div class="filter-container" ref="filter-container">
<el-form ref="queryForm" :inline="inline" :model="listQuery" label-width="100px"> <el-form ref="queryForm" :inline="inline" :model="listQuery" label-width="100px">
<el-row> <el-row>
<el-col :span="8"> <el-col :span="5">
<el-form-item label="姓名"> <el-form-item label="姓名">
<el-input v-model="listQuery.username" placeholder="请输入姓名"></el-input> <el-input v-model="listQuery.username" placeholder="请输入姓名"></el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="5">
<el-form-item label="手机号"> <el-form-item label="手机号">
<el-input v-model.number="listQuery.phone" placeholder="请输入手机号"></el-input> <el-input v-model.number="listQuery.phone" placeholder="请输入手机号"></el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-button class="filter-item" type="primary" v-waves icon="search" @click="handleFilter">搜索</el-button> <el-button class="filter-item" type="primary" v-waves icon="search" @click="handleFilter">搜索</el-button>
<el-button class="filter-item" type="primary" v-waves icon="search" @click="clearFilter">清除搜索</el-button>
</el-row> </el-row>
</el-form> </el-form>
</div> </div>
<el-table :key='tableKey' :data="list" border fit highlight-current-row <el-table :key="tableKey" :data="list" border fit highlight-current-row style="width: 100%;">
style="width: 100%;">
<el-table-column width="150" align="center" label="姓名" type="index"> <el-table-column width="150" align="center" label="姓名" type="index">
<template scope="scope"> <template scope="scope">
<span>{{scope.row.username}}</span> <span>{{scope.row.username}}</span>
...@@ -32,81 +32,99 @@ ...@@ -32,81 +32,99 @@
</template> </template>
</el-table-column> </el-table-column>
<!-- <el-table-column width="200" align="center" label="佣金比例">
<template scope="scope">
<span>{{scope.row.commissionRate+'%'}}</span>
</template>
</el-table-column> -->
<el-table-column width="200" align="center" label="总收益"> <el-table-column width="200" align="center" label="总收益">
<template scope="scope"> <template scope="scope">
<span>{{scope.row.totalAmount}}</span> <span>{{scope.row.totalAmount}}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column width="200" align="center" label="总提现"> <el-table-column width="200" align="center" label="当前余额">
<template scope="scope"> <template scope="scope">
<span>{{scope.row.withdrawals}}</span> <span>{{scope.row.balance}}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column width="200" align="center" label="总消费">
<el-table-column align="center" label="总提现">
<template scope="scope"> <template scope="scope">
<span>{{scope.row.totalConsumption}}</span> <span>{{scope.row.withdrawals}}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column width="200" align="center" label="提现中">
<el-table-column align="center" label="提现中">
<template scope="scope"> <template scope="scope">
<span>{{scope.row.withdrawaling}}</span> <span>{{scope.row.withdrawaling}}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column width="200" align="center" label="未入账"> <el-table-column align="center" label="未入账">
<template scope="scope"> <template scope="scope">
<span>{{scope.row.unbooked}}</span> <span>{{scope.row.unbooked}}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="当前余额"> <!-- <el-table-column align="center" label="当前余额">
<template scope="scope"> <template scope="scope">
<span>{{scope.row.balance}}</span> <span>{{scope.row.balance}}</span>
</template> </template>
</el-table-column> </el-table-column> -->
<!-- <el-table-column align="center" label="操作" fixed="right">
<template scope="scope">
<el-button
size="small"
class="el-button el-button--text el-button--small"
@click="deposit(scope.row)"
>{{scope.row.isFrozen == 0 ? '禁止提现' : '允许提现'}}</el-button>
</template>
</el-table-column> -->
</el-table> </el-table>
<div v-show="!listLoading" class="pagination-container"> <div v-show="!listLoading" class="pagination-container">
<el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" <el-pagination
:current-page.sync="listQuery.page" :page-sizes="[10,20,30,40,50]" :page-size="listQuery.limit" @size-change="handleSizeChange"
layout="total, sizes, prev, pager, next, jumper" :total="total"></el-pagination> @current-change="handleCurrentChange"
:current-page.sync="listQuery.page"
:page-sizes="[10,20,30,40,50]"
:page-size="listQuery.limit"
layout="total, sizes, prev, pager, next, jumper"
:total="total"
></el-pagination>
</div> </div>
</div> </div>
</div> </div>
</template> </template>
<script> <script>
import 'static/css/uploadImg.css';// 引入图片上传组件对话框 import 'static/css/uploadImg.css' // 引入图片上传组件对话框
import { import { formatDate } from 'utils/dateFormattor'
formatDate
} from 'utils/dateFormattor';
import { import {
toEast8Date, toEast8Date,
deepCopyDate, deepCopyDate,
newEast8Date, newEast8Date,
convertDate2Str, convertDate2Str,
timestamp2Date timestamp2Date
} from 'utils/dateUtils'; } from 'utils/dateUtils'
import rsCode from '../../utils/rsCode'; import rsCode from '../../utils/rsCode'
import {mapGetters} from 'vuex'; import { mapGetters } from 'vuex'
import { import { getToken } from 'utils/auth'
getToken import { incomList, forbidden } from 'api/purseManage'
} from 'utils/auth'; import Element1 from '../admin/menu/components/element'
import { import ElRow from 'element-ui/packages/row/src/row'
incomList import ElCol from 'element-ui/packages/col/src/col'
} from 'api/purseManage';
import Element1 from "../admin/menu/components/element";
import ElRow from "element-ui/packages/row/src/row";
import ElCol from "element-ui/packages/col/src/col";
export default { export default {
name: 'tourManage', name: 'tourManage',
components: { components: {
ElCol, ElCol,
ElRow, ElRow,
Element1, Element1
}, },
data() { data() {
return { return {
...@@ -118,33 +136,57 @@ ...@@ -118,33 +136,57 @@
listQuery: { listQuery: {
page: 1, page: 1,
limit: 20, limit: 20,
phone: '',//手机号 phone: '', //手机号
username: '',//姓名 username: '' //姓名
}, },
inline: true, inline: true,
tableKey: 0 tableKey: 0
} }
}, },
created() { created() {
this.getList(); this.getList()
}, },
computed: { computed: {
...mapGetters([ ...mapGetters(['elements'])
'elements'
])
}, },
methods: { methods: {
//清除搜索
clearFilter(){
this.listQuery.username = this.listQuery.phone = null;
this.getList()
},
//提现
deposit(row) {
let titleMsg =
row.isFrozen == 0 ? '请确定设为允许提现' : '请确定设为禁止提现'
let setId = row.isFrozen == 0 ? 1 : 0
this.$confirm(titleMsg, '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
forbidden({ id: row.id, state: setId }).then(data => {
if (data.status == 200) {
this.$message.success('设置成功')
this.getList()
}
})
})
},
/** /**
* 获取旅游列表 * 获取旅游列表
* */ * */
getList() { getList() {
this.listLoading = true; this.listLoading = true
incomList(this.listQuery).then(response => { incomList(this.listQuery).then(response => {
let totalCountRs = undefined; let totalCountRs = undefined
let listRs = undefined; let listRs = undefined
if (!this.$utils.isEmpty(response.data.data) && this.$utils.isInteger(response.data.totalCount)) { if (
listRs = response.data.data; !this.$utils.isEmpty(response.data.data) &&
totalCountRs = response.data.totalCount; this.$utils.isInteger(response.data.totalCount)
) {
listRs = response.data.data
totalCountRs = response.data.totalCount
// listRs.map(function(item){ // listRs.map(function(item){
// item.visible2 = false; // item.visible2 = false;
// item.crtTimeStr = timestamp2Date(item.crtTime); // item.crtTimeStr = timestamp2Date(item.crtTime);
...@@ -153,30 +195,29 @@ ...@@ -153,30 +195,29 @@
// } // }
// }); // });
} }
this.listLoading = false; this.listLoading = false
this.list = listRs; this.list = listRs
this.total = totalCountRs; this.total = totalCountRs
}) })
}, },
handleFilter() { handleFilter() {
this.listQuery.page = 1; this.listQuery.page = 1
this.$refs.queryForm.validate(valid => { this.$refs.queryForm.validate(valid => {
if (valid) { if (valid) {
this.getList(); this.getList()
} else { } else {
return false; return false
} }
}); })
}, },
handleSizeChange(val) { handleSizeChange(val) {
this.listQuery.limit = val; this.listQuery.limit = val
this.getList(); this.getList()
}, },
handleCurrentChange(val) { handleCurrentChange(val) {
this.listQuery.page = val; this.listQuery.page = val
this.getList(); this.getList()
}
} }
} }
}
</script> </script>
...@@ -235,10 +235,14 @@ import { staffImport } from 'src/api/admin/UserMember/index' ...@@ -235,10 +235,14 @@ import { staffImport } from 'src/api/admin/UserMember/index'
import { getAll } from 'api/base_info/branch_company' import { getAll } from 'api/base_info/branch_company'
export default { export default {
created() { created() {
this.getList() let query = localStorage.getItem("employeesInput");
this.postionsFn() if(query !="null" && query){
this.getAllFn() this.listQuery = JSON.parse(query);
this.jobsFn() }
this.getList();
this.postionsFn();
this.getAllFn();
this.jobsFn();
}, },
computed: { computed: {
...mapGetters(['elements']), ...mapGetters(['elements']),
...@@ -336,8 +340,7 @@ export default { ...@@ -336,8 +340,7 @@ export default {
getAll().then(data => { getAll().then(data => {
if (data.status == 200) { if (data.status == 200) {
this.companyList = data.data; this.companyList = data.data;
this.companyList.unshift({name:'全部',id:''}) this.companyList.unshift({name:'全部',id:''});
console.log(this.companyList);
} }
}) })
...@@ -431,26 +434,41 @@ export default { ...@@ -431,26 +434,41 @@ export default {
}) })
}, },
handleSizeChange(val) { handleSizeChange(val) {
this.listQuery.limit = val this.listQuery.limit = val;
this.getList() if(this.listQuery){
localStorage.setItem("employeesInput", JSON.stringify(this.listQuery));
}
this.getList();
}, },
handleCurrentChange(val) { handleCurrentChange(val) {
this.listQuery.page = val this.listQuery.page = val;
this.getList() if(this.listQuery){
localStorage.setItem("employeesInput", JSON.stringify(this.listQuery));
}
this.getList();
}, },
//搜索 //搜索
handleFilter() { handleFilter() {
this.listQuery.page = 1;
if(this.listQuery){
localStorage.setItem("employeesInput", JSON.stringify(this.listQuery));
}
this.getList() this.getList()
}, },
//清空搜索条件 //清空搜索条件
cleaningQuery() { cleaningQuery() {
this.listQuery.page = 1 this.listQuery = {
this.listQuery.limit = 10 name: '',
this.listQuery.name = '' phone: '',
this.listQuery.phone = '' status: null,
this.listQuery.status = '' page: 1,
this.listQuery.companyId = '' limit: 10,
this.listQuery.companyName = '' companyId: '',
companyName: ''
};
if(this.listQuery){
localStorage.setItem("employeesInput", JSON.stringify(this.listQuery));
}
this.getList() this.getList()
}, },
//新增员工 //新增员工
......
...@@ -36,6 +36,7 @@ ...@@ -36,6 +36,7 @@
<el-button class="filter-item" style="margin-left: 10px;" @click="bulkUpload" <el-button class="filter-item" style="margin-left: 10px;" @click="bulkUpload"
type="primary" icon="edit" v-if="memberEnter_btn_addIn">批量导入会员 type="primary" icon="edit" v-if="memberEnter_btn_addIn">批量导入会员
</el-button> </el-button>
<el-button class="filter-item" type="primary" v-waves @click="reloadPage">重置</el-button>
</div> </div>
<el-table :key='tableKey' :data="list" v-loading.body="listLoading" border fit highlight-current-row <el-table :key='tableKey' :data="list" v-loading.body="listLoading" border fit highlight-current-row
style="width: 100%"> style="width: 100%">
...@@ -302,6 +303,11 @@ ...@@ -302,6 +303,11 @@
this.memberEnter_btn_add=this.elements['memberEnter:btn_add'];//添加一条 this.memberEnter_btn_add=this.elements['memberEnter:btn_add'];//添加一条
this.memberEnter_btn_del=this.elements['memberEnter:btn_del'];//删除 this.memberEnter_btn_del=this.elements['memberEnter:btn_del'];//删除
this.memberEnter_btn_addIn=this.elements['memberEnter:btn_addIn'];//批量上传 this.memberEnter_btn_addIn=this.elements['memberEnter:btn_addIn'];//批量上传
let query = localStorage.getItem("memberEnter");
if(query !="null" && query){
this.listQuery = JSON.parse(query);
}
this.getList(); this.getList();
this. getMembersLevel() this. getMembersLevel()
} , } ,
...@@ -441,7 +447,6 @@ ...@@ -441,7 +447,6 @@
* 获取用户列表 * 获取用户列表
*/ */
getList() { getList() {
let query = this.listQuery; let query = this.listQuery;
console.log(typeof this.listQuery.startTime); console.log(typeof this.listQuery.startTime);
if(this.listQuery.startTime && (typeof this.listQuery.startTime == "object")){ if(this.listQuery.startTime && (typeof this.listQuery.startTime == "object")){
...@@ -450,6 +455,9 @@ ...@@ -450,6 +455,9 @@
if(this.listQuery.endTime && (typeof this.listQuery.endTime == "object")){ if(this.listQuery.endTime && (typeof this.listQuery.endTime == "object")){
this.listQuery.endTime = this.listQuery.endTime.getTime(); this.listQuery.endTime = this.listQuery.endTime.getTime();
} }
if(this.listQuery){
localStorage.setItem("memberEnter", JSON.stringify(this.listQuery));
}
getMemberEntryList(query) getMemberEntryList(query)
.then(response => { .then(response => {
let totalCountRs = undefined; let totalCountRs = undefined;
...@@ -467,18 +475,41 @@ ...@@ -467,18 +475,41 @@
this.listLoading = false; this.listLoading = false;
}) })
}, },
/**
* 重置
* */
reloadPage() {
this.listQuery = {
page: 1,
limit: 20,
startTime: undefined,
username: undefined,
endTime: undefined,
};
if(this.listQuery){
localStorage.setItem("memberEnter", JSON.stringify(this.listQuery));
}
this.getList();
},
/** /**
* 搜索 * 搜索
*/ */
handleFilter() { handleFilter() {
this.listQuery.page = 1;
this.getList(); this.getList();
}, },
handleSizeChange(val) { handleSizeChange(val) {
this.listQuery.limit = val; this.listQuery.limit = val;
if(this.listQuery){
localStorage.setItem("memberEnter", JSON.stringify(this.listQuery));
}
this.getList(); this.getList();
}, },
handleCurrentChange(val) { handleCurrentChange(val) {
this.listQuery.page = val; this.listQuery.page = val;
if(this.listQuery){
localStorage.setItem("memberEnter", JSON.stringify(this.listQuery));
}
this.getList(); this.getList();
}, },
handleCreate() { handleCreate() {
......
This diff is collapsed.
This diff is collapsed.
...@@ -52,6 +52,7 @@ ...@@ -52,6 +52,7 @@
<el-button class="filter-item" type="primary" @click="downloadExcel"> <el-button class="filter-item" type="primary" @click="downloadExcel">
导出 导出
</el-button> </el-button>
<el-button class="filter-item" type="primary" v-waves @click="reloadPage">重置</el-button>
</el-row> </el-row>
</el-form> </el-form>
<el-table id = "out-table" :key='tableKey' :data="list" border fit highlight-current-row style="width: 100%"> <el-table id = "out-table" :key='tableKey' :data="list" border fit highlight-current-row style="width: 100%">
...@@ -161,18 +162,36 @@ ...@@ -161,18 +162,36 @@
} }
}, },
created() { created() {
this.handlerSearch() let query = localStorage.getItem("vehicleCount");
}, if(query !="null" && query){
computed: { this.listQuery = JSON.parse(query);
}
this.handlerSearch();
}, },
methods: { methods: {
/**
* 重置
* */
reloadPage() {
this.listQuery = {
type: null,
startTime: new Date(),
endTime:new Date()
};
if(this.listQuery){
localStorage.setItem("vehicleCount", JSON.stringify(this.listQuery));
}
this.handlerSearch();
},
handlerSearch() { handlerSearch() {
if (this.listQuery.startTime) { if (this.listQuery.startTime) {
this.listQuery.startTime = getYMD_date(new Date(this.listQuery.startTime)); this.listQuery.startTime = getYMD_date(new Date(this.listQuery.startTime));
} }
if(this.listQuery.endTime) { if(this.listQuery.endTime) {
this.listQuery.endTime = getYMD_date(new Date(this.listQuery.endTime)); this.listQuery.endTime = getYMD_date(new Date(this.listQuery.endTime));
}
if(this.listQuery){
localStorage.setItem("vehicleCount", JSON.stringify(this.listQuery));
} }
get(this.listQuery).then(response => { get(this.listQuery).then(response => {
if (response.status === 200) { if (response.status === 200) {
......
This diff is collapsed.
...@@ -31,7 +31,8 @@ ...@@ -31,7 +31,8 @@
<span>{{currentItem.ii.vehicleBookRecord.remark}}</span> <span>{{currentItem.ii.vehicleBookRecord.remark}}</span>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" v-if='currentItem.ii.vehicleBookRecord.status==2&&bookRecord_btn_unbook&&currentItem.ii.vehicleBookRecord.vehicleDepartureLogVo!=undefined' class="dialog-footer"> <!--客户租车-已审核过-取消按钮权限-未出行-->
<div slot="footer" v-if='currentItem.ii.vehicleBookRecord.status==2 && currentItem.ii.bookType==9 &&bookRecord_btn_unbook && !currentItem.ii.vehicleBookRecord.vehicleDepartureLogVo' class="dialog-footer">
<el-button @click="cancel()">取消用车</el-button> <el-button @click="cancel()">取消用车</el-button>
</div> </div>
<div slot="footer" v-if='currentItem.ii.vehicleBookRecord.status==1' class="dialog-footer"> <div slot="footer" v-if='currentItem.ii.vehicleBookRecord.status==1' class="dialog-footer">
...@@ -91,10 +92,14 @@ ...@@ -91,10 +92,14 @@
* 弹框-取消 * 弹框-取消
* */ * */
cancel() { cancel() {
console.log("展览取消用车");
var obj = { var obj = {
vehicleBookRecordId:this.currentItem.ii.vehicleBookRecord.id vehicleBookRecordId:this.currentItem.ii.vehicleBookRecord.id
} };
this.$confirm('确定取消吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
cancleBook(obj).then(response => { cancleBook(obj).then(response => {
if(response.code==1){ if(response.code==1){
this.$emit("zhanlanDialogEvent", true); this.$emit("zhanlanDialogEvent", true);
...@@ -107,6 +112,9 @@ ...@@ -107,6 +112,9 @@
}); });
} }
}); });
}).catch(() => {
console.log("cancel");
});
}, },
/** /**
* 确定用车 * 确定用车
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment