|
|
@@ -655,7 +655,10 @@ define([ 'toaster', 'charts', 'ngTable', 'common/services', 'service/Purc', 'ser
|
|
|
|
|
|
var getDateCondition = function(zone, condition) {
|
|
|
var date = new Date();
|
|
|
- if(zone == 1) {
|
|
|
+ if(zone == -1) {
|
|
|
+ condition.dateFrom = null;
|
|
|
+ condition.dateTo = null;
|
|
|
+ } else if(zone == 1) {
|
|
|
date.setMonth(date.getMonth() - 1);
|
|
|
condition.dateFrom = date;
|
|
|
condition.dateTo = new Date();
|
|
|
@@ -673,11 +676,11 @@ define([ 'toaster', 'charts', 'ngTable', 'common/services', 'service/Purc', 'ser
|
|
|
app.controller('SaleOrderCtrl', ['$scope', '$filter', 'PurcOrderItem', 'PurcOrder', 'ngTableParams', 'toaster', 'ReportService', 'BaseService', 'PurcOrderItemHis',
|
|
|
function($scope, $filter, PurcOrderItem, PurcOrder, ngTableParams, toaster, ReportService, BaseService, PurcOrderItemHis){
|
|
|
$scope.active = 'todo';
|
|
|
- $scope.dateZoneText = '一个月内';
|
|
|
- $scope.condition = {dateZone: 1};
|
|
|
+ $scope.dateZoneText = '不限';
|
|
|
+ $scope.condition = {dateZone: -1};
|
|
|
$scope.changeDateZone = function(zone) {
|
|
|
$scope.condition.dateZone = zone;
|
|
|
- $scope.dateZoneText = typeof zone == 'undefined' ? '半年前' : (zone == 1 ? '一个月内' : '半年内');
|
|
|
+ $scope.dateZoneText = typeof zone == 'undefined' ? '半年前' : (zone == -1 ? '不限' : (zone == 1 ? '一个月内' : '半年内'));
|
|
|
$scope.condition.$dateZoneOpen = false;
|
|
|
getDateCondition(zone, $scope.condition);
|
|
|
$scope.tableParams.reload();
|
|
|
@@ -1602,12 +1605,12 @@ define([ 'toaster', 'charts', 'ngTable', 'common/services', 'service/Purc', 'ser
|
|
|
// 发货提醒
|
|
|
app.controller('SaleNoticeCtrl', ['$scope', '$rootScope', '$filter', 'PurcNotice', 'ngTableParams', 'toaster', 'BaseService', 'PurcNoticeHis', '$modal', 'SaleTruck', 'Symbol', function($scope, $rootScope, $filter, PurcNotice, ngTableParams, toaster, BaseService, PurcNoticeHis, $modal, SaleTruck, Symbol){
|
|
|
$scope.active = 'todo';
|
|
|
- $scope.dateZoneText = '一个月内';
|
|
|
- $scope.condition = {dateZone: 1};
|
|
|
$scope.currency = Symbol.currency;
|
|
|
+ $scope.dateZoneText = '不限';
|
|
|
+ $scope.condition = {dateZone: -1};
|
|
|
$scope.changeDateZone = function(zone) {
|
|
|
$scope.condition.dateZone = zone;
|
|
|
- $scope.dateZoneText = typeof zone == 'undefined' ? '半年前' : (zone == 1 ? '一个月内' : '半年内');
|
|
|
+ $scope.dateZoneText = typeof zone == 'undefined' ? '半年前' : (zone == -1 ? '不限' : (zone == 1 ? '一个月内' : '半年内'));
|
|
|
$scope.condition.$dateZoneOpen = false;
|
|
|
getDateCondition(zone, $scope.condition);
|
|
|
$scope.tableParams.reload();
|
|
|
@@ -1868,19 +1871,12 @@ define([ 'toaster', 'charts', 'ngTable', 'common/services', 'service/Purc', 'ser
|
|
|
*/
|
|
|
app.controller('SaleSendCtrl', ['$scope', '$filter', 'SaleSend', 'ngTableParams', 'toaster', 'BaseService', 'Symbol', function($scope, $filter, SaleSend, ngTableParams, toaster, BaseService, Symbol){
|
|
|
$scope.active = 'all';
|
|
|
- $scope.agreedText = '全部';
|
|
|
- $scope.dateZoneText = '一个月内';
|
|
|
- $scope.condition = {dateZone: 1};
|
|
|
$scope.currency = Symbol.currency;
|
|
|
-
|
|
|
- $scope.changeAgreed = function(agreed) {
|
|
|
- $scope.condition.agreed = agreed;
|
|
|
- $scope.agreedText = typeof agreed == 'undefined' ? '全部' : (agreed == 1 ? '已同意' : '不同意');
|
|
|
- $scope.condition.$agreedOpen = false;
|
|
|
- };
|
|
|
+ $scope.dateZoneText = '不限';
|
|
|
+ $scope.condition = {dateZone: -1};
|
|
|
$scope.changeDateZone = function(zone) {
|
|
|
$scope.condition.dateZone = zone;
|
|
|
- $scope.dateZoneText = typeof zone == 'undefined' ? '半年前' : (zone == 1 ? '一个月内' : '半年内');
|
|
|
+ $scope.dateZoneText = typeof zone == 'undefined' ? '半年前' : (zone == -1 ? '不限' : (zone == 1 ? '一个月内' : '半年内'));
|
|
|
$scope.condition.$dateZoneOpen = false;
|
|
|
getDateCondition(zone, $scope.condition);
|
|
|
$scope.tableParams.reload();
|
|
|
@@ -2608,22 +2604,16 @@ define([ 'toaster', 'charts', 'ngTable', 'common/services', 'service/Purc', 'ser
|
|
|
*/
|
|
|
app.controller('SaleApBillCtrl', ['$scope', '$filter', 'PurcApBill', 'ngTableParams', 'toaster', 'BaseService', 'Symbol', function($scope, $filter, PurcApBill, ngTableParams, toaster, BaseService, Symbol){
|
|
|
$scope.active = 'all';
|
|
|
- $scope.agreedText = '全部';
|
|
|
- $scope.dateZoneText = '一个月内';
|
|
|
- $scope.condition = {dateZone: 1};
|
|
|
- $scope.currency = Symbol.currency;//将币别转化为对应的符号
|
|
|
- $scope.changeAgreed = function(agreed) {
|
|
|
- $scope.condition.agreed = agreed;
|
|
|
- $scope.agreedText = typeof agreed == 'undefined' ? '全部' : (agreed == 1 ? '已同意' : '不同意');
|
|
|
- $scope.condition.$agreedOpen = false;
|
|
|
- };
|
|
|
+ $scope.dateZoneText = '不限';
|
|
|
+ $scope.condition = {dateZone: -1};
|
|
|
$scope.changeDateZone = function(zone) {
|
|
|
$scope.condition.dateZone = zone;
|
|
|
- $scope.dateZoneText = typeof zone == 'undefined' ? '半年前' : (zone == 1 ? '一个月内' : '半年内');
|
|
|
+ $scope.dateZoneText = typeof zone == 'undefined' ? '半年前' : (zone == -1 ? '不限' : (zone == 1 ? '一个月内' : '半年内'));
|
|
|
$scope.condition.$dateZoneOpen = false;
|
|
|
getDateCondition(zone, $scope.condition);
|
|
|
$scope.tableParams.reload();
|
|
|
};
|
|
|
+ $scope.currency = Symbol.currency;//将币别转化为对应的符号
|
|
|
$scope.setActive = function(state) {
|
|
|
if($scope.active != state) {
|
|
|
$scope.active = state;
|