Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
sgaqgl-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
李苏
sgaqgl-vue
Commits
fb276076
Commit
fb276076
authored
Nov 04, 2022
by
李苏
💬
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
部分
parent
59f05eb8
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
28 additions
and
11 deletions
+28
-11
main.js
src/main.js
+0
-1
index.vue
src/views/riskPrecontrol/maintenanceRiskTask/index.vue
+5
-0
content.vue
src/views/riskPrecontrol/screeningCriteria/content.vue
+2
-1
contentEdit.vue
src/views/riskPrecontrol/screeningCriteria/contentEdit.vue
+2
-2
index.vue
src/views/riskPrecontrol/screeningCriteria/index.vue
+3
-3
babel-clearArrow.js
tools/babel-clearArrow.js
+16
-4
No files found.
src/main.js
View file @
fb276076
import
Vue
from
'vue'
import
Vue
from
'vue'
/* 引入公用UI插件 */
/* 引入公用UI插件 */
import
Element
from
'element-ui'
import
Element
from
'element-ui'
import
Cookies
from
'js-cookie'
import
Cookies
from
'js-cookie'
...
...
src/views/riskPrecontrol/maintenanceRiskTask/index.vue
View file @
fb276076
...
@@ -50,6 +50,9 @@
...
@@ -50,6 +50,9 @@
<el-tabs
v-model=
"activeName"
@
tab-click=
"handleClick"
>
<el-tabs
v-model=
"activeName"
@
tab-click=
"handleClick"
>
<el-tab-pane
label=
"检查标准"
name=
"first"
>
<el-tab-pane
label=
"检查标准"
name=
"first"
>
<Details
/>
<Details
/>
</el-tab-pane>
<el-tab-pane
label=
"检查项"
name=
"second"
>
<Content
/>
</el-tab-pane>
</el-tab-pane>
<!-- -->
<!-- -->
</el-tabs>
</el-tabs>
...
@@ -72,6 +75,7 @@
...
@@ -72,6 +75,7 @@
/* edit页面*/
/* edit页面*/
import
Edit
from
'./edit'
import
Edit
from
'./edit'
import
Details
from
'./details.vue'
import
Details
from
'./details.vue'
import
Content
from
'./content.vue'
import
{
import
{
tableMixin
tableMixin
}
from
'common'
}
from
'common'
...
@@ -230,6 +234,7 @@
...
@@ -230,6 +234,7 @@
components
:
{
components
:
{
Edit
,
Edit
,
Details
,
Details
,
Content
}
}
...
...
src/views/riskPrecontrol/screeningCriteria/content.vue
View file @
fb276076
...
@@ -51,7 +51,8 @@
...
@@ -51,7 +51,8 @@
mid
:
''
mid
:
''
},
},
/* 表格标题对应参数*/
/* 表格标题对应参数*/
tableTitle
:
[{
label
:
"标准ID"
,
prop
:
"mid"
,
fieldType
:
"ftString"
,
width
:
192
},
tableTitle
:
[
// {label: "标准ID", prop: "mid", fieldType: "ftString",width:192},
{
label
:
"检查内容"
,
prop
:
"nr"
,
fieldType
:
"ftString"
,
width
:
300
},
{
label
:
"检查内容"
,
prop
:
"nr"
,
fieldType
:
"ftString"
,
width
:
300
},
{
label
:
"检查分值"
,
prop
:
"jcfz"
,
fieldType
:
"float"
},
{
label
:
"检查分值"
,
prop
:
"jcfz"
,
fieldType
:
"float"
},
{
label
:
"备注"
,
prop
:
"bz"
,
fieldType
:
"ftString"
,
width
:
300
},
{
label
:
"备注"
,
prop
:
"bz"
,
fieldType
:
"ftString"
,
width
:
300
},
...
...
src/views/riskPrecontrol/screeningCriteria/contentEdit.vue
View file @
fb276076
...
@@ -2,13 +2,13 @@
...
@@ -2,13 +2,13 @@
<RelDialog
:type=
'type'
:editApp=
'editApp'
:app=
'app'
:buttonApp=
'buttonApp'
>
<RelDialog
:type=
'type'
:editApp=
'editApp'
:app=
'app'
:buttonApp=
'buttonApp'
>
<!-- 填写表单内容,slot=form必写-->
<!-- 填写表单内容,slot=form必写-->
<el-form
slot=
"form"
ref=
"form"
:model=
"form"
label-width=
"80px"
:rules=
"rules"
>
<el-form
slot=
"form"
ref=
"form"
:model=
"form"
label-width=
"80px"
:rules=
"rules"
>
<el-row
:gutter=
"20"
>
<
!--
<
el-row
:gutter=
"20"
>
<el-col
:span=
"24"
>
<el-col
:span=
"24"
>
<el-form-item
label=
"标准ID"
ref=
"mid"
prop=
"mid"
>
<el-form-item
label=
"标准ID"
ref=
"mid"
prop=
"mid"
>
<el-input
:readonly=
"readonly"
v-model=
"form.mid"
></el-input>
<el-input
:readonly=
"readonly"
v-model=
"form.mid"
></el-input>
</el-form-item>
</el-form-item>
</el-col>
</el-col>
</el-row>
</el-row>
-->
<el-row
:gutter=
"20"
>
<el-row
:gutter=
"20"
>
<el-col
:span=
"24"
>
<el-col
:span=
"24"
>
<el-form-item
label=
"检查内容"
ref=
"nr"
prop=
"nr"
>
<el-form-item
label=
"检查内容"
ref=
"nr"
prop=
"nr"
>
...
...
src/views/riskPrecontrol/screeningCriteria/index.vue
View file @
fb276076
...
@@ -110,9 +110,9 @@
...
@@ -110,9 +110,9 @@
},
},
/* 表格标题对应参数*/
/* 表格标题对应参数*/
tableTitle
:
[
tableTitle
:
[
{
label
:
"部门
ID"
,
prop
:
"bmid
"
,
fieldType
:
"ftString"
,
width
:
192
},
{
label
:
"部门
"
,
prop
:
"bmName
"
,
fieldType
:
"ftString"
,
width
:
192
},
{
label
:
"车间
ID"
,
prop
:
"cjid
"
,
fieldType
:
"ftString"
,
width
:
192
},
{
label
:
"车间
"
,
prop
:
"cjName
"
,
fieldType
:
"ftString"
,
width
:
192
},
{
label
:
"岗位
ID"
,
prop
:
"gwid
"
,
fieldType
:
"ftString"
,
width
:
192
},
{
label
:
"岗位
"
,
prop
:
"gwName
"
,
fieldType
:
"ftString"
,
width
:
192
},
{
label
:
"风险地点"
,
prop
:
"fxpcdd"
,
fieldType
:
"ftString"
,
width
:
300
},
{
label
:
"风险地点"
,
prop
:
"fxpcdd"
,
fieldType
:
"ftString"
,
width
:
300
},
{
label
:
"风险点"
,
prop
:
"fxd"
,
fieldType
:
"ftString"
,
width
:
300
},
{
label
:
"风险点"
,
prop
:
"fxd"
,
fieldType
:
"ftString"
,
width
:
300
},
{
label
:
"事故类型"
,
prop
:
"sglx"
,
fieldType
:
"ftString"
,
width
:
192
},
{
label
:
"事故类型"
,
prop
:
"sglx"
,
fieldType
:
"ftString"
,
width
:
192
},
...
...
tools/babel-clearArrow.js
View file @
fb276076
module
.
exports
=
function
(
babel
)
{
module
.
exports
=
function
(
babel
)
{
/* 遍历AST时匹配visitor对象,遍历到FunctionDeclaration的节点会执行该回调*/
/* 遍历AST时匹配visitor对象,遍历到FunctionDeclaration的节点会执行该回调*/
/* https://babeljs.io/docs/en/babel-types查看全部节点信息*/
/* https://babeljs.io/docs/en/babel-types查看全部节点信息*/
function
generateBindName
(
path
,
name
=
'_this'
,
n
=
''
)
{
function
generateBindName
(
path
,
name
=
'_this'
,
n
=
''
)
{
if
(
path
.
scope
.
hasBinding
(
name
))
{
if
(
path
.
scope
.
hasBinding
(
name
))
{
generateBindName
(
path
,
'_this'
+
n
,
parseInt
(
n
)
+
1
);
generateBindName
(
path
,
'_this'
+
n
,
parseInt
(
n
)
+
1
);
...
@@ -18,7 +15,7 @@ function generateBindName(path, name = '_this', n = '') {
...
@@ -18,7 +15,7 @@ function generateBindName(path, name = '_this', n = '') {
/* 每一个方法都存在一个nodePath参数,所谓的nodePath参数你可以将它理解成为一个节点路径。它包含了这个树上这个节点分叉的所有信息和对应的api。注意这里可以强调是路径,你可以在这里查阅它的含义以及对应的所有API。*/
/* 每一个方法都存在一个nodePath参数,所谓的nodePath参数你可以将它理解成为一个节点路径。它包含了这个树上这个节点分叉的所有信息和对应的api。注意这里可以强调是路径,你可以在这里查阅它的含义以及对应的所有API。*/
/* AST编译参考 https://astexplorer.net/*/
/* AST编译参考 https://astexplorer.net/*/
const
node
=
nodePath
.
node
;
const
node
=
nodePath
.
node
;
console
.
log
(
node
)
}
}
}
}
...
@@ -26,3 +23,18 @@ function generateBindName(path, name = '_this', n = '') {
...
@@ -26,3 +23,18 @@ function generateBindName(path, name = '_this', n = '') {
visitor
visitor
}
}
}
}
// const babel = require('@babel/core');
// const babelTypes = require('@babel/types');
// const arrowFunction = require('@babel/plugin-transform-arrow-functions');
// const sourceCode = `const arrowFunc = () => {
// console.log(this)
// }`;
// const targetCode = babel.transform(sourceCode, {
// plugins: [arrowFunction]
// }, );
\ No newline at end of file
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