|
@@ -14,7 +14,7 @@
|
|
|
<div v-if="image.level" class="image-level">
|
|
|
{{ image.level | levelNameFilter }}
|
|
|
</div>
|
|
|
- <div v-if="image.sample" class="image-sample">标</div>
|
|
|
+ <div v-if="IS_SAMPLE" class="image-sample">标</div>
|
|
|
<div
|
|
|
v-else
|
|
|
:class="[
|
|
@@ -79,6 +79,12 @@ export default {
|
|
|
computed: {
|
|
|
IS_LEVEL() {
|
|
|
return this.stage === "LEVEL" || this.stage === "ROUGH_LEVEL";
|
|
|
+ },
|
|
|
+ IS_SAMPLE() {
|
|
|
+ return (
|
|
|
+ (this.stage === "LEVEL" && this.image.sample) ||
|
|
|
+ (this.stage === "ROUGH_LEVEL" && this.image.roughSample)
|
|
|
+ );
|
|
|
}
|
|
|
},
|
|
|
created() {
|
|
@@ -105,6 +111,7 @@ export default {
|
|
|
mark: false,
|
|
|
markDisabled: false,
|
|
|
sample: false,
|
|
|
+ roughSample: false,
|
|
|
selected: false
|
|
|
},
|
|
|
loading: false,
|
|
@@ -149,12 +156,12 @@ export default {
|
|
|
this.$emit("on-mark", this.image.mark);
|
|
|
},
|
|
|
toSelect() {
|
|
|
- if (this.image.sample || !this.IS_LEVEL) return;
|
|
|
+ if (this.IS_SAMPLE || !this.IS_LEVEL) return;
|
|
|
this.image.selected = !this.image.selected;
|
|
|
this.$emit("to-select", this.image);
|
|
|
},
|
|
|
changeSelect(selected) {
|
|
|
- if (this.image.sample) return;
|
|
|
+ if (this.IS_SAMPLE) return;
|
|
|
this.image.selected = selected;
|
|
|
this.$emit("to-select", this.image);
|
|
|
}
|