Commit 47e82381 by 前端

Merge branch 'v3.23.0' into 'master'

V3.23.0

See merge request !49
2 parents 4dd209b8 c805d36a
This diff could not be displayed because it is too large.
...@@ -8,6 +8,8 @@ ...@@ -8,6 +8,8 @@
"lint": "vue-cli-service lint" "lint": "vue-cli-service lint"
}, },
"dependencies": { "dependencies": {
"@wangeditor/editor": "^5.1.23",
"@wangeditor/editor-for-vue": "^1.0.2",
"core-js": "^3.4.4", "core-js": "^3.4.4",
"dayjs": "^1.10.7", "dayjs": "^1.10.7",
"el-tree-transfer": "^2.2.6", "el-tree-transfer": "^2.2.6",
...@@ -35,6 +37,7 @@ ...@@ -35,6 +37,7 @@
"number-precision": "^1.6.0", "number-precision": "^1.6.0",
"prettier": "^1.19.1", "prettier": "^1.19.1",
"sass-loader": "^8.0.0", "sass-loader": "^8.0.0",
"snabbdom": "^3.5.1",
"vue-cli-plugin-element": "^1.0.1", "vue-cli-plugin-element": "^1.0.1",
"vue-quill-editor": "^3.0.6", "vue-quill-editor": "^3.0.6",
"vue-template-compiler": "^2.6.10" "vue-template-compiler": "^2.6.10"
......
...@@ -172,6 +172,18 @@ const getPackageListApi = params => { ...@@ -172,6 +172,18 @@ const getPackageListApi = params => {
}) })
} }
// 获取无忧卡套餐列表(新接口) 编辑新增调取新接口,查看调用久接口
const getNewPackageListApi = params => {
params.method = `scrm.api.equity.service.package.dj.list.without.tire`
// params.method = `scrm.api.equity.service.package.list.get`
return http({
url: 'rop-scrm-equity/router',
method: 'GET',
data: params,
sign: true
})
}
const getEquityApi = params => { const getEquityApi = params => {
params.method = `scrm.api.equity.service.channel.order.detail` params.method = `scrm.api.equity.service.channel.order.detail`
return http({ return http({
...@@ -402,4 +414,4 @@ const getSummaryExportApi = params => { ...@@ -402,4 +414,4 @@ const getSummaryExportApi = params => {
}) })
} }
export default { getOrdersummary, getSummaryPackage, getSummaryExportApi, getUserInfoApi, getCountNoDataApi, getListApi, getMerchantApi, getExportApi, getPriteApi, getCarBrandListApi, getCarChildListApi, getCarTypeListApi, getCarSeriesListApi, getHotlineApi, getDefaultCarbrandApi, updateHotlineApi, updateCarBrandApi, getProListApi, getPackageListApi, getEquityApi, updateEquityApi, createCodeApi, getOrderAttrApi, getAllOrderValueApi, verifyOrderApi, checkOrderApi, updateOrderApi, uploadImgApi, backOrderApi, aduitOrderApi, judgeSetting, spaAgressData, merchantInfo, dateBycarNo, activeCodeList, updateActiveCode } export default { getOrdersummary, getSummaryPackage, getSummaryExportApi, getUserInfoApi, getCountNoDataApi, getListApi, getMerchantApi, getExportApi, getPriteApi, getCarBrandListApi, getCarChildListApi, getCarTypeListApi, getCarSeriesListApi, getHotlineApi, getDefaultCarbrandApi, updateHotlineApi, updateCarBrandApi, getProListApi, getPackageListApi, getNewPackageListApi, getEquityApi, updateEquityApi, createCodeApi, getOrderAttrApi, getAllOrderValueApi, verifyOrderApi, checkOrderApi, updateOrderApi, uploadImgApi, backOrderApi, aduitOrderApi, judgeSetting, spaAgressData, merchantInfo, dateBycarNo, activeCodeList, updateActiveCode }
...@@ -73,7 +73,6 @@ const babchInitTemplateApi = params => { ...@@ -73,7 +73,6 @@ const babchInitTemplateApi = params => {
}) })
} }
const exportContractApi = params => { const exportContractApi = params => {
params.method = `scrm.api.equity.service.contract.template.list.export` params.method = `scrm.api.equity.service.contract.template.list.export`
return http({ return http({
...@@ -84,6 +83,27 @@ const exportContractApi = params => { ...@@ -84,6 +83,27 @@ const exportContractApi = params => {
}) })
} }
const getProdContractListApi = params => {
params.method = `scrm.api.equity.service.base.package.list.page`
return http({
url: CUR_BASE_URL,
method: 'POST',
data: params,
sign: true
})
}
//产品列表导出
const exportProdContractApi = params => {
params.method = `scrm.api.equity.service.base.package.export`
return http({
url: CUR_BASE_URL,
method: 'POST',
data: params,
sign: true
})
}
export default { export default {
getContractListApi, getContractListApi,
saveContractTemplateApi, saveContractTemplateApi,
...@@ -92,5 +112,7 @@ export default { ...@@ -92,5 +112,7 @@ export default {
copyTemplateApi, copyTemplateApi,
babchCopyTemplateApi, babchCopyTemplateApi,
babchInitTemplateApi, babchInitTemplateApi,
exportContractApi exportContractApi,
getProdContractListApi,
exportProdContractApi
} }
...@@ -5,7 +5,7 @@ const getConfigList = params => { ...@@ -5,7 +5,7 @@ const getConfigList = params => {
return http({ return http({
url: 'rop-scrm-equity/router', url: 'rop-scrm-equity/router',
method: 'POST', method: 'POST',
data: params, data: params
}) })
} }
const openConfigs = params => { const openConfigs = params => {
...@@ -14,7 +14,7 @@ const openConfigs = params => { ...@@ -14,7 +14,7 @@ const openConfigs = params => {
url: 'rop-scrm-equity/router', url: 'rop-scrm-equity/router',
method: 'POST', method: 'POST',
data: params, data: params,
returnAll:true returnAll: true
}) })
} }
const closeConfigs = params => { const closeConfigs = params => {
...@@ -23,8 +23,7 @@ const closeConfigs = params => { ...@@ -23,8 +23,7 @@ const closeConfigs = params => {
url: 'rop-scrm-equity/router', url: 'rop-scrm-equity/router',
method: 'POST', method: 'POST',
data: params, data: params,
returnAll:true returnAll: true
}) })
} }
// 跳转后获取配置 // 跳转后获取配置
...@@ -33,7 +32,7 @@ const getConfig = params => { ...@@ -33,7 +32,7 @@ const getConfig = params => {
return http({ return http({
url: 'rop-scrm-equity/router', url: 'rop-scrm-equity/router',
method: 'POST', method: 'POST',
data: params, data: params
}) })
} }
// 配置导出 // 配置导出
...@@ -42,7 +41,7 @@ const exportConfig = params => { ...@@ -42,7 +41,7 @@ const exportConfig = params => {
return http({ return http({
url: 'rop-scrm-equity/router', url: 'rop-scrm-equity/router',
method: 'POST', method: 'POST',
data: params, data: params
}) })
} }
//修改配置 //修改配置
...@@ -52,7 +51,7 @@ const modifyConfig = params => { ...@@ -52,7 +51,7 @@ const modifyConfig = params => {
url: 'rop-scrm-equity/router', url: 'rop-scrm-equity/router',
method: 'POST', method: 'POST',
data: params, data: params,
returnAll:true returnAll: true
}) })
} }
//创建配置 //创建配置
...@@ -62,7 +61,7 @@ const addConfig = params => { ...@@ -62,7 +61,7 @@ const addConfig = params => {
url: 'rop-scrm-equity/router', url: 'rop-scrm-equity/router',
method: 'POST', method: 'POST',
data: params, data: params,
returnAll:true returnAll: true
}) })
} }
//分页获取商户配置 //分页获取商户配置
...@@ -71,7 +70,7 @@ const getStoreConfig = params => { ...@@ -71,7 +70,7 @@ const getStoreConfig = params => {
return http({ return http({
url: 'rop-scrm-equity/router', url: 'rop-scrm-equity/router',
method: 'POST', method: 'POST',
data: params, data: params
}) })
} }
//查询商户配置 //查询商户配置
...@@ -81,7 +80,17 @@ const selStoreConfig = params => { ...@@ -81,7 +80,17 @@ const selStoreConfig = params => {
url: 'rop-scrm-equity/router', url: 'rop-scrm-equity/router',
method: 'POST', method: 'POST',
data: params, data: params,
returnAll:true returnAll: true
})
}
//批量开通销售模式
const batchOpenSaleModeApi = params => {
params.method = `${defaultPath}service.merchant.config.batch.open`
return http({
url: 'rop-scrm-equity/router',
method: 'POST',
data: params
}) })
} }
export default { export default {
...@@ -93,5 +102,6 @@ export default { ...@@ -93,5 +102,6 @@ export default {
modifyConfig, modifyConfig,
getStoreConfig, getStoreConfig,
addConfig, addConfig,
selStoreConfig selStoreConfig,
batchOpenSaleModeApi
} }
export function attachmentToHtml(elem, childrenHtml) {
// JS 语法
// 获取附件元素的数据
const { key = '', name = '' } = elem
// 生成 HTML 代码
const html = `<span data-w-e-type="text" data-key="${key}" data-name="${name}">${name}</span>`
return html
}
export function parseAttachmentHtml(domElem, children, editor) {
const key = domElem.getAttribute('data-key') || ''
const name = domElem.getAttribute('data-name') || ''
// 生成“附件”元素(按照此前约定的数据结构)
const myResume = {
type: 'text',
name,
key,
children: [{ text: '' }]
}
return myResume
}
import { h } from 'snabbdom'
/**
* 渲染“附件”元素到编辑器
* @param elem 附件元素,即上文的 myResume
* @param children 元素子节点,void 元素可忽略
* @param editor 编辑器实例
* @returns vnode 节点(通过 snabbdom.js 的 h 函数生成)
*/
export function renderAttachment(elem, children, editor) {
const { name = '' } = elem
const Vnode = h(
'span',
{
props: { contentEditable: false },
style: { color: '#5f5efb' }
},
// 子节点
[name]
)
return Vnode
}
import { DomEditor } from '@wangeditor/editor'
export function withBreakAndDelete(editor) {
const { isInline, isVoid } = editor
const newEditor = editor
newEditor.isInline = elem => {
const type = DomEditor.getNodeType(elem)
if (type === 'text') return true
return isInline(elem)
}
newEditor.isVoid = elem => {
const type = DomEditor.getNodeType(elem)
if (type === 'text') return true
return isVoid(elem)
}
return newEditor // 返回 newEditor ,重要!!!
}
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
let cfg = require('./conf.js') let cfg = require('./conf.js')
let timeout = 30000 //超时时间 let timeout = 30000 //超时时间
import { Http } from 'glsx-common' import { Http } from 'glsx-common'
export const fetchConfig = function (common) { export const fetchConfig = function(common) {
// console.log(common); // console.log(common);
// console.log(utils); // console.log(utils);
// let params = { moduleName: 'presale', mockUrl: 'https://oss-config.dev.glsx.com.cn/mock/618f5cc91072f92988f05a26/services/config',env:'test', httpOptions: { Headers: { refererurl: location.href }, request: { timeout: 30000 } } } // let params = { moduleName: 'presale', mockUrl: 'https://oss-config.dev.glsx.com.cn/mock/618f5cc91072f92988f05a26/services/config',env:'test', httpOptions: { Headers: { refererurl: location.href }, request: { timeout: 30000 } } }
......
...@@ -4,20 +4,20 @@ ...@@ -4,20 +4,20 @@
<div class="main"> <div class="main">
<div class="edit-bar"> <div class="edit-bar">
<FoldFrame :name="item.title" v-for="item in contentList" :key="item.key"> <FoldFrame :name="item.title" v-for="item in contentList" :key="item.key">
<div v-if="item.type=='img'" class="bar-content"> <div v-if="item.type == 'img'" class="bar-content">
<div v-if="item.key=='electronicSealUrl'" class="input-content"> <div v-if="item.key == 'electronicSealUrl'" class="input-content">
<label class="required-field" for="">服务主体:</label> <label class="required-field" for="">服务主体:</label>
<el-input size="small" type="text" v-model="contentObj.serviceSubject" ></el-input> <el-input size="small" type="text" v-model="contentObj.serviceSubject"></el-input>
</div> </div>
<Upload :required="true" @uploadSuccess="uploadSuccess" @delImage="delImage" class="upload" :name="item.label+':'" :attr="item.key" :url="contentObj[item.key]" :defaultStyle="{width:'208px'}"></Upload> <Upload :required="true" @uploadSuccess="uploadSuccess" @delImage="delImage" class="upload" :name="item.label + ':'" :attr="item.key" :url="contentObj[item.key]" :defaultStyle="{ width: '208px' }"></Upload>
<span class="upload-tip">建议高度:48px</span> <span class="upload-tip">建议高度:48px</span>
</div> </div>
<div v-if="item.type=='richText'" class="bar-content"> <div v-if="item.type == 'richText'" class="bar-content">
<div v-if="item.key=='contractIntroduce'" class="input-content"> <div v-if="item.key == 'contractIntroduce'" class="input-content">
<label class="required-field" for="">合同标题:</label> <label class="required-field" for="">合同标题:</label>
<el-input size="small" type="text" v-model="contentObj.contractTitle"></el-input> <el-input size="small" type="text" v-model="contentObj.contractTitle"></el-input>
</div> </div>
<Editor :required="true" :ref="item.key+'Ref'" :operateList="item.key=='useConditions' ? placeholderList : []" :label="item.label" v-model="contentObj[item.key]"></Editor> <Editor :required="true" :ref="item.key + 'Ref'" :operateList="item.key == 'useConditions' ? placeholderList : []" :label="item.label" v-model="contentObj[item.key]"></Editor>
</div> </div>
</FoldFrame> </FoldFrame>
</div> </div>
...@@ -49,7 +49,7 @@ import Editor from '@/components/Editor' ...@@ -49,7 +49,7 @@ import Editor from '@/components/Editor'
import pdfDialog from '@/views/beforeSale/pdfDialog' import pdfDialog from '@/views/beforeSale/pdfDialog'
export default { export default {
name: 'AddTmpl', name: 'AddTmpl',
components:{ components: {
Editor, Editor,
Upload, Upload,
FoldFrame, FoldFrame,
...@@ -59,8 +59,9 @@ export default { ...@@ -59,8 +59,9 @@ export default {
return { return {
isPdfVisible: false, isPdfVisible: false,
pdfUrl: '', pdfUrl: '',
routerInfo: {},
placeholderList: [], placeholderList: [],
pdfObj :{ pdfObj: {
merchantId: '', merchantId: '',
packageCode: '' packageCode: ''
}, },
...@@ -138,12 +139,13 @@ export default { ...@@ -138,12 +139,13 @@ export default {
label: '电子章图片', label: '电子章图片',
key: 'electronicSealUrl', key: 'electronicSealUrl',
type: 'img' type: 'img'
}, }
] ]
} }
}, },
created(){ created() {
this.routerInfo = JSON.parse(decodeURIComponent(this.$route.params.id))
}, },
mounted() { mounted() {
...@@ -152,49 +154,59 @@ export default { ...@@ -152,49 +154,59 @@ export default {
methods: { methods: {
getContractDetail() { getContractDetail() {
this.$apis.contractManager.getContractDetailApi({id: this.$route.params.id}).then(res => { this.$apis.contractManager.getContractDetailApi({ id: this.routerInfo.id }).then(res => {
if(res && res.templateConfig){ if (res && res.templateConfig) {
this.placeholderList = res.placeholderList this.placeholderList = res.placeholderList
for(const key in this.contentObj){ for (const key in this.contentObj) {
if (key != 'useConditions') {
this.contentObj[key] = res.templateConfig[key] this.contentObj[key] = res.templateConfig[key]
} else {
for (var i = 0; i < res.placeholderList.length; i++) {
var placeholder = res.placeholderList[i]
let targetStr = `<span data-w-e-type="text" data-key="${placeholder.key}" data-name="${placeholder.name}">${placeholder.name}</span>`
res.templateConfig.useConditions = res.templateConfig.useConditions.replace(new RegExp(placeholder.key, 'g'), targetStr)
}
this.contentObj.useConditions = res.templateConfig.useConditions
}
} }
this.pdfObj = { this.pdfObj = {
merchantId: res.templateConfig.merchantId, merchantId: res.templateConfig.merchantId,
packageCode: res.templateConfig.packageCode packageCode: res.templateConfig.packageCode
}, }
this.$nextTick(()=>{
this.$refs.useConditionsRef[0].replaceText()
})
} }
}) })
}, },
handelCancel(){ handelCancel() {
this.$router.push('/ContractManager/index') this.$router.push('/ContractManager/index')
}, },
getParams(){ getParams() {
let params = this.$common.utils.deepClone(this.contentObj) let params = this.$common.utils.deepClone(this.contentObj)
let errorTip = ''; let errorTip = ''
params.useConditions = params.useConditions?.replace(/<span.*?class.*?keyname="(.*?)".*?<\/span>/g,'$1') params.useConditions = params.useConditions?.replace(/<span.*?data-w-e-type.*?data-key="(.*?)".*?<\/span>/g, '$1')
for(const key in params){ for (const key in params) {
if(key!='id' && !params[key]){ if (key != 'id' && !params[key]) {
if(key == 'electronicSealUrl' || key == 'logoUrl'){ if (key == 'electronicSealUrl' || key == 'logoUrl') {
errorTip = `请上传${key == 'logoUrl' ? 'Logo图': '电子章图片'}` errorTip = `请上传${key == 'logoUrl' ? 'Logo图' : '电子章图片'}`
}else{ } else {
errorTip = `${errorTipObj[key]}不能为空` errorTip = `${errorTipObj[key]}不能为空`
} }
} }
} }
if(errorTip) return {status: -1, errorTip} if (errorTip) return { status: -1, errorTip }
return params return params
}, },
commitTemplate(type){ commitTemplate(type) {
const params = this.getParams() const params = this.getParams()
if(params.status == -1) return this.$message.error(params.errorTip) if (params.status == -1) return this.$message.error(params.errorTip)
this.$apis.contractManager.saveContractTemplateApi({...params}).then(res => { const _targetParam = {
if(res){ ...params
if(type=='preview'){ }
if (this.routerInfo.skuId) _targetParam.skuId = this.routerInfo.skuId
this.$apis.contractManager.saveContractTemplateApi(_targetParam).then(res => {
if (res) {
if (type == 'preview') {
this.handlePdf() this.handlePdf()
}else{ } else {
this.$message.success('编辑成功') this.$message.success('编辑成功')
this.$router.push('/ContractManager/index') this.$router.push('/ContractManager/index')
} }
...@@ -211,27 +223,32 @@ export default { ...@@ -211,27 +223,32 @@ export default {
spinner: 'el-icon-loading', spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.3)' background: 'rgba(0, 0, 0, 0.3)'
}) })
this.$apis.contractManager.printContractApi({ packageCode : this.pdfObj.packageCode , merchantId: this.pdfObj.merchantId }).then(res => { const params = {
packageCode: this.pdfObj.packageCode,
baseFlag: this.routerInfo.skuId ? 1 : 0
}
if (!this.routerInfo.skuId) params.merchantId = this.pdfObj.merchantId
this.$apis.contractManager.printContractApi(params).then(res => {
this.pdfUrl = res this.pdfUrl = res
this.handlePdfClose() this.handlePdfClose()
loading.close() loading.close()
}) })
}, },
uploadSuccess(e){ uploadSuccess(e) {
this.contentObj[e.attr] = e.url this.contentObj[e.attr] = e.url
}, },
delImage(e){ delImage(e) {
this.contentObj[e.attr] = '' this.contentObj[e.attr] = ''
}, }
} }
} }
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.container{ .container {
background-color: #fff; background-color: #fff;
margin-bottom: 60px; margin-bottom: 60px;
.footer-btn-wrap{ .footer-btn-wrap {
width: 100%; width: 100%;
height: 60px; height: 60px;
line-height: 60px; line-height: 60px;
...@@ -243,15 +260,15 @@ export default { ...@@ -243,15 +260,15 @@ export default {
right: 0; right: 0;
box-shadow: 0 -2px 10px 0 #7a7a7a33; box-shadow: 0 -2px 10px 0 #7a7a7a33;
} }
.footer-btn{ .footer-btn {
text-align: center; text-align: center;
margin-top: 16px; margin-top: 16px;
} }
.input-content{ .input-content {
display: flex; display: flex;
align-items: center; align-items: center;
margin-bottom: 24px; margin-bottom: 24px;
label{ label {
flex-shrink: 0; flex-shrink: 0;
width: 154px; width: 154px;
white-space: nowrap; white-space: nowrap;
...@@ -260,24 +277,24 @@ export default { ...@@ -260,24 +277,24 @@ export default {
font-size: 14px; font-size: 14px;
color: #333333; color: #333333;
} }
/deep/ .el-input__inner{ /deep/ .el-input__inner {
width: 342px; width: 342px;
} }
} }
.main{ .main {
padding: 10px 20px 32px; padding: 10px 20px 32px;
.edit-bar{ .edit-bar {
.bar-content{ .bar-content {
background: #F9F9F9; background: #f9f9f9;
padding: 20px; padding: 20px;
margin-bottom: 10px; margin-bottom: 10px;
/deep/ .editor{ /deep/ .editor {
width: 935px!important; width: 935px !important;
} }
.upload{ .upload {
display: inline-block; display: inline-block;
} }
.upload-tip{ .upload-tip {
height: 20px; height: 20px;
font-weight: 400; font-weight: 400;
font-size: 14px; font-size: 14px;
...@@ -290,4 +307,3 @@ export default { ...@@ -290,4 +307,3 @@ export default {
} }
} }
</style> </style>
\ No newline at end of file \ No newline at end of file
<!-- 权益订单 --> <!-- 权益订单 -->
<template> <template>
<div> <div>
<report :key="comKey" :renewDisable="orderStatus!=0" @toSearchOrderDetail="toSearchOrderDetail" ref="reportRef" :isGH="routeInfo.isGH" :pageType="pageType" :editForm.sync="editForm"></report> <report :key="comKey" :renewDisable="orderStatus != 0" @toSearchOrderDetail="toSearchOrderDetail" ref="reportRef" :isGH="routeInfo.isGH" :pageType="pageType" :editForm.sync="editForm"></report>
<repair :renewDisable="orderStatus!=0" ref="repairRef" @changeObjectType="changeObjectType" :isGH="routeInfo.isGH" :pageType="pageType" :serviceItemsList.sync="serviceItemsList" :totalPrice.sync="totalPrice" :accountForm.sync="accountForm"></repair> <repair :renewDisable="orderStatus != 0" ref="repairRef" :isXB="true" @changeObjectType="changeObjectType" :isGH="routeInfo.isGH" :pageType="pageType" :serviceItemsList.sync="serviceItemsList" :totalPrice.sync="totalPrice" :accountForm.sync="accountForm"></repair>
<material :renewDisable="orderStatus!=0" :isXB="true" ref="materialRef" :pageType="pageType" :materialForm.sync="materialForm"></material> <material :renewDisable="orderStatus != 0" :isXB="true" ref="materialRef" :pageType="pageType" :materialForm.sync="materialForm"></material>
<!-- 案件说明 --> <!-- 案件说明 -->
<caseDesc :supplementList="supplementList"></caseDesc> <caseDesc :supplementList="supplementList"></caseDesc>
<!-- 定损记录 --> <!-- 定损记录 -->
...@@ -153,7 +153,7 @@ export default { ...@@ -153,7 +153,7 @@ export default {
}, },
computed: { computed: {
totalPrice() { totalPrice() {
let total = this.serviceItemsList.reduce(function (prev, cur) { let total = this.serviceItemsList.reduce(function(prev, cur) {
return prev + +(cur.approveAmount * 100).toFixed(0) return prev + +(cur.approveAmount * 100).toFixed(0)
}, 0) }, 0)
return total / 100 return total / 100
...@@ -200,18 +200,18 @@ export default { ...@@ -200,18 +200,18 @@ export default {
// 以下是文件数据 // 以下是文件数据
res.files.forEach(item => { res.files.forEach(item => {
let obj = { url: item.fileUrl, fileType: item.fileType, name: item.fileName, progress: 100, mark: item.mark, fileCode: item.fileCode } let obj = { url: item.fileUrl, fileType: item.fileType, name: item.fileName, progress: 100, mark: item.mark, fileCode: item.fileCode }
if (item.fileCode == '1'&&item.fileUrl) { if (item.fileCode == '1' && item.fileUrl) {
if (this.materialForm.idCard.length === 0) { if (this.materialForm.idCard.length === 0) {
this.materialForm.idCard.push(obj) this.materialForm.idCard.push(obj)
} else { } else {
this.materialForm.idCardBack.push(obj) this.materialForm.idCardBack.push(obj)
} }
} else if (item.fileCode == '31'&&item.fileUrl) { } else if (item.fileCode == '31' && item.fileUrl) {
this.materialForm.billInfo.push(obj) this.materialForm.billInfo.push(obj)
} else if (item.fileCode == '4'&&item.fileUrl) { } else if (item.fileCode == '4' && item.fileUrl) {
this.materialForm.otherInfo.push(obj) this.materialForm.otherInfo.push(obj)
} }
console.log(this.materialForm); console.log(this.materialForm)
}) })
// 案件说明 // 案件说明
res.supplementList.forEach(el => { res.supplementList.forEach(el => {
...@@ -343,10 +343,15 @@ export default { ...@@ -343,10 +343,15 @@ export default {
} }
params.approveAmounts = '' params.approveAmounts = ''
let tagetObj = {} let tagetObj = {}
let lossAssessmentTarget = {}
this.serviceItemsList.forEach(item => { this.serviceItemsList.forEach(item => {
tagetObj[item.serviceItemCode] = item.approveAmount tagetObj[item.serviceItemCode] = item.approveAmount
if (item.lossAssessmentFlag) {
lossAssessmentTarget[item.serviceItemCode] = item.lossAssessmentAmount
}
}) })
params.approveAmounts = JSON.stringify(tagetObj) params.approveAmounts = JSON.stringify(tagetObj)
params.lossAssessmentAmounts = JSON.stringify(lossAssessmentTarget)
delete params.reimbursementAddress delete params.reimbursementAddress
params.fileList = [] params.fileList = []
for (let key in this.materialForm) { for (let key in this.materialForm) {
...@@ -402,8 +407,8 @@ export default { ...@@ -402,8 +407,8 @@ export default {
this.renewalAudit({ approveAmounts: JSON.stringify(sc_obg) }, 4) this.renewalAudit({ approveAmounts: JSON.stringify(sc_obg) }, 4)
}, },
renewalAudit(params, operation) { renewalAudit(params, operation) {
const {equityOrderDetail} = this.detailInfo const { equityOrderDetail } = this.detailInfo
if(equityOrderDetail&&equityOrderDetail.vehicle){ if (equityOrderDetail && equityOrderDetail.vehicle) {
params.carNumber = equityOrderDetail.vehicle.licensePlate params.carNumber = equityOrderDetail.vehicle.licensePlate
} }
this.$apis.claims.renewalAudit({ ...this.editForm, operation, id: this.routeInfo.orderId, ...this.accountForm, ...params }).then(res => { this.$apis.claims.renewalAudit({ ...this.editForm, operation, id: this.routeInfo.orderId, ...this.accountForm, ...params }).then(res => {
......
...@@ -863,7 +863,8 @@ export default { ...@@ -863,7 +863,8 @@ export default {
let paraFormat = { let paraFormat = {
addOrEdit, addOrEdit,
contractNo: addOrEdit == 1 ? -1 : row.contractNo, contractNo: addOrEdit == 1 ? -1 : row.contractNo,
isSuper: this.userInfo.admin isSuper: this.userInfo.admin,
successDate: row?.successDate ? dayjs(row.successDate).format('YYYY-MM-DD HH:mm:ss') : ''
} }
const urlpara = encodeURIComponent(JSON.stringify(paraFormat)) const urlpara = encodeURIComponent(JSON.stringify(paraFormat))
addOrEdit == 1 ? this.$router.push('/beforeSale/editEquity/' + urlpara) : this.$router.push('/beforeSale/editEquity/' + urlpara) addOrEdit == 1 ? this.$router.push('/beforeSale/editEquity/' + urlpara) : this.$router.push('/beforeSale/editEquity/' + urlpara)
......
...@@ -28,8 +28,14 @@ ...@@ -28,8 +28,14 @@
</el-checkbox-group> </el-checkbox-group>
</div> </div>
<div class="unit-price" :class="[{ nopt20: item.serviceItemCode == 'SC0006' || item.serviceItemCode == 'SC0003' }]"> <div class="unit-price" :class="[{ nopt20: item.serviceItemCode == 'SC0006' || item.serviceItemCode == 'SC0003' }]">
<div>
<label class="required" for="">预估损失金额/元:</label> <label class="required" for="">预估损失金额/元:</label>
<el-input maxlength="10" @input="validPrice($event, index)" @blur="changePrice($event, index)" placeholder="请输入预估损失金额" v-model="item.applyAmount"></el-input> <el-input maxlength="10" @input="validPrice($event, index, 'applyAmount')" @blur="changePrice($event, index, 'applyAmount')" placeholder="请输入预估损失金额" v-model="item.applyAmount"></el-input>
</div>
<div v-if="item.lossAssessmentFlag" style="margin-top: 10px;">
<label class="required" for="">保险公司定损金额/元:</label>
<el-input :disabled="!item.applyAmount" maxlength="10" @input="validPrice($event, index, 'lossAssessmentAmount')" @blur="changePrice($event, index, 'lossAssessmentAmount')" placeholder="请输入保险定损金额" v-model="item.lossAssessmentAmount"></el-input>
</div>
</div> </div>
</div> </div>
<div class="lump-sum"> <div class="lump-sum">
...@@ -242,8 +248,8 @@ export default { ...@@ -242,8 +248,8 @@ export default {
const Item = this.editFormData.find(item => item.name === key) const Item = this.editFormData.find(item => item.name === key)
this.$set(Item.customPickerOptions, 'selectableRange', limitTime) this.$set(Item.customPickerOptions, 'selectableRange', limitTime)
}, },
validPrice(e, id) { validPrice(e, id, key) {
let checkPlan = '' + this.itemList[id].applyAmount let checkPlan = '' + this.itemList[id][key]
checkPlan = checkPlan checkPlan = checkPlan
.replace(/[^\d.]/g, '') .replace(/[^\d.]/g, '')
.replace(/\.{2,}/g, '.') .replace(/\.{2,}/g, '.')
...@@ -256,23 +262,23 @@ export default { ...@@ -256,23 +262,23 @@ export default {
} else if (checkPlan.indexOf('.') >= 0) { } else if (checkPlan.indexOf('.') >= 0) {
checkPlan = checkPlan.replace(/^()*(\d+)\.(\d\d).*$/, '$1$2.$3') // 只能输入两个小数 checkPlan = checkPlan.replace(/^()*(\d+)\.(\d\d).*$/, '$1$2.$3') // 只能输入两个小数
} }
this.$set(this.itemList[id], 'applyAmount', checkPlan) this.$set(this.itemList[id], key, checkPlan)
this.getTotal() this.getTotal()
}, },
changePrice(e, id) { changePrice(e, id, key) {
if (!e.target.value) return if (!e.target.value) return
const len = e.target.value.length const len = e.target.value.length
let lastStr = e.target.value.charAt(len - 1) let lastStr = e.target.value.charAt(len - 1)
if (lastStr === '.') { if (lastStr === '.') {
this.$set(this.itemList[id], 'applyAmount', e.target.value.substr(0, len - 1)) this.$set(this.itemList[id], key, e.target.value.substr(0, len - 1))
} }
const minPrice = 1 const minPrice = 1
if (Number(e.target.value) < minPrice) { if (Number(e.target.value) < minPrice) {
this.$set(this.itemList[id], 'applyAmount', 1) this.$set(this.itemList[id], key, 1)
} }
const maxPrice = 200000 const maxPrice = 200000
if (Number(e.target.value) > maxPrice) { if (Number(e.target.value) > maxPrice) {
this.$set(this.itemList[id], 'applyAmount', maxPrice) this.$set(this.itemList[id], key, maxPrice)
} }
this.getTotal() this.getTotal()
}, },
...@@ -327,11 +333,12 @@ export default { ...@@ -327,11 +333,12 @@ export default {
.unit-price { .unit-price {
background: #f9f9f9; background: #f9f9f9;
padding: 20px; padding: 20px;
display: flex; // display: flex;
flex-wrap: nowrap; flex-wrap: nowrap;
margin-bottom: 10px; margin-bottom: 10px;
.required { .required {
width: 154px; width: 154px;
display: inline-block;
text-align: right; text-align: right;
font-weight: 400; font-weight: 400;
font-size: 14px; font-size: 14px;
......
...@@ -30,6 +30,10 @@ ...@@ -30,6 +30,10 @@
<div class="ms_lab">预估损失金额/元:</div> <div class="ms_lab">预估损失金额/元:</div>
<el-input @input="validPrice($event, index, 'applyAmount')" @blur="changePrice($event, index, 'applyAmount')" v-model="item.applyAmount" size="mini" class="w432" maxlength="10"></el-input> <el-input @input="validPrice($event, index, 'applyAmount')" @blur="changePrice($event, index, 'applyAmount')" v-model="item.applyAmount" size="mini" class="w432" maxlength="10"></el-input>
</div> </div>
<div v-if="item.lossAssessmentFlag" class="ma20 ms flex_sc">
<div class="ms_lab">保险公司定损金额/元:</div>
<el-input @input="validPrice($event, index, 'lossAssessmentAmount')" @blur="changePrice($event, index, 'lossAssessmentAmount')" v-model="item.lossAssessmentAmount" size="mini" class="w432" maxlength="10"></el-input>
</div>
<div class="ms flex_sc ma20"> <div class="ms flex_sc ma20">
<div class="ms_lab">定损批准金额/元:</div> <div class="ms_lab">定损批准金额/元:</div>
<el-input @input="validPrice($event, index, 'approveAmount')" @blur="changePrice($event, index, 'approveAmount')" v-model="item.approveAmount" size="mini" class="w432" maxlength="10"></el-input> <el-input @input="validPrice($event, index, 'approveAmount')" @blur="changePrice($event, index, 'approveAmount')" v-model="item.approveAmount" size="mini" class="w432" maxlength="10"></el-input>
...@@ -415,7 +419,7 @@ export default { ...@@ -415,7 +419,7 @@ export default {
} }
} }
} }
.ms_txt{ .ms_txt {
font-size: 14px; font-size: 14px;
font-weight: 400; font-weight: 400;
color: #666666; color: #666666;
......
...@@ -26,8 +26,12 @@ ...@@ -26,8 +26,12 @@
<div class="service-item" v-for="(item, index) in serviceItemsList" :key="item.serviceItemCode"> <div class="service-item" v-for="(item, index) in serviceItemsList" :key="item.serviceItemCode">
<p class="name">{{ item.serviceItemName }}</p> <p class="name">{{ item.serviceItemName }}</p>
<div class="price-wrap"> <div class="price-wrap">
<label for="">定损批准金额:</label> <label class="label" for="">定损批准金额:</label>
<el-input :disabled="pageType == 2 || renewDisable" maxlength="10" @input="validPrice($event, index)" @blur="changePrice($event, index)" placeholder="请选择定损批准金额" v-model="item.approveAmount"></el-input> <el-input :disabled="pageType == 2 || renewDisable" maxlength="10" @input="validPrice($event, index, 'approveAmount')" @blur="changePrice($event, index, 'approveAmount')" placeholder="请输入" v-model="item.approveAmount"></el-input>
</div>
<div v-if="!isXB && item.lossAssessmentFlag" class="price-wrap">
<label class="label" for="">保险公司定损金额:</label>
<el-input :disabled="pageType == 2 || renewDisable || !item.approveAmount" maxlength="10" @input="validPrice($event, index, 'lossAssessmentAmount')" @blur="changePrice($event, index, 'lossAssessmentAmount')" placeholder="请输入" v-model="item.lossAssessmentAmount"></el-input>
</div> </div>
</div> </div>
</template> </template>
...@@ -69,6 +73,7 @@ export default { ...@@ -69,6 +73,7 @@ export default {
serviceItemsList: Array, serviceItemsList: Array,
totalPrice: Number, totalPrice: Number,
isGH: Boolean, isGH: Boolean,
isXB: Boolean,
pageType: { pageType: {
type: Number, type: Number,
default: 1 // 1.新增 2.查看 3.重新提交 4.去处理 default: 1 // 1.新增 2.查看 3.重新提交 4.去处理
...@@ -305,8 +310,8 @@ export default { ...@@ -305,8 +310,8 @@ export default {
IDCardTypeList.optionList = res.cardType IDCardTypeList.optionList = res.cardType
}) })
}, },
validPrice(e, id) { validPrice(e, id, key) {
let checkPlan = '' + this.serviceItemsList[id].approveAmount let checkPlan = '' + this.serviceItemsList[id][key]
checkPlan = checkPlan checkPlan = checkPlan
.replace(/[^\d.]/g, '') .replace(/[^\d.]/g, '')
.replace(/\.{2,}/g, '.') .replace(/\.{2,}/g, '.')
...@@ -319,22 +324,22 @@ export default { ...@@ -319,22 +324,22 @@ export default {
} else if (checkPlan.indexOf('.') >= 0) { } else if (checkPlan.indexOf('.') >= 0) {
checkPlan = checkPlan.replace(/^()*(\d+)\.(\d\d).*$/, '$1$2.$3') // 只能输入两个小数 checkPlan = checkPlan.replace(/^()*(\d+)\.(\d\d).*$/, '$1$2.$3') // 只能输入两个小数
} }
this.$set(this.serviceItemsList[id], 'approveAmount', checkPlan) this.$set(this.serviceItemsList[id], key, checkPlan)
}, },
changePrice(e, id) { changePrice(e, id, key) {
if (!e.target.value) return if (!e.target.value) return
const len = e.target.value.length const len = e.target.value.length
let lastStr = e.target.value.charAt(len - 1) let lastStr = e.target.value.charAt(len - 1)
if (lastStr === '.') { if (lastStr === '.') {
this.$set(this.serviceItemsList[id], 'approveAmount', e.target.value.substr(0, len - 1)) this.$set(this.serviceItemsList[id], key, e.target.value.substr(0, len - 1))
} }
const minPrice = 1 const minPrice = 1
if (Number(e.target.value) < minPrice) { if (Number(e.target.value) < minPrice) {
this.$set(this.serviceItemsList[id], 'approveAmount', 1) this.$set(this.serviceItemsList[id], key, 1)
} }
const maxPrice = 2000000 const maxPrice = 2000000
if (Number(e.target.value) > maxPrice) { if (Number(e.target.value) > maxPrice) {
this.$set(this.serviceItemsList[id], 'approveAmount', maxPrice) this.$set(this.serviceItemsList[id], key, maxPrice)
} }
} }
} }
...@@ -400,7 +405,8 @@ export default { ...@@ -400,7 +405,8 @@ export default {
height: 16px; height: 16px;
} }
.service-item { .service-item {
width: 264px; width: 294px;
box-sizing: border-box;
padding: 10px; padding: 10px;
background: #ffffff; background: #ffffff;
border-radius: 4px; border-radius: 4px;
...@@ -409,17 +415,25 @@ export default { ...@@ -409,17 +415,25 @@ export default {
margin-bottom: 20px; margin-bottom: 20px;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
.name { .name {
font-weight: 600; font-weight: 600;
flex: 1; height: 20px;
margin-bottom: 16px; line-height: 20px;
} }
.price-wrap { .price-wrap {
&:first-child {
margin-top: 0;
}
margin-top: 10px;
display: flex; display: flex;
align-items: center; align-items: baseline;
flex: 1; flex: 1;
label { label {
white-space: nowrap; white-space: nowrap;
display: inline-block;
width: 130px;
flex-shrink: 0;
} }
/deep/ .el-input__inner { /deep/ .el-input__inner {
height: 32px; height: 32px;
......
...@@ -33,6 +33,10 @@ ...@@ -33,6 +33,10 @@
<span>预估损失金额/元:</span> <span>预估损失金额/元:</span>
<span class="price">{{ item.applyAmount || 0 }}</span> <span class="price">{{ item.applyAmount || 0 }}</span>
</div> </div>
<div v-if="item.lossAssessmentFlag" class="ms">
<span>保险公司定损金额/元:</span>
<span class="price">{{ item.lossAssessmentAmount || 0 }}</span>
</div>
<div class="ms"> <div class="ms">
<span>定损批准金额:</span> <span>定损批准金额:</span>
<span class="price">{{ item.approveAmount || 0 }}</span> <span class="price">{{ item.approveAmount || 0 }}</span>
...@@ -561,7 +565,7 @@ export default { ...@@ -561,7 +565,7 @@ export default {
.text_wrap { .text_wrap {
white-space: pre-wrap !important; white-space: pre-wrap !important;
} }
.ms_txt{ .ms_txt {
font-size: 14px; font-size: 14px;
font-weight: 400; font-weight: 400;
color: #666666; color: #666666;
......
...@@ -282,6 +282,7 @@ export default { ...@@ -282,6 +282,7 @@ export default {
res.itemsList.map(item => { res.itemsList.map(item => {
item.applyAmount = item.applyAmount ? (item.applyAmount / 100).toFixed(2) : item.applyAmount item.applyAmount = item.applyAmount ? (item.applyAmount / 100).toFixed(2) : item.applyAmount
item.approveAmount = item.approveAmount ? (item.approveAmount / 100).toFixed(2) : item.approveAmount item.approveAmount = item.approveAmount ? (item.approveAmount / 100).toFixed(2) : item.approveAmount
item.lossAssessmentAmount = item.lossAssessmentAmount ? (item.lossAssessmentAmount / 100).toFixed(2) : item.lossAssessmentAmount
item.lossTypeList = [] item.lossTypeList = []
if (item.serviceItemCode == 'SC0006' && item.lossType) { if (item.serviceItemCode == 'SC0006' && item.lossType) {
item.lossTypeList = item.lossType.split(',') item.lossTypeList = item.lossType.split(',')
...@@ -404,6 +405,8 @@ export default { ...@@ -404,6 +405,8 @@ export default {
// 通过订单 // 通过订单
toPassOrder() { toPassOrder() {
this.isSave = false this.isSave = false
const _target = this.itemList?.find(item => item.applyAmount && item.lossAssessmentFlag && !item.lossAssessmentAmount)
if(_target) return this.$message.error(`请输入${_target.serviceItemName}的保险公司定损金额`)
if (this.orderMsg.status == 12 || this.orderMsg.status == 2) { if (this.orderMsg.status == 12 || this.orderMsg.status == 2) {
const isPass = this.verifyImages(this.claimsAttachmentConfigs) const isPass = this.verifyImages(this.claimsAttachmentConfigs)
if (!isPass) { if (!isPass) {
...@@ -737,6 +740,7 @@ export default { ...@@ -737,6 +740,7 @@ export default {
let contractNo = `itemsList[${index}].contractNo` let contractNo = `itemsList[${index}].contractNo`
let approveAmount = `itemsList[${index}].approveAmount` let approveAmount = `itemsList[${index}].approveAmount`
let applyAmount = `itemsList[${index}].applyAmount` let applyAmount = `itemsList[${index}].applyAmount`
let lossAssessmentAmount = `itemsList[${index}].lossAssessmentAmount`
let claimsId = `itemsList[${index}].claimsId` let claimsId = `itemsList[${index}].claimsId`
let lossType = `itemsList[${index}].lossType` let lossType = `itemsList[${index}].lossType`
let temp = { let temp = {
...@@ -747,6 +751,7 @@ export default { ...@@ -747,6 +751,7 @@ export default {
[contractNo]: this.repotData.contractNo, [contractNo]: this.repotData.contractNo,
[approveAmount]: item.approveAmount ? (Number(item.approveAmount) * 10 * 10).toFixed(0) : 0, [approveAmount]: item.approveAmount ? (Number(item.approveAmount) * 10 * 10).toFixed(0) : 0,
[applyAmount]: item.applyAmount ? (Number(item.applyAmount) * 10 * 10).toFixed(0) : 0, [applyAmount]: item.applyAmount ? (Number(item.applyAmount) * 10 * 10).toFixed(0) : 0,
[lossAssessmentAmount]: item.lossAssessmentAmount ? (Number(item.lossAssessmentAmount) * 10 * 10).toFixed(0) : 0,
[claimsId]: this.orderMsg.id, [claimsId]: this.orderMsg.id,
[lossType]: item.serviceItemCode == 'SC0006' ? item.lossTypeList.join(',') : item.lossType [lossType]: item.serviceItemCode == 'SC0006' ? item.lossTypeList.join(',') : item.lossType
} }
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
<span>核赔不通过:{{ noPassMap[reasonForFailureCode] }},{{ reasonForFailure }}</span> <span>核赔不通过:{{ noPassMap[reasonForFailureCode] }},{{ reasonForFailure }}</span>
</div> </div>
<report @toSearchOrderDetail="toSearchOrderDetail" ref="reportRef" :isGH="routeInfo.isGH" :pageType="pageType" :editForm.sync="editForm"></report> <report @toSearchOrderDetail="toSearchOrderDetail" ref="reportRef" :isGH="routeInfo.isGH" :pageType="pageType" :editForm.sync="editForm"></report>
<!-- 维修信息 -->
<repair ref="repairRef" @changeObjectType="changeObjectType" :isGH="routeInfo.isGH" :pageType="pageType" :serviceItemsList.sync="serviceItemsList" :totalPrice.sync="totalPrice" :accountForm.sync="accountForm"></repair> <repair ref="repairRef" @changeObjectType="changeObjectType" :isGH="routeInfo.isGH" :pageType="pageType" :serviceItemsList.sync="serviceItemsList" :totalPrice.sync="totalPrice" :accountForm.sync="accountForm"></repair>
<material ref="materialRef" :pageType="pageType" :materialForm.sync="materialForm"></material> <material ref="materialRef" :pageType="pageType" :materialForm.sync="materialForm"></material>
<wraning :isWatchOrder="isWatchOrder" @getWarningData="getWarningData" v-if="accountMatchResultList.length && detailOrderStatus != 2" :list="accountMatchResultList"></wraning> <wraning :isWatchOrder="isWatchOrder" @getWarningData="getWarningData" v-if="accountMatchResultList.length && detailOrderStatus != 2" :list="accountMatchResultList"></wraning>
...@@ -182,7 +183,7 @@ export default { ...@@ -182,7 +183,7 @@ export default {
}, },
computed: { computed: {
totalPrice() { totalPrice() {
let total = this.serviceItemsList.reduce(function (prev, cur) { let total = this.serviceItemsList.reduce(function(prev, cur) {
return prev + +(cur.approveAmount * 100).toFixed(0) return prev + +(cur.approveAmount * 100).toFixed(0)
}, 0) }, 0)
return total / 100 return total / 100
...@@ -213,7 +214,7 @@ export default { ...@@ -213,7 +214,7 @@ export default {
imgFlag = true imgFlag = true
curImgIndex = index curImgIndex = index
} }
if (el.accountVerifyImagesList&&el.accountVerifyImagesList.length) { if (el.accountVerifyImagesList && el.accountVerifyImagesList.length) {
el.accountVerifyImagesList.forEach((k, i) => { el.accountVerifyImagesList.forEach((k, i) => {
if (!k.verifyImage) { if (!k.verifyImage) {
imgFlag = true imgFlag = true
...@@ -248,10 +249,15 @@ export default { ...@@ -248,10 +249,15 @@ export default {
} }
params.approveAmounts = '' params.approveAmounts = ''
let tagetObj = {} let tagetObj = {}
let lossAssessmentTarget = {}
this.serviceItemsList.forEach(item => { this.serviceItemsList.forEach(item => {
tagetObj[item.serviceItemCode] = item.approveAmount tagetObj[item.serviceItemCode] = item.approveAmount
if (item.lossAssessmentFlag) {
lossAssessmentTarget[item.serviceItemCode] = item.lossAssessmentAmount
}
}) })
params.approveAmounts = JSON.stringify(tagetObj) params.approveAmounts = JSON.stringify(tagetObj)
params.lossAssessmentAmounts = JSON.stringify(lossAssessmentTarget)
delete params.reimbursementAddress delete params.reimbursementAddress
params.fileList = [] params.fileList = []
for (let key in this.materialForm) { for (let key in this.materialForm) {
...@@ -283,20 +289,27 @@ export default { ...@@ -283,20 +289,27 @@ export default {
this.showNoPassDialog = true this.showNoPassDialog = true
this.noPass_operation = operation this.noPass_operation = operation
} else { } else {
const _target = this.serviceItemsList?.find(item => item.approveAmount && item.lossAssessmentFlag && !item.lossAssessmentAmount)
if (_target) return this.$message.error(`请输入${_target.serviceItemName}的保险公司定损金额`)
const allEmpty = this.serviceItemsList?.find(item => item.approveAmount)
if (!allEmpty) return this.$message.error(`请至少输入一项定损批准金额`)
const _approveTarget = this.serviceItemsList?.find(item => !item.approveAmount && item.lossAssessmentFlag && item.lossAssessmentAmount)
if (_approveTarget) return this.$message.error(`请输入${_approveTarget.serviceItemName}的定损批准金额`)
this.toCheckOrder(operation) this.toCheckOrder(operation)
} }
}, },
toCheckOrder(operation, addQuery = {}) { toCheckOrder(operation, addQuery = {}) {
let claimsQuery = {},_accountMatchResultList = [] let claimsQuery = {},
_accountMatchResultList = []
claimsQuery = this.handlerClaimsQueryForCheck() claimsQuery = this.handlerClaimsQueryForCheck()
if (operation == 20) { if (operation == 20) {
const flag = this.verifyWarningImage() const flag = this.verifyWarningImage()
if (!flag) return if (!flag) return
} }
if(this.queryList&&this.queryList.length>0){ if (this.queryList && this.queryList.length > 0) {
const _temArr = JSON.stringify(this.queryList) const _temArr = JSON.stringify(this.queryList)
_accountMatchResultList = JSON.parse(_temArr) _accountMatchResultList = JSON.parse(_temArr)
_accountMatchResultList.forEach(el=>{ _accountMatchResultList.forEach(el => {
delete el.matchType delete el.matchType
}) })
} }
...@@ -333,7 +346,7 @@ export default { ...@@ -333,7 +346,7 @@ export default {
id: el.id, id: el.id,
verifyResultDesc: el.verifyResultDesc, verifyResultDesc: el.verifyResultDesc,
accountVerifyImagesList: el.accountVerifyImagesList, accountVerifyImagesList: el.accountVerifyImagesList,
matchType:el.matchType matchType: el.matchType
} }
arr.push(obj) arr.push(obj)
}) })
...@@ -375,6 +388,8 @@ export default { ...@@ -375,6 +388,8 @@ export default {
} }
if (this.accountForm.accountType !== 1) this.accountForm.accountType = 0 if (this.accountForm.accountType !== 1) this.accountForm.accountType = 0
this.serviceItemsList = serviceItemsList || [] this.serviceItemsList = serviceItemsList || []
console.log(this.serviceItemsList, ' this.serviceItemsList ')
// 以下是文件数据 // 以下是文件数据
res.files.forEach(item => { res.files.forEach(item => {
let obj = { url: item.fileUrl, fileType: item.fileType, name: item.fileName, progress: 100 } let obj = { url: item.fileUrl, fileType: item.fileType, name: item.fileName, progress: 100 }
...@@ -477,15 +492,31 @@ export default { ...@@ -477,15 +492,31 @@ export default {
}) })
if (!valid) return valid if (!valid) return valid
let requirePrice = true let requirePrice = true
let lossAssTipItem = null
let approItem = null
this.serviceItemsList.forEach(item => { this.serviceItemsList.forEach(item => {
if (item.approveAmount > 0) { if (item.approveAmount > 0) {
requirePrice = false requirePrice = false
} }
if (item.approveAmount && item.lossAssessmentFlag && !item.lossAssessmentAmount) {
lossAssTipItem = item
}
if (!item.approveAmount && item.lossAssessmentFlag && item.lossAssessmentAmount) {
approItem = item
}
}) })
if (requirePrice) { if (requirePrice) {
this.$message.error('至少输入一项服务的定损批准金额') this.$message.error('至少输入一项服务的定损批准金额')
return false return false
} }
if (approItem) {
this.$message.error(`请输入${approItem.serviceItemName}的定损批准金额`)
return false
}
if (lossAssTipItem) {
this.$message.error(`请输入${lossAssTipItem.serviceItemName}的保险公司定损金额`)
return false
}
let fileTip = false let fileTip = false
for (let key in this.materialForm) { for (let key in this.materialForm) {
if (this.materialForm[key].length < 1 && !fileTip) { if (this.materialForm[key].length < 1 && !fileTip) {
...@@ -531,10 +562,15 @@ export default { ...@@ -531,10 +562,15 @@ export default {
} }
params.approveAmounts = '' params.approveAmounts = ''
let tagetObj = {} let tagetObj = {}
let lossAssessmentTarget = {}
this.serviceItemsList.forEach(item => { this.serviceItemsList.forEach(item => {
tagetObj[item.serviceItemCode] = item.approveAmount tagetObj[item.serviceItemCode] = item.approveAmount
if (item.lossAssessmentFlag) {
lossAssessmentTarget[item.serviceItemCode] = item.lossAssessmentAmount
}
}) })
params.approveAmounts = JSON.stringify(tagetObj) params.approveAmounts = JSON.stringify(tagetObj)
params.lossAssessmentAmounts = JSON.stringify(lossAssessmentTarget)
delete params.reimbursementAddress delete params.reimbursementAddress
params.fileList = [] params.fileList = []
for (let key in this.materialForm) { for (let key in this.materialForm) {
...@@ -556,14 +592,15 @@ export default { ...@@ -556,14 +592,15 @@ export default {
spinner: 'el-icon-loading', spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.3)' background: 'rgba(0, 0, 0, 0.3)'
}) })
if(!this.routeInfo.isGH){ if (!this.routeInfo.isGH) {
params.equitySource = 2 params.equitySource = 2
} }
console.log(params, 'params')
this.$apis.claims.commitClaimsOrder(params).then(res => { this.$apis.claims.commitClaimsOrder(params).then(res => {
loading.close() loading.close()
if (res) { if (res) {
if (res.accountMatchResultList && res.accountMatchResultList.length) { if (res.accountMatchResultList && res.accountMatchResultList.length) {
res.accountMatchResultList.forEach(el=>{ res.accountMatchResultList.forEach(el => {
el.accountVerifyImagesList = el.accountVerifyImagesList || [] el.accountVerifyImagesList = el.accountVerifyImagesList || []
}) })
this.accountMatchResultList = res.accountMatchResultList || [] this.accountMatchResultList = res.accountMatchResultList || []
......
...@@ -19,6 +19,13 @@ ...@@ -19,6 +19,13 @@
<el-checkbox style="display: block; margin-left: 30px;" v-model="costPrice" @change="checkCostPrice">门店成本</el-checkbox> <el-checkbox style="display: block; margin-left: 30px;" v-model="costPrice" @change="checkCostPrice">门店成本</el-checkbox>
</el-form-item> </el-form-item>
</template> </template>
<div class="sale-mode">
<label class="label" for="">销售模式:</label>
<el-radio-group v-model="saleMode">
<el-radio :label="1">批发销售</el-radio>
<el-radio :label="2">驻店零售</el-radio>
</el-radio-group>
</div>
<template v-if="!showGh"> <template v-if="!showGh">
<el-form-item size="small" label="配置可见产品及产品属性"></el-form-item> <el-form-item size="small" label="配置可见产品及产品属性"></el-form-item>
<el-form-item> <el-form-item>
...@@ -91,7 +98,7 @@ ...@@ -91,7 +98,7 @@
<el-checkbox v-model="carefree">优享版</el-checkbox> <el-checkbox v-model="carefree">优享版</el-checkbox>
</el-form-item> </el-form-item>
<el-form-item v-for="item in newPackageList" :key="item.packageCode"> <el-form-item v-for="item in newPackageList" :key="item.packageCode">
<el-checkbox v-model="item.isChecked">{{item.packageName}}</el-checkbox> <el-checkbox v-model="item.isChecked">{{ item.packageName }}</el-checkbox>
<div> <div>
<el-checkbox v-model="item.cardName" true-label="card" false-label="">卡输入</el-checkbox> <el-checkbox v-model="item.cardName" true-label="card" false-label="">卡输入</el-checkbox>
</div> </div>
...@@ -103,7 +110,6 @@ ...@@ -103,7 +110,6 @@
<el-row slot> <el-row slot>
<el-form :model="searchForm" ref="relate" :inline="true" label-width="90px" class="configDialog"> <el-form :model="searchForm" ref="relate" :inline="true" label-width="90px" class="configDialog">
<el-form-item> <el-form-item>
<el-input placeholder="请输入内容" v-model="searchForm.selectInput" class="input-with-select" size="small"> <el-input placeholder="请输入内容" v-model="searchForm.selectInput" class="input-with-select" size="small">
<el-select v-model="searchForm.select" slot="prepend" placeholder="请选择"> <el-select v-model="searchForm.select" slot="prepend" placeholder="请选择">
<el-option label="商户名称" value="1"></el-option> <el-option label="商户名称" value="1"></el-option>
...@@ -140,6 +146,7 @@ export default { ...@@ -140,6 +146,7 @@ export default {
configTitle:'', configTitle:'',
selectedTable: false, selectedTable: false,
checkPosition: false, checkPosition: false,
saleMode: 1,
tableData: [], tableData: [],
merchantIds: [], merchantIds: [],
selectedList: [], selectedList: [],
...@@ -314,6 +321,7 @@ export default { ...@@ -314,6 +321,7 @@ export default {
} }
this.$apis.openconfig.getConfig(para).then(res => { this.$apis.openconfig.getConfig(para).then(res => {
res = res || {} res = res || {}
this.saleMode = res.saleMode
this.costPrice = res.openCostPrice == 1 this.costPrice = res.openCostPrice == 1
this.storeSelParams = res this.storeSelParams = res
this.id = res.id this.id = res.id
...@@ -447,7 +455,8 @@ export default { ...@@ -447,7 +455,8 @@ export default {
}) })
let targetParams = { let targetParams = {
openCostPrice : this.costPrice ? 1 : 0, openCostPrice : this.costPrice ? 1 : 0,
createDetailRequests: params createDetailRequests: params,
saleMode: this.saleMode
} }
if(this.showGh){ if(this.showGh){
delete targetParams.createDetailRequests delete targetParams.createDetailRequests
...@@ -678,6 +687,27 @@ export default { ...@@ -678,6 +687,27 @@ export default {
} }
} }
.sale-mode {
height: 32px;
line-height: 32px;
display: flex;
align-items: center;
.label {
// width: 154px;
display: inline-block;
font-family: PingFangSC-Regular;
font-weight: 400;
font-size: 14px;
color: #333333;
text-align: right;
&::before {
content: '*';
color: #f56c6c;
margin-right: 4px;
}
}
}
.special-config { .special-config {
margin-bottom: 0 !important; margin-bottom: 0 !important;
} }
......
...@@ -8,6 +8,7 @@ ...@@ -8,6 +8,7 @@
<!-- <el-button size="small" @click="toggleAll">全选</el-button> --> <!-- <el-button size="small" @click="toggleAll">全选</el-button> -->
<!-- <el-checkbox v-model="checkbox" @change="toggleAll" style="margin-left:20px">全选</el-checkbox> --> <!-- <el-checkbox v-model="checkbox" @change="toggleAll" style="margin-left:20px">全选</el-checkbox> -->
<div style="float: right;" class="primary_plain_btn"> <div style="float: right;" class="primary_plain_btn">
<el-button size="small" plain @click="batchOpenSale()">批量开通驻店零售</el-button>
<el-button size="small" plain @click="batchOperation(1)">批量开通</el-button> <el-button size="small" plain @click="batchOperation(1)">批量开通</el-button>
<el-button size="small" @click="batchOperation(2)">批量关闭</el-button> <el-button size="small" @click="batchOperation(2)">批量关闭</el-button>
<el-button size="small" @click="exportTable">导出</el-button> <el-button size="small" @click="exportTable">导出</el-button>
...@@ -150,6 +151,13 @@ export default { ...@@ -150,6 +151,13 @@ export default {
prop: 'merchantId' prop: 'merchantId'
}, },
{ {
label: '销售模式',
prop: 'saleMode',
formatter: cell => {
return cell.saleMode == 1 ? '批发销售' : '驻店零售'
}
},
{
label: '状态', label: '状态',
prop: 'openFlag', prop: 'openFlag',
formatter: cell => { formatter: cell => {
...@@ -259,6 +267,26 @@ export default { ...@@ -259,6 +267,26 @@ export default {
this.searchForm[this.searchSelectObj.idOrName.attr] = this.searchSelectObj.idOrName.value this.searchForm[this.searchSelectObj.idOrName.attr] = this.searchSelectObj.idOrName.value
this.$refs.table.refreshTable() this.$refs.table.refreshTable()
}, },
batchOpenSale(){
const data = this.$refs.table?.mutiSelectArr?.[this.tableParams.mutiSelectName] || []
if(!data?.length) return this.$message.error('请选择需要开通的商户')
this.$confirm('确定批量开通驻店零售吗', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
callback: action => {
if (action == 'confirm') {
const ids = data.map(item => item.id)
this.$apis.openconfig.batchOpenSaleModeApi({ids, saleMode: 2}).then(res => {
if(res){
this.$message.success('操作成功')
this.$refs.table.refreshTable()
}
})
}
}
})
},
// ['开通', '关闭'] // // ['开通', '关闭'] //
batchOperation(status) { batchOperation(status) {
let { configIndexMutiTable } = this.$refs.table.$refs let { configIndexMutiTable } = this.$refs.table.$refs
...@@ -285,8 +313,7 @@ export default { ...@@ -285,8 +313,7 @@ export default {
this.$confirm(content[status], '提示', { this.$confirm(content[status], '提示', {
confirmButtonText: '是', confirmButtonText: '是',
cancelButtonText: '否', cancelButtonText: '否',
type: 'warning', type: 'warning'
center: true
}) })
.then(() => { .then(() => {
let target = 'openConfigs' let target = 'openConfigs'
......
...@@ -5,16 +5,18 @@ ...@@ -5,16 +5,18 @@
<th rowspan="2">规格</th> <th rowspan="2">规格</th>
<th rowspan="2">价格区间(万元)</th> <th rowspan="2">价格区间(万元)</th>
<th rowspan="2">价格系数</th> <th rowspan="2">价格系数</th>
<th colspan="2" v-for="(item, index) in tableData.salePeriodData" :key="index">{{item.servicePeriod}}年版</th> <th colspan="2" v-for="(item, index) in tableData.salePeriodData" :key="index">{{ item.servicePeriod }}年版</th>
</tr> </tr>
<tr> <tr>
<template v-for="(item, index) in tableData.salePeriodData"> <template v-for="(item, index) in tableData.salePeriodData">
<th :key="index">上架成本 <th :key="index">
上架成本
<!-- <el-tooltip class="item" effect="dark" content="提示待运营提供" placement="top"> <!-- <el-tooltip class="item" effect="dark" content="提示待运营提供" placement="top">
<img class="tip" :src="require('@/assets/tip.png')" /> <img class="tip" :src="require('@/assets/tip.png')" />
</el-tooltip> --> </el-tooltip> -->
</th> </th>
<th :key="index">销售成本 <th :key="index">
销售成本
<!-- <el-tooltip class="item" effect="dark" content="提示待运营提供" placement="top"> <!-- <el-tooltip class="item" effect="dark" content="提示待运营提供" placement="top">
<img class="tip" :src="require('@/assets/tip.png')" /> <img class="tip" :src="require('@/assets/tip.png')" />
</el-tooltip> --> </el-tooltip> -->
...@@ -27,7 +29,7 @@ ...@@ -27,7 +29,7 @@
<td>-</td> <td>-</td>
<template v-for="(item, index) in tableData.salePeriodData"> <template v-for="(item, index) in tableData.salePeriodData">
<td :key="index"><el-input :placeholder="placeholder" @input="changePrice($event, item, 'standardShelfCost')" :disabled="disabled" v-model="item.standardShelfCost"></el-input></td> <td :key="index"><el-input :placeholder="placeholder" @input="changePrice($event, item, 'standardShelfCost')" :disabled="disabled" v-model="item.standardShelfCost"></el-input></td>
<td :key="index"> <el-input :placeholder="placeholder" @input="changePrice($event, item, 'standardSalesCost')" :disabled="disabled" v-model="item.standardSalesCost"></el-input></td> <td :key="index"><el-input :placeholder="placeholder" @input="changePrice($event, item, 'standardSalesCost')" :disabled="disabled" v-model="item.standardSalesCost"></el-input></td>
</template> </template>
</tr> </tr>
<tr v-for="(item, index) in tableData.gradeConfigList" :key="index"> <tr v-for="(item, index) in tableData.gradeConfigList" :key="index">
...@@ -38,36 +40,36 @@ ...@@ -38,36 +40,36 @@
</td> </td>
<td><el-input :placeholder="placeholder" @input="changePrice($event, item, 'priceCoefficient')" :disabled="disabled" @blur="formatPrice($event, item, 'priceCoefficient', 100)" v-model="item.priceCoefficient"></el-input></td> <td><el-input :placeholder="placeholder" @input="changePrice($event, item, 'priceCoefficient')" :disabled="disabled" @blur="formatPrice($event, item, 'priceCoefficient', 100)" v-model="item.priceCoefficient"></el-input></td>
<template v-for="(ele, eIdx) in tableData.salePeriodData"> <template v-for="(ele, eIdx) in tableData.salePeriodData">
<td :key="eIdx">{{calcPrice(ele.standardShelfCost, item.priceCoefficient)}}</td> <td :key="eIdx">{{ calcPrice(ele.standardShelfCost, item.priceCoefficient) }}</td>
<td :key="eIdx">{{calcPrice(ele.standardSalesCost, item.priceCoefficient)}}</td> <td :key="eIdx">{{ calcPrice(ele.standardSalesCost, item.priceCoefficient) }}</td>
</template> </template>
</tr> </tr>
<tr class="desc-wrap"> <tr class="desc-wrap">
<td class="desc-td" :colspan="tableData.salePeriodData.length*2 + 3"> <td class="desc-td" :colspan="tableData.salePeriodData.length * 2 + 3">
<div class="desc"> <div class="desc">
<label for="">服务条款概述:</label> <label for="">服务条款概述:</label>
<Editor :disabled="disabled" :editorOption="overviewOption" v-model="tableData.serviceOverview"></Editor> <Editor :disabled="disabled" :hasTool="false" :editorOption="overviewOption" v-model="tableData.serviceOverview"></Editor>
</div> </div>
</td> </td>
</tr> </tr>
<tr class="desc-wrap"> <tr class="desc-wrap">
<td class="desc-td" :colspan="tableData.salePeriodData.length*2+3"> <td class="desc-td" :colspan="tableData.salePeriodData.length * 2 + 3">
<div class="desc"> <div class="desc">
<label for="">规格详细描述:</label> <label for="">规格详细描述:</label>
<Editor :disabled="disabled" :editorOption="DetailOption" v-model="tableData.serviceDetail"></Editor> <Editor :disabled="disabled" :hasTool="false" :editorOption="DetailOption" v-model="tableData.serviceDetail"></Editor>
</div> </div>
</td> </td>
</tr> </tr>
</table> </table>
</div> </div>
</template> </template>
<script> <script>
import Editor from '@/components/Editor' import Editor from '@/components/Editor'
export default { export default {
name: 'ServicesTable', name: 'ServicesTable',
components:{ components: {
Editor, Editor
}, },
props: { props: {
name: { name: {
...@@ -76,7 +78,7 @@ ...@@ -76,7 +78,7 @@
}, },
tableData: { tableData: {
type: String, type: String,
default: ()=>{ default: () => {
return {} return {}
} }
}, },
...@@ -102,8 +104,8 @@ ...@@ -102,8 +104,8 @@
toolbar: false, toolbar: false,
clipboard: { clipboard: {
// 粘贴版,处理粘贴时候的自带样式 // 粘贴版,处理粘贴时候的自带样式
matchers: [[Node.ELEMENT_NODE, this.HandleCustomMatcher]], matchers: [[Node.ELEMENT_NODE, this.HandleCustomMatcher]]
}, }
} }
}, },
DetailOption: { DetailOption: {
...@@ -112,24 +114,34 @@ ...@@ -112,24 +114,34 @@
toolbar: false, toolbar: false,
clipboard: { clipboard: {
// 粘贴版,处理粘贴时候的自带样式 // 粘贴版,处理粘贴时候的自带样式
matchers: [[Node.ELEMENT_NODE, this.HandleCustomMatcher]], matchers: [[Node.ELEMENT_NODE, this.HandleCustomMatcher]]
}, }
} }
} }
} }
}, },
methods: { methods: {
changePrice(value, item , key){ changePrice(value, item, key) {
item[key] = value ? value.replace(/^0\d/g, '0').replace(/[^\d.]/g, '').replace(/^\./g, '').replace(/^\d{6}\d+(\.\d+)?/g, value.substr(0,6)).replace(/\.{2,}/g, '').replace('.', '$#$') item[key] = value
.replace(/\./g, '').replace('$#$', '.').replace(/^(-)*(\d+)\.(\d\d).*$/, '$1$2.$3') : '' ? value
.replace(/^0\d/g, '0')
.replace(/[^\d.]/g, '')
.replace(/^\./g, '')
.replace(/^\d{6}\d+(\.\d+)?/g, value.substr(0, 6))
.replace(/\.{2,}/g, '')
.replace('.', '$#$')
.replace(/\./g, '')
.replace('$#$', '.')
.replace(/^(-)*(\d+)\.(\d\d).*$/, '$1$2.$3')
: ''
}, },
formatPrice(e, item, key, maxNum){ formatPrice(e, item, key, maxNum) {
let num = e.target.value let num = e.target.value
if(num>maxNum){ if (num > maxNum) {
item[key] = maxNum item[key] = maxNum
} }
}, },
calcPrice(price1, price2){ calcPrice(price1, price2) {
price1 = price1 || 0 price1 = price1 || 0
price2 = price2 || 0 price2 = price2 || 0
return Number((price1 * price2).toFixed(2)) return Number((price1 * price2).toFixed(2))
...@@ -140,78 +152,76 @@ ...@@ -140,78 +152,76 @@
Delta.ops.forEach(op => { Delta.ops.forEach(op => {
if (op.insert && typeof op.insert === 'string') { if (op.insert && typeof op.insert === 'string') {
ops.push({ ops.push({
insert: op.insert, insert: op.insert
}) })
} }
}) })
Delta.ops = ops Delta.ops = ops
return Delta return Delta
},
} }
} }
</script> }
<style lang="scss" scoped> </script>
.table-wrap{ <style lang="scss" scoped>
.tip{ .table-wrap {
.tip {
width: 14px; width: 14px;
vertical-align: middle; vertical-align: middle;
margin-bottom: 2px; margin-bottom: 2px;
cursor: pointer; cursor: pointer;
} }
/deep/ .el-input__inner{ /deep/ .el-input__inner {
padding: 0 2px; padding: 0 2px;
text-align: center; text-align: center;
} }
th, td{ th,
border: 1px solid #E5E5E5; td {
border: 1px solid #e5e5e5;
padding: 0 16px; padding: 0 16px;
vertical-align: middle; vertical-align: middle;
text-align: center; text-align: center;
} }
th{ th {
background: #F4F6FC; background: #f4f6fc;
font-weight: 600; font-weight: 600;
font-size: 14px; font-size: 14px;
color: #333333; color: #333333;
} }
td{ td {
font-weight: 400; font-weight: 400;
height: 56px; height: 56px;
font-size: 14px; font-size: 14px;
color: #666666; color: #666666;
} }
.price{ .price {
width: 136px; width: 136px;
.sign{ .sign {
margin: 0 6px; margin: 0 6px;
} }
.el-input{ .el-input {
width: 50px; width: 50px;
} }
} }
.desc-wrap{ .desc-wrap {
height: 88px; height: 88px;
.desc-td{ .desc-td {
padding: 12px 16px; padding: 12px 16px;
} }
.desc{ .desc {
display: flex; display: flex;
height: 100%; height: 100%;
label{ label {
white-space: nowrap; white-space: nowrap;
} }
/deep/ .editor-ctnr{ /deep/ .editor {
height: 100%; width: 100%;
.ql-container{ text-align: left;
border-radius: 4px;
.w-e-text-container {
border-radius: 4px; border-radius: 4px;
.ql-editor{
padding: 8px;
}
}
} }
} }
} }
} }
</style>
\ No newline at end of file \ No newline at end of file
}
</style>
...@@ -11,8 +11,8 @@ ...@@ -11,8 +11,8 @@
</div> </div>
<GLTable ref="equityRef" :getListApi="getListApi" :searchForm="tableSearchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn"> <GLTable ref="equityRef" :getListApi="getListApi" :searchForm="tableSearchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn">
<div slot="statusSlot" slot-scope="scope"> <div slot="statusSlot" slot-scope="scope">
<span class="statsu-circle" :style="{'background-color': scope.scope.serviceStatus == 0 ? '#FDB757' : '#2CCA74'}"></span> <span class="statsu-circle" :style="{ 'background-color': scope.scope.serviceStatus == 0 ? '#FDB757' : '#2CCA74' }"></span>
<span>{{ scope.scope.serviceStatus == 0 ? '待配置': '已配置' }}</span> <span>{{ scope.scope.serviceStatus == 0 ? '待配置' : '已配置' }}</span>
</div> </div>
<span slot="auth-button" slot-scope="scope" :data="scope.scope"> <span slot="auth-button" slot-scope="scope" :data="scope.scope">
<GLTableButton :buttonList="buttonList" :buttonItem="scope" :buttonNum="3"></GLTableButton> <GLTableButton :buttonList="buttonList" :buttonItem="scope" :buttonNum="3"></GLTableButton>
...@@ -22,13 +22,12 @@ ...@@ -22,13 +22,12 @@
</div> </div>
</template> </template>
<script> <script>
import * as dayjs from 'dayjs' import * as dayjs from 'dayjs'
import utils from '../../util/util' import utils from '../../util/util'
export default { export default {
name: 'equityList', name: 'equityList',
components:{ components: {},
},
data() { data() {
return { return {
size: 'small', size: 'small',
...@@ -42,7 +41,7 @@ ...@@ -42,7 +41,7 @@
type: 'text' type: 'text'
}, },
listeners: { listeners: {
click: row => this.addClause(2,row.scope) click: row => this.addClause(2, row.scope)
} }
}, },
{ {
...@@ -54,7 +53,7 @@ ...@@ -54,7 +53,7 @@
type: 'text' type: 'text'
}, },
listeners: { listeners: {
click: row => this.addClause(3,row.scope) click: row => this.addClause(3, row.scope)
} }
} }
], ],
...@@ -70,7 +69,7 @@ ...@@ -70,7 +69,7 @@
label: '服务名称', label: '服务名称',
name: 'serviceName', name: 'serviceName',
type: 'input', type: 'input',
isClear: true, isClear: true
}, },
{ {
label: '状态', label: '状态',
...@@ -92,7 +91,7 @@ ...@@ -92,7 +91,7 @@
], ],
optionId: 'id', optionId: 'id',
optionLabel: 'label', optionLabel: 'label',
isClear: true, isClear: true
}, },
{ {
label: '创建时间', label: '创建时间',
...@@ -132,7 +131,12 @@ ...@@ -132,7 +131,12 @@
minWidth: 280, minWidth: 280,
prop: 'salePeriod', prop: 'salePeriod',
formatter: cellValue => { formatter: cellValue => {
return cellValue.salePeriod?.length ? cellValue.salePeriod.split(',').map(item => item = item+'年').join('、') : '--' return cellValue.salePeriod?.length
? cellValue.salePeriod
.split(',')
.map(item => (item = item + '年'))
.join('、')
: '--'
} }
}, },
{ {
...@@ -169,12 +173,11 @@ ...@@ -169,12 +173,11 @@
} }
] ]
}, },
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' }, pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' }
} }
}, },
mounted() { mounted() {},
},
methods: { methods: {
getParams() { getParams() {
...@@ -189,7 +192,7 @@ ...@@ -189,7 +192,7 @@
} }
delete params.createdDate delete params.createdDate
delete params.updatedDate delete params.updatedDate
return {...params} return { ...params }
}, },
beforeSearchFn() { beforeSearchFn() {
...@@ -236,7 +239,7 @@ ...@@ -236,7 +239,7 @@
let query = { let query = {
type type
} }
if(type!=1){ if (type != 1) {
query.id = id query.id = id
query.serviceCode = serviceCode query.serviceCode = serviceCode
query.serviceName = serviceName query.serviceName = serviceName
...@@ -245,22 +248,21 @@ ...@@ -245,22 +248,21 @@
this.$router.push('/serviceConfig/addService/' + queryStr) this.$router.push('/serviceConfig/addService/' + queryStr)
} }
} }
} }
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.container{ .container {
background-color: #ffffff; background-color: #ffffff;
padding: 20px; padding: 20px;
.statsu-circle{ .statsu-circle {
display: inline-block; display: inline-block;
width: 6px; width: 6px;
height: 6px; height: 6px;
border-radius: 50%; border-radius: 50%;
background-color: #FDB757; background-color: #fdb757;
margin-right: 8px; margin-right: 8px;
vertical-align: middle; vertical-align: middle;
} }
}
</style>
\ No newline at end of file \ No newline at end of file
}
</style>
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!