jiangping
2024-09-29 918deb5b53d9226c93ebfeb4e981f7af4cac5107
最新版本
已修改3个文件
21 ■■■■ 文件已修改
admin/src/api/business/device.js 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
admin/src/components/business/OperaDeviceLedWindow.vue 9 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
admin/src/views/business/deviceLed.vue 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
admin/src/api/business/device.js
@@ -31,5 +31,5 @@
}
// 发生led屏内容
export function setLedContent (data) {
  return request.post('/visitsAdmin/cloudService/business/device/setLedContent', data)
  return request.post('/visitsAdmin/cloudService/business/hksync/setLedContent', data)
}
admin/src/components/business/OperaDeviceLedWindow.vue
@@ -9,6 +9,9 @@
            <el-form-item label="显示内容" prop="title">
                <el-input v-model="form.title" placeholder="请输入LED屏显示内容" v-trim/>
            </el-form-item>
            <el-form-item label="播放速度" prop="title">
                <el-input type="number" v-model="form.speed" placeholder="请输入播放速度(大于0数字)" v-trim/>
            </el-form-item>
        </el-form>
    </GlobalWindow>
</template>
@@ -25,7 +28,8 @@
      // 表单数据
      form: {
        id: null,
        title: ''
        title: '',
        speed: 13
      },
      // 验证规则
      rules: {
@@ -54,7 +58,8 @@
      // 调用新建接口
      this.isWorking = true
      this.api.setLedContent({
        id: this.form.id,
        deviceId: this.form.id,
        speed: this.form.speed,
        content: this.form.title
      })
        .then(() => {
admin/src/views/business/deviceLed.vue
@@ -32,6 +32,16 @@
                </el-table-column>
                <el-table-column prop="ip" label="设备ip"></el-table-column>
                <el-table-column prop="port" label="设备端口"></el-table-column>
              <el-table-column
                  v-if="containPermissions(['business:device:update' ])"
                  label="操作"
                  min-width="120"
                  fixed="right"
              >
                <template slot-scope="{row}">
                  <el-button type="text" @click="$refs.OperaDeviceLedWindow.open('设置屏显内容', row)" icon="el-icon-edit" v-permissions="['business:device:update']">设置屏显内容</el-button>
                </template>
              </el-table-column>
            </el-table>
            <pagination
                @size-change="handleSizeChange"