Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
T
template_vue
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
杨硕
template_vue
Commits
91dab02c
Commit
91dab02c
authored
Jul 31, 2023
by
刘宇扬
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/project1' into project1
parents
70fd5f77
3e0354d0
Changes
7
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
599 additions
and
432 deletions
+599
-432
inventoryRecord.js
src/api/sample/inventoryRecord.js
+31
-0
BaseTableArguments.js
src/components/Table/AllTableArguments/BaseTableArguments.js
+5
-27
index.vue
src/components/Table/BaseTable/index.vue
+8
-11
basicInfo.vue
src/views/equipment/basicInfo.vue
+8
-13
index.vue
src/views/processManagement/inventoryRecord/index.vue
+25
-24
index.vue
src/views/sample/inventoryRecord/index.vue
+522
-150
index.vue
src/views/sample/sampleLibrary/index.vue
+0
-207
No files found.
src/api/sample/inventoryRecord.js
0 → 100644
View file @
91dab02c
import
request
from
'@/utils/request'
// TODO: 用来进行工序库的出入库记录的 分页+时间+普通字段的查询
export
function
listLog
(
queryParams
)
{
return
request
({
url
:
'/wbchemistrylog/queryWbChemistryLogByPagination'
,
method
:
'get'
,
params
:
queryParams
})
}
/* TODO: 用来查询单项出入库记录的废弃详情信息 */
export
function
findSingleLogDetail
(
singleLogIdAndUser
)
{
return
request
({
url
:
'/wbchemistrylog/detail'
,
method
:
'post'
,
data
:
singleLogIdAndUser
,
headers
:
{
'Content-Type'
:
'application/json;charset=UTF-8'
}
})
}
/* TODO: 用来导出表单信息 */
export
function
exportInventoryRecord
()
{
return
request
({
url
:
'/wbchemistrylog/export'
,
method
:
'get'
,
responseType
:
'blob'
})
}
src/components/Table/AllTableArguments/BaseTableArguments.js
View file @
91dab02c
...
...
@@ -81,32 +81,10 @@ export function BaseTableArguments(selection, loading, processList, queryParams,
}
// TODO: 组件表单所需的所有参数
export
function
BaseTableArgumentsTest
(
nIndex
,
selection
,
loading
,
List
,
queryParams
,
columnData
)
{
// TODO: 选择框是否需要存在 (selection判断表单选择框是否需要存在)
if
(
typeof
selection
!==
'boolean'
)
{
console
.
warn
(
'selection下拉框参数的type类型错误!请检查后重新赋值'
)
}
else
{
this
.
selection
=
selection
// TODO: 选择框 (根据条件是否可选)
this
.
selectable
=
(
row
,
index
)
=>
{
if
(
row
.
isSwitch
)
{
return
true
}
}
}
// TODO: 加载进度 (判断是否显示加载进度)
if
(
typeof
loading
!==
'boolean'
)
{
console
.
warn
(
'loading进度条参数的type类型错误!请检查后重新赋值'
)
}
else
{
this
.
loading
=
loading
}
// TODO: 查询参数 (判断查询条件是否符合类型)
if
(
queryParams
instanceof
queryParamsType
)
{
this
.
queryParams
=
queryParamsType
}
this
.
columnData
=
columnData
export
function
BaseTableArgumentsTest
(
listName
,
loading
,
List
,
queryParams
,
columObj
)
{
this
.
listName
=
listName
this
.
loading
=
loading
this
.
List
=
List
this
.
queryParams
=
queryParams
this
.
columObj
=
columObj
}
src/components/Table/BaseTable/index.vue
View file @
91dab02c
...
...
@@ -9,7 +9,7 @@
border
:data=
"allTableArguments.List"
style=
"width: 100%;"
@
selection-change=
"handleSelectionChange"
@
selection-change=
"handleSelectionChange
(row)
"
>
<el-table-column
type=
"index"
label=
"序号"
width=
"50"
/>
...
...
@@ -46,17 +46,17 @@
<!-- 图片展示 -->
<el-popover
trigger=
"hover"
placement=
"top"
popper-class=
"popper"
>
<img
v-if=
"column.image"
:src=
"viewUrl + row[column.prop]"
alt=
""
>
<el-image
v-if=
"column.image"
slot=
"reference"
:src=
"viewUrl + row[column.prop]"
/>
<el-image
v-if=
"column.image"
:src=
"viewUrl + row[column.prop]"
/>
</el-popover>
<!-- 图片数组 -->
<el-popover
v-if=
"column.imageArr"
trigger=
"hover"
placement=
"top"
popper-class=
"popper"
>
<img
v-if=
"row[column.prop].length>0"
:src=
"row[column.prop][0]"
alt=
""
>
<el-image
v-if=
"row[column.prop].length >0"
slot=
"reference"
:src=
"row[column.prop][0]"
:preview-src-list=
"row[column.prop]"
/>
<el-image
v-if=
"row[column.prop].length >0"
:src=
"row[column.prop][0]"
:preview-src-list=
"row[column.prop]"
/>
</el-popover>
<!-- 可编辑input,仅在text默认展示类型才可编辑-->
<el-input
v-if=
"column.editRow === $index"
v-model=
"row[column.prop]"
v-focus
@
blur=
"editInputBlur(row,$index,column.prop,columIndex)"
/>
<el-input
v-if=
"column.editRow === $index"
v-model=
"row[column.prop]"
@
blur=
"editInputBlur(row,$index,column.prop,columIndex)"
/>
<!-- 操作按钮 -->
<span
v-if=
"column.isOperation"
class=
"processListBtns"
>
<span
v-for=
"(operations, index) in column.operation"
:key=
"index"
>
...
...
@@ -84,13 +84,7 @@ export default {
allTableArguments
:
{
type
:
BaseTableArgumentsTest
,
default
:
()
=>
{
return
{
selection
:
Boolean
,
loading
:
Boolean
,
queryParams
:
Object
,
List
:
Array
,
columnData
:
Array
}
return
new
BaseTableArgumentsTest
()
}
},
nIndex
:
{
...
...
@@ -107,6 +101,9 @@ export default {
}
},
methods
:
{
handleSelectionChange
(
row
)
{
this
.
$emit
(
'handle-selection-change'
,
row
)
},
handleDetail
(
row
)
{
this
.
$emit
(
'handle-detail'
,
row
)
},
...
...
src/views/equipment/basicInfo.vue
View file @
91dab02c
...
...
@@ -12,20 +12,20 @@
@
keyup
.
enter
.
native=
"handleQuery"
/>
</el-form-item>
<el-form-item
label=
"p
type
"
prop=
"pgx"
>
<el-form-item
label=
"p
gx
"
prop=
"pgx"
>
<el-input
v-model=
"queryParams.p
type
"
placeholder=
"请输入p
type
"
v-model=
"queryParams.p
gx
"
placeholder=
"请输入p
gx
"
clearable
size=
"small"
style=
"width: 150px"
@
keyup
.
enter
.
native=
"handleQuery"
/>
</el-form-item>
<el-form-item
label=
"p
gx"
prop=
"pgx
"
>
<el-form-item
label=
"p
rank"
prop=
"prank
"
>
<el-input
v-model=
"queryParams.p
gx
"
placeholder=
"请输入p
gx
"
v-model=
"queryParams.p
rank
"
placeholder=
"请输入p
rank
"
clearable
size=
"small"
style=
"width: 150px"
...
...
@@ -56,11 +56,6 @@
{{
scope
.
row
.
pn
||
'-'
}}
</
template
>
</el-table-column>
<el-table-column
label=
"ptype"
prop=
"ptype"
:show-overflow-tooltip=
"true"
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
ptype
||
'-'
}}
</
template
>
</el-table-column>
<el-table-column
label=
"pgx"
prop=
"pgx"
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
pgx
||
'-'
}}
...
...
@@ -236,11 +231,11 @@ export default {
pgx
:
[
{
required
:
true
,
message
:
'请输入pgx'
,
trigger
:
'blur'
}
],
prank
:
[{
pattern
:
/^
[
0-9
]{1,9}(\.[
0-9
]{1,3})?
$/
,
message
:
'仅能输入数字和小数,限制三位小数'
,
trigger
:
'change'
}],
prank
:
[{
required
:
true
,
pattern
:
/^
[
0-9
]{1,9}(\.[
0-9
]{1,3})?
$/
,
message
:
'仅能输入数字和小数,限制三位小数'
,
trigger
:
'change'
}],
pissb
:
[
{
required
:
true
,
message
:
'请输入pissb'
,
trigger
:
'blur'
}
],
psm
:
[{
pattern
:
/^
[
0-9
]{1,9}(\.[
0-9
]{1,3})?
$/
,
message
:
'仅能输入数字和小数,限制三位小数'
,
trigger
:
'change'
}],
psm
:
[{
required
:
true
,
pattern
:
/^
[
0-9
]{1,9}(\.[
0-9
]{1,3})?
$/
,
message
:
'仅能输入数字和小数,限制三位小数'
,
trigger
:
'change'
}],
psy
:
[
{
required
:
true
,
message
:
'请输入psy'
,
trigger
:
'blur'
}
]
...
...
src/views/processManagement/inventoryRecord/index.vue
View file @
91dab02c
...
...
@@ -113,7 +113,6 @@
<component
:is=
"BaseTable"
:key=
"queryParams.rows"
:n-index=
"nIndex"
:all-table-arguments=
"allTableArguments"
@
handle-detail=
"handleDetail"
/>
...
...
@@ -164,7 +163,6 @@
<!-- TODO: 这里是 库状态为废弃时才会触发显示的模块 -->
<transition
name=
"fade-transform"
mode=
"out-in"
>
<el-row
v-if=
" activateAbandonedState "
style=
"height: 160px"
>
<el-col
:span=
"12"
>
<el-form-item
label=
"fq_ys:"
prop=
"fq_ys"
>
...
...
@@ -189,31 +187,32 @@
</el-form-item>
</el-col>
</el-row>
<transition
/
>
</transition
>
<el-row>
<el-col
:span=
"12"
>
<el-form-item
label=
"操作员:"
prop=
"userName"
>
<el-input
v-model
.
trim=
"singleDetails.userName"
:readonly=
"isReadOnly"
/>
</el-form-item>
</el-col>
<el-row>
<el-col
:span=
"12"
>
<el-form-item
label=
"操作员:"
prop=
"userName"
>
<el-input
v-model
.
trim=
"singleDetails.userName"
:readonly=
"isReadOnly"
/>
</el-form-item>
</el-col>
<el-col
:span=
"12"
>
<el-form-item
label=
"操作时间:"
prop=
"createDate"
>
<el-input
v-model
.
trim=
"singleDetails.createDate"
:readonly=
"isReadOnly"
/>
</el-form-item>
</el-col>
</el-row>
<el-col
:span=
"12"
>
<el-form-item
label=
"操作时间:"
prop=
"createDate"
>
<el-input
v-model
.
trim=
"singleDetails.createDate"
:readonly=
"isReadOnly"
/>
</el-form-item>
</el-col>
</el-row>
</transition>
</el-form>
</el-form>
</el-dialog>
</div>
</
template
>
<
script
>
import
{
listLog
,
findSingleLogDetail
,
exportInventoryRecord
}
from
'@/api/processMangement/InventoryRecord'
import
{
exportInventoryRecord
,
findSingleLogDetail
,
listLog
}
from
'@/api/processMangement/InventoryRecord'
import
BaseTable
from
'@/components/Table/BaseTable/index.vue'
import
{
BaseTableArgumentsTest
}
from
'@/components/Table/AllTableArguments/BaseTableArguments'
export
default
{
name
:
'InventoryRecord'
,
...
...
@@ -290,6 +289,8 @@ export default {
// TODO: 库类型 1设备库 2工序库
ptype
:
undefined
},
// TODO: list记录表名
listName
:
'出入库记录列表'
,
// TODO: 用来接收数据源
inventoryRecordList
:
[],
// TODO: 用来说明每一列的类型
...
...
@@ -394,13 +395,13 @@ export default {
},
// TODO: 用来汇总Table组件所需要的全部数据并一次性传输给子组件
allTableArguments
()
{
return
{
listName
:
'出入库记录列表'
,
loading
:
this
.
loading
,
List
:
this
.
inventoryRecordList
,
queryParams
:
this
.
queryParams
,
columObj
:
this
.
columObj
}
const
baseTableArgumentsTest
=
new
BaseTableArgumentsTest
()
baseTableArgumentsTest
.
listName
=
this
.
listName
baseTableArgumentsTest
.
loading
=
this
.
loading
baseTableArgumentsTest
.
List
=
this
.
inventoryRecordList
baseTableArgumentsTest
.
queryParams
=
this
.
queryParams
baseTableArgumentsTest
.
columObj
=
this
.
columObj
return
baseTableArgumentsTest
}
},
/** 路由离开前存储筛选条件*/
...
...
src/views/sample/inventoryRecord/index.vue
View file @
91dab02c
This diff is collapsed.
Click to expand it.
src/views/sample/sampleLibrary/index.vue
deleted
100644 → 0
View file @
70fd5f77
<
template
>
<div
class=
"basicInformation-module app-container"
>
<!-- 搜索区 -->
<el-form
ref=
"queryForm"
style=
"padding: 0 0 0 10px"
:model=
"queryParams"
:inline=
"true"
>
<el-form-item
label=
"pn"
prop=
"pn"
>
<el-input
v-model=
"queryParams.pn"
placeholder=
"请输入pn"
clearable
:maxlength=
"30"
size=
"small"
style=
"width: 150px"
@
keyup
.
enter
.
native=
"handleQuery"
/>
</el-form-item>
<el-form-item
label=
"name"
prop=
"name"
>
<el-input
v-model=
"queryParams.name"
placeholder=
"请输入名称"
clearable
size=
"small"
style=
"width: 150px"
@
keyup
.
enter
.
native=
"handleQuery"
/>
</el-form-item>
<el-form-item>
<el-button
type=
"primary"
style=
"padding: 8px 7px;"
icon=
"el-icon-search"
size=
"small"
@
click=
"handleQuery"
>
查询
</el-button>
<el-button
type=
"primary"
style=
"padding: 8px 7px;"
icon=
"el-icon-refresh"
size=
"small"
@
click=
"resetQuery"
>
重置
</el-button>
</el-form-item>
<div
style=
"float: right"
>
<el-form-item>
<el-button
type=
"primary"
size=
"small"
icon=
"el-icon-plus"
@
click=
"handleAdd"
>
新增
</el-button>
<el-button
style=
"padding: 8px 7px;"
type=
"success"
size=
"small"
icon=
"el-icon-download"
@
click=
"handleExport"
>
导出
</el-button>
</el-form-item>
</div>
</el-form>
<!-- 分割线 -->
<div
class=
"placeholder"
/>
<!-- 表单区 -->
<div
style=
"padding:5px 10px"
>
<div
class=
"mb12 font-small-bold"
>
基础样式列表
</div>
<el-table
v-loading=
"loading"
border
:data=
"basicinfoMationList"
>
<el-table-column
type=
"index"
label=
"序号"
width=
"50"
/>
<el-table-column
label=
"pn"
prop=
"pn"
:show-overflow-tooltip=
"true"
>
<template
slot-scope=
"scope"
>
{{
scope
.
row
.
pn
||
'-'
}}
</
template
>
</el-table-column>
<el-table-column
label=
"qty"
prop=
"qty"
:show-overflow-tooltip=
"true"
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
qty
||
'-'
}}
</
template
>
</el-table-column>
<el-table-column
label=
"name"
prop=
"name"
:show-overflow-tooltip=
"true"
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
name
||
'-'
}}
</
template
>
</el-table-column>
<el-table-column
label=
"max_qty"
prop=
"max_qty"
:show-overflow-tooltip=
"true"
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
max_qty
||
'-'
}}
</
template
>
</el-table-column>
<el-table-column
label=
"min_qty"
prop=
"min_qty"
:show-overflow-tooltip=
"true"
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
min_qty
||
'-'
}}
</
template
>
</el-table-column>
<el-table-column
label=
"unit"
prop=
"unit"
:show-overflow-tooltip=
"true"
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
unit
||
'-'
}}
</
template
>
</el-table-column>
<el-table-column
label=
"操作人"
prop=
"createName"
:show-overflow-tooltip=
"true"
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
createName
||
'-'
}}
</
template
>
</el-table-column>
<el-table-column
label=
"操作时间"
prop=
"create_date"
:show-overflow-tooltip=
"true"
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
create_date
||
'-'
}}
</
template
>
</el-table-column>
<el-table-column
label=
"操作"
>
<
template
slot-scope=
"scope"
>
<el-button
size=
"mini"
type=
"text"
style=
"color: #49cec9"
@
click=
"handleUpdate(scope.row)"
>
修改
</el-button>
<!--
<el-button-->
<!-- v-hasPermi="['sys:role:update']"-->
<!-- size="mini"-->
<!-- type="text"-->
<!-- icon="el-icon-circle-check"-->
<!-- @click="handleMenu(scope.row)"-->
<!-- >数据权限
</el-button>
-->
<el-button
size=
"mini"
type=
"text"
icon=
"el-icon-delete"
@
click=
"handleDelete(scope.row)"
>
删除
</el-button>
</
template
>
</el-table-column>
</el-table>
</div>
<!-- 分页区-->
<pagination
v-show=
"total>0"
:total=
"total"
:page
.
sync=
"queryParams.page"
:limit
.
sync=
"queryParams.page"
@
pagination=
"getList"
/>
<!-- 新增修改弹出 -->
</div>
</template>
<
script
>
import
{
queryList
}
from
'@/api/sample/basicInformation'
export
default
{
name
:
'Index'
,
data
()
{
return
{
total
:
0
,
loading
:
false
,
queryParams
:
{
page
:
1
,
rows
:
10
,
pn
:
''
,
name
:
''
},
statusOptions
:
{},
basicinfoMationList
:
[]
}
},
created
()
{
this
.
getList
()
},
methods
:
{
handleDelete
()
{
},
handleUpdate
()
{
},
// 初始化获取数据
getList
()
{
this
.
loading
=
true
queryList
(
this
.
queryParams
).
then
(
res
=>
{
console
.
log
(
'res'
,
res
)
this
.
total
=
res
.
total
this
.
basicinfoMationList
=
res
.
rows
this
.
loading
=
false
})
},
// 查询
handleQuery
()
{
this
.
queryParams
.
page
=
1
this
.
getList
()
},
// 重置
resetQuery
()
{
this
.
queryParams
=
{
page
:
1
,
rows
:
10
,
pn
:
''
,
name
:
''
}
this
.
getList
()
},
handleAdd
()
{
},
handleExport
()
{
}
}
}
</
script
>
<
style
lang=
"scss"
scoped
>
.basicInformation-module
{
font-size
:
18px
;
padding
:
0
;
.placeholder
{
height
:
1
.3vh
;
background-color
:
#F4F4F4
;
margin-bottom
:
10px
}
}
</
style
>
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment