Merge remote-tracking branch 'origin/xiaozy_产品列表'
This commit is contained in:
@@ -66,7 +66,8 @@ export default {
|
|||||||
handler(nval, oval) {
|
handler(nval, oval) {
|
||||||
this.list = [];
|
this.list = [];
|
||||||
// this.isDisabled = !!this.config.isDisabled;
|
// this.isDisabled = !!this.config.isDisabled;
|
||||||
if (nval) {
|
let type = this.$utils.typeJudgment(this.config.echoName);
|
||||||
|
if (nval && ["String"].includes(type)) {
|
||||||
let resultName = this.config.echoName.replace(/\s*/g, "");
|
let resultName = this.config.echoName.replace(/\s*/g, "");
|
||||||
if (!resultName) return;
|
if (!resultName) return;
|
||||||
this.remoteMethod(resultName);
|
this.remoteMethod(resultName);
|
||||||
|
|||||||
@@ -56,7 +56,7 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
|
|
||||||
<el-select
|
<!-- <el-select
|
||||||
v-model="parameter.params.companyType"
|
v-model="parameter.params.companyType"
|
||||||
placeholder="账户类型"
|
placeholder="账户类型"
|
||||||
clearable
|
clearable
|
||||||
@@ -67,7 +67,7 @@
|
|||||||
:label="item.label"
|
:label="item.label"
|
||||||
:value="item.value"
|
:value="item.value"
|
||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select> -->
|
||||||
|
|
||||||
<!-- 企业负责人或联系方式 -->
|
<!-- 企业负责人或联系方式 -->
|
||||||
<autocomplete
|
<autocomplete
|
||||||
@@ -332,13 +332,13 @@
|
|||||||
</p>
|
</p>
|
||||||
</template>
|
</template>
|
||||||
<template #companyNature>
|
<template #companyNature>
|
||||||
<!-- <p v-if="oilCompanyMatch[0]">
|
<p v-if="oilCompanyMatch[0]">
|
||||||
{{
|
{{
|
||||||
companyNatureEnum.find(
|
companyNatureEnum.find(
|
||||||
(item) => item.value === oilCompanyMatch[0].companyNature
|
(item) => item.value === oilCompanyMatch[0].companyNature
|
||||||
).label
|
).label
|
||||||
}}
|
}}
|
||||||
</p> -->
|
</p>
|
||||||
</template>
|
</template>
|
||||||
<template #companyDockType>
|
<template #companyDockType>
|
||||||
<p>
|
<p>
|
||||||
@@ -501,7 +501,8 @@ export default {
|
|||||||
querykey: "companyName",
|
querykey: "companyName",
|
||||||
},
|
},
|
||||||
configAutocompleteHead: {
|
configAutocompleteHead: {
|
||||||
serveTarget: commonServe.getCompanyNames,
|
serveTarget: commonServe.getRefineryCompanyList,
|
||||||
|
autocompleteKey: "name",
|
||||||
labelKey: "name",
|
labelKey: "name",
|
||||||
valueKey: "name",
|
valueKey: "name",
|
||||||
placeholder: "总公司名称",
|
placeholder: "总公司名称",
|
||||||
@@ -693,6 +694,7 @@ export default {
|
|||||||
this.getByPage();
|
this.getByPage();
|
||||||
},
|
},
|
||||||
getByPage() {
|
getByPage() {
|
||||||
|
this.parameter.params.companyType = "4";
|
||||||
serve.getByPage(this.parameter).then((res) => {
|
serve.getByPage(this.parameter).then((res) => {
|
||||||
this.tableData = res.data.list;
|
this.tableData = res.data.list;
|
||||||
this.parameter.total = res.data.totalCount;
|
this.parameter.total = res.data.totalCount;
|
||||||
|
|||||||
@@ -36,7 +36,11 @@
|
|||||||
placeholder="请选择炼厂"
|
placeholder="请选择炼厂"
|
||||||
></el-autocomplete> -->
|
></el-autocomplete> -->
|
||||||
|
|
||||||
<autocomplete :params="form" :config="configAutocomplete" />
|
<autocomplete
|
||||||
|
ref="autocomplete"
|
||||||
|
:params="form"
|
||||||
|
:config="configAutocomplete"
|
||||||
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="所属炼厂库名" prop="belongLibrary">
|
<el-form-item label="所属炼厂库名" prop="belongLibrary">
|
||||||
<el-input
|
<el-input
|
||||||
@@ -203,6 +207,7 @@ export default {
|
|||||||
this.form = {};
|
this.form = {};
|
||||||
this.controlWindows.addInfo = {};
|
this.controlWindows.addInfo = {};
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
|
this.$refs.autocomplete.list = [];
|
||||||
this.$refs.form.clearValidate();
|
this.$refs.form.clearValidate();
|
||||||
this.controlWindows.add = false;
|
this.controlWindows.add = false;
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -41,14 +41,28 @@ export default {
|
|||||||
controlWindows: Object,
|
controlWindows: Object,
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
|
let validatorFloorPrice = (rule, value, callback) => {
|
||||||
|
if (!value || !+value) return callback("成本价价不能为0或空");
|
||||||
|
callback();
|
||||||
|
};
|
||||||
|
let validatorSalePrice2company = (rule, value, callback) => {
|
||||||
|
if (!value || !+value) return callback("企业销售价不能为0或空");
|
||||||
|
if (value < this.form.floorPrice)
|
||||||
|
return callback("企业销售价不能低于成本价");
|
||||||
|
callback();
|
||||||
|
};
|
||||||
return {
|
return {
|
||||||
form: {},
|
form: {},
|
||||||
rules: {
|
rules: {
|
||||||
floorPrice: [
|
floorPrice: [
|
||||||
{ required: true, message: "请输入成本价", trigger: "blur" },
|
{ required: true, validator: validatorFloorPrice, trigger: "change" },
|
||||||
],
|
],
|
||||||
salePrice2company: [
|
salePrice2company: [
|
||||||
{ required: true, message: "请输入企业销售价", trigger: "blur" },
|
{
|
||||||
|
required: true,
|
||||||
|
validator: validatorSalePrice2company,
|
||||||
|
trigger: "change",
|
||||||
|
},
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -66,7 +66,7 @@
|
|||||||
</p></template
|
</p></template
|
||||||
>
|
>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="个人销售价">
|
<!-- <el-table-column label="个人销售价">
|
||||||
<template slot-scope="{ row }">
|
<template slot-scope="{ row }">
|
||||||
<p v-if="row.salePrice2personal">
|
<p v-if="row.salePrice2personal">
|
||||||
{{ row.salePrice2personal }}/{{ row.measurement }}
|
{{ row.salePrice2personal }}/{{ row.measurement }}
|
||||||
@@ -79,7 +79,7 @@
|
|||||||
{{ row.lastSalePrice2personal }}/{{ row.measurement }}
|
{{ row.lastSalePrice2personal }}/{{ row.measurement }}
|
||||||
</p></template
|
</p></template
|
||||||
>
|
>
|
||||||
</el-table-column>
|
</el-table-column> -->
|
||||||
<el-table-column label="时间" width="235">
|
<el-table-column label="时间" width="235">
|
||||||
<template slot-scope="{ row }">
|
<template slot-scope="{ row }">
|
||||||
<p class="gray">
|
<p class="gray">
|
||||||
|
|||||||
@@ -97,17 +97,17 @@
|
|||||||
</el-switch>
|
</el-switch>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="refineryLevel" label="成本价" width="70">
|
<el-table-column prop="refineryLevel" label="成本价" width="110">
|
||||||
<template slot-scope="{ row }">
|
<template slot-scope="{ row }">
|
||||||
{{ row.floorPrice | toNumberFixed }}/{{ row.measurement }}
|
{{ row.floorPrice | toNumberFixed }}/{{ row.measurement }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="refineryLevel" label="企业销售价" width="100">
|
<el-table-column prop="refineryLevel" label="企业销售价" width="110">
|
||||||
<template slot-scope="{ row }">
|
<template slot-scope="{ row }">
|
||||||
{{ row.salePrice2company | toNumberFixed }}/{{ row.measurement }}
|
{{ row.salePrice2company | toNumberFixed }}/{{ row.measurement }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="refineryLevel" label="个人销售价" width="100">
|
<el-table-column prop="refineryLevel" label="个人销售价" width="110">
|
||||||
<template slot-scope="{ row }">
|
<template slot-scope="{ row }">
|
||||||
{{ row.salePrice2personal | toNumberFixed }}/{{ row.measurement }}
|
{{ row.salePrice2personal | toNumberFixed }}/{{ row.measurement }}
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -27,7 +27,11 @@
|
|||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="炼厂名称" prop="refineryId">
|
<el-form-item label="炼厂名称" prop="refineryId">
|
||||||
<autocomplete :params="form" :config="configAutocomplete" />
|
<autocomplete
|
||||||
|
ref="autocomplete"
|
||||||
|
:params="form"
|
||||||
|
:config="configAutocomplete"
|
||||||
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
</div>
|
</div>
|
||||||
@@ -104,6 +108,7 @@ export default {
|
|||||||
this.form = {};
|
this.form = {};
|
||||||
this.controlWindows.addInfo = {};
|
this.controlWindows.addInfo = {};
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
|
this.$refs.autocomplete.list = [];
|
||||||
this.$refs.form.clearValidate();
|
this.$refs.form.clearValidate();
|
||||||
this.controlWindows.add = false;
|
this.controlWindows.add = false;
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user