|
@@ -31,6 +31,7 @@
|
|
|
placeholder="请选择"
|
|
|
clearable
|
|
|
@keyup.enter.native="handleQuery"
|
|
|
+ @change="changeSampleType"
|
|
|
>
|
|
|
<el-option
|
|
|
v-for="item in options.sampleTypeOption"
|
|
@@ -52,6 +53,7 @@
|
|
|
placeholder="请选择"
|
|
|
clearable
|
|
|
@keyup.enter.native="handleQuery"
|
|
|
+ @change="changeSampleModel"
|
|
|
>
|
|
|
<el-option
|
|
|
v-for="item in options.sampleModelOption"
|
|
@@ -352,7 +354,12 @@
|
|
|
|
|
|
<script>
|
|
|
import * as echarts from "echarts";
|
|
|
-import { getIndexInfo, getOthersOptions } from "@/api/manage/index";
|
|
|
+import {
|
|
|
+ getIndexInfo,
|
|
|
+ getSampleType,
|
|
|
+ getSampleModel,
|
|
|
+ getOthersOptions,
|
|
|
+} from "@/api/manage/index";
|
|
|
export default {
|
|
|
name: "Index",
|
|
|
dicts: ["biz_data_type", "biz_wavelength_um"],
|
|
@@ -421,9 +428,9 @@ export default {
|
|
|
getList() {
|
|
|
const loading = this.$loading({
|
|
|
lock: true,
|
|
|
- text: 'Loading',
|
|
|
- spinner: 'el-icon-loading',
|
|
|
- background: 'rgba(0, 0, 0, 0.7)'
|
|
|
+ text: "Loading",
|
|
|
+ spinner: "el-icon-loading",
|
|
|
+ background: "rgba(0, 0, 0, 0.7)",
|
|
|
});
|
|
|
getIndexInfo(this.queryParams).then((response) => {
|
|
|
const data = response.data;
|
|
@@ -463,16 +470,65 @@ export default {
|
|
|
thetaReflected: null,
|
|
|
phiReflected: null,
|
|
|
};
|
|
|
- const params = {
|
|
|
- dataType: this.queryParams.dataType,
|
|
|
+ getSampleType(this.queryParams).then((resp) => {
|
|
|
+ this.options = {
|
|
|
+ sampleTypeOption: resp.data,
|
|
|
+ sampleModelOption: [],
|
|
|
+ temperatureKOption: [],
|
|
|
+ allAngleOption: {
|
|
|
+ thetaIncidentOptions: [],
|
|
|
+ phiIncidentOptions: [],
|
|
|
+ thetaReflectedOptions: [],
|
|
|
+ phiReflectedList: [],
|
|
|
+ },
|
|
|
+ };
|
|
|
+ });
|
|
|
+ },
|
|
|
+ changeSampleType(val) {
|
|
|
+ this.showResult = false;
|
|
|
+ const dataType = this.queryParams.dataType;
|
|
|
+ this.queryParams = {
|
|
|
+ dataType,
|
|
|
+ sampleType: val,
|
|
|
+ sampleModel: null,
|
|
|
+ temperatureK: null,
|
|
|
+ wavelengthUm: null,
|
|
|
+ thetaIncident: null,
|
|
|
+ phiIncident: null,
|
|
|
+ thetaReflected: null,
|
|
|
+ phiReflected: null,
|
|
|
+ };
|
|
|
+ getSampleModel(this.queryParams).then((resp) => {
|
|
|
+ this.options.sampleModelOption = resp.data;
|
|
|
+ this.options.allAngleOption = {
|
|
|
+ thetaIncidentOptions: [],
|
|
|
+ phiIncidentOptions: [],
|
|
|
+ thetaReflectedOptions: [],
|
|
|
+ phiReflectedList: [],
|
|
|
+ };
|
|
|
+ });
|
|
|
+ },
|
|
|
+ changeSampleModel(val) {
|
|
|
+ this.showResult = false;
|
|
|
+ const dataType = this.queryParams.dataType;
|
|
|
+ const sampleType = this.queryParams.sampleType;
|
|
|
+ this.queryParams = {
|
|
|
+ dataType,
|
|
|
+ sampleType,
|
|
|
+ sampleModel: val,
|
|
|
+ temperatureK: null,
|
|
|
+ wavelengthUm: null,
|
|
|
+ thetaIncident: null,
|
|
|
+ phiIncident: null,
|
|
|
+ thetaReflected: null,
|
|
|
+ phiReflected: null,
|
|
|
};
|
|
|
- getOthersOptions(params).then((resp) => {
|
|
|
- this.options.sampleTypeOption = resp.data.sampleTypeOptions;
|
|
|
- this.options.sampleModelOption = resp.data.sampleModelOptions;
|
|
|
+ getOthersOptions(this.queryParams).then((resp) => {
|
|
|
this.options.temperatureKOption = resp.data.temperatureKOptions;
|
|
|
this.options.allAngleOption = resp.data.allAngleOptions;
|
|
|
});
|
|
|
},
|
|
|
+
|
|
|
// 修改 initChart 方法
|
|
|
initChart() {
|
|
|
// 确保容器存在
|