Commit 62c7c1c8 by 李伟康

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

…ife-system into SAAS+V4.50.0-0311
2 parents 81997462 bd5ff9e9
...@@ -71,6 +71,11 @@ export function getGoodsDetail(data) { ...@@ -71,6 +71,11 @@ export function getGoodsDetail(data) {
return request(data, RequestMethods.POST) return request(data, RequestMethods.POST)
} }
// 嘀加上架提交
export function saveApprove(data) {
data.method = `${path}save`
return request(data, RequestMethods.POST, ["file"])
}
// 新增商户 - 保存商户 // 新增商户 - 保存商户
export function saveMerchant(data) { export function saveMerchant(data) {
data.method = `merchants.api.merchant.saveMerchant` data.method = `merchants.api.merchant.saveMerchant`
...@@ -88,3 +93,8 @@ export function operationConfirm(data) { ...@@ -88,3 +93,8 @@ export function operationConfirm(data) {
data.method = `dj.api.create.business.approve.operationConfirm` data.method = `dj.api.create.business.approve.operationConfirm`
return request(data, RequestMethods.POST) return request(data, RequestMethods.POST)
} }
// 嘀加上架 - 保存
export function operationConfirmJson(data) {
data.method = `dj.api.create.business.approve.operationConfirm.json`
return request(data, RequestMethods.POST)
}
...@@ -244,34 +244,38 @@ export default { ...@@ -244,34 +244,38 @@ export default {
handleSelectGoodsConfirm(selectedData) { handleSelectGoodsConfirm(selectedData) {
const _formData = this.formData const _formData = this.formData
const _valueObj = selectedData const _valueObj = selectedData
console.log('_valueObj', _valueObj)
// const _positionNamesArr = deepClone(this.positionTypeList).filter(val => (_valueObj?.position?.split(','))?.includes(val.position + '')) || [] // const _positionNamesArr = deepClone(this.positionTypeList).filter(val => (_valueObj?.position?.split(','))?.includes(val.position + '')) || []
// const { goodsTypeName, secondaryGoodsTypeName, thirdLevelGoodsTypeName } = _valueObj?.goodsInfo || {} const { goodsTypeName, secondaryGoodsTypeName, thirdLevelGoodsTypeName } = _valueObj?.goodsInfo || {}
// const types = [goodsTypeName, secondaryGoodsTypeName, thirdLevelGoodsTypeName] const types = [goodsTypeName, secondaryGoodsTypeName, thirdLevelGoodsTypeName]
// const result = types.filter(type => type).join('-') const result = types.filter(type => type).join('-')
// _formData.upgradeGoods = { _formData.upgradeGoods = {
// ..._valueObj, ..._valueObj,
// goodsName: _valueObj.goodsInfo.goodsName, goodsName: _valueObj.goodsInfo.goodsName,
// tempGoodsTypeName: result, tempGoodsTypeName: result,
// serviceItemNames: _valueObj?.upgradeGoodsServiceItemsList?.map(item => { return `${item.serviceName}-${item.serviceGrade}/${item.servicePeriod}` })?.join(','), // 服务项目 serviceItemNames: _valueObj?.upgradeGoodsServiceItemsList?.map(item => { return `${item.serviceName}-${item.serviceGrade}/${item.servicePeriod}` })?.join(','), // 服务项目
// positionNames: _positionNamesArr.length ? _positionNamesArr.map(subItem => { return subItem?.confName }).join('/') : '', // positionNames: _positionNamesArr.length ? _positionNamesArr.map(subItem => { return subItem?.confName }).join('/') : '',
// specificationData: this.filterSpecsStr(_valueObj), // specificationData: this.filterSpecsStr(_valueObj),
// djCost: _valueObj?.djCost, djCost: _valueObj?.djCost,
// carTypeConfigName: _valueObj?.carTypeConfigList?.map(item => item.seriesName).join('/'), carTypeConfigName: _valueObj?.carTypeConfigList?.map(item => item.seriesName).join('/'),
// upgradeCommodityCode: _valueObj?.commodityCode upgradeCommodityCode: _valueObj?.commodityCode
// } }
// _formData.goodsType = _valueObj?.goodsInfo?.goodsType _formData.goodsType = _valueObj?.goodsInfo?.goodsType
// _formData.upgradeGoodsId = _valueObj.id _formData.upgradeGoodsId = _valueObj.id
// _formData.positionNamesArr = _positionNamesArr // _formData.positionNamesArr = _positionNamesArr
// _formData.productType = [] // 切换上架商品 将服务类型清空 _formData.productType = [] // 切换上架商品 将服务类型清空
// _formData.baseSupplyMode = '' // 切换上架商品 将基础供货模式清空 _formData.baseSupplyMode = '' // 切换上架商品 将基础供货模式清空
// _formData.upgradeSupplyMode = '' // 切换上架商品 将升级/产品供货模式清空 _formData.upgradeSupplyMode = '' // 切换上架商品 将升级/产品供货模式清空
// _formData.supplierCode = _valueObj?.goodsInfo?.supplierCode // 供应方 判断是否需要走审核流程 _formData.supplierCode = _valueObj?.goodsInfo?.supplierCode // 供应方 判断是否需要走审核流程
if (!this.filterEmpty(_valueObj?.djCost)) _formData.djCost = _valueObj?.djCost // 嘀加成本 商品信息自带数据 if (!this.filterEmpty(_valueObj?.djCost)) _formData.djCost = _valueObj?.djCost // 嘀加成本 商品信息自带数据
this.handleSelectGoodsClose() this.handleSelectGoodsClose()
}, },
handleSelectGoodsClose() { handleSelectGoodsClose() {
this.selectGoodsVisible = false this.selectGoodsVisible = false
}, },
filterEmpty(data) {
return (data ?? '') === ''
},
val3_handleInput(newVal) { val3_handleInput(newVal) {
this.form.val3 = limitPrice( this.form.val3 = limitPrice(
......
...@@ -279,110 +279,8 @@ export default { ...@@ -279,110 +279,8 @@ export default {
// }), // }),
...mapGetters("goodsSourceSet", { goodsSourceSet: "goodsSourceSet" }), ...mapGetters("goodsSourceSet", { goodsSourceSet: "goodsSourceSet" }),
routerInfo() { routerInfo() {
// return this.$route.query.params console.log(this.$route.params, "this.$route.params🚀🚀")
// ? JSON.parse(this.$route.query.params) return this.$route.params ? this.$route.params : ""
// : ""
return {
scene: 0,
merchantId: 44217961,
yqMerchant: {
id: null,
merchantId: 44218078,
merchantName: "测试园区-门店",
shortName: null,
userType: null,
merchantType: 6,
accountName: null,
contactName: null,
phone: null,
address: null,
provinceId: null,
provinceName: null,
cityId: null,
cityName: null,
areaId: null,
areaName: null,
lng: null,
lat: null,
shopPhoto: null,
channelType: null,
ysemRefedFlag: null,
accountStatus: null,
yseMerchantId: null,
yseUserCode: null,
region: null,
stayContactName: null,
stayPhone: null,
divisionTestFlag: null,
openDate: null,
entryDate: null,
sourceType: null,
storeCode: null,
businessType: null,
latestOrderTime: null,
createdBy: null,
createdDate: null,
updatedBy: null,
updatedDate: 1740104144000,
deletedFlag: null,
cardCodeFlag: null,
trafficExpireFlag: null
},
serviceList: [
{
id: null,
merchantId: 44211753,
merchantName: "权限验证门店",
shortName: null,
userType: null,
merchantType: 7,
accountName: null,
contactName: null,
phone: null,
address: null,
provinceId: null,
provinceName: null,
cityId: null,
cityName: null,
areaId: null,
areaName: null,
lng: null,
lat: null,
shopPhoto: null,
channelType: null,
ysemRefedFlag: null,
accountStatus: null,
yseMerchantId: null,
yseUserCode: null,
region: null,
stayContactName: null,
stayPhone: null,
divisionTestFlag: null,
openDate: null,
entryDate: null,
sourceType: null,
storeCode: null,
businessType: null,
latestOrderTime: null,
createdBy: null,
createdDate: null,
updatedBy: null,
updatedDate: 1739737467000,
deletedFlag: null,
cardCodeFlag: null,
trafficExpireFlag: null
}
],
autoFlag: null,
testFlag: null,
divisionType: "N",
maxUpdatedDate: 1740104144000,
merchantName: "single_xiehx测试单店",
userType: 1,
channelType: 1,
updatedDate: 1740104144000,
num: 2
}
}, },
addVisible() { addVisible() {
// return false // return false
...@@ -394,6 +292,7 @@ export default { ...@@ -394,6 +292,7 @@ export default {
return length1 - length3 - 2 > 0 && length1 > length2 return length1 - length3 - 2 > 0 && length1 > length2
}, },
financialLedgerParty() { financialLedgerParty() {
console.log(this.financialObj, "wangzhh ")
const { const {
realityPlatformMerchantId, realityPlatformMerchantId,
realityPlatformMerchantName, realityPlatformMerchantName,
...@@ -419,6 +318,7 @@ export default { ...@@ -419,6 +318,7 @@ export default {
watch: { watch: {
"financialObj.realityShopMerchantId": { "financialObj.realityShopMerchantId": {
handler(val) { handler(val) {
console.log(val, "realityShopMerchantId")
// this.financialObj.realityShopMerchantId // this.financialObj.realityShopMerchantId
const obj = this.baseData.merchantLevelList.find( const obj = this.baseData.merchantLevelList.find(
(item) => item.merchantId == val (item) => item.merchantId == val
...@@ -479,6 +379,7 @@ export default { ...@@ -479,6 +379,7 @@ export default {
this.initFeeCategoryByType() this.initFeeCategoryByType()
this.getGoodsCategoryConfiguration() // 商品分类 this.getGoodsCategoryConfiguration() // 商品分类
const { merchantId, scene } = this.routerInfo const { merchantId, scene } = this.routerInfo
console.log(this.routerInfo, "this.routerInfo🚀")
// yqMerchant && this.getMerchantLevel(yqMerchant.merchantId, 'PlatformLevelList') // yqMerchant && this.getMerchantLevel(yqMerchant.merchantId, 'PlatformLevelList')
// this.initPlatformLevelList() // this.initPlatformLevelList()
// this.getFinancialObj() // this.getFinancialObj()
...@@ -494,7 +395,6 @@ export default { ...@@ -494,7 +395,6 @@ export default {
this.checkSelectEmpty() this.checkSelectEmpty()
}) })
this.$EventBus.$on("packageInfoList", (obj) => { this.$EventBus.$on("packageInfoList", (obj) => {
console.log(obj)
this.getSelectingListPackage([], obj) this.getSelectingListPackage([], obj)
}) })
// 平台方 // 平台方
...@@ -510,12 +410,20 @@ export default { ...@@ -510,12 +410,20 @@ export default {
}) })
// 服务商 // 服务商
this.$EventBus.$on("shelfUpdateParMer", (obj) => { this.$EventBus.$on("shelfUpdateParMer", (obj) => {
console.log(obj, "this.$set")
this.$set(this.financialObj, "partnerMerchantId", obj.merchantId) this.$set(this.financialObj, "partnerMerchantId", obj.merchantId)
this.$set(this.financialObj, "partnerMerchantName", obj.merchantName) this.$set(this.financialObj, "partnerMerchantName", obj.merchantName)
this.financialObj = deepClone(this.financialObj)
// this.financialObj.partnerMerchantId = obj.merchantId // this.financialObj.partnerMerchantId = obj.merchantId
// this.financialObj.partnerMerchantName = obj.merchantName // this.financialObj.partnerMerchantName = obj.merchantName
}) })
//获取流量方请求流量方分账
this.$EventBus.$on("shelfUpdatMerchantId", (obj) => {
this.baseData.merchantLevelList = []
this.financialObj.realityShopMerchantId = ""
this.financialObj.realityShopMerchantName = ""
this.financialObj = deepClone(this.financialObj)
this.getMerchantLevel(obj.merchantId, "merchantLevelList", obj.scene)
})
}, },
methods: { methods: {
...mapActions("FinancialRules", ["reset"]), ...mapActions("FinancialRules", ["reset"]),
...@@ -540,7 +448,9 @@ export default { ...@@ -540,7 +448,9 @@ export default {
realityPlatformUserType: "2", // 实际分账平台方商户用户类型(1工厂2省代3市代4门店) realityPlatformUserType: "2", // 实际分账平台方商户用户类型(1工厂2省代3市代4门店)
realityShopMerchantId: merchantId, // 实际分账4S店商户号 realityShopMerchantId: merchantId, // 实际分账4S店商户号
realityShopMerchantName: merchantName, // 实际分账4S店商户名称 realityShopMerchantName: merchantName, // 实际分账4S店商户名称
realityShopUserType: channelType // 实际分账4S店商户用户类型(1工厂2省代3市代4门店) realityShopUserType: channelType, // 实际分账4S店商户用户类型(1工厂2省代3市代4门店)
partnerMerchantId: "",
partnerMerchantName: ""
}) })
}, },
initSettleTimeObj() { initSettleTimeObj() {
...@@ -643,7 +553,7 @@ export default { ...@@ -643,7 +553,7 @@ export default {
return new Promise((resolve) => { return new Promise((resolve) => {
const { id } = this.routerInfo const { id } = this.routerInfo
merchantSettleDistributeRuleLastRule({ merchantSettleDistributeRuleLastRule({
id: 1 id
}) })
.then((result) => { .then((result) => {
const goodsTypeGroupRules = const goodsTypeGroupRules =
...@@ -888,6 +798,7 @@ export default { ...@@ -888,6 +798,7 @@ export default {
...res, ...res,
goodsTypeGroupRules goodsTypeGroupRules
} }
console.log(this.submitParams, "this.submitParams ")
this.checkCalculateType() this.checkCalculateType()
this.verificationCodeVisible = true this.verificationCodeVisible = true
console.log(this.submitParams, "this.submitParams ") console.log(this.submitParams, "this.submitParams ")
...@@ -1268,7 +1179,7 @@ export default { ...@@ -1268,7 +1179,7 @@ export default {
packageArr = packageArr.map((item) => { packageArr = packageArr.map((item) => {
// item.packageCode = item.id // item.packageCode = item.id
// item.packageName = item.name // item.packageName = item.name
item.packageCode = item.id || item.timeId item.packageCode = item.packageCode || item.timeId
item.packageName = item.name || item.val1 item.packageName = item.name || item.val1
item.tempPackageCode = item.timeId || "" item.tempPackageCode = item.timeId || ""
// console.log(item, "item") // console.log(item, "item")
...@@ -1311,6 +1222,10 @@ export default { ...@@ -1311,6 +1222,10 @@ export default {
) )
}, },
getParams() { getParams() {
console.log(
this.baseData.PlatformLevelList,
this.baseData.merchantLevelList
)
var realityPlatform = this.baseData.PlatformLevelList.find( var realityPlatform = this.baseData.PlatformLevelList.find(
(item) => item.merchantId == this.financialObj.realityPlatformMerchantId (item) => item.merchantId == this.financialObj.realityPlatformMerchantId
) )
...@@ -1328,10 +1243,10 @@ export default { ...@@ -1328,10 +1243,10 @@ export default {
settleTime: settleTime:
this.settleTimeObj[settleTimeType == 1 ? "first" : "second"], this.settleTimeObj[settleTimeType == 1 ? "first" : "second"],
// 平台方 // 平台方
realityPlatformMerchantId: realityPlatform.merchantId, // realityPlatformMerchantId: realityPlatform.merchantId,
realityPlatformMerchantName: realityPlatform.merchantName, // realityPlatformMerchantName: realityPlatform.merchantName,
realityPlatformUserType: realityPlatform.userType || 2, // realityPlatformUserType: realityPlatform.userType || 2,
// 导流方 // // 导流方
realityShopMerchantId: realityMerchant.merchantId, realityShopMerchantId: realityMerchant.merchantId,
realityShopMerchantName: realityMerchant.merchantName, realityShopMerchantName: realityMerchant.merchantName,
realityShopUserType: realityMerchant.userType realityShopUserType: realityMerchant.userType
...@@ -1366,6 +1281,7 @@ export default { ...@@ -1366,6 +1281,7 @@ export default {
}) })
}, },
getMerchantLevel(id, name, scene) { getMerchantLevel(id, name, scene) {
console.log(id, name, scene, "getMerchantLevel🚀")
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
getMerchantLevelApi({ getMerchantLevelApi({
merchantId: id, merchantId: id,
...@@ -1373,6 +1289,9 @@ export default { ...@@ -1373,6 +1289,9 @@ export default {
scene scene
}) })
.then((res) => { .then((res) => {
console.log(
"------------------------------------------------------------"
)
const attrToVal = deepClone(attrToValOptions) const attrToVal = deepClone(attrToValOptions)
if (name == "PlatformLevelList") { if (name == "PlatformLevelList") {
delete attrToVal[2] delete attrToVal[2]
...@@ -1431,6 +1350,10 @@ export default { ...@@ -1431,6 +1350,10 @@ export default {
} }
// 将数据去重 (商户上架时一级流量方和流量通道方设置同一家门店) // 将数据去重 (商户上架时一级流量方和流量通道方设置同一家门店)
this.baseData[name] = this.uniqueMerchant(this.baseData[name]) this.baseData[name] = this.uniqueMerchant(this.baseData[name])
console.log(
this.baseData.merchantLevelList,
"this.baseData[name]---------------------"
)
resolve() resolve()
}) })
.catch(() => { .catch(() => {
......
...@@ -136,153 +136,7 @@ export default { ...@@ -136,153 +136,7 @@ export default {
}, },
computed: { computed: {
routerInfo() { routerInfo() {
// return this.$route.query.params return this.$route.params ? this.$route.params : ""
// ? JSON.parse(this.$route.query.params)
// : ""
return {
scene: 0,
merchantId: 44218105,
yqMerchant: {
id: null,
merchantId: 44218107,
merchantName: "鸿蒙园区店",
shortName: null,
userType: null,
merchantType: 6,
accountName: null,
contactName: null,
phone: null,
address: null,
provinceId: null,
provinceName: null,
cityId: null,
cityName: null,
areaId: null,
areaName: null,
lng: null,
lat: null,
shopPhoto: null,
channelType: null,
ysemRefedFlag: null,
accountStatus: null,
yseMerchantId: null,
yseUserCode: null,
region: null,
stayContactName: null,
stayPhone: null,
divisionTestFlag: null,
openDate: null,
entryDate: null,
sourceType: null,
storeCode: null,
businessType: null,
latestOrderTime: null,
createdBy: null,
createdDate: null,
updatedBy: null,
updatedDate: 1740036558000,
deletedFlag: null,
cardCodeFlag: null,
trafficExpireFlag: null
},
serviceList: [
{
id: null,
merchantId: 44218130,
merchantName: "新华园区店",
shortName: null,
userType: null,
merchantType: 7,
accountName: null,
contactName: null,
phone: null,
address: null,
provinceId: null,
provinceName: null,
cityId: null,
cityName: null,
areaId: null,
areaName: null,
lng: null,
lat: null,
shopPhoto: null,
channelType: null,
ysemRefedFlag: null,
accountStatus: null,
yseMerchantId: null,
yseUserCode: null,
region: null,
stayContactName: null,
stayPhone: null,
divisionTestFlag: null,
openDate: null,
entryDate: null,
sourceType: null,
storeCode: null,
businessType: null,
latestOrderTime: null,
createdBy: null,
createdDate: null,
updatedBy: null,
updatedDate: 1739737537000,
deletedFlag: null,
cardCodeFlag: null,
trafficExpireFlag: null
},
{
id: null,
merchantId: 44218103,
merchantName: "鸿蒙服务商",
shortName: null,
userType: null,
merchantType: 7,
accountName: null,
contactName: null,
phone: null,
address: null,
provinceId: null,
provinceName: null,
cityId: null,
cityName: null,
areaId: null,
areaName: null,
lng: null,
lat: null,
shopPhoto: null,
channelType: null,
ysemRefedFlag: null,
accountStatus: null,
yseMerchantId: null,
yseUserCode: null,
region: null,
stayContactName: null,
stayPhone: null,
divisionTestFlag: null,
openDate: null,
entryDate: null,
sourceType: null,
storeCode: null,
businessType: null,
latestOrderTime: null,
createdBy: null,
createdDate: null,
updatedBy: null,
updatedDate: 1739737514000,
deletedFlag: null,
cardCodeFlag: null,
trafficExpireFlag: null
}
],
autoFlag: "N",
testFlag: "N",
divisionType: "N",
maxUpdatedDate: 1740036558000,
merchantName: "第一个鸿蒙4S店",
userType: 4,
channelType: 1,
updatedDate: 1740036558000,
num: 3
}
}, },
addVisible() { addVisible() {
// return false // return false
...@@ -450,7 +304,7 @@ export default { ...@@ -450,7 +304,7 @@ export default {
packageArr = packageArr.map((item) => { packageArr = packageArr.map((item) => {
// item.packageCode = item.id // item.packageCode = item.id
// item.packageName = item.name // item.packageName = item.name
item.packageCode = item.id || item.timeId item.packageCode = item.packageCode || item.timeId
item.packageName = item.name || item.val1 item.packageName = item.name || item.val1
// console.log(item, "item") // console.log(item, "item")
return item return item
...@@ -794,11 +648,10 @@ export default { ...@@ -794,11 +648,10 @@ export default {
// 对账item的详情 // 对账item的详情
async getEffectRule() { async getEffectRule() {
const params = { const params = {
id: 1 id: this.routerInfo.id
} }
const res = await merchantSettleDistributeRuleLastRule(params) const res = await merchantSettleDistributeRuleLastRule(params)
if (res) { if (res) {
console.log(res, "9999999999999999999999999999999999999999")
const typeList = const typeList =
res?.merchantReconciliationRule.goodsTypeGroupReconciliationRules res?.merchantReconciliationRule.goodsTypeGroupReconciliationRules
...@@ -932,6 +785,7 @@ export default { ...@@ -932,6 +785,7 @@ export default {
return new Promise(async (resolve, reject) => { return new Promise(async (resolve, reject) => {
// 校验重置数据 防止重复push // 校验重置数据 防止重复push
this.goodsTypeGroupRulesAll = [] this.goodsTypeGroupRulesAll = []
console.log(this.goodsTypeGroupRulesAll, "this.goodsTypeGroupRulesAll")
const goodsTypeGroupRules = [] const goodsTypeGroupRules = []
for (var index = 0; index < this.editableTabs.length; index++) { for (var index = 0; index < this.editableTabs.length; index++) {
const node = const node =
...@@ -947,6 +801,7 @@ export default { ...@@ -947,6 +801,7 @@ export default {
goodsTypeGroupRules.push(res) goodsTypeGroupRules.push(res)
} }
this.$forceUpdate() this.$forceUpdate()
console.log(this.goodsTypeGroupRulesAll, "this.goodsTypeGroupRulesAll")
resolve(goodsTypeGroupRules) resolve(goodsTypeGroupRules)
}) })
}, },
......
...@@ -153,7 +153,7 @@ export default { ...@@ -153,7 +153,7 @@ export default {
getDetail() { getDetail() {
console.log("getGoodsDetail") console.log("getGoodsDetail")
// this.recordId // this.recordId
getGoodsDetail({ id: 1 }) getGoodsDetail({ id: 6 })
.then((res) => { .then((res) => {
console.log(res, "getGoodsDetail") console.log(res, "getGoodsDetail")
this.goodsInfo = res this.goodsInfo = res
...@@ -340,10 +340,12 @@ export default { ...@@ -340,10 +340,12 @@ export default {
this.packageInfoList = [] this.packageInfoList = []
this.packageTabs.forEach((item) => { this.packageTabs.forEach((item) => {
if (item.info) { if (item.info) {
console.log(item)
const o = { const o = {
name: item.info.val1 || item.info.packageName, name: item.info.val1 || item.info.packageName,
virtualCode: item.info.timeId, virtualCode: item.info.timeId,
id: item.info.id id: item.info.id,
packageCode: item.info.packageCode
} }
this.packageInfoList.push(o) this.packageInfoList.push(o)
} }
......
...@@ -72,9 +72,10 @@ export default { ...@@ -72,9 +72,10 @@ export default {
changeAttr: (value) => { changeAttr: (value) => {
this.getMerchantLevel() this.getMerchantLevel()
// this.baseData.pointTypeOpt = [] // this.baseData.pointTypeOpt = []
// if (value) { if (value) {
// this.baseData.pointTypeOpt = this.baseData.pointClassificationOpt.find(item => item.categoryCode == value).typeList const merchantName = this.baseData.merchantList.find(item => item.merchantId == value).merchantName
// } this.$EventBus.$emit('shelfUpdatMerchantId', { merchantId: value, merchantName: merchantName,scene:this.editData.sceneType })
}
// this.editData.pointType = "" // this.editData.pointType = ""
// this.getOptionsList('editFormData', false) // this.getOptionsList('editFormData', false)
} }
......
...@@ -379,14 +379,14 @@ export default { ...@@ -379,14 +379,14 @@ export default {
// expenseCategoryRules: [] // expenseCategoryRules: []
shop4sDeductChargeFlag: "Y", // 导流方POS机支付是否扣除手续费(Y:扣除,N:不扣) shop4sDeductChargeFlag: "Y", // 导流方POS机支付是否扣除手续费(Y:扣除,N:不扣)
partnerDeductChargeFlag: "Y", // 服务商POS机支付是否扣除手续费(Y:扣除,N:不扣) partnerDeductChargeFlag: "Y", // 服务商POS机支付是否扣除手续费(Y:扣除,N:不扣)
goodsCostFlag: "Y", // 平台方是否扣除产品成本(Y:计算,N:不计算) goodsCostFlag: "N", // 平台方是否扣除产品成本(Y:计算,N:不计算)
groupType: 1, groupType: 1,
categoryType: "", // 分类类别 categoryType: "", // 分类类别
upgradeGoods: [], // 具体商品 upgradeGoods: [], // 具体商品
packageGoods: [], packageGoods: [],
virtualAccountCostFlag: "Y", virtualAccountCostFlag: "N",
recoveryCostFlag: "Y", recoveryCostFlag: "N",
djCostFlag: "Y", djCostFlag: "N",
thirdPartyCostFlag: "Y", thirdPartyCostFlag: "Y",
goodsSource: 1 goodsSource: 1
// expenseCategoryRules: [ // expenseCategoryRules: [
...@@ -665,7 +665,7 @@ export default { ...@@ -665,7 +665,7 @@ export default {
if (val) { if (val) {
this.copyPackageGoodsList = deepClone(val) this.copyPackageGoodsList = deepClone(val)
// 然后对比一下当前选择的套件是否还在队列,不在就删除 // 然后对比一下当前选择的套件是否还在队列,不在就删除
this.classificationObj.packageGoods.length && this.classificationObj.packageGoods?.length &&
this.diffPackageGoodsList() this.diffPackageGoodsList()
} }
}, },
...@@ -1353,7 +1353,7 @@ export default { ...@@ -1353,7 +1353,7 @@ export default {
}, },
getParams() { getParams() {
const obj = deepClone(this.classificationObj) const obj = deepClone(this.classificationObj)
const expenseCategoryRules = [] let expenseCategoryRules = []
// 合并出对象的集合 类目对象合集 // 合并出对象的集合 类目对象合集
for (const key in obj) { for (const key in obj) {
if ( if (
...@@ -1404,8 +1404,11 @@ export default { ...@@ -1404,8 +1404,11 @@ export default {
// categoryType: obj.categoryType, // categoryType: obj.categoryType,
// goodsTypeGroupRelations: obj.categoryType == 1 ? goodsTypes : upgradeGoods, // goodsTypeGroupRelations: obj.categoryType == 1 ? goodsTypes : upgradeGoods,
console.log(obj, "obj") expenseCategoryRules = expenseCategoryRules.filter(
(item) => item.expenseCategoryId != 701
)
// debugger // debugger
console.log(obj, expenseCategoryRules, "obj")
const returnObj = { const returnObj = {
expenseCategoryRules, expenseCategoryRules,
shop4sDeductChargeFlag: obj.shop4sDeductChargeFlag, shop4sDeductChargeFlag: obj.shop4sDeductChargeFlag,
......
...@@ -524,7 +524,7 @@ export default { ...@@ -524,7 +524,7 @@ export default {
if (val) { if (val) {
this.copyPackageGoodsList = deepClone(val) this.copyPackageGoodsList = deepClone(val)
// 然后对比一下当前选择的套件是否还在队列,不在就删除 // 然后对比一下当前选择的套件是否还在队列,不在就删除
this.classificationObj.packageGoods.length && this.classificationObj.packageGoods?.length &&
this.diffPackageGoodsList() this.diffPackageGoodsList()
} }
}, },
...@@ -1434,7 +1434,7 @@ export default { ...@@ -1434,7 +1434,7 @@ export default {
}, },
// 换成后端数据结构 // 换成后端数据结构
getBackendFormat() { getBackendFormat() {
const flowServiceCostArr = [ let flowServiceCostArr = [
...this.classificationObj.temporaryArr, ...this.classificationObj.temporaryArr,
...this.classificationObj.flowCostArr, ...this.classificationObj.flowCostArr,
...this.classificationObj.serviceCostArr, ...this.classificationObj.serviceCostArr,
...@@ -1446,8 +1446,14 @@ export default { ...@@ -1446,8 +1446,14 @@ export default {
item.children[i].targetMerchantName = v.merchant?.merchantName item.children[i].targetMerchantName = v.merchant?.merchantName
item.children[i].targetMerchantId = v.merchant?.merchantId item.children[i].targetMerchantId = v.merchant?.merchantId
}) })
// item.expenseCategoryCalculateType =
// item.expenseCategoryCalculateType || 3
// item.expenseCategoryValue = item.expenseCategoryValue || 0
return item return item
}) })
flowServiceCostArr = flowServiceCostArr.filter(
(item) => item.expenseCategoryValue
)
// 按具体商品 // 按具体商品
this.classificationObj.upgradeGoods?.map((val) => { this.classificationObj.upgradeGoods?.map((val) => {
val.categoryType = this.classificationObj.categoryType val.categoryType = this.classificationObj.categoryType
......
...@@ -12,9 +12,17 @@ ...@@ -12,9 +12,17 @@
<!-- 基础信息 --> <!-- 基础信息 -->
<base-info :basic-info="basicInfo"></base-info> <base-info :basic-info="basicInfo"></base-info>
<!-- 流量方信息 --> <!-- 流量方信息 -->
<shop-merchant-info ref="shopMerchant" :edit-data="merchantEditData" @addMerchant="handleAddMerchant"></shop-merchant-info> <shop-merchant-info
ref="shopMerchant"
:edit-data="merchantEditData"
@addMerchant="handleAddMerchant"
></shop-merchant-info>
<!-- 流量方信息 - 新增 - 新增商户 --> <!-- 流量方信息 - 新增 - 新增商户 -->
<add-merchant v-if="addMerVisible" :add-mer-visible="addMerVisible" @handleClose="handleAddMerchant"></add-merchant> <add-merchant
v-if="addMerVisible"
:add-mer-visible="addMerVisible"
@handleClose="handleAddMerchant"
></add-merchant>
<!-- 上架商品及测算 --> <!-- 上架商品及测算 -->
<goods-info ref="goodsInfo" :record-id="routeObj.id"></goods-info> <goods-info ref="goodsInfo" :record-id="routeObj.id"></goods-info>
<!-- 分账配置 --> <!-- 分账配置 -->
...@@ -42,7 +50,11 @@ import AddMerchant from "./components/editCon/AddMerchant" ...@@ -42,7 +50,11 @@ import AddMerchant from "./components/editCon/AddMerchant"
import GoodsInfo from "./components/editCon/GoodsInfo.vue" import GoodsInfo from "./components/editCon/GoodsInfo.vue"
import DivisionConfig from "./components/editCon/DivisionConfig.vue" import DivisionConfig from "./components/editCon/DivisionConfig.vue"
import FinanceConfig from "./components/editCon/FinanceConfig.vue" import FinanceConfig from "./components/editCon/FinanceConfig.vue"
import { getBusisDetailBasic, operationConfirm } from "@api/shelfManage" import {
getBusisDetailBasic,
operationConfirm,
operationConfirmJson
} from "@api/shelfManage"
export default { export default {
name: "EditContract", name: "EditContract",
data() { data() {
...@@ -92,12 +104,17 @@ export default { ...@@ -92,12 +104,17 @@ export default {
this.addMerVisible = !this.addMerVisible this.addMerVisible = !this.addMerVisible
}, },
handleConfirm(confirmType) { handleConfirm(confirmType) {
this.$refs.divisionConfig.submit() // this.$refs.divisionConfig.submit()
this.$refs.financeConfig.submit() // this.$refs.financeConfig.submit()
if (confirmType == "save") { if (confirmType == "save") {
// console.log(
// !this.$refs.shopMerchant.submit(),
// !this.$refs.divisionConfig.submit(),
// !this.$refs.financeConfig.submit()
// )
// 各模块校验 // 各模块校验
if ( if (
!this.$refs.shopMerchant.submit() || // !this.$refs.shopMerchant.submit() ||
!this.$refs.divisionConfig.submit() || !this.$refs.divisionConfig.submit() ||
!this.$refs.financeConfig.submit() !this.$refs.financeConfig.submit()
) { ) {
...@@ -113,17 +130,14 @@ export default { ...@@ -113,17 +130,14 @@ export default {
settleDistributeRule: this.$refs.divisionConfig.submitParams, settleDistributeRule: this.$refs.divisionConfig.submitParams,
reconciliationRule: this.$refs.financeConfig.submitParams reconciliationRule: this.$refs.financeConfig.submitParams
} }
console.log( console.log(params, "params----")
this.$refs.goodsInfo.submitParamsGoods(), operationConfirmJson({ dataString: JSON.stringify(params) }).then(
this.$refs.goodsInfo.submitParamsPackages(), (res) => {
params, console.log(res)
"params----" this.$message.success("操作成功")
this.handleCancel()
}
) )
operationConfirm(params).then(res => {
console.log(res)
this.$message.success("操作成功")
this.handleCancel()
})
}, },
handleCancel() { handleCancel() {
this.close({ tagName: "/shelfManage" }) this.close({ tagName: "/shelfManage" })
......
...@@ -184,7 +184,8 @@ import { mapActions, mapState } from 'vuex' ...@@ -184,7 +184,8 @@ import { mapActions, mapState } from 'vuex'
import { deepClone } from "@/common/util" import { deepClone } from "@/common/util"
import { uploadFile } from "@/api/sys.base" import { uploadFile } from "@/api/sys.base"
import { import {
getWorkwechatTemplate getWorkwechatTemplate,
saveApprove
} from "@api/shelfManage.js" } from "@api/shelfManage.js"
export default { export default {
name: "EditShelf", name: "EditShelf",
...@@ -470,23 +471,27 @@ export default { ...@@ -470,23 +471,27 @@ export default {
const params = {} const params = {}
params.file = this.infoForm.fileInfo params.file = this.infoForm.fileInfo
params.basicApproveInfo = JSON.stringify(this.itemList) params.basicApproveInfo = JSON.stringify(this.itemList)
const approveType = this.$route.params.operate == "add" ? 1 : 2
params.approveType = approveType
console.log('params', params) console.log('params', params)
// console.log("JSON.stringify(this.itemList)", JSON.stringify(this.itemList)) // console.log("JSON.stringify(this.itemList)", JSON.stringify(this.itemList))
// merchantTargetConfigUpdate(params) saveApprove(params)
// .then((res) => { .then((res) => {
// console.log(res, "merchantTargetConfigUpdate") console.log(res)
// this.$notify({ this.$notify({
// type: "success", type: "success",
// title: "保存成功" title: "保存成功"
// }) })
// this.$router.push("/inStoreGoalsConfig") this.close({ tagName: "/editShelf" })
// }) this.$router.push({ name: "shelfManage" })
// .catch((err) => { })
// console.log(err) .catch((err) => {
// }) console.log(err)
// } else { })
// console.log("error submit!!") } else {
// return false console.log("error submit!!")
return false
} }
}) })
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!