Browse Source

财务

dev-xx
马远东 11 months ago
parent
commit
a04df14b18
  1. 36
      src/views/financialsector/FinanceHome.vue
  2. 6
      src/views/financialsector/Financialse/FinancialBill.vue
  3. 1
      src/views/financialsector/Financialse/FinancialTrunkLine.vue
  4. 11
      src/views/financialsector/Financialse/FinancialWarehousing.vue

36
src/views/financialsector/FinanceHome.vue

@ -1,5 +1,5 @@
<template>
<div class="content_box" v-loading='ServiceTypeLoading'>
<div class="content_box" v-loading='pageLoading'>
<div class="header">
<!-- 模板名称 -->
<div class="el_Template">
@ -79,6 +79,7 @@ import { ref, defineAsyncComponent,reactive, toRefs, computed, onMounted, nextTi
import { getDictionaryBiz } from '@/api/system/dict'; //
import { $_basicdataBrande,$_InfopriceTemplate} from '@/api/financialsector/index'; //
const $route = useRoute(); //
const pageLoading=ref(true);//
//
const FinancialWarehousing = defineAsyncComponent(() =>
import('@/views/financialsector/Financialse/FinancialWarehousing.vue')
@ -99,6 +100,7 @@ const ServiceTypeLoading=ref(true);//菜单加载
const form = ref({});
const brand=ref([]);//
const Tabmenu = ref('仓储');
const request=ref({});//
const templateInfo = ref({});
//
const ServiceList = ref([]);
@ -119,11 +121,22 @@ function updateDictionary(targetArray, dictionaryType) {
}
}).catch(()=>{
}).finally(()=>{
ServiceTypeLoading.value=false;
ServiceTypeLoading.value=false;
});
}
//
async function executeCheckedResults(results) {
for (const res of results) {
await new Promise(resolve => setTimeout(resolve, 500));
await isChecked(res);
await provideData()
}
pageLoading.value=false;
}
//
const onLoad=()=>{
const onLoad= async()=>{
await updateDictionary(ServiceList.value,'service_type');//
if($route.query.id){
let data={
id:$route.query.id
@ -131,13 +144,16 @@ const onLoad=()=>{
$_InfopriceTemplate(data).then(res=>{
console.log(res,'获取详情');
if(res.data.code == 200){
form.value=res.data.data
request.value=res.data.data;//
form.value.brand=res.data.data.brandId||'';//
form.value.TemplateName=res.data.data.name||'';//
form.value.ServiceType= res.data.data.serviceType.split(",")||[];//
const result = ServiceList.value.filter(item => form.value.ServiceType.includes(item.value));
//
executeCheckedResults(result);
}
})
}
updateDictionary(ServiceList.value,'service_type');//
let data={
current:1,
size:1000,
@ -152,8 +168,11 @@ const onLoad=()=>{
onLoad()
//
const isChecked = val => {
console.log(val,'val');
///
val.state = !val.state;
val.check=!val.check;
//
//
Tabmenu.value = val.label;
//
@ -179,6 +198,9 @@ const provideData = (data) => {
if(data){
templateInfo.value.code=data;//
}
if($route.query.id){
templateInfo.value.request=request.value;//
}
};
</script>

6
src/views/financialsector/Financialse/FinancialBill.vue

@ -269,11 +269,11 @@ const details = reactive({
/** 计价方式 */
pickupPricingType: [],
/** 是否统一区域计费 */
pickupIsUnifyAreaBill: '1',
pickupIsUnifyAreaBill: '0',
/** 是否区分品类 */
pickupIsByCategory: '1',
pickupIsByCategory: '0',
/** 是否最低计费 */
pickupIsMinCost: '1',
pickupIsMinCost: '0',
/** 最低计费类型 */
pickupMinCostType: '1',
/** 计费模版详情 */

1
src/views/financialsector/Financialse/FinancialTrunkLine.vue

@ -402,6 +402,7 @@ const initDictionaryBiz = async () => {
initDictionaryBiz();
/** 新增品类 */
const handlePlus = async (value: any, index: number) => {
value.categories.splice(index + 1, 0, {

11
src/views/financialsector/Financialse/FinancialWarehousing.vue

@ -456,7 +456,7 @@ function updateDictionary(targetArray, dictionaryType) {
if (res.data.data.length) {
res.data.data.forEach(item => {
targetArray.push({
value: item.dictKey,
value: Number(item.dictKey),
label: item.dictValue,
id: item.id,
});
@ -474,12 +474,19 @@ function updateDictionary(targetArray, dictionaryType) {
.finally(() => {});
}
//
const onLoad = () => {
const onLoad = async() => {
updateDictionary(Storagebillingtype.value, 'warehouse_pricing_type'); //
updateDictionary(Warehousebillingmode.value, 'warehouse_pricing_mode'); //
updateDictionary(CalculationBasis.value, 'warehouse_calculation_basis'); //
updateDictionary(Distinguishcategories.value, 'price_yes_no'); //
updateDictionary(Surchargepricingunit.value, 'warehouse_pricing_unit'); //
if(props.templateData.request){
//
form.value=props.templateData.request
}
};
onLoad();
//

Loading…
Cancel
Save