|
|
@@ -183,7 +183,33 @@ define(['app/app'], function (app) {
|
|
|
$scope.release = function () {
|
|
|
// 校验
|
|
|
if ($scope.checkAll()) {
|
|
|
- seekPurchase.saveOneSeekPurchase($scope.applyObj,
|
|
|
+ var inquiry = {};
|
|
|
+ var inquiryItem = {};
|
|
|
+ inquiry.recorderUU = $scope.userInfo.userUU;
|
|
|
+ inquiry.enUU = $scope.userInfo.enterprise.uu;
|
|
|
+ inquiry.code = "MALL" + $filter('date')(new Date, 'yyyyMMddsss');
|
|
|
+ inquiry.date = new Date();
|
|
|
+ inquiry.recorder = $scope.userInfo.userName;
|
|
|
+ inquiry.endDate = $scope.applyObj.deadline;
|
|
|
+ inquiry.sourceapp = "MALL";
|
|
|
+ inquiry.amount = 1;
|
|
|
+ inquiryItem.userUU = $scope.userInfo.userUU;
|
|
|
+ inquiryItem.userName = $scope.userInfo.userName;
|
|
|
+ inquiryItem.userTel = $scope.userInfo.userTel;
|
|
|
+ inquiryItem.needquantity = $scope.applyObj.amount;
|
|
|
+ inquiryItem.inbrand = $scope.applyObj.brand;
|
|
|
+ inquiryItem.currency = $scope.applyObj.currency;
|
|
|
+ inquiryItem.cmpCode = $scope.applyObj.code;
|
|
|
+ inquiryItem.unitPrice = $scope.applyObj.unitPrice;
|
|
|
+ inquiryItem.produceDate = $scope.applyObj.produceDate;
|
|
|
+ inquiryItem.date = new Date();
|
|
|
+ inquiryItem.endDate = $scope.applyObj.deadline;
|
|
|
+ inquiryItem.encapsulation = $scope.applyObj.encapsulation;
|
|
|
+ var inquiryItems = [];
|
|
|
+ inquiryItems.push(inquiryItem);
|
|
|
+ inquiry.inquiryItems = inquiryItems;
|
|
|
+
|
|
|
+ seekPurchase.saveOneSeekPurchase(inquiry,
|
|
|
function (data) {
|
|
|
$scope.showUseFlag = false;
|
|
|
$scope.seekPurchaseTableParams.reload();
|
|
|
@@ -244,14 +270,16 @@ define(['app/app'], function (app) {
|
|
|
total: 0,
|
|
|
getData: function ($defer, params) {
|
|
|
const param = BaseService.parseParams(params.url());
|
|
|
+ param.userUU = $scope.userInfo.userUU;
|
|
|
+ param.enUU = $scope.userInfo.enterprise.uu;
|
|
|
// param.isMallGoods = $scope.isMallGoods;
|
|
|
// param.deadline = $scope.deadline;
|
|
|
- // param.keyWord = $scope.keyWord;
|
|
|
+ param.keyword = $scope.keyWord;
|
|
|
// param.status = $scope.searchStatus;
|
|
|
- // param.minReleaseDate = $scope.startDate
|
|
|
- // ? $scope.startDate.getTime() : null;
|
|
|
- // param.maxReleaseDate = $scope.endDate ? $scope.endDate.getTime()
|
|
|
- // : null;
|
|
|
+ param.fromDate = $scope.startDate
|
|
|
+ ? $scope.startDate.getTime() : null;
|
|
|
+ param.endDate = $scope.endDate ? $scope.endDate.getTime()
|
|
|
+ : null;
|
|
|
if ($scope.isSearch) {
|
|
|
param.page = 1;
|
|
|
params.page(1);
|