jinlin
2026-02-27 884d1457cebbda20ad2539550062c408a58709be
web/src/components/major-selector/src/major-selector.vue
@@ -11,15 +11,15 @@
      value: [String, Array],
      modelId: {
        type: String,
        default: ""
        default: ''
      },
      shipId: {
        type: String,
        default: ""
        default: ''
      },
      projectId: {
        type: String,
        default: ""
        default: ''
      },
      multiple: {
        type: Boolean,
@@ -37,12 +37,12 @@
    },
    data() {
      return {
        url:'/sys/major/getList?modelId='+this.modelId+'&shipId='+this.shipId+'&projectId='+this.projectId,
        url: '/sys/major/getList?modelId=' + this.modelId + '&shipId=' + this.shipId + '&projectId=' + this.projectId,
        selectValue: this.value || ''
      }
    },
    watch: {
      'selectValue'(){
      'selectValue'() {
        if (this.multiple) {
          this.$emit('input', (this.selectValue || []).join(','))
        } else {
@@ -53,7 +53,7 @@
        this.selectValue = val
      },
      'projectId'() {
        this.url = '/sys/major/getList?modelId='+this.modelId+'&shipId='+this.shipId+'&projectId='+this.projectId
        this.url = '/sys/major/getList?modelId=' + this.modelId + '&shipId=' + this.shipId + '&projectId=' + this.projectId
      }
    },