|
@@ -101,6 +101,7 @@
|
|
|
<template #default="{ row }">
|
|
|
<div>
|
|
|
<el-button type="primary" @click="changeExchangeRate(row)" link>汇率</el-button>
|
|
|
+ <el-button type="primary" @click="changeBudget(row)" link>预算</el-button>
|
|
|
</div>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
@@ -166,6 +167,82 @@
|
|
|
<el-button type="primary" @click="submitChangeForm()" size="large">确 定</el-button>
|
|
|
</template>
|
|
|
</el-dialog>
|
|
|
+
|
|
|
+ <el-dialog title="预算" v-if="openBudget" v-model="openBudget" width="400">
|
|
|
+ <byForm :formConfig="formBudgetConfig" :formOption="formOption" v-model="formBudgetData.data" ref="budget">
|
|
|
+ <template #budgetMoney>
|
|
|
+ <div style="width: 100%">
|
|
|
+ <el-form-item label="拖车费" prop="trailerFee">
|
|
|
+ <el-input v-model="formBudgetData.data.trailerFee" placeholder="请输入拖车费" class="input-with-select">
|
|
|
+ <template #prepend>
|
|
|
+ <el-select v-model="formBudgetData.data.trailerFeeCurrency" placeholder="请选择货币" style="width: 115px">
|
|
|
+ <el-option v-for="(item, index) in accountCurrency" :key="index" :label="item.label" :value="item.value" />
|
|
|
+ </el-select>
|
|
|
+ </template>
|
|
|
+ </el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item label="报关费" prop="customsFee" style="margin-top: 20px">
|
|
|
+ <el-input v-model="formBudgetData.data.customsFee" placeholder="请输入报关费" class="input-with-select">
|
|
|
+ <template #prepend>
|
|
|
+ <el-select v-model="formBudgetData.data.customsFeeCurrency" placeholder="请选择货币" style="width: 115px">
|
|
|
+ <el-option v-for="(item, index) in accountCurrency" :key="index" :label="item.label" :value="item.value" />
|
|
|
+ </el-select>
|
|
|
+ </template>
|
|
|
+ </el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item label="代理费" prop="agencyFee" style="margin-top: 20px">
|
|
|
+ <el-input v-model="formBudgetData.data.agencyFee" placeholder="请输入代理费" class="input-with-select">
|
|
|
+ <template #prepend>
|
|
|
+ <el-select v-model="formBudgetData.data.agencyFeeCurrency" placeholder="请选择货币" style="width: 115px">
|
|
|
+ <el-option v-for="(item, index) in accountCurrency" :key="index" :label="item.label" :value="item.value" />
|
|
|
+ </el-select>
|
|
|
+ </template>
|
|
|
+ </el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item label="港杂费" prop="portMixedFee" style="margin-top: 20px">
|
|
|
+ <el-input v-model="formBudgetData.data.portMixedFee" placeholder="请输入港杂费" class="input-with-select">
|
|
|
+ <template #prepend>
|
|
|
+ <el-select v-model="formBudgetData.data.portMixedFeeCurrency" placeholder="请选择货币" style="width: 115px">
|
|
|
+ <el-option v-for="(item, index) in accountCurrency" :key="index" :label="item.label" :value="item.value" />
|
|
|
+ </el-select>
|
|
|
+ </template>
|
|
|
+ </el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item label="验货红包" prop="inspectionRedPack" style="margin-top: 20px">
|
|
|
+ <el-input v-model="formBudgetData.data.inspectionRedPack" placeholder="请输入验货红包" class="input-with-select">
|
|
|
+ <template #prepend>
|
|
|
+ <el-select v-model="formBudgetData.data.inspectionRedPackCurrency" placeholder="请选择货币" style="width: 115px">
|
|
|
+ <el-option v-for="(item, index) in accountCurrency" :key="index" :label="item.label" :value="item.value" />
|
|
|
+ </el-select>
|
|
|
+ </template>
|
|
|
+ </el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item label="佣金" prop="commission" style="margin-top: 20px">
|
|
|
+ <el-input v-model="formBudgetData.data.commission" placeholder="请输入佣金" class="input-with-select">
|
|
|
+ <template #prepend>
|
|
|
+ <el-select v-model="formBudgetData.data.commissionCurrency" placeholder="请选择货币" style="width: 115px">
|
|
|
+ <el-option v-for="(item, index) in accountCurrency" :key="index" :label="item.label" :value="item.value" />
|
|
|
+ </el-select>
|
|
|
+ </template>
|
|
|
+ </el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item label="其他" prop="other" style="margin-top: 20px">
|
|
|
+ <el-input v-model="formBudgetData.data.other" placeholder="请输入其他" class="input-with-select">
|
|
|
+ <template #prepend>
|
|
|
+ <el-select v-model="formBudgetData.data.otherCurrency" placeholder="请选择货币" style="width: 115px">
|
|
|
+ <el-option v-for="(item, index) in accountCurrency" :key="index" :label="item.label" :value="item.value" />
|
|
|
+ </el-select>
|
|
|
+ </template>
|
|
|
+ </el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ </byForm>
|
|
|
+ <template #footer>
|
|
|
+ <el-button @click="openBudget = false" size="large">取 消</el-button>
|
|
|
+ <el-button type="primary" @click="submitBudgetForm()" size="large">确 定</el-button>
|
|
|
+ </template>
|
|
|
+ </el-dialog>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
@@ -470,6 +547,84 @@ const submitChangeForm = () => {
|
|
|
);
|
|
|
});
|
|
|
};
|
|
|
+const openBudget = ref(false);
|
|
|
+const budget = ref(null);
|
|
|
+const formBudgetData = reactive({
|
|
|
+ data: {},
|
|
|
+});
|
|
|
+const formBudgetConfig = computed(() => {
|
|
|
+ return [
|
|
|
+ {
|
|
|
+ type: "title",
|
|
|
+ title: "合同信息",
|
|
|
+ label: "",
|
|
|
+ },
|
|
|
+ {
|
|
|
+ type: "input",
|
|
|
+ prop: "contractCode",
|
|
|
+ label: "合同编号",
|
|
|
+ itemType: "text",
|
|
|
+ disabled: true,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ type: "input",
|
|
|
+ prop: "customerName",
|
|
|
+ label: "客户名称",
|
|
|
+ itemType: "text",
|
|
|
+ disabled: true,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ type: "input",
|
|
|
+ prop: "userName",
|
|
|
+ label: "业务员",
|
|
|
+ itemType: "text",
|
|
|
+ disabled: true,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ type: "title",
|
|
|
+ title: "预算金额",
|
|
|
+ label: "",
|
|
|
+ },
|
|
|
+ {
|
|
|
+ type: "slot",
|
|
|
+ slotName: "budgetMoney",
|
|
|
+ label: "",
|
|
|
+ },
|
|
|
+ ];
|
|
|
+});
|
|
|
+const changeBudget = (row) => {
|
|
|
+ formBudgetData.data = {
|
|
|
+ id: row.id,
|
|
|
+ contractCode: row.contractCode,
|
|
|
+ customerName: row.customerName,
|
|
|
+ userName: row.userName,
|
|
|
+ trailerFeeCurrency: row.trailerFeeCurrency,
|
|
|
+ trailerFee: row.trailerFee,
|
|
|
+ customsFeeCurrency: row.customsFeeCurrency,
|
|
|
+ customsFee: row.customsFee,
|
|
|
+ agencyFeeCurrency: row.agencyFeeCurrency,
|
|
|
+ agencyFee: row.agencyFee,
|
|
|
+ portMixedFeeCurrency: row.portMixedFeeCurrency,
|
|
|
+ portMixedFee: row.portMixedFee,
|
|
|
+ inspectionRedPackCurrency: row.inspectionRedPackCurrency,
|
|
|
+ inspectionRedPack: row.inspectionRedPack,
|
|
|
+ commissionCurrency: row.commissionCurrency,
|
|
|
+ commission: row.commission,
|
|
|
+ otherCurrency: row.otherCurrency,
|
|
|
+ other: row.other,
|
|
|
+ };
|
|
|
+ openBudget.value = true;
|
|
|
+};
|
|
|
+const submitBudgetForm = () => {
|
|
|
+ proxy.post("/contract/edit", formBudgetData.data).then(() => {
|
|
|
+ ElMessage({
|
|
|
+ message: "保存成功",
|
|
|
+ type: "success",
|
|
|
+ });
|
|
|
+ openBudget.value = false;
|
|
|
+ getList();
|
|
|
+ });
|
|
|
+};
|
|
|
</script>
|
|
|
|
|
|
<style lang="scss" scoped>
|