增加品规管理

bozhou-古井贡酒
LAPTOP-S9HJSOEB\昊天 4 months ago
parent d1e2cae606
commit 7d1bb40fd0

@ -177,6 +177,11 @@ export default {
name: '复核页面的核对信息',
method: 'POST'
},
fatherList: {
url: '/category/fatherList',
name: '品规信息',
method: 'GET'
},
getCategoryList: {
url: '/stock/getCategoryList',
name: '品规信息',

@ -164,6 +164,15 @@ const routes = [{
},
component: () => import('@/views/cameraManage/model')
},
{
path: 'productSpecManage',
name: 'productSpecManage',
meta: {
icon: 'pushpin',
name: '品规管理'
},
component: () => import('@/views/productSpecManage/index')
},
// {
// path: 'productSpecManage',
// name: 'productSpecManage',

@ -4,23 +4,7 @@
<a-button type="primary" class="add" @click="showModel('add','')">
新增
</a-button>
<a-upload
name="file"
:multiple="true"
accept=".xlsx"
:action="uploadProps.action"
:showUploadList = 'false'
@change="handleChange"
ref="table"
style="margin-right:15px"
>
<a-button type="primary" >
导入
</a-button>
</a-upload>
<a-button type="" @click="categoryExportModel">
模板下载
</a-button>
</div>
<a-table
style="margin-top:40px"
@ -76,6 +60,26 @@ const columns = [
title: '条码',
dataIndex: 'code',
},
{
title: '一行个数',
dataIndex: 'count',
},
{
title: '度数',
dataIndex: 'degree',
},
{
title: '毫升',
dataIndex: 'milliliter',
},
{
title: '一箱个数',
dataIndex: 'number',
},
{
title: '父类类型',
dataIndex: 'fatherName',
},
{
title: '修改时间',
dataIndex: 'updateTime',
@ -155,6 +159,7 @@ export default {
}).catch(err => {
});
},
categoryExportModel() {
this.$api.httpApi.categoryExportModel({

@ -32,6 +32,56 @@
v-decorator="['code', { rules: [{ required: true, message: '请输入条码!' }] }]"
/>
</a-form-item>
<a-form-item label="度数"
:label-col="formItemVerticalLayout.labelCol"
>
<a-input
v-decorator="['degree', { rules: [{ required: true, message: '请输入度数!' }] }]"
/>
</a-form-item>
<a-form-item label="毫升"
:label-col="formItemVerticalLayout.labelCol"
>
<a-input
v-decorator="['milliliter', { rules: [{ required: true, message: '请输入度数!' }] }]"
/>
</a-form-item>
<a-form-item label="一箱个数"
:label-col="formItemVerticalLayout.labelCol"
> <a-input
v-decorator="['number', { rules: [{ required: true, message: '请输入一箱个数!' }] }]"
/>
</a-form-item>
<a-form-item label="一排个数"
:label-col="formItemVerticalLayout.labelCol"
>
<a-input
v-decorator="['count', { rules: [{ required: true, message: '请输入条码!' }] }]"
/>
</a-form-item>
<a-form-item label="父类类型"
:label-col="formItemVerticalLayout.labelCol"
>
<a-select
v-decorator="['father', { rules: [{ required: true, message: '请选择父类类型!' }] }]"
placeholder="请选择父类类型"
>
<a-select-option
v-for="(item, index) in fathers"
:key="index"
:value="index"
>
{{ item }}
</a-select-option>
</a-select>
</a-form-item>
</a-form>
</a-modal>
</template>
@ -68,6 +118,11 @@ export default {
this.form.setFieldsValue({ //setFieldsValue form
name:newVal.name,
code:newVal.code,
count:newVal.count,
father:newVal.father,
degree:newVal.degree,
milliliter:newVal.milliliter,
number:newVal.number,
ip:newVal.ip,
rtsp:newVal.rtsp
})
@ -79,6 +134,7 @@ export default {
},
data() {
return {
fathers:[],
isShow:false,
type:'',
title:'',
@ -93,8 +149,20 @@ export default {
},
mounted() {
console.log('mounted执行了')
this.request()
},
methods: {
request(){
this.$api.httpApi.fatherList({
}).then(res => {
this.fathers = res.data
}).catch(err => {
});
},
handleOk() {
this.confirmLoading = true;
setTimeout(() => {

Loading…
Cancel
Save