Commit c0dbf650 by 前端

Merge branch 'SAAS+V4.53.0-0528' of http://192.168.3.233:8090/saas_plus/dj-car-l…

…ife-system into SAAS+V4.53.0-0528
2 parents b6df2a27 8afdc3d0
......@@ -298,4 +298,16 @@ export function getCarBrandIds(data) {
export function getSonCarBrandIds(data) {
data.method = 'dj.api.car.series.list.by.son.car.brandIds'
return request(data, "post")
}
/** 删除平板首页配置 */
export function deleteConfig(data) {
data.method = 'dj.api.mindworkplate.pad.home.page.config.delete'
return request(data, "post")
}
/** 接待首页素材详情 */
export function getMateralDetail(data) {
data.method = 'dj.api.smartcarlife.reception.home.page.material.detail'
return request(data, "post")
}
\ No newline at end of file
......@@ -99,4 +99,10 @@ export function getOperationRecord(data) {
export function getOrderByScore(data) {
data.method = `dj.api.smartcarlife.staff.motivation.order.score`
return request(data)
}
/** 积分退款订单详情查询 */
export function getGoodsSubOrder(data) {
data.method = 'dj.api.smartcarlife.goodsOrder.goodsSubOrder.list'
return request(data)
}
\ No newline at end of file
......@@ -31,7 +31,7 @@ export const routerName = {
authId: "9140104",
parentId: "91401",
label: "标记退款",
handle: "handleRefund"
handle: "openRefundDetail"
},
{
authId: "9140102",
......
......@@ -5,8 +5,8 @@
<d2-search ref="showSearch" class="show-search" :search-form="searchForm" :label-width="'100px'"
:form-data="showFormData">
<template slot="brand">
<el-cascader ref="cascader" v-model="searchForm.brandId" filterable :options="options" :value-key="'id'" :props="cascaderProps"
clearable></el-cascader>
<el-cascader ref="cascader" v-model="searchForm.brandId" filterable :options="options" :value-key="'id'"
:props="cascaderProps" clearable></el-cascader>
</template>
</d2-search>
<div class="up-btns">
......@@ -24,11 +24,56 @@
</d2-table-header>
<d2-table ref="table" :get-list-api="getListApi" :search-form="searchFormSearch" :table-params="tableParams"
:before-search-fn="beforeSearchFn">
<div slot="brandName" slot-scope="scope">
<template v-if="scope.scope.brandName">
{{ scope.scope.brandName.split(",").length > 1 ? scope.scope.brandName.split(",")[0] + '...' :
scope.scope.brandName.split(",")[0]}}
<el-popover placement="top-start" width="200" trigger="hover">
<p v-for="(item, index) in scope.scope.brandName.split(',')" :key="index">
{{ item }}
</p>
<span class="trick-no" slot="reference" v-show="scope.scope.brandName.split(',').length > 1">({{
scope.scope.brandName.split(",").length - 1 }})</span>
<!-- <el-button slot="reference">hover 激活</el-button> -->
</el-popover>
</template>
<template v-else>-</template>
</div>
<div slot="subBrandName" slot-scope="scope">
<template v-if="scope.scope.subBrandName">
{{ scope.scope.subBrandName.split(",").length > 1 ? scope.scope.subBrandName.split(",")[0] + '...' :
scope.scope.subBrandName.split(",")[0]}}
<el-popover placement="top-start" width="200" trigger="hover">
<p v-for="(item, index) in scope.scope.subBrandName.split(',')" :key="index">
{{ item }}
</p>
<span class="trick-no" slot="reference" v-show="scope.scope.subBrandName.split(',').length > 1">({{
scope.scope.subBrandName.split(",").length - 1 }})</span>
<!-- <el-button slot="reference">hover 激活</el-button> -->
</el-popover>
</template>
<template v-else>-</template>
</div>
<div slot="merchantName" slot-scope="scope">
<template v-if="scope.scope.merchantName">
{{ scope.scope.merchantName.split(",").length > 1 ? scope.scope.merchantName.split(",")[0] + '...' :
scope.scope.merchantName.split(",")[0]}}
<el-popover placement="top-start" width="200" trigger="hover">
<p v-for="(item, index) in scope.scope.merchantName.split(',')" :key="index">
{{ item }}
</p>
<span class="trick-no" slot="reference" v-show="scope.scope.merchantName.split(',').length > 1">({{
scope.scope.merchantName.split(",").length - 1 }})</span>
<!-- <el-button slot="reference">hover 激活</el-button> -->
</el-popover>
</template>
<template v-else>-</template>
</div>
<div slot="auth-button" slot-scope="scope">
<el-button type="text" @click="handleEdit(scope.scope)">
编辑
</el-button>
<el-button type="text" @click="handleClone(scope.scope)">
<el-button type="text" @click="handleDelete(scope.scope)">
删除
</el-button>
</div>
......@@ -39,7 +84,7 @@
</template>
<script>
import { deepClone } from "@/common/util"
import { getConfigList, getCarbrandTree, getListShop4sByRef } from "@api/contentManager"
import { getConfigList, getCarbrandTree, getListShop4sByRef, deleteConfig, getMateralDetail } from "@api/contentManager"
export default {
data() {
return {
......@@ -71,62 +116,29 @@ export default {
tableColumns: [
{
label: "品牌",
prop: "merchantName"
prop: "brandName",
addHtml: "brandName"
},
{
label: "子品牌",
prop: "merchantId"
prop: "subBrandName",
addHtml: "subBrandName"
},
{
label: "关联门店",
prop: "merchantId",
addHtml: "polishContent"
prop: "merchantName",
addHtml: "merchantName"
},
{
label: "更新时间",
prop: "merchantId",
prop: "updatedDate",
},
]
},
baseData: {
shopList: [],
},
options: [{
value: 'zhinan',
label: '指南',
children: [{
value: 'shejiyuanze',
label: '设计原则',
}, {
value: 'daohang',
label: '导航'
}]
}, {
value: 'zujian',
label: '组件',
children: [{
value: 'basic',
label: 'Basic',
}, {
value: 'form',
label: 'Form',
}, {
value: 'data',
label: 'Data',
}, {
value: 'notice',
label: 'Notice',
}, {
value: 'navigation',
label: 'Navigation',
}, {
value: 'others',
label: 'Others',
}]
}, {
value: 'ziyuan',
label: '资源',
}],
options: [],
cascaderProps: { checkStrictly: true, value: 'id' }
}
},
......@@ -138,7 +150,7 @@ export default {
beforeSearchFn() {
return new Promise((resolve) => {
this.searchFormSearch = deepClone(this.searchForm)
const {brandId} = this.searchFormSearch
const { brandId } = this.searchFormSearch
if (brandId) {
this.searchFormSearch.brandId = brandId[brandId.length - 1]
}
......@@ -217,6 +229,37 @@ export default {
},
handleDialog() {
this.$router.push({ name: "addEquity" })
},
async handleEdit(row) {
const res = await getMateralDetail({id: row.id})
console.log(res)
this.$router.push({ name: "addEquity", query: {
id: row.id,
isRelMerchant: res.isRelMerchant,
materialInfoList: res.materialInfoList,
brandData: res.relBrandList,
storeData: res.relMerchantList
} })
},
handleDelete(row) {
this.$confirm("删除后相关品牌素材将从展业助手中移除", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
closeOnClickModal: false
})
.then(async() => {
const res = await deleteConfig({id: row.id})
if (res) {
this.$message.success('删除成功')
this.$refs.table.refreshTable(true, true)
}
else this.$message.error('删除失败')
})
.catch((err) => {
console.log(err)
})
}
}
}
......@@ -225,4 +268,11 @@ export default {
.m-t-40 {
margin-top: 40px;
}
.trick-no {
cursor: pointer;
font-size: 13px;
color: #2a58ad;
line-height: 20px;
}
</style>
......@@ -70,7 +70,8 @@ export default {
props: {
dialogVisible: Boolean,
formInfo: Object,
brandData: Array
brandData: Array,
levelId: Number
},
watch: {
formInfo(val) {
......@@ -99,7 +100,8 @@ export default {
seriesId: carSeries.id,
seriesName: carSeries.name,
contentPicUrl,
index
index,
levelId: this.levelId
}
this.$emit("dialogConfirm", obj)
this.formData = {
......
......@@ -1445,7 +1445,6 @@ export default {
},
beforeDestroy() {
this.$EventBus.$off("packageInfoList")
this.$EventBus.$off("shelfUpdateContractMer")
this.$EventBus.$off("shelfUpdateParMer")
this.$EventBus.$off("shelfUpdatMerchantId")
}
......
......@@ -118,12 +118,11 @@ export default {
return this.goodInfoList
},
submitParamsPackages() {
this.goodInfoList = []
this.packageInfoList = []
this.packageTabs.forEach((item, idx) => {
const info = this.$refs["packageTabRef" + idx][0].returnThisTabDate()
this.packageInfoList.push(info)
})
// console.log("this.packageInfoList", this.packageInfoList)
return this.packageInfoList
},
submit() {
......
......@@ -163,10 +163,6 @@ export default {
merchantName: merchantName
}
})
// this.$EventBus.$emit("shelfUpdateContractMer", {
// merchantId: value,
// merchantName: merchantName
// })
}
},
{
......
......@@ -541,7 +541,7 @@ export default {
},
salesProportionPercentInput(e) {
e = e.replace(/[^\d.]/g, "")
const oldValue = `${this.formData["salesProportionPercent"]}`
const oldValue = `${this.formData["oldesalesProportionPercent"]}`
this.$set(
this.formData,
"salesProportionPercent",
......
......@@ -509,7 +509,7 @@ export default {
}),
salesProportionPercentInput(e) {
e = e.replace(/[^\d.]/g, "")
const oldValue = `${this.packageForm["salesProportionPercent"]}`
const oldValue = `${this.packageForm["oldesalesProportionPercent"]}`
this.$set(
this.packageForm,
"salesProportionPercent",
......
......@@ -1473,7 +1473,6 @@ export default {
},
beforeDestroy() {
this.$EventBus.$off("packageInfoList")
this.$EventBus.$off("shelfUpdateContractMer")
this.$EventBus.$off("shelfUpdateParMer")
this.$EventBus.$off("shelfUpdatMerchantId")
}
......
......@@ -169,10 +169,6 @@ export default {
merchantName: merchantName
}
})
// this.$EventBus.$emit("shelfUpdateContractMer", {
// merchantId: value,
// merchantName: merchantName
// })
}
},
{
......
......@@ -215,7 +215,7 @@ export default {
}
var params = {
businessCode: this.routeObj.businessCode,
merchant: this.$refs.shopMerchant.editData,
merchants: this.$refs.shopMerchant.editData,
settleDistributeRule: this.$refs.divisionConfig.submitParams,
reconciliationRule: this.$refs.financeConfig.submitParams
}
......@@ -282,7 +282,7 @@ export default {
businessCode: this.routeObj.businessCode,
goods: this.$refs.goodsInfo.submitParamsGoods(),
packages: this.$refs.goodsInfo.submitParamsPackages(),
merchant: [this.$refs.shopMerchant.editData],
merchants: [this.$refs.shopMerchant.editData],
settleDistributeRule:
settleDistributeRule || this.$refs.divisionConfig.submitParams,
reconciliationRule:
......
......@@ -163,7 +163,7 @@ export default {
}
var params = {
businessCode: this.routeObj.businessCode,
merchant: this.$refs.multilateralShopMerchant.getAllParams(),
merchants: this.$refs.multilateralShopMerchant.getAllParams(),
settleDistributeRule: this.$refs.divisionConfig.submitParams,
reconciliationRule: this.$refs.financeConfig.submitParams
}
......@@ -202,7 +202,7 @@ export default {
businessCode: this.routeObj.businessCode,
goods: this.$refs.goodsInfo.submitParamsGoods(),
packages: this.$refs.goodsInfo.submitParamsPackages(),
merchant: this.$refs.multilateralShopMerchant.getAllParams(),
merchants: this.$refs.multilateralShopMerchant.getAllParams(),
settleDistributeRule:
settleDistributeRule || this.$refs.divisionConfig.submitParams,
reconciliationRule:
......
......@@ -138,6 +138,16 @@ export default {
optionsName: "approveTypeOpt"
},
{
label: "上架类型",
name: "shelfType",
type: "select",
isClear: true,
optionList: [],
optionId: "confId",
optionLabel: "confValue",
optionsName: "shelfTypeOpt"
},
{
label: "系统状态",
name: "systemStatus",
type: "select",
......
......@@ -368,6 +368,14 @@ export default {
busiInfoAttrObj: {
fixed: [
{
label: "退款子项",
name: "refundSubOrderCode"
},
{
label: "可退总价",
name: "refundableTotalPrice"
},
{
label: "退款类型",
name: "refundTypeTxt"
},
......
<template>
<d2-dialog title="请选择退款明细" :is-visible.sync="refundVisible" width="70%" btn-ok-label="下一步"
@confirmDialog="handleConfirm" @closeDialog="handleClose" class="relateStore">
<el-dialog title="请选择退款明细" :visible.sync="refundVisible" :before-close="handleClose"
:close-on-click-modal="false" width="70%" class="relateStore">
<div>
<el-table ref="seletingTable" :data="tableData" class="table" border @select="handleChange"
@select-all="handleAll">
......@@ -15,7 +15,11 @@
</el-table>
<div class="total">可选可退总价:<div class="price">¥{{ total }}</div></div>
</div>
</d2-dialog>
<span slot="footer" class="dialog-footer">
<el-button @click="handleClose">取 消</el-button>
<el-button type="primary" @click="handleConfirm" :disabled="!refundSubOrderCode">下一步</el-button>
</span>
</el-dialog>
</template>
<script>
......
......@@ -7,7 +7,7 @@
>
<div class="detail-content">
<div class="form_div">
<el-form class="edit-sub-block" label-width="110px" :inline="true">
<el-form class="edit-sub-block" label-width="140px" :inline="true">
<el-row :gutter="20">
<el-col :span="8">
<el-form-item label="客户:">
......@@ -154,6 +154,26 @@
{{ addScore ? addScore : "-" }}
</el-form-item>
</el-col>
<el-col
:span="8"
v-if="detailInfo.status == '已失效'"
>
<el-form-item label="退款金额:" class="halfItem">
{{
detailInfo.orderMoney
? "¥" + detailInfo.orderMoney.toFixed(2)
: "-"
}}
</el-form-item>
</el-col>
<el-col
:span="8"
v-if="detailInfo.status == '已失效'"
>
<el-form-item label="退款子订单信息:" class="halfItem">
{{ detailInfo.refundSubOrderCode ? detailInfo.refundSubOrderCode : "-" }}
</el-form-item>
</el-col>
</el-row>
</el-form>
</div>
......
<template>
<el-dialog title="请选择退款明细" :visible.sync="refundVisible" :before-close="handleClose"
:close-on-click-modal="false" width="70%" class="relateStore">
<div>
<el-table ref="seletingTable" :data="tableData" class="table" border @select="handleChange"
@select-all="handleAll">
<el-table-column :selectable-fn="selectableFn" type="selection" width="55" align="center" />
<template v-for="item in tableColumn">
<el-table-column :prop="item.prop" :label="item.label" align="center">
<span slot-scope="scope">{{
scope.row[item.prop] ? scope.row[item.prop] : "-"
}}</span>
</el-table-column>
</template>
</el-table>
<div class="total">可选可退总价:<div class="price">¥{{ total }}</div></div>
</div>
<span slot="footer" class="dialog-footer">
<el-button @click="handleClose">取 消</el-button>
<el-button type="primary" @click="handleConfirm" :disabled="!refundSubOrderCode">下一步</el-button>
</span>
</el-dialog>
</template>
<script>
import { getGoodsSubOrder } from "@api/point"
export default {
name: 'refundDetail',
data() {
return {
tableData: [],
tableColumn: [
{
label: '子订单编码',
prop: 'subOrderCode'
},
{
label: '商品名称',
prop: 'goodsName'
},
{
label: '商品别名',
prop: 'goodsAlias'
},
{
label: '商品ID',
prop: 'goodsCommodityCode'
},
{
label: '分类',
prop: 'upgradeGoodsTypeName'
},
{
label: '售价',
prop: 'upgradePrice'
},
{
label: '数量/件',
prop: 'number'
},
{
label: '支付金额',
prop: 'totalPrice'
}
],
total: 0,
refundSubOrderCode: ''
}
},
props: {
refundVisible: {
type: Boolean,
default: false
},
dataInfo: {
type: Object,
default: {}
}
},
watch: {
dataInfo(val) {
console.log(val)
if (val && val.orderCode) this.getList(val.orderCode)
}
},
methods: {
// 设置禁用
selectableFn(row) {
console.log(row)
if (row.status == 2) return false
else if (row.status == 1) return true
},
async getList(orderCode) {
const res = await getGoodsSubOrder({ orderCode })
this.tableData = res
},
handleChange(selection) {
console.log(selection)
this.getParams(selection)
},
handleAll(selection) {
console.log(selection)
this.getParams(selection)
},
getParams(selection) {
let _total = 0
let _refundSubOrderCode = []
selection.forEach(item => {
_total += item.totalPrice
_refundSubOrderCode.push(item.subOrderCode)
})
this.total = _total
this.refundSubOrderCode = _refundSubOrderCode.join('/')
console.log(this.refundSubOrderCode)
},
handleConfirm() {
const {refundSubOrderCode, total} = this
this.$emit("handleConfirm", {
total,
refundSubOrderCode
})
},
handleClose() {
this.$emit("handleClose")
}
}
}
</script>
<style lang="scss" scoped>
.total {
display: flex;
align-items: center;
color: #666666;
font-size: 14px;
.price {
color: #2A58AD;
margin-left: 10px;
}
}
</style>
\ No newline at end of file
......@@ -103,11 +103,13 @@
>
</glsx-combi-form>
</d2-dialog>
<refundDetail :dataInfo="dataInfo" :refundVisible="refundDetailVisible" @handleClose="handleRefundDetailClose" @handleConfirm="handleConfirm"></refundDetail>
</div>
</d2-container>
</template>
<script>
import refundDetail from './components/refundDetail'
import { Util, deepClone } from "@/common/util"
import { mapActions, mapState } from "vuex"
import detailDialog from "./components/detailDialog"
......@@ -125,7 +127,8 @@ import {
export default {
name: "PointList",
components: {
detailDialog
detailDialog,
refundDetail
},
data() {
var checkIntegral = (rule, value, callback) => {
......@@ -387,7 +390,10 @@ export default {
width: "290px",
isDisabled: false
}
]
],
refundDetailVisible: false,
dataInfo: {},
refundInfo: {}
}
},
computed: {
......@@ -650,6 +656,24 @@ export default {
// })
})
},
// 添加选择退款明细弹窗
openRefundDetail(data) {
this.refundDetailVisible = true
this.dataInfo = {
orderCode: data.orderCode
}
this.refundInfo = data
},
handleRefundDetailClose() {
this.refundDetailVisible = false
},
handleConfirm(val) {
console.log(val, '=====')
this.refundInfo.refundSubOrderCode = val.refundSubOrderCode
this.refundInfo.total = val.total
this.handleRefund(this.refundInfo) // 原来的逻辑
this.refundDetailVisible = false
},
//标记退款
handleRefund(data) {
this.refundVisible = true
......@@ -660,6 +684,8 @@ export default {
this.refundForm.refundPoints = data.integralIncome //退还积分
this.refundForm.refundAmount = data.orderMoney //退还金额
this.refundForm.staffUuid = data.staffUuid
this.refundForm.refundSubOrderCode = data.refundSubOrderCode
this.refundForm.refundableTotalPrice = data.total
//当前积分能抵扣的最大值
this.getScore()
},
......@@ -721,7 +747,9 @@ export default {
refundPoints: this.refundForm.refundPoints,
refundAmount: this.refundForm.refundAmount,
employeeUserId: this.refundForm.employeeUserId,
employeeName: this.refundForm.employeeName
employeeName: this.refundForm.employeeName,
refundSubOrderCode: this.refundForm.refundSubOrderCode,
refundableTotalPrice: this.refundForm.refundableTotalPrice
})
.then((res) => {
if (res) {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!