Parcourir la source

全局配置

yxb
DESKTOP-2IO5MST\huting il y a 2 ans
Parent
révision
b83ec7ce0e

+ 4
- 3
pages/service/service.vue Voir le fichier

@@ -7,7 +7,7 @@
</view>
<view class="content">
<view class="left">
<view v-for="(item,index) in menu.list" :key="index"
<view v-for="(item,index) in menu.menuList" :key="index"
:class="activeTab === item.name ? 'menu active' : 'menu'" @click="tabHandle(item.name,index)">
<view :class="activeTab === item.name ? 'border on' : 'border'"></view>
<view class="menu-text">{{item.name}}</view>
@@ -15,8 +15,8 @@
</view>
<view class="right">
<view class="right-content">
<block v-if="menu.list.length >0">
<view v-for="(item,index) in menu.list[tableSelectIndex].children" :key='index' class="item-box" @click="toNext(item.link)">
<block v-if="menu.menuList.length >0">
<view v-for="(item,index) in menu.menuList[tableSelectIndex].children" :key='index' class="item-box" @click="toNext(item.link)">
<view class="item bg-blue" :style="{ '--background': bgBlue }">
<image :src="`${$imgUrl}${item.iconPath}`" />
</view>
@@ -92,6 +92,7 @@
return new Promise(async (resolve, reject) => {
const res = await request(queryMenuConfig, options);
const data = stringToJson(res.bizContent);
console.log("data",data.menuList)
resolve(data);
}).catch((error) => {
reject(error);

+ 39
- 3
subpackage/applyCard/components/layout-numberplate-color.vue Voir le fichier

@@ -13,6 +13,9 @@
<script setup lang="ts">
import { onMounted, reactive } from "vue";
import{fileURL} from '@/datas/fileURL.js';
import { getItem} from "@/utils/storage";
import { getGlobalParam } from "@/utils/network/api.js";
import {getCodeName} from "@/datas/queryKey.js";
const emit = defineEmits(['numberplateResult'])
const props = defineProps({
@@ -26,12 +29,18 @@
numberplateCor:{
type:Object,
default:()=>{return {id:-1}}
}
},
//客车1 货车2
type:{
type:String,
default:'1'
},
})
const state = reactive({
curCheckId:-1, //当前选择的车牌
numberplateColorList:[//车牌颜色
numberplateColorList:[],
allColorList:[//车牌颜色
{src:'bg-blue',checkSrc:'icon-select-blue',id:0,color:'#ffffff',title:'蓝色'},
{src:'bg-green',checkSrc:'icon-select-green',id:4,color:'#000000',title:'渐变绿色'},
{src:'bg-orange',checkSrc:'icon-select-orange',id:1,color:'#000000',title:'黄色'},
@@ -39,7 +48,10 @@
{src:'bg-black',checkSrc:'icon-select-black',id:2,color:'#ffffff',title:'黑色'},
{src:'bg-white',checkSrc:'icon-select-white',id:3,color:'#000000',title:'白色'},
{src:'bg-white_blue',checkSrc:'icon-select-blue',id:6,color:'#000000',title:'蓝白渐变'},
],
{src:'bg-green',checkSrc:'icon-select-green',id:11,color:'rgb(0,255,0)',title:'绿色'},
{src:'bg-white_white',checkSrc:'icon-select-white',id:12,color:'rgb(255,0,0)',title:'红色'},
]
})
/* 选择车牌颜色 */
@@ -47,10 +59,34 @@
state.curCheckId = item.id;
emit('numberplateResult',item)
}
const getCarColor = () => {
const data=getItem('globalParam')
if(props.type==1){
for(var i=0;i<data.carPlateColorType.length;i++){
for(var j=0;j<state.allColorList.length;j++){
if(state.allColorList[j].title==getCodeName('VEHICLE_COLOR_TYPE',data.carPlateColorType[i])){
state.numberplateColorList.push(state.allColorList[j])
}
}
}
}else{
for(var i=0;i<data.trucksPlateColorType.length;i++){
for(var j=0;j<state.allColorList.length;j++){
if(state.allColorList[j].title==getCodeName('VEHICLE_COLOR_TYPE',data.trucksPlateColorType[i])){
state.numberplateColorList.push(state.allColorList[j])
}
}
}
}
}
onMounted(()=>{
state.curCheckId = props.numberplateCor.id;
getCarColor()
console.log("type",props.type)
})
</script>

<style lang="scss" scoped>

+ 10
- 2
subpackage/applyCard/essential-information.vue Voir le fichier

@@ -13,6 +13,7 @@
<numberplate-color
:numberplate="state.data.vehiclePlateNumber"
:numberplateCor="{ id: 0 }"
:type="state.data.type"
@numberplateResult="checkNumberplateColor"
>
</numberplate-color>
@@ -562,7 +563,14 @@ const productReCodeAction = (orderId) => {
line-height: 80rpx;
}
}
::deep.numberplates .numberplate-bg.data-v-18c7b8f7 {
width: 195rpx;
:deep(.numberplates .numberplate-bg) {
width: 190rpx;
}
:deep(.numberplates .numberplate){
margin-right: 0rpx !important;
width: 190rpx;
}
:deep(.numberplates){
justify-content: space-between;
}
</style>

Chargement…
Annuler
Enregistrer