Commit 3d342e6f authored by zhengke's avatar zhengke
parents a7f6b8c1 b8b5662c
......@@ -101,10 +101,10 @@ export function UploadViittoBlobFile(path, file, callback) {
let vtUploadUrl = "http://192.168.20.214:8120/upload/UploadBlob";
let locationName = window.location.hostname;
if (locationName.indexOf('testerp.oytour') !== -1) {
vtUploadUrl = "http://upload.oytour.com";
vtUploadUrl = "http://upload.oytour.com/upload/UploadBlob";
viewFileUrl = "https://imgfile.oytour.com";
} else if (locationName.indexOf('oytour') !== -1) {
vtUploadUrl = "http://upload.oytour.com";
vtUploadUrl = "http://upload.oytour.com/upload/UploadBlob";
viewFileUrl = "https://imgfile.oytour.com";
}
var UploadConfig = {
......@@ -141,7 +141,6 @@ export function UploadBolbFileToSystem(uploadConfig, fileFullPath, fileObj, uplo
xhr.onload = function () {
uploadLoadding.hide();
var jsonObj = JSON.parse(xhr.responseText);
console.log(206, jsonObj, successCall)
if ((jsonObj.StatusCode === 1 || jsonObj.StatusCode === 0) && successCall) {
var tempArray = [];
if (jsonObj.OtherFile && jsonObj.OtherFile.length > 0) {
......
......@@ -170,7 +170,7 @@
}
.adv-box .property-box{
position: absolute;
left: 532px;
left: 550px;
top: 0px;
width: 640px;
right: 10px;
......
......@@ -61,14 +61,14 @@
<div class="row wrap q-mt-lg">
<div class="col-12">
<q-uploader :style="{ backgroundImage: 'url(' + addMsg.PictureUrl + ')' }" style="width:auto;height:500px;background-repeat:no-repeat;background-size:cover; border:1px solid #eee" flat
hide-upload-btn max-files="1" label="底图" accept=".jpg, image/*" :factory="uploadFile1" auto-upload>
hide-upload-btn max-files="1" label="底图" accept=".jpg, image/*" :factory="uploadFile1" auto-upload no-thumbnails>
</q-uploader>
</div>
</div>
<div class="row wrap q-mt-lg">
<div class="col-12">
<q-uploader :style="{ backgroundImage: 'url(' + addMsg.SamplePicturesUrl + ')' }" style="width:auto;height:500px;background-repeat:no-repeat;background-size:cover; border:1px solid #eee" flat
hide-upload-btn max-files="1" label="原图" accept=".jpg, image/*" :factory="uploadFile2" auto-upload>
hide-upload-btn max-files="1" label="原图" accept=".jpg, image/*" :factory="uploadFile2" auto-upload no-thumbnails>
</q-uploader>
</div>
</div>
......@@ -180,7 +180,6 @@ import {
},
//保存信息
saveRule() {
console.log(this.addMsg)
if(this.addMsg.PictureUrl==""){
this.$q.notify({
type: 'negative',
......
......@@ -298,7 +298,7 @@
<div style="min-height:135px;">
<div style="margin:10px 20px 0 20px">
<el-tabs v-model="WorkActive">
<el-tab-pane label="规则" name="1"></el-tab-pane>
<el-tab-pane label="工作清单规则" name="1"></el-tab-pane>
<el-tab-pane label="工作清单" name="2"></el-tab-pane>
</el-tabs>
<template v-if="WorkActive==2">
......@@ -340,8 +340,12 @@
<template v-if="WorkObj.ItemType==2">
<div style="margin:10px 0;">
<template v-if="workAuthObj.isShowEditAndDelete">
<span v-if="!isShowSure&&WorkObj.WorkContent" title="点击进行修改"
@click="isShowSure=true">{{WorkObj.WorkContent}}</span>
<span v-if="!isShowSure&&WorkObj.WorkContent" style="cursor:pointer;"
@click="isShowSure=true">{{WorkObj.WorkContent}}
 <q-tooltip :offset="[10, 10]">
点击文字进行修改
     </q-tooltip>
</span>
<el-input v-else v-model="WorkObj.WorkContent" @focus="isShowSure=true" placeholder="完成情况怎么样">
</el-input>
</template>
......@@ -429,7 +433,7 @@
</div>
<div class="secondList_Bottom">
<el-tabs v-model="TufaActive">
<el-tab-pane label="规则" name="1"></el-tab-pane>
<el-tab-pane label="突发事件规则" name="1"></el-tab-pane>
<el-tab-pane label="突发事件" name="2"></el-tab-pane>
</el-tabs>
<template v-if="TufaActive==2">
......@@ -540,8 +544,8 @@
</div>
<div class="secondList_Bottom">
<el-tabs v-model="handActive">
<el-tab-pane label="规则" name="1"></el-tab-pane>
<el-tab-pane label="交接说明" name="2"></el-tab-pane>
<el-tab-pane label="交接工作规则" name="1"></el-tab-pane>
<el-tab-pane label="交接工作" name="2"></el-tab-pane>
</el-tabs>
<template v-if="handActive==2">
<div class="tufa_List">
......@@ -722,7 +726,6 @@
getWorkList() {
queryDutyWork_V2(this.qMsg).then(res => {
if (res.Code == 1) {
console.log(res, '数据');
this.HandoverList = res.Data.HandoverList;
this.EmergenciesList = res.Data.EmergenciesList;
this.WorkList = res.Data.WorkList;
......@@ -872,7 +875,8 @@
WorkContent: this.WorkObj.WorkContent,
WorkIsFinish: this.WorkObj.IsChecked,
ItemId: this.WorkObj.ItemId,
FileList: this.WorkObj.FileList
FileList: this.WorkObj.FileList,
ItemType:this.WorkObj.ItemType,
};
if (type == 2) {
saveWorkMsg.WorkContent = this.WorkContent;
......
......@@ -13,7 +13,7 @@
<q-btn label="新增" size="sm" color="accent q-px-md" style="font-weight:400 !important" @click="add" />
</div>
<div class="content" >
<vueWaterfallEasy :imgsArr="addatas" @scrollReachBottom="handleCurrentChange" :maxCols='7' :imgWidth='208' :enablePullDownEvent='true'>
<vueWaterfallEasy :imgsArr="addatas" ref="waterfall" @scrollReachBottom="handleCurrentChange" :maxCols='7' :imgWidth='208' :enablePullDownEvent='true'>
<template slot-scope="props">
<span class="money" v-if="props.value.IsFee==1">{{props.value.ChargeAmount.toFixed(2)}}</span>
<span class="free" v-else>{{$t('advmanager.v_free')}}</span>
......@@ -119,9 +119,12 @@ export default {
if(type==0){
this.addatas=res.Data.PageData
}else{
this.addatas=this.addatas.concat(resDdata.PageData)
this.addatas=this.addatas.concat(res.Data.PageData)
}
this.total=res.Data.Count
if (res.Data.PageData.length == 0) {
this.$refs.waterfall.waterfallOver()
}
}
})
......
......@@ -75,7 +75,7 @@
</li> -->
</ul>
<div class="property-box" v-if='currentNode.type==0 && !isMax'>
<el-form ref="form" :model="currentNode" label-width="100px">
<el-form ref="form" :model="currentNode" label-width="80px">
<el-form-item label="内容:">
<el-input type="textarea" v-model="currentNode.content"></el-input>
</el-form-item>
......@@ -167,11 +167,11 @@
</el-form-item>
</el-form>
</div>
<div class="resorece max-resource" @click="tiggerMax" v-if="isMax">
<div class="resorece max-resource" style="margin-left:100px" @click="tiggerMax" v-if="isMax">
<img :src="st" />
</div>
<div class="property-box" v-if='currentNode.type==1 && !isMax'>
<el-form ref="form" :model="currentNode" label-width="100px">
<el-form ref="form" :model="currentNode" label-width="80px">
<!-- <el-form-item label="宽度:">
<el-input-number v-model="currentNode.width" :min="0"></el-input-number>
</el-form-item>
......@@ -229,7 +229,7 @@
</el-form>
</div>
<div class="property-box" v-if='currentNode.type==2 && !isMax'>
<el-form ref="form" :model="currentNode" label-width="100px">
<el-form ref="form" :model="currentNode" label-width="80px">
<el-form-item label="圆角:">
<el-input-number v-model="currentNode.radius" :min="0"></el-input-number>
<label class="remark">修改块的圆角弧度(有背景色时体现)</label>
......@@ -287,7 +287,7 @@
</el-form>
</div>
<div class="property-box" v-if='currentNode.type==3 && !isMax'>
<el-form ref="form" :model="currentNode" label-width="100px">
<el-form ref="form" :model="currentNode" label-width="80px">
<el-form-item label="内容:">
<el-input type="textarea" v-model="currentNode.content"></el-input>
</el-form-item>
......@@ -481,7 +481,6 @@
if(this.$route.query.id){
this.dataId = this.$route.query.id
}
console.log(479,this.dataId)
// this.user = JSON.parse(window.localStorage.userInfo)
if (this.dataId != 0) {
this.bg = ' '
......@@ -583,7 +582,6 @@
methods: {
loadObj() {
getMyAdDetail({ID:this.dataId}).then(res=>{
console.log('tag', res)
this.isLoading = false
if(res.Code===1){
let data = res.Data
......@@ -613,18 +611,6 @@
},
save(imgUrl) {
this.isLoading = true;
// let msg = {
// ID: this.dataId,
// BaseAdvertisingID: this.templateId,
// content: JSON.stringify(this.nodes),
// AdvertisingPicUrl: '',
// SecretKey: '',
// fileName: '',
// fileSize: '',
// TCID: 0,
// IsAssociated: 0,
// }
let msg = {
ID: this.dataId,
AdvertisingPicUrl: '',
......@@ -632,49 +618,21 @@
Content:JSON.stringify(this.nodes),
SecretKey:""
}
let that = this
let blob = that.base64ToBlob(imgUrl)
// let newArr = [];
// newArr.push(blob);
// var fileName = `${that.uuid(10,10)}.png`
// // var path = `/Adv/user/${that.user.EmployeeId}/${fileName}`;
// var path = `/Adv/user/template/${fileName}`;
UploadViittoBlobFile ("Edu",blob,(res)=>{
this.isLoading = false;
console.log(671,res);
if(res.Code===1){
msg.AdvertisingPicUrl = res.FileUrl
new browserMD5File(blob, function (err, md5) {
msg.SecretKey = md5;
saveMakeAd(msg).then(res=>{
console.log(res)
console.log(651,res)
})
// msg.fileName = fileName;
// msg.fileSize = blob.size;
// that.apipost("Advertising_post_Set", msg, x => {
// that.isLoading = false;
// that.outerVisible = false;
// if (x.data.resultCode == 1) {
// that.$message.success('保存成功!')
// if (msg.ID == 0) {
// that.dataId = x.data.data.result
// }
// } else
// that.$message.success(x.data.message)
// }, err => {})
})
}
},'ad')
})
......@@ -734,6 +692,7 @@
a.readAsDataURL(blob)
},
handleCurrentChange() {
this.adMsg.pageIndex++
this.pageIndex++
this.getaddatas(1)
},
......@@ -744,7 +703,6 @@
}
getAdvertisingList(this.adMsg).then(res=>{
if(res.Code===1){
console.log(397,res)
res.Data.PageData.forEach(x=>{
x.src=`${x.SamplePicturesUrl}?x-oss-process=image/resize,w_200`
x.id=x.ID
......@@ -752,7 +710,7 @@
if(type==0){
this.addatas=res.Data.PageData
}else{
this.addatas=this.addatas.concat(resDdata.PageData)
this.addatas=this.addatas.concat(res.Data.PageData)
}
this.total=res.Data.Count
if (res.Data.PageData.length == 0) {
......@@ -803,12 +761,12 @@
getFileBase64(type) {
let that = this
var cntElem = this.$refs.board;
var shareContent = cntElem
var width = shareContent.offsetWidth
var height = shareContent.offsetHeight
var canvas = document.createElement("canvas")
var scale = 2
// var scale = window.devicePixelRatio;//显示设备的物理像素分辨率与CSS像素分辨率之比
var scale=1
canvas.width = width * scale
canvas.height = height * scale
canvas.getContext("2d").scale(scale, scale)
......@@ -1200,7 +1158,7 @@
nodeId: this.currentMaxId,
type: 0, //0文本,1图片
width: (36 * 4) + 10,
height: 36,
height: 100,
lineHeight: '1',
bg: null,
color: '#000',
......@@ -1239,7 +1197,7 @@
nodeId: this.currentMaxId,
type: 0, //0文本,1图片
width: (16 * 4) + 10,
height: 16,
height: 50,
lineHeight: '1',
bg: null,
color: '#000',
......
......@@ -10,7 +10,7 @@
<span class="free"><i class="el-icon-share"></i> 0</span>
<div class="zezhao">
<a :href='`/#/activity/makeAd?id=${props.value.ID}`'><i class="el-icon-edit" title="修改"></i></a>
<a :href='props.value.AdvertisingPicUrlStr' download="广告图.png"><i class="el-icon-download" title="下载"></i></a>
<a :href='props.value.AdvertisingPicUrlStr' download="广告图.png"><i class="el-icon-download" title="下载"></i></a>
<i class="el-icon-delete" title="删除" @click="deleteItem(props.value)"></i>
</div>
</template>
......@@ -35,7 +35,7 @@ export default {
modelTeams:[],
countrys:[],
addatas:[],
pageIndex:0,
pageIndex:1,
pageSize:15,
total:0,
msg:{
......@@ -74,7 +74,7 @@ export default {
},
getaddatas(type){
if(type==0){
this.pageIndex=0
this.pageIndex=1
}
let msg={
pageIndex:this.pageIndex,
......@@ -91,12 +91,10 @@ export default {
if(type==0){
this.addatas=res.Data.PageData
}else{
this.addatas=this.addatas.concat(resDdata.PageData)
this.addatas=this.addatas.concat(res.Data.PageData)
}
this.total=res.Data.pageCount
}
console.log(98,res)
})
},
}
......
......@@ -134,7 +134,7 @@
margin-right: 15px;
display: inline-block;
text-align: right;
width:60px;
width: 60px;
}
.Scdu_benci::after {
......@@ -270,7 +270,7 @@
</template>
</div>
</div>
</div>
</div>
</div>
</div>
......@@ -281,12 +281,12 @@
</q-card-section>
<q-card-section class="q-pt-none">
<div class="q-gutter-sm" style="width:280px;" v-if="isShowOne">
<span style="position:relative;top:6px;">有无突发</span>
<span style="position:relative;top:6px;">突发事件</span>
<q-radio v-model="isHaveTufa" :val="2" label="有" />
<q-radio v-model="isHaveTufa" :val="1" label="无" />
</div>
<div class="q-gutter-sm" style="width:280px;" v-if="isShowTwo">
<span style="position:relative;top:6px;">有无交接</span>
<span style="position:relative;top:6px;">交接工作</span>
<q-radio v-model="isHaveHand" :val="2" label="有" />
<q-radio v-model="isHaveHand" :val="1" label="无" />
</div>
......@@ -331,8 +331,8 @@
Id: 0,
Shift: 0,
Status: 0, //Status(1-值班打卡,2-交接打卡)
IsBurst:0, //突发
IsHandover:0 //交接
IsBurst: 0, //突发
IsHandover: 0 //交接
},
dataList: {},
//是否显示访客操作按钮
......@@ -346,11 +346,11 @@
isShowEditAndDelete: false, //是否显示编辑和删除按钮【默认不显示】
},
isShowTuFA: false,
isHaveTufa:2, //是否有突发
isHaveHand:2, //是否有交接
isShowOne:false,
isShowTwo:false,
status:0
isHaveTufa: 2, //是否有突发
isHaveHand: 2, //是否有交接
isShowOne: false,
isShowTwo: false,
status: 0
}
},
created() {
......@@ -377,31 +377,34 @@
//值班打卡或值班交接
SetDutyCheck(status) {
this.status = status;
this.checkMsg.IsBurst = this.$refs.schOrder.getTufaHand().IsBurst;
this.checkMsg.IsHandover = this.$refs.schOrder.getTufaHand().IsHandover;
//突发事件
if(this.$refs.schOrder.getTufaHand().IsBurst==0){
this.isShowOne=true;
this.isShowTuFA=true;
}
//交接工作
if(this.$refs.schOrder.getTufaHand().IsHandover==0){
this.isShowTwo=true;
this.isShowTuFA=true;
}
if(this.$refs.schOrder.getTufaHand().IsBurst>0&&this.$refs.schOrder.getTufaHand().IsHandover>0){
this.saveInfo()
if (this.status == 2) {
this.checkMsg.IsBurst = this.$refs.schOrder.getTufaHand().IsBurst;
this.checkMsg.IsHandover = this.$refs.schOrder.getTufaHand().IsHandover;
//突发事件
if (this.$refs.schOrder.getTufaHand().IsBurst == 0) {
this.isShowOne = true;
this.isShowTuFA = true;
}
//交接工作
if (this.$refs.schOrder.getTufaHand().IsHandover == 0) {
this.isShowTwo = true;
this.isShowTuFA = true;
}
if (this.$refs.schOrder.getTufaHand().IsBurst > 0 && this.$refs.schOrder.getTufaHand().IsHandover > 0) {
this.saveInfo()
}
} else {
this.saveInfo();
}
},
//保存
saveInfo(){
let diaMsg='';
if(this.status==1){
diaMsg='是否确定值班打卡?'
saveInfo() {
let diaMsg = '';
if (this.status == 1) {
diaMsg = '是否确定值班打卡?'
}
if(this.status==2){
diaMsg='是否确定值班交接?'
if (this.status == 2) {
diaMsg = '是否确定值班交接?'
}
this.$q.dialog({
title: '消息提示',
......@@ -438,8 +441,8 @@
},
//确定是否有突发
submitHand(){
if(this.isHaveTufa==2){
submitHand() {
if (this.isHaveTufa == 2) {
this.$q.notify({
type: 'negative',
position: "top",
......@@ -448,7 +451,7 @@
this.isShowTuFA = false;
return
}
if(this.isHaveHand==2){
if (this.isHaveHand == 2) {
this.$q.notify({
type: 'negative',
position: "top",
......@@ -457,12 +460,12 @@
this.isShowTuFA = false;
return
}
if(this.isHaveTufa==1){
this.checkMsg.IsBurst=1;
if (this.isHaveTufa == 1) {
this.checkMsg.IsBurst = 1;
this.saveInfo();
}
if(this.isHaveHand==1){
this.checkMsg.IsHandover=1;
if (this.isHaveHand == 1) {
this.checkMsg.IsHandover = 1;
this.saveInfo();
}
this.isShowTuFA = 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