Compare commits
No commits in common. '47a6eec1bcab5a9b1bbcb766d979a8d5b86ec119' and '947a4fc2122d589a274af51e1f614457df270f1d' have entirely different histories.
47a6eec1bc
...
947a4fc212
@ -1,80 +0,0 @@
|
|||||||
import request from '@/utils/request'
|
|
||||||
|
|
||||||
// 新增能源设备
|
|
||||||
export function createEnergyDevice(data) {
|
|
||||||
return request({
|
|
||||||
url: '/admin-api/mes/energy-device/create',
|
|
||||||
method: 'POST',
|
|
||||||
data: data
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 查询能源设备详情
|
|
||||||
export function getEnergyDeviceById(id) {
|
|
||||||
return request({
|
|
||||||
url: '/admin-api/mes/energy-device/get?id=' + id,
|
|
||||||
method: 'GET',
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 修改能源设备
|
|
||||||
export function updateEnergyDevice(data) {
|
|
||||||
return request({
|
|
||||||
url: '/admin-api/mes/energy-device/update',
|
|
||||||
method: 'PUT',
|
|
||||||
data: data
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// 查询能源设备列表
|
|
||||||
export function getEnergyDevice(params) {
|
|
||||||
return request({
|
|
||||||
url: '/admin-api/mes/energy-device/page',
|
|
||||||
method: 'GET',
|
|
||||||
params: params
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 删除能源设备
|
|
||||||
export function deleteEnergyDevice(id) {
|
|
||||||
return request({
|
|
||||||
url: '/admin-api/mes/energy-device/delete?id='+id,
|
|
||||||
method: 'DELETE'
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 新增抄表记录
|
|
||||||
export function createEnergyDeviceCheckRecord(data) {
|
|
||||||
return request({
|
|
||||||
url: '/admin-api/mes/energy-device/energy-device-check-record/create',
|
|
||||||
method: 'POST',
|
|
||||||
data: data
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 查询抄表记录
|
|
||||||
export function getEnergyDeviceCheckRecord(params) {
|
|
||||||
return request({
|
|
||||||
url: '/admin-api/mes/energy-device/energy-device-check-record/page',
|
|
||||||
method: 'GET',
|
|
||||||
params
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 修改抄表记录
|
|
||||||
export function updateEnergyDeviceCheckRecord(data) {
|
|
||||||
return request({
|
|
||||||
url: '/admin-api/mes/energy-device/update',
|
|
||||||
method: 'PUT',
|
|
||||||
data: data
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 删除抄表记录
|
|
||||||
export function deleteEnergyDeviceCheckRecordById(id) {
|
|
||||||
return request({
|
|
||||||
url: '/admin-api/mes/energy-device/energy-device-check-record/delete?id='+id,
|
|
||||||
method: 'DELETE'
|
|
||||||
})
|
|
||||||
}
|
|
||||||
@ -1,45 +0,0 @@
|
|||||||
import request from '@/utils/request'
|
|
||||||
|
|
||||||
// 查询产线工位列表
|
|
||||||
export function getListOrgWorker(params) {
|
|
||||||
return request({
|
|
||||||
url: '/admin-api/mes/organization/listOrgWorker',
|
|
||||||
method: 'GET',
|
|
||||||
params: params
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 获得班组成员
|
|
||||||
export function getUserList2(params) {
|
|
||||||
return request({
|
|
||||||
url: '/admin-api/mes/work-team/work-team-detail/getUserList2',
|
|
||||||
method: 'GET',
|
|
||||||
params: params
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 多个日期新增工位安排
|
|
||||||
export function createWorker(params) {
|
|
||||||
return request({
|
|
||||||
url: '/admin-api/mes/org-worker/createWorker',
|
|
||||||
method: 'GET',
|
|
||||||
params: params
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 查询工位安排分页
|
|
||||||
export function getOrgWorkerPage(params) {
|
|
||||||
return request({
|
|
||||||
url: '/admin-api/mes/org-worker/page',
|
|
||||||
method: 'GET',
|
|
||||||
params: params
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 删除工位安排
|
|
||||||
export function deleteOrgWorker(id) {
|
|
||||||
return request({
|
|
||||||
url: '/admin-api/mes/org-worker/delete?id='+id,
|
|
||||||
method: 'DELETE'
|
|
||||||
})
|
|
||||||
}
|
|
||||||
@ -1,89 +0,0 @@
|
|||||||
<template>
|
|
||||||
<view>
|
|
||||||
<u-sticky
|
|
||||||
class="sticky"
|
|
||||||
:custom-nav-height="0"
|
|
||||||
>
|
|
||||||
<u-navbar
|
|
||||||
title="重置最后抄表值"
|
|
||||||
bg-color="transparent"
|
|
||||||
:auto-back="true"
|
|
||||||
:title-style="{ fontWeight: 'bold' }"
|
|
||||||
safe-area-inset-top
|
|
||||||
placeholder
|
|
||||||
/>
|
|
||||||
</u-sticky>
|
|
||||||
<view class="container">
|
|
||||||
<!-- 自定义表单校验 -->
|
|
||||||
<uni-forms labelWidth="105px" :modelValue="formData">
|
|
||||||
<uni-forms-item label="名称">
|
|
||||||
<u-input v-model="formData.name" disabled/>
|
|
||||||
</uni-forms-item>
|
|
||||||
<uni-forms-item label="编码">
|
|
||||||
<u-input v-model="formData.code" disabled/>
|
|
||||||
</uni-forms-item>
|
|
||||||
<uni-forms-item label="上次抄表时间" name="lastCheckTime">
|
|
||||||
<uni-datetime-picker v-model="formData.lastCheckTime" type="date" :clear-icon="true" placeholder="选择上次抄表时间"/>
|
|
||||||
</uni-forms-item>
|
|
||||||
<uni-forms-item label="最后抄表值" name="lastCheckValue">
|
|
||||||
<u-input v-model="formData.lastCheckValue"></u-input>
|
|
||||||
</uni-forms-item>
|
|
||||||
</uni-forms>
|
|
||||||
<view class="u-flex justify-end">
|
|
||||||
<view @click="submit()">
|
|
||||||
<u-button type="success">
|
|
||||||
<uni-icons type="checkbox" class="u-m-r-10"/>
|
|
||||||
确定
|
|
||||||
</u-button></view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script setup>
|
|
||||||
import { ref } from "vue";
|
|
||||||
import { onLoad } from "@dcloudio/uni-app";
|
|
||||||
import tab from "@/plugins/tab";
|
|
||||||
import { updateEnergyDeviceCheckRecord } from "@/api/mes/application";
|
|
||||||
import modal from "@/plugins/modal";
|
|
||||||
|
|
||||||
const formData = ref({
|
|
||||||
name: undefined,
|
|
||||||
code: undefined,
|
|
||||||
id: undefined,
|
|
||||||
lastCheckTime: undefined,
|
|
||||||
lastCheckValue: undefined,
|
|
||||||
})
|
|
||||||
|
|
||||||
const submit = async ()=>{
|
|
||||||
await updateEnergyDeviceCheckRecord(formData.value)
|
|
||||||
modal.msgSuccess("修改成功")
|
|
||||||
await tab.navigateBack()
|
|
||||||
// 通知组件刷新列表
|
|
||||||
uni.$emit('success', true)
|
|
||||||
}
|
|
||||||
|
|
||||||
onLoad(() => {
|
|
||||||
formData.value.name = tab.getParams().name
|
|
||||||
formData.value.id = tab.getParams().id
|
|
||||||
formData.value.lastCheckTime = tab.getParams().time
|
|
||||||
formData.value.lastCheckValue = tab.getParams().value
|
|
||||||
formData.value.code = tab.getParams().code
|
|
||||||
formData.value.isEnable = tab.getParams().isEnable
|
|
||||||
});
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style lang="sass" scoped>
|
|
||||||
.sticky
|
|
||||||
background: linear-gradient(180deg, #d4e9ff 0%, #f3f9ff 100%)
|
|
||||||
backdrop-filter: blur(27.18px)
|
|
||||||
box-shadow: 0 1px 1px 0 rgba(0, 72, 145, 0.1), 0 0.5px 0 0 rgba(0, 0, 0, 0.1)
|
|
||||||
.container
|
|
||||||
padding: 20rpx
|
|
||||||
margin: 20rpx
|
|
||||||
background-color: #ffffff
|
|
||||||
.uniui-checkbox:before
|
|
||||||
color: #ffffff
|
|
||||||
.u-button
|
|
||||||
height: 35px
|
|
||||||
</style>
|
|
||||||
@ -1,119 +0,0 @@
|
|||||||
<template>
|
|
||||||
<view>
|
|
||||||
<u-sticky
|
|
||||||
class="sticky"
|
|
||||||
:custom-nav-height="0"
|
|
||||||
>
|
|
||||||
<u-navbar
|
|
||||||
title="我的应用"
|
|
||||||
bg-color="transparent"
|
|
||||||
:auto-back="false"
|
|
||||||
:title-style="{ fontWeight: 'bold' }"
|
|
||||||
left-icon=""
|
|
||||||
safe-area-inset-top
|
|
||||||
placeholder
|
|
||||||
/>
|
|
||||||
</u-sticky>
|
|
||||||
<view class="container-wrap">
|
|
||||||
<view
|
|
||||||
v-for="(item,index) in appList"
|
|
||||||
:key="item.title"
|
|
||||||
class="app-list"
|
|
||||||
>
|
|
||||||
<view
|
|
||||||
class="u-flex u-flex-between"
|
|
||||||
>
|
|
||||||
<view class="app-title">
|
|
||||||
{{ item.title }}
|
|
||||||
</view>
|
|
||||||
<u-icon
|
|
||||||
name="arrow-right"
|
|
||||||
color="#333333"
|
|
||||||
size="14"
|
|
||||||
/>
|
|
||||||
</view>
|
|
||||||
<u-row class="model-container">
|
|
||||||
<u-col v-for="(app, index) in item.list" :key="app.id" span="3">
|
|
||||||
<view class="u-flex u-flex-center" @click="navTo(path[index])">
|
|
||||||
<view class="item u-flex u-flex-column">
|
|
||||||
<u-image
|
|
||||||
:show-loading="true"
|
|
||||||
:src="app.img"
|
|
||||||
width="96rpx"
|
|
||||||
height="96rpx"
|
|
||||||
/>
|
|
||||||
<text class="text">
|
|
||||||
{{ app.text }}
|
|
||||||
</text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</u-col>
|
|
||||||
</u-row>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script setup>
|
|
||||||
import { ref } from 'vue'
|
|
||||||
import tab from "@/plugins/tab";
|
|
||||||
|
|
||||||
const appList = ref([
|
|
||||||
{
|
|
||||||
title: '基础数据',
|
|
||||||
list: [
|
|
||||||
{
|
|
||||||
id: 1,
|
|
||||||
img: '/static/images/icon/arrangement.png',
|
|
||||||
text: '工位安排'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: 2,
|
|
||||||
img: '/static/images/icon/energy.png',
|
|
||||||
text: '能源设备'
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
])
|
|
||||||
|
|
||||||
const path = ['/pages/application/components/deskArrangement','/pages/application/components/energyEquipment']
|
|
||||||
const navTo = (url) => {
|
|
||||||
tab.navigateTo(url)
|
|
||||||
}
|
|
||||||
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style lang="sass" scoped>
|
|
||||||
.page
|
|
||||||
width: 100%
|
|
||||||
|
|
||||||
.sticky
|
|
||||||
background: linear-gradient(180deg, #d4e9ff 0%, #f3f9ff 100%)
|
|
||||||
backdrop-filter: blur(27.18px)
|
|
||||||
box-shadow: 0 1px 1px 0 rgba(0, 72, 145, 0.1), 0 0.5px 0 0 rgba(0, 0, 0, 0.1)
|
|
||||||
|
|
||||||
.container-wrap
|
|
||||||
padding: 20rpx
|
|
||||||
.app-list
|
|
||||||
background-color: #ffffff
|
|
||||||
padding: 20rpx 10rpx
|
|
||||||
border-radius: 20rpx
|
|
||||||
.app-title
|
|
||||||
color: #343434
|
|
||||||
font-size: 28rpx
|
|
||||||
font-weight: bold
|
|
||||||
.model-container
|
|
||||||
flex-wrap: wrap
|
|
||||||
.item
|
|
||||||
box-sizing: border-box
|
|
||||||
padding: 24rpx
|
|
||||||
&:active
|
|
||||||
background-color: #f1f1f1
|
|
||||||
border-radius: 20rpx
|
|
||||||
.text
|
|
||||||
margin-top: 8rpx
|
|
||||||
color: #595959
|
|
||||||
font-size: 24rpx
|
|
||||||
+ .app-list
|
|
||||||
margin-top: 20rpx
|
|
||||||
</style>
|
|
||||||
Binary file not shown.
|
Before Width: | Height: | Size: 1.3 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 1.2 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 543 B |
Binary file not shown.
|
Before Width: | Height: | Size: 569 B |
Loading…
Reference in New Issue