Commit eeedb8f0 by 胡悦

轻改提单添加商品页面

1 parent 8fe8604c
......@@ -114,5 +114,38 @@ module.exports = {
projectName: 'boutique',
...data
})
}
},
// 权益提单相关接口
// 查询店铺配置
getShopMerchantPointConfig(data) {
return http.post({
method: 'dj.api.smartcarlife.shopMerchantPointConfig.get',
projectName: 'boutique',
...data
})
},
// 根据4s店商户好获取二级流浪方列表
getSubShopMerchantList(data) {
return http.post({
method: 'dj.api.smartcarlife.diversionMerchant.getDiversionMerchantRef',
projectName: 'boutique',
...data
})
},
// 获取商户订单设置
getMerchantRecordingSettings(data) {
return http.post({
method: 'dj.api.smartcarlife.recordingSettings.getMerchantRecordingSettings',
projectName: 'boutique',
...data
})
},
// 获取园区店配置
getYqStoreConfig(data) {
return http.post({
method: 'dj.api.smarcarlife.yqMerchantConfig.detail',
projectName: 'boutique',
...data
})
},
}
......@@ -154,7 +154,7 @@
.icon-logo { width: calc(100vmin * (1173 / 768) * 0.06820119352088662); height: calc(100vmin * (1173 / 768) * 0.06820119352088662);
background-position: calc(100vmin * (1173 / 768) * -0.5647911338448423) calc(100vmin * (1173 / 768) * -0.10017050298380221);}
.icon-lssl-icon { width: calc(100vmin * (1173 / 768) * 0.011935208866155157); height: calc(100vmin * (1173 / 768) * 0.011935208866155157);
background-position: calc(100vmin * (1173 / 768) * -0.08013640238704177) calc(100vmin * (1173 / 768) * -0.6530264279624893);}
background-position: calc(100vmin * (1173 / 768) * -0.10017050298380221) calc(100vmin * (1173 / 768) * -0.6530264279624893);}
.icon-mask-del { width: calc(100vmin * (1173 / 768) * 0.03410059676044331); height: calc(100vmin * (1173 / 768) * 0.03410059676044331);
background-position: calc(100vmin * (1173 / 768) * -0.17902813299232737) calc(100vmin * (1173 / 768) * -0.5839727195225917);}
.icon-mask-edit { width: calc(100vmin * (1173 / 768) * 0.03410059676044331); height: calc(100vmin * (1173 / 768) * 0.03410059676044331);
......@@ -254,7 +254,7 @@
.icon-role-2 { width: calc(100vmin * (1173 / 768) * 0.028985507246376812); height: calc(100vmin * (1173 / 768) * 0.028985507246376812);
background-position: calc(100vmin * (1173 / 768) * -0.4134697357203751) calc(100vmin * (1173 / 768) * -0.5839727195225917);}
.icon-rule { width: calc(100vmin * (1173 / 768) * 0.011935208866155157); height: calc(100vmin * (1173 / 768) * 0.011935208866155157);
background-position: calc(100vmin * (1173 / 768) * -0.09846547314578005) calc(100vmin * (1173 / 768) * -0.6530264279624893);}
background-position: calc(100vmin * (1173 / 768) * -0.1184995737425405) calc(100vmin * (1173 / 768) * -0.6530264279624893);}
.icon-scan { width: calc(100vmin * (1173 / 768) * 0.013640238704177323); height: calc(100vmin * (1173 / 768) * 0.013640238704177323);
background-position: calc(100vmin * (1173 / 768) * -0.5042625745950554) calc(100vmin * (1173 / 768) * -0.6312872975277067);}
.icon-scene-0 { width: calc(100vmin * (1173 / 768) * 0.04092071611253197); height: calc(100vmin * (1173 / 768) * 0.04092071611253197);
......@@ -292,7 +292,7 @@
.icon-study-active { width: calc(100vmin * (1173 / 768) * 0.0443307757885763); height: calc(100vmin * (1173 / 768) * 0.0443307757885763);
background-position: calc(100vmin * (1173 / 768) * -0.41602728047740833) calc(100vmin * (1173 / 768) * -0.4825234441602728);}
.icon-study-tips { width: calc(100vmin * (1173 / 768) * 0.011935208866155157); height: calc(100vmin * (1173 / 768) * 0.011935208866155157);
background-position: calc(100vmin * (1173 / 768) * -0.11679454390451834) calc(100vmin * (1173 / 768) * -0.6530264279624893);}
background-position: calc(100vmin * (1173 / 768) * -0.13682864450127877) calc(100vmin * (1173 / 768) * -0.6530264279624893);}
.icon-study { width: calc(100vmin * (1173 / 768) * 0.0443307757885763); height: calc(100vmin * (1173 / 768) * 0.0443307757885763);
background-position: calc(100vmin * (1173 / 768) * -0.46675191815856776) calc(100vmin * (1173 / 768) * -0.4825234441602728);}
.icon-submit { width: calc(100vmin * (1173 / 768) * 0.017050298380221655); height: calc(100vmin * (1173 / 768) * 0.017050298380221655);
......@@ -306,7 +306,7 @@
.icon-tag-checked { width: calc(100vmin * (1173 / 768) * 0.02557544757033248); height: calc(100vmin * (1173 / 768) * 0.013640238704177323);
background-position: calc(100vmin * (1173 / 768) * -0.6547314578005116) calc(100vmin * (1173 / 768) * -0.46462063086104005);}
.icon-task-pass { width: calc(100vmin * (1173 / 768) * 0.011935208866155157); height: calc(100vmin * (1173 / 768) * 0.011935208866155157);
background-position: calc(100vmin * (1173 / 768) * -0.13512361466325662) calc(100vmin * (1173 / 768) * -0.6530264279624893);}
background-position: calc(100vmin * (1173 / 768) * -0.15515771526001704) calc(100vmin * (1173 / 768) * -0.6530264279624893);}
.icon-tdcj-icon { width: calc(100vmin * (1173 / 768) * 0.017050298380221655); height: calc(100vmin * (1173 / 768) * 0.017050298380221655);
background-position: calc(100vmin * (1173 / 768) * -0.43861892583120204) calc(100vmin * (1173 / 768) * -0.4079283887468031);}
.icon-time-icon { width: calc(100vmin * (1173 / 768) * 0.013640238704177323); height: calc(100vmin * (1173 / 768) * 0.013640238704177323);
......@@ -340,4 +340,6 @@
.icon-yw-icon { width: calc(100vmin * (1173 / 768) * 0.015345268542199489); height: calc(100vmin * (1173 / 768) * 0.015345268542199489);
background-position: calc(100vmin * (1173 / 768) * -0.021739130434782608) calc(100vmin * (1173 / 768) * -0.6312872975277067);}
.icon-zj-icon { width: calc(100vmin * (1173 / 768) * 0.013640238704177323); height: calc(100vmin * (1173 / 768) * 0.013640238704177323);
background-position: calc(100vmin * (1173 / 768) * -0.06010230179028133) calc(100vmin * (1173 / 768) * -0.6530264279624893);}
\ No newline at end of file
background-position: calc(100vmin * (1173 / 768) * -0.06010230179028133) calc(100vmin * (1173 / 768) * -0.6530264279624893);}
.icon-blue-delete { width: calc(100vmin * (1173 / 768) * 0.013640238704177323); height: calc(100vmin * (1173 / 768) * 0.013640238704177323);
background-position: calc(100vmin * (1173 / 768) * -0.08013640238704177) calc(100vmin * (1173 / 768) * -0.6530264279624893);}
\ No newline at end of file

2.54 MB | W: | H:

2.54 MB | W: | H:

assets/images/sprite.png
assets/images/sprite.png
assets/images/sprite.png
assets/images/sprite.png
  • 2-up
  • Swipe
  • Onion skin
<template>
<view>
<view v-for="(items, boxIdx) in formList" :key="boxIdx">
<view class="cell-box">
<view v-for="(item, idx) in items" :key="idx" class="cell" @click="onCellClick(item)" :class="[
item.noBorder ? '' : 'border',
item.onlyLabel ? 'small-height' : '',
item.class
]">
<view :class="['cell-label', { 'only-label': item.onlyLabel }]">
<view v-if="item.labellIcon" :class="['sprite-icon', `icon-${item.labellIcon}`]"></view>
{{ item.label }}
<view v-if="item.required" class="required">*</view>
</view>
<view class="cell-value">
<!-- 输入框 -->
<template v-if="item.type === 'input'">
<view class="input-box">
<input class="input-value" v-model="formData[item.value]" :placeholder="item.placeholder || '请输入'"
:maxlength="item.maxlength || 500" />
<view v-if="item.valueIcon" :class="['sprite-icon', `icon-${item.valueIcon}`]" @click="onValueClick(item)"></view>
</view>
</template>
<!-- 下拉选择 -->
<template v-else-if="item.type === 'select'">
<view v-if="formData[item.value] && formData[item.value][item.key]" class="value">
{{ formData[item.value][item.key] }}
<view v-for="(item, idx) in items" :key="idx" class="cell-row">
<view class="cell" @click="onCellClick(item)" :class="[
item.noBorder ? '' : 'border',
item.onlyLabel ? 'small-height' : '',
item.class
]">
<template v-if="!item.hidden">
<view :class="['cell-label', { 'only-label': item.onlyLabel }]">
<view v-if="item.labellIcon" :class="['sprite-icon', `icon-${item.labellIcon}`]"></view>
{{ item.label }}
<view v-if="item.required" class="required">*</view>
</view>
<view v-else class="placeholder value">
请选择
<view class="sprite-icon icon-icon-select"></view>
<view class="cell-value">
<!-- 输入框 -->
<template v-if="item.type === 'input'">
<view class="input-box">
<input class="input-value" v-model="formData[item.value]" :placeholder="item.placeholder || '请输入'"
:maxlength="item.maxlength || 500" />
<view v-if="item.valueIcon" :class="['sprite-icon', `icon-${item.valueIcon}`]"
@click="onValueClick(item)"></view>
</view>
</template>
<!-- 下拉选择 -->
<template v-else-if="item.type === 'select'">
<view class="value">
<template v-if="formData[item.value] && formData[item.value][item.key]">
<template v-if="item.showText && userInfo && userInfo[item.showText]">
{{ userInfo[item.showText] }}<text>|</text>
</template>
{{ formData[item.value][item.key] }}
</template>
<template v-else>
<span class="placeholder">请选择</span>
</template>
<view class="sprite-icon icon-icon-select"></view>
</view>
</template>
<!-- 单选框 -->
<template v-else-if="item.type === 'radio'">
<radio-group class="radio-group value" @change="onRadioChange($event, item)">
<label class="uni-list-cell uni-list-cell-pd" v-for="radio in item.radioList"
:key="radio.value + item.value">
<radio style="transform:scale(0.7)" :value="radio.value" :checked="radio.value == item.current" />
<view class="radio-name">{{ radio.name }}</view>
</label>
</radio-group>
</template>
<!-- 多行文本 -->
<template v-else-if="item.type === 'textarea'">
<textarea class="textarea" v-model="formData[item.value]" :placeholder="item.placeholder || '请输入'"
placeholder-class="textarea-placeholder" confirm-type="done" auto-height
:maxlength="item.maxlength"></textarea>
</template>
</view>
</template>
<!-- 单选框 -->
<template v-else-if="item.type === 'radio'">
<radio-group class="radio-group value" @change="onRadioChange($event, item)">
<label class="uni-list-cell uni-list-cell-pd" v-for="radio in item.radioList"
:key="radio.value + item.value">
<radio style="transform:scale(0.7)" :value="radio.value" :checked="radio.value == item.current" />
<view class="radio-name">{{ radio.name }}</view>
</label>
</radio-group>
</template>
<!-- 多行文本 -->
<template v-else-if="item.type === 'textarea'">
<textarea class="textarea" v-model="formData[item.value]" :placeholder="item.placeholder || '请输入'"
placeholder-class="textarea-placeholder" confirm-type="done" auto-height
:maxlength="item.maxlength"></textarea>
</template>
</view>
<slot v-if="item.addHtml" :name="item.addHtml"></slot>
</view>
</view>
</view>
......@@ -62,7 +72,7 @@ export default {
/**
* noBorder:默认false:有下边框,true:无下边框
* onlyLabel:判断是否只有label,默认false,主要是为了做样式区分
* class:cell-row:不一行显示,主要用于文本域
* class:cell-break:不一行显示,主要用于文本域
* required:是否为必填项,添加星号
* value: 绑定的字段名称
* key:如果绑定的字段名称为对象,则需要传入需要显示在页面上的属性名
......@@ -80,6 +90,14 @@ export default {
default: () => ({})
}
},
data() {
return {
userInfo: {}
}
},
mounted() {
this.userInfo = uni.$storage.get('userInfo') || {}
},
methods: {
onCellClick(item) {
if (item.type === 'select') {
......@@ -103,18 +121,20 @@ export default {
overflow: hidden;
margin-bottom: toRpx(18);
}
.cell-row {
padding-left: toRpx(32);
}
.cell {
display: flex;
align-items: center;
padding: 0 toRpx(32);
padding-right: toRpx(32);
height: toRpx(96);
&.small-height {
height: toRpx(72);
}
&.cell-row {
&.cell-break {
flex-direction: column;
align-items: normal;
height: auto;
......@@ -130,6 +150,7 @@ export default {
font-size: toRpx(28);
display: flex;
align-items: center;
.sprite-icon {
margin-right: toRpx(8);
}
......@@ -146,12 +167,12 @@ export default {
}
}
.cell-row .cell-label {
.cell-break .cell-label {
height: toRpx(96);
line-height: toRpx(96);
}
.cell-row .cell-value {
.cell-break .cell-value {
width: 100%;
margin-left: 0;
}
......@@ -178,15 +199,18 @@ export default {
align-items: center;
height: 100%;
}
.input-box {
display: flex;
align-items: center;
justify-content: flex-end;
height: 100%;
.sprite-icon {
margin-left: toRpx(8);
}
}
.input-value {
height: 100%;
text-align: right;
......@@ -212,7 +236,7 @@ export default {
display: inline-block;
}
.textarea {
width: 100%;
......
......@@ -124,6 +124,7 @@ export default {
uni.$storage.rm("noSignInUuid");
uni.$storage.rm("beisenToken");
uni.$storage.rm("studyCenterPermission");
uni.$storage.rm("boutique_YQorderSetting")
setTimeout(() => {
uni.hideLoading()
uni.reLaunch({
......
const FORM_LIST = [
[
{
label: '销售顾问',
value: 'userInfo',
type: 'select',
key: 'staffName',
required: true,
showText: 'shopMerchantName'
},
{
label: '交付专员',
value: 'deliveryUserInfo',
type: 'select',
required: true,
key: 'staffName',
hidden: true,
showText: 'shopMerchantName'
},
{
label: '二级流量方',
value: 'subShopMerchantInfo',
type: 'select',
required: true,
key: 'subMerchantName',
hidden: true
},
{
label: '转化人员',
value: 'sellerUserInfo',
type: 'select',
key: 'staffName',
required: true,
showText: 'merchantName'
},
],
[
{
label: '车主姓名',
value: 'customer',
maxlength: '16',
type: 'input',
required: true
},
{
label: '客户来源',
value: 'salesType',
type: 'radio',
current: '0',
radioList: [
{
value: '0',
name: '售前'
},
{
value: '1',
name: '售后'
}
],
required: true
},
{
label: '性别',
value: 'customerSex',
type: 'radio',
current: '1',
radioList: [
{
value: '1',
name: '男'
},
{
value: '2',
name: '女'
}
]
},
{
label: '手机号',
value: 'customerPhone',
maxlength: '11',
type: 'input',
required: true
},
{
label: '选择车型',
value: 'carBrand',
type: 'select',
key: 'carInfo',
},
{
label: '车架号',
value: 'standNo',
maxlength: '17',
type: 'input'
},
{
label: '车牌号',
value: 'plateNumber',
maxlength: '8',
type: 'input'
},
{
label: '是否体验',
value: 'experienceFlag',
type: 'radio',
current: 'Y',
radioList: [
{
value: 'Y',
name: '是'
},
{
value: 'N',
name: '否'
}
]
},
],
[
{
label: '精品礼券',
value: 'couponInfo',
type: 'select',
key: 'name',
required: true
},
{
label: '请选择产品',
onlyLabel: true,
required: true,
noBorder: true
},
{
label: '前档',
value: 'user',
type: 'select',
key: 'name',
labellIcon: 'front-gear',
addHtml: 'product'
},
{
label: '前侧窗玻璃',
value: 'user',
type: 'select',
key: 'name',
labellIcon: 'front-window',
addHtml: 'product'
},
{
label: '后侧窗玻璃',
value: 'user',
type: 'select',
key: 'name',
labellIcon: 'rear-gear',
addHtml: 'product'
},
{
label: '后档',
value: 'user',
type: 'select',
key: 'name',
labellIcon: 'rear-window',
addHtml: 'product'
},
{
label: '天窗',
value: 'user',
type: 'select',
key: 'name',
labellIcon: 'sun-roof',
addHtml: 'product'
},
{
label: '套餐',
value: 'couponInfo',
type: 'select',
key: 'name',
required: true,
addHtml: 'package'
},
{
label: '精品礼券',
value: 'couponInfo',
type: 'select',
key: 'name',
required: true,
addHtml: 'product'
},
{
label: '收款方式',
value: 'payeeType',
type: 'radio',
key: 'name',
current: '0',
radioList: [
{
value: '0',
name: '嘀加收款'
},
{
value: '1',
name: '4s店收款'
}
],
},
{
label: '支付方式',
value: 'selectPayType',
type: 'radio',
key: 'name',
current: '0',
radioList: [
{
value: '3',
name: 'POS机'
},
{
value: '6',
name: '对公转账'
},
{
value: '7',
name: '其他收款'
}
],
addHtml: 'otherPay'
},
],
[
{
label: '备注',
value: 'remark',
maxlength: '100',
type: 'textarea',
placeholder: '请输入 (100字以内)',
class: 'cell-break'
},
]
]
const payType = [
{
value: '1',
name: '微信支付'
},
{
value: '2',
name: '线下收款'
},
{
value: '3',
name: 'POS机'
},
{
value: '4',
name: '支付宝支付'
},
{
value: '5',
name: '嘀加收款'
},
{
value: '6',
name: '对公转账'
},
{
value: '7',
name: '其他收款'
}
]
const popupTypeEnum = {
0: 'userInfo',
1: 'deliveryUserInfo',
2: 'subShopMerchantInfo',
3: 'sellerUserInfo',
4: 'carBrand'
}
export {
FORM_LIST,
popupTypeEnum,
payType
}
\ No newline at end of file
......@@ -40,8 +40,8 @@ export const STORAGE_OBJECTKEY = {
leadPage: 'leadPage',
recordTrackList: 'recordTrackList',
beisenToken: 'beisenToken',
messagePopShownDate: 'messagePopShownDate',
noticeTopInfo: 'noticeTopInfo',
studyCenterPermission: 'studyCenterPermission',
caseInfo: 'caseInfo',
boutique_YQorderSetting: 'boutique_YQorderSetting'
}
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!