Browse Source

Merge remote-tracking branch 'origin/dev' into dev

fix_bug_pro20231227
caoyizhong 2 years ago
parent
commit
a68fc74bd9
  1. 3
      src/main.js
  2. 34
      src/utils/util.js
  3. 8
      src/utils/watermark.js
  4. 946
      src/views/distribution/inventory/distributionStockArticleDetails.vue
  5. 2
      src/views/distribution/inventory/distrilbutionBillLading.vue
  6. 2
      vite.config.js

3
src/main.js

@ -12,7 +12,7 @@ import Avue from '@smallwei/avue';
import '@smallwei/avue/lib/index.css';
import crudCommon from '@/mixins/crud.js';
import globalc from '@/api/basicdata/globalc.js'
import { getScreen } from './utils/util';
import { getScreen,getHtmls } from './utils/util';
import functions from './utils/functions'
import './permission';
import error from './error';
@ -55,6 +55,7 @@ app.provide('functions',functions)
app.config.globalProperties.$globalc = globalc;
app.config.globalProperties.website = website;
app.config.globalProperties.getScreen = getScreen;
app.config.globalProperties.getHtmls = getHtmls;
app.use(error);
app.use(i18n);

34
src/utils/util.js

@ -277,13 +277,13 @@ export const openWindow = (url, title, w, h) => {
const width = window.innerWidth
? window.innerWidth
: document.documentElement.clientWidth
? document.documentElement.clientWidth
: screen.width;
? document.documentElement.clientWidth
: screen.width;
const height = window.innerHeight
? window.innerHeight
: document.documentElement.clientHeight
? document.documentElement.clientHeight
: screen.height;
? document.documentElement.clientHeight
: screen.height;
const left = width / 2 - w / 2 + dualScreenLeft;
const top = height / 2 - h / 2 + dualScreenTop;
@ -291,13 +291,13 @@ export const openWindow = (url, title, w, h) => {
url,
title,
'toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=no, resizable=yes, copyhistory=no, width=' +
w +
', height=' +
h +
', top=' +
top +
', left=' +
left
w +
', height=' +
h +
', top=' +
top +
', left=' +
left
);
// Puts focus on the newWindow
@ -314,6 +314,18 @@ export const getScreen = isCollapse => {
}
};
export const getHtmls = (arrs, htmldemo) => {
let html = ''
arrs.map(item => {
let strhtml = JSON.parse(JSON.stringify(htmldemo));
for (let key in item) {
let str = '${' + key + '}';
strhtml = strhtml.replace(str, item[key]);
}
html += strhtml;
});
return html
}
/**
* 获取顶部地址栏地址
*/

8
src/utils/watermark.js

@ -11,8 +11,8 @@ let setWatermark = (str) => {
}
let can = document.createElement('canvas')
can.width = 600
can.height = 600
can.width = 700
can.height = 650
let cans = can.getContext('2d')
cans.rotate(-15 * Math.PI / 150)
@ -25,8 +25,8 @@ let setWatermark = (str) => {
let div = document.createElement('div')
div.id = id
div.style.pointerEvents = 'none'
div.style.top = '10px'
div.style.left = '10px'
div.style.top = '50px'
div.style.left = '60px'
div.style.position = 'fixed'
div.style.zIndex = '1000000'
div.style.width = document.documentElement.clientWidth + 'px'

946
src/views/distribution/inventory/distributionStockArticleDetails.vue

File diff suppressed because it is too large Load Diff

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

@ -1495,7 +1495,7 @@ export default {
let fei = new Map();
await this.bianLier(this.costListName,this.clientType,this.costList,fei);
this.form.fei = Object.fromEntries(fei);
this.form.stockArticleId = !this.$route.query.id ? null : this.$route.query.id; //ID
this.form.stockArticleId = !this.$route.query.id ? null : this.$route.query.id+','; //ID
this.form.stockDTOList = this.data;
let o = [];
if(this.fileListClerk.length > 0){

2
vite.config.js

@ -12,7 +12,7 @@ export default ({ mode, command }) => {
port: 2888,
proxy: {
'/api': {
target: 'http://192.168.10.200:8888',
target: 'http://192.168.10.75:8777',
//target: 'http://test3.javablade.com',
changeOrigin: true,
rewrite: path => path.replace(/^\/api/, ''),

Loading…
Cancel
Save