Commit 816acaac by 王志慧

commit

1 parent 26611e3d
...@@ -19,9 +19,8 @@ const finishOrderStatus = data => { ...@@ -19,9 +19,8 @@ const finishOrderStatus = data => {
data.method = 'scrm.api.shopmall.weapp.order.status.finish.nosession' data.method = 'scrm.api.shopmall.weapp.order.status.finish.nosession'
return request(data) return request(data)
} }
const orderExportApi = data => { const orderExportApi = data => {
data.method = `${defaultPath}order.export` data.method = `${defaultPath}order.noSessionExport`
return request(data) return request(data)
} }
const pictureUpload = data => { const pictureUpload = data => {
...@@ -47,4 +46,4 @@ const getCrowdfundingParams = data => { ...@@ -47,4 +46,4 @@ const getCrowdfundingParams = data => {
export default { pictureUpload, getCrowdfundingParams, orderEndExportApi, getListApi, getCountApi, getOrderDetailApi, orderExportApi, finishOrderStatus } export default { pictureUpload, getCrowdfundingParams, orderEndExportApi, getListApi, getCountApi, getOrderDetailApi, orderExportApi, finishOrderStatus }
...@@ -90,15 +90,21 @@ service.interceptors.request.use( ...@@ -90,15 +90,21 @@ service.interceptors.request.use(
} else { } else {
if (config.isPoint) { if (config.isPoint) {
config.url = baseConfig.axios2.baseURL config.url = baseConfig.axios2.baseURL
} else if(config.isCommon){ } else if (config.isCommon) {
config.url = baseConfig.common.baseURL config.url = baseConfig.common.baseURL
}else { } else {
config.url = baseConfig.axios.baseURL config.url = baseConfig.axios.baseURL
} }
} }
} else { } else {
config.url = baseConfig.axios.baseURL if (config.isPoint) {
config.url = baseConfig.axios2.baseURL
} else if (config.isCommon) {
config.url = baseConfig.common.baseURL
} else {
config.url = baseConfig.axios.baseURL
}
} }
// if (config.params && config.params.method.includes('common.uploadImg')) { // if (config.params && config.params.method.includes('common.uploadImg')) {
......
<template>
<div class="select-staff">
<d2-dialog
title="选择员工"
width="700px"
:is-visible="dialogVisible"
@confirmDialog="handleConfirm"
@closeDialog="handleClose"
>
<el-form :model="searchForm" label-width="120px" inline="true">
<el-form-item label="员工:" prop="name">
<el-input v-model="searchForm.name" placeholder="请输入员工姓名" />
</el-form-item>
<el-form-item>
<el-button size="small" type="primary" @click="getList"
>查询</el-button
>
</el-form-item>
</el-form>
<d2-table
ref="staffRef"
:hasPage="false"
:hasNum="false"
:tableData="staffList"
:tableParams="tableParams"
@refreshTable="getList"
:setTableFinishFun="setTableFinishFun"
>
<div slot="radioHtml" class="staff-table" slot-scope="scope">
<el-radio
v-model="staffUuid"
:label="scope.scope.uuid"
@click.native="handleClick(scope.scope)"
></el-radio>
</div>
</d2-table>
</d2-dialog>
</div>
</template>
<script>
export default {
name: "selectStaff",
data() {
return {
searchForm: {
name: ""
},
total: 0,
staffList: [],
heightBox: 200,
staffUuid: "",
// 搜索
searchFormData: [
{
label: "员工",
name: "name",
type: "input",
placeholder: "请输入员工名称",
width: "300px",
labelWidth: "10px"
}
],
// 表格
// getListApi: this.$apis.common.getstaffTreeListApi,
tableParams: {
listName: "staffUnitList",
// 行数据的key
// mutiSelectUniqueKey: 'staffId',
// checkSelectKey: 'staffId',
// checkSelectVal: [],
// 多选ref的名称
// mutiSelectName: 'list',
tableColumns: [
{
label: "",
prop: "",
width: 80,
addHtml: "radioHtml"
},
{
label: "序号",
prop: "idx",
width: 80
},
{
label: "员工姓名",
prop: "staffName",
formatter: (cellValue) => {
return cellValue.staffName || "-"
}
}
]
},
pageConf: {
pageSize: "pageSize",
pageNum: "pageNum",
totalCount: "count"
},
baseData: {}
}
},
props: {
dialogVisible: {
type: Boolean,
default: false
},
selectedstaffUuid: {
type: String
},
merchantId: {
type: Number,
required: true
},
orderCode: {
type: String,
required: true
}
},
mounted() {
// this.userInfo = this.$globalState.session
let clientHeight = document.documentElement.clientHeight
this.heightBox = clientHeight - 0.15 * clientHeight - 425
this.staffUuid = this.selectedstaffUuid
// this.getList()
},
methods: {
getList() {
var params = {
merchantId: this.merchantId,
// merchantId: '44209390',
...this.searchForm
}
this.$apis.common.getMerchantStaff(params).then((res) => {
console.log(res)
this.staffList = res
// this.staffList = res.staffUnitList
// this.total = res.total
// var page = this.$refs.staffRef.page
// // 添加序号
this.staffList.forEach((item, index) => {
item.idx = index + 1
})
this.$refs.staffRef.tableHeightValues = "460px"
})
},
setTableFinishFun() {
this.staffList = this.$refs.staffRef.data
//接收到的数据为空
this.$refs.staffRef.tableHeightValues = "460px"
},
handleClick(val) {
console.log(val)
// let temp = JSON.parse(JSON.stringify(val))
// delete temp.idx
// this.staffUuid = val.uuid
},
handleClose() {
// console.log('handleStoreClose')
this.$emit("handleStaffClose")
},
handleConfirm() {
if (!this.staffUuid)
return this.$message({
message: "请先选择员工",
type: "error"
})
let parmas = {
subOrderCode: this.orderCode,
staffUuid: this.staffUuid
}
this.$apis.orderManage.signerOrder(parmas).then((res) => {
console.log(res)
this.$emit("handleStaffConfirm", this.staffUuid)
})
}
}
}
</script>
<style lang="scss">
.select-staff {
.staffDailog {
width: 500px;
}
.title {
margin-bottom: 12px;
}
.customer-tag-box {
display: flex;
margin: 20px 16px;
.tag-label {
display: inline-block;
height: 30px;
line-height: 30px;
}
.input-tag-wrapper {
max-height: 75px;
overflow: auto;
position: relative;
font-size: 14px;
background-color: #fff;
background-image: none;
border-radius: 4px;
border: 1px solid #dcdfe6;
box-sizing: border-box;
color: #666;
display: inline-block;
outline: none;
padding: 5px;
flex-wrap: wrap;
transition: border-color 0.2s cubic-bezier(0.645, 0.045, 0.355, 1);
width: 648px;
display: flex;
align-items: center;
cursor: pointer;
i {
color: #75acff;
margin-right: 3px;
font-size: 14px;
}
}
}
// .customer-list {
// width: calc(100% - 280px);
// margin-right: 10px;
// }
.p-16 {
padding: 16px;
}
.staff-table .el-radio__label {
display: none;
}
}
</style>
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!