parent
f6573bb833
commit
ca404625ba
@ -0,0 +1,317 @@
|
||||
<template>
|
||||
<a-card :bordered="false">
|
||||
<!-- 查询区域 -->
|
||||
<div class="table-page-search-wrapper">
|
||||
<a-form layout="inline" @keyup.enter.native="searchQuery">
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="8">
|
||||
<a-form-item
|
||||
label="机台"
|
||||
name="equipNo"
|
||||
>
|
||||
<a-input v-model:value="queryParam.equipNo" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="8">
|
||||
<a-form-model-item label="日期" name="startEndDate">
|
||||
<a-range-picker
|
||||
v-model="queryParam.startEndDate"
|
||||
format="YYYY-MM-DD"
|
||||
name="buildTime"
|
||||
style="width: 100%"
|
||||
@change="handleDate"
|
||||
v-decorator="[
|
||||
'buildTime',
|
||||
{rules: [{ required: true, message: '请选择起止日期' }]}
|
||||
]" />
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="8">
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form>
|
||||
</div>
|
||||
<!-- 查询区域-END -->
|
||||
|
||||
<!-- 操作按钮区域 -->
|
||||
<div class="table-operator">
|
||||
<!-- <a-button @click="handleAdd" type="primary" icon="plus">新增</a-button> -->
|
||||
<a-button @click="searchQuery" type="primary" icon="search">查询</a-button>
|
||||
<a-button type="primary" icon="download" @click="handleExportXls('tt_inject_spot_data')">导出</a-button>
|
||||
<!-- <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel">
|
||||
<a-button type="primary" icon="import">导入</a-button>
|
||||
</a-upload>
|
||||
<j-super-query :fieldList="superFieldList" ref="superQueryModal" @handleSuperQuery="handleSuperQuery"></j-super-query> -->
|
||||
<a-dropdown v-if="selectedRowKeys.length > 0">
|
||||
<a-menu slot="overlay">
|
||||
<a-menu-item key="1" @click="batchDel"><a-icon type="delete"/>删除</a-menu-item>
|
||||
</a-menu>
|
||||
<a-button style="margin-left: 8px"> 批量操作 <a-icon type="down" /></a-button>
|
||||
</a-dropdown>
|
||||
</div>
|
||||
|
||||
<!-- table区域-begin -->
|
||||
<div>
|
||||
<div class="ant-alert ant-alert-info" style="margin-bottom: 16px;">
|
||||
<i class="anticon anticon-info-circle ant-alert-icon"></i> 已选择 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>项
|
||||
<a style="margin-left: 24px" @click="onClearSelected">清空</a>
|
||||
</div>
|
||||
|
||||
<a-table
|
||||
ref="table"
|
||||
size="middle"
|
||||
:scroll="{x:true}"
|
||||
bordered
|
||||
rowKey="id"
|
||||
:columns="columns"
|
||||
:dataSource="dataSource"
|
||||
:pagination="ipagination"
|
||||
:loading="loading"
|
||||
:rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
|
||||
class="j-table-force-nowrap"
|
||||
@change="handleTableChange">
|
||||
|
||||
<template slot="htmlSlot" slot-scope="text">
|
||||
<div v-html="text"></div>
|
||||
</template>
|
||||
<template slot="imgSlot" slot-scope="text,record">
|
||||
<span v-if="!text" style="font-size: 12px;font-style: italic;">无图片</span>
|
||||
<img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/>
|
||||
</template>
|
||||
<template slot="fileSlot" slot-scope="text">
|
||||
<span v-if="!text" style="font-size: 12px;font-style: italic;">无文件</span>
|
||||
<a-button
|
||||
v-else
|
||||
:ghost="true"
|
||||
type="primary"
|
||||
icon="download"
|
||||
size="small"
|
||||
@click="downloadFile(text)">
|
||||
下载
|
||||
</a-button>
|
||||
</template>
|
||||
|
||||
<span slot="action" slot-scope="text, record">
|
||||
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
|
||||
<a>删除</a>
|
||||
</a-popconfirm>
|
||||
<!-- <a @click="handleEdit(record)">编辑</a>
|
||||
|
||||
<a-divider type="vertical" />
|
||||
<a-dropdown>
|
||||
<a class="ant-dropdown-link">更多 <a-icon type="down" /></a>
|
||||
<a-menu slot="overlay">
|
||||
<a-menu-item>
|
||||
<a @click="handleDetail(record)">详情</a>
|
||||
</a-menu-item>
|
||||
<a-menu-item>
|
||||
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
|
||||
<a>删除</a>
|
||||
</a-popconfirm>
|
||||
</a-menu-item>
|
||||
</a-menu>
|
||||
</a-dropdown> -->
|
||||
</span>
|
||||
|
||||
</a-table>
|
||||
</div>
|
||||
|
||||
<tt-inject-spot-data-modal ref="modalForm" @ok="modalFormOk"></tt-inject-spot-data-modal>
|
||||
</a-card>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import '@/assets/less/TableExpand.less'
|
||||
import { mixinDevice } from '@/utils/mixin'
|
||||
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
|
||||
import TtInjectSpotDataModal from './modules/TtInjectSpotDataModal'
|
||||
|
||||
export default {
|
||||
name: 'TtInjectSpotDataList',
|
||||
mixins:[JeecgListMixin, mixinDevice],
|
||||
components: {
|
||||
TtInjectSpotDataModal
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
description: 'tt_inject_spot_data管理页面',
|
||||
// 表头
|
||||
columns: [
|
||||
{
|
||||
title: '#',
|
||||
dataIndex: '',
|
||||
key:'rowIndex',
|
||||
width:60,
|
||||
align:"center",
|
||||
customRender:function (t,r,index) {
|
||||
return parseInt(index)+1;
|
||||
}
|
||||
},
|
||||
{
|
||||
title:'日期',
|
||||
align:"center",
|
||||
dataIndex: 'dayName',
|
||||
sorter: true,
|
||||
customRender:function (text) {
|
||||
return !text?"":(text.length>10?text.substr(0,10):text)
|
||||
}
|
||||
},
|
||||
{
|
||||
title:'机台',
|
||||
align:"center",
|
||||
sorter: true,
|
||||
dataIndex: 'equipNo'
|
||||
},
|
||||
{
|
||||
title:'定模设定值',
|
||||
align:"center",
|
||||
dataIndex: 'fixedMoldCfgTemp'
|
||||
},
|
||||
{
|
||||
title:'定模实际值',
|
||||
align:"center",
|
||||
dataIndex: 'fixedMoldActTemp'
|
||||
},
|
||||
{
|
||||
title:'动模设定值',
|
||||
align:"center",
|
||||
dataIndex: 'dynamicMoldCfgTemp'
|
||||
},
|
||||
{
|
||||
title:'动模实际值',
|
||||
align:"center",
|
||||
dataIndex: 'dynamicMoldActTemp'
|
||||
},
|
||||
{
|
||||
title:'液压油温度',
|
||||
align:"center",
|
||||
dataIndex: 'hydraulicOilTemp'
|
||||
},
|
||||
{
|
||||
title:'干燥机滤芯',
|
||||
align:"center",
|
||||
dataIndex: 'dryer'
|
||||
},
|
||||
{
|
||||
title:'机台润滑油量',
|
||||
align:"center",
|
||||
dataIndex: 'lubricateOil'
|
||||
},
|
||||
{
|
||||
title:'清扫',
|
||||
align:"center",
|
||||
dataIndex: 'clean'
|
||||
},
|
||||
{
|
||||
title:'是否漏油/水',
|
||||
align:"center",
|
||||
dataIndex: 'noLeakageOil'
|
||||
},
|
||||
{
|
||||
title:'动作确认',
|
||||
align:"center",
|
||||
dataIndex: 'actConfirm'
|
||||
},
|
||||
{
|
||||
title:'压力计',
|
||||
align:"center",
|
||||
dataIndex: 'pressureGauge'
|
||||
},
|
||||
{
|
||||
title:'模具松紧',
|
||||
align:"center",
|
||||
dataIndex: 'moldTightness'
|
||||
},
|
||||
{
|
||||
title:'材料干燥温度设定值',
|
||||
align:"center",
|
||||
dataIndex: 'materialDryCfgTemp'
|
||||
},
|
||||
{
|
||||
title:'材料干燥温度实际值',
|
||||
align:"center",
|
||||
dataIndex: 'materialDryActTemp'
|
||||
},
|
||||
{
|
||||
title:'担当',
|
||||
align:"center",
|
||||
dataIndex: 'operator'
|
||||
},
|
||||
{
|
||||
title:'确认',
|
||||
align:"center",
|
||||
dataIndex: 'confirmUser'
|
||||
},
|
||||
{
|
||||
title:'备注',
|
||||
align:"center",
|
||||
dataIndex: 'remark'
|
||||
},
|
||||
{
|
||||
title: '操作',
|
||||
dataIndex: 'action',
|
||||
align:"center",
|
||||
fixed:"right",
|
||||
width:147,
|
||||
scopedSlots: { customRender: 'action' }
|
||||
}
|
||||
],
|
||||
url: {
|
||||
list: "/injectspotdata/ttInjectSpotData/list",
|
||||
delete: "/injectspotdata/ttInjectSpotData/delete",
|
||||
deleteBatch: "/injectspotdata/ttInjectSpotData/deleteBatch",
|
||||
exportXlsUrl: "/injectspotdata/ttInjectSpotData/exportXls",
|
||||
importExcelUrl: "injectspotdata/ttInjectSpotData/importExcel",
|
||||
|
||||
},
|
||||
dictOptions:{},
|
||||
superFieldList:[],
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getSuperFieldList();
|
||||
},
|
||||
computed: {
|
||||
importExcelUrl: function(){
|
||||
return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`;
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
initDictConfig(){
|
||||
},
|
||||
// 选择月份日期
|
||||
handleDate: function (value, dateString) {
|
||||
console.log(dateString[0],dateString[1]);
|
||||
this.queryParam.startDayName=dateString[0];
|
||||
this.queryParam.endDayName=dateString[1];
|
||||
},
|
||||
getSuperFieldList(){
|
||||
let fieldList=[];
|
||||
fieldList.push({type:'date',value:'dayName',text:'日期'})
|
||||
fieldList.push({type:'string',value:'equipNo',text:'机台'})
|
||||
fieldList.push({type:'string',value:'fixedMoldCfgTemp',text:'定模设定值'})
|
||||
fieldList.push({type:'string',value:'fixedMoldActTemp',text:'定模实际值'})
|
||||
fieldList.push({type:'string',value:'dynamicMoldCfgTemp',text:'动模设定值'})
|
||||
fieldList.push({type:'string',value:'dynamicMoldActTemp',text:'动模实际值'})
|
||||
fieldList.push({type:'string',value:'hydraulicOilTemp',text:'液压油温度'})
|
||||
fieldList.push({type:'string',value:'dryer',text:'干燥机滤芯'})
|
||||
fieldList.push({type:'string',value:'lubricateOil',text:'机台润滑油量'})
|
||||
fieldList.push({type:'string',value:'clean',text:'清扫'})
|
||||
fieldList.push({type:'string',value:'noLeakageOil',text:'是否漏油/水'})
|
||||
fieldList.push({type:'string',value:'actConfirm',text:'动作确认'})
|
||||
fieldList.push({type:'string',value:'pressureGauge',text:'压力计'})
|
||||
fieldList.push({type:'string',value:'moldTightness',text:'模具松紧'})
|
||||
fieldList.push({type:'string',value:'materialDryCfgTemp',text:'材料干燥温度设定值'})
|
||||
fieldList.push({type:'string',value:'materialDryActTemp',text:'材料干燥温度实际值'})
|
||||
fieldList.push({type:'string',value:'operator',text:'担当'})
|
||||
fieldList.push({type:'string',value:'confirmUser',text:'确认'})
|
||||
fieldList.push({type:'string',value:'remark',text:'备注'})
|
||||
this.superFieldList = fieldList
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style scoped>
|
||||
@import '~@assets/less/common.less';
|
||||
</style>
|
@ -0,0 +1,194 @@
|
||||
<template>
|
||||
<a-spin :spinning="confirmLoading">
|
||||
<j-form-container :disabled="formDisabled">
|
||||
<a-form-model ref="form" :model="model" :rules="validatorRules" slot="detail">
|
||||
<a-row>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="日期" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="dayName">
|
||||
<j-date placeholder="请选择日期" v-model="model.dayName" style="width: 100%" />
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="机台" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="equipNo">
|
||||
<a-input v-model="model.equipNo" placeholder="请输入机台" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="定模设定值" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="fixedMoldCfgTemp">
|
||||
<a-input v-model="model.fixedMoldCfgTemp" placeholder="请输入定模设定值" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="定模实际值" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="fixedMoldActTemp">
|
||||
<a-input v-model="model.fixedMoldActTemp" placeholder="请输入定模实际值" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="动模设定值" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="dynamicMoldCfgTemp">
|
||||
<a-input v-model="model.dynamicMoldCfgTemp" placeholder="请输入动模设定值" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="动模实际值" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="dynamicMoldActTemp">
|
||||
<a-input v-model="model.dynamicMoldActTemp" placeholder="请输入动模实际值" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="液压油温度" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="hydraulicOilTemp">
|
||||
<a-input v-model="model.hydraulicOilTemp" placeholder="请输入液压油温度" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="干燥机滤芯" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="dryer">
|
||||
<a-input v-model="model.dryer" placeholder="请输入干燥机滤芯" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="机台润滑油量" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="lubricateOil">
|
||||
<a-input v-model="model.lubricateOil" placeholder="请输入机台润滑油量" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="清扫" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="clean">
|
||||
<a-input v-model="model.clean" placeholder="请输入清扫" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="是否漏油/水" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="noLeakageOil">
|
||||
<a-input v-model="model.noLeakageOil" placeholder="请输入是否漏油/水" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="动作确认" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="actConfirm">
|
||||
<a-input v-model="model.actConfirm" placeholder="请输入动作确认" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="压力计" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="pressureGauge">
|
||||
<a-input v-model="model.pressureGauge" placeholder="请输入压力计" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="模具松紧" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="moldTightness">
|
||||
<a-input v-model="model.moldTightness" placeholder="请输入模具松紧" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="材料干燥温度设定值" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="materialDryCfgTemp">
|
||||
<a-input v-model="model.materialDryCfgTemp" placeholder="请输入材料干燥温度设定值" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="材料干燥温度实际值" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="materialDryActTemp">
|
||||
<a-input v-model="model.materialDryActTemp" placeholder="请输入材料干燥温度实际值" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="担当" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="operator">
|
||||
<a-input v-model="model.operator" placeholder="请输入担当" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="确认" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="confirmUser">
|
||||
<a-input v-model="model.confirmUser" placeholder="请输入确认" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="备注" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="remark">
|
||||
<a-input v-model="model.remark" placeholder="请输入备注" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form-model>
|
||||
</j-form-container>
|
||||
</a-spin>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import { httpAction, getAction } from '@/api/manage'
|
||||
import { validateDuplicateValue } from '@/utils/util'
|
||||
|
||||
export default {
|
||||
name: 'TtInjectSpotDataForm',
|
||||
components: {
|
||||
},
|
||||
props: {
|
||||
//表单禁用
|
||||
disabled: {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
required: false
|
||||
}
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
model:{
|
||||
},
|
||||
labelCol: {
|
||||
xs: { span: 24 },
|
||||
sm: { span: 5 },
|
||||
},
|
||||
wrapperCol: {
|
||||
xs: { span: 24 },
|
||||
sm: { span: 16 },
|
||||
},
|
||||
confirmLoading: false,
|
||||
validatorRules: {
|
||||
},
|
||||
url: {
|
||||
add: "/injectspotdata/ttInjectSpotData/add",
|
||||
edit: "/injectspotdata/ttInjectSpotData/edit",
|
||||
queryById: "/injectspotdata/ttInjectSpotData/queryById"
|
||||
}
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
formDisabled(){
|
||||
return this.disabled
|
||||
},
|
||||
},
|
||||
created () {
|
||||
//备份model原始值
|
||||
this.modelDefault = JSON.parse(JSON.stringify(this.model));
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.edit(this.modelDefault);
|
||||
},
|
||||
edit (record) {
|
||||
this.model = Object.assign({}, record);
|
||||
this.visible = true;
|
||||
},
|
||||
submitForm () {
|
||||
const that = this;
|
||||
// 触发表单验证
|
||||
this.$refs.form.validate(valid => {
|
||||
if (valid) {
|
||||
that.confirmLoading = true;
|
||||
let httpurl = '';
|
||||
let method = '';
|
||||
if(!this.model.id){
|
||||
httpurl+=this.url.add;
|
||||
method = 'post';
|
||||
}else{
|
||||
httpurl+=this.url.edit;
|
||||
method = 'put';
|
||||
}
|
||||
httpAction(httpurl,this.model,method).then((res)=>{
|
||||
if(res.success){
|
||||
that.$message.success(res.message);
|
||||
that.$emit('ok');
|
||||
}else{
|
||||
that.$message.warning(res.message);
|
||||
}
|
||||
}).finally(() => {
|
||||
that.confirmLoading = false;
|
||||
})
|
||||
}
|
||||
|
||||
})
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
@ -0,0 +1,84 @@
|
||||
<template>
|
||||
<a-drawer
|
||||
:title="title"
|
||||
:width="width"
|
||||
placement="right"
|
||||
:closable="false"
|
||||
@close="close"
|
||||
destroyOnClose
|
||||
:visible="visible">
|
||||
<tt-inject-spot-data-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit" normal></tt-inject-spot-data-form>
|
||||
<div class="drawer-footer">
|
||||
<a-button @click="handleCancel" style="margin-bottom: 0;">关闭</a-button>
|
||||
<a-button v-if="!disableSubmit" @click="handleOk" type="primary" style="margin-bottom: 0;">提交</a-button>
|
||||
</div>
|
||||
</a-drawer>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import TtInjectSpotDataForm from './TtInjectSpotDataForm'
|
||||
|
||||
export default {
|
||||
name: 'TtInjectSpotDataModal',
|
||||
components: {
|
||||
TtInjectSpotDataForm
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
title:"操作",
|
||||
width:800,
|
||||
visible: false,
|
||||
disableSubmit: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.add();
|
||||
})
|
||||
},
|
||||
edit (record) {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.edit(record);
|
||||
});
|
||||
},
|
||||
close () {
|
||||
this.$emit('close');
|
||||
this.visible = false;
|
||||
},
|
||||
submitCallback(){
|
||||
this.$emit('ok');
|
||||
this.visible = false;
|
||||
},
|
||||
handleOk () {
|
||||
this.$refs.realForm.submitForm();
|
||||
},
|
||||
handleCancel () {
|
||||
this.close()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
/** Button按钮间距 */
|
||||
.ant-btn {
|
||||
margin-left: 30px;
|
||||
margin-bottom: 30px;
|
||||
float: right;
|
||||
}
|
||||
.drawer-footer{
|
||||
position: absolute;
|
||||
bottom: -8px;
|
||||
width: 100%;
|
||||
border-top: 1px solid #e8e8e8;
|
||||
padding: 10px 16px;
|
||||
text-align: right;
|
||||
left: 0;
|
||||
background: #fff;
|
||||
border-radius: 0 0 2px 2px;
|
||||
}
|
||||
</style>
|
@ -0,0 +1,60 @@
|
||||
<template>
|
||||
<j-modal
|
||||
:title="title"
|
||||
:width="width"
|
||||
:visible="visible"
|
||||
switchFullscreen
|
||||
@ok="handleOk"
|
||||
:okButtonProps="{ class:{'jee-hidden': disableSubmit} }"
|
||||
@cancel="handleCancel"
|
||||
cancelText="关闭">
|
||||
<tt-inject-spot-data-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit"></tt-inject-spot-data-form>
|
||||
</j-modal>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import TtInjectSpotDataForm from './TtInjectSpotDataForm'
|
||||
export default {
|
||||
name: 'TtInjectSpotDataModal',
|
||||
components: {
|
||||
TtInjectSpotDataForm
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
title:'',
|
||||
width:800,
|
||||
visible: false,
|
||||
disableSubmit: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.add();
|
||||
})
|
||||
},
|
||||
edit (record) {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.edit(record);
|
||||
})
|
||||
},
|
||||
close () {
|
||||
this.$emit('close');
|
||||
this.visible = false;
|
||||
},
|
||||
handleOk () {
|
||||
this.$refs.realForm.submitForm();
|
||||
},
|
||||
submitCallback(){
|
||||
this.$emit('ok');
|
||||
this.visible = false;
|
||||
},
|
||||
handleCancel () {
|
||||
this.close()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
@ -0,0 +1,288 @@
|
||||
<template>
|
||||
<a-card :bordered="false">
|
||||
<!-- 查询区域 -->
|
||||
<div class="table-page-search-wrapper">
|
||||
<a-form layout="inline" @keyup.enter.native="searchQuery">
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="8">
|
||||
<a-form-item
|
||||
label="机台"
|
||||
name="equipNo"
|
||||
>
|
||||
<a-input v-model:value="queryParam.equipNo" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="8">
|
||||
<a-form-model-item label="日期" name="startEndDate">
|
||||
<a-range-picker
|
||||
v-model="queryParam.startEndDate"
|
||||
format="YYYY-MM-DD"
|
||||
name="buildTime"
|
||||
style="width: 100%"
|
||||
@change="handleDate"
|
||||
v-decorator="[
|
||||
'buildTime',
|
||||
{rules: [{ required: true, message: '请选择起止日期' }]}
|
||||
]" />
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="8">
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form>
|
||||
</div>
|
||||
<!-- 查询区域-END -->
|
||||
|
||||
<!-- 操作按钮区域 -->
|
||||
<div class="table-operator">
|
||||
<!-- <a-button @click="handleAdd" type="primary" icon="plus">新增</a-button> -->
|
||||
<a-button @click="searchQuery" type="primary" icon="search">查询</a-button>
|
||||
<a-button type="primary" icon="download" @click="handleExportXls('tt_ipqc_ma_data')">导出</a-button>
|
||||
<!-- <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel">
|
||||
<a-button type="primary" icon="import">导入</a-button>
|
||||
</a-upload>
|
||||
<j-super-query :fieldList="superFieldList" ref="superQueryModal" @handleSuperQuery="handleSuperQuery"></j-super-query> -->
|
||||
<a-dropdown v-if="selectedRowKeys.length > 0">
|
||||
<a-menu slot="overlay">
|
||||
<a-menu-item key="1" @click="batchDel"><a-icon type="delete"/>删除</a-menu-item>
|
||||
</a-menu>
|
||||
<a-button style="margin-left: 8px"> 批量操作 <a-icon type="down" /></a-button>
|
||||
</a-dropdown>
|
||||
</div>
|
||||
|
||||
<!-- table区域-begin -->
|
||||
<div>
|
||||
<div class="ant-alert ant-alert-info" style="margin-bottom: 16px;">
|
||||
<i class="anticon anticon-info-circle ant-alert-icon"></i> 已选择 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>项
|
||||
<a style="margin-left: 24px" @click="onClearSelected">清空</a>
|
||||
</div>
|
||||
|
||||
<a-table
|
||||
ref="table"
|
||||
size="middle"
|
||||
:scroll="{x:true}"
|
||||
bordered
|
||||
rowKey="id"
|
||||
:columns="columns"
|
||||
:dataSource="dataSource"
|
||||
:pagination="ipagination"
|
||||
:loading="loading"
|
||||
:rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
|
||||
class="j-table-force-nowrap"
|
||||
@change="handleTableChange">
|
||||
|
||||
<template slot="htmlSlot" slot-scope="text">
|
||||
<div v-html="text"></div>
|
||||
</template>
|
||||
<template slot="imgSlot" slot-scope="text,record">
|
||||
<span v-if="!text" style="font-size: 12px;font-style: italic;">无图片</span>
|
||||
<img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/>
|
||||
</template>
|
||||
<template slot="fileSlot" slot-scope="text">
|
||||
<span v-if="!text" style="font-size: 12px;font-style: italic;">无文件</span>
|
||||
<a-button
|
||||
v-else
|
||||
:ghost="true"
|
||||
type="primary"
|
||||
icon="download"
|
||||
size="small"
|
||||
@click="downloadFile(text)">
|
||||
下载
|
||||
</a-button>
|
||||
</template>
|
||||
|
||||
<span slot="action" slot-scope="text, record">
|
||||
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
|
||||
<a>删除</a>
|
||||
</a-popconfirm>
|
||||
</span>
|
||||
|
||||
</a-table>
|
||||
</div>
|
||||
|
||||
<tt-ipqc-ma-data-modal ref="modalForm" @ok="modalFormOk"></tt-ipqc-ma-data-modal>
|
||||
</a-card>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import '@/assets/less/TableExpand.less'
|
||||
import { mixinDevice } from '@/utils/mixin'
|
||||
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
|
||||
import TtIpqcMaDataModal from './modules/TtIpqcMaDataModal'
|
||||
|
||||
export default {
|
||||
name: 'TtIpqcMaDataList',
|
||||
mixins:[JeecgListMixin, mixinDevice],
|
||||
components: {
|
||||
TtIpqcMaDataModal
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
description: 'tt_ipqc_ma_data管理页面',
|
||||
// 表头
|
||||
columns: [
|
||||
{
|
||||
title: '#',
|
||||
dataIndex: '',
|
||||
key:'rowIndex',
|
||||
width:60,
|
||||
align:"center",
|
||||
customRender:function (t,r,index) {
|
||||
return parseInt(index)+1;
|
||||
}
|
||||
},
|
||||
{
|
||||
title:'日期',
|
||||
align:"center",
|
||||
dataIndex: 'day_name',
|
||||
sorter: true,
|
||||
customRender:function (text) {
|
||||
return !text?"":(text.length>10?text.substr(0,10):text)
|
||||
}
|
||||
},
|
||||
{
|
||||
title:'班次',
|
||||
align:"center",
|
||||
sorter: true,
|
||||
dataIndex: 'shift_name'
|
||||
},
|
||||
{
|
||||
title:'机台',
|
||||
align:"center",
|
||||
dataIndex: 'equip_no'
|
||||
},
|
||||
{
|
||||
title:'操作工',
|
||||
align:"center",
|
||||
dataIndex: 'operator'
|
||||
},
|
||||
{
|
||||
title:'规格',
|
||||
align:"center",
|
||||
dataIndex: 'spec'
|
||||
},
|
||||
{
|
||||
title:'胶料型号',
|
||||
align:"center",
|
||||
dataIndex: 'glue_type'
|
||||
},
|
||||
{
|
||||
title:'时间(单位:秒)',
|
||||
align:"center",
|
||||
dataIndex: 'sulf_time'
|
||||
},
|
||||
{
|
||||
title:'最低温度(℃)',
|
||||
align:"center",
|
||||
dataIndex: 'sulf_temp1'
|
||||
},
|
||||
{
|
||||
title:'最高温度(℃)',
|
||||
align:"center",
|
||||
dataIndex: 'sulf_temp2'
|
||||
},
|
||||
{
|
||||
title:'压力(Mpa)',
|
||||
align:"center",
|
||||
dataIndex: 'sulf_pressure'
|
||||
},
|
||||
{
|
||||
title:'厚度(mm)',
|
||||
align:"center",
|
||||
dataIndex: 'height'
|
||||
},
|
||||
{
|
||||
title:'外径(mm)',
|
||||
align:"center",
|
||||
dataIndex: 'external_size'
|
||||
},
|
||||
{
|
||||
title:'孔径(mm)',
|
||||
align:"center",
|
||||
dataIndex: 'aperture_size'
|
||||
},
|
||||
{
|
||||
title:'硬度(A)',
|
||||
align:"center",
|
||||
dataIndex: 'hardness'
|
||||
},
|
||||
{
|
||||
title:'外观检查结果',
|
||||
align:"center",
|
||||
dataIndex: 'desc1'
|
||||
},
|
||||
{
|
||||
title:'质检确认结果',
|
||||
align:"center",
|
||||
dataIndex: 'desc2'
|
||||
},
|
||||
{
|
||||
title:'IPQC人员',
|
||||
align:"center",
|
||||
dataIndex: 'ipqc_user'
|
||||
},
|
||||
{
|
||||
title:'硫化主管',
|
||||
align:"center",
|
||||
dataIndex: 'sulf_user'
|
||||
},
|
||||
{
|
||||
title:'品质主管',
|
||||
align:"center",
|
||||
dataIndex: 'qa_user'
|
||||
},
|
||||
{
|
||||
title: '操作',
|
||||
dataIndex: 'action',
|
||||
align:"center",
|
||||
fixed:"right",
|
||||
width:147,
|
||||
scopedSlots: { customRender: 'action' }
|
||||
}
|
||||
],
|
||||
url: {
|
||||
list: "/ipqcmadata/ttIpqcMaData/queryPageList",
|
||||
delete: "/ipqcmadata/ttIpqcMaData/delete",
|
||||
deleteBatch: "/ipqcmadata/ttIpqcMaData/deleteBatch",
|
||||
exportXlsUrl: "/ipqcmadata/ttIpqcMaData/exportXls",
|
||||
importExcelUrl: "ipqcmadata/ttIpqcMaData/importExcel",
|
||||
|
||||
},
|
||||
dictOptions:{},
|
||||
superFieldList:[],
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getSuperFieldList();
|
||||
},
|
||||
computed: {
|
||||
importExcelUrl: function(){
|
||||
return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`;
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
initDictConfig(){
|
||||
},
|
||||
// 选择月份日期
|
||||
handleDate: function (value, dateString) {
|
||||
console.log(dateString[0],dateString[1]);
|
||||
this.queryParam.startDayName=dateString[0];
|
||||
this.queryParam.endDayName=dateString[1];
|
||||
},
|
||||
getSuperFieldList(){
|
||||
let fieldList=[];
|
||||
fieldList.push({type:'date',value:'dayName',text:'日期名称'})
|
||||
fieldList.push({type:'string',value:'shiftName',text:'班次名称'})
|
||||
fieldList.push({type:'string',value:'ipqcStandard',text:'参考标准'})
|
||||
fieldList.push({type:'string',value:'ipqcUser',text:'ipqc用户'})
|
||||
fieldList.push({type:'string',value:'sulfUser',text:'硫化主管'})
|
||||
fieldList.push({type:'string',value:'qaUser',text:'品质主管'})
|
||||
this.superFieldList = fieldList
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style scoped>
|
||||
@import '~@assets/less/common.less';
|
||||
</style>
|
@ -0,0 +1,138 @@
|
||||
<template>
|
||||
<a-spin :spinning="confirmLoading">
|
||||
<j-form-container :disabled="formDisabled">
|
||||
<a-form-model ref="form" :model="model" :rules="validatorRules" slot="detail">
|
||||
<a-row>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="日期名称" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="dayName">
|
||||
<j-date placeholder="请选择日期名称" v-model="model.dayName" style="width: 100%" />
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="班次名称" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="shiftName">
|
||||
<a-input v-model="model.shiftName" placeholder="请输入班次名称" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="参考标准" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="ipqcStandard">
|
||||
<a-input v-model="model.ipqcStandard" placeholder="请输入参考标准" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="ipqc用户" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="ipqcUser">
|
||||
<a-input v-model="model.ipqcUser" placeholder="请输入ipqc用户" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="硫化主管" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="sulfUser">
|
||||
<a-input v-model="model.sulfUser" placeholder="请输入硫化主管" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="品质主管" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="qaUser">
|
||||
<a-input v-model="model.qaUser" placeholder="请输入品质主管" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form-model>
|
||||
</j-form-container>
|
||||
</a-spin>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import { httpAction, getAction } from '@/api/manage'
|
||||
import { validateDuplicateValue } from '@/utils/util'
|
||||
|
||||
export default {
|
||||
name: 'TtIpqcMaDataForm',
|
||||
components: {
|
||||
},
|
||||
props: {
|
||||
//表单禁用
|
||||
disabled: {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
required: false
|
||||
}
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
model:{
|
||||
},
|
||||
labelCol: {
|
||||
xs: { span: 24 },
|
||||
sm: { span: 5 },
|
||||
},
|
||||
wrapperCol: {
|
||||
xs: { span: 24 },
|
||||
sm: { span: 16 },
|
||||
},
|
||||
confirmLoading: false,
|
||||
validatorRules: {
|
||||
dayName: [
|
||||
{ required: true, message: '请输入日期名称!'},
|
||||
],
|
||||
shiftName: [
|
||||
{ required: true, message: '请输入班次名称!'},
|
||||
],
|
||||
ipqcStandard: [
|
||||
{ required: true, message: '请输入参考标准!'},
|
||||
],
|
||||
},
|
||||
url: {
|
||||
add: "/ipqcmadata/ttIpqcMaData/add",
|
||||
edit: "/ipqcmadata/ttIpqcMaData/edit",
|
||||
queryById: "/ipqcmadata/ttIpqcMaData/queryById"
|
||||
}
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
formDisabled(){
|
||||
return this.disabled
|
||||
},
|
||||
},
|
||||
created () {
|
||||
//备份model原始值
|
||||
this.modelDefault = JSON.parse(JSON.stringify(this.model));
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.edit(this.modelDefault);
|
||||
},
|
||||
edit (record) {
|
||||
this.model = Object.assign({}, record);
|
||||
this.visible = true;
|
||||
},
|
||||
submitForm () {
|
||||
const that = this;
|
||||
// 触发表单验证
|
||||
this.$refs.form.validate(valid => {
|
||||
if (valid) {
|
||||
that.confirmLoading = true;
|
||||
let httpurl = '';
|
||||
let method = '';
|
||||
if(!this.model.id){
|
||||
httpurl+=this.url.add;
|
||||
method = 'post';
|
||||
}else{
|
||||
httpurl+=this.url.edit;
|
||||
method = 'put';
|
||||
}
|
||||
httpAction(httpurl,this.model,method).then((res)=>{
|
||||
if(res.success){
|
||||
that.$message.success(res.message);
|
||||
that.$emit('ok');
|
||||
}else{
|
||||
that.$message.warning(res.message);
|
||||
}
|
||||
}).finally(() => {
|
||||
that.confirmLoading = false;
|
||||
})
|
||||
}
|
||||
|
||||
})
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
@ -0,0 +1,84 @@
|
||||
<template>
|
||||
<a-drawer
|
||||
:title="title"
|
||||
:width="width"
|
||||
placement="right"
|
||||
:closable="false"
|
||||
@close="close"
|
||||
destroyOnClose
|
||||
:visible="visible">
|
||||
<tt-ipqc-ma-data-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit" normal></tt-ipqc-ma-data-form>
|
||||
<div class="drawer-footer">
|
||||
<a-button @click="handleCancel" style="margin-bottom: 0;">关闭</a-button>
|
||||
<a-button v-if="!disableSubmit" @click="handleOk" type="primary" style="margin-bottom: 0;">提交</a-button>
|
||||
</div>
|
||||
</a-drawer>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import TtIpqcMaDataForm from './TtIpqcMaDataForm'
|
||||
|
||||
export default {
|
||||
name: 'TtIpqcMaDataModal',
|
||||
components: {
|
||||
TtIpqcMaDataForm
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
title:"操作",
|
||||
width:800,
|
||||
visible: false,
|
||||
disableSubmit: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.add();
|
||||
})
|
||||
},
|
||||
edit (record) {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.edit(record);
|
||||
});
|
||||
},
|
||||
close () {
|
||||
this.$emit('close');
|
||||
this.visible = false;
|
||||
},
|
||||
submitCallback(){
|
||||
this.$emit('ok');
|
||||
this.visible = false;
|
||||
},
|
||||
handleOk () {
|
||||
this.$refs.realForm.submitForm();
|
||||
},
|
||||
handleCancel () {
|
||||
this.close()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
/** Button按钮间距 */
|
||||
.ant-btn {
|
||||
margin-left: 30px;
|
||||
margin-bottom: 30px;
|
||||
float: right;
|
||||
}
|
||||
.drawer-footer{
|
||||
position: absolute;
|
||||
bottom: -8px;
|
||||
width: 100%;
|
||||
border-top: 1px solid #e8e8e8;
|
||||
padding: 10px 16px;
|
||||
text-align: right;
|
||||
left: 0;
|
||||
background: #fff;
|
||||
border-radius: 0 0 2px 2px;
|
||||
}
|
||||
</style>
|
@ -0,0 +1,60 @@
|
||||
<template>
|
||||
<j-modal
|
||||
:title="title"
|
||||
:width="width"
|
||||
:visible="visible"
|
||||
switchFullscreen
|
||||
@ok="handleOk"
|
||||
:okButtonProps="{ class:{'jee-hidden': disableSubmit} }"
|
||||
@cancel="handleCancel"
|
||||
cancelText="关闭">
|
||||
<tt-ipqc-ma-data-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit"></tt-ipqc-ma-data-form>
|
||||
</j-modal>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import TtIpqcMaDataForm from './TtIpqcMaDataForm'
|
||||
export default {
|
||||
name: 'TtIpqcMaDataModal',
|
||||
components: {
|
||||
TtIpqcMaDataForm
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
title:'',
|
||||
width:800,
|
||||
visible: false,
|
||||
disableSubmit: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.add();
|
||||
})
|
||||
},
|
||||
edit (record) {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.edit(record);
|
||||
})
|
||||
},
|
||||
close () {
|
||||
this.$emit('close');
|
||||
this.visible = false;
|
||||
},
|
||||
handleOk () {
|
||||
this.$refs.realForm.submitForm();
|
||||
},
|
||||
submitCallback(){
|
||||
this.$emit('ok');
|
||||
this.visible = false;
|
||||
},
|
||||
handleCancel () {
|
||||
this.close()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
@ -0,0 +1,184 @@
|
||||
package org.jeecg.modules.demo.injectspotdata.controller;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
import java.io.IOException;
|
||||
import java.io.UnsupportedEncodingException;
|
||||
import java.net.URLDecoder;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import org.jeecg.common.api.vo.Result;
|
||||
import org.jeecg.common.system.query.QueryGenerator;
|
||||
import org.jeecg.common.util.oConvertUtils;
|
||||
import org.jeecg.modules.demo.injectspotdata.entity.TtInjectSpotData;
|
||||
import org.jeecg.modules.demo.injectspotdata.service.ITtInjectSpotDataService;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
|
||||
import org.jeecgframework.poi.excel.ExcelImportUtil;
|
||||
import org.jeecgframework.poi.excel.def.NormalExcelConstants;
|
||||
import org.jeecgframework.poi.excel.entity.ExportParams;
|
||||
import org.jeecgframework.poi.excel.entity.ImportParams;
|
||||
import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
|
||||
import org.jeecg.common.system.base.controller.JeecgController;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
import org.springframework.web.multipart.MultipartHttpServletRequest;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.jeecg.common.aspect.annotation.AutoLog;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
|
||||
/**
|
||||
* @Description: tt_inject_spot_data
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Api(tags="tt_inject_spot_data")
|
||||
@RestController
|
||||
@RequestMapping("/injectspotdata/ttInjectSpotData")
|
||||
@Slf4j
|
||||
public class TtInjectSpotDataController extends JeecgController<TtInjectSpotData, ITtInjectSpotDataService> {
|
||||
@Autowired
|
||||
private ITtInjectSpotDataService ttInjectSpotDataService;
|
||||
|
||||
/**
|
||||
* 分页列表查询
|
||||
*
|
||||
* @param ttInjectSpotData
|
||||
* @param pageNo
|
||||
* @param pageSize
|
||||
* @param req
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_inject_spot_data-分页列表查询")
|
||||
@ApiOperation(value="tt_inject_spot_data-分页列表查询", notes="tt_inject_spot_data-分页列表查询")
|
||||
@GetMapping(value = "/list")
|
||||
public Result<IPage<TtInjectSpotData>> queryPageList(TtInjectSpotData ttInjectSpotData,
|
||||
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
||||
HttpServletRequest req) {
|
||||
QueryWrapper<TtInjectSpotData> queryWrapper = QueryGenerator.initQueryWrapper(ttInjectSpotData, req.getParameterMap());
|
||||
Page<TtInjectSpotData> page = new Page<TtInjectSpotData>(pageNo, pageSize);
|
||||
if(ttInjectSpotData.getStartDayName() != null){
|
||||
queryWrapper.gt("day_name", ttInjectSpotData.getStartDayName());
|
||||
}
|
||||
if(ttInjectSpotData.getEndDayName() != null){
|
||||
queryWrapper.lt("day_name", ttInjectSpotData.getEndDayName());
|
||||
}
|
||||
IPage<TtInjectSpotData> pageList = ttInjectSpotDataService.page(page, queryWrapper);
|
||||
return Result.OK(pageList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加
|
||||
*
|
||||
* @param ttInjectSpotData
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_inject_spot_data-添加")
|
||||
@ApiOperation(value="tt_inject_spot_data-添加", notes="tt_inject_spot_data-添加")
|
||||
//@RequiresPermissions("injectspotdata:tt_inject_spot_data:add")
|
||||
@PostMapping(value = "/add")
|
||||
public Result<String> add(@RequestBody TtInjectSpotData ttInjectSpotData) {
|
||||
ttInjectSpotDataService.save(ttInjectSpotData);
|
||||
return Result.OK("添加成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
*
|
||||
* @param ttInjectSpotData
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_inject_spot_data-编辑")
|
||||
@ApiOperation(value="tt_inject_spot_data-编辑", notes="tt_inject_spot_data-编辑")
|
||||
//@RequiresPermissions("injectspotdata:tt_inject_spot_data:edit")
|
||||
@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
|
||||
public Result<String> edit(@RequestBody TtInjectSpotData ttInjectSpotData) {
|
||||
ttInjectSpotDataService.updateById(ttInjectSpotData);
|
||||
return Result.OK("编辑成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_inject_spot_data-通过id删除")
|
||||
@ApiOperation(value="tt_inject_spot_data-通过id删除", notes="tt_inject_spot_data-通过id删除")
|
||||
//@RequiresPermissions("injectspotdata:tt_inject_spot_data:delete")
|
||||
@DeleteMapping(value = "/delete")
|
||||
public Result<String> delete(@RequestParam(name="id",required=true) String id) {
|
||||
ttInjectSpotDataService.removeById(id);
|
||||
return Result.OK("删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_inject_spot_data-批量删除")
|
||||
@ApiOperation(value="tt_inject_spot_data-批量删除", notes="tt_inject_spot_data-批量删除")
|
||||
//@RequiresPermissions("injectspotdata:tt_inject_spot_data:deleteBatch")
|
||||
@DeleteMapping(value = "/deleteBatch")
|
||||
public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
|
||||
this.ttInjectSpotDataService.removeByIds(Arrays.asList(ids.split(",")));
|
||||
return Result.OK("批量删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_inject_spot_data-通过id查询")
|
||||
@ApiOperation(value="tt_inject_spot_data-通过id查询", notes="tt_inject_spot_data-通过id查询")
|
||||
@GetMapping(value = "/queryById")
|
||||
public Result<TtInjectSpotData> queryById(@RequestParam(name="id",required=true) String id) {
|
||||
TtInjectSpotData ttInjectSpotData = ttInjectSpotDataService.getById(id);
|
||||
if(ttInjectSpotData==null) {
|
||||
return Result.error("未找到对应数据");
|
||||
}
|
||||
return Result.OK(ttInjectSpotData);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出excel
|
||||
*
|
||||
* @param request
|
||||
* @param ttInjectSpotData
|
||||
*/
|
||||
//@RequiresPermissions("injectspotdata:tt_inject_spot_data:exportXls")
|
||||
@RequestMapping(value = "/exportXls")
|
||||
public ModelAndView exportXls(HttpServletRequest request, TtInjectSpotData ttInjectSpotData) {
|
||||
return super.exportXls(request, ttInjectSpotData, TtInjectSpotData.class, "tt_inject_spot_data");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过excel导入数据
|
||||
*
|
||||
* @param request
|
||||
* @param response
|
||||
* @return
|
||||
*/
|
||||
//@RequiresPermissions("injectspotdata:tt_inject_spot_data:importExcel")
|
||||
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||
return super.importExcel(request, response, TtInjectSpotData.class);
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,125 @@
|
||||
package org.jeecg.modules.demo.injectspotdata.entity;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.io.UnsupportedEncodingException;
|
||||
import java.util.Date;
|
||||
import java.math.BigDecimal;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
import org.jeecgframework.poi.excel.annotation.Excel;
|
||||
import org.jeecg.common.aspect.annotation.Dict;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
/**
|
||||
* @Description: tt_inject_spot_data
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Data
|
||||
@TableName("tt_inject_spot_data")
|
||||
@Accessors(chain = true)
|
||||
@EqualsAndHashCode(callSuper = false)
|
||||
@ApiModel(value="tt_inject_spot_data对象", description="tt_inject_spot_data")
|
||||
public class TtInjectSpotData implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**id*/
|
||||
@TableId(type = IdType.ASSIGN_ID)
|
||||
@ApiModelProperty(value = "id")
|
||||
private Integer id;
|
||||
/**日期*/
|
||||
@Excel(name = "日期", width = 15, format = "yyyy-MM-dd")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
@ApiModelProperty(value = "日期")
|
||||
private Date dayName;
|
||||
/**机台*/
|
||||
@Excel(name = "机台", width = 15)
|
||||
@ApiModelProperty(value = "机台")
|
||||
private String equipNo;
|
||||
/**定模设定值*/
|
||||
@Excel(name = "定模设定值", width = 15)
|
||||
@ApiModelProperty(value = "定模设定值")
|
||||
private String fixedMoldCfgTemp;
|
||||
/**定模实际值*/
|
||||
@Excel(name = "定模实际值", width = 15)
|
||||
@ApiModelProperty(value = "定模实际值")
|
||||
private String fixedMoldActTemp;
|
||||
/**动模设定值*/
|
||||
@Excel(name = "动模设定值", width = 15)
|
||||
@ApiModelProperty(value = "动模设定值")
|
||||
private String dynamicMoldCfgTemp;
|
||||
/**动模实际值*/
|
||||
@Excel(name = "动模实际值", width = 15)
|
||||
@ApiModelProperty(value = "动模实际值")
|
||||
private String dynamicMoldActTemp;
|
||||
/**液压油温度*/
|
||||
@Excel(name = "液压油温度", width = 15)
|
||||
@ApiModelProperty(value = "液压油温度")
|
||||
private String hydraulicOilTemp;
|
||||
/**干燥机滤芯*/
|
||||
@Excel(name = "干燥机滤芯", width = 15)
|
||||
@ApiModelProperty(value = "干燥机滤芯")
|
||||
private String dryer;
|
||||
/**机台润滑油量*/
|
||||
@Excel(name = "机台润滑油量", width = 15)
|
||||
@ApiModelProperty(value = "机台润滑油量")
|
||||
private String lubricateOil;
|
||||
/**清扫*/
|
||||
@Excel(name = "清扫", width = 15)
|
||||
@ApiModelProperty(value = "清扫")
|
||||
private String clean;
|
||||
/**是否漏油/水*/
|
||||
@Excel(name = "是否漏油/水", width = 15)
|
||||
@ApiModelProperty(value = "是否漏油/水")
|
||||
private String noLeakageOil;
|
||||
/**动作确认*/
|
||||
@Excel(name = "动作确认", width = 15)
|
||||
@ApiModelProperty(value = "动作确认")
|
||||
private String actConfirm;
|
||||
/**压力计*/
|
||||
@Excel(name = "压力计", width = 15)
|
||||
@ApiModelProperty(value = "压力计")
|
||||
private String pressureGauge;
|
||||
/**模具松紧*/
|
||||
@Excel(name = "模具松紧", width = 15)
|
||||
@ApiModelProperty(value = "模具松紧")
|
||||
private String moldTightness;
|
||||
/**材料干燥温度设定值*/
|
||||
@Excel(name = "材料干燥温度设定值", width = 15)
|
||||
@ApiModelProperty(value = "材料干燥温度设定值")
|
||||
private String materialDryCfgTemp;
|
||||
/**材料干燥温度实际值*/
|
||||
@Excel(name = "材料干燥温度实际值", width = 15)
|
||||
@ApiModelProperty(value = "材料干燥温度实际值")
|
||||
private String materialDryActTemp;
|
||||
/**担当*/
|
||||
@Excel(name = "担当", width = 15)
|
||||
@ApiModelProperty(value = "担当")
|
||||
private String operator;
|
||||
/**确认*/
|
||||
@Excel(name = "确认", width = 15)
|
||||
@ApiModelProperty(value = "确认")
|
||||
private String confirmUser;
|
||||
/**备注*/
|
||||
@Excel(name = "备注", width = 15)
|
||||
@ApiModelProperty(value = "备注")
|
||||
private String remark;
|
||||
@TableField(exist = false)
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
@ApiModelProperty(value = "开始日期")
|
||||
private Date startDayName;
|
||||
@TableField(exist = false)
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
@ApiModelProperty(value = "结束日期")
|
||||
private Date endDayName;
|
||||
}
|
@ -0,0 +1,17 @@
|
||||
package org.jeecg.modules.demo.injectspotdata.mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.jeecg.modules.demo.injectspotdata.entity.TtInjectSpotData;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* @Description: tt_inject_spot_data
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface TtInjectSpotDataMapper extends BaseMapper<TtInjectSpotData> {
|
||||
|
||||
}
|
@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="org.jeecg.modules.demo.injectspotdata.mapper.TtInjectSpotDataMapper">
|
||||
|
||||
</mapper>
|
@ -0,0 +1,14 @@
|
||||
package org.jeecg.modules.demo.injectspotdata.service;
|
||||
|
||||
import org.jeecg.modules.demo.injectspotdata.entity.TtInjectSpotData;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
|
||||
/**
|
||||
* @Description: tt_inject_spot_data
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface ITtInjectSpotDataService extends IService<TtInjectSpotData> {
|
||||
|
||||
}
|
@ -0,0 +1,19 @@
|
||||
package org.jeecg.modules.demo.injectspotdata.service.impl;
|
||||
|
||||
import org.jeecg.modules.demo.injectspotdata.entity.TtInjectSpotData;
|
||||
import org.jeecg.modules.demo.injectspotdata.mapper.TtInjectSpotDataMapper;
|
||||
import org.jeecg.modules.demo.injectspotdata.service.ITtInjectSpotDataService;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
|
||||
/**
|
||||
* @Description: tt_inject_spot_data
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Service
|
||||
public class TtInjectSpotDataServiceImpl extends ServiceImpl<TtInjectSpotDataMapper, TtInjectSpotData> implements ITtInjectSpotDataService {
|
||||
|
||||
}
|
@ -0,0 +1,282 @@
|
||||
<template>
|
||||
<a-card :bordered="false">
|
||||
<!-- 查询区域 -->
|
||||
<div class="table-page-search-wrapper">
|
||||
<a-form layout="inline" @keyup.enter.native="searchQuery">
|
||||
<a-row :gutter="24">
|
||||
</a-row>
|
||||
</a-form>
|
||||
</div>
|
||||
<!-- 查询区域-END -->
|
||||
|
||||
<!-- 操作按钮区域 -->
|
||||
<div class="table-operator">
|
||||
<a-button @click="handleAdd" type="primary" icon="plus">新增</a-button>
|
||||
<a-button type="primary" icon="download" @click="handleExportXls('tt_inject_spot_data')">导出</a-button>
|
||||
<a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel">
|
||||
<a-button type="primary" icon="import">导入</a-button>
|
||||
</a-upload>
|
||||
<!-- 高级查询区域 -->
|
||||
<j-super-query :fieldList="superFieldList" ref="superQueryModal" @handleSuperQuery="handleSuperQuery"></j-super-query>
|
||||
<a-dropdown v-if="selectedRowKeys.length > 0">
|
||||
<a-menu slot="overlay">
|
||||
<a-menu-item key="1" @click="batchDel"><a-icon type="delete"/>删除</a-menu-item>
|
||||
</a-menu>
|
||||
<a-button style="margin-left: 8px"> 批量操作 <a-icon type="down" /></a-button>
|
||||
</a-dropdown>
|
||||
</div>
|
||||
|
||||
<!-- table区域-begin -->
|
||||
<div>
|
||||
<div class="ant-alert ant-alert-info" style="margin-bottom: 16px;">
|
||||
<i class="anticon anticon-info-circle ant-alert-icon"></i> 已选择 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>项
|
||||
<a style="margin-left: 24px" @click="onClearSelected">清空</a>
|
||||
</div>
|
||||
|
||||
<a-table
|
||||
ref="table"
|
||||
size="middle"
|
||||
:scroll="{x:true}"
|
||||
bordered
|
||||
rowKey="id"
|
||||
:columns="columns"
|
||||
:dataSource="dataSource"
|
||||
:pagination="ipagination"
|
||||
:loading="loading"
|
||||
:rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
|
||||
class="j-table-force-nowrap"
|
||||
@change="handleTableChange">
|
||||
|
||||
<template slot="htmlSlot" slot-scope="text">
|
||||
<div v-html="text"></div>
|
||||
</template>
|
||||
<template slot="imgSlot" slot-scope="text,record">
|
||||
<span v-if="!text" style="font-size: 12px;font-style: italic;">无图片</span>
|
||||
<img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/>
|
||||
</template>
|
||||
<template slot="fileSlot" slot-scope="text">
|
||||
<span v-if="!text" style="font-size: 12px;font-style: italic;">无文件</span>
|
||||
<a-button
|
||||
v-else
|
||||
:ghost="true"
|
||||
type="primary"
|
||||
icon="download"
|
||||
size="small"
|
||||
@click="downloadFile(text)">
|
||||
下载
|
||||
</a-button>
|
||||
</template>
|
||||
|
||||
<span slot="action" slot-scope="text, record">
|
||||
<a @click="handleEdit(record)">编辑</a>
|
||||
|
||||
<a-divider type="vertical" />
|
||||
<a-dropdown>
|
||||
<a class="ant-dropdown-link">更多 <a-icon type="down" /></a>
|
||||
<a-menu slot="overlay">
|
||||
<a-menu-item>
|
||||
<a @click="handleDetail(record)">详情</a>
|
||||
</a-menu-item>
|
||||
<a-menu-item>
|
||||
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
|
||||
<a>删除</a>
|
||||
</a-popconfirm>
|
||||
</a-menu-item>
|
||||
</a-menu>
|
||||
</a-dropdown>
|
||||
</span>
|
||||
|
||||
</a-table>
|
||||
</div>
|
||||
|
||||
<tt-inject-spot-data-modal ref="modalForm" @ok="modalFormOk"></tt-inject-spot-data-modal>
|
||||
</a-card>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import '@/assets/less/TableExpand.less'
|
||||
import { mixinDevice } from '@/utils/mixin'
|
||||
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
|
||||
import TtInjectSpotDataModal from './modules/TtInjectSpotDataModal'
|
||||
|
||||
export default {
|
||||
name: 'TtInjectSpotDataList',
|
||||
mixins:[JeecgListMixin, mixinDevice],
|
||||
components: {
|
||||
TtInjectSpotDataModal
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
description: 'tt_inject_spot_data管理页面',
|
||||
// 表头
|
||||
columns: [
|
||||
{
|
||||
title: '#',
|
||||
dataIndex: '',
|
||||
key:'rowIndex',
|
||||
width:60,
|
||||
align:"center",
|
||||
customRender:function (t,r,index) {
|
||||
return parseInt(index)+1;
|
||||
}
|
||||
},
|
||||
{
|
||||
title:'日期',
|
||||
align:"center",
|
||||
dataIndex: 'dayName',
|
||||
customRender:function (text) {
|
||||
return !text?"":(text.length>10?text.substr(0,10):text)
|
||||
}
|
||||
},
|
||||
{
|
||||
title:'机台',
|
||||
align:"center",
|
||||
dataIndex: 'equipNo'
|
||||
},
|
||||
{
|
||||
title:'定模设定值',
|
||||
align:"center",
|
||||
dataIndex: 'fixedMoldCfgTemp'
|
||||
},
|
||||
{
|
||||
title:'定模实际值',
|
||||
align:"center",
|
||||
dataIndex: 'fixedMoldActTemp'
|
||||
},
|
||||
{
|
||||
title:'动模设定值',
|
||||
align:"center",
|
||||
dataIndex: 'dynamicMoldCfgTemp'
|
||||
},
|
||||
{
|
||||
title:'动模实际值',
|
||||
align:"center",
|
||||
dataIndex: 'dynamicMoldActTemp'
|
||||
},
|
||||
{
|
||||
title:'液压油温度',
|
||||
align:"center",
|
||||
dataIndex: 'hydraulicOilTemp'
|
||||
},
|
||||
{
|
||||
title:'干燥机滤芯',
|
||||
align:"center",
|
||||
dataIndex: 'dryer'
|
||||
},
|
||||
{
|
||||
title:'机台润滑油量',
|
||||
align:"center",
|
||||
dataIndex: 'lubricateOil'
|
||||
},
|
||||
{
|
||||
title:'清扫',
|
||||
align:"center",
|
||||
dataIndex: 'clean'
|
||||
},
|
||||
{
|
||||
title:'是否漏油/水',
|
||||
align:"center",
|
||||
dataIndex: 'noLeakageOil'
|
||||
},
|
||||
{
|
||||
title:'动作确认',
|
||||
align:"center",
|
||||
dataIndex: 'actConfirm'
|
||||
},
|
||||
{
|
||||
title:'压力计',
|
||||
align:"center",
|
||||
dataIndex: 'pressureGauge'
|
||||
},
|
||||
{
|
||||
title:'模具松紧',
|
||||
align:"center",
|
||||
dataIndex: 'moldTightness'
|
||||
},
|
||||
{
|
||||
title:'材料干燥温度设定值',
|
||||
align:"center",
|
||||
dataIndex: 'materialDryCfgTemp'
|
||||
},
|
||||
{
|
||||
title:'材料干燥温度实际值',
|
||||
align:"center",
|
||||
dataIndex: 'materialDryActTemp'
|
||||
},
|
||||
{
|
||||
title:'担当',
|
||||
align:"center",
|
||||
dataIndex: 'operator'
|
||||
},
|
||||
{
|
||||
title:'确认',
|
||||
align:"center",
|
||||
dataIndex: 'confirmUser'
|
||||
},
|
||||
{
|
||||
title:'备注',
|
||||
align:"center",
|
||||
dataIndex: 'remark'
|
||||
},
|
||||
{
|
||||
title: '操作',
|
||||
dataIndex: 'action',
|
||||
align:"center",
|
||||
fixed:"right",
|
||||
width:147,
|
||||
scopedSlots: { customRender: 'action' }
|
||||
}
|
||||
],
|
||||
url: {
|
||||
list: "/injectspotdata/ttInjectSpotData/list",
|
||||
delete: "/injectspotdata/ttInjectSpotData/delete",
|
||||
deleteBatch: "/injectspotdata/ttInjectSpotData/deleteBatch",
|
||||
exportXlsUrl: "/injectspotdata/ttInjectSpotData/exportXls",
|
||||
importExcelUrl: "injectspotdata/ttInjectSpotData/importExcel",
|
||||
|
||||
},
|
||||
dictOptions:{},
|
||||
superFieldList:[],
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getSuperFieldList();
|
||||
},
|
||||
computed: {
|
||||
importExcelUrl: function(){
|
||||
return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`;
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
initDictConfig(){
|
||||
},
|
||||
getSuperFieldList(){
|
||||
let fieldList=[];
|
||||
fieldList.push({type:'date',value:'dayName',text:'日期'})
|
||||
fieldList.push({type:'string',value:'equipNo',text:'机台'})
|
||||
fieldList.push({type:'string',value:'fixedMoldCfgTemp',text:'定模设定值'})
|
||||
fieldList.push({type:'string',value:'fixedMoldActTemp',text:'定模实际值'})
|
||||
fieldList.push({type:'string',value:'dynamicMoldCfgTemp',text:'动模设定值'})
|
||||
fieldList.push({type:'string',value:'dynamicMoldActTemp',text:'动模实际值'})
|
||||
fieldList.push({type:'string',value:'hydraulicOilTemp',text:'液压油温度'})
|
||||
fieldList.push({type:'string',value:'dryer',text:'干燥机滤芯'})
|
||||
fieldList.push({type:'string',value:'lubricateOil',text:'机台润滑油量'})
|
||||
fieldList.push({type:'string',value:'clean',text:'清扫'})
|
||||
fieldList.push({type:'string',value:'noLeakageOil',text:'是否漏油/水'})
|
||||
fieldList.push({type:'string',value:'actConfirm',text:'动作确认'})
|
||||
fieldList.push({type:'string',value:'pressureGauge',text:'压力计'})
|
||||
fieldList.push({type:'string',value:'moldTightness',text:'模具松紧'})
|
||||
fieldList.push({type:'string',value:'materialDryCfgTemp',text:'材料干燥温度设定值'})
|
||||
fieldList.push({type:'string',value:'materialDryActTemp',text:'材料干燥温度实际值'})
|
||||
fieldList.push({type:'string',value:'operator',text:'担当'})
|
||||
fieldList.push({type:'string',value:'confirmUser',text:'确认'})
|
||||
fieldList.push({type:'string',value:'remark',text:'备注'})
|
||||
this.superFieldList = fieldList
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style scoped>
|
||||
@import '~@assets/less/common.less';
|
||||
</style>
|
@ -0,0 +1,194 @@
|
||||
<template>
|
||||
<a-spin :spinning="confirmLoading">
|
||||
<j-form-container :disabled="formDisabled">
|
||||
<a-form-model ref="form" :model="model" :rules="validatorRules" slot="detail">
|
||||
<a-row>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="日期" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="dayName">
|
||||
<j-date placeholder="请选择日期" v-model="model.dayName" style="width: 100%" />
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="机台" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="equipNo">
|
||||
<a-input v-model="model.equipNo" placeholder="请输入机台" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="定模设定值" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="fixedMoldCfgTemp">
|
||||
<a-input v-model="model.fixedMoldCfgTemp" placeholder="请输入定模设定值" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="定模实际值" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="fixedMoldActTemp">
|
||||
<a-input v-model="model.fixedMoldActTemp" placeholder="请输入定模实际值" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="动模设定值" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="dynamicMoldCfgTemp">
|
||||
<a-input v-model="model.dynamicMoldCfgTemp" placeholder="请输入动模设定值" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="动模实际值" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="dynamicMoldActTemp">
|
||||
<a-input v-model="model.dynamicMoldActTemp" placeholder="请输入动模实际值" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="液压油温度" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="hydraulicOilTemp">
|
||||
<a-input v-model="model.hydraulicOilTemp" placeholder="请输入液压油温度" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="干燥机滤芯" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="dryer">
|
||||
<a-input v-model="model.dryer" placeholder="请输入干燥机滤芯" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="机台润滑油量" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="lubricateOil">
|
||||
<a-input v-model="model.lubricateOil" placeholder="请输入机台润滑油量" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="清扫" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="clean">
|
||||
<a-input v-model="model.clean" placeholder="请输入清扫" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="是否漏油/水" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="noLeakageOil">
|
||||
<a-input v-model="model.noLeakageOil" placeholder="请输入是否漏油/水" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="动作确认" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="actConfirm">
|
||||
<a-input v-model="model.actConfirm" placeholder="请输入动作确认" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="压力计" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="pressureGauge">
|
||||
<a-input v-model="model.pressureGauge" placeholder="请输入压力计" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="模具松紧" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="moldTightness">
|
||||
<a-input v-model="model.moldTightness" placeholder="请输入模具松紧" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="材料干燥温度设定值" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="materialDryCfgTemp">
|
||||
<a-input v-model="model.materialDryCfgTemp" placeholder="请输入材料干燥温度设定值" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="材料干燥温度实际值" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="materialDryActTemp">
|
||||
<a-input v-model="model.materialDryActTemp" placeholder="请输入材料干燥温度实际值" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="担当" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="operator">
|
||||
<a-input v-model="model.operator" placeholder="请输入担当" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="确认" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="confirmUser">
|
||||
<a-input v-model="model.confirmUser" placeholder="请输入确认" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="备注" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="remark">
|
||||
<a-input v-model="model.remark" placeholder="请输入备注" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form-model>
|
||||
</j-form-container>
|
||||
</a-spin>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import { httpAction, getAction } from '@/api/manage'
|
||||
import { validateDuplicateValue } from '@/utils/util'
|
||||
|
||||
export default {
|
||||
name: 'TtInjectSpotDataForm',
|
||||
components: {
|
||||
},
|
||||
props: {
|
||||
//表单禁用
|
||||
disabled: {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
required: false
|
||||
}
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
model:{
|
||||
},
|
||||
labelCol: {
|
||||
xs: { span: 24 },
|
||||
sm: { span: 5 },
|
||||
},
|
||||
wrapperCol: {
|
||||
xs: { span: 24 },
|
||||
sm: { span: 16 },
|
||||
},
|
||||
confirmLoading: false,
|
||||
validatorRules: {
|
||||
},
|
||||
url: {
|
||||
add: "/injectspotdata/ttInjectSpotData/add",
|
||||
edit: "/injectspotdata/ttInjectSpotData/edit",
|
||||
queryById: "/injectspotdata/ttInjectSpotData/queryById"
|
||||
}
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
formDisabled(){
|
||||
return this.disabled
|
||||
},
|
||||
},
|
||||
created () {
|
||||
//备份model原始值
|
||||
this.modelDefault = JSON.parse(JSON.stringify(this.model));
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.edit(this.modelDefault);
|
||||
},
|
||||
edit (record) {
|
||||
this.model = Object.assign({}, record);
|
||||
this.visible = true;
|
||||
},
|
||||
submitForm () {
|
||||
const that = this;
|
||||
// 触发表单验证
|
||||
this.$refs.form.validate(valid => {
|
||||
if (valid) {
|
||||
that.confirmLoading = true;
|
||||
let httpurl = '';
|
||||
let method = '';
|
||||
if(!this.model.id){
|
||||
httpurl+=this.url.add;
|
||||
method = 'post';
|
||||
}else{
|
||||
httpurl+=this.url.edit;
|
||||
method = 'put';
|
||||
}
|
||||
httpAction(httpurl,this.model,method).then((res)=>{
|
||||
if(res.success){
|
||||
that.$message.success(res.message);
|
||||
that.$emit('ok');
|
||||
}else{
|
||||
that.$message.warning(res.message);
|
||||
}
|
||||
}).finally(() => {
|
||||
that.confirmLoading = false;
|
||||
})
|
||||
}
|
||||
|
||||
})
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
@ -0,0 +1,84 @@
|
||||
<template>
|
||||
<a-drawer
|
||||
:title="title"
|
||||
:width="width"
|
||||
placement="right"
|
||||
:closable="false"
|
||||
@close="close"
|
||||
destroyOnClose
|
||||
:visible="visible">
|
||||
<tt-inject-spot-data-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit" normal></tt-inject-spot-data-form>
|
||||
<div class="drawer-footer">
|
||||
<a-button @click="handleCancel" style="margin-bottom: 0;">关闭</a-button>
|
||||
<a-button v-if="!disableSubmit" @click="handleOk" type="primary" style="margin-bottom: 0;">提交</a-button>
|
||||
</div>
|
||||
</a-drawer>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import TtInjectSpotDataForm from './TtInjectSpotDataForm'
|
||||
|
||||
export default {
|
||||
name: 'TtInjectSpotDataModal',
|
||||
components: {
|
||||
TtInjectSpotDataForm
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
title:"操作",
|
||||
width:800,
|
||||
visible: false,
|
||||
disableSubmit: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.add();
|
||||
})
|
||||
},
|
||||
edit (record) {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.edit(record);
|
||||
});
|
||||
},
|
||||
close () {
|
||||
this.$emit('close');
|
||||
this.visible = false;
|
||||
},
|
||||
submitCallback(){
|
||||
this.$emit('ok');
|
||||
this.visible = false;
|
||||
},
|
||||
handleOk () {
|
||||
this.$refs.realForm.submitForm();
|
||||
},
|
||||
handleCancel () {
|
||||
this.close()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
/** Button按钮间距 */
|
||||
.ant-btn {
|
||||
margin-left: 30px;
|
||||
margin-bottom: 30px;
|
||||
float: right;
|
||||
}
|
||||
.drawer-footer{
|
||||
position: absolute;
|
||||
bottom: -8px;
|
||||
width: 100%;
|
||||
border-top: 1px solid #e8e8e8;
|
||||
padding: 10px 16px;
|
||||
text-align: right;
|
||||
left: 0;
|
||||
background: #fff;
|
||||
border-radius: 0 0 2px 2px;
|
||||
}
|
||||
</style>
|
@ -0,0 +1,60 @@
|
||||
<template>
|
||||
<j-modal
|
||||
:title="title"
|
||||
:width="width"
|
||||
:visible="visible"
|
||||
switchFullscreen
|
||||
@ok="handleOk"
|
||||
:okButtonProps="{ class:{'jee-hidden': disableSubmit} }"
|
||||
@cancel="handleCancel"
|
||||
cancelText="关闭">
|
||||
<tt-inject-spot-data-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit"></tt-inject-spot-data-form>
|
||||
</j-modal>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import TtInjectSpotDataForm from './TtInjectSpotDataForm'
|
||||
export default {
|
||||
name: 'TtInjectSpotDataModal',
|
||||
components: {
|
||||
TtInjectSpotDataForm
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
title:'',
|
||||
width:800,
|
||||
visible: false,
|
||||
disableSubmit: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.add();
|
||||
})
|
||||
},
|
||||
edit (record) {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.edit(record);
|
||||
})
|
||||
},
|
||||
close () {
|
||||
this.$emit('close');
|
||||
this.visible = false;
|
||||
},
|
||||
handleOk () {
|
||||
this.$refs.realForm.submitForm();
|
||||
},
|
||||
submitCallback(){
|
||||
this.$emit('ok');
|
||||
this.visible = false;
|
||||
},
|
||||
handleCancel () {
|
||||
this.close()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
@ -0,0 +1,178 @@
|
||||
package org.jeecg.modules.demo.ipqcdedata.controller;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
import java.io.IOException;
|
||||
import java.io.UnsupportedEncodingException;
|
||||
import java.net.URLDecoder;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import org.jeecg.common.api.vo.Result;
|
||||
import org.jeecg.common.system.query.QueryGenerator;
|
||||
import org.jeecg.common.util.oConvertUtils;
|
||||
import org.jeecg.modules.demo.ipqcdedata.entity.TtIpqcDeData;
|
||||
import org.jeecg.modules.demo.ipqcdedata.service.ITtIpqcDeDataService;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
|
||||
import org.jeecgframework.poi.excel.ExcelImportUtil;
|
||||
import org.jeecgframework.poi.excel.def.NormalExcelConstants;
|
||||
import org.jeecgframework.poi.excel.entity.ExportParams;
|
||||
import org.jeecgframework.poi.excel.entity.ImportParams;
|
||||
import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
|
||||
import org.jeecg.common.system.base.controller.JeecgController;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
import org.springframework.web.multipart.MultipartHttpServletRequest;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.jeecg.common.aspect.annotation.AutoLog;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
|
||||
/**
|
||||
* @Description: tt_ipqc_de_data
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Api(tags="tt_ipqc_de_data")
|
||||
@RestController
|
||||
@RequestMapping("/ipqcdedata/ttIpqcDeData")
|
||||
@Slf4j
|
||||
public class TtIpqcDeDataController extends JeecgController<TtIpqcDeData, ITtIpqcDeDataService> {
|
||||
@Autowired
|
||||
private ITtIpqcDeDataService ttIpqcDeDataService;
|
||||
|
||||
/**
|
||||
* 分页列表查询
|
||||
*
|
||||
* @param ttIpqcDeData
|
||||
* @param pageNo
|
||||
* @param pageSize
|
||||
* @param req
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_ipqc_de_data-分页列表查询")
|
||||
@ApiOperation(value="tt_ipqc_de_data-分页列表查询", notes="tt_ipqc_de_data-分页列表查询")
|
||||
@GetMapping(value = "/list")
|
||||
public Result<IPage<TtIpqcDeData>> queryPageList(TtIpqcDeData ttIpqcDeData,
|
||||
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
||||
HttpServletRequest req) {
|
||||
QueryWrapper<TtIpqcDeData> queryWrapper = QueryGenerator.initQueryWrapper(ttIpqcDeData, req.getParameterMap());
|
||||
Page<TtIpqcDeData> page = new Page<TtIpqcDeData>(pageNo, pageSize);
|
||||
IPage<TtIpqcDeData> pageList = ttIpqcDeDataService.page(page, queryWrapper);
|
||||
return Result.OK(pageList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加
|
||||
*
|
||||
* @param ttIpqcDeData
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_ipqc_de_data-添加")
|
||||
@ApiOperation(value="tt_ipqc_de_data-添加", notes="tt_ipqc_de_data-添加")
|
||||
//@RequiresPermissions("ipqcdedata:tt_ipqc_de_data:add")
|
||||
@PostMapping(value = "/add")
|
||||
public Result<String> add(@RequestBody TtIpqcDeData ttIpqcDeData) {
|
||||
ttIpqcDeDataService.save(ttIpqcDeData);
|
||||
return Result.OK("添加成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
*
|
||||
* @param ttIpqcDeData
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_ipqc_de_data-编辑")
|
||||
@ApiOperation(value="tt_ipqc_de_data-编辑", notes="tt_ipqc_de_data-编辑")
|
||||
//@RequiresPermissions("ipqcdedata:tt_ipqc_de_data:edit")
|
||||
@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
|
||||
public Result<String> edit(@RequestBody TtIpqcDeData ttIpqcDeData) {
|
||||
ttIpqcDeDataService.updateById(ttIpqcDeData);
|
||||
return Result.OK("编辑成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_ipqc_de_data-通过id删除")
|
||||
@ApiOperation(value="tt_ipqc_de_data-通过id删除", notes="tt_ipqc_de_data-通过id删除")
|
||||
//@RequiresPermissions("ipqcdedata:tt_ipqc_de_data:delete")
|
||||
@DeleteMapping(value = "/delete")
|
||||
public Result<String> delete(@RequestParam(name="id",required=true) String id) {
|
||||
ttIpqcDeDataService.removeById(id);
|
||||
return Result.OK("删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_ipqc_de_data-批量删除")
|
||||
@ApiOperation(value="tt_ipqc_de_data-批量删除", notes="tt_ipqc_de_data-批量删除")
|
||||
//@RequiresPermissions("ipqcdedata:tt_ipqc_de_data:deleteBatch")
|
||||
@DeleteMapping(value = "/deleteBatch")
|
||||
public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
|
||||
this.ttIpqcDeDataService.removeByIds(Arrays.asList(ids.split(",")));
|
||||
return Result.OK("批量删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_ipqc_de_data-通过id查询")
|
||||
@ApiOperation(value="tt_ipqc_de_data-通过id查询", notes="tt_ipqc_de_data-通过id查询")
|
||||
@GetMapping(value = "/queryById")
|
||||
public Result<TtIpqcDeData> queryById(@RequestParam(name="id",required=true) String id) {
|
||||
TtIpqcDeData ttIpqcDeData = ttIpqcDeDataService.getById(id);
|
||||
if(ttIpqcDeData==null) {
|
||||
return Result.error("未找到对应数据");
|
||||
}
|
||||
return Result.OK(ttIpqcDeData);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出excel
|
||||
*
|
||||
* @param request
|
||||
* @param ttIpqcDeData
|
||||
*/
|
||||
//@RequiresPermissions("ipqcdedata:tt_ipqc_de_data:exportXls")
|
||||
@RequestMapping(value = "/exportXls")
|
||||
public ModelAndView exportXls(HttpServletRequest request, TtIpqcDeData ttIpqcDeData) {
|
||||
return super.exportXls(request, ttIpqcDeData, TtIpqcDeData.class, "tt_ipqc_de_data");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过excel导入数据
|
||||
*
|
||||
* @param request
|
||||
* @param response
|
||||
* @return
|
||||
*/
|
||||
//@RequiresPermissions("ipqcdedata:tt_ipqc_de_data:importExcel")
|
||||
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||
return super.importExcel(request, response, TtIpqcDeData.class);
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,17 @@
|
||||
package org.jeecg.modules.demo.ipqcdedata.mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.jeecg.modules.demo.ipqcdedata.entity.TtIpqcDeData;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* @Description: tt_ipqc_de_data
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface TtIpqcDeDataMapper extends BaseMapper<TtIpqcDeData> {
|
||||
|
||||
}
|
@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="org.jeecg.modules.demo.ipqcdedata.mapper.TtIpqcDeDataMapper">
|
||||
|
||||
</mapper>
|
@ -0,0 +1,14 @@
|
||||
package org.jeecg.modules.demo.ipqcdedata.service;
|
||||
|
||||
import org.jeecg.modules.demo.ipqcdedata.entity.TtIpqcDeData;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
|
||||
/**
|
||||
* @Description: tt_ipqc_de_data
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface ITtIpqcDeDataService extends IService<TtIpqcDeData> {
|
||||
|
||||
}
|
@ -0,0 +1,19 @@
|
||||
package org.jeecg.modules.demo.ipqcdedata.service.impl;
|
||||
|
||||
import org.jeecg.modules.demo.ipqcdedata.entity.TtIpqcDeData;
|
||||
import org.jeecg.modules.demo.ipqcdedata.mapper.TtIpqcDeDataMapper;
|
||||
import org.jeecg.modules.demo.ipqcdedata.service.ITtIpqcDeDataService;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
|
||||
/**
|
||||
* @Description: tt_ipqc_de_data
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Service
|
||||
public class TtIpqcDeDataServiceImpl extends ServiceImpl<TtIpqcDeDataMapper, TtIpqcDeData> implements ITtIpqcDeDataService {
|
||||
|
||||
}
|
@ -0,0 +1,84 @@
|
||||
<template>
|
||||
<a-drawer
|
||||
:title="title"
|
||||
:width="width"
|
||||
placement="right"
|
||||
:closable="false"
|
||||
@close="close"
|
||||
destroyOnClose
|
||||
:visible="visible">
|
||||
<tt-ipqc-de-data-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit" normal></tt-ipqc-de-data-form>
|
||||
<div class="drawer-footer">
|
||||
<a-button @click="handleCancel" style="margin-bottom: 0;">关闭</a-button>
|
||||
<a-button v-if="!disableSubmit" @click="handleOk" type="primary" style="margin-bottom: 0;">提交</a-button>
|
||||
</div>
|
||||
</a-drawer>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import TtIpqcDeDataForm from './TtIpqcDeDataForm'
|
||||
|
||||
export default {
|
||||
name: 'TtIpqcDeDataModal',
|
||||
components: {
|
||||
TtIpqcDeDataForm
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
title:"操作",
|
||||
width:800,
|
||||
visible: false,
|
||||
disableSubmit: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.add();
|
||||
})
|
||||
},
|
||||
edit (record) {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.edit(record);
|
||||
});
|
||||
},
|
||||
close () {
|
||||
this.$emit('close');
|
||||
this.visible = false;
|
||||
},
|
||||
submitCallback(){
|
||||
this.$emit('ok');
|
||||
this.visible = false;
|
||||
},
|
||||
handleOk () {
|
||||
this.$refs.realForm.submitForm();
|
||||
},
|
||||
handleCancel () {
|
||||
this.close()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
/** Button按钮间距 */
|
||||
.ant-btn {
|
||||
margin-left: 30px;
|
||||
margin-bottom: 30px;
|
||||
float: right;
|
||||
}
|
||||
.drawer-footer{
|
||||
position: absolute;
|
||||
bottom: -8px;
|
||||
width: 100%;
|
||||
border-top: 1px solid #e8e8e8;
|
||||
padding: 10px 16px;
|
||||
text-align: right;
|
||||
left: 0;
|
||||
background: #fff;
|
||||
border-radius: 0 0 2px 2px;
|
||||
}
|
||||
</style>
|
@ -0,0 +1,60 @@
|
||||
<template>
|
||||
<j-modal
|
||||
:title="title"
|
||||
:width="width"
|
||||
:visible="visible"
|
||||
switchFullscreen
|
||||
@ok="handleOk"
|
||||
:okButtonProps="{ class:{'jee-hidden': disableSubmit} }"
|
||||
@cancel="handleCancel"
|
||||
cancelText="关闭">
|
||||
<tt-ipqc-de-data-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit"></tt-ipqc-de-data-form>
|
||||
</j-modal>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import TtIpqcDeDataForm from './TtIpqcDeDataForm'
|
||||
export default {
|
||||
name: 'TtIpqcDeDataModal',
|
||||
components: {
|
||||
TtIpqcDeDataForm
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
title:'',
|
||||
width:800,
|
||||
visible: false,
|
||||
disableSubmit: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.add();
|
||||
})
|
||||
},
|
||||
edit (record) {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.edit(record);
|
||||
})
|
||||
},
|
||||
close () {
|
||||
this.$emit('close');
|
||||
this.visible = false;
|
||||
},
|
||||
handleOk () {
|
||||
this.$refs.realForm.submitForm();
|
||||
},
|
||||
submitCallback(){
|
||||
this.$emit('ok');
|
||||
this.visible = false;
|
||||
},
|
||||
handleCancel () {
|
||||
this.close()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
@ -0,0 +1,199 @@
|
||||
package org.jeecg.modules.demo.ipqcmadata.controller;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
import java.io.IOException;
|
||||
import java.io.UnsupportedEncodingException;
|
||||
import java.net.URLDecoder;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import org.jeecg.common.api.vo.Result;
|
||||
import org.jeecg.common.system.query.QueryGenerator;
|
||||
import org.jeecg.common.util.oConvertUtils;
|
||||
import org.jeecg.modules.demo.ipqcmadata.entity.TtIpqcMaData;
|
||||
import org.jeecg.modules.demo.ipqcmadata.service.ITtIpqcMaDataService;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
|
||||
import org.jeecgframework.poi.excel.ExcelImportUtil;
|
||||
import org.jeecgframework.poi.excel.def.NormalExcelConstants;
|
||||
import org.jeecgframework.poi.excel.entity.ExportParams;
|
||||
import org.jeecgframework.poi.excel.entity.ImportParams;
|
||||
import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
|
||||
import org.jeecg.common.system.base.controller.JeecgController;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
import org.springframework.web.multipart.MultipartHttpServletRequest;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.jeecg.common.aspect.annotation.AutoLog;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
|
||||
/**
|
||||
* @Description: tt_ipqc_ma_data
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Api(tags="tt_ipqc_ma_data")
|
||||
@RestController
|
||||
@RequestMapping("/ipqcmadata/ttIpqcMaData")
|
||||
@Slf4j
|
||||
public class TtIpqcMaDataController extends JeecgController<TtIpqcMaData, ITtIpqcMaDataService> {
|
||||
@Autowired
|
||||
private ITtIpqcMaDataService ttIpqcMaDataService;
|
||||
|
||||
/**
|
||||
* 分页列表查询
|
||||
*
|
||||
* @param ttIpqcMaData
|
||||
* @param pageNo
|
||||
* @param pageSize
|
||||
* @param req
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_ipqc_ma_data-分页列表查询")
|
||||
@ApiOperation(value="tt_ipqc_ma_data-分页列表查询", notes="tt_ipqc_ma_data-分页列表查询")
|
||||
@GetMapping(value = "/list")
|
||||
public Result<IPage<TtIpqcMaData>> queryPageList(TtIpqcMaData ttIpqcMaData,
|
||||
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
||||
HttpServletRequest req) {
|
||||
QueryWrapper<TtIpqcMaData> queryWrapper = QueryGenerator.initQueryWrapper(ttIpqcMaData, req.getParameterMap());
|
||||
Page<TtIpqcMaData> page = new Page<TtIpqcMaData>(pageNo, pageSize);
|
||||
IPage<TtIpqcMaData> pageList = ttIpqcMaDataService.page(page, queryWrapper);
|
||||
return Result.OK(pageList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页列表查询
|
||||
*
|
||||
* @param ttIpqcMaData
|
||||
* @param pageNo
|
||||
* @param pageSize
|
||||
* @param req
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_ipqc_ma_data-分页列表查询")
|
||||
@ApiOperation(value="tt_ipqc_ma_data-分页列表查询", notes="tt_ipqc_ma_data-分页列表查询")
|
||||
@GetMapping(value = "/queryPageList")
|
||||
public Result<IPage<List<Map>>> queryPageList2(TtIpqcMaData ttIpqcMaData,
|
||||
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
||||
HttpServletRequest req) {
|
||||
Page<TtIpqcMaData> page = new Page<TtIpqcMaData>(pageNo, pageSize);
|
||||
IPage<List<Map>> pageList = ttIpqcMaDataService.queryPage(page, ttIpqcMaData);
|
||||
return Result.OK(pageList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加
|
||||
*
|
||||
* @param ttIpqcMaData
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_ipqc_ma_data-添加")
|
||||
@ApiOperation(value="tt_ipqc_ma_data-添加", notes="tt_ipqc_ma_data-添加")
|
||||
//@RequiresPermissions("ipqcmadata:tt_ipqc_ma_data:add")
|
||||
@PostMapping(value = "/add")
|
||||
public Result<String> add(@RequestBody TtIpqcMaData ttIpqcMaData) {
|
||||
ttIpqcMaDataService.save(ttIpqcMaData);
|
||||
return Result.OK("添加成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
*
|
||||
* @param ttIpqcMaData
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_ipqc_ma_data-编辑")
|
||||
@ApiOperation(value="tt_ipqc_ma_data-编辑", notes="tt_ipqc_ma_data-编辑")
|
||||
//@RequiresPermissions("ipqcmadata:tt_ipqc_ma_data:edit")
|
||||
@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
|
||||
public Result<String> edit(@RequestBody TtIpqcMaData ttIpqcMaData) {
|
||||
ttIpqcMaDataService.updateById(ttIpqcMaData);
|
||||
return Result.OK("编辑成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_ipqc_ma_data-通过id删除")
|
||||
@ApiOperation(value="tt_ipqc_ma_data-通过id删除", notes="tt_ipqc_ma_data-通过id删除")
|
||||
//@RequiresPermissions("ipqcmadata:tt_ipqc_ma_data:delete")
|
||||
@DeleteMapping(value = "/delete")
|
||||
public Result<String> delete(@RequestParam(name="id",required=true) String id) {
|
||||
ttIpqcMaDataService.removeById(id);
|
||||
return Result.OK("删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_ipqc_ma_data-批量删除")
|
||||
@ApiOperation(value="tt_ipqc_ma_data-批量删除", notes="tt_ipqc_ma_data-批量删除")
|
||||
//@RequiresPermissions("ipqcmadata:tt_ipqc_ma_data:deleteBatch")
|
||||
@DeleteMapping(value = "/deleteBatch")
|
||||
public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
|
||||
this.ttIpqcMaDataService.removeByIds(Arrays.asList(ids.split(",")));
|
||||
return Result.OK("批量删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_ipqc_ma_data-通过id查询")
|
||||
@ApiOperation(value="tt_ipqc_ma_data-通过id查询", notes="tt_ipqc_ma_data-通过id查询")
|
||||
@GetMapping(value = "/queryById")
|
||||
public Result<TtIpqcMaData> queryById(@RequestParam(name="id",required=true) String id) {
|
||||
TtIpqcMaData ttIpqcMaData = ttIpqcMaDataService.getById(id);
|
||||
if(ttIpqcMaData==null) {
|
||||
return Result.error("未找到对应数据");
|
||||
}
|
||||
return Result.OK(ttIpqcMaData);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出excel
|
||||
*
|
||||
* @param request
|
||||
* @param ttIpqcMaData
|
||||
*/
|
||||
//@RequiresPermissions("ipqcmadata:tt_ipqc_ma_data:exportXls")
|
||||
@RequestMapping(value = "/exportXls")
|
||||
public ModelAndView exportXls(HttpServletRequest request, TtIpqcMaData ttIpqcMaData) {
|
||||
return super.exportXls(request, ttIpqcMaData, TtIpqcMaData.class, "tt_ipqc_ma_data");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过excel导入数据
|
||||
*
|
||||
* @param request
|
||||
* @param response
|
||||
* @return
|
||||
*/
|
||||
//@RequiresPermissions("ipqcmadata:tt_ipqc_ma_data:importExcel")
|
||||
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||
return super.importExcel(request, response, TtIpqcMaData.class);
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,77 @@
|
||||
package org.jeecg.modules.demo.ipqcmadata.entity;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.io.UnsupportedEncodingException;
|
||||
import java.util.Date;
|
||||
import java.math.BigDecimal;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
import org.jeecgframework.poi.excel.annotation.Excel;
|
||||
import org.jeecg.common.aspect.annotation.Dict;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
/**
|
||||
* @Description: tt_ipqc_ma_data
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Data
|
||||
@TableName("tt_ipqc_ma_data")
|
||||
@Accessors(chain = true)
|
||||
@EqualsAndHashCode(callSuper = false)
|
||||
@ApiModel(value="tt_ipqc_ma_data对象", description="tt_ipqc_ma_data")
|
||||
public class TtIpqcMaData implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**id*/
|
||||
@TableId(type = IdType.ASSIGN_ID)
|
||||
@ApiModelProperty(value = "id")
|
||||
private Integer id;
|
||||
/**日期名称*/
|
||||
@Excel(name = "日期名称", width = 15, format = "yyyy-MM-dd")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
@ApiModelProperty(value = "日期名称")
|
||||
private Date dayName;
|
||||
/**班次名称*/
|
||||
@Excel(name = "班次名称", width = 15)
|
||||
@ApiModelProperty(value = "班次名称")
|
||||
private String shiftName;
|
||||
/**参考标准*/
|
||||
@Excel(name = "参考标准", width = 15)
|
||||
@ApiModelProperty(value = "参考标准")
|
||||
private String ipqcStandard;
|
||||
/**ipqc用户*/
|
||||
@Excel(name = "ipqc用户", width = 15)
|
||||
@ApiModelProperty(value = "ipqc用户")
|
||||
private String ipqcUser;
|
||||
/**硫化主管*/
|
||||
@Excel(name = "硫化主管", width = 15)
|
||||
@ApiModelProperty(value = "硫化主管")
|
||||
private String sulfUser;
|
||||
/**品质主管*/
|
||||
@Excel(name = "品质主管", width = 15)
|
||||
@ApiModelProperty(value = "品质主管")
|
||||
private String qaUser;
|
||||
|
||||
@TableField(exist = false)
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
@ApiModelProperty(value = "开始日期")
|
||||
private Date startDayName;
|
||||
@TableField(exist = false)
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
@ApiModelProperty(value = "结束日期")
|
||||
private Date endDayName;
|
||||
@TableField(exist = false)
|
||||
@ApiModelProperty(value = "机台")
|
||||
private String equipNo;
|
||||
}
|
@ -0,0 +1,21 @@
|
||||
package org.jeecg.modules.demo.ipqcmadata.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.jeecg.modules.demo.ipqcmadata.entity.TtIpqcMaData;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* @Description: tt_ipqc_ma_data
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface TtIpqcMaDataMapper extends BaseMapper<TtIpqcMaData> {
|
||||
|
||||
IPage<List<Map>> queryPage(Page<TtIpqcMaData> page, TtIpqcMaData ttIpqcMaData);
|
||||
}
|
@ -0,0 +1,21 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="org.jeecg.modules.demo.ipqcmadata.mapper.TtIpqcMaDataMapper">
|
||||
|
||||
<!-- 列表查询 -->
|
||||
<select id="queryPage" resultType="java.util.Map">
|
||||
select a.*,b.* from tt_ipqc_ma_data a, tt_ipqc_de_data b
|
||||
where a.id=b.m_id
|
||||
<if test="ttIpqcMaData.startDayName != null">
|
||||
AND a.dayName <![CDATA[ <= ]]> #{ttIpqcMaData.startDayName}
|
||||
</if>
|
||||
<if test="ttIpqcMaData.endDayName != null">
|
||||
AND a.dayName <![CDATA[ < ]]> #{ttIpqcMaData.endDayName}
|
||||
</if>
|
||||
<if test="ttIpqcMaData.equipNo != null and ttIpqcMaData.equipNo != ''">
|
||||
AND b.equip_no = #{ttIpqcMaData.equipNo}
|
||||
</if>
|
||||
order by a.day_name,a.shift_name
|
||||
</select>
|
||||
|
||||
</mapper>
|
@ -0,0 +1,20 @@
|
||||
package org.jeecg.modules.demo.ipqcmadata.service;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import org.jeecg.modules.demo.ipqcmadata.entity.TtIpqcMaData;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @Description: tt_ipqc_ma_data
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface ITtIpqcMaDataService extends IService<TtIpqcMaData> {
|
||||
|
||||
IPage<List<Map>> queryPage(Page<TtIpqcMaData> page, TtIpqcMaData ttIpqcMaData);
|
||||
}
|
@ -0,0 +1,31 @@
|
||||
package org.jeecg.modules.demo.ipqcmadata.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import org.jeecg.modules.demo.ipqcmadata.entity.TtIpqcMaData;
|
||||
import org.jeecg.modules.demo.ipqcmadata.mapper.TtIpqcMaDataMapper;
|
||||
import org.jeecg.modules.demo.ipqcmadata.service.ITtIpqcMaDataService;
|
||||
import org.jeecg.modules.demo.kanbanpsrate.mapper.TtKanbanPsRateMapper;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @Description: tt_ipqc_ma_data
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Service
|
||||
public class TtIpqcMaDataServiceImpl extends ServiceImpl<TtIpqcMaDataMapper, TtIpqcMaData> implements ITtIpqcMaDataService {
|
||||
@Autowired
|
||||
private TtIpqcMaDataMapper ttIpqcMaDataMapper;
|
||||
@Override
|
||||
public IPage<List<Map>> queryPage(Page<TtIpqcMaData> page, TtIpqcMaData ttIpqcMaData) {
|
||||
return ttIpqcMaDataMapper.queryPage(page, ttIpqcMaData);
|
||||
}
|
||||
}
|
@ -0,0 +1,204 @@
|
||||
<template>
|
||||
<a-card :bordered="false">
|
||||
<!-- 查询区域 -->
|
||||
<div class="table-page-search-wrapper">
|
||||
<a-form layout="inline" @keyup.enter.native="searchQuery">
|
||||
<a-row :gutter="24">
|
||||
</a-row>
|
||||
</a-form>
|
||||
</div>
|
||||
<!-- 查询区域-END -->
|
||||
|
||||
<!-- 操作按钮区域 -->
|
||||
<div class="table-operator">
|
||||
<a-button @click="handleAdd" type="primary" icon="plus">新增</a-button>
|
||||
<a-button type="primary" icon="download" @click="handleExportXls('tt_ipqc_ma_data')">导出</a-button>
|
||||
<a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel">
|
||||
<a-button type="primary" icon="import">导入</a-button>
|
||||
</a-upload>
|
||||
<!-- 高级查询区域 -->
|
||||
<j-super-query :fieldList="superFieldList" ref="superQueryModal" @handleSuperQuery="handleSuperQuery"></j-super-query>
|
||||
<a-dropdown v-if="selectedRowKeys.length > 0">
|
||||
<a-menu slot="overlay">
|
||||
<a-menu-item key="1" @click="batchDel"><a-icon type="delete"/>删除</a-menu-item>
|
||||
</a-menu>
|
||||
<a-button style="margin-left: 8px"> 批量操作 <a-icon type="down" /></a-button>
|
||||
</a-dropdown>
|
||||
</div>
|
||||
|
||||
<!-- table区域-begin -->
|
||||
<div>
|
||||
<div class="ant-alert ant-alert-info" style="margin-bottom: 16px;">
|
||||
<i class="anticon anticon-info-circle ant-alert-icon"></i> 已选择 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>项
|
||||
<a style="margin-left: 24px" @click="onClearSelected">清空</a>
|
||||
</div>
|
||||
|
||||
<a-table
|
||||
ref="table"
|
||||
size="middle"
|
||||
:scroll="{x:true}"
|
||||
bordered
|
||||
rowKey="id"
|
||||
:columns="columns"
|
||||
:dataSource="dataSource"
|
||||
:pagination="ipagination"
|
||||
:loading="loading"
|
||||
:rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
|
||||
class="j-table-force-nowrap"
|
||||
@change="handleTableChange">
|
||||
|
||||
<template slot="htmlSlot" slot-scope="text">
|
||||
<div v-html="text"></div>
|
||||
</template>
|
||||
<template slot="imgSlot" slot-scope="text,record">
|
||||
<span v-if="!text" style="font-size: 12px;font-style: italic;">无图片</span>
|
||||
<img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/>
|
||||
</template>
|
||||
<template slot="fileSlot" slot-scope="text">
|
||||
<span v-if="!text" style="font-size: 12px;font-style: italic;">无文件</span>
|
||||
<a-button
|
||||
v-else
|
||||
:ghost="true"
|
||||
type="primary"
|
||||
icon="download"
|
||||
size="small"
|
||||
@click="downloadFile(text)">
|
||||
下载
|
||||
</a-button>
|
||||
</template>
|
||||
|
||||
<span slot="action" slot-scope="text, record">
|
||||
<a @click="handleEdit(record)">编辑</a>
|
||||
|
||||
<a-divider type="vertical" />
|
||||
<a-dropdown>
|
||||
<a class="ant-dropdown-link">更多 <a-icon type="down" /></a>
|
||||
<a-menu slot="overlay">
|
||||
<a-menu-item>
|
||||
<a @click="handleDetail(record)">详情</a>
|
||||
</a-menu-item>
|
||||
<a-menu-item>
|
||||
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
|
||||
<a>删除</a>
|
||||
</a-popconfirm>
|
||||
</a-menu-item>
|
||||
</a-menu>
|
||||
</a-dropdown>
|
||||
</span>
|
||||
|
||||
</a-table>
|
||||
</div>
|
||||
|
||||
<tt-ipqc-ma-data-modal ref="modalForm" @ok="modalFormOk"></tt-ipqc-ma-data-modal>
|
||||
</a-card>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import '@/assets/less/TableExpand.less'
|
||||
import { mixinDevice } from '@/utils/mixin'
|
||||
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
|
||||
import TtIpqcMaDataModal from './modules/TtIpqcMaDataModal'
|
||||
|
||||
export default {
|
||||
name: 'TtIpqcMaDataList',
|
||||
mixins:[JeecgListMixin, mixinDevice],
|
||||
components: {
|
||||
TtIpqcMaDataModal
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
description: 'tt_ipqc_ma_data管理页面',
|
||||
// 表头
|
||||
columns: [
|
||||
{
|
||||
title: '#',
|
||||
dataIndex: '',
|
||||
key:'rowIndex',
|
||||
width:60,
|
||||
align:"center",
|
||||
customRender:function (t,r,index) {
|
||||
return parseInt(index)+1;
|
||||
}
|
||||
},
|
||||
{
|
||||
title:'日期名称',
|
||||
align:"center",
|
||||
dataIndex: 'dayName',
|
||||
customRender:function (text) {
|
||||
return !text?"":(text.length>10?text.substr(0,10):text)
|
||||
}
|
||||
},
|
||||
{
|
||||
title:'班次名称',
|
||||
align:"center",
|
||||
dataIndex: 'shiftName'
|
||||
},
|
||||
{
|
||||
title:'参考标准',
|
||||
align:"center",
|
||||
dataIndex: 'ipqcStandard'
|
||||
},
|
||||
{
|
||||
title:'ipqc用户',
|
||||
align:"center",
|
||||
dataIndex: 'ipqcUser'
|
||||
},
|
||||
{
|
||||
title:'硫化主管',
|
||||
align:"center",
|
||||
dataIndex: 'sulfUser'
|
||||
},
|
||||
{
|
||||
title:'品质主管',
|
||||
align:"center",
|
||||
dataIndex: 'qaUser'
|
||||
},
|
||||
{
|
||||
title: '操作',
|
||||
dataIndex: 'action',
|
||||
align:"center",
|
||||
fixed:"right",
|
||||
width:147,
|
||||
scopedSlots: { customRender: 'action' }
|
||||
}
|
||||
],
|
||||
url: {
|
||||
list: "/ipqcmadata/ttIpqcMaData/list",
|
||||
delete: "/ipqcmadata/ttIpqcMaData/delete",
|
||||
deleteBatch: "/ipqcmadata/ttIpqcMaData/deleteBatch",
|
||||
exportXlsUrl: "/ipqcmadata/ttIpqcMaData/exportXls",
|
||||
importExcelUrl: "ipqcmadata/ttIpqcMaData/importExcel",
|
||||
|
||||
},
|
||||
dictOptions:{},
|
||||
superFieldList:[],
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getSuperFieldList();
|
||||
},
|
||||
computed: {
|
||||
importExcelUrl: function(){
|
||||
return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`;
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
initDictConfig(){
|
||||
},
|
||||
getSuperFieldList(){
|
||||
let fieldList=[];
|
||||
fieldList.push({type:'date',value:'dayName',text:'日期名称'})
|
||||
fieldList.push({type:'string',value:'shiftName',text:'班次名称'})
|
||||
fieldList.push({type:'string',value:'ipqcStandard',text:'参考标准'})
|
||||
fieldList.push({type:'string',value:'ipqcUser',text:'ipqc用户'})
|
||||
fieldList.push({type:'string',value:'sulfUser',text:'硫化主管'})
|
||||
fieldList.push({type:'string',value:'qaUser',text:'品质主管'})
|
||||
this.superFieldList = fieldList
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style scoped>
|
||||
@import '~@assets/less/common.less';
|
||||
</style>
|
@ -0,0 +1,138 @@
|
||||
<template>
|
||||
<a-spin :spinning="confirmLoading">
|
||||
<j-form-container :disabled="formDisabled">
|
||||
<a-form-model ref="form" :model="model" :rules="validatorRules" slot="detail">
|
||||
<a-row>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="日期名称" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="dayName">
|
||||
<j-date placeholder="请选择日期名称" v-model="model.dayName" style="width: 100%" />
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="班次名称" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="shiftName">
|
||||
<a-input v-model="model.shiftName" placeholder="请输入班次名称" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="参考标准" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="ipqcStandard">
|
||||
<a-input v-model="model.ipqcStandard" placeholder="请输入参考标准" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="ipqc用户" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="ipqcUser">
|
||||
<a-input v-model="model.ipqcUser" placeholder="请输入ipqc用户" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="硫化主管" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="sulfUser">
|
||||
<a-input v-model="model.sulfUser" placeholder="请输入硫化主管" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-model-item label="品质主管" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="qaUser">
|
||||
<a-input v-model="model.qaUser" placeholder="请输入品质主管" ></a-input>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form-model>
|
||||
</j-form-container>
|
||||
</a-spin>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import { httpAction, getAction } from '@/api/manage'
|
||||
import { validateDuplicateValue } from '@/utils/util'
|
||||
|
||||
export default {
|
||||
name: 'TtIpqcMaDataForm',
|
||||
components: {
|
||||
},
|
||||
props: {
|
||||
//表单禁用
|
||||
disabled: {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
required: false
|
||||
}
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
model:{
|
||||
},
|
||||
labelCol: {
|
||||
xs: { span: 24 },
|
||||
sm: { span: 5 },
|
||||
},
|
||||
wrapperCol: {
|
||||
xs: { span: 24 },
|
||||
sm: { span: 16 },
|
||||
},
|
||||
confirmLoading: false,
|
||||
validatorRules: {
|
||||
dayName: [
|
||||
{ required: true, message: '请输入日期名称!'},
|
||||
],
|
||||
shiftName: [
|
||||
{ required: true, message: '请输入班次名称!'},
|
||||
],
|
||||
ipqcStandard: [
|
||||
{ required: true, message: '请输入参考标准!'},
|
||||
],
|
||||
},
|
||||
url: {
|
||||
add: "/ipqcmadata/ttIpqcMaData/add",
|
||||
edit: "/ipqcmadata/ttIpqcMaData/edit",
|
||||
queryById: "/ipqcmadata/ttIpqcMaData/queryById"
|
||||
}
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
formDisabled(){
|
||||
return this.disabled
|
||||
},
|
||||
},
|
||||
created () {
|
||||
//备份model原始值
|
||||
this.modelDefault = JSON.parse(JSON.stringify(this.model));
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.edit(this.modelDefault);
|
||||
},
|
||||
edit (record) {
|
||||
this.model = Object.assign({}, record);
|
||||
this.visible = true;
|
||||
},
|
||||
submitForm () {
|
||||
const that = this;
|
||||
// 触发表单验证
|
||||
this.$refs.form.validate(valid => {
|
||||
if (valid) {
|
||||
that.confirmLoading = true;
|
||||
let httpurl = '';
|
||||
let method = '';
|
||||
if(!this.model.id){
|
||||
httpurl+=this.url.add;
|
||||
method = 'post';
|
||||
}else{
|
||||
httpurl+=this.url.edit;
|
||||
method = 'put';
|
||||
}
|
||||
httpAction(httpurl,this.model,method).then((res)=>{
|
||||
if(res.success){
|
||||
that.$message.success(res.message);
|
||||
that.$emit('ok');
|
||||
}else{
|
||||
that.$message.warning(res.message);
|
||||
}
|
||||
}).finally(() => {
|
||||
that.confirmLoading = false;
|
||||
})
|
||||
}
|
||||
|
||||
})
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
@ -0,0 +1,84 @@
|
||||
<template>
|
||||
<a-drawer
|
||||
:title="title"
|
||||
:width="width"
|
||||
placement="right"
|
||||
:closable="false"
|
||||
@close="close"
|
||||
destroyOnClose
|
||||
:visible="visible">
|
||||
<tt-ipqc-ma-data-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit" normal></tt-ipqc-ma-data-form>
|
||||
<div class="drawer-footer">
|
||||
<a-button @click="handleCancel" style="margin-bottom: 0;">关闭</a-button>
|
||||
<a-button v-if="!disableSubmit" @click="handleOk" type="primary" style="margin-bottom: 0;">提交</a-button>
|
||||
</div>
|
||||
</a-drawer>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import TtIpqcMaDataForm from './TtIpqcMaDataForm'
|
||||
|
||||
export default {
|
||||
name: 'TtIpqcMaDataModal',
|
||||
components: {
|
||||
TtIpqcMaDataForm
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
title:"操作",
|
||||
width:800,
|
||||
visible: false,
|
||||
disableSubmit: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.add();
|
||||
})
|
||||
},
|
||||
edit (record) {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.edit(record);
|
||||
});
|
||||
},
|
||||
close () {
|
||||
this.$emit('close');
|
||||
this.visible = false;
|
||||
},
|
||||
submitCallback(){
|
||||
this.$emit('ok');
|
||||
this.visible = false;
|
||||
},
|
||||
handleOk () {
|
||||
this.$refs.realForm.submitForm();
|
||||
},
|
||||
handleCancel () {
|
||||
this.close()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
/** Button按钮间距 */
|
||||
.ant-btn {
|
||||
margin-left: 30px;
|
||||
margin-bottom: 30px;
|
||||
float: right;
|
||||
}
|
||||
.drawer-footer{
|
||||
position: absolute;
|
||||
bottom: -8px;
|
||||
width: 100%;
|
||||
border-top: 1px solid #e8e8e8;
|
||||
padding: 10px 16px;
|
||||
text-align: right;
|
||||
left: 0;
|
||||
background: #fff;
|
||||
border-radius: 0 0 2px 2px;
|
||||
}
|
||||
</style>
|
@ -0,0 +1,60 @@
|
||||
<template>
|
||||
<j-modal
|
||||
:title="title"
|
||||
:width="width"
|
||||
:visible="visible"
|
||||
switchFullscreen
|
||||
@ok="handleOk"
|
||||
:okButtonProps="{ class:{'jee-hidden': disableSubmit} }"
|
||||
@cancel="handleCancel"
|
||||
cancelText="关闭">
|
||||
<tt-ipqc-ma-data-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit"></tt-ipqc-ma-data-form>
|
||||
</j-modal>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import TtIpqcMaDataForm from './TtIpqcMaDataForm'
|
||||
export default {
|
||||
name: 'TtIpqcMaDataModal',
|
||||
components: {
|
||||
TtIpqcMaDataForm
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
title:'',
|
||||
width:800,
|
||||
visible: false,
|
||||
disableSubmit: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.add();
|
||||
})
|
||||
},
|
||||
edit (record) {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.edit(record);
|
||||
})
|
||||
},
|
||||
close () {
|
||||
this.$emit('close');
|
||||
this.visible = false;
|
||||
},
|
||||
handleOk () {
|
||||
this.$refs.realForm.submitForm();
|
||||
},
|
||||
submitCallback(){
|
||||
this.$emit('ok');
|
||||
this.visible = false;
|
||||
},
|
||||
handleCancel () {
|
||||
this.close()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
@ -0,0 +1,195 @@
|
||||
package org.jeecg.modules.demo.kanbanequiprate.controller;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
import java.io.IOException;
|
||||
import java.io.UnsupportedEncodingException;
|
||||
import java.net.URLDecoder;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import org.jeecg.common.api.vo.Result;
|
||||
import org.jeecg.common.system.query.QueryGenerator;
|
||||
import org.jeecg.common.util.oConvertUtils;
|
||||
import org.jeecg.modules.demo.kanbanequiprate.entity.TtKanbanEquipRate;
|
||||
import org.jeecg.modules.demo.kanbanequiprate.service.ITtKanbanEquipRateService;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
|
||||
import org.jeecg.modules.demo.kanbanpassrate.entity.TtKanbanPassRate;
|
||||
import org.jeecgframework.poi.excel.ExcelImportUtil;
|
||||
import org.jeecgframework.poi.excel.def.NormalExcelConstants;
|
||||
import org.jeecgframework.poi.excel.entity.ExportParams;
|
||||
import org.jeecgframework.poi.excel.entity.ImportParams;
|
||||
import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
|
||||
import org.jeecg.common.system.base.controller.JeecgController;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
import org.springframework.web.multipart.MultipartHttpServletRequest;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.jeecg.common.aspect.annotation.AutoLog;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
|
||||
/**
|
||||
* @Description: tt_kanban_equip_rate
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Api(tags="tt_kanban_equip_rate")
|
||||
@RestController
|
||||
@RequestMapping("/kanbanequiprate/ttKanbanEquipRate")
|
||||
@Slf4j
|
||||
public class TtKanbanEquipRateController extends JeecgController<TtKanbanEquipRate, ITtKanbanEquipRateService> {
|
||||
@Autowired
|
||||
private ITtKanbanEquipRateService ttKanbanEquipRateService;
|
||||
|
||||
/**
|
||||
* 分页列表查询
|
||||
*
|
||||
* @param ttKanbanEquipRate
|
||||
* @param pageNo
|
||||
* @param pageSize
|
||||
* @param req
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_kanban_equip_rate-分页列表查询")
|
||||
@ApiOperation(value="tt_kanban_equip_rate-分页列表查询", notes="tt_kanban_equip_rate-分页列表查询")
|
||||
@GetMapping(value = "/list")
|
||||
public Result<IPage<TtKanbanEquipRate>> queryPageList(TtKanbanEquipRate ttKanbanEquipRate,
|
||||
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
||||
HttpServletRequest req) {
|
||||
QueryWrapper<TtKanbanEquipRate> queryWrapper = QueryGenerator.initQueryWrapper(ttKanbanEquipRate, req.getParameterMap());
|
||||
Page<TtKanbanEquipRate> page = new Page<TtKanbanEquipRate>(pageNo, pageSize);
|
||||
IPage<TtKanbanEquipRate> pageList = ttKanbanEquipRateService.page(page, queryWrapper);
|
||||
return Result.OK(pageList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 看板6列表查询
|
||||
*
|
||||
* @param ttKanbanEquipRate
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_kanban_equip_rate-分页列表查询")
|
||||
@ApiOperation(value="tt_kanban_equip_rate-看板6列表查询", notes="tt_kanban_equip_rate-看板6列表查询")
|
||||
@GetMapping(value = "/queryList")
|
||||
public Result<List<TtKanbanEquipRate>> queryList(TtKanbanEquipRate ttKanbanEquipRate) {
|
||||
QueryWrapper<TtKanbanEquipRate> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.eq("company_id", 1);
|
||||
List<TtKanbanEquipRate> kanbanEquipRateList = ttKanbanEquipRateService.list(queryWrapper);
|
||||
return Result.OK(kanbanEquipRateList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加
|
||||
*
|
||||
* @param ttKanbanEquipRate
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_equip_rate-添加")
|
||||
@ApiOperation(value="tt_kanban_equip_rate-添加", notes="tt_kanban_equip_rate-添加")
|
||||
//@RequiresPermissions("kanbanequiprate:tt_kanban_equip_rate:add")
|
||||
@PostMapping(value = "/add")
|
||||
public Result<String> add(@RequestBody TtKanbanEquipRate ttKanbanEquipRate) {
|
||||
ttKanbanEquipRateService.save(ttKanbanEquipRate);
|
||||
return Result.OK("添加成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
*
|
||||
* @param ttKanbanEquipRate
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_equip_rate-编辑")
|
||||
@ApiOperation(value="tt_kanban_equip_rate-编辑", notes="tt_kanban_equip_rate-编辑")
|
||||
//@RequiresPermissions("kanbanequiprate:tt_kanban_equip_rate:edit")
|
||||
@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
|
||||
public Result<String> edit(@RequestBody TtKanbanEquipRate ttKanbanEquipRate) {
|
||||
ttKanbanEquipRateService.updateById(ttKanbanEquipRate);
|
||||
return Result.OK("编辑成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_equip_rate-通过id删除")
|
||||
@ApiOperation(value="tt_kanban_equip_rate-通过id删除", notes="tt_kanban_equip_rate-通过id删除")
|
||||
//@RequiresPermissions("kanbanequiprate:tt_kanban_equip_rate:delete")
|
||||
@DeleteMapping(value = "/delete")
|
||||
public Result<String> delete(@RequestParam(name="id",required=true) String id) {
|
||||
ttKanbanEquipRateService.removeById(id);
|
||||
return Result.OK("删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_equip_rate-批量删除")
|
||||
@ApiOperation(value="tt_kanban_equip_rate-批量删除", notes="tt_kanban_equip_rate-批量删除")
|
||||
//@RequiresPermissions("kanbanequiprate:tt_kanban_equip_rate:deleteBatch")
|
||||
@DeleteMapping(value = "/deleteBatch")
|
||||
public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
|
||||
this.ttKanbanEquipRateService.removeByIds(Arrays.asList(ids.split(",")));
|
||||
return Result.OK("批量删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_kanban_equip_rate-通过id查询")
|
||||
@ApiOperation(value="tt_kanban_equip_rate-通过id查询", notes="tt_kanban_equip_rate-通过id查询")
|
||||
@GetMapping(value = "/queryById")
|
||||
public Result<TtKanbanEquipRate> queryById(@RequestParam(name="id",required=true) String id) {
|
||||
TtKanbanEquipRate ttKanbanEquipRate = ttKanbanEquipRateService.getById(id);
|
||||
if(ttKanbanEquipRate==null) {
|
||||
return Result.error("未找到对应数据");
|
||||
}
|
||||
return Result.OK(ttKanbanEquipRate);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出excel
|
||||
*
|
||||
* @param request
|
||||
* @param ttKanbanEquipRate
|
||||
*/
|
||||
//@RequiresPermissions("kanbanequiprate:tt_kanban_equip_rate:exportXls")
|
||||
@RequestMapping(value = "/exportXls")
|
||||
public ModelAndView exportXls(HttpServletRequest request, TtKanbanEquipRate ttKanbanEquipRate) {
|
||||
return super.exportXls(request, ttKanbanEquipRate, TtKanbanEquipRate.class, "tt_kanban_equip_rate");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过excel导入数据
|
||||
*
|
||||
* @param request
|
||||
* @param response
|
||||
* @return
|
||||
*/
|
||||
//@RequiresPermissions("kanbanequiprate:tt_kanban_equip_rate:importExcel")
|
||||
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||
return super.importExcel(request, response, TtKanbanEquipRate.class);
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,17 @@
|
||||
package org.jeecg.modules.demo.kanbanequiprate.mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.jeecg.modules.demo.kanbanequiprate.entity.TtKanbanEquipRate;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* @Description: tt_kanban_equip_rate
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface TtKanbanEquipRateMapper extends BaseMapper<TtKanbanEquipRate> {
|
||||
|
||||
}
|
@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="org.jeecg.modules.demo.kanbanequiprate.mapper.TtKanbanEquipRateMapper">
|
||||
|
||||
</mapper>
|
@ -0,0 +1,14 @@
|
||||
package org.jeecg.modules.demo.kanbanequiprate.service;
|
||||
|
||||
import org.jeecg.modules.demo.kanbanequiprate.entity.TtKanbanEquipRate;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
|
||||
/**
|
||||
* @Description: tt_kanban_equip_rate
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface ITtKanbanEquipRateService extends IService<TtKanbanEquipRate> {
|
||||
|
||||
}
|
@ -0,0 +1,19 @@
|
||||
package org.jeecg.modules.demo.kanbanequiprate.service.impl;
|
||||
|
||||
import org.jeecg.modules.demo.kanbanequiprate.entity.TtKanbanEquipRate;
|
||||
import org.jeecg.modules.demo.kanbanequiprate.mapper.TtKanbanEquipRateMapper;
|
||||
import org.jeecg.modules.demo.kanbanequiprate.service.ITtKanbanEquipRateService;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
|
||||
/**
|
||||
* @Description: tt_kanban_equip_rate
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Service
|
||||
public class TtKanbanEquipRateServiceImpl extends ServiceImpl<TtKanbanEquipRateMapper, TtKanbanEquipRate> implements ITtKanbanEquipRateService {
|
||||
|
||||
}
|
@ -0,0 +1,84 @@
|
||||
<template>
|
||||
<a-drawer
|
||||
:title="title"
|
||||
:width="width"
|
||||
placement="right"
|
||||
:closable="false"
|
||||
@close="close"
|
||||
destroyOnClose
|
||||
:visible="visible">
|
||||
<tt-kanban-equip-rate-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit" normal></tt-kanban-equip-rate-form>
|
||||
<div class="drawer-footer">
|
||||
<a-button @click="handleCancel" style="margin-bottom: 0;">关闭</a-button>
|
||||
<a-button v-if="!disableSubmit" @click="handleOk" type="primary" style="margin-bottom: 0;">提交</a-button>
|
||||
</div>
|
||||
</a-drawer>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import TtKanbanEquipRateForm from './TtKanbanEquipRateForm'
|
||||
|
||||
export default {
|
||||
name: 'TtKanbanEquipRateModal',
|
||||
components: {
|
||||
TtKanbanEquipRateForm
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
title:"操作",
|
||||
width:800,
|
||||
visible: false,
|
||||
disableSubmit: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.add();
|
||||
})
|
||||
},
|
||||
edit (record) {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.edit(record);
|
||||
});
|
||||
},
|
||||
close () {
|
||||
this.$emit('close');
|
||||
this.visible = false;
|
||||
},
|
||||
submitCallback(){
|
||||
this.$emit('ok');
|
||||
this.visible = false;
|
||||
},
|
||||
handleOk () {
|
||||
this.$refs.realForm.submitForm();
|
||||
},
|
||||
handleCancel () {
|
||||
this.close()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
/** Button按钮间距 */
|
||||
.ant-btn {
|
||||
margin-left: 30px;
|
||||
margin-bottom: 30px;
|
||||
float: right;
|
||||
}
|
||||
.drawer-footer{
|
||||
position: absolute;
|
||||
bottom: -8px;
|
||||
width: 100%;
|
||||
border-top: 1px solid #e8e8e8;
|
||||
padding: 10px 16px;
|
||||
text-align: right;
|
||||
left: 0;
|
||||
background: #fff;
|
||||
border-radius: 0 0 2px 2px;
|
||||
}
|
||||
</style>
|
@ -0,0 +1,60 @@
|
||||
<template>
|
||||
<j-modal
|
||||
:title="title"
|
||||
:width="width"
|
||||
:visible="visible"
|
||||
switchFullscreen
|
||||
@ok="handleOk"
|
||||
:okButtonProps="{ class:{'jee-hidden': disableSubmit} }"
|
||||
@cancel="handleCancel"
|
||||
cancelText="关闭">
|
||||
<tt-kanban-equip-rate-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit"></tt-kanban-equip-rate-form>
|
||||
</j-modal>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import TtKanbanEquipRateForm from './TtKanbanEquipRateForm'
|
||||
export default {
|
||||
name: 'TtKanbanEquipRateModal',
|
||||
components: {
|
||||
TtKanbanEquipRateForm
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
title:'',
|
||||
width:800,
|
||||
visible: false,
|
||||
disableSubmit: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.add();
|
||||
})
|
||||
},
|
||||
edit (record) {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.edit(record);
|
||||
})
|
||||
},
|
||||
close () {
|
||||
this.$emit('close');
|
||||
this.visible = false;
|
||||
},
|
||||
handleOk () {
|
||||
this.$refs.realForm.submitForm();
|
||||
},
|
||||
submitCallback(){
|
||||
this.$emit('ok');
|
||||
this.visible = false;
|
||||
},
|
||||
handleCancel () {
|
||||
this.close()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
@ -0,0 +1,194 @@
|
||||
package org.jeecg.modules.demo.kanbaninwh.controller;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
import java.io.IOException;
|
||||
import java.io.UnsupportedEncodingException;
|
||||
import java.net.URLDecoder;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import org.jeecg.common.api.vo.Result;
|
||||
import org.jeecg.common.system.query.QueryGenerator;
|
||||
import org.jeecg.common.util.oConvertUtils;
|
||||
import org.jeecg.modules.demo.kanbaninwh.entity.TtKanbanInWh;
|
||||
import org.jeecg.modules.demo.kanbaninwh.service.ITtKanbanInWhService;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
|
||||
import org.jeecg.modules.demo.kanbanplan.entity.TtKanbanPlan;
|
||||
import org.jeecgframework.poi.excel.ExcelImportUtil;
|
||||
import org.jeecgframework.poi.excel.def.NormalExcelConstants;
|
||||
import org.jeecgframework.poi.excel.entity.ExportParams;
|
||||
import org.jeecgframework.poi.excel.entity.ImportParams;
|
||||
import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
|
||||
import org.jeecg.common.system.base.controller.JeecgController;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
import org.springframework.web.multipart.MultipartHttpServletRequest;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.jeecg.common.aspect.annotation.AutoLog;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
|
||||
/**
|
||||
* @Description: tt_kanban_in_wh
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Api(tags="tt_kanban_in_wh")
|
||||
@RestController
|
||||
@RequestMapping("/kanbaninwh/ttKanbanInWh")
|
||||
@Slf4j
|
||||
public class TtKanbanInWhController extends JeecgController<TtKanbanInWh, ITtKanbanInWhService> {
|
||||
@Autowired
|
||||
private ITtKanbanInWhService ttKanbanInWhService;
|
||||
|
||||
/**
|
||||
* 分页列表查询
|
||||
*
|
||||
* @param ttKanbanInWh
|
||||
* @param pageNo
|
||||
* @param pageSize
|
||||
* @param req
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_kanban_in_wh-分页列表查询")
|
||||
@ApiOperation(value="tt_kanban_in_wh-分页列表查询", notes="tt_kanban_in_wh-分页列表查询")
|
||||
@GetMapping(value = "/list")
|
||||
public Result<IPage<TtKanbanInWh>> queryPageList(TtKanbanInWh ttKanbanInWh,
|
||||
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
||||
HttpServletRequest req) {
|
||||
QueryWrapper<TtKanbanInWh> queryWrapper = QueryGenerator.initQueryWrapper(ttKanbanInWh, req.getParameterMap());
|
||||
Page<TtKanbanInWh> page = new Page<TtKanbanInWh>(pageNo, pageSize);
|
||||
IPage<TtKanbanInWh> pageList = ttKanbanInWhService.page(page, queryWrapper);
|
||||
return Result.OK(pageList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 看板2列表查询
|
||||
*
|
||||
* @param ttKanbanInWh
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_kanban_in_wh-分页列表查询")
|
||||
@ApiOperation(value="tt_kanban_in_wh-看板2列表查询", notes="tt_kanban_in_wh-看板2列表查询")
|
||||
@GetMapping(value = "/queryList")
|
||||
public Result<List<TtKanbanInWh>> queryList(TtKanbanInWh ttKanbanInWh) {
|
||||
List<TtKanbanInWh> kanbanInWhList = ttKanbanInWhService.kanbanInWhList();
|
||||
return Result.OK(kanbanInWhList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加
|
||||
*
|
||||
* @param ttKanbanInWh
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_in_wh-添加")
|
||||
@ApiOperation(value="tt_kanban_in_wh-添加", notes="tt_kanban_in_wh-添加")
|
||||
//@RequiresPermissions("kanbaninwh:tt_kanban_in_wh:add")
|
||||
@PostMapping(value = "/add")
|
||||
public Result<String> add(@RequestBody TtKanbanInWh ttKanbanInWh) {
|
||||
ttKanbanInWhService.save(ttKanbanInWh);
|
||||
return Result.OK("添加成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
*
|
||||
* @param ttKanbanInWh
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_in_wh-编辑")
|
||||
@ApiOperation(value="tt_kanban_in_wh-编辑", notes="tt_kanban_in_wh-编辑")
|
||||
//@RequiresPermissions("kanbaninwh:tt_kanban_in_wh:edit")
|
||||
@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
|
||||
public Result<String> edit(@RequestBody TtKanbanInWh ttKanbanInWh) {
|
||||
ttKanbanInWhService.updateById(ttKanbanInWh);
|
||||
return Result.OK("编辑成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_in_wh-通过id删除")
|
||||
@ApiOperation(value="tt_kanban_in_wh-通过id删除", notes="tt_kanban_in_wh-通过id删除")
|
||||
//@RequiresPermissions("kanbaninwh:tt_kanban_in_wh:delete")
|
||||
@DeleteMapping(value = "/delete")
|
||||
public Result<String> delete(@RequestParam(name="id",required=true) String id) {
|
||||
ttKanbanInWhService.removeById(id);
|
||||
return Result.OK("删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_in_wh-批量删除")
|
||||
@ApiOperation(value="tt_kanban_in_wh-批量删除", notes="tt_kanban_in_wh-批量删除")
|
||||
//@RequiresPermissions("kanbaninwh:tt_kanban_in_wh:deleteBatch")
|
||||
@DeleteMapping(value = "/deleteBatch")
|
||||
public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
|
||||
this.ttKanbanInWhService.removeByIds(Arrays.asList(ids.split(",")));
|
||||
return Result.OK("批量删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_kanban_in_wh-通过id查询")
|
||||
@ApiOperation(value="tt_kanban_in_wh-通过id查询", notes="tt_kanban_in_wh-通过id查询")
|
||||
@GetMapping(value = "/queryById")
|
||||
public Result<TtKanbanInWh> queryById(@RequestParam(name="id",required=true) String id) {
|
||||
TtKanbanInWh ttKanbanInWh = ttKanbanInWhService.getById(id);
|
||||
if(ttKanbanInWh==null) {
|
||||
return Result.error("未找到对应数据");
|
||||
}
|
||||
return Result.OK(ttKanbanInWh);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出excel
|
||||
*
|
||||
* @param request
|
||||
* @param ttKanbanInWh
|
||||
*/
|
||||
//@RequiresPermissions("kanbaninwh:tt_kanban_in_wh:exportXls")
|
||||
@RequestMapping(value = "/exportXls")
|
||||
public ModelAndView exportXls(HttpServletRequest request, TtKanbanInWh ttKanbanInWh) {
|
||||
return super.exportXls(request, ttKanbanInWh, TtKanbanInWh.class, "tt_kanban_in_wh");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过excel导入数据
|
||||
*
|
||||
* @param request
|
||||
* @param response
|
||||
* @return
|
||||
*/
|
||||
//@RequiresPermissions("kanbaninwh:tt_kanban_in_wh:importExcel")
|
||||
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||
return super.importExcel(request, response, TtKanbanInWh.class);
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,18 @@
|
||||
package org.jeecg.modules.demo.kanbaninwh.mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.jeecg.modules.demo.kanbaninwh.entity.TtKanbanInWh;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* @Description: tt_kanban_in_wh
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface TtKanbanInWhMapper extends BaseMapper<TtKanbanInWh> {
|
||||
|
||||
List<TtKanbanInWh> kanbanInWhList();
|
||||
}
|
@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="org.jeecg.modules.demo.kanbaninwh.mapper.TtKanbanInWhMapper">
|
||||
|
||||
<!-- 看板2列表查询 -->
|
||||
<select id="kanbanInWhList" resultType="org.jeecg.modules.demo.kanbaninwh.entity.TtKanbanInWh">
|
||||
select * from tt_kanban_in_wh where company_id = 1 and day_name >= date_sub(now(), interval 5 day) and day_name < now()
|
||||
order by type_id,day_name
|
||||
</select>
|
||||
</mapper>
|
@ -0,0 +1,17 @@
|
||||
package org.jeecg.modules.demo.kanbaninwh.service;
|
||||
|
||||
import org.jeecg.modules.demo.kanbaninwh.entity.TtKanbanInWh;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Description: tt_kanban_in_wh
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface ITtKanbanInWhService extends IService<TtKanbanInWh> {
|
||||
|
||||
List<TtKanbanInWh> kanbanInWhList();
|
||||
}
|
@ -0,0 +1,28 @@
|
||||
package org.jeecg.modules.demo.kanbaninwh.service.impl;
|
||||
|
||||
import org.jeecg.modules.demo.kanbaninwh.entity.TtKanbanInWh;
|
||||
import org.jeecg.modules.demo.kanbaninwh.mapper.TtKanbanInWhMapper;
|
||||
import org.jeecg.modules.demo.kanbaninwh.service.ITtKanbanInWhService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Description: tt_kanban_in_wh
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Service
|
||||
public class TtKanbanInWhServiceImpl extends ServiceImpl<TtKanbanInWhMapper, TtKanbanInWh> implements ITtKanbanInWhService {
|
||||
@Autowired
|
||||
private TtKanbanInWhMapper TtKanbanInWhMapper;
|
||||
|
||||
@Override
|
||||
public List<TtKanbanInWh> kanbanInWhList() {
|
||||
return TtKanbanInWhMapper.kanbanInWhList();
|
||||
}
|
||||
}
|
@ -0,0 +1,84 @@
|
||||
<template>
|
||||
<a-drawer
|
||||
:title="title"
|
||||
:width="width"
|
||||
placement="right"
|
||||
:closable="false"
|
||||
@close="close"
|
||||
destroyOnClose
|
||||
:visible="visible">
|
||||
<tt-kanban-in-wh-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit" normal></tt-kanban-in-wh-form>
|
||||
<div class="drawer-footer">
|
||||
<a-button @click="handleCancel" style="margin-bottom: 0;">关闭</a-button>
|
||||
<a-button v-if="!disableSubmit" @click="handleOk" type="primary" style="margin-bottom: 0;">提交</a-button>
|
||||
</div>
|
||||
</a-drawer>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import TtKanbanInWhForm from './TtKanbanInWhForm'
|
||||
|
||||
export default {
|
||||
name: 'TtKanbanInWhModal',
|
||||
components: {
|
||||
TtKanbanInWhForm
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
title:"操作",
|
||||
width:800,
|
||||
visible: false,
|
||||
disableSubmit: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.add();
|
||||
})
|
||||
},
|
||||
edit (record) {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.edit(record);
|
||||
});
|
||||
},
|
||||
close () {
|
||||
this.$emit('close');
|
||||
this.visible = false;
|
||||
},
|
||||
submitCallback(){
|
||||
this.$emit('ok');
|
||||
this.visible = false;
|
||||
},
|
||||
handleOk () {
|
||||
this.$refs.realForm.submitForm();
|
||||
},
|
||||
handleCancel () {
|
||||
this.close()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
/** Button按钮间距 */
|
||||
.ant-btn {
|
||||
margin-left: 30px;
|
||||
margin-bottom: 30px;
|
||||
float: right;
|
||||
}
|
||||
.drawer-footer{
|
||||
position: absolute;
|
||||
bottom: -8px;
|
||||
width: 100%;
|
||||
border-top: 1px solid #e8e8e8;
|
||||
padding: 10px 16px;
|
||||
text-align: right;
|
||||
left: 0;
|
||||
background: #fff;
|
||||
border-radius: 0 0 2px 2px;
|
||||
}
|
||||
</style>
|
@ -0,0 +1,60 @@
|
||||
<template>
|
||||
<j-modal
|
||||
:title="title"
|
||||
:width="width"
|
||||
:visible="visible"
|
||||
switchFullscreen
|
||||
@ok="handleOk"
|
||||
:okButtonProps="{ class:{'jee-hidden': disableSubmit} }"
|
||||
@cancel="handleCancel"
|
||||
cancelText="关闭">
|
||||
<tt-kanban-in-wh-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit"></tt-kanban-in-wh-form>
|
||||
</j-modal>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import TtKanbanInWhForm from './TtKanbanInWhForm'
|
||||
export default {
|
||||
name: 'TtKanbanInWhModal',
|
||||
components: {
|
||||
TtKanbanInWhForm
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
title:'',
|
||||
width:800,
|
||||
visible: false,
|
||||
disableSubmit: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.add();
|
||||
})
|
||||
},
|
||||
edit (record) {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.edit(record);
|
||||
})
|
||||
},
|
||||
close () {
|
||||
this.$emit('close');
|
||||
this.visible = false;
|
||||
},
|
||||
handleOk () {
|
||||
this.$refs.realForm.submitForm();
|
||||
},
|
||||
submitCallback(){
|
||||
this.$emit('ok');
|
||||
this.visible = false;
|
||||
},
|
||||
handleCancel () {
|
||||
this.close()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
@ -0,0 +1,196 @@
|
||||
package org.jeecg.modules.demo.kanbanpassrate.controller;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
import java.io.IOException;
|
||||
import java.io.UnsupportedEncodingException;
|
||||
import java.net.URLDecoder;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import org.jeecg.common.api.vo.Result;
|
||||
import org.jeecg.common.system.query.QueryGenerator;
|
||||
import org.jeecg.common.util.oConvertUtils;
|
||||
import org.jeecg.modules.demo.kanbanpassrate.entity.TtKanbanPassRate;
|
||||
import org.jeecg.modules.demo.kanbanpassrate.service.ITtKanbanPassRateService;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
|
||||
import org.jeecg.modules.demo.kanbanplan.entity.TtKanbanPlan;
|
||||
import org.jeecgframework.poi.excel.ExcelImportUtil;
|
||||
import org.jeecgframework.poi.excel.def.NormalExcelConstants;
|
||||
import org.jeecgframework.poi.excel.entity.ExportParams;
|
||||
import org.jeecgframework.poi.excel.entity.ImportParams;
|
||||
import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
|
||||
import org.jeecg.common.system.base.controller.JeecgController;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
import org.springframework.web.multipart.MultipartHttpServletRequest;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.jeecg.common.aspect.annotation.AutoLog;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
|
||||
/**
|
||||
* @Description: tt_kanban_pass_rate
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Api(tags="tt_kanban_pass_rate")
|
||||
@RestController
|
||||
@RequestMapping("/kanbanpassrate/ttKanbanPassRate")
|
||||
@Slf4j
|
||||
public class TtKanbanPassRateController extends JeecgController<TtKanbanPassRate, ITtKanbanPassRateService> {
|
||||
@Autowired
|
||||
private ITtKanbanPassRateService ttKanbanPassRateService;
|
||||
|
||||
/**
|
||||
* 分页列表查询
|
||||
*
|
||||
* @param ttKanbanPassRate
|
||||
* @param pageNo
|
||||
* @param pageSize
|
||||
* @param req
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_kanban_pass_rate-分页列表查询")
|
||||
@ApiOperation(value="tt_kanban_pass_rate-分页列表查询", notes="tt_kanban_pass_rate-分页列表查询")
|
||||
@GetMapping(value = "/list")
|
||||
public Result<IPage<TtKanbanPassRate>> queryPageList(TtKanbanPassRate ttKanbanPassRate,
|
||||
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
||||
HttpServletRequest req) {
|
||||
QueryWrapper<TtKanbanPassRate> queryWrapper = QueryGenerator.initQueryWrapper(ttKanbanPassRate, req.getParameterMap());
|
||||
Page<TtKanbanPassRate> page = new Page<TtKanbanPassRate>(pageNo, pageSize);
|
||||
IPage<TtKanbanPassRate> pageList = ttKanbanPassRateService.page(page, queryWrapper);
|
||||
return Result.OK(pageList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 看板3列表查询
|
||||
*
|
||||
* @param ttKanbanPassRate
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_kanban_pass_rate-分页列表查询")
|
||||
@ApiOperation(value="tt_kanban_pass_rate-看板3列表查询", notes="tt_kanban_plan-看板3列表查询")
|
||||
@GetMapping(value = "/queryList")
|
||||
public Result<List<TtKanbanPassRate>> queryList(TtKanbanPassRate ttKanbanPassRate) {
|
||||
QueryWrapper<TtKanbanPassRate> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.eq("company_id", 1);
|
||||
List<TtKanbanPassRate> kanbanPassRateList = ttKanbanPassRateService.list(queryWrapper);
|
||||
return Result.OK(kanbanPassRateList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加
|
||||
*
|
||||
* @param ttKanbanPassRate
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_pass_rate-添加")
|
||||
@ApiOperation(value="tt_kanban_pass_rate-添加", notes="tt_kanban_pass_rate-添加")
|
||||
//@RequiresPermissions("kanbanpassrate:tt_kanban_pass_rate:add")
|
||||
@PostMapping(value = "/add")
|
||||
public Result<String> add(@RequestBody TtKanbanPassRate ttKanbanPassRate) {
|
||||
ttKanbanPassRateService.save(ttKanbanPassRate);
|
||||
return Result.OK("添加成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
*
|
||||
* @param ttKanbanPassRate
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_pass_rate-编辑")
|
||||
@ApiOperation(value="tt_kanban_pass_rate-编辑", notes="tt_kanban_pass_rate-编辑")
|
||||
//@RequiresPermissions("kanbanpassrate:tt_kanban_pass_rate:edit")
|
||||
@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
|
||||
public Result<String> edit(@RequestBody TtKanbanPassRate ttKanbanPassRate) {
|
||||
ttKanbanPassRateService.updateById(ttKanbanPassRate);
|
||||
return Result.OK("编辑成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_pass_rate-通过id删除")
|
||||
@ApiOperation(value="tt_kanban_pass_rate-通过id删除", notes="tt_kanban_pass_rate-通过id删除")
|
||||
//@RequiresPermissions("kanbanpassrate:tt_kanban_pass_rate:delete")
|
||||
@DeleteMapping(value = "/delete")
|
||||
public Result<String> delete(@RequestParam(name="id",required=true) String id) {
|
||||
ttKanbanPassRateService.removeById(id);
|
||||
return Result.OK("删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_pass_rate-批量删除")
|
||||
@ApiOperation(value="tt_kanban_pass_rate-批量删除", notes="tt_kanban_pass_rate-批量删除")
|
||||
//@RequiresPermissions("kanbanpassrate:tt_kanban_pass_rate:deleteBatch")
|
||||
@DeleteMapping(value = "/deleteBatch")
|
||||
public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
|
||||
this.ttKanbanPassRateService.removeByIds(Arrays.asList(ids.split(",")));
|
||||
return Result.OK("批量删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_kanban_pass_rate-通过id查询")
|
||||
@ApiOperation(value="tt_kanban_pass_rate-通过id查询", notes="tt_kanban_pass_rate-通过id查询")
|
||||
@GetMapping(value = "/queryById")
|
||||
public Result<TtKanbanPassRate> queryById(@RequestParam(name="id",required=true) String id) {
|
||||
TtKanbanPassRate ttKanbanPassRate = ttKanbanPassRateService.getById(id);
|
||||
if(ttKanbanPassRate==null) {
|
||||
return Result.error("未找到对应数据");
|
||||
}
|
||||
return Result.OK(ttKanbanPassRate);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出excel
|
||||
*
|
||||
* @param request
|
||||
* @param ttKanbanPassRate
|
||||
*/
|
||||
//@RequiresPermissions("kanbanpassrate:tt_kanban_pass_rate:exportXls")
|
||||
@RequestMapping(value = "/exportXls")
|
||||
public ModelAndView exportXls(HttpServletRequest request, TtKanbanPassRate ttKanbanPassRate) {
|
||||
return super.exportXls(request, ttKanbanPassRate, TtKanbanPassRate.class, "tt_kanban_pass_rate");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过excel导入数据
|
||||
*
|
||||
* @param request
|
||||
* @param response
|
||||
* @return
|
||||
*/
|
||||
//@RequiresPermissions("kanbanpassrate:tt_kanban_pass_rate:importExcel")
|
||||
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||
return super.importExcel(request, response, TtKanbanPassRate.class);
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,17 @@
|
||||
package org.jeecg.modules.demo.kanbanpassrate.mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.jeecg.modules.demo.kanbanpassrate.entity.TtKanbanPassRate;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* @Description: tt_kanban_pass_rate
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface TtKanbanPassRateMapper extends BaseMapper<TtKanbanPassRate> {
|
||||
|
||||
}
|
@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="org.jeecg.modules.demo.kanbanpassrate.mapper.TtKanbanPassRateMapper">
|
||||
|
||||
</mapper>
|
@ -0,0 +1,14 @@
|
||||
package org.jeecg.modules.demo.kanbanpassrate.service;
|
||||
|
||||
import org.jeecg.modules.demo.kanbanpassrate.entity.TtKanbanPassRate;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
|
||||
/**
|
||||
* @Description: tt_kanban_pass_rate
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface ITtKanbanPassRateService extends IService<TtKanbanPassRate> {
|
||||
|
||||
}
|
@ -0,0 +1,19 @@
|
||||
package org.jeecg.modules.demo.kanbanpassrate.service.impl;
|
||||
|
||||
import org.jeecg.modules.demo.kanbanpassrate.entity.TtKanbanPassRate;
|
||||
import org.jeecg.modules.demo.kanbanpassrate.mapper.TtKanbanPassRateMapper;
|
||||
import org.jeecg.modules.demo.kanbanpassrate.service.ITtKanbanPassRateService;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
|
||||
/**
|
||||
* @Description: tt_kanban_pass_rate
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Service
|
||||
public class TtKanbanPassRateServiceImpl extends ServiceImpl<TtKanbanPassRateMapper, TtKanbanPassRate> implements ITtKanbanPassRateService {
|
||||
|
||||
}
|
@ -0,0 +1,84 @@
|
||||
<template>
|
||||
<a-drawer
|
||||
:title="title"
|
||||
:width="width"
|
||||
placement="right"
|
||||
:closable="false"
|
||||
@close="close"
|
||||
destroyOnClose
|
||||
:visible="visible">
|
||||
<tt-kanban-pass-rate-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit" normal></tt-kanban-pass-rate-form>
|
||||
<div class="drawer-footer">
|
||||
<a-button @click="handleCancel" style="margin-bottom: 0;">关闭</a-button>
|
||||
<a-button v-if="!disableSubmit" @click="handleOk" type="primary" style="margin-bottom: 0;">提交</a-button>
|
||||
</div>
|
||||
</a-drawer>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import TtKanbanPassRateForm from './TtKanbanPassRateForm'
|
||||
|
||||
export default {
|
||||
name: 'TtKanbanPassRateModal',
|
||||
components: {
|
||||
TtKanbanPassRateForm
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
title:"操作",
|
||||
width:800,
|
||||
visible: false,
|
||||
disableSubmit: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.add();
|
||||
})
|
||||
},
|
||||
edit (record) {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.edit(record);
|
||||
});
|
||||
},
|
||||
close () {
|
||||
this.$emit('close');
|
||||
this.visible = false;
|
||||
},
|
||||
submitCallback(){
|
||||
this.$emit('ok');
|
||||
this.visible = false;
|
||||
},
|
||||
handleOk () {
|
||||
this.$refs.realForm.submitForm();
|
||||
},
|
||||
handleCancel () {
|
||||
this.close()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
/** Button按钮间距 */
|
||||
.ant-btn {
|
||||
margin-left: 30px;
|
||||
margin-bottom: 30px;
|
||||
float: right;
|
||||
}
|
||||
.drawer-footer{
|
||||
position: absolute;
|
||||
bottom: -8px;
|
||||
width: 100%;
|
||||
border-top: 1px solid #e8e8e8;
|
||||
padding: 10px 16px;
|
||||
text-align: right;
|
||||
left: 0;
|
||||
background: #fff;
|
||||
border-radius: 0 0 2px 2px;
|
||||
}
|
||||
</style>
|
@ -0,0 +1,60 @@
|
||||
<template>
|
||||
<j-modal
|
||||
:title="title"
|
||||
:width="width"
|
||||
:visible="visible"
|
||||
switchFullscreen
|
||||
@ok="handleOk"
|
||||
:okButtonProps="{ class:{'jee-hidden': disableSubmit} }"
|
||||
@cancel="handleCancel"
|
||||
cancelText="关闭">
|
||||
<tt-kanban-pass-rate-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit"></tt-kanban-pass-rate-form>
|
||||
</j-modal>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import TtKanbanPassRateForm from './TtKanbanPassRateForm'
|
||||
export default {
|
||||
name: 'TtKanbanPassRateModal',
|
||||
components: {
|
||||
TtKanbanPassRateForm
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
title:'',
|
||||
width:800,
|
||||
visible: false,
|
||||
disableSubmit: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.add();
|
||||
})
|
||||
},
|
||||
edit (record) {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.edit(record);
|
||||
})
|
||||
},
|
||||
close () {
|
||||
this.$emit('close');
|
||||
this.visible = false;
|
||||
},
|
||||
handleOk () {
|
||||
this.$refs.realForm.submitForm();
|
||||
},
|
||||
submitCallback(){
|
||||
this.$emit('ok');
|
||||
this.visible = false;
|
||||
},
|
||||
handleCancel () {
|
||||
this.close()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
@ -0,0 +1,199 @@
|
||||
package org.jeecg.modules.demo.kanbanplan.controller;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
import java.io.IOException;
|
||||
import java.io.UnsupportedEncodingException;
|
||||
import java.net.URLDecoder;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import org.jeecg.common.api.vo.Result;
|
||||
import org.jeecg.common.system.query.QueryGenerator;
|
||||
import org.jeecg.common.util.oConvertUtils;
|
||||
import org.jeecg.modules.demo.kanbanplan.entity.TtKanbanPlan;
|
||||
import org.jeecg.modules.demo.kanbanplan.service.ITtKanbanPlanService;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
|
||||
import org.jeecgframework.poi.excel.ExcelImportUtil;
|
||||
import org.jeecgframework.poi.excel.def.NormalExcelConstants;
|
||||
import org.jeecgframework.poi.excel.entity.ExportParams;
|
||||
import org.jeecgframework.poi.excel.entity.ImportParams;
|
||||
import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
|
||||
import org.jeecg.common.system.base.controller.JeecgController;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
import org.springframework.web.multipart.MultipartHttpServletRequest;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.jeecg.common.aspect.annotation.AutoLog;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
|
||||
/**
|
||||
* @Description: tt_kanban_plan
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Api(tags="tt_kanban_plan")
|
||||
@RestController
|
||||
@RequestMapping("/kanbanplan/ttKanbanPlan")
|
||||
@Slf4j
|
||||
public class TtKanbanPlanController extends JeecgController<TtKanbanPlan, ITtKanbanPlanService> {
|
||||
@Autowired
|
||||
private ITtKanbanPlanService ttKanbanPlanService;
|
||||
|
||||
/**
|
||||
* 分页列表查询
|
||||
*
|
||||
* @param ttKanbanPlan
|
||||
* @param pageNo
|
||||
* @param pageSize
|
||||
* @param req
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_kanban_plan-分页列表查询")
|
||||
@ApiOperation(value="tt_kanban_plan-分页列表查询", notes="tt_kanban_plan-分页列表查询")
|
||||
@GetMapping(value = "/list")
|
||||
public Result<IPage<TtKanbanPlan>> queryPageList(TtKanbanPlan ttKanbanPlan,
|
||||
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
||||
HttpServletRequest req) {
|
||||
QueryWrapper<TtKanbanPlan> queryWrapper = QueryGenerator.initQueryWrapper(ttKanbanPlan, req.getParameterMap());
|
||||
Page<TtKanbanPlan> page = new Page<TtKanbanPlan>(pageNo, pageSize);
|
||||
IPage<TtKanbanPlan> pageList = ttKanbanPlanService.page(page, queryWrapper);
|
||||
return Result.OK(pageList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 看板1列表查询
|
||||
*
|
||||
* @param ttKanbanPlan
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_kanban_plan-分页列表查询")
|
||||
@ApiOperation(value="tt_kanban_plan-看板1列表查询", notes="tt_kanban_plan-看板1列表查询")
|
||||
@GetMapping(value = "/queryList")
|
||||
public Result<List<TtKanbanPlan>> queryList(TtKanbanPlan ttKanbanPlan) {
|
||||
QueryWrapper<TtKanbanPlan> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.eq("company_id", 1);
|
||||
List<String> list = new ArrayList<>();
|
||||
list.add("type_id");
|
||||
list.add("month_name");
|
||||
queryWrapper.orderByAsc(list);
|
||||
List<TtKanbanPlan> kanbanPlanList = ttKanbanPlanService.list(queryWrapper);
|
||||
return Result.OK(kanbanPlanList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加
|
||||
*
|
||||
* @param ttKanbanPlan
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_plan-添加")
|
||||
@ApiOperation(value="tt_kanban_plan-添加", notes="tt_kanban_plan-添加")
|
||||
//@RequiresPermissions("kanbanplan:tt_kanban_plan:add")
|
||||
@PostMapping(value = "/add")
|
||||
public Result<String> add(@RequestBody TtKanbanPlan ttKanbanPlan) {
|
||||
ttKanbanPlanService.save(ttKanbanPlan);
|
||||
return Result.OK("添加成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
*
|
||||
* @param ttKanbanPlan
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_plan-编辑")
|
||||
@ApiOperation(value="tt_kanban_plan-编辑", notes="tt_kanban_plan-编辑")
|
||||
//@RequiresPermissions("kanbanplan:tt_kanban_plan:edit")
|
||||
@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
|
||||
public Result<String> edit(@RequestBody TtKanbanPlan ttKanbanPlan) {
|
||||
ttKanbanPlanService.updateById(ttKanbanPlan);
|
||||
return Result.OK("编辑成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_plan-通过id删除")
|
||||
@ApiOperation(value="tt_kanban_plan-通过id删除", notes="tt_kanban_plan-通过id删除")
|
||||
//@RequiresPermissions("kanbanplan:tt_kanban_plan:delete")
|
||||
@DeleteMapping(value = "/delete")
|
||||
public Result<String> delete(@RequestParam(name="id",required=true) String id) {
|
||||
ttKanbanPlanService.removeById(id);
|
||||
return Result.OK("删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_plan-批量删除")
|
||||
@ApiOperation(value="tt_kanban_plan-批量删除", notes="tt_kanban_plan-批量删除")
|
||||
//@RequiresPermissions("kanbanplan:tt_kanban_plan:deleteBatch")
|
||||
@DeleteMapping(value = "/deleteBatch")
|
||||
public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
|
||||
this.ttKanbanPlanService.removeByIds(Arrays.asList(ids.split(",")));
|
||||
return Result.OK("批量删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_kanban_plan-通过id查询")
|
||||
@ApiOperation(value="tt_kanban_plan-通过id查询", notes="tt_kanban_plan-通过id查询")
|
||||
@GetMapping(value = "/queryById")
|
||||
public Result<TtKanbanPlan> queryById(@RequestParam(name="id",required=true) String id) {
|
||||
TtKanbanPlan ttKanbanPlan = ttKanbanPlanService.getById(id);
|
||||
if(ttKanbanPlan==null) {
|
||||
return Result.error("未找到对应数据");
|
||||
}
|
||||
return Result.OK(ttKanbanPlan);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出excel
|
||||
*
|
||||
* @param request
|
||||
* @param ttKanbanPlan
|
||||
*/
|
||||
//@RequiresPermissions("kanbanplan:tt_kanban_plan:exportXls")
|
||||
@RequestMapping(value = "/exportXls")
|
||||
public ModelAndView exportXls(HttpServletRequest request, TtKanbanPlan ttKanbanPlan) {
|
||||
return super.exportXls(request, ttKanbanPlan, TtKanbanPlan.class, "tt_kanban_plan");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过excel导入数据
|
||||
*
|
||||
* @param request
|
||||
* @param response
|
||||
* @return
|
||||
*/
|
||||
//@RequiresPermissions("kanbanplan:tt_kanban_plan:importExcel")
|
||||
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||
return super.importExcel(request, response, TtKanbanPlan.class);
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,17 @@
|
||||
package org.jeecg.modules.demo.kanbanplan.mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.jeecg.modules.demo.kanbanplan.entity.TtKanbanPlan;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* @Description: tt_kanban_plan
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface TtKanbanPlanMapper extends BaseMapper<TtKanbanPlan> {
|
||||
|
||||
}
|
@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="org.jeecg.modules.demo.kanbanplan.mapper.TtKanbanPlanMapper">
|
||||
|
||||
</mapper>
|
@ -0,0 +1,14 @@
|
||||
package org.jeecg.modules.demo.kanbanplan.service;
|
||||
|
||||
import org.jeecg.modules.demo.kanbanplan.entity.TtKanbanPlan;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
|
||||
/**
|
||||
* @Description: tt_kanban_plan
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface ITtKanbanPlanService extends IService<TtKanbanPlan> {
|
||||
|
||||
}
|
@ -0,0 +1,19 @@
|
||||
package org.jeecg.modules.demo.kanbanplan.service.impl;
|
||||
|
||||
import org.jeecg.modules.demo.kanbanplan.entity.TtKanbanPlan;
|
||||
import org.jeecg.modules.demo.kanbanplan.mapper.TtKanbanPlanMapper;
|
||||
import org.jeecg.modules.demo.kanbanplan.service.ITtKanbanPlanService;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
|
||||
/**
|
||||
* @Description: tt_kanban_plan
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Service
|
||||
public class TtKanbanPlanServiceImpl extends ServiceImpl<TtKanbanPlanMapper, TtKanbanPlan> implements ITtKanbanPlanService {
|
||||
|
||||
}
|
@ -0,0 +1,84 @@
|
||||
<template>
|
||||
<a-drawer
|
||||
:title="title"
|
||||
:width="width"
|
||||
placement="right"
|
||||
:closable="false"
|
||||
@close="close"
|
||||
destroyOnClose
|
||||
:visible="visible">
|
||||
<tt-kanban-plan-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit" normal></tt-kanban-plan-form>
|
||||
<div class="drawer-footer">
|
||||
<a-button @click="handleCancel" style="margin-bottom: 0;">关闭</a-button>
|
||||
<a-button v-if="!disableSubmit" @click="handleOk" type="primary" style="margin-bottom: 0;">提交</a-button>
|
||||
</div>
|
||||
</a-drawer>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import TtKanbanPlanForm from './TtKanbanPlanForm'
|
||||
|
||||
export default {
|
||||
name: 'TtKanbanPlanModal',
|
||||
components: {
|
||||
TtKanbanPlanForm
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
title:"操作",
|
||||
width:800,
|
||||
visible: false,
|
||||
disableSubmit: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.add();
|
||||
})
|
||||
},
|
||||
edit (record) {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.edit(record);
|
||||
});
|
||||
},
|
||||
close () {
|
||||
this.$emit('close');
|
||||
this.visible = false;
|
||||
},
|
||||
submitCallback(){
|
||||
this.$emit('ok');
|
||||
this.visible = false;
|
||||
},
|
||||
handleOk () {
|
||||
this.$refs.realForm.submitForm();
|
||||
},
|
||||
handleCancel () {
|
||||
this.close()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
/** Button按钮间距 */
|
||||
.ant-btn {
|
||||
margin-left: 30px;
|
||||
margin-bottom: 30px;
|
||||
float: right;
|
||||
}
|
||||
.drawer-footer{
|
||||
position: absolute;
|
||||
bottom: -8px;
|
||||
width: 100%;
|
||||
border-top: 1px solid #e8e8e8;
|
||||
padding: 10px 16px;
|
||||
text-align: right;
|
||||
left: 0;
|
||||
background: #fff;
|
||||
border-radius: 0 0 2px 2px;
|
||||
}
|
||||
</style>
|
@ -0,0 +1,60 @@
|
||||
<template>
|
||||
<j-modal
|
||||
:title="title"
|
||||
:width="width"
|
||||
:visible="visible"
|
||||
switchFullscreen
|
||||
@ok="handleOk"
|
||||
:okButtonProps="{ class:{'jee-hidden': disableSubmit} }"
|
||||
@cancel="handleCancel"
|
||||
cancelText="关闭">
|
||||
<tt-kanban-plan-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit"></tt-kanban-plan-form>
|
||||
</j-modal>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import TtKanbanPlanForm from './TtKanbanPlanForm'
|
||||
export default {
|
||||
name: 'TtKanbanPlanModal',
|
||||
components: {
|
||||
TtKanbanPlanForm
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
title:'',
|
||||
width:800,
|
||||
visible: false,
|
||||
disableSubmit: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.add();
|
||||
})
|
||||
},
|
||||
edit (record) {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.edit(record);
|
||||
})
|
||||
},
|
||||
close () {
|
||||
this.$emit('close');
|
||||
this.visible = false;
|
||||
},
|
||||
handleOk () {
|
||||
this.$refs.realForm.submitForm();
|
||||
},
|
||||
submitCallback(){
|
||||
this.$emit('ok');
|
||||
this.visible = false;
|
||||
},
|
||||
handleCancel () {
|
||||
this.close()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
@ -0,0 +1,193 @@
|
||||
package org.jeecg.modules.demo.kanbanpsrate.controller;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
import java.io.IOException;
|
||||
import java.io.UnsupportedEncodingException;
|
||||
import java.net.URLDecoder;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import org.jeecg.common.api.vo.Result;
|
||||
import org.jeecg.common.system.query.QueryGenerator;
|
||||
import org.jeecg.common.util.oConvertUtils;
|
||||
import org.jeecg.modules.demo.kanbaninwh.entity.TtKanbanInWh;
|
||||
import org.jeecg.modules.demo.kanbanpsrate.entity.TtKanbanPsRate;
|
||||
import org.jeecg.modules.demo.kanbanpsrate.service.ITtKanbanPsRateService;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
|
||||
import org.jeecgframework.poi.excel.ExcelImportUtil;
|
||||
import org.jeecgframework.poi.excel.def.NormalExcelConstants;
|
||||
import org.jeecgframework.poi.excel.entity.ExportParams;
|
||||
import org.jeecgframework.poi.excel.entity.ImportParams;
|
||||
import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
|
||||
import org.jeecg.common.system.base.controller.JeecgController;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
import org.springframework.web.multipart.MultipartHttpServletRequest;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.jeecg.common.aspect.annotation.AutoLog;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
|
||||
/**
|
||||
* @Description: tt_kanban_ps_rate
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Api(tags="tt_kanban_ps_rate")
|
||||
@RestController
|
||||
@RequestMapping("/kanbanpsrate/ttKanbanPsRate")
|
||||
@Slf4j
|
||||
public class TtKanbanPsRateController extends JeecgController<TtKanbanPsRate, ITtKanbanPsRateService> {
|
||||
@Autowired
|
||||
private ITtKanbanPsRateService ttKanbanPsRateService;
|
||||
|
||||
/**
|
||||
* 分页列表查询
|
||||
*
|
||||
* @param ttKanbanPsRate
|
||||
* @param pageNo
|
||||
* @param pageSize
|
||||
* @param req
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_kanban_ps_rate-分页列表查询")
|
||||
@ApiOperation(value="tt_kanban_ps_rate-分页列表查询", notes="tt_kanban_ps_rate-分页列表查询")
|
||||
@GetMapping(value = "/list")
|
||||
public Result<IPage<TtKanbanPsRate>> queryPageList(TtKanbanPsRate ttKanbanPsRate,
|
||||
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
||||
HttpServletRequest req) {
|
||||
QueryWrapper<TtKanbanPsRate> queryWrapper = QueryGenerator.initQueryWrapper(ttKanbanPsRate, req.getParameterMap());
|
||||
Page<TtKanbanPsRate> page = new Page<TtKanbanPsRate>(pageNo, pageSize);
|
||||
IPage<TtKanbanPsRate> pageList = ttKanbanPsRateService.page(page, queryWrapper);
|
||||
return Result.OK(pageList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 看板5列表查询
|
||||
*
|
||||
* @param ttKanbanPsRate
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_kanban_ps_rate-分页列表查询")
|
||||
@ApiOperation(value="tt_kanban_ps_rate-看板5列表查询", notes="tt_kanban_ps_rate-看板5列表查询")
|
||||
@GetMapping(value = "/queryList")
|
||||
public Result<List<TtKanbanPsRate>> queryList(TtKanbanPsRate ttKanbanPsRate) {
|
||||
List<TtKanbanPsRate> kanbanPsRateList = ttKanbanPsRateService.kanbanPsRateList();
|
||||
return Result.OK(kanbanPsRateList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加
|
||||
*
|
||||
* @param ttKanbanPsRate
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_ps_rate-添加")
|
||||
@ApiOperation(value="tt_kanban_ps_rate-添加", notes="tt_kanban_ps_rate-添加")
|
||||
//@RequiresPermissions("kanbanpsrate:tt_kanban_ps_rate:add")
|
||||
@PostMapping(value = "/add")
|
||||
public Result<String> add(@RequestBody TtKanbanPsRate ttKanbanPsRate) {
|
||||
ttKanbanPsRateService.save(ttKanbanPsRate);
|
||||
return Result.OK("添加成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
*
|
||||
* @param ttKanbanPsRate
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_ps_rate-编辑")
|
||||
@ApiOperation(value="tt_kanban_ps_rate-编辑", notes="tt_kanban_ps_rate-编辑")
|
||||
//@RequiresPermissions("kanbanpsrate:tt_kanban_ps_rate:edit")
|
||||
@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
|
||||
public Result<String> edit(@RequestBody TtKanbanPsRate ttKanbanPsRate) {
|
||||
ttKanbanPsRateService.updateById(ttKanbanPsRate);
|
||||
return Result.OK("编辑成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_ps_rate-通过id删除")
|
||||
@ApiOperation(value="tt_kanban_ps_rate-通过id删除", notes="tt_kanban_ps_rate-通过id删除")
|
||||
//@RequiresPermissions("kanbanpsrate:tt_kanban_ps_rate:delete")
|
||||
@DeleteMapping(value = "/delete")
|
||||
public Result<String> delete(@RequestParam(name="id",required=true) String id) {
|
||||
ttKanbanPsRateService.removeById(id);
|
||||
return Result.OK("删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_ps_rate-批量删除")
|
||||
@ApiOperation(value="tt_kanban_ps_rate-批量删除", notes="tt_kanban_ps_rate-批量删除")
|
||||
//@RequiresPermissions("kanbanpsrate:tt_kanban_ps_rate:deleteBatch")
|
||||
@DeleteMapping(value = "/deleteBatch")
|
||||
public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
|
||||
this.ttKanbanPsRateService.removeByIds(Arrays.asList(ids.split(",")));
|
||||
return Result.OK("批量删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_kanban_ps_rate-通过id查询")
|
||||
@ApiOperation(value="tt_kanban_ps_rate-通过id查询", notes="tt_kanban_ps_rate-通过id查询")
|
||||
@GetMapping(value = "/queryById")
|
||||
public Result<TtKanbanPsRate> queryById(@RequestParam(name="id",required=true) String id) {
|
||||
TtKanbanPsRate ttKanbanPsRate = ttKanbanPsRateService.getById(id);
|
||||
if(ttKanbanPsRate==null) {
|
||||
return Result.error("未找到对应数据");
|
||||
}
|
||||
return Result.OK(ttKanbanPsRate);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出excel
|
||||
*
|
||||
* @param request
|
||||
* @param ttKanbanPsRate
|
||||
*/
|
||||
//@RequiresPermissions("kanbanpsrate:tt_kanban_ps_rate:exportXls")
|
||||
@RequestMapping(value = "/exportXls")
|
||||
public ModelAndView exportXls(HttpServletRequest request, TtKanbanPsRate ttKanbanPsRate) {
|
||||
return super.exportXls(request, ttKanbanPsRate, TtKanbanPsRate.class, "tt_kanban_ps_rate");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过excel导入数据
|
||||
*
|
||||
* @param request
|
||||
* @param response
|
||||
* @return
|
||||
*/
|
||||
//@RequiresPermissions("kanbanpsrate:tt_kanban_ps_rate:importExcel")
|
||||
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||
return super.importExcel(request, response, TtKanbanPsRate.class);
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,18 @@
|
||||
package org.jeecg.modules.demo.kanbanpsrate.mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.jeecg.modules.demo.kanbanpsrate.entity.TtKanbanPsRate;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* @Description: tt_kanban_ps_rate
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface TtKanbanPsRateMapper extends BaseMapper<TtKanbanPsRate> {
|
||||
|
||||
List<TtKanbanPsRate> kanbanPsRateList();
|
||||
}
|
@ -0,0 +1,11 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="org.jeecg.modules.demo.kanbanpsrate.mapper.TtKanbanPsRateMapper">
|
||||
|
||||
<!-- 看板5列表查询 -->
|
||||
<select id="kanbanPsRateList" resultType="org.jeecg.modules.demo.kanbanpsrate.entity.TtKanbanPsRate">
|
||||
select * from tt_kanban_ps_rate where company_id = 1 and day_name >= date_sub(now(), interval 5 day) and day_name < now()
|
||||
order by day_name
|
||||
</select>
|
||||
|
||||
</mapper>
|
@ -0,0 +1,17 @@
|
||||
package org.jeecg.modules.demo.kanbanpsrate.service;
|
||||
|
||||
import org.jeecg.modules.demo.kanbanpsrate.entity.TtKanbanPsRate;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Description: tt_kanban_ps_rate
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface ITtKanbanPsRateService extends IService<TtKanbanPsRate> {
|
||||
|
||||
List<TtKanbanPsRate> kanbanPsRateList();
|
||||
}
|
@ -0,0 +1,29 @@
|
||||
package org.jeecg.modules.demo.kanbanpsrate.service.impl;
|
||||
|
||||
import org.jeecg.modules.demo.kanbaninwh.mapper.TtKanbanInWhMapper;
|
||||
import org.jeecg.modules.demo.kanbanpsrate.entity.TtKanbanPsRate;
|
||||
import org.jeecg.modules.demo.kanbanpsrate.mapper.TtKanbanPsRateMapper;
|
||||
import org.jeecg.modules.demo.kanbanpsrate.service.ITtKanbanPsRateService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Description: tt_kanban_ps_rate
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Service
|
||||
public class TtKanbanPsRateServiceImpl extends ServiceImpl<TtKanbanPsRateMapper, TtKanbanPsRate> implements ITtKanbanPsRateService {
|
||||
@Autowired
|
||||
private TtKanbanPsRateMapper TtKanbanInWhMapper;
|
||||
|
||||
@Override
|
||||
public List<TtKanbanPsRate> kanbanPsRateList() {
|
||||
return TtKanbanInWhMapper.kanbanPsRateList();
|
||||
}
|
||||
}
|
@ -0,0 +1,84 @@
|
||||
<template>
|
||||
<a-drawer
|
||||
:title="title"
|
||||
:width="width"
|
||||
placement="right"
|
||||
:closable="false"
|
||||
@close="close"
|
||||
destroyOnClose
|
||||
:visible="visible">
|
||||
<tt-kanban-ps-rate-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit" normal></tt-kanban-ps-rate-form>
|
||||
<div class="drawer-footer">
|
||||
<a-button @click="handleCancel" style="margin-bottom: 0;">关闭</a-button>
|
||||
<a-button v-if="!disableSubmit" @click="handleOk" type="primary" style="margin-bottom: 0;">提交</a-button>
|
||||
</div>
|
||||
</a-drawer>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import TtKanbanPsRateForm from './TtKanbanPsRateForm'
|
||||
|
||||
export default {
|
||||
name: 'TtKanbanPsRateModal',
|
||||
components: {
|
||||
TtKanbanPsRateForm
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
title:"操作",
|
||||
width:800,
|
||||
visible: false,
|
||||
disableSubmit: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.add();
|
||||
})
|
||||
},
|
||||
edit (record) {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.edit(record);
|
||||
});
|
||||
},
|
||||
close () {
|
||||
this.$emit('close');
|
||||
this.visible = false;
|
||||
},
|
||||
submitCallback(){
|
||||
this.$emit('ok');
|
||||
this.visible = false;
|
||||
},
|
||||
handleOk () {
|
||||
this.$refs.realForm.submitForm();
|
||||
},
|
||||
handleCancel () {
|
||||
this.close()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
/** Button按钮间距 */
|
||||
.ant-btn {
|
||||
margin-left: 30px;
|
||||
margin-bottom: 30px;
|
||||
float: right;
|
||||
}
|
||||
.drawer-footer{
|
||||
position: absolute;
|
||||
bottom: -8px;
|
||||
width: 100%;
|
||||
border-top: 1px solid #e8e8e8;
|
||||
padding: 10px 16px;
|
||||
text-align: right;
|
||||
left: 0;
|
||||
background: #fff;
|
||||
border-radius: 0 0 2px 2px;
|
||||
}
|
||||
</style>
|
@ -0,0 +1,60 @@
|
||||
<template>
|
||||
<j-modal
|
||||
:title="title"
|
||||
:width="width"
|
||||
:visible="visible"
|
||||
switchFullscreen
|
||||
@ok="handleOk"
|
||||
:okButtonProps="{ class:{'jee-hidden': disableSubmit} }"
|
||||
@cancel="handleCancel"
|
||||
cancelText="关闭">
|
||||
<tt-kanban-ps-rate-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit"></tt-kanban-ps-rate-form>
|
||||
</j-modal>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import TtKanbanPsRateForm from './TtKanbanPsRateForm'
|
||||
export default {
|
||||
name: 'TtKanbanPsRateModal',
|
||||
components: {
|
||||
TtKanbanPsRateForm
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
title:'',
|
||||
width:800,
|
||||
visible: false,
|
||||
disableSubmit: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.add();
|
||||
})
|
||||
},
|
||||
edit (record) {
|
||||
this.visible=true
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.realForm.edit(record);
|
||||
})
|
||||
},
|
||||
close () {
|
||||
this.$emit('close');
|
||||
this.visible = false;
|
||||
},
|
||||
handleOk () {
|
||||
this.$refs.realForm.submitForm();
|
||||
},
|
||||
submitCallback(){
|
||||
this.$emit('ok');
|
||||
this.visible = false;
|
||||
},
|
||||
handleCancel () {
|
||||
this.close()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
@ -0,0 +1,201 @@
|
||||
package org.jeecg.modules.demo.kanbansales.controller;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
import java.io.IOException;
|
||||
import java.io.UnsupportedEncodingException;
|
||||
import java.net.URLDecoder;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import org.jeecg.common.api.vo.Result;
|
||||
import org.jeecg.common.system.query.QueryGenerator;
|
||||
import org.jeecg.common.util.oConvertUtils;
|
||||
import org.jeecg.modules.demo.kanbanplan.entity.TtKanbanPlan;
|
||||
import org.jeecg.modules.demo.kanbansales.entity.TtKanbanSales;
|
||||
import org.jeecg.modules.demo.kanbansales.service.ITtKanbanSalesService;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
|
||||
import org.jeecgframework.poi.excel.ExcelImportUtil;
|
||||
import org.jeecgframework.poi.excel.def.NormalExcelConstants;
|
||||
import org.jeecgframework.poi.excel.entity.ExportParams;
|
||||
import org.jeecgframework.poi.excel.entity.ImportParams;
|
||||
import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
|
||||
import org.jeecg.common.system.base.controller.JeecgController;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
import org.springframework.web.multipart.MultipartHttpServletRequest;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.jeecg.common.aspect.annotation.AutoLog;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
|
||||
/**
|
||||
* @Description: tt_kanban_sales
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-02-05
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Api(tags="tt_kanban_sales")
|
||||
@RestController
|
||||
@RequestMapping("/kanbansales/ttKanbanSales")
|
||||
@Slf4j
|
||||
public class TtKanbanSalesController extends JeecgController<TtKanbanSales, ITtKanbanSalesService> {
|
||||
@Autowired
|
||||
private ITtKanbanSalesService ttKanbanSalesService;
|
||||
|
||||
/**
|
||||
* 分页列表查询
|
||||
*
|
||||
* @param ttKanbanSales
|
||||
* @param pageNo
|
||||
* @param pageSize
|
||||
* @param req
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_kanban_sales-分页列表查询")
|
||||
@ApiOperation(value="tt_kanban_sales-分页列表查询", notes="tt_kanban_sales-分页列表查询")
|
||||
@GetMapping(value = "/list")
|
||||
public Result<IPage<TtKanbanSales>> queryPageList(TtKanbanSales ttKanbanSales,
|
||||
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
||||
HttpServletRequest req) {
|
||||
QueryWrapper<TtKanbanSales> queryWrapper = QueryGenerator.initQueryWrapper(ttKanbanSales, req.getParameterMap());
|
||||
Page<TtKanbanSales> page = new Page<TtKanbanSales>(pageNo, pageSize);
|
||||
IPage<TtKanbanSales> pageList = ttKanbanSalesService.page(page, queryWrapper);
|
||||
return Result.OK(pageList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 看板4列表查询
|
||||
*
|
||||
* @param ttKanbanSales
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_kanban_sales-分页列表查询")
|
||||
@ApiOperation(value="tt_kanban_sales-看板4列表查询", notes="tt_kanban_sales-看板4列表查询")
|
||||
@GetMapping(value = "/queryList")
|
||||
public Result<List<TtKanbanSales>> queryList(TtKanbanSales ttKanbanSales) {
|
||||
QueryWrapper<TtKanbanSales> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.eq("company_id", 1);
|
||||
List<String> list = new ArrayList<>();
|
||||
list.add("type_id");
|
||||
list.add("year_name");
|
||||
list.add("month_name");
|
||||
queryWrapper.orderByAsc(list);
|
||||
List<TtKanbanSales> kanbanSalesList = ttKanbanSalesService.list(queryWrapper);
|
||||
return Result.OK(kanbanSalesList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加
|
||||
*
|
||||
* @param ttKanbanSales
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_sales-添加")
|
||||
@ApiOperation(value="tt_kanban_sales-添加", notes="tt_kanban_sales-添加")
|
||||
//@RequiresPermissions("kanbansales:tt_kanban_sales:add")
|
||||
@PostMapping(value = "/add")
|
||||
public Result<String> add(@RequestBody TtKanbanSales ttKanbanSales) {
|
||||
ttKanbanSalesService.save(ttKanbanSales);
|
||||
return Result.OK("添加成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
*
|
||||
* @param ttKanbanSales
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_sales-编辑")
|
||||
@ApiOperation(value="tt_kanban_sales-编辑", notes="tt_kanban_sales-编辑")
|
||||
//@RequiresPermissions("kanbansales:tt_kanban_sales:edit")
|
||||
@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
|
||||
public Result<String> edit(@RequestBody TtKanbanSales ttKanbanSales) {
|
||||
ttKanbanSalesService.updateById(ttKanbanSales);
|
||||
return Result.OK("编辑成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_sales-通过id删除")
|
||||
@ApiOperation(value="tt_kanban_sales-通过id删除", notes="tt_kanban_sales-通过id删除")
|
||||
//@RequiresPermissions("kanbansales:tt_kanban_sales:delete")
|
||||
@DeleteMapping(value = "/delete")
|
||||
public Result<String> delete(@RequestParam(name="id",required=true) String id) {
|
||||
ttKanbanSalesService.removeById(id);
|
||||
return Result.OK("删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "tt_kanban_sales-批量删除")
|
||||
@ApiOperation(value="tt_kanban_sales-批量删除", notes="tt_kanban_sales-批量删除")
|
||||
//@RequiresPermissions("kanbansales:tt_kanban_sales:deleteBatch")
|
||||
@DeleteMapping(value = "/deleteBatch")
|
||||
public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
|
||||
this.ttKanbanSalesService.removeByIds(Arrays.asList(ids.split(",")));
|
||||
return Result.OK("批量删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "tt_kanban_sales-通过id查询")
|
||||
@ApiOperation(value="tt_kanban_sales-通过id查询", notes="tt_kanban_sales-通过id查询")
|
||||
@GetMapping(value = "/queryById")
|
||||
public Result<TtKanbanSales> queryById(@RequestParam(name="id",required=true) String id) {
|
||||
TtKanbanSales ttKanbanSales = ttKanbanSalesService.getById(id);
|
||||
if(ttKanbanSales==null) {
|
||||
return Result.error("未找到对应数据");
|
||||
}
|
||||
return Result.OK(ttKanbanSales);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出excel
|
||||
*
|
||||
* @param request
|
||||
* @param ttKanbanSales
|
||||
*/
|
||||
//@RequiresPermissions("kanbansales:tt_kanban_sales:exportXls")
|
||||
@RequestMapping(value = "/exportXls")
|
||||
public ModelAndView exportXls(HttpServletRequest request, TtKanbanSales ttKanbanSales) {
|
||||
return super.exportXls(request, ttKanbanSales, TtKanbanSales.class, "tt_kanban_sales");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过excel导入数据
|
||||
*
|
||||
* @param request
|
||||
* @param response
|
||||
* @return
|
||||
*/
|
||||
//@RequiresPermissions("kanbansales:tt_kanban_sales:importExcel")
|
||||
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||
return super.importExcel(request, response, TtKanbanSales.class);
|
||||
}
|
||||
|
||||
}
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in new issue