Commit 86384606 authored by 黄奎's avatar 黄奎

页面修改

parent 554c3ff7
...@@ -58,6 +58,17 @@ export function deleteSupplier(data) { ...@@ -58,6 +58,17 @@ export function deleteSupplier(data) {
} }
/**
* 获取留学就业产品类型列表
*/
export function queryStudyAbroadProductType(data) {
return request({
url: '/StudyAbroad/GetProductTypeList',
method: 'post',
data
})
}
/** /**
* 获取留学就业分页列表 * 获取留学就业分页列表
*/ */
......
...@@ -9,24 +9,29 @@ ...@@ -9,24 +9,29 @@
<div class="row wrap"> <div class="row wrap">
<q-input filled stack-label maxlength="30" :dense="false" v-model="objOption.Name" ref="Name" <q-input filled stack-label maxlength="30" :dense="false" v-model="objOption.Name" ref="Name"
class="col-6 q-pr-lg q-pb-lg" label="项目名称" :rules="[val => !!val || '项目名称']" /> class="col-6 q-pr-lg q-pb-lg" label="项目名称" :rules="[val => !!val || '项目名称']" />
<q-select filled stack-label option-value="Id" option-label="Name" v-model="objOption.SupplierId" ref="SupplierId" <q-select filled stack-label option-value="Id" option-label="Name" v-model="objOption.SupplierId"
:options="supplierList" label="供应商" :dense="false" :rules="[val => !!val || '请选择供应商']" class="col-6 q-pb-lg" emit-value map-options /> ref="SupplierId" :options="supplierList" label="供应商" :dense="false" :rules="[val => !!val || '请选择供应商']"
class="col-6 q-pb-lg" emit-value map-options />
</div> </div>
<div class="row wrap"> <div class="row wrap">
<div class="col-6"> <div class="col-6">
<q-select filled stack-label option-value="SId" option-label="SName" v-model="objOption.School_Id" <q-select filled stack-label option-value="SId" option-label="SName" v-model="objOption.School_Id"
ref="School_Id" :options="SchoolList" label="所属校区" :dense="false" class="col-6 q-pr-lg q-pb-lg" emit-value ref="School_Id" :options="SchoolList" label="所属校区" :dense="false" class="col-6 q-pr-lg q-pb-lg" emit-value
map-options /> map-options />
<div class="col-6">
<a v-if="objOption.SupplierContract&&isHaveViewContractAction" <a v-if="objOption.SupplierContract&&isHaveViewContractAction"
style="margin-left:10px;color:#2961FE;text-decoration:none;" :href="objOption.SupplierContract">查看合同</a> style="margin-left:10px;color:#2961FE;text-decoration:none;" :href="objOption.SupplierContract">查看合同</a>
</div> </div>
<div class="col-6">
<q-select filled stack-label option-value="Id" option-label="Name" v-model="objOption.ProductType"
ref="ProductType" :options="productList" label="产品类型" :dense="false" class="col-6 q-pb-lg" emit-value
map-options />
</div> </div>
</div> </div>
<div class="row wrap"> <div class="row wrap">
<div class="col-6 q-pb-lg q-pr-lg"> <div class="col-6 q-pb-lg q-pr-lg">
<q-uploader :style="{ backgroundImage: 'url(' + objOption.ImgCover + ')' }" style="width:auto;height:200px;background-repeat:no-repeat;background-size:cover;" flat <q-uploader :style="{ backgroundImage: 'url(' + objOption.ImgCover + ')' }"
hide-upload-btn max-files="1" label="封面图" accept=".jpg, image/*" :factory="uploadFile" auto-upload> style="width:auto;height:200px;background-repeat:no-repeat;background-size:cover;" flat hide-upload-btn
max-files="1" label="封面图" accept=".jpg, image/*" :factory="uploadFile" auto-upload>
</q-uploader> </q-uploader>
</div> </div>
</div> </div>
...@@ -51,7 +56,8 @@ ...@@ -51,7 +56,8 @@
import { import {
saveStudyAbroad, saveStudyAbroad,
queryStudyAbroadInfo, queryStudyAbroadInfo,
querySupplierList querySupplierList,
queryStudyAbroadProductType
} from '../../api/studyabroad/index' } from '../../api/studyabroad/index'
import { import {
UploadSelfFile UploadSelfFile
...@@ -84,12 +90,14 @@ ...@@ -84,12 +90,14 @@
SupplierContract: '', //供应商合同 SupplierContract: '', //供应商合同
Remark: '', //备注 Remark: '', //备注
School_Id: -1, //所属校区 School_Id: -1, //所属校区
ImgCover:'', //封面图 ImgCover: '', //封面图
ProductType: 1, //产品类型
}, },
optionTitle: "", optionTitle: "",
saveLoading: false, saveLoading: false,
supplierList: [], //供应商下拉数据 supplierList: [], //供应商下拉数据
uploadMultple: true, uploadMultple: true,
productList: [], //产品类型
fileObj: { fileObj: {
FileName: '', FileName: '',
FileUrl: '' FileUrl: ''
...@@ -113,13 +121,22 @@ ...@@ -113,13 +121,22 @@
} }
}), }),
created() { created() {
this.getSchool() this.getSchool();
this.getProductList();
}, },
mounted() { mounted() {
this.getStudyAbroadList(); this.getStudyAbroadList();
this.initObj() this.initObj()
}, },
methods: { methods: {
//获取产品类型列表
getProductList() {
queryStudyAbroadProductType({}).then(res => {
if (res.Code == 1) {
this.productList = res.Data
}
})
},
uploadFile(files) { uploadFile(files) {
UploadSelfFile("course", files[0], res => { UploadSelfFile("course", files[0], res => {
if (res.Code == 1) { if (res.Code == 1) {
...@@ -157,6 +174,7 @@ ...@@ -157,6 +174,7 @@
this.objOption.Remark = tempObj.Remark; this.objOption.Remark = tempObj.Remark;
this.objOption.School_Id = tempObj.School_Id; this.objOption.School_Id = tempObj.School_Id;
this.objOption.ImgCover = tempObj.ImgCover; this.objOption.ImgCover = tempObj.ImgCover;
this.objOption.ProductType = tempObj.ProductType;
} }
} }
}) })
...@@ -168,6 +186,7 @@ ...@@ -168,6 +186,7 @@
this.objOption.SupplierContract = ''; this.objOption.SupplierContract = '';
this.objOption.Remark = ''; this.objOption.Remark = '';
this.objOption.School_Id = -1; this.objOption.School_Id = -1;
this.objOption.ProductType = 1;
} }
}, },
//关闭弹窗 //关闭弹窗
...@@ -187,7 +206,7 @@ ...@@ -187,7 +206,7 @@
// } // }
this.$refs.Name.validate(); this.$refs.Name.validate();
this.$refs.SupplierId.validate(); this.$refs.SupplierId.validate();
if (!this.$refs.Name.hasError&&!this.$refs.SupplierId.hasError) { if (!this.$refs.Name.hasError && !this.$refs.SupplierId.hasError) {
this.saveLoading = true; this.saveLoading = true;
saveStudyAbroad(this.objOption).then(res => { saveStudyAbroad(this.objOption).then(res => {
this.saveLoading = false this.saveLoading = false
...@@ -228,5 +247,4 @@ ...@@ -228,5 +247,4 @@
}, },
} }
} }
</script> </script>
\ No newline at end of file
...@@ -32,6 +32,9 @@ ...@@ -32,6 +32,9 @@
:icon="props.row.expand ? 'remove' : 'add'" /> :icon="props.row.expand ? 'remove' : 'add'" />
</q-td> </q-td>
<template v-for="col in props.cols"> <template v-for="col in props.cols">
<q-td v-if="col.name == 'ProductTypeName'" style="width:100px;">
{{col.value}}
</q-td>
<q-td v-if="col.name == 'Name'" style="width:200px;"> <q-td v-if="col.name == 'Name'" style="width:200px;">
{{col.value}} {{col.value}}
</q-td> </q-td>
...@@ -255,11 +258,17 @@ ...@@ -255,11 +258,17 @@
}, },
dataList: [], dataList: [],
loading: true, loading: true,
columns: [{ columns: [ {
name: 'Remark', name: 'Remark',
label: '备注', label: '备注',
field: 'Remark', field: 'Remark',
align: 'left' align: 'left'
},
{
name: 'ProductTypeName',
label: '类型',
field: 'ProductTypeName',
align: 'left'
}, },
{ {
name: 'Name', name: 'Name',
...@@ -338,7 +347,7 @@ ...@@ -338,7 +347,7 @@
'Remark', 'Name', 'SchoolName', 'SuggestPrice', 'SellPrice', "PreferentialList", 'Remark', 'Name', 'SchoolName', 'SuggestPrice', 'SellPrice', "PreferentialList",
"PreferentialListSellCommission", "PreferentialListSellCommission",
"PreferentialListB2BCommission", "PreferentialListB2BCommission",
"EducationCommission", 'SaleStateName', 'Id', 'SupplierName', "EducationCommission", 'SaleStateName', 'Id', 'SupplierName','ProductTypeName',
], //可见列 ], //可见列
PageCount: 0, PageCount: 0,
isShowStudy: false, //是否显示留学弹窗 isShowStudy: false, //是否显示留学弹窗
......
...@@ -32,6 +32,9 @@ ...@@ -32,6 +32,9 @@
:icon="props.row.expand ? 'remove' : 'add'" /> :icon="props.row.expand ? 'remove' : 'add'" />
</q-td> </q-td>
<template v-for="col in props.cols"> <template v-for="col in props.cols">
<q-td v-if="col.name == 'ProductTypeName'" style="width:100px;">
{{col.value}}
</q-td>
<q-td v-if="col.name == 'Name'" style="width:200px;"> <q-td v-if="col.name == 'Name'" style="width:200px;">
{{col.value}} {{col.value}}
</q-td> </q-td>
...@@ -256,11 +259,18 @@ ...@@ -256,11 +259,18 @@
}, },
dataList: [], dataList: [],
loading: true, loading: true,
columns: [{ columns: [
{
name: 'Remark', name: 'Remark',
label: '备注', label: '备注',
field: 'Remark', field: 'Remark',
align: 'left' align: 'left'
},
{
name: 'ProductTypeName',
label: '类型',
field: 'ProductTypeName',
align: 'left'
}, },
{ {
name: 'Name', name: 'Name',
...@@ -339,7 +349,7 @@ ...@@ -339,7 +349,7 @@
'Remark', 'Name', 'SchoolName', 'SuggestPrice', 'SellPrice', "PreferentialList", 'Remark', 'Name', 'SchoolName', 'SuggestPrice', 'SellPrice', "PreferentialList",
"PreferentialListSellCommission", "PreferentialListSellCommission",
"PreferentialListB2BCommission", "PreferentialListB2BCommission",
"EducationCommission", 'SaleStateName', 'Id', 'SupplierName', "EducationCommission", 'SaleStateName', 'Id', 'SupplierName','ProductTypeName'
], //可见列 ], //可见列
PageCount: 0, PageCount: 0,
isShowStudy: false, //是否显示留学弹窗 isShowStudy: false, //是否显示留学弹窗
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment