Browse Source

修复图片显示错误

master
feng 4 years ago
parent
commit
9315aefd18
  1. 2
      客户端/齐越慧眼/齐越慧眼/ApiHelper.cs
  2. 5
      客户端/齐越慧眼/齐越慧眼/UserControls/ItemControl.xaml.cs
  3. 39
      客户端/齐越慧眼/齐越慧眼/vuepage/client/src/views/items/Index.vue
  4. 536
      客户端/齐越慧眼/齐越慧眼/vuepage/client/src/views/pricetask/Index.vue
  5. 0
      客户端/齐越慧眼/齐越慧眼/vuepage/dist/css/app.4f57b433.css
  6. 1
      客户端/齐越慧眼/齐越慧眼/vuepage/dist/css/app.a281d79c.css
  7. 1
      客户端/齐越慧眼/齐越慧眼/vuepage/dist/css/app.cbd86d30.css
  8. 2
      客户端/齐越慧眼/齐越慧眼/vuepage/dist/index.html
  9. 2
      客户端/齐越慧眼/齐越慧眼/vuepage/dist/js/app.js
  10. 2
      客户端/齐越慧眼/齐越慧眼/vuepage/dist/js/app.js.map
  11. 12
      客户端/齐越慧眼/齐越慧眼/齐越慧眼.csproj

2
客户端/齐越慧眼/齐越慧眼/ApiHelper.cs

@ -21,7 +21,7 @@ namespace 齐越慧眼
public static string JwtToken { public static string JwtToken {
get get
{ {
//return "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySWQiOiIxNDM5OTA3NDY1MDMzNDIwODAwIiwidGVhbUlkIjoiMTQzNjI4ODUwMDIzNTI0MzUyMCIsImV4cCI6MTY3MDY2ODk3OX0.EXnvVkAAUkDndalUo_SalFKOBsbzpx_c-L_ddCwa7RY";
if (string.IsNullOrEmpty(jwtToken)) if (string.IsNullOrEmpty(jwtToken))
{ {
jwtToken = GetMemoryToken().Replace("\r\n",""); jwtToken = GetMemoryToken().Replace("\r\n","");

5
客户端/齐越慧眼/齐越慧眼/UserControls/ItemControl.xaml.cs

@ -109,6 +109,11 @@ namespace 齐越慧眼.UserControls
{ {
try try
{ {
if (url.StartsWith("http:http"))
{
url= url.Substring("http:".Length);
}
byte[] arr = client.DownloadData(url.Replace("_.webp", "")); byte[] arr = client.DownloadData(url.Replace("_.webp", ""));
arr = GetSmallImgArr(arr); arr = GetSmallImgArr(arr);

39
客户端/齐越慧眼/齐越慧眼/vuepage/client/src/views/items/Index.vue

@ -65,7 +65,7 @@
" "
> >
<a target="_black" :href="item.GoodsUrl"> <a target="_black" :href="item.GoodsUrl">
<img :src="'http:' + item.ItemImg" width="200" height="165" <img :src="getImgPath( item.ItemImg)" width="200" height="165"
/></a> /></a>
<a-row> <a-row>
<a-col :span="12" style="text-align: left" <a-col :span="12" style="text-align: left"
@ -278,10 +278,10 @@
<a-dropdown <a-dropdown
style="margin-left: 10px"> style="margin-left: 10px">
<a-menu slot="overlay" > <a-menu slot="overlay" >
<a-menu-item key="1" @click="getImgBase64(item.ItemImg,1)"> <a-menu-item key="1" @click="getImgBase64(getImgPath( item.ItemImg),1)">
阿里巴巴 阿里巴巴
</a-menu-item> </a-menu-item>
<a-menu-item key="2" @click="getImgBase64(item.ItemImg,2)"> <a-menu-item key="2" @click="getImgBase64(getImgPath( item.ItemImg),2)">
京东 京东
</a-menu-item> </a-menu-item>
</a-menu> </a-menu>
@ -390,8 +390,20 @@
</a-row> </a-row>
</a-col> </a-col>
</a-row> </a-row>
<div style="float:right;margin-top:30px">
<a-pagination
v-model="pagination.current"
:default-current="1"
:total="pagination.total"
:page-size="pagination.pageSize"
@change="changePage"
/>
</div> </div>
</div> </div>
</div>
</template> </template>
@ -403,6 +415,7 @@ export default {
pagination: { pagination: {
current: 1, current: 1,
pageSize: 10, pageSize: 10,
total:0,
showTotal: (total, range) => showTotal: (total, range) =>
`总数:${total} 当前:${range[0]}-${range[1]}`, `总数:${total} 当前:${range[0]}-${range[1]}`,
}, },
@ -424,6 +437,15 @@ export default {
//this.getDatas(0) //this.getDatas(0)
}, },
methods: { methods: {
getImgPath(img){
if(img.indexOf("http")>=0)
{
return img;
}else
{
return 'http:'+img;
}
},
// select // select
handleSearch(value, ext, item) { handleSearch(value, ext, item) {
this.handleChange(value, ext, item); this.handleChange(value, ext, item);
@ -447,8 +469,16 @@ export default {
changeTab(e) { changeTab(e) {
this.getDatas(e); this.getDatas(e);
this.currentTab = e; this.currentTab = e;
this.pagination.current=1;
},
changePage(page, pageSize)
{
this.pagination.current=page;
this.getDatas(this.currentTab);
}, },
getDatas(type) { getDatas(type) {
var that=this
this.http this.http
.post("/HuiYan/teamitems/GetItems", { .post("/HuiYan/teamitems/GetItems", {
PageIndex: this.pagination.current, PageIndex: this.pagination.current,
@ -459,6 +489,7 @@ export default {
...this.filters, ...this.filters,
}) })
.then((res) => { .then((res) => {
that.pagination.total=res.Total
res.Data.forEach((item) => { res.Data.forEach((item) => {
item.isEdit = false; item.isEdit = false;
item.Extensions.forEach((ext) => { item.Extensions.forEach((ext) => {
@ -552,7 +583,7 @@ export default {
}); });
}, },
getImgBase64(src,type) { getImgBase64(src,type) {
hyCoreModel.getImgBase64("http:" + src,type).then((res) => { hyCoreModel.getImgBase64(src,type).then((res) => {
console.log(res); console.log(res);
}); });
}, },

536
客户端/齐越慧眼/齐越慧眼/vuepage/client/src/views/pricetask/Index.vue

@ -1,18 +1,10 @@
<template> <template>
<div class="about"> <div class="about">
<a-tabs @change="changeTab"> <a-tabs @change="changeTab">
<a-tab-pane key="0" tab="待比价"> <a-tab-pane key="0" tab="待比价"> </a-tab-pane>
<a-tab-pane key="1" tab="已比价"> </a-tab-pane>
</a-tab-pane> <a-tab-pane key="2" tab="待修改"> </a-tab-pane>
<a-tab-pane key="1" tab="已比价"> <a-tab-pane key="3" tab="已完结"> </a-tab-pane>
</a-tab-pane>
<a-tab-pane key="2" tab="待修改">
</a-tab-pane>
<a-tab-pane key="3" tab="已完结">
</a-tab-pane>
</a-tabs> </a-tabs>
<div class="border"> <div class="border">
@ -52,122 +44,217 @@
</a-col> </a-col>
</a-row> </a-row>
<!--内容页面--> <!--内容页面-->
<a-row justify="center" style="text-align: center;" v-for="item in datas" :key="item.Id"> <a-row
justify="center"
style="text-align: center"
v-for="item in datas"
:key="item.Id"
>
<a-col :span="4"> <a-col :span="4">
<div class="borderRight"> <div class="borderRight">
<div <div
style="padding-top: 10px;padding-bottom: 10px;width: 200px;margin: 0px auto;height: 215px;"> style="
<a target="_black" :href="item.GoodsUrl"> <img :src="'http:'+item.ItemImg" width="200" padding-top: 10px;
height="165" /></a> padding-bottom: 10px;
width: 200px;
margin: 0px auto;
height: 215px;
"
>
<a target="_black" :href="item.GoodsUrl">
<img :src="getImgPath( item.ItemImg)" width="200" height="165"
/></a>
<a-row> <a-row>
<a-col :span="12" style="text-align: left;">¥{{item.Price}}</a-col> <a-col :span="12" style="text-align: left"
<a-col :span="12" style="text-align: right;">{{item.Sales}}</a-col> >¥{{ item.Price }}</a-col
>
<a-col :span="12" style="text-align: right">{{
item.Sales
}}</a-col>
</a-row> </a-row>
</div> </div>
</div> </div>
</a-col> </a-col>
<!--供应商来源方式--> <!--供应商来源方式-->
<a-col :span="2" style="margin-top: 5px;"> <a-col :span="2" style="margin-top: 5px">
<div v-for="(ext,index) in item.Extensions" style="height: 40px;" :key="index"> <div
<a-select v-if="item.isEdit" v-model='ext.SupplierFrom' :show-search="true" v-for="(ext, index) in item.Extensions"
:not-found-content="null" :show-arrow="false" :filter-option="true" style="height: 40px"
style="width: 100%;" :key="index"
:autoClearSearchValue="false" @search="handleSearch($event,ext)" @blur="handleBlur($event,ext,item)" >
@change="handleChange($event,ext,item)"> <a-select
<a-select-option v-for="item in extFormList" :key="item"> {{item}}</a-select-option> v-if="item.isEdit"
v-model="ext.SupplierFrom"
:show-search="true"
:not-found-content="null"
:show-arrow="false"
:filter-option="true"
style="width: 100%"
:autoClearSearchValue="false"
@search="handleSearch($event, ext)"
@blur="handleBlur($event, ext, item)"
@change="handleChange($event, ext, item)"
>
<a-select-option v-for="item in extFormList" :key="item">
{{ item }}</a-select-option
>
</a-select> </a-select>
<span class="spanValue" v-else>{{ext.SupplierFrom}}</span> <span class="spanValue" v-else>{{ ext.SupplierFrom }}</span>
</div> </div>
</a-col> </a-col>
<!--平台--> <!--平台-->
<a-col :span="1" style="margin-top: 5px;"> <a-col :span="1" style="margin-top: 5px">
<div style="height: 40px;" v-for="(ext,index) in item.Extensions" :key="index"> <div
<span v-if="ext.Platform==0">淘宝</span> style="height: 40px"
<span v-if="ext.Platform==1">京东</span> v-for="(ext, index) in item.Extensions"
<span v-if="ext.Platform==2">阿里巴巴</span> :key="index"
>
<span v-if="ext.Platform == 0">淘宝</span>
<span v-if="ext.Platform == 1">京东</span>
<span v-if="ext.Platform == 2">阿里巴巴</span>
</div> </div>
</a-col> </a-col>
<!--采购链接--> <!--采购链接-->
<a-col :span="2" style="margin-top: 5px;"> <a-col :span="2" style="margin-top: 5px">
<div v-for="(ext,index) in item.Extensions" style="height: 40px;" :key="index"> <div
v-for="(ext, index) in item.Extensions"
style="height: 40px"
:key="index"
>
<a-input v-if="item.isEdit" v-model="ext.BuyUrl"></a-input> <a-input v-if="item.isEdit" v-model="ext.BuyUrl"></a-input>
<span class="spanValue" v-else>{{ext.BuyUrl}}</span> <span class="spanValue" v-else>{{ ext.BuyUrl }}</span>
</div> </div>
</a-col> </a-col>
<!--SKU名称--> <!--SKU名称-->
<a-col :span="3" style="margin-top: 5px;"> <a-col :span="3" style="margin-top: 5px">
<div v-for="(ext,index) in item.Extensions" style="height: 40px;" :key="index"> <div
v-for="(ext, index) in item.Extensions"
style="height: 40px"
:key="index"
>
<a-input v-if="item.isEdit" v-model="ext.SkuName"></a-input> <a-input v-if="item.isEdit" v-model="ext.SkuName"></a-input>
<span class="spanValue" v-else>{{ext.SkuName}}</span> <span class="spanValue" v-else>{{ ext.SkuName }}</span>
</div> </div>
</a-col> </a-col>
<!--采购价--> <!--采购价-->
<a-col :span="2" style="margin-top: 5px;"> <a-col :span="2" style="margin-top: 5px">
<div v-for="(ext,index) in item.Extensions" style="height: 40px;" :key="index"> <div
<div v-if="ext.BuyPrice||item.isEdit"> v-for="(ext, index) in item.Extensions"
style="height: 40px"
:key="index"
>
<div v-if="ext.BuyPrice || item.isEdit">
<a-input v-if="item.isEdit" v-model="ext.BuyPrice"></a-input> <a-input v-if="item.isEdit" v-model="ext.BuyPrice"></a-input>
<span class="spanValue" v-else>{{ext.BuyPrice}}</span> <span class="spanValue" v-else>{{ ext.BuyPrice }}</span>
</div> </div>
<span v-else>-</span> <span v-else>-</span>
</div> </div>
</a-col> </a-col>
<!--快递费--> <!--快递费-->
<a-col :span="2" style="margin-top: 5px;"> <a-col :span="2" style="margin-top: 5px">
<div v-for="(ext,index) in item.Extensions" style="height: 40px;" :key="index"> <div
<div v-if="ext.BuyPrice||item.isEdit"> v-for="(ext, index) in item.Extensions"
style="height: 40px"
:key="index"
>
<div v-if="ext.BuyPrice || item.isEdit">
<a-input v-if="item.isEdit" v-model="ext.KDPrice"></a-input> <a-input v-if="item.isEdit" v-model="ext.KDPrice"></a-input>
<span class="spanValue" v-else>{{ext.KDPrice}}</span> <span class="spanValue" v-else>{{ ext.KDPrice }}</span>
</div> </div>
<span v-else>-</span> <span v-else>-</span>
</div> </div>
</a-col> </a-col>
<!--平台扣点--> <!--平台扣点-->
<a-col :span="2" style="margin-top: 5px;"> <a-col :span="2" style="margin-top: 5px">
<div v-for="(ext,index) in item.Extensions" style="height: 40px;" :key="index"> <div
v-for="(ext, index) in item.Extensions"
style="height: 40px"
:key="index"
>
<!-- <a-input v-if="item.isEdit" v-model="ext.PlatformPoint"></a-input>--> <!-- <a-input v-if="item.isEdit" v-model="ext.PlatformPoint"></a-input>-->
<span class="spanValue">{{ext.PlatformPoint}}</span> <span class="spanValue">{{ ext.PlatformPoint }}</span>
</div> </div>
</a-col> </a-col>
<!--利润--> <!--利润-->
<a-col :span="1" style="margin-top: 5px;"> <a-col :span="1" style="margin-top: 5px">
<div v-for="(ext,index) in item.Extensions" style="height: 40px;" :key="index"> <div
<span v-if="ext.BuyPrice" class="spanValue">{{ext.Profit}}</span> v-for="(ext, index) in item.Extensions"
style="height: 40px"
:key="index"
>
<span v-if="ext.BuyPrice" class="spanValue">{{ ext.Profit }}</span>
<span v-else>-</span> <span v-else>-</span>
</div> </div>
</a-col> </a-col>
<!--利润率--> <!--利润率-->
<a-col :span="1" style="margin-top: 5px;"> <a-col :span="1" style="margin-top: 5px">
<div v-for="(ext,index) in item.Extensions" style="height: 40px;" :key="index"> <div
v-for="(ext, index) in item.Extensions"
style="height: 40px"
:key="index"
>
<!-- <a-input v-if="item.isEdit" v-model="ext.Profits"></a-input>--> <!-- <a-input v-if="item.isEdit" v-model="ext.Profits"></a-input>-->
<span v-if="ext.BuyPrice" class="spanValue">{{ext.Profits}}%</span> <span v-if="ext.BuyPrice" class="spanValue"
>{{ ext.Profits }}%</span
>
<span v-else>-</span> <span v-else>-</span>
</div> </div>
</a-col> </a-col>
<a-col :span="4"> <a-col :span="4">
<div style="padding-top: 10px;padding-bottom: 10px;height: 215px;" class="borderLeft"> <div
<div style="margin: 0px auto;width: 200px;"> style="padding-top: 10px; padding-bottom: 10px; height: 215px"
class="borderLeft"
>
<div style="margin: 0px auto; width: 200px">
<div v-if="item.isEdit"> <div v-if="item.isEdit">
<a-input style="margin-top: 10px;" v-model="item.RivalTitle" placeholder="请输入竞品标题"> <a-input
style="margin-top: 10px"
v-model="item.RivalTitle"
placeholder="请输入竞品标题"
>
</a-input> </a-input>
<a-input style="margin-top: 10px;" v-model="item.RivalPrice" placeholder="请输入竞品价格"> <a-input
style="margin-top: 10px"
v-model="item.RivalPrice"
placeholder="请输入竞品价格"
>
</a-input> </a-input>
<a-input style="margin-top: 10px;" v-model="item.RivalPLCount" placeholder="请输入竞品评论数"> <a-input
style="margin-top: 10px"
v-model="item.RivalPLCount"
placeholder="请输入竞品评论数"
>
</a-input> </a-input>
<a-input style="margin-top: 10px;" v-model="item.RivalGoodsId" placeholder="请输入竞品链接"> <a-input
style="margin-top: 10px"
v-model="item.RivalGoodsId"
placeholder="请输入竞品链接"
>
</a-input> </a-input>
</div> </div>
<div v-else> <div v-else>
<div style="padding-top: 10px;padding-bottom: 10px;width: 200px;margin: 5px auto;"> <div
style="
padding-top: 10px;
padding-bottom: 10px;
width: 200px;
margin: 5px auto;
"
>
<a target="_black" :href="item.RivalGoodsId"> <a target="_black" :href="item.RivalGoodsId">
<img src="/jp.png" width="200" height="165" /></a> <img src="/jp.png" width="200" height="165"
/></a>
<a-row> <a-row>
<a-col :span="12" style="text-align: left;">¥{{item.RivalPrice}}</a-col> <a-col :span="12" style="text-align: left"
<a-col :span="12" style="text-align: right;">{{item.RivalPLCount}}人评论</a-col> >¥{{ item.RivalPrice }}</a-col
>
<a-col :span="12" style="text-align: right"
>{{ item.RivalPLCount }}人评论</a-col
>
</a-row> </a-row>
</div> </div>
</div> </div>
@ -178,264 +265,345 @@
<a-col :span="24" class="borderT"> <a-col :span="24" class="borderT">
<a-row justify="center" type="flex" :align="'middle'"> <a-row justify="center" type="flex" :align="'middle'">
<a-col :span="4"> <a-col :span="4">
<a class="borderNoTop itemtitle" :title="item.Title">{{item.Title}}</a> <a class="borderNoTop itemtitle" :title="item.Title">{{
item.Title
}}</a>
</a-col> </a-col>
<a-col :span="16"> <a-col :span="16">
<a-row> <a-row>
<a-col :span="12" style="text-align: left;"> <a-col :span="12" style="text-align: left">
<span v-if="item.PriceTaskState==0"> <span v-if="item.PriceTaskState == 0">
<a-button style="margin-left: 10px;" type="primary"
@click="getImgBase64(item.ItemImg)">搜图 <a-dropdown
style="margin-left: 10px">
<a-menu slot="overlay" >
<a-menu-item key="1" @click="getImgBase64(getImgPath( item.ItemImg),1)">
阿里巴巴
</a-menu-item>
<a-menu-item key="2" @click="getImgBase64(getImgPath( item.ItemImg),2)">
京东
</a-menu-item>
</a-menu>
<a-button
type="primary">
搜图 <a-icon type="down" />
</a-button> </a-button>
</a-dropdown>
</span> </span>
<a-button v-if="item.PriceTaskState==0" style="margin-left: 10px;" type="primary" <a-button
@click="setState(item.PriceTaskId,1)">完成比价 v-if="item.PriceTaskState == 0"
style="margin-left: 10px"
type="primary"
@click="setState(item.PriceTaskId, 1)"
>完成比价
</a-button> </a-button>
<a-button
<a-button v-if="item.PriceTaskState==1" style="margin-left: 10px;" type="primary" v-if="item.PriceTaskState == 1"
style="margin-left: 10px"
type="primary"
>等待验收 >等待验收
</a-button> </a-button>
<a-button v-if="item.PriceTaskState==2" style="margin-left: 10px;" type="primary" <a-button
@click="setState(item.PriceTaskId,1)">修改完成 v-if="item.PriceTaskState == 2"
style="margin-left: 10px"
type="primary"
@click="setState(item.PriceTaskId, 1)"
>修改完成
</a-button> </a-button>
</a-col> </a-col>
<a-col :span="12" style="text-align: right;" v-if="item.PriceTaskState!=3"> <a-col
<a-button style="margin-right: 10px;" type="primary" v-if="item.isEdit===false" :span="12"
@click="editData(item)">编辑</a-button> style="text-align: right"
<a-button style="margin-right: 10px;" type="primary" v-if="item.isEdit===true" v-if="item.PriceTaskState != 3"
@click="canelEdit(item)">取消</a-button> >
<a-button style="margin-right: 10px;" type="primary" v-if="item.isEdit===true" <a-button
@click="setData(item)">保存</a-button> style="margin-right: 10px"
type="primary"
v-if="item.isEdit === false"
@click="editData(item)"
>编辑</a-button
>
<a-button
style="margin-right: 10px"
type="primary"
v-if="item.isEdit === true"
@click="canelEdit(item)"
>取消</a-button
>
<a-button
style="margin-right: 10px"
type="primary"
v-if="item.isEdit === true"
@click="setData(item)"
>保存</a-button
>
</a-col> </a-col>
</a-row> </a-row>
</a-col> </a-col>
<a-col :span="4"> <a-col :span="4">
<a class="borderNoTop itemtitle" :title="item.RivalTitle">{{item.RivalTitle}}</a> <a class="borderNoTop itemtitle" :title="item.RivalTitle">{{
item.RivalTitle
}}</a>
</a-col> </a-col>
</a-row> </a-row>
</a-col> </a-col>
</a-row> </a-row>
<div style="float:right;margin-top:30px">
<a-pagination
v-model="pagination.current"
:default-current="1"
:total="pagination.total"
:page-size="pagination.pageSize"
@change="changePage"
/>
</div> </div>
</div> </div>
</div>
</template> </template>
<script> <script>
export default { export default {
data() { data() {
return { return {
datas: [], datas: [],
pagination: { pagination: {
current: 1, current: 1,
pageSize: 10, pageSize: 10,
showTotal: (total, range) => `总数:${total} 当前:${range[0]}-${range[1]}` total: 0,
showTotal: (total, range) =>
`总数:${total} 当前:${range[0]}-${range[1]}`,
}, },
filters: {}, filters: {},
sorter: { field: 'Id', order: 'asc' }, sorter: { field: "Id", order: "asc" },
loading: false, loading: false,
queryParam: { condition: 'State', keyword: 0 }, queryParam: { condition: "State", keyword: 0 },
selectedRowKeys: [], selectedRowKeys: [],
currentTab: 0, currentTab: 0,
lastEditData: undefined, lastEditData: undefined,
extFormList:['以图搜款'] extFormList: ["以图搜款"],
} };
}, },
mounted() { mounted() {
window.getDatas = this.getDatas window.getDatas = this.getDatas;
// this.getDatas(0) // this.getDatas(0)
}, },
activated() { activated() {
//this.getDatas(0) //this.getDatas(0)
}, },
methods: { methods: {
getImgPath(img){
if(img.indexOf("http")>=0)
{
return img;
}else
{
return 'http:'+img;
}
},
// select // select
handleSearch(value,ext,item) { handleSearch(value, ext, item) {
this.handleChange(value,ext,item); this.handleChange(value, ext, item);
}, },
handleChange(value,ext,item) { handleChange(value, ext, item) {
ext.SupplierFrom = value != null && value != "" ? value : [];
ext.SupplierFrom= value != null && value != '' ? value : [];
if (
if(item.Extensions.filter(c=>c.SupplierFrom=='以图搜款').length>2) item.Extensions.filter((c) => c.SupplierFrom == "以图搜款").length > 2
{ ) {
this.$message.error('以图搜款最多可选择2个!'); this.$message.error("以图搜款最多可选择2个!");
ext.SupplierFrom='' ext.SupplierFrom = "";
} }
}, },
handleBlur(value,ext) { handleBlur(value, ext) {
ext.SupplierFrom = value; ext.SupplierFrom = value;
if (value&& this.extFormList.indexOf(value) == -1) { if (value && this.extFormList.indexOf(value) == -1) {
this.extFormList.push(value); this.extFormList.push(value);
} }
}, },
changeTab(e) { changeTab(e) {
this.getDatas(e) this.getDatas(e);
this.currentTab = e this.currentTab = e;
this.pagination.current=1;
},
changePage(page, pageSize)
{
this.pagination.current=page;
this.getDatas(this.currentTab);
}, },
getDatas(type) { getDatas(type) {
this.http.post('/HuiYan/pricetasklog/GetItems', { var that=this
this.http
.post("/HuiYan/pricetasklog/GetItems", {
PageIndex: this.pagination.current, PageIndex: this.pagination.current,
PageRows: this.pagination.pageSize, PageRows: this.pagination.pageSize,
SortField: this.sorter.field || 'Id', SortField: this.sorter.field || "Id",
SortType: this.sorter.order, SortType: this.sorter.order,
Search: { condition: 'State', keyword: type }, Search: { condition: "State", keyword: type },
...this.filters ...this.filters,
}).then(res => { })
res.Data.forEach(item => { .then((res) => {
item.isEdit = false that.pagination.total=res.Total
item.Extensions.forEach(ext => { res.Data.forEach((item) => {
ext.PlatformPoint = parseFloat(item.RivalPrice * 0.05).toFixed(2) item.isEdit = false;
ext.Profit = item.RivalPrice - ext.BuyPrice - ext.KDPrice - ext.PlatformPoint item.Extensions.forEach((ext) => {
ext.PlatformPoint = parseFloat(item.RivalPrice * 0.05).toFixed(2);
ext.Profit =
item.RivalPrice -
ext.BuyPrice -
ext.KDPrice -
ext.PlatformPoint;
if (ext.BuyPrice == 0) { if (ext.BuyPrice == 0) {
ext.Profits = 0 ext.Profits = 0;
} } else {
else { ext.Profits = parseFloat(
ext.Profits = parseFloat((ext.Profit / ext.BuyPrice) * 100).toFixed(2) (ext.Profit / ext.BuyPrice) * 100
).toFixed(2);
} }
})
}); });
this.datas = res.Data });
}) this.datas = res.Data;
});
}, },
editData(data) { editData(data) {
data.isEdit = true data.isEdit = true;
this.lastEditData = JSON.parse(JSON.stringify(data)) this.lastEditData = JSON.parse(JSON.stringify(data));
}, },
canelEdit(data) { canelEdit(data) {
this.lastEditData.isEdit = false this.lastEditData.isEdit = false;
Object.assign(data, this.lastEditData) Object.assign(data, this.lastEditData);
}, },
setData(data) { setData(data) {
data.Extensions.forEach(ext => { data.Extensions.forEach((ext) => {
ext.PlatformPoint = parseFloat(data.RivalPrice * 0.05).toFixed(2) ext.PlatformPoint = parseFloat(data.RivalPrice * 0.05).toFixed(2);
ext.Profit = data.RivalPrice - ext.BuyPrice - ext.KDPrice - ext.PlatformPoint ext.Profit =
data.RivalPrice - ext.BuyPrice - ext.KDPrice - ext.PlatformPoint;
if (ext.BuyPrice == 0) { if (ext.BuyPrice == 0) {
ext.Profits = 0 ext.Profits = 0;
} } else {
else { ext.Profits = parseFloat((ext.Profit / ext.BuyPrice) * 100).toFixed(
ext.Profits = parseFloat((ext.Profit / ext.BuyPrice) * 100).toFixed(2) 2
);
} }
}) });
this.http.post('/HuiYan/teamitems/SetItem', data).then(res => { this.http.post("/HuiYan/teamitems/SetItem", data).then((res) => {
if (res.Success) { if (res.Success) {
this.$message.success('操作成功!'); this.$message.success("操作成功!");
data.isEdit = false data.isEdit = false;
} else { } else {
this.$message.error(res.Msg); this.$message.error(res.Msg);
} }
}) });
}, },
setState(id, type) { setState(id, type) {
/// ///
if (type == 5) { if (type == 5) {
this.sendPriceTask(id) this.sendPriceTask(id);
} } else if (type == 0) {
else if (type == 0) { this.canelPriceTask(id);
this.canelPriceTask(id) } else {
} this.http
else { .post(`/HuiYan/pricetasklog/SetState?id=${id}&state=${type}`)
this.http.post(`/HuiYan/pricetasklog/SetState?id=${id}&state=${type}`).then(res => { .then((res) => {
if (res.Success) { if (res.Success) {
this.$message.success('操作成功!'); this.$message.success("操作成功!");
this.getDatas(this.currentTab) this.getDatas(this.currentTab);
} else { } else {
this.$message.error(res.Msg); this.$message.error(res.Msg);
} }
}) });
} }
}, },
sendPriceTask(id) { sendPriceTask(id) {
this.http.post(`/HuiYan/pricetasklog/AddTask?id=${id}`).then(res => { this.http.post(`/HuiYan/pricetasklog/AddTask?id=${id}`).then((res) => {
if (res.Success) { if (res.Success) {
this.$message.success('操作成功!'); this.$message.success("操作成功!");
this.getDatas(this.currentTab) this.getDatas(this.currentTab);
} else { } else {
this.$message.error(res.Msg); this.$message.error(res.Msg);
} }
}) });
}, },
canelPriceTask(id) { canelPriceTask(id) {
this.http.post(`/HuiYan/pricetasklog/CanelTask?id=${id}`).then(res => { this.http.post(`/HuiYan/pricetasklog/CanelTask?id=${id}`).then((res) => {
if (res.Success) { if (res.Success) {
this.$message.success('操作成功!'); this.$message.success("操作成功!");
this.getDatas(this.currentTab) this.getDatas(this.currentTab);
} else { } else {
this.$message.error(res.Msg); this.$message.error(res.Msg);
} }
}) });
}, },
getImgBase64(src) { getImgBase64(src,type) {
hyCoreModel.getImgBase64('http:' + src).then(res => { hyCoreModel.getImgBase64(src,type).then((res) => {
console.log(res) console.log(res);
}) });
}, },
}, },
} };
</script> </script>
<style> <style>
.headCol { .headCol {
border: 1px solid rgba(215, 215, 215, 1); border: 1px solid rgba(215, 215, 215, 1);
border-left: 0px; border-left: 0px;
text-align: center; text-align: center;
background-color: rgba(243, 242, 247, 1); background-color: rgba(243, 242, 247, 1);
} }
.headColFirst { .headColFirst {
border-left: 1px solid rgba(215, 215, 215, 1); border-left: 1px solid rgba(215, 215, 215, 1);
} }
.borderNoTop { .borderNoTop {
border: 1px solid rgba(215, 215, 215, 1); border: 1px solid rgba(215, 215, 215, 1);
border-top: 0px; border-top: 0px;
border-bottom: 0px; border-bottom: 0px;
} }
.borderT { .borderT {
border: 1px solid rgba(215, 215, 215, 1); border: 1px solid rgba(215, 215, 215, 1);
border-left: 0px; border-left: 0px;
border-right: 0px; border-right: 0px;
} }
.border { .border {
border: 1px solid rgba(215, 215, 215, 1); border: 1px solid rgba(215, 215, 215, 1);
width: 1450px; width: 1450px;
} }
.borderLeft { .borderLeft {
border: 1px solid rgba(215, 215, 215, 1); border: 1px solid rgba(215, 215, 215, 1);
border-top: 0px; border-top: 0px;
border-right: 0px; border-right: 0px;
border-bottom: 0px; border-bottom: 0px;
} }
.borderRight { .borderRight {
border: 1px solid rgba(215, 215, 215, 1); border: 1px solid rgba(215, 215, 215, 1);
border-top: 0px; border-top: 0px;
border-left: 0px; border-left: 0px;
border-bottom: 0px; border-bottom: 0px;
} }
.itemtitle { .itemtitle {
height: 50px; height: 50px;
max-height: 50px; max-height: 50px;
display: block; display: block;
overflow: auto; overflow: auto;
} }
.spanValue { .spanValue {
display: block; display: block;
overflow: auto; overflow: auto;
} }
</style> </style>

0
客户端/齐越慧眼/齐越慧眼/vuepage/dist/css/app.90b53025.css → 客户端/齐越慧眼/齐越慧眼/vuepage/dist/css/app.4f57b433.css

1
客户端/齐越慧眼/齐越慧眼/vuepage/dist/css/app.a281d79c.css

File diff suppressed because one or more lines are too long

1
客户端/齐越慧眼/齐越慧眼/vuepage/dist/css/app.cbd86d30.css

File diff suppressed because one or more lines are too long

2
客户端/齐越慧眼/齐越慧眼/vuepage/dist/index.html

@ -1 +1 @@
<!DOCTYPE html><html lang=""><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width,initial-scale=1"><link rel="icon" href="/favicon.ico"><title>client</title><link href="/css/app.a281d79c.css" rel="preload" as="style"><link href="/css/app.css" rel="preload" as="style"><link href="/css/chunk-vendors.09af4a6b.css" rel="preload" as="style"><link href="/css/chunk-vendors.css" rel="preload" as="style"><link href="/js/app.js" rel="preload" as="script"><link href="/js/chunk-vendors.js" rel="preload" as="script"><link href="/css/chunk-vendors.09af4a6b.css" rel="stylesheet"><link href="/css/chunk-vendors.css" rel="stylesheet"><link href="/css/app.a281d79c.css" rel="stylesheet"><link href="/css/app.css" rel="stylesheet"></head><body><noscript><strong>We're sorry but client doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id="app"></div><script src="/js/chunk-vendors.js"></script><script src="/js/app.js"></script></body></html> <!DOCTYPE html><html lang=""><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width,initial-scale=1"><link rel="icon" href="/favicon.ico"><title>client</title><link href="/css/app.4f57b433.css" rel="preload" as="style"><link href="/css/app.css" rel="preload" as="style"><link href="/css/chunk-vendors.09af4a6b.css" rel="preload" as="style"><link href="/css/chunk-vendors.css" rel="preload" as="style"><link href="/js/app.js" rel="preload" as="script"><link href="/js/chunk-vendors.js" rel="preload" as="script"><link href="/css/chunk-vendors.09af4a6b.css" rel="stylesheet"><link href="/css/chunk-vendors.css" rel="stylesheet"><link href="/css/app.4f57b433.css" rel="stylesheet"><link href="/css/app.css" rel="stylesheet"></head><body><noscript><strong>We're sorry but client doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id="app"></div><script src="/js/chunk-vendors.js"></script><script src="/js/app.js"></script></body></html>

2
客户端/齐越慧眼/齐越慧眼/vuepage/dist/js/app.js

File diff suppressed because one or more lines are too long

2
客户端/齐越慧眼/齐越慧眼/vuepage/dist/js/app.js.map

File diff suppressed because one or more lines are too long

12
客户端/齐越慧眼/齐越慧眼/齐越慧眼.csproj

@ -41,10 +41,8 @@
<None Remove="vuepage\client\.eslintrc.js" /> <None Remove="vuepage\client\.eslintrc.js" />
<None Remove="vuepage\client\.gitignore" /> <None Remove="vuepage\client\.gitignore" />
<None Remove="vuepage\client\.postcssrc.js" /> <None Remove="vuepage\client\.postcssrc.js" />
<None Remove="vuepage\dist\css\app.90b53025.css" /> <None Remove="vuepage\dist\css\app.4f57b433.css" />
<None Remove="vuepage\dist\css\app.a281d79c.css" />
<None Remove="vuepage\dist\css\app.b0aefef5.css" /> <None Remove="vuepage\dist\css\app.b0aefef5.css" />
<None Remove="vuepage\dist\css\app.cbd86d30.css" />
<None Remove="vuepage\dist\css\app.css" /> <None Remove="vuepage\dist\css\app.css" />
<None Remove="vuepage\dist\css\chunk-vendors.09af4a6b.css" /> <None Remove="vuepage\dist\css\chunk-vendors.09af4a6b.css" />
<None Remove="vuepage\dist\css\chunk-vendors.css" /> <None Remove="vuepage\dist\css\chunk-vendors.css" />
@ -56,6 +54,7 @@
<None Remove="vuepage\client\README.md" /> <None Remove="vuepage\client\README.md" />
<None Remove="vuepage\client\vue.config.js" /> <None Remove="vuepage\client\vue.config.js" />
<None Remove="vuepage\client\yarn.lock" /> <None Remove="vuepage\client\yarn.lock" />
<None Remove="vuepage\dist\jp.png" />
<None Remove="vuepage\dist\js\app.js" /> <None Remove="vuepage\dist\js\app.js" />
<None Remove="vuepage\dist\js\app.js.map" /> <None Remove="vuepage\dist\js\app.js.map" />
<None Remove="vuepage\dist\js\chunk-vendors.js" /> <None Remove="vuepage\dist\js\chunk-vendors.js" />
@ -72,9 +71,7 @@
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<EmbeddedResource Include="vuepage\dist\css\app.90b53025.css" /> <EmbeddedResource Include="vuepage\dist\css\app.4f57b433.css" />
<EmbeddedResource Include="vuepage\dist\css\app.a281d79c.css" />
<EmbeddedResource Include="vuepage\dist\css\app.cbd86d30.css" />
<EmbeddedResource Include="vuepage\dist\css\app.css" /> <EmbeddedResource Include="vuepage\dist\css\app.css" />
<EmbeddedResource Include="vuepage\dist\css\chunk-vendors.09af4a6b.css" /> <EmbeddedResource Include="vuepage\dist\css\chunk-vendors.09af4a6b.css" />
<EmbeddedResource Include="vuepage\dist\css\chunk-vendors.css" /> <EmbeddedResource Include="vuepage\dist\css\chunk-vendors.css" />
@ -86,6 +83,9 @@
<ItemGroup> <ItemGroup>
<EmbeddedResource Include="vuepage\dist\favicon.ico" /> <EmbeddedResource Include="vuepage\dist\favicon.ico" />
<EmbeddedResource Include="vuepage\dist\index.html" /> <EmbeddedResource Include="vuepage\dist\index.html" />
<EmbeddedResource Include="vuepage\dist\jp.png">
<CopyToOutputDirectory>Never</CopyToOutputDirectory>
</EmbeddedResource>
<EmbeddedResource Include="vuepage\dist\js\app.js" /> <EmbeddedResource Include="vuepage\dist\js\app.js" />
<EmbeddedResource Include="vuepage\dist\js\app.js.map" /> <EmbeddedResource Include="vuepage\dist\js\app.js.map" />
<EmbeddedResource Include="vuepage\dist\js\chunk-vendors.js" /> <EmbeddedResource Include="vuepage\dist\js\chunk-vendors.js" />

Loading…
Cancel
Save