Browse Source

Merge branch 'dev' of http://47.108.105.48:3000/java_project/logpm_page into dev

fix_bug_pro20231227
pref_mail@163.com 2 years ago
parent
commit
3d774e424f
  1. 14
      src/api/distribution/distributionSignfor.js
  2. 57
      src/api/system/pdaversionManage.js
  3. 133
      src/option/system/padversionManage1.js
  4. 120
      src/option/system/pdaversionManage.js
  5. 1
      src/utils/store.js
  6. 1210
      src/views/basicdata/warehouse/tray/basicdataTrayedt.vue
  7. 1356
      src/views/basicdata/warehouse/tray/basicdataTrayhistory.vue
  8. 135
      src/views/distribution/deliverylist/distributionDeliveryListedt.vue
  9. 16
      src/views/distribution/inventory/distrilbutionBillLading.vue
  10. 5
      src/views/distribution/reservation/atlas.vue
  11. 4
      src/views/distribution/reservation/atlas1.vue
  12. 18
      src/views/distribution/reservation/reservationAddFrom.vue
  13. 204
      src/views/distribution/signfor/distributionSignforedt.vue
  14. 7
      src/views/distribution/stockup/distributionStockupDetails.vue
  15. 1413
      src/views/distribution/stockup/distributionStockupDetailsSelf.vue
  16. 601
      src/views/system/pdaversion/pdaversionManage.vue
  17. 1
      vite.config.js

14
src/api/distribution/distributionSignfor.js

@ -106,6 +106,20 @@ export const signforPackageList = (signforId) => {
}
})
}
/**
* 查询签收库存品信息
* @param signforId
* @returns {AxiosPromise}
*/
export const signforInventoryList = (signforId) => {
return request({
url: '/api/logpm-distribution/signfor/signforInventoryList',
method: 'get',
params: {
signforId
}
})
}
export const getLocationAddress = (signforId) => {

57
src/api/system/pdaversionManage.js

@ -0,0 +1,57 @@
import request from '@/axios';
export const getList = (current, size, params) => {
return request({
url: '/blade-system/pdaversionManage/list',
method: 'get',
params: {
...params,
current,
size,
}
})
}
export const getDetail = (id) => {
return request({
url: '/blade-system/pdaversionManage/detail',
method: 'get',
params: {
id
}
})
}
export const remove = (ids) => {
return request({
url: '/blade-system/pdaversionManage/remove',
method: 'post',
params: {
ids,
}
})
}
export const add = (row) => {
return request({
url: '/blade-system/pdaversionManage/save',
method: 'post',
data: row
})
}
export const update = (row) => {
return request({
url: '/blade-system/pdaversionManage/update',
method: 'post',
data: row
})
}
export const tenantpage = (row) => {
return request({
url: '/blade-system/tenant/pageown',
method: 'get',
data: row
})
}

133
src/option/system/padversionManage1.js

@ -0,0 +1,133 @@
export default {
height:'auto',
calcHeight: 30,
tip: false,
searchShow: true,
searchMenuSpan: 6,
border: true,
index: true,
// viewBtn: false,
// editBtn: false,
// addBtn:false,
selection: true,
cellBtn:false,
indexLabel:'序号',
indexWidth:'80',
dialogClickModal: false,
column: [
{
label: "ID",
prop: "id",
display: false,
hide: true,
},
{
label: "租户号",
prop: "tenantId",
display: false,
hide: true,
},
{
label: "创建人",
prop: "createUser",
display: false,
hide: true,
},
{
label: "创建时间",
prop: "createTime",
display: false,
hide: true,
},
{
label: "更新人",
prop: "updateUser",
display: false,
hide: true,
},
{
label: "更新时间",
prop: "updateTime",
display: false,
hide: true,
},
{
label: "是否已删除",
prop: "isDeleted",
display: false,
hide: true,
},
{
label: "状态",
prop: "status",
display: false,
hide: true,
},
{
label: "创建部门",
prop: "createDept",
display: false,
hide: true,
},
{
label: "预留1",
prop: "reserve1",
display: false,
hide: true,
},
{
label: "预留2",
prop: "reserve2",
display: false,
hide: true,
},
{
label: "预留3",
prop: "reserve3",
display: false,
hide: true,
},
{
label: "预留4",
prop: "reserve4",
display: false,
hide: true,
},
{
label: "预留5",
prop: "reserve5",
display: false,
hide: true,
},
{
label: "版本名称",
prop: "versionName",
},
// {
// label: "版本code",
// prop: "versionCode",
// },
{
label: "预发布时间",
prop: "releaseTime",
},
{
label: "包链接",
prop: "link",
},
{
label: "预计更新时间(分)",
prop: "expectTime",
},
{
label: "是否强制更新(1-否,2-是)",
prop: "isUpdates",
},
{
label: "备注",
prop: "node",
},
]
}

120
src/option/system/pdaversionManage.js

@ -0,0 +1,120 @@
export default {
expand: false,
index: true,
border: true,
selection: true,
column: [
{
label: "ID",
prop: "id",
display: false,
hide: true,
},
{
label: "租户号",
prop: "tenantId",
display: false,
hide: true,
},
{
label: "创建人",
prop: "createUser",
display: false,
hide: true,
},
{
label: "创建时间",
prop: "createTime",
display: false,
hide: true,
},
{
label: "更新人",
prop: "updateUser",
display: false,
hide: true,
},
{
label: "更新时间",
prop: "updateTime",
display: false,
hide: true,
},
{
label: "是否已删除",
prop: "isDeleted",
display: false,
hide: true,
},
{
label: "状态",
prop: "status",
display: false,
hide: true,
},
{
label: "创建部门",
prop: "createDept",
display: false,
hide: true,
},
{
label: "预留1",
prop: "reserve1",
display: false,
hide: true,
},
{
label: "预留2",
prop: "reserve2",
display: false,
hide: true,
},
{
label: "预留3",
prop: "reserve3",
display: false,
hide: true,
},
{
label: "预留4",
prop: "reserve4",
display: false,
hide: true,
},
{
label: "预留5",
prop: "reserve5",
display: false,
hide: true,
},
{
label: "备注",
prop: "node",
},
{
label: "版本名称",
prop: "versionName",
},
{
label: "版本code",
prop: "versionCode",
},
{
label: "预发布时间",
prop: "releaseTime",
},
{
label: "包链接",
prop: "link",
},
{
label: "预计更新时间(分)",
prop: "expectTime",
},
{
label: "是否强制更新(1-否,2-是)",
prop: "isUpdates",
},
]
}

1
src/utils/store.js

@ -19,6 +19,7 @@ export const setStore = (params = {},value) => {
else window.localStorage.setItem(name, JSON.stringify(obj));
} catch (error) {
console.log(error, 'error', params, 'params')
return
var keys = [];
for (var i = 0; i < localStorage.length; i++) {
if(localStorage.key(i).indexOf('AMap')!=-1){

1210
src/views/basicdata/warehouse/tray/basicdataTrayedt.vue

File diff suppressed because it is too large Load Diff

1356
src/views/basicdata/warehouse/tray/basicdataTrayhistory.vue

File diff suppressed because it is too large Load Diff

135
src/views/distribution/deliverylist/distributionDeliveryListedt.vue

@ -236,6 +236,13 @@
@selection="selectionChange"
>
<template #default="slotProps">
<el-text
type="primary"
text
icon="el-icon-view"
@click="inventoryDetail(slotProps.scope.row)"
>查看详情
</el-text>
</template>
</tablecmt>
</el-tab-pane>
@ -1232,8 +1239,8 @@ export default {
head: false,
},
{
prop: 'deliveryNumber',
label: '备货数',
prop: 'cargoNumber',
label: '物料编号',
type: 2,
values: '',
width: '150',
@ -1243,25 +1250,124 @@ export default {
head: false,
},
{
prop: 'readyStock',
label: '已备数量',
prop: 'cargoNorms',
label: '物料规格',
type: 2,
values: '',
width: '180',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'readyStock',
label: '签收数量',
prop: 'cargoUnit',
label: '物料单位',
type: 2,
values: '',
width: '180',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'loadingStatusName',
label: '装车状态',
type: 2,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'reservationNum',
label: '计划出库数',
type: 2,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'loadedinNumber',
label: '实际出库数',
type: 2,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'signingStatusName',
label: '签收状态',
type: 2,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'signeeName',
label: '签收人',
type: 2,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'sjsigningTime',
label: '签收时间',
type: 2,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
// {
// prop: 'deliveryNumber',
// label: '',
// type: 2,
// values: '',
// width: '150',
// checkarr: [],
// fixed: false,
// sortable: true,
// head: false,
// },
// {
// prop: 'readyStock',
// label: '',
// type: 2,
// values: '',
// width: '180',
// checkarr: [],
// fixed: false,
// sortable: true,
// },
// {
// prop: 'readyStock',
// label: '',
// type: 2,
// values: '',
// width: '180',
// checkarr: [],
// fixed: false,
// sortable: true,
// },
{
prop: 'cargoNumber',
label: '物料编号',
@ -1325,6 +1431,16 @@ export default {
fixed: false,
sortable: true,
},
{
prop: '',
label: '操作',
type: 6,
values: '',
width: '200',
checkarr: [],
fixed: 'right',
hide: true,
},
],
height: 300,
//
@ -2433,6 +2549,9 @@ export default {
this.signform = row;
this.signBox = true;
},
inventoryDetail(row) {
console.log('一键签收>>>>>>>>>>', row);
},
handleOne(row) {
console.log('签收>>>>>>>>>>', row);
this.$confirm('确认一键装车?')

16
src/views/distribution/inventory/distrilbutionBillLading.vue

@ -1856,18 +1856,26 @@ export default {
return ;
}
let isa = false;
console.log('执行了');
// console.log('');
this.selectionListStock.some(i => {
console.log('asdgfasdv', i);
// console.log('', i);
if (parseInt(i.inventoryQuantity) > parseInt(i.quantityStock)) {
// this.$message.warning("");
isa = true;
return;
}
let a = this.data.filter(ele => ele.id == i.id).length >= 1;
// console.log("asdgfasdv",a);
// console.log("",a);
if (!a) {
// console.log("");
this.data.push(i);
}else if(a){
this.data.forEach( ii =>{
// console.log("",ii);
if(ii.id == i.id && parseInt(ii.inventoryQuantity)+parseInt(i.inventoryQuantity) < ii.quantityStock){
ii.inventoryQuantity = parseInt(ii.inventoryQuantity)+parseInt(i.inventoryQuantity);
}
});
}
});
@ -1877,7 +1885,7 @@ export default {
},
//
handleNumberRange(e, row) {
console.log('执行了2222', e, e.target.value, row);
// console.log('2222', e, e.target.value, row);
if (e.target.value) {
e.target.value = e.target.value.replace(/[^\.\d]/g, ''); //
if (e.target.value) {

5
src/views/distribution/reservation/atlas.vue

@ -66,9 +66,7 @@ export default {
onMounted(() => {
details.ids = router.currentRoute.value.query.id;
initMap(router.currentRoute.value.query.id);
setTimeout(() => {
init();
}, 1500);
init();
// setTimeout(()=>{
// details.mapLoc.clearOverlays();
@ -80,6 +78,7 @@ export default {
console.log('watch 已触发', newValue);
if (details.mapLoc) {
details.mapLoc.remove(details.markersarr);
details.markersarr=[]
}
details.reservationIds.map((item, index) => {
details.reservationData.map(ite => {

4
src/views/distribution/reservation/atlas1.vue

@ -70,9 +70,7 @@ watchEffect(() => {
})
details.drivingarrs=[]
details.datalists = [];
setTimeout(() => {
init(data);
}, 1000);
init(data);
});
// setTimeout(() => {
// init();

18
src/views/distribution/reservation/reservationAddFrom.vue

@ -1702,23 +1702,7 @@
},
mounted() {
this.init();
let arr = [];
this.option.columnParcels.map(item => {
if (!item.hide) {
arr.push({
prop: item.prop,
label: item.label,
type: 2,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false
});
}
});
console.log(JSON.stringify(arr));
this.onLoad(this.page);
this.getDictionary();
},

204
src/views/distribution/signfor/distributionSignforedt.vue

@ -257,42 +257,36 @@
</el-tab-pane>
<el-tab-pane label="库 存 品 列 表" name="tab3">
<!-- 列表模块 -->
<!-- <el-table ref="table" v-loading="loading"-->
<!-- @selection-change="selectionChange"-->
<!-- :data="packageData"-->
<!-- :height="height"-->
<!-- style="width: 100%"-->
<!-- :border="wrapoption.border"-->
<!-- >-->
<el-table ref="table" v-loading="loading"
@selection-change="selectionChange"
:data="inventoryData"
:height="height"
style="width: 100%"
:border="inventory.border"
>
<!-- align="center"-->center
<!-- <el-table-column type="expand" v-if="wrapoption.expand"></el-table-column>-->
<!-- <template v-for="(item,index) in wrapoption.column">-->
<!-- &lt;!&ndash; table字段 &ndash;&gt;-->
<!-- <el-table-column v-if="item.hide!==true"-->
<!-- :prop="item.prop"-->
<!-- :label="item.label"-->
<!-- :show-overflow-tooltip="true"-->
<!-- :width="item.width"-->
<!-- :key="index">-->
<!-- &lt;!&ndash; :align="center"&ndash;&gt;-->
<el-table-column type="expand" v-if="inventory.expand"></el-table-column>
<template v-for="(item,index) in inventory.column">
<!-- table字段 -->
<el-table-column v-if="item.hide!==true"
:prop="item.prop"
:label="item.label"
:show-overflow-tooltip="true"
:width="item.width"
:key="index">
<!-- :align="center"-->
</el-table-column>
</template>
<el-table-column prop="menu" label="操作" :width="220" align="center">
<template #="{row}">
<el-button type="primary" text icon="el-icon-view" @click="handleInventoryView(row)">查看详情</el-button>
</template>
</el-table-column>
</el-table>
<!-- </el-table-column>-->
<!-- </template>-->
<!-- </el-table>-->
<!-- <div class="avue-crud__pagination" style="width:100%">-->
<!-- &lt;!&ndash; 分页模块 &ndash;&gt;-->
<!-- <el-pagination align="right"-->
<!-- background-->
<!-- @size-change="psizeChange"-->
<!-- @current-change="pcurrentChange"-->
<!-- :current-page="packpage.currentPage"-->
<!-- :page-sizes="[30, 50,80, 120]"-->
<!-- :page-size="packpage.pageSize"-->
<!-- layout="total, sizes, prev, pager, next, jumper"-->
<!-- :total="packpage.total">-->
<!-- </el-pagination>-->
<!-- </div>-->
</el-tab-pane>
</el-tabs>
</div>
@ -300,7 +294,7 @@
</template>
<script>
import { getList, getDetail, add, update, remove ,getDetailById,getListOrder,signforPackageList} from '@/api/distribution/distributionSignfor';
import { getList, getDetail, add, update, remove ,getDetailById,getListOrder,signforPackageList,signforInventoryList} from '@/api/distribution/distributionSignfor';
import { mapGetters } from 'vuex';
import { getDictionaryBiz } from '@/api/system/dict';
@ -1080,6 +1074,137 @@ export default {
]
},
inventory: {
expand: false,
index: true,
border: true,
selection: true,
column: [
{
prop: 'sku',
label: 'SKU',
type: 2,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'descriptionGoods',
label: '物料名称',
type: 2,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'cargoNumber',
label: '物料编号',
type: 2,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'cargoNorms',
label: '物料规格',
type: 2,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'cargoUnit',
label: '物料单位',
type: 2,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'category',
label: '品分类',
type: 2,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'reservationNum',
label: '计划出库数',
type: 2,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'loadedinNumber',
label: '实际出库数',
type: 2,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'loadingStatusName',
label: '装车状态',
type: 2,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'signingStatusName',
label: '签收状态',
type: 2,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'signUser',
label: '签收人',
type: 2,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
]
},
//
data: [],
//
@ -1298,6 +1423,11 @@ export default {
getWrapdetail(row.id).then(res => {
console.log("查看>>>>>>>",res.data.data);
});
},
handleInventoryView(row) {
console.log("查看>>>>>>>>>>",row);
},
//
checkAddValue(scope) {
@ -1471,6 +1601,12 @@ export default {
// this.page.total = data.total
this.packageData =data
});
signforInventoryList(signforId).then(res => {
const data =res.data.data
console.log("------------>data",data);
// this.page.total = data.total
this.inventoryData =data
});
},
}
};

7
src/views/distribution/stockup/distributionStockupDetails.vue

@ -976,6 +976,7 @@ export default {
};
getPrintDetail(qr).then( res =>{
console.log(",./");
this.dialogVisible = true;
this.html=''
this.html=this.getHtmls(res.data.data.dataList,res.data.data.templateHtml)
})
@ -995,6 +996,7 @@ export default {
//
getPrintDetail(qr).then( res =>{
// console.log(",./");
this.dialogVisible = true;
this.html=''
this.html=this.getHtmls(res.data.data.dataList,res.data.data.templateHtml)
})
@ -1008,6 +1010,7 @@ export default {
row.type = "1";
getPrintDetail(row).then( res =>{
console.log(",./");
this.dialogVisible = true;
this.html=''
this.html=this.getHtmls(res.data.data.dataList,res.data.data.templateHtml)
})
@ -1029,11 +1032,14 @@ export default {
if(!!i){
let a = {};
a.sku = i.sku;
a.id = i.id;
a.orderCode = i.orderCode;
a.descriptionGoods = i.descriptionGoods;
a.cargoUnit = i.cargoUnit;
a.stockPackageCode = i.stockPackageCode;
a.brandName = i.brandName;
a.stockListId = i.stockListId;
a.reservationId = i.reservationId;
s.push(a);
}
});
@ -1480,6 +1486,7 @@ export default {
getDetailStockupOwn(this.$route.query.id).then(res => {
console.log("返回的值",res.data.data);
const data = res.data.data;
if(!data)return
this.data[0] = data;
const { serveType, deliveryWay, deliveryType } = this.data[0];
const serveTypes = !!serveType ? serveType.split(',') : null;

1413
src/views/distribution/stockup/distributionStockupDetailsSelf.vue

File diff suppressed because it is too large Load Diff

601
src/views/system/pdaversion/pdaversionManage.vue

@ -0,0 +1,601 @@
<template>
<basic-container>
<div class="avue-crud">
<el-row v-if="!search" style="padding: 6px 18px">
<!-- 查询模块 -->
<el-form :inline="true" :model="query">
<!-- 查询按钮 -->
<el-form-item>
<el-button type="primary" icon="el-icon-search" @click="searchChange"> </el-button>
<el-button icon="el-icon-delete" @click="searchReset()"> </el-button>
</el-form-item>
</el-form>
</el-row>
<el-row>
<div class="avue-crud__header">
<!-- 头部左侧按钮模块 -->
<div class="avue-crud__left">
<el-button type="primary" icon="el-icon-plus" @click="handleAdd"> </el-button>
<el-button type="danger" icon="el-icon-delete" @click="handleDelete" plain
> </el-button
>
</div>
<!-- 头部右侧按钮模块 -->
<div class="avue-crud__right">
<el-button icon="el-icon-refresh" @click="searchChange" circle></el-button>
<el-button icon="el-icon-search" @click="searchHide" circle></el-button>
</div>
</div>
</el-row>
<el-row>
<!-- 列表模块 -->
<tablecmt
:columnList="columnList"
:tableData="data"
:loading="loading"
@inputTxt="inputsc"
@timeCheck="timesc"
@btnCheck="btnsc"
@selectCheck="selectsc"
@selection="selectionChange"
>
<template #default="slotProps">
<el-text @click="handleView(slotProps.scope.row)">查看</el-text>
<el-text @click="handleEdit(slotProps.scope.row)">编辑</el-text>
<el-text @click="rowDel(slotProps.scope.row)">删除</el-text>
</template>
</tablecmt>
</el-row>
<el-row>
<div class="avue-crud__pagination" style="width: 100%">
<!-- 分页模块 -->
<el-pagination
align="right"
background
@size-change="sizeChange"
@current-change="currentChange"
:current-page="page.currentPage"
:page-sizes="[10, 20, 30, 40, 50, 100]"
:page-size="page.pageSize"
layout="total, sizes, prev, pager, next, jumper"
:total="page.total"
>
</el-pagination>
</div>
</el-row>
<!-- 表单模块 -->
<el-dialog
:title="title"
v-model="box"
width="50%"
:before-close="beforeClose"
append-to-body
>
<el-form :disabled="view" ref="form" :model="form" label-width="150px">
<!-- 表单字段 -->
<el-form-item label="版本名称" prop="versionName">
<el-input v-model="form.versionName" placeholder="请输入版本名称" />
</el-form-item>
<!-- <el-form-item label="版本code" prop="versionCode">
<el-input type="number" v-model="form.versionCode" placeholder="请输入版本code" />
</el-form-item> -->
<el-form-item label="预发布时间" prop="releaseTime">
<el-date-picker
v-model="form.releaseTime"
format="YYYY-MM-DD HH:mm:ss"
value-format="YYYY-MM-DD HH:mm:ss"
type="datetime"
placeholder="请选择预发布时间"
/>
</el-form-item>
<el-form-item label="安装包" prop="link">
<el-upload
multiple
class="upfilebox"
v-model:file-list="form.filelink"
:limit="1"
list-type="text"
drag
:action="action"
:headers="headers"
:auto-upload="true"
:on-remove="handleRemove"
>
上传文件
</el-upload>
</el-form-item>
<!-- <el-form-item label="预计更新时间(分)" prop="expectTime">
<el-input v-model="form.expectTime" placeholder="请输入预计更新时间(分)"/>
</el-form-item> -->
<el-form-item label="更新版本类型" prop="isUpdates">
<el-select v-model="form.versionType1" class="m-2" placeholder="请选择" size="large">
<el-option
v-for="(item, index) in ['开发版本', '测试版本', '正式版本']"
:key="item"
:label="item"
:value="item"
/>
</el-select>
</el-form-item>
<el-form-item label="是否强制更新" prop="isUpdates">
<el-select v-model="form.isUpdates1" class="m-2" placeholder="请选择" size="large">
<el-option
v-for="(item, index) in ['否', '是']"
:key="item"
:label="item"
:value="item"
/>
</el-select>
</el-form-item>
<el-form-item label="是否无感更新" prop="noSensation">
<el-select v-model="form.noSensation1" class="m-2" placeholder="请选择" size="large">
<el-option
v-for="(item, index) in ['否', '是']"
:key="item"
:label="item"
:value="item"
/>
</el-select>
<el-text style="color: #ff0000; margin-left: 10px">*仅对wgt生效</el-text>
</el-form-item>
<el-form-item label="更新租户" prop="tenantList">
<el-select
v-model="form.tenantIds"
class="m-2"
placeholder="请选择"
clearable
multiple
filterable
size="large"
>
<el-option
v-for="item in tenantList"
:key="item.id"
:label="item.tenantName"
:value="item.id"
/>
</el-select>
</el-form-item>
<el-form-item label="备注" prop="node">
<el-input v-model="form.node" placeholder="请输入备注" />
</el-form-item>
</el-form>
<!-- 表单按钮 -->
<template #footer>
<span v-if="!view" class="dialog-footer">
<el-button type="primary" icon="el-icon-circle-check" @click="handleSubmit"
> </el-button
>
<el-button icon="el-icon-circle-close" @click="box = false"> </el-button>
</span>
</template>
</el-dialog>
</div>
</basic-container>
</template>
<script>
import { getList, getDetail, add, update, remove, tenantpage } from '@/api/system/pdaversionManage';
import option from '@/option/system/pdaversionManage';
import { mapGetters } from 'vuex';
import { getToken } from '@/utils/auth';
export default {
data() {
return {
columnList: [
{
prop: '',
label: '序号',
type: 0,
values: '',
width: 55,
checkarr: [],
fixed: true,
},
{
prop: 'versionName',
label: '版本名称',
type: 1,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'versionCode',
label: '版本code',
type: 1,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'versionType',
label: '版本类型',
type: 1,
values: '',
width: '150',
checkarr: [
{value:'1',label:'开发版本'},
{value:'2',label:'测试版本'},
{value:'3',label:'正式版本'},
],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'tenantNames',
label: '可更新的租户',
type: 1,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'versionName',
label: '包链接',
type: 9,
downprop:'link',
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'isUpdates',
label: '强制更新',
type: 1,
values: '',
width: '150',
checkarr: [
{value:'1',label:'否'},
{value:'2',label:'是'},
],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'noSensation',
label: '无感更新',
type: 1,
values: '',
width: '150',
checkarr: [
{value:'1',label:'否'},
{value:'2',label:'是'},
],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'newTypes',
label: '更新类型',
type: 1,
values: '',
width: '150',
checkarr: [
{value:'1',label:'整包更新'},
{value:'2',label:'补丁更新'},
],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'node',
label: '备注',
type: 1,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'releaseTime',
label: '预发布时间',
type: 1,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'createUserName',
label: '版本发布人',
type: 1,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: '',
label: '操作',
type: 6,
values: '',
width: '150',
checkarr: [],
fixed: 'right',
sortable: false,
},
// ...
],
height: 0,
//
title: '',
//
box: false,
//
search: true,
//
loading: true,
//
view: false,
//
query: {},
//
page: {
currentPage: 1,
pageSize: 10,
total: 40,
},
//
form: {},
//
selectionList: [],
fileList: [],
//
option: option,
//
data: [],
//
tenantList: [],
};
},
mounted() {
this.init();
this.onLoad(this.page);
// setTimeout(() => {
// console.log(this.form.link[0].response.data.link)
// }, 10000);
let arr = [];
this.option.column.map(item => {
if (!item.hide) {
arr.push({
prop: item.prop,
label: item.label,
type: 1,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
});
}
});
console.log(JSON.stringify(arr));
},
computed: {
...mapGetters(['permission']),
ids() {
let ids = [];
this.selectionList.forEach(ele => {
ids.push(ele.id);
});
return ids.join(',');
},
headers() {
return {
'Blade-Auth': 'Bearer ' + getToken(),
};
},
action() {
return '/api/blade-resource/oss/endpoint/put-file';
},
},
methods: {
init() {
this.height = this.setPx(document.body.clientHeight - 340);
tenantpage({}).then(res => {
console.log(res.data.data);
this.tenantList = res.data.data;
});
},
searchHide() {
this.search = !this.search;
},
searchChange() {
this.onLoad(this.page);
},
searchReset() {
this.query = {};
this.page.currentPage = 1;
this.onLoad(this.page);
},
handleSubmit() {
if (!this.form.id) {
this.form.link = this.form.filelink[0].response.data.link;
this.form.versionCode = this.form.versionName.split('.').join('');
this.form.newTypes = this.form.link.indexOf('wgt') == -1 ? '1' : '2';
this.form.isUpdates = this.form.isUpdates1 == '否' ? '1' : '2';
this.form.noSensation = this.form.noSensation1 == '否' ? '1' : '2';
this.form.versionType=this.form.versionType1=='开发版本'?'1':this.form.versionType1=='测试版本'?'2':'3'
add(this.form).then(() => {
this.box = false;
this.onLoad(this.page);
this.$message({
type: 'success',
message: '操作成功!',
});
});
} else {
this.form.newTypes = this.form.link.indexOf('wgt') == -1 ? '1' : '2';
this.form.versionCode = this.form.versionName.split('.').join('');
this.form.isUpdates = this.form.isUpdates1 == '否' ? '1' : '2';
this.form.noSensation = this.form.noSensation1 == '否' ? '1' : '2';
this.form.versionType=this.form.versionType1=='开发版本'?'1':this.form.versionType1=='测试版本'?'2':'3'
update(this.form).then(() => {
this.box = false;
this.onLoad(this.page);
this.$message({
type: 'success',
message: '操作成功!',
});
});
}
},
//
handlePictureCardPreview(file) {},
//
handleRemove(file, fileList) {
console.log(file, fileList);
},
handleAdd() {
this.title = '新增';
this.form = {};
this.box = true;
},
handleEdit(row) {
this.title = '编辑';
this.box = true;
getDetail(row.id).then(res => {
this.form = res.data.data;
this.form.isUpdates1 = res.data.data.isUpdates == '1' ? '否' : '是';
this.form.noSensation1 = res.data.data.noSensation == '1' ? '否' : '是';
this.form.versionType1=this.form.versionType=='1'?'开发版本':this.form.versionType=='2'?'测试版本':'正式版本'
this.form['filelink'] = [res.data.data.link];
this.form.tenantIds= []
res.data.data.tenantList.map(item=>{
this.form.tenantIds.push(item.id)
})
});
},
handleView(row) {
this.title = '查看';
this.view = true;
this.box = true;
getDetail(row.id).then(res => {
this.form = res.data.data;
this.form.isUpdates1 = res.data.data.isUpdates == '1' ? '否' : '是';
this.form.noSensation1 = res.data.data.noSensation == '1' ? '否' : '是';
this.form.versionType1=this.form.versionType=='1'?'开发版本':this.form.versionType=='2'?'测试版本':'正式版本'
this.form['filelink'] = [res.data.data.link];
this.form.tenantIds= []
res.data.data.tenantList.map(item=>{
this.form.tenantIds.push(item.id)
})
});
},
handleDelete() {
if (this.selectionList.length === 0) {
this.$message.warning('请选择至少一条数据');
return;
}
this.$confirm('确定将选择数据删除?', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
})
.then(() => {
return remove(this.ids);
})
.then(() => {
this.selectionClear();
this.onLoad(this.page);
this.$message({
type: 'success',
message: '操作成功!',
});
});
},
rowDel(row) {
this.$confirm('确定将选择数据删除?', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
})
.then(() => {
return remove(row.id);
})
.then(() => {
this.onLoad(this.page);
this.$message({
type: 'success',
message: '操作成功!',
});
});
},
beforeClose(done) {
done();
this.form = {};
this.view = false;
},
selectionChange(list) {
this.selectionList = list;
},
selectionClear() {
this.selectionList = [];
// this.$refs.table.clearSelection();
},
currentChange(currentPage) {
this.page.currentPage = currentPage;
this.onLoad(this.page);
},
sizeChange(pageSize) {
this.page.pageSize = pageSize;
this.onLoad(this.page);
},
onLoad(page, params = {}) {
this.loading = true;
getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
const data = res.data.data;
this.page.total = data.total;
this.data = data.records;
this.data.map(item=>{
item.tenantNames=''
item.tenantList.map((ite,index)=>{
if(index==0){
item.tenantNames+=ite.tenantName
}else{
item.tenantNames+=','+ite.tenantName
}
})
return item
})
this.$functions.newdatas(this.columnList, this.data);
this.loading = false;
this.selectionClear();
});
},
},
};
</script>
<style lang="scss">
.upfilebox {
width: 280px;
}
</style>

1
vite.config.js

@ -14,6 +14,7 @@ export default ({ mode, command }) => {
'/api': {
// target: 'http://192.168.10.126:8889',
target: 'http://192.168.10.123:8889',
// target: 'http://192.168.10.75:8777',
// target: 'http://192.168.10.29:13000',
//target: 'http://test3.javablade.com',
changeOrigin: true,

Loading…
Cancel
Save