Compare commits
No commits in common. "3e310fb7ea0f5509a88cb450a8dfa2a7215393f2" and "f36e2bbffcb0749b562d6b379ae9d969b92ceb60" have entirely different histories.
3e310fb7ea
...
f36e2bbffc
|
@ -71,7 +71,7 @@
|
|||
|
||||
<!--操作按钮查询-->
|
||||
<el-form-item>
|
||||
<el-button type="primary" @click="getDataList()">{{ $t('query') }}</el-button>
|
||||
<el-button @click="getDataList()">{{ $t('query') }}</el-button>
|
||||
</el-form-item>
|
||||
<!--操作按钮重置-->
|
||||
<el-form-item>
|
||||
|
|
|
@ -106,8 +106,7 @@ const algorithmCardPhoto = (item) => {
|
|||
if(item.pic && typeof item.pic == 'string') {
|
||||
_arr = JSON.parse(item.pic)
|
||||
}
|
||||
let _img = _arr[0] && _arr[0].img || imgSrc.value;
|
||||
console.log('_img------------>', _img);
|
||||
let _img = _arr[0] && _arr[0].img || ''
|
||||
return _img
|
||||
}
|
||||
//跳转详情页
|
||||
|
|
|
@ -45,6 +45,7 @@
|
|||
:fallback="imgSrc"
|
||||
:preview="false"
|
||||
></a-image>
|
||||
|
||||
<a-tooltip>
|
||||
<template #title>{{ item.name }}</template>
|
||||
<div class="algorithm-card-title" @click="detailFunction(item.id)">
|
||||
|
@ -60,6 +61,7 @@
|
|||
import { getCategoryTreePage } from '@/api/personalCenter'
|
||||
import { getGisByArea } from '@/api/home'
|
||||
import { ref, onMounted, onBeforeUnmount, nextTick } from 'vue'
|
||||
|
||||
const deptType = ref(null)
|
||||
const typeName = ref('全市')
|
||||
const typeName2 = ref('全部')
|
||||
|
@ -85,6 +87,7 @@
|
|||
area: typeName2.value == '全部' ? '' : typeName2.value,
|
||||
pageSize: 9, // 固定9
|
||||
}
|
||||
|
||||
// 切换领域
|
||||
const changeAreaFunction = (val) => {
|
||||
params.pageNum = 1
|
||||
|
@ -93,6 +96,7 @@
|
|||
selectFlag2.value = false
|
||||
pageWithAttrsFunction()
|
||||
}
|
||||
|
||||
let algorithmclassDom = null
|
||||
const imgSrc = ref(require('@/assets/capacitySquare/algorithm-photo2.jpg'))
|
||||
const dataLength = ref(true)
|
||||
|
@ -106,10 +110,12 @@
|
|||
})
|
||||
}
|
||||
pageWithAttrsFunction()
|
||||
|
||||
//跳转详情页
|
||||
const detailFunction = (id) => {
|
||||
window.open(window.SITE_CONFIG.previewUrl + `#/details?id=${id}`)
|
||||
}
|
||||
|
||||
const changeDeptType = (str) => {
|
||||
if (str) {
|
||||
if (algorithmclassDom) {
|
||||
|
@ -145,6 +151,7 @@
|
|||
selectFlag.value = false
|
||||
getData(str)
|
||||
}
|
||||
|
||||
const getData = (str) => {
|
||||
getGisByArea(params).then((res) => {
|
||||
const resData = res.data.data || {}
|
||||
|
@ -169,6 +176,7 @@
|
|||
})
|
||||
})
|
||||
}
|
||||
|
||||
const layerFunction = (e) => {
|
||||
var scrollTop = e.currentTarget.scrollTop
|
||||
var windowHeight = e.currentTarget.clientHeight
|
||||
|
@ -202,6 +210,7 @@
|
|||
algorithmclassDom.removeEventListener('scroll', layerFunction, true)
|
||||
})
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
.algorithm {
|
||||
.select {
|
||||
|
@ -210,6 +219,7 @@
|
|||
font-size: 0.2rem;
|
||||
font-family: webfont;
|
||||
position: relative;
|
||||
|
||||
.top {
|
||||
cursor: pointer;
|
||||
width: 3.61rem;
|
||||
|
@ -220,6 +230,7 @@
|
|||
background: url('~@/assets/capacitySquare/select-bg.png') no-repeat;
|
||||
background-size: 100%;
|
||||
position: relative;
|
||||
|
||||
.light {
|
||||
width: 0.56rem;
|
||||
height: 3px;
|
||||
|
@ -231,6 +242,7 @@
|
|||
background-size: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
.bottom {
|
||||
cursor: pointer;
|
||||
position: absolute;
|
||||
|
@ -239,6 +251,7 @@
|
|||
z-index: 1000;
|
||||
background: rgba(57, 134, 239, 0.68);
|
||||
border: 1px solid #aed5ff;
|
||||
|
||||
.light {
|
||||
display: inline-block;
|
||||
width: 2.39rem;
|
||||
|
@ -250,6 +263,7 @@
|
|||
no-repeat;
|
||||
background-size: 100%;
|
||||
}
|
||||
|
||||
& > div {
|
||||
width: 1.8rem;
|
||||
height: 0.4rem;
|
||||
|
@ -257,11 +271,13 @@
|
|||
text-align: center;
|
||||
border-top: 1px solid #aed5ff;
|
||||
}
|
||||
|
||||
& > div:nth-of-type(1) {
|
||||
border: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.algorithm-class {
|
||||
// margin-top: 0.6rem;
|
||||
margin-bottom: 0.18rem;
|
||||
|
@ -271,6 +287,7 @@
|
|||
overflow: auto;
|
||||
margin-left: 1.15rem;
|
||||
margin-right: 0.15rem;
|
||||
|
||||
.algorithm-card {
|
||||
height: 2.75rem;
|
||||
width: 5.23rem;
|
||||
|
@ -279,6 +296,7 @@
|
|||
margin-bottom: 0.4rem;
|
||||
margin-right: 0.65rem;
|
||||
position: relative;
|
||||
|
||||
:deep(.ant-image) {
|
||||
img {
|
||||
margin-top: 0.15rem;
|
||||
|
@ -287,6 +305,7 @@
|
|||
margin-left: 0.1rem;
|
||||
}
|
||||
}
|
||||
|
||||
.algorithm-card-photo {
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
|
@ -294,6 +313,7 @@
|
|||
no-repeat;
|
||||
background-size: 100%;
|
||||
}
|
||||
|
||||
.algorithm-card-title {
|
||||
position: absolute;
|
||||
height: 0.6rem;
|
||||
|
@ -310,6 +330,7 @@
|
|||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
|
||||
span {
|
||||
line-height: 0.24rem;
|
||||
overflow: hidden;
|
||||
|
@ -317,20 +338,24 @@
|
|||
white-space: nowrap;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
span:last-child {
|
||||
font-size: 0.14rem;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.algorithm-class::-webkit-scrollbar-track-piece {
|
||||
background: #a5bcdb;
|
||||
border-radius: 0.08rem;
|
||||
}
|
||||
|
||||
.algorithm-class::-webkit-scrollbar-thumb {
|
||||
height: 3.2rem;
|
||||
background: linear-gradient(to bottom, #47d7f5, #3dc6e3);
|
||||
}
|
||||
|
||||
.algorithm-class::-webkit-scrollbar {
|
||||
height: 8.8rem;
|
||||
width: 0.08rem;
|
||||
|
|
|
@ -9,38 +9,83 @@
|
|||
<div class="form-container">
|
||||
<div v-if="applySuccess">
|
||||
<div class="title">申请人信息</div>
|
||||
<a-form ref="formRef" :model="formName" name="basic" :label-col="{ style: { width: '106px' } }"
|
||||
:wrapper-col="{ style: { width: '230px' } }" labelAlign="left" autocomplete="off">
|
||||
<a-form
|
||||
ref="formRef"
|
||||
:model="formName"
|
||||
name="basic"
|
||||
:label-col="{ style: { width: '106px' } }"
|
||||
:wrapper-col="{ style: { width: '230px' } }"
|
||||
labelAlign="left"
|
||||
autocomplete="off"
|
||||
>
|
||||
<div class="base-info">
|
||||
<a-form-item label="申请人" name="applyUserName" :rules="[{ required: true, message: '请输入申请人' }]">
|
||||
<a-input placeholder="请输入申请人" v-model:value="formName.applyUserName" />
|
||||
<a-form-item
|
||||
label="申请人"
|
||||
name="applyUserName"
|
||||
:rules="[{ required: true, message: '请输入申请人' }]"
|
||||
>
|
||||
<a-input
|
||||
placeholder="请输入申请人"
|
||||
v-model:value="formName.applyUserName"
|
||||
/>
|
||||
</a-form-item>
|
||||
|
||||
<a-form-item style="margin: 0 22px" label="申请人电话" name="applyUserPhone" :rules="[
|
||||
<a-form-item
|
||||
style="margin: 0 22px"
|
||||
label="申请人电话"
|
||||
name="applyUserPhone"
|
||||
:rules="[
|
||||
{
|
||||
required: true,
|
||||
pattern: /^1[3456789]\d{9}$/,
|
||||
message: '请输入正确的电话号码',
|
||||
},
|
||||
]">
|
||||
<a-input placeholder="请输入申请人电话" v-model:value="formName.applyUserPhone" />
|
||||
]"
|
||||
>
|
||||
<a-input
|
||||
placeholder="请输入申请人电话"
|
||||
v-model:value="formName.applyUserPhone"
|
||||
/>
|
||||
</a-form-item>
|
||||
|
||||
<a-form-item label="申请单位" name="applyUserDeptName" :rules="[{ required: true, message: '请输入申请单位' }]">
|
||||
<a-input placeholder="请输入申请单位" v-model:value="formName.applyUserDeptName" />
|
||||
<a-form-item
|
||||
label="申请单位"
|
||||
name="applyUserDeptName"
|
||||
:rules="[{ required: true, message: '请输入申请单位' }]"
|
||||
>
|
||||
<a-input
|
||||
placeholder="请输入申请单位"
|
||||
v-model:value="formName.applyUserDeptName"
|
||||
/>
|
||||
</a-form-item>
|
||||
</div>
|
||||
|
||||
<div class="title">需求信息</div>
|
||||
|
||||
<a-form-item style="margin-bottom: 10px" label="需求标题" name="demandSubject"
|
||||
:rules="[{ required: true, message: '请输入需求标题' }]">
|
||||
<a-input style="width: 350px" v-model:value="formName.demandSubject" />
|
||||
<a-form-item
|
||||
style="margin-bottom: 10px"
|
||||
label="需求标题"
|
||||
name="demandSubject"
|
||||
:rules="[{ required: true, message: '请输入需求标题' }]"
|
||||
>
|
||||
<a-input
|
||||
style="width: 350px"
|
||||
v-model:value="formName.demandSubject"
|
||||
/>
|
||||
</a-form-item>
|
||||
|
||||
<a-form-item style="margin-bottom: 10px" label="需求类型" name="detailsType"
|
||||
:rules="[{ required: true, message: '请选择需求类型' }]">
|
||||
<a-select ref="select" v-model:value="formName.detailsType" @focus="focus" style="width: 200px">
|
||||
<a-form-item
|
||||
style="margin-bottom: 10px"
|
||||
label="需求类型"
|
||||
name="detailsType"
|
||||
:rules="[{ required: true, message: '请选择需求类型' }]"
|
||||
>
|
||||
<a-select
|
||||
ref="select"
|
||||
v-model:value="formName.detailsType"
|
||||
@focus="focus"
|
||||
style="width: 200px"
|
||||
>
|
||||
<a-select-option value="基础设施">基础设施</a-select-option>
|
||||
<a-select-option value="数据资源">数据资源</a-select-option>
|
||||
<a-select-option value="组件服务">组件服务</a-select-option>
|
||||
|
@ -49,24 +94,50 @@
|
|||
</a-select>
|
||||
</a-form-item>
|
||||
|
||||
<a-form-item label="应用领域" v-if="formName.detailsType === '应用资源' ||
|
||||
formName.detailsType === '组件服务'" name="detailsField" style="width: 6.93rem" :rules="[
|
||||
<a-form-item
|
||||
label="应用领域"
|
||||
name="detailsField"
|
||||
style="width: 6.93rem"
|
||||
:rules="[
|
||||
{
|
||||
required: true,
|
||||
required:
|
||||
formName.detailsType === '应用资源' ||
|
||||
formName.detailsType === '组件服务'
|
||||
? true
|
||||
: false,
|
||||
message: '请选择应用领域',
|
||||
},
|
||||
]">
|
||||
<a-select v-model:value="formName.detailsField" :options="applicationSceneOpthion" mode="tags"
|
||||
:size="size" placeholder="请选择应用领域" :filterOption="false" :searchValue="false" style="width: 5.87rem">
|
||||
</a-select>
|
||||
]"
|
||||
>
|
||||
<a-select
|
||||
:disabled="
|
||||
formName.detailsType === '应用资源' ||
|
||||
formName.detailsType === '组件服务'
|
||||
? false
|
||||
: true
|
||||
"
|
||||
v-model:value="formName.detailsField"
|
||||
:options="applicationSceneOpthion"
|
||||
mode="tags"
|
||||
:size="size"
|
||||
placeholder="请选择应用领域"
|
||||
:filterOption="false"
|
||||
:searchValue="false"
|
||||
style="width: 5.87rem"
|
||||
></a-select>
|
||||
</a-form-item>
|
||||
<!-- <a-form-item label="应用领域" name="detailsField" style="width: 350px"
|
||||
:rules="[{ required: true, message: '请输入应用领域' }]">
|
||||
<a-input placeholder="请输入应用领域" v-model:value="formName.detailsField" />
|
||||
</a-form-item> -->
|
||||
<a-form-item style="margin-bottom: 10px" label="需求描述" name="demandDetails"
|
||||
:rules="[{ required: true, message: '请输入需求描述' }]">
|
||||
<a-textarea style="
|
||||
<a-form-item
|
||||
style="margin-bottom: 10px"
|
||||
label="需求描述"
|
||||
name="demandDetails"
|
||||
:rules="[{ required: true, message: '请输入需求描述' }]"
|
||||
>
|
||||
<a-textarea
|
||||
style="
|
||||
width: 500px;
|
||||
height: 150px;
|
||||
font-size: 16px;
|
||||
|
@ -76,12 +147,25 @@
|
|||
border-radius: 6px;
|
||||
padding: 10px;
|
||||
resize: none;
|
||||
" v-model:value="formName.demandDetails" />
|
||||
"
|
||||
v-model:value="formName.demandDetails"
|
||||
/>
|
||||
</a-form-item>
|
||||
<a-form-item style="color: #666; font-size: 16px" label="附件上传" name="applyDoc">
|
||||
<a-upload v-model:file-list="fileList" name="file" :action="upLoadUrl" :headers="headers"
|
||||
@change="handleChange" :maxCount="1">
|
||||
<a-button style="
|
||||
<a-form-item
|
||||
style="color: #666; font-size: 16px"
|
||||
label="附件上传"
|
||||
name="applyDoc"
|
||||
>
|
||||
<a-upload
|
||||
v-model:file-list="fileList"
|
||||
name="file"
|
||||
:action="upLoadUrl"
|
||||
:headers="headers"
|
||||
@change="handleChange"
|
||||
:maxCount="1"
|
||||
>
|
||||
<a-button
|
||||
style="
|
||||
width: 100px;
|
||||
height: 30px;
|
||||
margin-right: 10px;
|
||||
|
@ -92,7 +176,8 @@
|
|||
border: 1px solid #bbd3ef;
|
||||
padding: 0;
|
||||
text-align: center;
|
||||
">
|
||||
"
|
||||
>
|
||||
<upload-outlined></upload-outlined>
|
||||
文件上传
|
||||
</a-button>
|
||||
|
@ -103,7 +188,8 @@
|
|||
</a-form-item>
|
||||
|
||||
<a-form-item :wrapper-col="{ offset: 8, span: 16 }">
|
||||
<a-button style="
|
||||
<a-button
|
||||
style="
|
||||
width: 80px;
|
||||
height: 38px;
|
||||
margin-right: 20px;
|
||||
|
@ -114,10 +200,15 @@
|
|||
border: none;
|
||||
padding: 0;
|
||||
text-align: center;
|
||||
" type="primary" html-type="cancle" @click="signOut">
|
||||
"
|
||||
type="primary"
|
||||
html-type="cancle"
|
||||
@click="signOut"
|
||||
>
|
||||
退出申请
|
||||
</a-button>
|
||||
<a-button style="
|
||||
<a-button
|
||||
style="
|
||||
width: 80px;
|
||||
height: 38px;
|
||||
background: #0087ff;
|
||||
|
@ -127,7 +218,11 @@
|
|||
border: none;
|
||||
padding: 0;
|
||||
text-align: center;
|
||||
" type="primary" html-type="submit" @click="processStartHandle()">
|
||||
"
|
||||
type="primary"
|
||||
html-type="submit"
|
||||
@click="processStartHandle()"
|
||||
>
|
||||
提交申请
|
||||
</a-button>
|
||||
</a-form-item>
|
||||
|
@ -150,21 +245,21 @@
|
|||
</template>
|
||||
|
||||
<script>
|
||||
import HomeHeader from '@/views/home/components/header'
|
||||
import { reactive, ref } from 'vue'
|
||||
import { message } from 'ant-design-vue'
|
||||
// import { UploadOutlined } from '@ant-design/icons-vue'
|
||||
import { getUser, getUserInfo, relaunch } from '@/api/home'
|
||||
import {
|
||||
import HomeHeader from '@/views/home/components/header'
|
||||
import { reactive, ref } from 'vue'
|
||||
import { message } from 'ant-design-vue'
|
||||
// import { UploadOutlined } from '@ant-design/icons-vue'
|
||||
import { getUser, getUserInfo, relaunch } from '@/api/home'
|
||||
import {
|
||||
demandApply,
|
||||
getDemandForm,
|
||||
updateDemandForm,
|
||||
getCategoryTreePage,
|
||||
} from '@/api/personalCenter'
|
||||
// import { baseURL } from '@/config'
|
||||
import { useRouter } from 'vue-router'
|
||||
} from '@/api/personalCenter'
|
||||
// import { baseURL } from '@/config'
|
||||
import { useRouter } from 'vue-router'
|
||||
|
||||
export default {
|
||||
export default {
|
||||
name: '',
|
||||
props: {},
|
||||
components: {
|
||||
|
@ -250,21 +345,19 @@ export default {
|
|||
}
|
||||
|
||||
const fileList = ref([])
|
||||
const subimtFlag = ref(true)
|
||||
const processStartHandle = () => {
|
||||
let detailsField = '';
|
||||
if (formName.detailsField.length > 0) {
|
||||
let detailsField = ''
|
||||
formName.detailsField.map((item) => {
|
||||
detailsField += item + ';'
|
||||
})
|
||||
formName.detailsField = detailsField
|
||||
}
|
||||
// copy传参
|
||||
let _postData = JSON.parse(JSON.stringify(formName))
|
||||
_postData.detailsField = detailsField;
|
||||
|
||||
if (id.value) {
|
||||
updateDemandForm(_postData).then((upres) => {
|
||||
updateDemandForm(formName).then((upres) => {
|
||||
if (upres.data.code == 0) {
|
||||
relaunch({ data: _postData, taskId: taskId.value }).then((res) => {
|
||||
relaunch({ data: formName, taskId: taskId.value }).then((res) => {
|
||||
console.log('驳回================>', res)
|
||||
if (res.data.code == 0) {
|
||||
message.success('重新发起流程成功!')
|
||||
|
@ -280,18 +373,22 @@ export default {
|
|||
}
|
||||
})
|
||||
} else {
|
||||
formRef.value.validate().then((valid) => {
|
||||
const detString = String(_postData.detailsField)
|
||||
_postData.detailsField = detString
|
||||
console.log(detString, _postData.detailsField, 'detString')
|
||||
demandApply(_postData).then((res) => {
|
||||
if (subimtFlag.value) {
|
||||
subimtFlag.value = false
|
||||
formRef.value.validate().then(() => {
|
||||
const detString = String(formName.detailsField)
|
||||
formName.detailsField = detString
|
||||
console.log(detString, formName.detailsField, 'detString')
|
||||
demandApply(formName).then((res) => {
|
||||
applySuccess.value = false
|
||||
message.success('操作成功!')
|
||||
console.log('能力申请================>', res)
|
||||
subimtFlag.value = true
|
||||
})
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return {
|
||||
formRef,
|
||||
|
@ -310,11 +407,11 @@ export default {
|
|||
applicationSceneOpthion,
|
||||
}
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang="less">
|
||||
#apply-container {
|
||||
#apply-container {
|
||||
background-color: #f5f8fc;
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
|
@ -387,11 +484,11 @@ export default {
|
|||
font-weight: bold;
|
||||
color: #000;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
<style>
|
||||
body,
|
||||
html {
|
||||
body,
|
||||
html {
|
||||
height: unset;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
|
Loading…
Reference in New Issue