|
|
@@ -7,7 +7,7 @@
|
|
|
<div class="clear">
|
|
|
<div class="floatr">
|
|
|
<el-button type="primary" @click="createOrder()">新增订单</el-button>
|
|
|
- <el-button>导出报表</el-button>
|
|
|
+ <el-button @click="downFinanceList">导出报表</el-button>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
@@ -21,7 +21,7 @@
|
|
|
<!-- @click="clickDev(scope.row.uid)" -->
|
|
|
<span class="lblue point">
|
|
|
<nuxt-link
|
|
|
- :to="{path:'/main/orders_detail?id='+scope.row.id}"
|
|
|
+ :to="{path:'/main/orders_detail?id='+scope.row.order_no}"
|
|
|
>{{scope.row.product_title}}</nuxt-link>
|
|
|
</span>
|
|
|
</template>
|
|
|
@@ -35,7 +35,7 @@
|
|
|
v-if="parseInt(scope.row.real_amount)>=0"
|
|
|
class="green"
|
|
|
>+{{(scope.row.real_amount/100).toFixed(2)}}</span>
|
|
|
- <span v-else class="orange">-{{(scope.row.real_amount/100).toFixed(2)}}</span>
|
|
|
+ <span v-else class="orange">{{(scope.row.real_amount/100).toFixed(2)}}</span>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
<el-table-column label="收支类型">
|
|
|
@@ -234,7 +234,7 @@ export default {
|
|
|
}
|
|
|
},
|
|
|
mounted() {
|
|
|
- this.getTableData();
|
|
|
+ // this.getTableData();
|
|
|
this.getFinanceList();
|
|
|
},
|
|
|
methods: {
|
|
|
@@ -287,23 +287,7 @@ export default {
|
|
|
},
|
|
|
|
|
|
// 获取列表数据
|
|
|
- async getTableData() {
|
|
|
- this.tableData = [];
|
|
|
- let url = "/api/admin/job/get_all_periods";
|
|
|
- let body = { page: this.currentPage, page_size: this.currentPageSize };
|
|
|
- if (this.status) body.j_status = this.status;
|
|
|
- if (this.period) body.p_status = this.period;
|
|
|
- if (this.checkUser) body.chk_user = this.checkUser;
|
|
|
- if (this.jobID) body.job_id = this.jobID;
|
|
|
- const res = await this.$post(url, body);
|
|
|
- const data = res.data;
|
|
|
- this.tableData = this.formatTableData(data.list);
|
|
|
- this.totalData = data;
|
|
|
- // // console.log(this.tableData)
|
|
|
- // this.totalCount = Number(data.total);
|
|
|
- // this.totalPage = data.totalPage;
|
|
|
- this.localData.env = data.current_env;
|
|
|
- },
|
|
|
+
|
|
|
async getFinanceList() {
|
|
|
let body = {
|
|
|
page: this.currentPage,
|
|
|
@@ -315,6 +299,19 @@ export default {
|
|
|
this.finaceList = data.orders;
|
|
|
this.totalCount = Number(data.count);
|
|
|
},
|
|
|
+ async downFinanceList() {
|
|
|
+ let body = {
|
|
|
+ page: this.currentPage,
|
|
|
+ page_size: this.currentPageSize,
|
|
|
+ artificial_mark: 1
|
|
|
+ };
|
|
|
+ // const res = await this.$get("/api/admin/order/get_orders", body);
|
|
|
+ // http://local-rooter.proginn.com:20201/api/admin/order/get_orders?page=1&page_size=20&artificial_mark=1
|
|
|
+ var url =
|
|
|
+ window.location.host + "/api/admin/order/export?" + "artificial_mark=1";
|
|
|
+ console.log(url);
|
|
|
+ window.location.href = "http://" + url;
|
|
|
+ },
|
|
|
createOrder() {
|
|
|
this.$router.push({
|
|
|
path: "artificial_order/",
|