Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
glsx-business
/
website-middleground
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 810ee5f5
authored
Jul 29, 2024
by
前端
Browse Files
Options
Browse Files
Tag
Download
Plain Diff
Merge branch 'v1.0.0' of
http://192.168.3.233:8090/glsx-business/website-middleground
into v1.0.0
2 parents
ed633fd3
286d6686
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
32 additions
and
14 deletions
src/views/investorRelated/addInvnotice.vue
src/views/investorRelated/components/AddForm.vue
src/views/investorRelated/index.vue
src/views/investorRelated/interface.ts
src/views/investorRelated/addInvnotice.vue
View file @
810ee5f
<
script
lang=
"ts"
setup
>
import
{
useRouter
}
from
"vue-router"
;
import
{
reactive
,
onMounted
}
from
'vue'
import
{
useRouter
,
useRoute
}
from
"vue-router"
;
import
{
reactive
,
onMounted
,
toRefs
}
from
'vue'
import
{
DataInfo
}
from
"./addInterface"
;
import
AddForm
from
"./components/AddForm.vue"
;
let
route
=
useRoute
()
let
{
query
}
=
toRefs
(
route
)
const
router
=
useRouter
();
const
form
=
reactive
<
Partial
<
DataInfo
>>
({
name
:
''
...
...
@@ -19,10 +21,10 @@ const handleSubmit = () => {
<
template
>
<a-breadcrumb>
<a-breadcrumb-item
class=
"back"
@
click=
"back"
>
投资者相关
</a-breadcrumb-item>
<a-breadcrumb-item>
新增
公告
</a-breadcrumb-item>
<a-breadcrumb-item>
{{
query
.
id
?
'编辑'
:
'新增'
}}
公告
</a-breadcrumb-item>
</a-breadcrumb>
<div
class=
"add-box"
>
<a-page-header
:style=
"
{ background: 'var(--color-bg-2)' }"
title="新增公告
" :show-back="false">
</a-page-header>
<a-page-header
:style=
"
{ background: 'var(--color-bg-2)' }"
:title="`${query.id ? '编辑' : '新增'}公告`
" :show-back="false">
</a-page-header>
<div
class=
"form"
>
<AddForm></AddForm>
</div>
...
...
src/views/investorRelated/components/AddForm.vue
View file @
810ee5f
...
...
@@ -3,10 +3,10 @@
* @Author: huyue
* @Date: 2024-07-26 10:46:04
* @LastEditors: huyue
* @LastEditTime: 2024-07-29 1
6:13:48
* @LastEditTime: 2024-07-29 1
7:20:35
-->
<
script
lang=
"ts"
setup
>
import
{
reactive
,
ref
,
nextTick
}
from
"vue"
;
import
{
reactive
,
ref
,
nextTick
,
toRefs
,
onMounted
}
from
"vue"
;
import
{
DataInfo
}
from
"../addInterface"
;
import
{
RequestOption
,
FileItem
}
from
"@arco-design/web-vue"
;
import
{
req
,
uploadReq
,
uploadFile
}
from
"../../../utils/request"
;
...
...
@@ -161,6 +161,14 @@ const getList = async () => {
const
res
=
await
req
(
"gw.api.invnotice.findAllTypeByLanguageCode"
);
data
.
sectionList
=
res
;
};
const
findById
=
async
()
=>
{
const
id
=
query
.
value
.
id
const
res
=
await
req
(
"gw.api.invnotice.findById"
,
{
id
});
console
.
log
(
res
)
// form = res;
// data.childPass = res.childPass;
}
findById
()
getList
();
/** 自定义上传 */
// 图片的
...
...
src/views/investorRelated/index.vue
View file @
810ee5f
...
...
@@ -3,7 +3,7 @@
* @Author: huyue
* @Date: 2024-07-23 16:43:07
* @LastEditors: huyue
* @LastEditTime: 2024-07-29 16:
21:16
* @LastEditTime: 2024-07-29 16:
57:27
-->
<!--
* @Description:
...
...
@@ -13,7 +13,7 @@
* @LastEditTime: 2024-07-29 15:46:54
-->
<
script
lang=
"ts"
setup
>
import
{
h
,
reactive
}
from
"vue"
;
import
{
h
,
reactive
,
ref
}
from
"vue"
;
import
{
useRouter
}
from
"vue-router"
;
import
{
DataInfo
,
TableItem
,
BasicItem
}
from
"./interface"
;
import
{
req
}
from
"../../utils/request"
;
...
...
@@ -28,7 +28,8 @@ const data = reactive<Partial<DataInfo>>({
pageNum
:
1
,
pageSize
:
10
},
imgVisible
:
false
imgVisible
:
false
,
imgUrl
:
''
})
/** table列配置 */
const
columns
=
[
...
...
@@ -57,7 +58,6 @@ const columns = [
const
vnode
=
(
record
:
Partial
<
TableItem
>
)
=>
{
const
{
invnoticeProductTranslationsList
,
externalReleaseDate
,
zhTag
}
=
record
;
const
_CN
=
invnoticeProductTranslationsList
?.
find
((
item
:
Partial
<
BasicItem
>
)
=>
item
.
languageCode
==
'zh-CN'
)
console
.
log
(
_CN
)
const
_US
=
invnoticeProductTranslationsList
?.
find
((
item
:
Partial
<
BasicItem
>
)
=>
item
.
languageCode
==
'en-US'
)
const
_TW
=
invnoticeProductTranslationsList
?.
find
((
item
:
Partial
<
BasicItem
>
)
=>
item
.
languageCode
==
'zh-TW'
)
return
h
(
'div'
,
{},
[
...
...
@@ -147,10 +147,16 @@ const down = (record: Partial<TableItem>) => {
}
const edit = (record: Partial<TableItem>) => {
router.push({
path: "/layout/addInvnotice",
query: {
id: record?.id
}
});
}
const previewOA = () => {
const previewOA = (
record: Partial<TableItem>
) => {
data.imgVisible = true
data.imgUrl = record?.oaScreenshotUrl
}
// 接口定义、调用
const getList = async () => {
...
...
@@ -191,9 +197,9 @@ getTableData()
<a-button
type=
"text"
@
click=
"publish(record)"
v-if=
"record.systemPublishStatus === 1 || record.systemPublishStatus === 2"
>
发布
</a-button>
<a-button
type=
"text"
@
click=
"down(record)"
v-if=
"record.systemPublishStatus === 3"
>
下架
</a-button>
<a-button
type=
"text"
@
click=
"edit(record)"
v-if=
"record.systemPublishStatus === 1 || record.systemPublishStatus === 2"
>
编辑
</a-button>
<a-button
type=
"text"
@
click=
"previewOA"
>
OA截图
</a-button>
<a-button
type=
"text"
@
click=
"previewOA
(record)
"
>
OA截图
</a-button>
<a-image-preview
:src=
"
record.oaScreenshot
Url"
:src=
"
data.img
Url"
v-model:visible=
"data.imgVisible"
/>
</
template
>
...
...
src/views/investorRelated/interface.ts
View file @
810ee5f
...
...
@@ -20,6 +20,7 @@ export interface DataInfo {
total
:
Number
;
page
:
Page
;
imgVisible
:
Boolean
;
imgUrl
:
String
;
}
export
interface
TableItem
{
...
...
@@ -31,4 +32,5 @@ export interface TableItem {
invnoticeProductTranslationsList
:
Partial
<
BasicItem
>
[],
externalReleaseDate
:
String
;
zhTag
:
String
;
oaScreenshotUrl
:
String
;
}
Write
Preview
Markdown
is supported
Attach a file
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 post a comment