12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455 |
- <template>
- <view class="control">
- <view class="control-title">
- 基础控制
- </view>
- <view class="current">
- <view class="item" v-for="item in preview" :key="item.w_functionid">
- <view class="label">{{ item.paramName }}</view>
- <view class="value">{{ item.lastvalue || '' }}{{ item.unit || '' }}</view>
- </view>
- </view>
- <view class="show-list">
- <control-item v-for="item in itemList" :key="item.w_functionid" :item="item" @click.native="onClick(item)" />
- </view>
- <My_input ref="MyInput" />
- </view>
- </template>
- <script>
- export default {
- name: "basics",
- data() {
- return {
- itemList: [],
- preview: []
- }
- },
- methods: {
- onClick(item) {
- this.$refs.MyInput.openInput(item)
- }
- }
- }
- </script>
- <style lang="scss" scoped>
- .current {
- display: flex;
- justify-content: space-around;
- color: #fff;
- margin-bottom: 10px;
- font-size: 12px;
- .label {
- margin-bottom: 5px;
- }
- }
- .show-list {
- display: flex;
- flex-wrap: wrap;
- justify-content: space-between;
- margin-top: -5px;
- box-sizing: border-box;
- }
- </style>
|